From: Pat LaVarre <p.lavarre@ieee.org>
To: Jens Axboe <axboe@suse.de>
Cc: linux-scsi@vger.kernel.org
Subject: Re: [PATCH] fix cdrom mt rainier probe
Date: 14 Jul 2004 17:34:42 -0600 [thread overview]
Message-ID: <1089848082.3736.21.camel@patibmrh9> (raw)
In-Reply-To: <20040714054133.GI3055@suse.de>
Jens A:
> > --- linux-2.6.8-rc1/drivers/ide/ide-cd.c 2004-07-13 08:26:05.000000000 -0600
> > +++ linux-2.6.8-rc1-pel/drivers/ide/ide-cd.c 2004-07-13 14:33:40.000000000 -0600
> > @@ -3251,6 +3251,7 @@ int ide_cdrom_setup (ide_drive_t *drive)
> > * set correct block size and read-only for non-ram media
> > */
> > set_disk_ro(drive->disk, !CDROM_CONFIG_FLAGS(drive)->ram);
> > + set_disk_ro(drive->disk, 0);
>
> Trace that backwards and find out why ->ram isn't getting set.
An answer to that helpfully concrete question is:
2.6.8-rc1 differs from 2.6.7 by lacking the three-line patch below.
Back in the ide_cdrom_probe_capabilities of 2.6.7, we were saying any
drive that offered "feature" x0020 "Random Writable" was set_disk_ro
rewritable. Now in 2.6.8-rc1 we accept only:
cap.dvd_ram_write || (drive->media == ide_optical)
That criterion denies the rewritability of the drive I'm testing i.e.
the "Iomega" "RRD" drive.
I'd like Linux to perceive the reality that RRD discs are as rewritable
as DVD RAM discs are - can I help further?
Pat LaVarre
--- linux-2.6.8-rc1/drivers/ide/ide-cd.c 2004-07-13 08:26:05.000000000 -0600
+++ linux-2.6.8-rc1-pel/drivers/ide/ide-cd.c 2004-07-14 17:00:28.000000000 -0600
@@ -2925,7 +2925,7 @@ int ide_cdrom_probe_capabilities (ide_dr
struct cdrom_info *info = drive->driver_data;
struct cdrom_device_info *cdi = &info->devinfo;
struct atapi_capabilities_page cap;
- int nslots = 1;
+ int nslots = 1, ram_write = 0;
if (drive->media == ide_optical) {
CDROM_CONFIG_FLAGS(drive)->mo_drive = 1;
@@ -2954,6 +2954,10 @@ int ide_cdrom_probe_capabilities (ide_dr
if (ide_cdrom_get_capabilities(drive, &cap))
return 0;
+ if (!cdrom_is_random_writable(cdi, &ram_write))
+ if (ram_write)
+ CDROM_CONFIG_FLAGS(drive)->ram = 1;
+
if (cap.lock == 0)
CDROM_CONFIG_FLAGS(drive)->no_doorlock = 1;
if (cap.eject)
next prev parent reply other threads:[~2004-07-14 23:34 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1089741428.3806.3.camel@patibmrh9>
2004-07-13 20:55 ` [PATCH] fix cdrom mt rainier probe Pat LaVarre
2004-07-14 5:41 ` Jens Axboe
2004-07-14 23:34 ` Pat LaVarre [this message]
2004-07-16 0:39 ` Pat LaVarre
2004-07-16 12:25 ` Jens Axboe
2004-07-16 12:28 ` Jens Axboe
2004-07-16 15:58 ` Pat LaVarre
2004-07-16 16:02 ` Jens Axboe
2004-07-16 16:19 ` Pat LaVarre
2004-07-16 17:51 ` Jens Axboe
2004-07-18 0:43 ` Pat LaVarre
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=1089848082.3736.21.camel@patibmrh9 \
--to=p.lavarre@ieee.org \
--cc=axboe@suse.de \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox