Hello,
We upgraded from BSP 2.8 downstream kernel to BSP mainline kernel and are facing issues with a connected USB3 device. This device is a SDR (Ettus B205) which has a Cypress FX3 chip. I can see the device with “lsusb” but downloading the firmware fails when the Cypress chip re-enumerates itself as USB3 device. I have attached the dmesg logfile for better insight. When i execute “lsusb -v” various error messages appear like:
can't get device qualifier: Resource temporarily unavailable
can't get debug descriptor: Resource temporarily unavailable
I have also attached the lsusb output. When i download the firmware the following output is added to dmesg:
[ 411.906011] usb 4-1: USB disconnect, device number 2
[ 412.270233] usb 5-2: new SuperSpeed Gen 1 USB device number 2 using tegra-xusb
[ 412.300898] usb 5-2: LPM exit latency is zeroed, disabling LPM.
It seems to me that the download process triggered the device to reenumerate itself as superspeed device but however the process fails with:
[INFO] [UHD] linux; GNU C++ version 8.2.0; Boost_106800; UHD_4.0.0.0-release
[INFO] [B200] Loading firmware image: /usr/share/uhd/images/usrp_b200_fw.hex...
[ERROR] [UHD] Device discovery error: EnvironmentError: IOError: Could not load firmware:
EnvironmentError: IOError: ihex_reader::read(): record hander returned failure code
Error: LookupError: KeyError: No devices found for ----->
Empty Device Address
The strange thing is that the whole download process succeeds every once in a while. In that case no error messages can be found in “lsusb .v”. Any help on that would be much appreciated.
Thank you for using the Toradex Community as well as for providing all the information.
We are currently looking at your issue.
Do you observe this behavior only with the Ettus B205 device or is any USB-device affected by this?
The strange thing is that the whole download process succeeds every once in a while. In that case no error messages can be found in
“lsusb .v”. Any help on that would be much appreciated.
If it succeeds, do you encounter any issues or strange behavior?
Hello @kevin.tx
Thanks for your response. USB3 pen drives are working fine. I do not think that we have other USB3 devices at the moment. We tested some other TK1 modules and Ixora carrier boards in various combinations but the result stays the same - most of the time its not working. I assumed that this issue might be related to the LPM so i disabled the usbcore.autosuspend (-1). This change had not effect as well as enabling the performance mode. Sometimes its working after reboot and in this case no strange behavior can be seen (transfer perfomance is excellent). BR
analyzing your dmesg log. I can’t see any errors or other messages.
It looks a lot like the enumeration process might take longer than expected by the software.
I see that you are using the Mainline kernel 5.4, would it be possible for you to test it with kernel version 3.10 and let us know about the progress?
Hi @kevin.tx ,
Well, it seems that the downstream kernel 3.10 is perfoming much better. So far no issues there. We need the mainline kernel because of various advanced drivers, like for wifi an bt cards.
I hope you are not dependant on any functionality which may not be there in mainline like e.g. LVDS displays and/or hardware accelerated multimedia.
Anyway, concerning the USB issue it would be interesting to know whether or not it works with later mainline (e.g. directly from kernel.org). Is this something you are comfortable testing or would you need further assistance in this?
We are not dependant on LVDS and multimedia but USB is crucial. How would i change the kernel recipe to the most recent kernel version within my oe-core environment? We always want to stick with one of Toradex LTS BSP versions because of support issues.
You should first try to install the Bsp 3.0b4 mainline machine or Bsp 5.0 and then just replace the kernel, kernel modules and device tree with the complied sources from kernel.org. If this works, then we can discuss about changing the recipe.
My compile VM is already using BSP 3.0b4. The machine is set to apalis-tk1-mainline. I know how to replace the kernel on the system (the TK1 module) but how do i complile the linux kernel properly without recipe? BR
Hi. I was able to compile the latest kernel 5.12.9. Once installed on the system the following output is generated when loading the firmware to the device:
[INFO] [UHD] linux; GNU C++ version 8.2.0; Boost_106800; UHD_4.0.0.0-release
[ 39.298299] tegra-ahci 70027000.sata: supply ahci not found, using dummy regulator
[ 39.306865] tegra-ahci 70027000.sata: supply phy not found, using dummy regulator
[INFO] [B200] Loading firmware image: /usr/share/uhd/images/usrp_b[ 39.318389] tegra-pcie 1003000.pcie: host bridge /pcie@1003000 r:
200_fw.hex...
[ 39.328310] tegra-pcie 1003000.pcie: MEM 0x0001000000..0x0001001fff -> 0x0001000000
[ 39.338391] tegra-pcie 1003000.pcie: IO 0x0012000000..0x001200ffff -> 0x0000000000
[ 39.346653] tegra-pcie 1003000.pcie: MEM 0x0013000000..0x001fffffff -> 0x0013000000
[ 39.355524] tegra-pcie 1003000.pcie: MEM 0x0020000000..0x003fffffff -> 0x0020000000
[ 39.364506] tegra-pcie 1003000.pcie: 2x1, 1x1 configuration
[ 39.372120] tegra-pcie 1003000.pcie: failed to get PHY#0: -517
[ 39.378223] tegra-pcie 1003000.pcie: failed to get PHYs: -517
[ 39.384056] tegra-pcie 1003000.pcie: failed to request resources: -517
[ 43.101244] usb 1-1: USB disconnect, device number 2
[ 43.577394] usb 1-1: new high-speed USB device number 3 using ci_hdrc
[ 44.019920] tegra-ahci 70027000.sata: supply ahci not found, using dummy regulator
[ 44.027937] tegra-ahci 70027000.sata: supply phy not found, using dummy regulator
[ 44.036425] tegra-pcie 1003000.pcie: host bridge /pcie@1003000 ranges:
[ 44.043410] tegra-pcie 1003000.pcie: MEM 0x0001000000..0x0001001fff -> 0x0001000000
[ 44.051775] tegra-pcie 1003000.pcie: IO 0x0012000000..0x001200ffff -> 0x0000000000
[ 44.060132] tegra-pcie 1003000.pcie: MEM 0x0013000000..0x001fffffff -> 0x0013000000
[ 44.068427] tegra-pcie 1003000.pcie: MEM 0x0020000000..0x003fffffff -> 0x0020000000
[ 44.076632] tegra-pcie 1003000.pcie: 2x1, 1x1 configuration
[ 44.082862] tegra-pcie 1003000.pcie: failed to get PHY#0: -517
[ 44.088877] tegra-pcie 1003000.pcie: failed to get PHYs: -517
[ 44.094641] tegra-pcie 1003000.pcie: failed to request resources: -517
[ 44.109370] tegra-ahci 70027000.sata: supply ahci not found, using dummy regulator
[ 44.117061] tegra-ahci 70027000.sata: supply phy not found, using dummy regulator
[ 44.126597] tegra-pcie 1003000.pcie: host bridge /pcie@1003000 ranges:
[ 44.134038] tegra-pcie 1003000.pcie: MEM 0x0001000000..0x0001001fff -> 0x0001000000
[ 44.142993] tegra-pcie 1003000.pcie: IO 0x0012000000..0x001200ffff -> 0x0000000000
[ 44.151955] tegra-pcie 1003000.pcie: MEM 0x0013000000..0x001fffffff -> 0x0013000000
[ 44.161013] tegra-pcie 1003000.pcie: MEM 0x0020000000..0x003fffffff -> 0x0020000000
[ 44.170044] tegra-pcie 1003000.pcie: 2x1, 1x1 configuration
[ 44.175879] tegra-pcie 1003000.pcie: failed to get PHY#0: -517
[ 44.183166] tegra-pcie 1003000.pcie: failed to get PHYs: -517
[ 44.189754] tegra-pcie 1003000.pcie: failed to request resources: -517
[ 44.296692] tegra-ahci 70027000.sata: supply ahci not found, using dummy regulator
[ 44.310298] tegra-ahci 70027000.sata: supply phy not found, using dummy regulator
[ 44.327584] tegra-pcie 1003000.pcie: host bridge /pcie@1003000 ranges:
[ 44.335065] tegra-pcie 1003000.pcie: MEM 0x0001000000..0x0001001fff -> 0x0001000000
[ 44.344453] tegra-pcie 1003000.pcie: IO 0x0012000000..0x001200ffff -> 0x0000000000
[ 44.352837] tegra-pcie 1003000.pcie: MEM 0x0013000000..0x001fffffff -> 0x0013000000
[ 44.361186] tegra-pcie 1003000.pcie: MEM 0x0020000000..0x003fffffff -> 0x0020000000
[ 44.369821] tegra-pcie 1003000.pcie: 2x1, 1x1 configuration
[ 44.382811] tegra-pcie 1003000.pcie: failed to get PHY#0: -517
[ 44.389628] tegra-pcie 1003000.pcie: failed to get PHYs: -517
[ 44.396269] tegra-pcie 1003000.pcie: failed to request resources: -517
[INFO] [B200] Detected Device: B205mini
[INFO] [B200] Loading FPGA image: /usr/share/uhd/images/usrp_b205mini_fpga.bin...
[INFO] [B200] Operating ov[ 111.048189] tegra-ahci 70027000.sata: supply ahci not found, using dummy regulator
er USB 2.
[ 111.059260] tegra-ahci 70027000.sata: supply phy not found, using dummy regulator
[ 111.068458] tegra-pcie 1003000.pcie: host bridge /pcie@1003000 ranges:
[ 111.075071] tegra-pcie 1003000.pcie: MEM 0x0001000000..0x0001001fff -> 0x0001000000
[ 111.084157] tegra-pcie 1003000.pcie: IO 0x0012000000..0x001200ffff -> 0x0000000000
[ 111.092714] tegra-pcie 1003000.pcie: MEM 0x0013000000..0x001fffffff -> 0x0013000000
[ 111.101331] tegra-pcie 1003000.pcie: MEM 0x0020000000..0x003fffffff -> 0x0020000000
[ 111.109884] tegra-pcie 1003000.pcie: 2x1, 1x1 configuration
[ 111.116113] tegra-pcie 1003000.pcie: failed to get PHY#0: -517
[ 111.122198] tegra-pcie 1003000.pcie: failed to get PHYs: -517
[ 111.128259] tegra-pcie 1003000.pcie: failed to request resources: -517
[INFO] [B200] Initialize C[ 111.136903] tegra-ahci 70027000.sata: supply ahci not found, using dummy regulator
ODEC control...
[ 111.147511] tegra-ahci 70027000.sata: supply phy not found, using dummy regulator
[ 111.156983] tegra-pcie 1003000.pcie: host bridge /pcie@1003000 ranges:
[ 111.163763] tegra-pcie 1003000.pcie: MEM 0x0001000000..0x0001001fff -> 0x0001000000
[ 111.172234] tegra-pcie 1003000.pcie: IO 0x0012000000..0x001200ffff -> 0x0000000000
[ 111.180500] tegra-pcie 1003000.pcie: MEM 0x0013000000..0x001fffffff -> 0x0013000000
[ 111.188679] tegra-pcie 1003000.pcie: MEM 0x0020000000..0x003fffffff -> 0x0020000000
[ 111.196867] tegra-pcie 1003000.pcie: 2x1, 1x1 configuration
[ 111.203131] tegra-pcie 1003000.pcie: failed to get PHY#0: -517
[ 111.209219] tegra-pcie 1003000.pcie: failed to get PHYs: -517
[ 111.215069] tegra-pcie 1003000.pcie: failed to request resources: -517
[INFO] [B200] Initialize Radio control...
After some minutes the download process seems to succeed…
Its not solved. The device is not recognized as USB3 but USB2. Either LAN nor PCIe is working. Besides that the download process succeeded. In the meantime i have tried the 5.4.77 kernel which is the last merge i found in the toradex linux sources. This kernel seems to lack usb3 support as well (no usb3 hubs found).
Hi @jaski.tx,
This hardware combination has proved to be working fine for some years now. The problem arised when we upgraded to the BSP3 LTS and mainline kernel. Moving away from your adopted kernel could have other side effects and that is too risky for us. I am not a Linux expert, but maybe something changed in your USB configuration? I can provide you more logs and details if needed. BR
I checked on my side on Bsp 3.04 mainline and Bsp 5.2. USB3.0 and PCIe seems to work. Which USB Port did you use on Ixora?
root@apalis-tk1:~# [ 52.951803] usb 4-3: new high-speed USB device number 3 using tegra-xusb
[ 53.171380] hub 4-3:1.0: USB hub found
[ 53.176347] hub 4-3:1.0: 4 ports detected
[ 53.323032] usb 5-1: new SuperSpeed Gen 1 USB device number 4 using tegra-xusb
[ 53.374918] hub 5-1:1.0: USB hub found
[ 53.379941] hub 5-1:1.0: 4 ports detected
[ 53.712419] usb 5-1.4: new SuperSpeed Gen 1 USB device number 5 using tegra-xusb
Bus 005 Device 004: ID 0bda:0411 Realtek Semiconductor Corp. 4-Port USB 3.0 Hub