From: Jens Axboe <jens.axboe@oracle.com>
To: Douglas Gilbert <dougg@torque.net>
Cc: James Bottomley <James.Bottomley@SteelEye.com>,
linux-scsi@vger.kernel.org
Subject: Re: [PATCH] scsi_debug: illegal blocking memory allocation
Date: Fri, 5 Jan 2007 13:49:18 +0100 [thread overview]
Message-ID: <20070105124918.GD11203@kernel.dk> (raw)
In-Reply-To: <459DE265.7030100@torque.net>
On Fri, Jan 05 2007, Douglas Gilbert wrote:
> Jens Axboe wrote:
> > On Thu, Jan 04 2007, James Bottomley wrote:
> >> On Thu, 2007-01-04 at 12:21 +0100, Jens Axboe wrote:
> >>> I guess it's fully up to you how you want to solve it. The scheme seems
> >>> a little elaborate, but these error conditions are unlikely to ever been
> >>> seen in the wild, so no objections from me.
> >> Actually, there's already a DID_ code that does what you want. Instead
> >> of DID_ERROR, which will retry immediately, there's DID_REQUEUE which
> >> will halt the device queue and wait for a returning command to retry.
> >
> > As long as it keeps firing the queue at some intervals even without any
> > commands pending at all, then that'll work just fine. I like that
> > approach a lot better than coding the error into some sense value that
> > is (at best) some vague approximation of what has happened (calling
> > memory shortage a transport error is a bit of a stretch).
>
> True, but both happen. The scsi_debug driver is a
> virtual host, virtual target and a lu (ram disk).
> The failure that you pointed out stopped a response
> being built. In the real world that would in the
> target or lu.
The point is that the condition need not be exposed, even if it could be
compared to (say) a device busy condition. Both should just results in a
requeue and later retry, when resources are available to satisfy the
request.
Your revised patch looks good to me!
--
Jens Axboe
prev parent reply other threads:[~2007-01-05 12:48 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-03 13:49 [PATCH] scsi_debug: illegal blocking memory allocation Jens Axboe
2007-01-04 5:38 ` Douglas Gilbert
2007-01-04 11:21 ` Jens Axboe
2007-01-04 15:10 ` James Bottomley
2007-01-04 15:27 ` Matthew Wilcox
2007-01-04 15:34 ` James Bottomley
2007-01-04 15:50 ` Jens Axboe
2007-01-05 5:30 ` Douglas Gilbert
2007-01-05 12:49 ` Jens Axboe [this message]
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=20070105124918.GD11203@kernel.dk \
--to=jens.axboe@oracle.com \
--cc=James.Bottomley@SteelEye.com \
--cc=dougg@torque.net \
--cc=linux-scsi@vger.kernel.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