projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6d50824
)
[PATCH] md: fix BUG when raid10 rebuilds without enough drives
author
NeilBrown
<
[email protected]
>
Fri, 9 Sep 2005 23:24:04 +0000
(16:24 -0700)
committer
Linus Torvalds
<
[email protected]
>
Fri, 9 Sep 2005 23:39:15 +0000
(16:39 -0700)
This shouldn't be a BUG. We should cope.
Signed-off-by: Neil Brown <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
drivers/md/raid10.c
patch
|
blob
|
history
diff --git
a/drivers/md/raid10.c
b/drivers/md/raid10.c
index 834bf0f862225c471648fbea0863d8cb1541ad88..5bd1e9ec899d8b23f02d498664ca7d29c76a9a7c 100644
(file)
--- a/
drivers/md/raid10.c
+++ b/
drivers/md/raid10.c
@@
-1474,7
+1474,13
@@
static sector_t sync_request(mddev_t *mddev, sector_t sector_nr, int *skipped, i
}
}
if (j == conf->copies) {
- BUG();
+ /* Cannot recover, so abort the recovery */
+ put_buf(r10_bio);
+ r10_bio = rb2;
+ if (!test_and_set_bit(MD_RECOVERY_ERR, &mddev->recovery))
+ printk(KERN_INFO "raid10: %s: insufficient working devices for recovery.\n",
+ mdname(mddev));
+ break;
}
}
if (biolist == NULL) {