public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Cc: jens.axboe@oracle.com, bharrosh@panasas.com, dougg@torque.net,
	linux-scsi@vger.kernel.org, osd-dev@open-osd.org
Subject: Re: [PATCH] bsg: Add support for submitting requests at tail of queue
Date: Thu, 22 Jan 2009 16:27:59 -0600	[thread overview]
Message-ID: <1232663279.27348.6.camel@localhost.localdomain> (raw)
In-Reply-To: <20090123070237B.fujita.tomonori@lab.ntt.co.jp>

On Fri, 2009-01-23 at 07:03 +0900, FUJITA Tomonori wrote: 
> So, Boaz, what do you want to do exactly? It should have in the patch
> description. I don't want to add something that nobody uses.

OK, can we step back a bit from this?  Everyone seems to be talking past
each other.  The original complaint was that multiple commands against
the same device issued by SG_IO could be executed "out of order".  This
is really irrelevant because we never guarantee execution order in the
first place.

However, if you consider our current at head insertion policy coupled
with a multi-threaded application issuing hundreds of SG_IO requests at
once, you can see we have a potential starvation issue:  Commands at the
tail of the queue end up pushed further and further back as more
commands are added to the head.  This starvation issue is worth
addressing, I think, and it can only be addressed by allowing tail
insertion.

The original reason for at head is, as you surmise, inherited from sg
and the rationale is largely for error handling:  you need error
handling commands to pre-empt everything in the current queue.

James





  reply	other threads:[~2009-01-22 22:28 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-21  9:52 [PATCH] bsg: Add support for submitting requests at tail of queue Boaz Harrosh
2009-01-21 23:24 ` FUJITA Tomonori
2009-01-22  8:57   ` Boaz Harrosh
2009-01-22 11:13   ` Jens Axboe
2009-01-22 12:44     ` Boaz Harrosh
2009-01-22 12:46       ` Jens Axboe
2009-01-22 22:03         ` FUJITA Tomonori
2009-01-22 22:27           ` James Bottomley [this message]
2009-01-23  6:14             ` FUJITA Tomonori
2009-01-25  9:17               ` Boaz Harrosh
2009-01-25  9:41 ` [PATCH version2] " Boaz Harrosh
2009-01-25  9:44   ` Boaz Harrosh
2009-01-25 10:07 ` [PATCH version 3] " Boaz Harrosh

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=1232663279.27348.6.camel@localhost.localdomain \
    --to=james.bottomley@hansenpartnership.com \
    --cc=bharrosh@panasas.com \
    --cc=dougg@torque.net \
    --cc=fujita.tomonori@lab.ntt.co.jp \
    --cc=jens.axboe@oracle.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=osd-dev@open-osd.org \
    /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