Linux SCSI subsystem development
 help / color / mirror / Atom feed
From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: ltuikov@yahoo.com
Cc: Tony Battersby <tonyb@cybernetics.com>,
	"linux-scsi@vger.kernel.org" <linux-scsi@vger.kernel.org>,
	"Salyzyn, Mark" <Mark_Salyzyn@adaptec.com>
Subject: Re: [PATCH] [SCSI] sd: make error handling more robust (v2)
Date: Mon, 04 Feb 2008 15:22:08 -0600	[thread overview]
Message-ID: <1202160128.3096.118.camel@localhost.localdomain> (raw)
In-Reply-To: <228743.69246.qm@web31807.mail.mud.yahoo.com>

On Mon, 2008-02-04 at 01:11 -0800, Luben Tuikov wrote:
> Looks good except that "End LBA" is usually defined
> to be something of the sort of "the LBA of the last
> logical block accessed by the command" or "the LBA
> of the logical block on which the command failed".
> 
> A spec savvy editor of this code would be
> "pleasantly" surprised if they had to use "end_lba",
> and didn't pay attention that it was actually
> "End LBA" + 1.

Heh, well, that's where spec people and programmers part company.  The
universal expectation of a programmer in looping is

for (a = beginning; a < end; a++)

rather than <= if end were actually to point to last rather than last +
1.

James



  reply	other threads:[~2008-02-04 21:22 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-01 17:03 [PATCH] [SCSI] sd: make error handling more robust (v2) Tony Battersby
2008-02-01 20:13 ` Luben Tuikov
2008-02-01 20:47 ` Salyzyn, Mark
2008-02-02  0:43   ` Mike Snitzer
2008-02-02 20:24     ` Greg KH
2008-02-02 20:56       ` Mike Snitzer
2008-02-02 21:08         ` Greg KH
2008-02-02 22:06 ` James Bottomley
2008-02-03 15:14   ` Mike Snitzer
2008-02-04  9:14     ` Luben Tuikov
2008-02-06 21:54       ` [PATCH 1/1] aacraid: do not set valid bit in sense information Salyzyn, Mark
2008-02-06 22:19         ` Luben Tuikov
2008-02-04  9:11   ` [PATCH] [SCSI] sd: make error handling more robust (v2) Luben Tuikov
2008-02-04 21:22     ` James Bottomley [this message]
2008-02-04 23:23       ` Luben Tuikov

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=1202160128.3096.118.camel@localhost.localdomain \
    --to=james.bottomley@hansenpartnership.com \
    --cc=Mark_Salyzyn@adaptec.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=ltuikov@yahoo.com \
    --cc=tonyb@cybernetics.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