diff options
author | Hunter Shaffer <huntershaffer182456@gmail.com> | 2023-09-24 23:55:37 -0400 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:10:15 -0400 |
commit | 1241df5872b439ff1e5a8c70e0ce82345264904f (patch) | |
tree | 6830d32daf5e3481d399b52a1224a5093e914186 /fs/bcachefs/replicas.c | |
parent | 73bbeaa2de1d429590a1b5ddd706dfeaf6d7d0e1 (diff) | |
download | linux-1241df5872b439ff1e5a8c70e0ce82345264904f.tar.gz linux-1241df5872b439ff1e5a8c70e0ce82345264904f.tar.bz2 linux-1241df5872b439ff1e5a8c70e0ce82345264904f.zip |
bcachefs: Add new helper to retrieve bch_member from sb
Prep work for introducing bch_sb_field_members_v2 - introduce new
helpers that will check for members_v2 if it exists, otherwise using v1
Signed-off-by: Hunter Shaffer <huntershaffer182456@gmail.com>
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/replicas.c')
-rw-r--r-- | fs/bcachefs/replicas.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/bcachefs/replicas.c b/fs/bcachefs/replicas.c index dbef41cd8593..a9a694fb0b18 100644 --- a/fs/bcachefs/replicas.c +++ b/fs/bcachefs/replicas.c @@ -805,7 +805,6 @@ static int bch2_cpu_replicas_validate(struct bch_replicas_cpu *cpu_r, struct bch_sb *sb, struct printbuf *err) { - struct bch_sb_field_members *mi = bch2_sb_get_members(sb); unsigned i, j; sort_cmp_size(cpu_r->entries, @@ -837,7 +836,7 @@ static int bch2_cpu_replicas_validate(struct bch_replicas_cpu *cpu_r, } for (j = 0; j < e->nr_devs; j++) - if (!bch2_dev_exists(sb, mi, e->devs[j])) { + if (!bch2_dev_exists(sb, e->devs[j])) { prt_printf(err, "invalid device %u in entry ", e->devs[j]); bch2_replicas_entry_to_text(err, e); return -BCH_ERR_invalid_sb_replicas; |