[7997] in linux-scsi channel archive
Re: Devices not supporting read-6....
daemon@ATHENA.MIT.EDU (Rogier Wolff)
Thu Feb 3 04:07:54 2000
Message-Id: <200002030851.JAA13451@cave.bitwizard.nl>
In-Reply-To: <004c01bf6dfc$8f2cd750$0f17a8c0@eric.home> from Eric Youngdale at
"Feb 2, 2000 11:10:08 pm"
To: Eric Youngdale <eric@andante.org>
Date: Thu, 3 Feb 2000 09:51:27 +0100 (MET)
Cc: Drew Eckhardt <drew@Poohsticks.Org>,
Rogier Wolff <R.E.Wolff@BitWizard.nl>,
"Kenneth D. Merry" <ken@kdm.org>,
Jonas Nickel <jonas.nickel@tu-berlin.de>,
linux-kernel@vger.rutgers.edu, linux-scsi@vger.rutgers.edu,
phoenix@thesindicate.com
From: R.E.Wolff@BitWizard.nl (Rogier Wolff)
MIME-Version: 1.0
Content-Type: text/plain; charset=US-ASCII
Content-Transfer-Encoding: 7bit
Eric Youngdale wrote:
> Is this what that ghost stuff is really for? There is a much easier
> way of doing this, you know. There is no technical reason why the
> same Scsi_Device cannot be driven by both drivers - the only thing
> you would need to do is to teach sd.c that it should also attach to
> DVD RAM drives.
Which is what the ghost stuff does, maybe not in the cleanest way, but
that is still the only thing that it does.
> If I had to guess, all you would need to do is to fix it so that
> scsi_scan() first marked the Scsi_Device as writable, and then a
> couple of minor edits to sd.c so that it treats the combination of
> TYPE_ROM with the writable flag set as equivalent to TYPE_MOD.
The end result is exactly the same as what the ghost stuff does now.
The common code between sd and sr is "read a block". This is code that
should be shared. Moreover, that's about the only "real" thing that
should be in those drivers. Of course "sr" also supports a few ioctls,
and "sd" also does writing.
Roger.
--
** R.E.Wolff@BitWizard.nl ** http://www.BitWizard.nl/ ** +31-15-2137555 **
*-- BitWizard writes Linux device drivers for any device you may have! --*
"I didn't say it was your fault. I said I was going to blame it on you."
-
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@vger.rutgers.edu