Verdin iMX8MP & USB2514B/M2

Hello there!

tdx-info output:

Software summary
------------------------------------------------------------
Bootloader:               U-Boot
Kernel version:           5.15.148-6.7.0+git.bfdbfb2c85fb #1-TorizonCore SMP PREEMPT Thu Jun 20 15:59:41 UTC 2024
Kernel command line:      root=LABEL=otaroot rootfstype=ext4 quiet logo.nologo vt.global_cursor_default=0 plymouth.ignore-serial-consoles splash fbcon=map:3 ostree=/ostree/boot.1/torizon/90e01d0d190736f48ecdd06a21b8c8f58031df0728192beb7e16fa15b5dc7608/0
Distro name:              NAME="TorizonCore"
Distro version:           VERSION_ID=6.7.0-build.18
Distro variant:           VARIANT="Docker"
Hostname:                 verdin-imx8mp-15128326
------------------------------------------------------------

Hardware info
------------------------------------------------------------
HW model:                 Toradex Verdin iMX8MP WB on prototype mk1
Toradex version:          0064 V1.1A
Serial number:            15128326
Processor arch:           aarch64
------------------------------------------------------------

I’ve recently received the prototype of a custom carrier board for an upcoming product of ours. One of the features the board needs to support is a USB hub, a Microchip USB2514B/M2, which is currently connected the USB_1 pins. Only SODIMM 163 (USB_1_D_N) and 165 (USB_1_D_P) are connected to the IC.
I’ve made a custom device tree, based off of the imx8mp-verdin-dev.dtsi. The relevant changes to phandles are:

/dts-v1/;

#include "imx8mp-verdin.dtsi"
#include "imx8mp-verdin-wifi.dtsi"

/ {
    model = "Toradex Verdin iMX8MP WB on prototype mk1";
    compatible = "toradex,verdin-imx8mp-wifi-dev",
                 "toradex,verdin-imx8mp-wifi",
                 "toradex,verdin-imx8mp",
                 "fsl,imx8mp";
};

...

&usb3_0 {
    status = "okay";
};

&usb_dwc3_0 {
    dr_mode = "host";
};

&usb3_phy0 {
    status = "okay";
};

...

So far I’ve been able to get the SoM to recognize the hub, as evident by the output of lsusb:

Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 002: ID 0424:2514 Microchip Technology, Inc. (formerly SMSC) USB 2.0 Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

However, when I connect any USB device to the hub, they aren’t recognized. I’ve looked for documentation on adding the USB2514B/M2 to our device tree, however i could only find documentation and examples utilizing I2C, whereas the SDA and SCL pins on the IC are wired to ground on the prototype I have at hand.
dmesg | grep -i usb logs:

[    0.092780] usbcore: registered new interface driver usbfs
[    0.092817] usbcore: registered new interface driver hub
[    0.092840] usbcore: registered new device driver usb
[    0.925089] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.925321] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    0.926003] usbcore: registered new interface driver uas
[    0.926044] usbcore: registered new interface driver usb-storage
[    0.926102] usbcore: registered new interface driver usbserial_generic
[    0.926124] usbserial: USB Serial support registered for generic
[    0.926375] usbcore: registered new device driver onboard-usb-hub
[    0.969838] usbcore: registered new interface driver usbhid
[    0.969843] usbhid: USB HID core driver
[    0.980014] usbcore: registered new interface driver snd-usb-audio
[    1.028304] imx8mq-usb-phy 381f0040.usb-phy: supply vbus not found, using dummy regulator
[    1.061343] xhci-hcd xhci-hcd.1.auto: new USB bus registered, assigned bus number 1
[    1.061932] xhci-hcd xhci-hcd.1.auto: new USB bus registered, assigned bus number 2
[    1.061945] xhci-hcd xhci-hcd.1.auto: Host supports USB 3.0 SuperSpeed
[    1.062779] hub 1-0:1.0: USB hub found
[    1.063119] usb usb2: We don't know the algorithms for LPM for this host, disabling LPM.
[    1.063523] hub 2-0:1.0: USB hub found
[    1.356690] usb 1-1: new high-speed USB device number 2 using xhci-hcd
[    1.574217] hub 1-1:1.0: USB hub found
[    1.734149] hub 1-1:1.0: USB hub found
[   46.756375] usb 1-1.1: new full-speed USB device number 3 using xhci-hcd
[   46.856399] usb 1-1.1: device no response, device descriptor read/64, error -32
[   47.076388] usb 1-1.1: device no response, device descriptor read/64, error -32
[   47.296376] usb 1-1.1: new full-speed USB device number 4 using xhci-hcd
[   47.406396] usb 1-1.1: device no response, device descriptor read/64, error -32
[   47.626408] usb 1-1.1: device no response, device descriptor read/64, error -32
[   47.746520] usb 1-1-port1: attempt power cycle
[   48.406373] usb 1-1.1: new full-speed USB device number 5 using xhci-hcd
[   48.406462] usb 1-1.1: Device not responding to setup address.
[   48.626469] usb 1-1.1: Device not responding to setup address.
[   48.846375] usb 1-1.1: device not accepting address 5, error -71
[   48.946377] usb 1-1.1: new full-speed USB device number 6 using xhci-hcd
[   48.946466] usb 1-1.1: Device not responding to setup address.
[   49.166464] usb 1-1.1: Device not responding to setup address.
[   49.386374] usb 1-1.1: device not accepting address 6, error -71
[   49.392534] usb 1-1-port1: unable to enumerate USB device

