public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@suse.de>
To: Douglas Gilbert <dougg@torque.net>
Cc: Pat LaVarre <p.lavarre@ieee.org>, linux-scsi@vger.kernel.org
Subject: Re: sense visible despite ide-floppy in 2.6 maybe
Date: Sun, 13 Jun 2004 22:00:48 +0200	[thread overview]
Message-ID: <20040613200048.GB2566@suse.de> (raw)
In-Reply-To: <40C8FB79.1050706@torque.net>

On Fri, Jun 11 2004, Douglas Gilbert wrote:
> Pat LaVarre wrote:
> >Doug G:
> >
> >Did I do something wrong, or does "everyone know" already,
> >
> >SCSI pass thru in 2.6 omits ide-floppy, except if we do resort to the
> >ide-scsi deprecated there?
> 
> Pat,
> In lk 2.6 the ide-scsi driver is "deprecated" for cd/dvd device types
> but not other device types that use the ATAPI protocol. The ide-scsi

Direct-device is still clearly superior. ide-scsi is deprecated for any
ATAPI type device using SG_IO, other uses may vary.

> Anyway ide-scsi probably needs some repair work in lk 2.6. Both
> Willem Riede and I have tried. IMO the ide-scsi driver looks ok
> from the scsi subsystem side ....

Should work since months.

> >Or more specifically,
> >
> >Can ioctl SG_IO fetch the offset 7 Additional Length field of op x03
> >"REQUEST SENSE" data?
> >
> >Naively I thought yes of course, I know that works with /dev/scd$n.
> >
> >But then I tried a /dev/hd$v ide-floppy.  No joy.  perror tells me ioctl
> >SG_IO fails via "Invalid argument", dmesg has no comment.  sg_scan you
> >know.  ~/bin/sgio source is the trivial exercise quoted in source far
> >below, specifically with an O_NONBLOCK|O_RDWR open as you can see.
> 
> My method with the SG_IO ioctl was to yield errnos
> if the SCSI command could not be sent (or was rejected
> at the point of transmission). So if there is an errno
> there will be no sense buffer (or any other valid
> response data). It is only when a response to the SCSI
> command is received that errno will be clear (and the
> various status variables should be checked).

The issue here is that ide-floppy doesn't grok REQ_BLOCK_PC requests
correctly, so when SG_IO generates them they are failed.

-- 
Jens Axboe


  parent reply	other threads:[~2004-06-13 20:00 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-06-08 15:53 sense visible despite ide-floppy in 2.6 maybe Pat LaVarre
2004-06-09  8:00 ` Jens Axboe
2004-06-09  8:20   ` Jens Axboe
2004-06-09 16:22     ` Pat LaVarre
2004-06-09 17:37       ` Jens Axboe
2004-06-09 18:29       ` Pat LaVarre
2004-06-09 18:51         ` Pat LaVarre
2004-06-09 23:30           ` Pat LaVarre
2004-06-11  9:30             ` Jens Axboe
2004-06-11  9:38               ` Jens Axboe
2004-06-13 18:48                 ` Pat LaVarre
2004-06-13 19:58                   ` Jens Axboe
2004-06-11  9:24           ` Jens Axboe
2004-06-11  9:24         ` Jens Axboe
2004-06-11  0:23 ` Douglas Gilbert
2004-06-11  2:08   ` Willem Riede
2004-06-13 18:21   ` Pat LaVarre
2004-06-13 19:06   ` Pat LaVarre
2004-06-14  6:39     ` Douglas Gilbert
2004-06-13 20:00   ` Jens Axboe [this message]
2004-06-17 19:03     ` Pat LaVarre
2004-06-17 19:12       ` Jens Axboe

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=20040613200048.GB2566@suse.de \
    --to=axboe@suse.de \
    --cc=dougg@torque.net \
    --cc=linux-scsi@vger.kernel.org \
    --cc=p.lavarre@ieee.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