From: James Bottomley <James.Bottomley@suse.de>
To: Bart Van Assche <bvanassche@acm.org>
Cc: Andi Kleen <ak@linux.intel.com>, Joe Eykholt <jeykholt@cisco.com>,
Tim Chen <tim.c.chen@linux.intel.com>,
Eric Moore <Eric.Moore@lsi.com>,
linux-scsi@vger.kernel.org, vasu.dev@intel.com,
willy@linux.intel.com
Subject: Re: [PATCH] scsi, mptsas : drop scsi_host lock when calling mptsas_qcmd
Date: Fri, 17 Sep 2010 08:19:46 -0400 [thread overview]
Message-ID: <1284725986.26423.64.camel@mulgrave.site> (raw)
In-Reply-To: <AANLkTikDSbzqJHLToz9L7VhOtifzUANomYBBbbbEHBwt@mail.gmail.com>
On Fri, 2010-09-17 at 12:32 +0200, Bart Van Assche wrote:
> On Fri, Sep 17, 2010 at 9:16 AM, Andi Kleen <ak@linux.intel.com> wrote:
> >
> > > Not really ... look at the code path (in scsi.c:scsi_dispatch_cmd()).
> > > We take the lock, then get the serial number (that would likley have to
> > > be replaced with an atomic), check the state, call trace, call
> >
> > An atomic unfortunately usually doesn't scale much better than a spinlock.
> > I suspect serials would need to be made optional, e.g.
> > computing them lazily if really needed.
>
> We should be careful that the command processing order for commands
> issued by different threads is not altered by removing the host lock,
> at least for those SCSI commands where in-order processing matters.
> There might be better solutions than a serial number though.
We don't actually make any ordering guarantees at the top of the stack.
The block layer originally did need internal ordering guarantees for
barriers, but they were automatically preserved by the fact that the
exit from the ioscheduler is single threaded.
However, the barrier redo means that we no longer even need the single
threaded guarantee ... and I suspect Jens is already thinking about
multi threading the ioscheduler exit, which is also another good reason
for reducing the locking footprint.
James
next prev parent reply other threads:[~2010-09-17 12:19 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-16 19:44 [PATCH] scsi, mptsas : drop scsi_host lock when calling mptsas_qcmd Tim Chen
2010-09-16 20:48 ` Nicholas A. Bellinger
2010-09-16 21:18 ` Tim Chen
2010-09-16 21:25 ` Andi Kleen
2010-09-16 21:24 ` James Bottomley
2010-09-16 23:25 ` Christoph Hellwig
2010-09-17 0:13 ` Nicholas A. Bellinger
2010-09-17 1:12 ` Vasu Dev
2010-09-16 21:34 ` Nicholas A. Bellinger
2010-09-16 21:44 ` Nicholas A. Bellinger
2010-09-16 21:48 ` Nicholas A. Bellinger
2010-09-16 22:00 ` Joe Eykholt
2010-09-16 22:16 ` James Bottomley
2010-09-17 7:16 ` Andi Kleen
2010-09-17 10:32 ` Bart Van Assche
2010-09-17 12:19 ` James Bottomley [this message]
2010-09-16 22:26 ` Tim Chen
2010-09-16 21:31 ` Vasu Dev
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=1284725986.26423.64.camel@mulgrave.site \
--to=james.bottomley@suse.de \
--cc=Eric.Moore@lsi.com \
--cc=ak@linux.intel.com \
--cc=bvanassche@acm.org \
--cc=jeykholt@cisco.com \
--cc=linux-scsi@vger.kernel.org \
--cc=tim.c.chen@linux.intel.com \
--cc=vasu.dev@intel.com \
--cc=willy@linux.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