hal assumes that devices ending with a number are partitions on a block
device, which is not the case for SCSI CD-ROMs (i.e. it's not
/sys/block/sra/sra0, SCSI CD-ROMs are enumerated with numbers, not with letters
as ATAPI devices are). Thus is_partition becomes true.
if (is_partition) {
gchar *parent_path;
parent_path = hal_util_get_parent_path (hotplug_event->sysfs.sysfs_path);
sysfs.sysfs_path is /sys/block/sr0, thus parent_path is /sys/block, which is of
course not a device.
OK, I think I have an idea about what goes wrong now:
* The kernel creates /sys/block/sr0, which is the block device for the USB CD-ROM.
* ./hald/ linux2/ hotplug. c, around line 285:
is_partition = isdigit( hotplug_ event-> sysfs.sysfs_ path[len - 1]) || event-> sysfs.sysfs_ path, "/fakevolume") ;
strstr (hotplug_
hal assumes that devices ending with a number are partitions on a block sra/sra0, SCSI CD-ROMs are enumerated with numbers, not with letters
device, which is not the case for SCSI CD-ROMs (i.e. it's not
/sys/block/
as ATAPI devices are). Thus is_partition becomes true.
if (is_partition) { get_parent_ path (hotplug_ event-> sysfs.sysfs_ path);
gchar *parent_path;
parent_path = hal_util_
sysfs.sysfs_path is /sys/block/sr0, thus parent_path is /sys/block, which is of
course not a device.
parent = hal_device_ store_match_ key_value_ string (hald_get_gdl (),
"linux. sysfs_path_ device" , parent_path);
parent becomes NULL here, which is then directly passed to event_begin_ add_blockdev( ), which throws the event away.
hotplug_