From: Pat LaVarre <p.lavarre@ieee.org>
To: linux-scsi@vger.kernel.org
Subject: Re: [PATCH] CDC_WR_OVER
Date: 18 Nov 2003 17:00:02 -0700 [thread overview]
Message-ID: <1069200002.2912.8.camel@patrh9> (raw)
In-Reply-To: <1068851585.2851.17.camel@patrh9>
> we can begin to move forward now by accepting or
> revising the patch of this e-mail?
As yet revising, Not accepting.
In fact somehow we have moved this profile/ features/ writability patch
of too many names from sr_mod.ko into cdrom.ko without actually
achieving writability for devices other than DVD-RAM connected via
ide-cd.ko.
> - if (ide_cdrom_get_capabilities(drive, &cap))
> + if (ide_cdrom_get_capabilities(drive, &cap)) {
> + ; /* FIXME: mask CDC_WR */
> return 0;
> + }
>
> if (cap.lock == 0)
> CDROM_CONFIG_FLAGS(drive)->no_doorlock = 1;
> @@ -3211,6 +3214,7 @@
>
> nslots = ide_cdrom_probe_capabilities (drive);
>
> + ; /* FIXME: also not ro if CDC_WR */
> if (CDROM_CONFIG_FLAGS(drive)->dvd_ram)
> set_disk_ro(drive->disk, 0);
Possibly some of those conjectured ide-cd FIXME are necessary.
Now substituting ATAPI for USB, even with the patch applied to
2.6.0-test9, still we see:
$ sudo sg_scan -i
/dev/sg0: scsi0 channel=0 id=0 lun=0 [em] type=5
Iomega RRD 40.D [wide=0 sync=0 cmdq=0 sftre=0 pq=0x0]
$
$ sudo sg_dd of=/dev/sg0 if=/dev/zero bs=2k count=1
1+0 records in
1+0 records out
$
$ sudo sg_inq /dev/hdd | egrep 'id'
Vendor identification: Iomega
Product identification: RRD
$
$ sudo dd of=/dev/hdd if=/dev/zero bs=2k count=1
dd: writing `/dev/hdd': Operation not permitted
1+0 records in
0+0 records out
$
$ grep -i permitted /usr/include/asm/errno.h
#define EPERM 1 /* Operation not permitted */
$ grep EPERM drivers/ide/ide-cd.c
$ grep EPERM drivers/cdrom/cdrom.c
$
Pat LaVarre
next prev parent reply other threads:[~2003-11-19 0:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-14 23:13 [PATCH] CDC_WR_OVER Pat LaVarre
2003-11-19 0:00 ` Pat LaVarre [this message]
2003-11-21 21:18 ` 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=1069200002.2912.8.camel@patrh9 \
--to=p.lavarre@ieee.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox