]> git.ipfire.org Git - thirdparty/mdadm.git/commit - super-intel.c
imsm: FIX: Raid5 data corruption data recovering from backup
authorAdam Kwolek <adam.kwolek@intel.com>
Tue, 14 Jun 2011 02:42:22 +0000 (12:42 +1000)
committerNeilBrown <neilb@suse.de>
Tue, 14 Jun 2011 02:42:22 +0000 (12:42 +1000)
commitd1877f697d8084755c80079bc3a8ee7f93788833
treefa3f2d523ce32585f3d1ea40920e95e59ea9159b
parentb66e591b145c84d59270410a34abcd5136caa24f
imsm: FIX: Raid5 data corruption data recovering from backup

Sporadicaly when Raid5's data are restored from backup area,
corruption occurs.
It doesn't happen if reshape process is beyond critical section.

Root cause of the problem is passing wrong starting point in
restore_stripes(). It was hard coded to 0 so far.
This causes that parity disks position in first stripe was always set
to the last raid disk. This position should depend on data position in array.

Proper start position was set and pointer for restoring data
(copy area address) is adjusted to passed start parameter.

Signed-off-by: Adam Kwolek <adam.kwolek@intel.com>
Signed-off-by: Krzysztof Wojcik <krzysztof.wojcik@intel.com>
Signed-off-by: NeilBrown <neilb@suse.de>
super-intel.c