public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: "Gérard Roudier" <groudier@free.fr>
To: Matthew Jacob <mjacob@feral.com>
Cc: Jeremy Higdon <jeremy@classic.engr.sgi.com>,
	Doug Ledford <dledford@redhat.com>,
	Martin Peschke3 <MPESCHKE@de.ibm.com>,
	Pete Zaitcev <zaitcev@redhat.com>,
	linux-scsi@vger.kernel.org
Subject: Re: [PATCH + RFC] Beginning of some updates to scsi mid layer
Date: Mon, 1 Jul 2002 23:02:24 +0200 (CEST)	[thread overview]
Message-ID: <20020701225037.E3271-100000@localhost.my.domain> (raw)
In-Reply-To: <Pine.BSF.4.21.0206281902170.16861-100000@beppo>



On Fri, 28 Jun 2002, Matthew Jacob wrote:

> FWIW, Bob Snively (on T10 commitee) has always claimed that the correct
> response to QUEUE FULL is immediate command resubmission (i.e., *don't* wait
> for a command to complete (the QFULL may have resulted from commands being
> processed for *another* initiator), and *don't* a period of time for things to
> 'get better').
>
> I'm not sure  agree with this 100%, but he might have a point.

My favorite retry handling algorithm looks like this:

1) Retry immediately,
2) If still fails, retry after some minimal delay T,
3) If still fails, retry after delay 2T,
4) If still fails, retry after delay 4T,
*) and so on ... until some maximum value for the delay.

Even with T being very short, you will never flood. OTOH, a transient
condition that lasts X will be recovered in not more than 2X.

BTW, it isn't implemented in the sym drivers, but I use to use such
algorithm when kind of blind retrying is to be implemented.

  Gérard.

> On Fri, 28 Jun 2002, Jeremy Higdon wrote:
>
> > On Jun 28,  3:39am, Doug Ledford wrote:
> > >
> > > On Fri, Jun 28, 2002 at 08:08:01AM +0200, Martin Peschke3 wrote:
> > > > as you describe below. This condition results in a starvation
> > > > of I/O for that particular device. The command which was rejected
> > > > with QUEUE_FULL is moved into the ml queue and never retried
> > > > since the mid layer only triggers a retry when another command for
> > > > that device returns. But there is no other command which
> > > > could return.
> > > > We think this needs to be fixed in the ml code (e.g. retry periodically
> > > > triggered by timer?). Our current workaround is to map QUEUE_FULL
> > >
> > > Yes, the answer to this problem involves a timer.  Basically what I
> > > suggest (and do in my driver) is set it so that the driver waits until
> > > either A) a command is completed or B) 10ms has passed before sending the
> > > command back out, whichever comes first.  Since most drives have had
> > > plenty of time to complete one or more commands in 10ms, we assume that
> > > even if we haven't got a completion yet that the drive likely has some
> > > freed up resources and so we try again.
> >
> >
> > Do you change the queue depth that you use based on a QUEUE_FULL, then?
> > If so, then I presume you have some minimum, such as two or four
> > commands . . . ?
> >
> > jeremy
> > -
> > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at  http://vger.kernel.org/majordomo-info.html
> >
>
> -
> To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2002-07-01 21:02 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-28  6:08 [PATCH + RFC] Beginning of some updates to scsi mid layer Martin Peschke3
2002-06-28  7:39 ` Doug Ledford
2002-06-29  1:19   ` Jeremy Higdon
2002-06-29  2:04     ` Matthew Jacob
2002-06-29 10:05       ` Doug Ledford
2002-06-29 10:37         ` Matthew Jacob
2002-07-01 21:02       ` Gérard Roudier [this message]
2002-07-01 19:08         ` Matthew Jacob
2002-07-01 19:15           ` Doug Ledford
2002-07-01 19:23             ` Matthew Jacob
2002-07-01 19:59               ` Doug Ledford
2002-07-01 20:17                 ` Matthew Jacob
2002-07-02 11:27             ` Rogier Wolff
2002-06-29 10:10     ` Doug Ledford
  -- strict thread matches above, loose matches on Subject: below --
2002-06-28  8:25 Martin Peschke3
2002-06-28 11:22 ` Doug Ledford
     [not found] <20020619014048.B8623@redhat.com>
2002-06-19 17:44 ` Pete Zaitcev
2002-06-19 17:55   ` Matthew Jacob
2002-06-19 18:25   ` Doug Ledford
2002-06-28  5:41     ` Jeremy Higdon
2002-06-28  7:37       ` Doug Ledford
2002-06-19  0:47 Doug Ledford
2002-06-19 21:15 ` Patrick Mansfield
2002-06-20 19:45   ` Doug Ledford

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=20020701225037.E3271-100000@localhost.my.domain \
    --to=groudier@free.fr \
    --cc=MPESCHKE@de.ibm.com \
    --cc=dledford@redhat.com \
    --cc=jeremy@classic.engr.sgi.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mjacob@feral.com \
    --cc=zaitcev@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