I’m quite at a loss, and am unsure how to continue the development on this part of the prototype… Any help which could point me in the right direction would be much appreciated!

Best regards,
Sophus

Hi, I’m the Toradex AI Assistant. The Toradex Support team will follow up with you shortly!

Did you like my answer?

:+1: :-1:


Hello Sophus,

It looks like you’ve made good progress in getting the USB hub recognized by the system. However, the issue seems to be with the devices connected to the hub not being recognized. Here are a few steps and considerations that might help you troubleshoot and resolve the issue:

  1. Power Supply:

    • Ensure that the USB hub is receiving adequate power. Sometimes, insufficient power can cause devices connected to the hub to malfunction or not be recognized.
  2. Device Tree Configuration:

    • Your device tree configuration seems mostly correct, but you might need to ensure that all necessary properties for the USB hub are set. For example, you might need to specify the vbus-supply property if your hub requires it.
  3. USB Hub Initialization:

    • Check if the USB hub requires any specific initialization sequence or additional configuration. Some USB hubs might need specific GPIOs to be toggled or other initialization steps.
  4. Kernel Logs:

    • The dmesg logs indicate errors when trying to enumerate devices connected to the hub. The error device not accepting address often points to issues with power or signal integrity. Double-check the physical connections and ensure there are no loose connections or shorts.
  5. USB Hub Documentation:

    • Refer to the USB2514B/M2 datasheet and reference manual to ensure that all necessary connections and configurations are correctly implemented on your custom carrier board.
  6. Testing with Known Good Devices:

    • Try connecting different USB devices to the hub to see if the issue is specific to certain devices or if it affects all devices. This can help narrow down whether the issue is with the hub or the connected devices.
  7. I2C Configuration:

    • Although you mentioned that the SDA and SCL pins are grounded, double-check if the USB hub requires any I2C configuration for full functionality. Some hubs might have optional I2C interfaces for additional features or configurations.
  8. USB Driver Support:

    • Ensure that the necessary USB drivers are enabled in your kernel configuration. The xhci-hcd driver seems to be loaded, but verify that all required drivers for your USB hub and connected devices are enabled.
  9. Firmware Updates:

    • Check if there are any firmware updates available for the USB hub that might address compatibility or functionality issues.
  10. Debugging Tools:

    • Use tools like usbmon to capture USB traffic and get more detailed insights into what might be going wrong during device enumeration.

If after these steps the issue persists, you might want to reach out to Toradex support with detailed logs and your device tree configuration for further assistance.

Best regards,
[Your Name]

Please, also check if these links can help you solve your problem:

USB boot from Apalis iMX8QM USB01 on custom carrier board.

With the help of our Hardware Engineers, we found the issue. In our case D+ and D- from the hub to the device ports had swapped labels, and thus swapped connections. As we are utilizing the default configuration (self powered operation, CFG_SEL[0] and CFG_SEL[1] pulled to ground), this left us with no way of potentially fixing this issue through any SMBus based configuration. The solution was to swap the offending D+ and D- lines. Once the lines were swapped, the kernel was able to recognize devices connected to the ports of the hub. We tested this with USB Mass Storage Devices, Mice and Keyboards.