mirror of
https://github.com/torvalds/linux.git
synced 2024-11-12 07:01:57 +00:00
[PATCH] md: only try to print recovery/resync status for personalities that support recovery
The introduction of 'resync=PENDING' (for read-only devices) caused that message to appear for non-syncable arrays like raid0 and linear. Simplest thing is to not try to print any resync info unless the personality clearly supports it. Signed-off-by: Neil Brown <neilb@suse.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
411036fa19
commit
8e1b39d623
@ -3722,13 +3722,15 @@ static int md_seq_show(struct seq_file *seq, void *v)
|
|||||||
if (mddev->pers) {
|
if (mddev->pers) {
|
||||||
mddev->pers->status (seq, mddev);
|
mddev->pers->status (seq, mddev);
|
||||||
seq_printf(seq, "\n ");
|
seq_printf(seq, "\n ");
|
||||||
if (mddev->curr_resync > 2) {
|
if (mddev->pers->sync_request) {
|
||||||
status_resync (seq, mddev);
|
if (mddev->curr_resync > 2) {
|
||||||
seq_printf(seq, "\n ");
|
status_resync (seq, mddev);
|
||||||
} else if (mddev->curr_resync == 1 || mddev->curr_resync == 2)
|
seq_printf(seq, "\n ");
|
||||||
seq_printf(seq, "\tresync=DELAYED\n ");
|
} else if (mddev->curr_resync == 1 || mddev->curr_resync == 2)
|
||||||
else if (mddev->recovery_cp < MaxSector)
|
seq_printf(seq, "\tresync=DELAYED\n ");
|
||||||
seq_printf(seq, "\tresync=PENDING\n ");
|
else if (mddev->recovery_cp < MaxSector)
|
||||||
|
seq_printf(seq, "\tresync=PENDING\n ");
|
||||||
|
}
|
||||||
} else
|
} else
|
||||||
seq_printf(seq, "\n ");
|
seq_printf(seq, "\n ");
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user