Bugzilla – Bug 368234
usb-sotrage is not autoloaded on EFIKA PPC
Last modified: 2008-05-26 09:49:16 UTC
The kernel modul, usb-sotrage is not autoloaded on EFIKA PPC when an USB key or HDD is attached, which makes some extra steps necessary during installation when these are used as installation sources. If loaded with the 'insmod=usb-storage' boot argument, then it is loaded before the HDD controller, changing device order, so it is not a convenient workaround...
Still a problem in latest factory. USB storage devices are found, at least information is shown about them in kernel messages, still usb-storage is not loaded automatically. It is loaded on Pegasos PPC and also on x86 automagically. It is a problem only during installation (but there really annoying). Relevant parts from dmesg on an installed 'factory' from 2008-04-09: ohci_hcd: 2006 August 04 USB 1.1 'Open' Host Controller (OHCI) Driver ppc-of-ohci f0001000.usb: OF OHCI ppc-of-ohci f0001000.usb: new USB bus registered, assigned bus number 1 ppc-of-ohci f0001000.usb: irq 134, io mem 0xf0001000 usb usb1: configuration #1 chosen from 1 choice hub 1-0:1.0: USB hub found hub 1-0:1.0: 2 ports detected usb usb1: New USB device found, idVendor=1d6b, idProduct=0001 usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1 usb usb1: Product: OF OHCI usb usb1: Manufacturer: Linux 2.6.25-rc8-12-default ohci_hcd usb usb1: SerialNumber: PPC-OF USB [..] usb 1-1: new full speed USB device using ppc-of-ohci and address 2 usb 1-1: configuration #1 chosen from 1 choice hub 1-1:1.0: USB hub found hub 1-1:1.0: 4 ports detected usb 1-1: New USB device found, idVendor=05e3, idProduct=0608 usb 1-1: New USB device strings: Mfr=0, Product=1, SerialNumber=0 usb 1-1: Product: USB2.0 Hub usb 1-1.2: new full speed USB device using ppc-of-ohci and address 3 usb 1-1.2: configuration #1 chosen from 1 choice usb 1-1.2: New USB device found, idVendor=13fe, idProduct=1d00 usb 1-1.2: New USB device strings: Mfr=1, Product=2, SerialNumber=3 usb 1-1.2: Product: DataTraveler 2.0 usb 1-1.2: Manufacturer: Kingston usb 1-1.2: SerialNumber: 5B7110927C07 usb 1-1.3: new low speed USB device using ppc-of-ohci and address 4 usb 1-1.3: configuration #1 chosen from 1 choice usb 1-1.3: New USB device found, idVendor=04f2, idProduct=0116 usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=0 usb 1-1.3: Product: USB Keyboard usb 1-1.3: Manufacturer: CHICONY usbcore: registered new interface driver hiddev input: CHICONY USB Keyboard as /devices/f0000000.builtin/f0001000.usb/usb1/1-1/1-1.3/1-1.3:1.0/input/input1 input,hidraw0: USB HID v1.10 Keyboard [CHICONY USB Keyboard] on usb-PPC-OF USB-1.3 usbcore: registered new interface driver usbhid drivers/hid/usbhid/hid-core.c: v2.6:USB HID core driver [..] Initializing USB Mass Storage driver... scsi1 : SCSI emulation for USB Mass Storage devices usbcore: registered new interface driver usb-storage usb-storage: device found at 3 usb-storage: waiting for device to settle before scanning USB Mass Storage support registered. scsi 1:0:0:0: Direct-Access Kingston DataTraveler 2.0 PMAP PQ: 0 ANSI: 0 CCS sd 1:0:0:0: [sdb] 4030464 512-byte hardware sectors (2064 MB) sd 1:0:0:0: [sdb] Write Protect is off sd 1:0:0:0: [sdb] Mode Sense: 23 00 00 00 sd 1:0:0:0: [sdb] Assuming drive cache: write through sd 1:0:0:0: [sdb] 4030464 512-byte hardware sectors (2064 MB) sd 1:0:0:0: [sdb] Write Protect is off sd 1:0:0:0: [sdb] Mode Sense: 23 00 00 00 sd 1:0:0:0: [sdb] Assuming drive cache: write through sdb: sdb1 sd 1:0:0:0: [sdb] Attached SCSI removable disk sd 1:0:0:0: Attached scsi generic sg1 type 0 usb-storage: device scan complete
is it loaded when you boot with 'insmod=usb-storage', and is the usbdisk usable?
Yes, it loads, and it is usable. But in this case usb-storage is loaded first and HDD driver second, so it is not much useful to make an installation from, as device names are reversed (/dev/sda <-> /dev/sdb).
Steffen, and idea? hwinfo seems to list the device. inst-sys:/ # hwinfo --usb 04: USB 00.0: 10600 Disk [Created at usb.122] UDI: /org/freedesktop/Hal/devices/usb_device_324_bc06_AA04012700041653_if0 Unique ID: mQbf.1jgKp33wQcE Parent ID: u9LK.nUU7fp8MYPA SysFS ID: /devices/f0000000.builtin/f0001000.usb/usb1/1-2/1-2:1.0 SysFS BusID: 1-2:1.0 Hardware Class: disk Model: "OCZ RALLY2" Hotplug: USB Vendor: usb 0x0324 "OCZ Technology" Device: usb 0xbc06 "RALLY2" Revision: "11.00" Serial ID: "AA04012700041653" Speed: 12 Mbps Module Alias: "usb:v0324pBC06d1100dc00dsc00dp00ic08isc06ip50" Driver Info #0: Driver Status: usb_storage is not active Driver Activation Cmd: "modprobe usb_storage" Config Status: cfg=new, avail=yes, need=no, active=unknown Attached to: #5 (Hub) 05: USB 00.0: 10a00 Hub [Created at usb.122] UDI: /org/freedesktop/Hal/devices/usb_device_1d6b_1_PPC_OF_USB_if0 Unique ID: u9LK.nUU7fp8MYPA SysFS ID: /devices/f0000000.builtin/f0001000.usb/usb1/1-0:1.0 SysFS BusID: 1-0:1.0 Hardware Class: hub Model: "Linux 2.6.25-rc9-17-default ohci_hcd OF OHCI" Hotplug: USB Vendor: usb 0x1d6b "Linux 2.6.25-rc9-17-default ohci_hcd" Device: usb 0x0001 "OF OHCI" Revision: "2.06" Serial ID: "PPC-OF USB" Driver: "hub" Driver Modules: "usbcore" Speed: 12 Mbps Module Alias: "usb:v1D6Bp0001d0206dc09dsc00dp00ic09isc00ip00" Config Status: cfg=new, avail=yes, need=no, active=unknown inst-sys:/ #
Created attachment 210216 [details] efika-usbstorage.txt
Does 'hwinfo --usb-ctrl' list something?
no, it does not list anything. I think the platform detection is not working correctly in hwinfo.
==> /sys/devices/f0000000.builtin/f0001000.usb/modalias <== of:NusbTusbCohci-bigendianCohci-beCmpc5200-ohciCmpc5200-usb 07: None 00.0: 0c00 FireWire (IEEE 1394) (Generic) [Created at pci.910] Unique ID: pCPP._bvMLZrF7W9 SysFS ID: /devices/f0000000.builtin/f0001000.usb SysFS BusID: f0001000.usb Hardware Class: firewire controller Model: "Freescale mpc5200 USB 0" Vendor: pci 0x1957 "Freescale Semiconductor Inc" Device: "mpc5200 USB 0" Driver: "ppc-of-ohci" Module Alias: "of:NusbTusbCohci-bigendianCohci-beCmpc5200-ohciCmpc5200-usb" Config Status: cfg=new, avail=yes, need=no, active=unknown 'hd->base_class.id = bc_serial;' is not the correct class, in src/hd/pci.c:hd_read_of_platform()
--firewire and --sound prints also nothing. What needs to be changed in hd_read_of_platform?
Class 0x0c is correct, but usb is subclass 3 (1394 is subclass 0). Also, uhci/ohci/ehci is prog_if.id = 0/0x10/0x20. I can't comment on --firewire, --sound; I'd have to see the entries you want to get listed.
Tested beta3, usb-storage is still not loaded...
I get this with the patch below: 06: None 00.0: 0c03 USB Controller (OHCI) [Created at pci.923] UDI: /org/freedesktop/Hal/devices/of_platform_f0001000_usb Unique ID: pCPP.fKBMAaVBljB SysFS ID: /devices/f0000000.builtin/f0001000.usb SysFS BusID: f0001000.usb Hardware Class: usb controller Model: "Freescale mpc5200 USB 0" Vendor: pci 0x1957 "Freescale Semiconductor Inc" Device: "mpc5200 USB 0" Driver: "ppc-of-ohci" Module Alias: "of:NusbTusbCohci-bigendianCohci-beCmpc5200-ohciCmpc5200-usb" Driver Info #0: Driver Status: ohci-hcd is not active Driver Activation Cmd: "modprobe ohci-hcd" Config Status: cfg=new, avail=yes, need=no, active=unknown --- a/src/hd/pci.c +++ b/src/hd/pci.c @@ -924,6 +924,8 @@ void hd_read_of_platform(hd_data_t *hd_d hd->vendor.id = MAKE_ID(TAG_PCI, 0x1957); /* Freescale */ hd->base_class.id = bc_serial; + hd->sub_class.id = sc_ser_usb; + hd->prog_if.id = pif_usb_ohci; str_printf(&hd->device.name, 0, "mpc5200 USB %d", hd->slot); hd->modalias = new_str(modalias);
Steffen, any chance to get this patch into hwinfo before release?
ok, patch added