linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Shaohua Li <shli@kernel.org>
To: "linux-raid@vger.kernel.org" <linux-raid@vger.kernel.org>,
	"neilb@suse.de" <neilb@suse.de>
Subject: Re: [RFC]md: using GFP_NOIO to allocate bio for flush request
Date: Tue, 8 May 2012 18:18:00 +0800	[thread overview]
Message-ID: <20120508101800.GB9757@kernel.org> (raw)
In-Reply-To: <4F8BAED6.9090105@kernel.org>

On Mon, Apr 16, 2012 at 01:32:06PM +0800, Shaohua Li wrote:
> 
> flush request is issued in transaction commit code path usually, so
> looks using
> GFP_KERNEL to allocate memory for flush request bio falls into the classic
> deadlock issue. dm already gets it right.
ping!


> Signed-off-by: Shaohua Li <shli@fusionio.com>
> ---
>  drivers/md/md.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> Index: linux/drivers/md/md.c
> ===================================================================
> --- linux.orig/drivers/md/md.c	2012-04-13 10:03:58.395497650 +0800
> +++ linux/drivers/md/md.c	2012-04-13 10:04:37.445497882 +0800
> @@ -450,7 +450,7 @@ static void submit_flushes(struct work_s
>  			atomic_inc(&rdev->nr_pending);
>  			atomic_inc(&rdev->nr_pending);
>  			rcu_read_unlock();
> -			bi = bio_alloc_mddev(GFP_KERNEL, 0, mddev);
> +			bi = bio_alloc_mddev(GFP_NOIO, 0, mddev);
>  			bi->bi_end_io = md_end_flush;
>  			bi->bi_private = rdev;
>  			bi->bi_bdev = rdev->bdev;

  reply	other threads:[~2012-05-08 10:18 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-16  5:32 [RFC]md: using GFP_NOIO to allocate bio for flush request Shaohua Li
2012-05-08 10:18 ` Shaohua Li [this message]
2012-05-08 19:31   ` Dan Williams
2012-05-08 20:14     ` 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=20120508101800.GB9757@kernel.org \
    --to=shli@kernel.org \
    --cc=linux-raid@vger.kernel.org \
    --cc=neilb@suse.de \
    /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).