From: Jens Axboe <axboe@suse.de>
To: Linus Torvalds <torvalds@osdl.org>
Cc: Andreas Jellinghaus <aj@dungeon.inka.de>, linux-kernel@vger.kernel.org
Subject: Re: ide cdrom sg like access / rpcmgr ?
Date: Wed, 12 Nov 2003 18:32:01 +0100 [thread overview]
Message-ID: <20031112173201.GP21141@suse.de> (raw)
In-Reply-To: <Pine.LNX.4.44.0311120829060.3288-100000@home.osdl.org>
On Wed, Nov 12 2003, Linus Torvalds wrote:
>
> On Wed, 12 Nov 2003, Jens Axboe wrote:
> >
> > To make the below work, all you probably need to do is change sgio() to
> > use CDROM_SEND_PACKET for instance. That'll work in 2.4 and 2.6. You
> > just need to fill a cdrom_generic_command and send it to the cdrom fd.
>
> Don't forget: you also need to open the device with "O_NONBLOCK", so as to
> not make the kernel try to figure out the media etc. Otherwise you can't
> do anything with media that the kernel can't figure out (ie empty media
> that hasn't been written to, or even no media at all).
>
> Depending on what your tool is for, this may or may not be a problem, of
> course. If you only want to send commands to a drive that already has a
> readable media in it, you can skip the O_NONBLOCK.
Yes of course, you are absolutely right.
--
Jens Axboe
prev parent reply other threads:[~2003-11-12 17:32 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-10 20:04 ide cdrom sg like access / rpcmgr ? Andreas Jellinghaus
2003-11-12 11:36 ` Jens Axboe
2003-11-12 12:39 ` Andreas Jellinghaus
2003-11-12 14:31 ` Jens Axboe
2003-11-12 16:33 ` Linus Torvalds
2003-11-12 17:32 ` 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=20031112173201.GP21141@suse.de \
--to=axboe@suse.de \
--cc=aj@dungeon.inka.de \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@osdl.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