]> git.ipfire.org Git - thirdparty/mdadm.git/commitdiff
Do not set default 'before.layout' when reshaping from RAID4 to RAID4
authorBaldysiak, Pawel <pawel.baldysiak@intel.com>
Fri, 30 May 2014 14:38:09 +0000 (14:38 +0000)
committerNeilBrown <neilb@suse.de>
Mon, 2 Jun 2014 02:29:37 +0000 (12:29 +1000)
Commit fdcad551e9a54c4aa8c4b63160b76e2c539a0441
brings some changes to reshape process.
Setting 'before.layout' when reshaping from RAID4 to another RAID4 is
not really necessary.
If reshape is restarted 'before.layout' will be compared with
'info->array.layout' in reshape_array(). Changes brought by mentioned
commit will cause this comparation return as false, becouse 'array.layout'
is always set to 'ALGORITHM_PARITY_N' in analyse_change() for RAID4, so
reshape will not be continued after reboot/stop.
This patch reverts unnecessary changes.

Signed-off-by: Pawel Baldysiak pawel.baldysiak@intel.com
Reviewed-by: Artur Paszkiewicz <artur.paszkiewicz@intel.com>
Signed-off-by: NeilBrown <neilb@suse.de>
Grow.c

diff --git a/Grow.c b/Grow.c
index 2af6c96e764a67b6125bea90775342b462f61a45..2bb4e98fef63151cea000aa9e6619ecff30503f5 100644 (file)
--- a/Grow.c
+++ b/Grow.c
@@ -1322,7 +1322,6 @@ char *analyse_change(char *devname, struct mdinfo *info, struct reshape *re)
 
                switch (re->level) {
                case 4:
-                       re->before.layout = 0;
                        re->after.layout = 0;
                        break;
                case 5: