linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Vivek Goyal <vgoyal@redhat.com>
To: NeilBrown <neilb@suse.de>
Cc: Mike Snitzer <snitzer@redhat.com>,
	Jens Axboe <jaxboe@fusionio.com>,
	linux-kernel@vger.kernel.org
Subject: Re: blk_throtl_exit taking q->queue_lock is problematic
Date: Mon, 21 Feb 2011 09:42:40 -0500	[thread overview]
Message-ID: <20110221144240.GB6428@redhat.com> (raw)
In-Reply-To: <20110221182419.3545cdbb@notabene.brown>

On Mon, Feb 21, 2011 at 06:24:19PM +1100, NeilBrown wrote:
> On Fri, 18 Feb 2011 10:04:29 -0500 Vivek Goyal <vgoyal@redhat.com> wrote:
> 
> > On Fri, Feb 18, 2011 at 02:33:25PM +1100, NeilBrown wrote:
> > > On Thu, 17 Feb 2011 22:19:52 -0500 Mike Snitzer <snitzer@redhat.com> wrote:
> 
> > > > Noticed an inconsistency, raid10.c's additional locking also protects
> > > > the bio_list_add() whereas raid1.c's doesn't.  Seems the additional
> > > > protection in raid10 isn't needed?
> > > 
> > > Correct - not needed at all.
> > > I put it there because it felt a little cleaner keeping the two 'lock's
> > > together like the two 'unlock's.  Probably confusing though...
> > 
> > I guess you could use blk_plug_device_unlocked() to get rid of ugliness
> > and this routine will take care of taking queue lock.
> > 
> 
> Yep, that gets rid of some ugliness.
> I've made that change and will submit it in due course.
> So blk_throtl doesn't need any change to avoid the problem with md - that
> changes are made in md instead.

Thanks Neil. I might still end up moving blk_throtl_exit() to
blk_cleanup_queue() once I have sorted out blk_sync_queue(). Because
at the end of blk_cleanup_queue() driver is free to release the spin
lock and there are no gurantees that in blk_release_queue() lock is 
still there.

Thanks
Vivek

  reply	other threads:[~2011-02-21 14:42 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-16  7:31 blk_throtl_exit taking q->queue_lock is problematic NeilBrown
2011-02-16 15:53 ` Vivek Goyal
2011-02-17  0:35   ` NeilBrown
2011-02-17  1:10     ` Vivek Goyal
2011-02-17  5:55       ` NeilBrown
2011-02-17 15:01         ` Vivek Goyal
2011-02-17 16:59         ` Vivek Goyal
2011-02-18  2:40           ` NeilBrown
2011-02-18  3:19             ` Mike Snitzer
2011-02-18  3:33               ` NeilBrown
2011-02-18 14:04                 ` Mike Snitzer
2011-02-18 15:04                 ` Vivek Goyal
2011-02-21  7:24                   ` NeilBrown
2011-02-21 14:42                     ` Vivek Goyal [this message]
2011-02-18 15:05             ` Vivek Goyal
2011-02-17 20:00 ` Vivek Goyal
2011-02-18  1:57   ` 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=20110221144240.GB6428@redhat.com \
    --to=vgoyal@redhat.com \
    --cc=jaxboe@fusionio.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=neilb@suse.de \
    --cc=snitzer@redhat.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).