On Thu, May 9, 2013 at 5:29 PM, NeilBrown <neilb@xxxxxxx> wrote: > > It is an unfortunate consequence of incoherent design. > I've occasionally wondered if I should "fix" it. Neil, Thanks for the insight. I don't know the code well but I do notice that changing the md_seq_show() function to print out the raid_disk rather than desc_nr at least gives me the "desired" behavior from /proc/mdstat. This still doesn't change the fact that the "Number" is still changed in the mdadm --detail output but is a quick easy way to change mdstat without actually having to re-architect anything. What do you think? diff --git a/drivers/md/md.c b/drivers/md/md.c index aeceedf..b47fd35 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -7023,7 +7023,7 @@ static int md_seq_show(struct seq_file *seq, void *v) rdev_for_each(rdev, mddev) { char b[BDEVNAME_SIZE]; seq_printf(seq, " %s[%d]", - bdevname(rdev->bdev,b), rdev->desc_nr); + bdevname(rdev->bdev,b), rdev->raid_disk); if (test_bit(WriteMostly, &rdev->flags)) seq_printf(seq, "(W)"); if (test_bit(Faulty, &rdev->flags)) { -- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html