Use USB0 as host usb on Orin NX custom carrier board(JP 5.1.2)

Hi

We have a custom carrier board with Orin - JP 5.1.2
I want to use the usb0 port as a host device
We have a FTDI chip connected to usb0 on the hardware and we are unable to detect it

i encounter the following errors:

[ 30.230494] usb0: HOST MAC be:69:b9:83:6d:2a
[ 30.230502] usb0: MAC be:69:b9:83:6d:2b
[ 30.242297] l4tbr0: port 2(usb0) entered blocking state
[ 30.242309] l4tbr0: port 2(usb0) entered disabled state
[ 30.242418] device usb0 entered promiscuous mode

Here are my device tree settings:

Changed otg to host

                ports {

                        u0x2b7sb2-0 {
                                status = "okay";
                                mode = "host";
                                vbus-supply = <0x2b6>;
                                usb-role-switch;

                                port {

                                        endpoint {
                                                remote-endpoint = <0x2b7>;
                                                phandle = <0x69>;
                                        };
                                };
                        };

Removed usb2-a from xudc@3550000
and added u0x2b7sb2-0 with its respective phandle value in phys

xhci@3610000 {
                compatible = "nvidia,tegra234-xhci\0nvidia,tegra234-xusb";
                reg = <0x00 0x3610000 0x00 0x40000 0x00 0x3600000 0x00 0x10000 0x00 0x3650000 0x00 0x10000>;
                reg-names = "base\0fpci\0bar2";
                interrupts-extended = <0x01 0x00 0xa3 0x04 0x01 0x00 0xa4 0x04 0x01 0x00 0xa7 0x04 0x0a 0x4c 0x04 0x0a 0x4d 0x04 0x0a 0x4e 0x04 0x0a 0x4f 0x04 0x0a 0x50 0x04 0x0a 0x51 0x04 0x0a 0x52 0x04>;
                interrupt-names = "xhci\0mbox\0padctl\0wake0\0wake1\0wake2\0wake3\0wake4\0wake5\0wake6";
                clocks = <0x02 0x10a 0x02 0x10b 0x02 0x10c 0x02 0x10d 0x02 0x10e 0x02 0x10f 0x02 0x110 0x02 0x111 0x02 0x113 0x02 0x115 0x02 0x67 0x02 0x0e 0x02 0x64>;
                clock-names = "xusb_hs_src\0xusb_host\0xusb_core_superspeed_clk\0xusb_falcon_src\0xusb_falcon_host_clk\0xusb_falcon_superspeed_clk\0xusb_fs_src\0xusb_fs_host_clk\0xusb_ss_src\0xusb_ss\0pll_u_480m\0clk_m\0pll_e";
                power-domains = <0x02 0x0c 0x02 0x0a>;
                power-domain-names = "xusb_host\0xusb_ss";
                nvidia,xusb-padctl = <0x2b9>;
                interconnects = <0x03 0x4a 0x03 0x4b>;
                interconnect-names = "dma-mem\0dma-mem";
                iommus = <0x56 0x0e>;
                dma-coherent;
                status = "okay";
                phys = <0x2b7 0x2ba 0x2bd 0x2be 0x2bf 0x2bc>;
                phy-names = "u0x2b7sb2-0\0usb2-0\0usb2-1\0usb2-2\0usb3-0\0usb3-1";
                phandle = <0x45f>;

Please advice thanks

Hi,

Does usb 1-1 in the dmesg mean USB0? it says device not responding, we have two FTDI chips connected - one on USB0 and the other on USB1


**[    7.684444] usb 1-1: new low-speed USB device number 2 using tegra-xusb**
**[    7.820739] usb 1-1: device descriptor read/64, error -71**
**[    8.064743] usb 1-1: device descriptor read/64, error -71**
**[    8.304442] usb 1-1: new low-speed USB device number 3 using tegra-xusb**
**[    8.440921] usb 1-1: device descriptor read/64, error -71**
**[    8.680621] usb 1-1: device descriptor read/64, error -71**
**[    8.796420] usb usb1-port1: attempt power cycle**
**[    9.208444] usb 1-1: new low-speed USB device number 4 using tegra-xusb**
**[    9.216624] usb 1-1: Device not responding to setup address.**
**[    9.429848] usb 1-1: Device not responding to setup address.**
**[    9.644440] usb 1-1: device not accepting address 4, error -71**
**[    9.776442] usb 1-1: new low-speed USB device number 5 using tegra-xusb**
**[    9.784429] usb 1-1: Device not responding to setup address.**
**[    9.997845] usb 1-1: Device not responding to setup address.**
**[   10.228441] usb 1-1: device not accepting address 5, error -71**
[   10.234723] usb usb1-port1: unable to enumerate USB device
[   10.368516] usb 1-2: new high-speed USB device number 6 using tegra-xusb
[   10.528943] usb 1-2: New USB device found, idVendor=0403, idProduct=6011, bcdDevice= 8.00
[   10.537358] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[   10.544698] usb 1-2: Product: Quad RS232-HS
[   10.548983] usb 1-2: Manufacturer: FTDI
[   10.752442] usb 1-3: new high-speed USB device number 7 using tegra-xusb
[   10.912625] usb 1-3: New USB device found, idVendor=0781, idProduct=55ab, bcdDevice= 1.00
[   10.921050] usb 1-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[   10.928392] usb 1-3: Product:  SanDisk 3.2Gen1
[   10.932947] usb 1-3: Manufacturer:  USB
[   10.936891] usb 1-3: SerialNumber: 0401560f40952dbc0e3436df992295ab6675723839beef3157b08d7291ecd0dd91ef00000000000000000000fee19030008c2a18ab558107562ee5c1
[   10.952338] usb-storage 1-3:1.0: USB Mass Storage device detected
[   10.959457] scsi host0: usb-storage 1-3:1.0
[   18.023867] fusb301 1-0025: failed to read device id, err : 0xffffff87
[   18.031260] fusb301 1-0025: fusb301 not support
[   18.036135] fusb301: probe of 1-0025 failed with error -22
[   19.009444] usbcore: registered new interface driver ftdi_sio
[   19.015393] usbserial: USB Serial support registered for FTDI USB Serial Device
[   19.029834] usb 1-2: Detected FT4232H
[   19.034747] usb 1-2: FTDI USB Serial Device converter now attached to ttyUSB0
[   19.049012] usb 1-2: Detected FT4232H
[   19.053965] usb 1-2: FTDI USB Serial Device converter now attached to ttyUSB1
[   19.068200] usb 1-2: Detected FT4232H
[   19.073629] usb 1-2: FTDI USB Serial Device converter now attached to ttyUSB2
[   19.093519] usb 1-2: Detected FT4232H
[   19.098481] usb 1-2: FTDI USB Serial Device converter now attached to ttyUSB3
[   30.513062] usb0: HOST MAC be:69:b9:83:6d:2a
[   30.513066] usb0: MAC be:69:b9:83:6d:2b
[   30.525626] l4tbr0: port 2(usb0) entered blocking state
[   30.525638] l4tbr0: port 2(usb0) entered disabled state
[   30.525757] device usb0 entered promiscuous mode

Sorry for the late response.
Is this still an issue to support? Any result can be shared?

@kayccc

yes this is still an issue, no results yet to be shared.

please share the whole schematic and whole device tree. It is not able to know those phandle with just your partial snippets.

@WayneWWW

Here is the device tree:

check.dts.txt (412.4 KB)

We need to know the whole part from jetson side to the connector side.

@WayneWWW

There are 2 FTDI chips connected:
On USB0 and USB1

USB1 ftdi chip is being detected but USB0 FTDI is not.

please remove the fusb301 related things on your board too. This is the type C controller on the USB0.

@WayneWWW

We have disabled it.