summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_ioctl32.c
diff options
context:
space:
mode:
authorDarrick J. Wong2019-07-04 05:36:26 +0200
committerDarrick J. Wong2019-07-04 05:36:26 +0200
commit7035f9724f8497c709077c08df2073bfcde9c2f5 (patch)
treec54718e02aa9003ed7588f5f789b2537d947f7a7 /fs/xfs/xfs_ioctl32.c
parentxfs: rename bulkstat functions (diff)
downloadkernel-qcow2-linux-7035f9724f8497c709077c08df2073bfcde9c2f5.tar.gz
kernel-qcow2-linux-7035f9724f8497c709077c08df2073bfcde9c2f5.tar.xz
kernel-qcow2-linux-7035f9724f8497c709077c08df2073bfcde9c2f5.zip
xfs: introduce new v5 bulkstat structure
Introduce a new version of the in-core bulkstat structure that supports our new v5 format features. This structure also fills the gaps in the previous structure. We leave wiring up the ioctls for the next patch. Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com> Reviewed-by: Allison Collins <allison.henderson@oracle.com> Reviewed-by: Brian Foster <bfoster@redhat.com>
Diffstat (limited to 'fs/xfs/xfs_ioctl32.c')
-rw-r--r--fs/xfs/xfs_ioctl32.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/fs/xfs/xfs_ioctl32.c b/fs/xfs/xfs_ioctl32.c
index 084b44a026a7..ed8e012dabbb 100644
--- a/fs/xfs/xfs_ioctl32.c
+++ b/fs/xfs/xfs_ioctl32.c
@@ -166,10 +166,14 @@ xfs_bstime_store_compat(
/* Return 0 on success or positive error (to xfs_bulkstat()) */
STATIC int
xfs_fsbulkstat_one_fmt_compat(
- struct xfs_ibulk *breq,
- const struct xfs_bstat *buffer)
+ struct xfs_ibulk *breq,
+ const struct xfs_bulkstat *bstat)
{
- struct compat_xfs_bstat __user *p32 = breq->ubuffer;
+ struct compat_xfs_bstat __user *p32 = breq->ubuffer;
+ struct xfs_bstat bs1;
+ struct xfs_bstat *buffer = &bs1;
+
+ xfs_bulkstat_to_bstat(breq->mp, &bs1, bstat);
if (put_user(buffer->bs_ino, &p32->bs_ino) ||
put_user(buffer->bs_mode, &p32->bs_mode) ||