Lines Matching refs:dev_idx
355 struct bch_member *m = __bch2_members_v2_get_mut(mi, ca->dev_idx); in bch2_sb_members_from_cpu()
369 m = bch2_sb_member_get(c->disk_sb.sb, ca->dev_idx); in bch2_dev_io_errors_to_text()
400 m = bch2_members_v2_get_mut(c->disk_sb.sb, ca->dev_idx); in bch2_dev_errors_reset()
488 unsigned dev_idx = c->sb.nr_devices; in bch2_sb_member_alloc() local
495 if (dev_idx < BCH_SB_MEMBERS_MAX) in bch2_sb_member_alloc()
498 for (dev_idx = 0; dev_idx < BCH_SB_MEMBERS_MAX; dev_idx++) { in bch2_sb_member_alloc()
500 if (dev_idx == BCH_SB_MEMBER_INVALID) in bch2_sb_member_alloc()
503 struct bch_member m = bch2_sb_member_get(c->disk_sb.sb, dev_idx); in bch2_sb_member_alloc()
509 best = dev_idx; in bch2_sb_member_alloc()
514 dev_idx = best; in bch2_sb_member_alloc()
520 nr_devices = max_t(unsigned, dev_idx + 1, c->sb.nr_devices); in bch2_sb_member_alloc()
531 return dev_idx; in bch2_sb_member_alloc()