From: Douglas Gilbert <dougg@torque.net>
To: linux-kernel@vger.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: [RFC] remove IDESCSI_SG_TRANSFORM (compile fix)
Date: Tue, 03 Dec 2002 19:13:06 +1100 [thread overview]
Message-ID: <3DEC6792.3060509@torque.net> (raw)
In-Reply-To: 3DEC5B4C.4040208@torque.net
Douglas Gilbert wrote:
> On Mon, 2002-12-02 at 17:21, Christoph Hellwig wrote:
> > On Fri, Nov 29, 2002 at 04:44:35PM -0800, Mike Anderson wrote:
> > > Thanks for catching this Christoph I thought the only use was inside
> > > SCSI. I could make a patch to scsi-misc to add tag back in. Another
> > > option if it is still needed is to switch to "->name == "generic").
> > >
> > > Though I have not used this interface I thought if one was using
> > > an sg
> > > device to a ide-scsi device and the flag was set that sg
> > > commands that
> > > where not 100% the same as ATAP commands where translated.
> >
> > Well, imho IDESCSI_SG_TRANSFORM is broken in 2.5. Now that ever block
> > driver implements the sg ioctls a sg request can come from sd or sr
> > aswell.
>
> Christoph,
> Thanks for alerting me to the implementation (by Jens) of
> the sg driver's SG_IO ioctl in drivers/block/scsi_ioctl.c .
>
> It goes by the name SCSI_IOCTL_SEND_COMMAND which is the same
> name as the old ioctl defined in drivers/scsi/scsi_ioctl.c .
> As far as I can see if you send that ioctl to a block device
> (including an ATA disk) you get the new functionality (i.e.
> similar to sg's SG_IO). However if you send that ioctl to
> a char device (e.g. st, osst or sg) you get the old
> interface (i.e. as found in drivers/scsi/scsi_ioctl.c).
> Somewhat confusing.
> So old utilities like scsiinfo will now fail for disks
> but continue to work for tapes.
Correcting my previous post ...
On reviewing drivers/block/scsi_ioctl.c it supports both
the SG_IO (i.e. equivalent to the sg driver's SG_IO ioctl)
and the SCSI_IOCTL_SEND_COMMAND ioctl with the old
functionality. So the SCSI_IOCTL_SEND_COMMAND ioctl is
consistent for both block and char (scsi) drivers.
The SG_IO ioctl first appeared in the lk 2.4 series
(2.4.0) while the SCSI_IOCTL_SEND_COMMAND ioctl has
been there for a long time (but has been marked as
deprecated in the source for some time).
Doug Gilbert
next prev parent reply other threads:[~2002-12-03 8:13 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-12-03 7:20 [RFC] remove IDESCSI_SG_TRANSFORM (compile fix) Douglas Gilbert
2002-12-03 8:13 ` Douglas Gilbert [this message]
-- strict thread matches above, loose matches on Subject: below --
2002-11-29 22:53 Christoph Hellwig
2002-11-30 0:44 ` Mike Anderson
2002-12-02 17:21 ` Christoph Hellwig
2002-12-02 22:22 ` Alan Cox
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=3DEC6792.3060509@torque.net \
--to=dougg@torque.net \
--cc=linux-kernel@vger.kernel.org \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.