Commit 352f526
md/raid10: fix "enough" function for detecting if array is failed.
commit 80b4812 upstream.
The 'enough' function is written to work with 'near' arrays only
in that is implicitly assumes that the offset from one 'group' of
devices to the next is the same as the number of copies.
In reality it is the number of 'near' copies.
So change it to make this number explicit.
This bug makes it possible to run arrays without enough drives
present, which is dangerous.
It is appropriate for an -stable kernel, but will almost certainly
need to be modified for some of them.
Reported-by: Jakub Husák <jakub@gooseman.cz>
Signed-off-by: NeilBrown <neilb@suse.de>
[bwh: Backported to 3.2: s/geo->/conf->/]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Cc: Rui Xiang <rui.xiang@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent e4bf930 commit 352f526
1 file changed
+5
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1419 | 1419 | | |
1420 | 1420 | | |
1421 | 1421 | | |
| 1422 | + | |
1422 | 1423 | | |
1423 | | - | |
1424 | | - | |
| 1424 | + | |
| 1425 | + | |
1425 | 1426 | | |
1426 | | - | |
| 1427 | + | |
1427 | 1428 | | |
1428 | 1429 | | |
1429 | 1430 | | |
| 1431 | + | |
1430 | 1432 | | |
1431 | 1433 | | |
1432 | 1434 | | |
| |||
0 commit comments