On 4/17/20 10:51 AM, Romain Dolbeau wrote: > Le ven. 17 avr. 2020 à 10:37, John Paul Adrian Glaubitz > <glaub...@physik.fu-berlin.de> a écrit : >> I have come up with this patch, can you test it on the mac-support branch? > > No cigars: > > dolbeau@powermacg5:~/powerpc-utils$ sudo ./scripts/ofpathname sda > /ht@0,f2000000/pci@9/k2-sata-root@c/@0 > > The first added line on your patch compares the variable 'fc' to > 'sata', but if I echo $fc, it actually contains 'k2-sata-root' on my > system - so plug_id is never set (confirmed by looking at the output > of bash -x). > > If I compare to 'k2-sata-root' instead, plug_id stays empty for the > first two times it's set, then the last one fallback to -1, naturally. > > Looking at the setting of plug_id, it's looking for some 'host' in two > places where I don't have any (for sda): > > ls: cannot access > '/sys/devices/pci0001:00/0001:00:09.0/0001:03:0c.0/ata2/host1/target1:0:0/1:0:0:0/*/host*': > No such file or directory > ls: cannot access > '/sys/devices/pci0001:00/0001:00:09.0/0001:03:0c.0/ata2/host1/target1:0:0/1:0:0:0/host*': > No such file or directory > > It's only the final 'host*' part that is missing, the directory itself exists: > > dolbeau@powermacg5:~/powerpc-utils$ ls > /sys/devices/pci0001:00/0001:00:09.0/0001:03:0c.0/ata2/host1/target1:0:0/1:0:0:0/ > blacklist eh_timeout inquiry > power scsi_level vpd_pg80 > block evt_capacity_change_reported iocounterbits > queue_depth state vpd_pg83 > bsg evt_inquiry_change_reported iodone_cnt > queue_type subsystem wwid > delete evt_lun_change_reported ioerr_cnt > rescan timeout > device_blocked evt_media_change iorequest_cnt > rev type > device_busy evt_mode_parameter_change_reported modalias > scsi_device uevent > dh_state evt_soft_threshold_reached model > scsi_disk unload_heads > driver generic ncq_prio_enable > scsi_generic vendor
Well, I don't have access to a G5 because no one grants me access to one so I have to write this code blind-folded. Guess, I'll have to wait then until someone has mercy and grants me access or they'll send me a patch themselves. Continuing this way is not efficient. Adrian -- .''`. John Paul Adrian Glaubitz : :' : Debian Developer - glaub...@debian.org `. `' Freie Universitaet Berlin - glaub...@physik.fu-berlin.de `- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913