diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2024-04-30 22:43:20 +0300 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2024-05-09 00:29:22 +0300 |
commit | 9b3059a1b3e9a71e345edf52f8487fc881d9f414 (patch) | |
tree | 10c7b6aebb1e88d4e42aba7dda6a1f45bf080295 /fs/bcachefs/buckets.h | |
parent | 4cd91e2f87a6b1f28806fc0082a9b31ce23d28b8 (diff) | |
download | linux-9b3059a1b3e9a71e345edf52f8487fc881d9f414.tar.xz |
bcachefs: bch2_check_alloc_key() -> bch2_dev_tryget_noerror()
More elimination of bch2_dev_bkey_exists() usage.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/buckets.h')
-rw-r--r-- | fs/bcachefs/buckets.h | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/fs/bcachefs/buckets.h b/fs/bcachefs/buckets.h index f352d88d9b8e..95cf3c290734 100644 --- a/fs/bcachefs/buckets.h +++ b/fs/bcachefs/buckets.h @@ -35,11 +35,6 @@ static inline u64 sector_to_bucket_and_offset(const struct bch_dev *ca, sector_t return div_u64_rem(s, ca->mi.bucket_size, offset); } -static inline bool bucket_valid(const struct bch_dev *ca, u64 b) -{ - return b - ca->mi.first_bucket < ca->mi.nbuckets_minus_first; -} - #define for_each_bucket(_b, _buckets) \ for (_b = (_buckets)->b + (_buckets)->first_bucket; \ _b < (_buckets)->b + (_buckets)->nbuckets; _b++) |