Messages in this thread Patch in this message | | | Date | Wed, 15 Aug 2001 13:17:33 +0200 | From | Jens Axboe <> | Subject | Re: 4.7GB DVD-RAM geometry wrong? |
| |
On Wed, Aug 15 2001, Joseph N. Hall wrote: > I don't know if I'm doing this the right way or not. I did spend an hour > or three googling for "linux dvd-ram" and the like, and all I came up with > was a bunch of 2.2-specific stuff, until I found a usenet posting that > said in effect "you can write to /dev/scd0". So I gave that a try > and it worked. Sort of. > > I have a Panasonic DVD-RAM, LF-D201 (SCSI 4.7/9.4GB). I put in a > 4.7GB type II cartridge (that's a single-sided disk), did 'mkfs > /dev/scd0' and then mounted it, and ... I have a 2.2GB disk!
Attached patch should fix it, Linus please apply.
-- Jens Axboe
--- /opt/kernel/linux-2.4.9-pre4/drivers/scsi/sr_ioctl.c Thu Jul 5 20:28:17 2001 +++ drivers/scsi/sr_ioctl.c Wed Aug 15 13:15:21 2001 @@ -545,7 +545,7 @@ switch (cmd) { case BLKGETSIZE: - return put_user(scsi_CDs[target].capacity >> 1, (long *) arg); + return put_user(scsi_CDs[target].capacity, (long *) arg); case BLKROSET: case BLKROGET: case BLKRASET: | |