linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: NeilBrown <neilb@suse.de>
To: Adam Kwolek <adam.kwolek@intel.com>
Cc: linux-raid@vger.kernel.org, dan.j.williams@intel.com,
	ed.ciechanowski@intel.com, wojciech.neubauer@intel.com
Subject: Re: [PATCH 4/6] FIX: mdadm throws coredump on exit in error case
Date: Mon, 17 Jan 2011 12:33:43 +1100	[thread overview]
Message-ID: <20110117123343.07494fa2@notabene.brown> (raw)
In-Reply-To: <20110113145034.12728.14388.stgit@gklab-128-013.igk.intel.com>

On Thu, 13 Jan 2011 15:50:34 +0100 Adam Kwolek <adam.kwolek@intel.com> wrote:

> When mdadm falls in "reduce size" error on takeovered array it jumps
> to release and tries execute backward takeover. This time sra pointer is not initialized
> and coredump is generated.
> 
> Signed-off-by: Adam Kwolek <adam.kwolek@intel.com>
> ---
> 
>  Grow.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
> 
> diff --git a/Grow.c b/Grow.c
> index 7cc6bae..f1a6218 100644
> --- a/Grow.c
> +++ b/Grow.c
> @@ -1594,7 +1594,7 @@ static int reshape_array(char *container, int cfd, int fd, char *devname,
>  	unsigned long cache;
>  	unsigned long long array_size;
>  	int done;
> -	struct mdinfo *sra;
> +	struct mdinfo *sra = NULL;
>  	int info_reloaded = 0;
>  
>  
> @@ -1802,7 +1802,6 @@ static int reshape_array(char *container, int cfd, int fd, char *devname,
>  	sra = sysfs_read(fd, 0,
>  			 GET_COMPONENT|GET_DEVS|GET_OFFSET|GET_STATE|GET_CHUNK|
>  			 GET_CACHE);
> -
>  	if (!sra) {
>  		fprintf(stderr, Name ": %s: Cannot get array details from sysfs\n",
>  			devname);
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-raid" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


Applied, thanks.

NeilBrown


  reply	other threads:[~2011-01-17  1:33 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-13 14:50 [PATCH 0/6] OLCE raid5/0 (all arrays in container) Adam Kwolek
2011-01-13 14:50 ` [PATCH 1/6] imsm: Update metadata for second array Adam Kwolek
2011-01-13 14:50 ` [PATCH 2/6] FIX: continue raid0 reshape Adam Kwolek
2011-01-13 14:50 ` [PATCH 3/6] FIX: reshape raid0 on second array Adam Kwolek
2011-01-13 14:50 ` [PATCH 4/6] FIX: mdadm throws coredump on exit in error case Adam Kwolek
2011-01-17  1:33   ` NeilBrown [this message]
2011-01-13 14:50 ` [PATCH 5/6] FIX: mdadm hangs during reshape Adam Kwolek
2011-01-17  1:37   ` NeilBrown
2011-01-17  9:43     ` Kwolek, Adam
2011-01-13 14:50 ` [PATCH 6/6] FIX: sync_completed == 0 causes reshape cancellation in metadata Adam Kwolek
2011-01-17  1:38   ` NeilBrown
2011-01-17  1:31 ` [PATCH 0/6] OLCE raid5/0 (all arrays in container) NeilBrown
2011-01-17 11:52   ` Kwolek, Adam
2011-01-19 20:41     ` NeilBrown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110117123343.07494fa2@notabene.brown \
    --to=neilb@suse.de \
    --cc=adam.kwolek@intel.com \
    --cc=dan.j.williams@intel.com \
    --cc=ed.ciechanowski@intel.com \
    --cc=linux-raid@vger.kernel.org \
    --cc=wojciech.neubauer@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).