diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2021-01-21 20:51:51 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:08:52 -0400 |
commit | 72eab8da47b211f50d0b68548e4cf070efb0c7ef (patch) | |
tree | 2e4ecbf7bfdeee280bd96369243648b535da8bfe /fs/bcachefs/chardev.c | |
parent | 079663d8ed81bfd74a331b819eda17d753719605 (diff) |
bcachefs: Refactor dev usage
This is to make it more amenable for serialization.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/chardev.c')
-rw-r--r-- | fs/bcachefs/chardev.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/bcachefs/chardev.c b/fs/bcachefs/chardev.c index 7c77fd09c834..34085e32a159 100644 --- a/fs/bcachefs/chardev.c +++ b/fs/bcachefs/chardev.c @@ -477,11 +477,11 @@ static long bch2_ioctl_dev_usage(struct bch_fs *c, arg.nr_buckets = ca->mi.nbuckets - ca->mi.first_bucket; arg.available_buckets = arg.nr_buckets - src.buckets_unavailable; arg.ec_buckets = src.buckets_ec; - arg.ec_sectors = src.sectors_ec; + arg.ec_sectors = 0; for (i = 0; i < BCH_DATA_NR; i++) { - arg.buckets[i] = src.buckets[i]; - arg.sectors[i] = src.sectors[i]; + arg.buckets[i] = src.d[i].buckets; + arg.sectors[i] = src.d[i].sectors; } percpu_ref_put(&ca->ref); |