Messages in this thread Patch in this message | | | Date | Tue, 30 Nov 2004 18:29:28 +0000 | From | "J.A. Magallon" <> | Subject | Re: cdrecord dev=ATA cannont scanbus as non-root |
| |
On 2004.11.30, Jan Engelhardt wrote: > >Err, as it tries to open a device and it does not exist. > >I tries sequentially > >hda, hdb, hdc.. up to 256 until it finds something to open. > >If it exists, but has not permissions, it keeps trying on the next. > >But if it is not present, cdrecord gives up. > > Reasonable procedure. Albeit, leaky: > Imagine you use devfs... open()ing something like hd* would probably always > create a node. Although there is a max on possible, meaningful, nodes, > someone could use this to fill up /dev with > ridiculuous amounts of nodes, all of which are to my knowledge in kernel space. > "Well then, goodbye". > > Luckily, even the very default config does not create arbitrarily nodes, and > cdrecord doesnot probe arbitr. devices. > > So I guess, yes, cdrecord should probe harder. Preferably by looking into /sys > when using a 2.6 system. >
Patch for cdrecord:
--- cdrtools-2.01/libscg/scsi-linux-ata.c.orig 2004-11-30 19:02:37.929176615 +0100 +++ cdrtools-2.01/libscg/scsi-linux-ata.c 2004-11-30 19:06:11.316213702 +0100 @@ -385,8 +385,6 @@ device, f, errno); } return (-2); - } else if (errno == ENOENT || errno == ENODEV) { - break; } } else { /* ugly hack, make better, when you can. Alex */ -- J.A. Magallon <jamagallon()able!es> \ Software is like sex: werewolf!able!es \ It's better when it's free Mandrakelinux release 10.2 (Cooker) for i586 Linux 2.6.10-rc2-jam3 (gcc 3.4.1 (Mandrakelinux 10.1 3.4.1-4mdk)) #1
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |