Re: 2.6.0-mm2

From: Diego Calleja
Date: Mon Dec 29 2003 - 17:43:50 EST


El Mon, 29 Dec 2003 21:57:26 +0100 Felipe Alfaro Solana <felipe_alfaro@xxxxxxxxxxxxx> escribió:

> The same happens here. cdrecord is broken under -mm, but works fine with
> plain 2.6.0.



I'm seeing the same here:

open("/dev/cd-rw", O_RDWR|O_NONBLOCK) = -1 EROFS (Read-only file system)
write(2, "cdrecord.mmap: Read-only file sy"..., 89cdrecord.mmap: Read-only file system. Cannot open '/dev/cd-rw'. Cannot open SCSI driver.) = 89


Looking at the error path, it looks like it happens in cdrom.c:

cdrom_open() in line 747 -> cdrom_open_write() in line 708
-> cdrom_mrw_open_write() in line 680, where there's:

if (!di.erasable)
return 1;

which is where it fails. di isn't filled correctly by
cdrom_get_disc_info(cdi, &di)

ie: change the "if (!di.erasable) return 1;"
to "if (!di.erasable) return 0;" and it will work.

Jens Axboe is listed in the changelog so he may know what's the issue here.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/