diff options
author | Darrick J. Wong <darrick.wong@oracle.com> | 2019-07-03 20:36:26 -0700 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2019-07-03 20:36:26 -0700 |
commit | 7035f9724f8497c709077c08df2073bfcde9c2f5 (patch) | |
tree | c54718e02aa9003ed7588f5f789b2537d947f7a7 /fs/xfs/xfs_ioctl.c | |
parent | 8bfe9d1810e657aaa1b4137f43fae83560e6d71d (diff) | |
download | linux-7035f9724f8497c709077c08df2073bfcde9c2f5.tar.gz linux-7035f9724f8497c709077c08df2073bfcde9c2f5.tar.bz2 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_ioctl.c')
-rw-r--r-- | fs/xfs/xfs_ioctl.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/fs/xfs/xfs_ioctl.c b/fs/xfs/xfs_ioctl.c index 0bfee8a05454..9f1984c31ba2 100644 --- a/fs/xfs/xfs_ioctl.c +++ b/fs/xfs/xfs_ioctl.c @@ -716,10 +716,13 @@ out_unlock: /* Return 0 on success or positive error */ int xfs_fsbulkstat_one_fmt( - struct xfs_ibulk *breq, - const struct xfs_bstat *bstat) + struct xfs_ibulk *breq, + const struct xfs_bulkstat *bstat) { - if (copy_to_user(breq->ubuffer, bstat, sizeof(*bstat))) + struct xfs_bstat bs1; + + xfs_bulkstat_to_bstat(breq->mp, &bs1, bstat); + if (copy_to_user(breq->ubuffer, &bs1, sizeof(bs1))) return -EFAULT; return xfs_ibulk_advance(breq, sizeof(struct xfs_bstat)); } |