From mboxrd@z Thu Jan 1 00:00:00 1970 From: Neil Brown Subject: Re: [PATCH 15/53] FIX: Unfreeze not only container for external metadata Date: Mon, 29 Nov 2010 10:48:44 +1100 Message-ID: <20101129104844.2ec7efd3@notabene.brown> References: <20101126075407.5221.62582.stgit@gklab-170-024.igk.intel.com> <20101126080545.5221.8247.stgit@gklab-170-024.igk.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20101126080545.5221.8247.stgit@gklab-170-024.igk.intel.com> Sender: linux-raid-owner@vger.kernel.org To: Adam Kwolek Cc: linux-raid@vger.kernel.org, dan.j.williams@intel.com, ed.ciechanowski@intel.com List-Id: linux-raid.ids On Fri, 26 Nov 2010 09:05:45 +0100 Adam Kwolek wrote: > Unfreeze for external metadata case should unfreeze arrays and container, > not only container as so far. Unfreeze() function doesn't know > what the changes to configuration was made so far, and if arrays > are pulled from frozen state in md. > Unfreeze() has to make sure by performing array unfreeze that all arrays > are not frozen and then unblock monitor. unfreeze for external metadata case *does* unfreeze the arrays. unfreeze_container calls unblock_monitor which calls unblock_subarray for each subarray. So I cannot see that this patch changes anything. What have I missed? NeilBrown > > Signed-off-by: Adam Kwolek > --- > > Grow.c | 18 ++++++++---------- > 1 files changed, 8 insertions(+), 10 deletions(-) > > diff --git a/Grow.c b/Grow.c > index 4060129..8ca1812 100644 > --- a/Grow.c > +++ b/Grow.c > @@ -495,16 +495,14 @@ static void unfreeze(struct supertype *st, int frozen) > return; > > if (st->ss->external) > - return unfreeze_container(st); > - else { > - struct mdinfo *sra = sysfs_read(-1, st->devnum, GET_VERSION); > - > - if (sra) > - sysfs_set_str(sra, NULL, "sync_action", "idle"); > - else > - fprintf(stderr, Name ": failed to unfreeze array\n"); > - sysfs_free(sra); > - } > + unfreeze_container(st); > + > + struct mdinfo *sra = sysfs_read(-1, st->devnum, GET_VERSION); > + if (sra) > + sysfs_set_str(sra, NULL, "sync_action", "idle"); > + else > + fprintf(stderr, Name ": failed to unfreeze array\n"); > + sysfs_free(sra); > } > > static void wait_reshape(struct mdinfo *sra)