I working on custom carrier board for Orin Industrial. I have problem with usb-c port stopping work after leaving UEFI. It works fine with UEFI and I’m able to use keyboard and mouse, but after launch the linux kernel it stops work.
lsusb result is empty.
Dmesg:
dmesg.txt (55.3 KB)
Orin Device tree:
tegra234-p3737-0000+p3701-0008-nv.dts.txt (3.8 KB)
Xavier Device tree(working):
xusb_padctl@3520000 {
compatible = "nvidia,tegra194-xusb-padctl";
reg = <0x00 0x3520000 0x00 0x1000 0x00 0x3540000 0x00 0x1000>;
reg-names = "padctl\0ao";
interrupts = <0x00 0xa7 0x04>;
resets = <0x04 0x72>;
reset-names = "padctl";
status = "okay";
vclamp-usb-supply = <0x15>;
avdd-usb-supply = <0x2c4>;
phandle = <0x2c7>;
pads {
usb2 {
clocks = <0x04 0xa5>;
clock-names = "trk";
lanes {
usb2-0 {
status = "okay";
#phy-cells = <0x00>;
nvidia,function = "xusb";
phandle = <0x2c8>;
};
usb2-1 {
status = "okay";
#phy-cells = <0x00>;
nvidia,function = "xusb";
phandle = <0x2ca>;
};
usb2-2 {
status = "okay";
#phy-cells = <0x00>;
nvidia,function = "xusb";
phandle = <0x2cc>;
};
usb2-3 {
status = "okay";
#phy-cells = <0x00>;
nvidia,function = "xusb";
phandle = <0x2cb>;
};
};
};
usb3 {
lanes {
usb3-0 {
status = "okay";
#phy-cells = <0x00>;
nvidia,function = "xusb";
phandle = <0x2cd>;
};
usb3-1 {
status = "disabled";
#phy-cells = <0x00>;
};
usb3-2 {
status = "okay";
#phy-cells = <0x00>;
nvidia,function = "xusb";
phandle = <0x2c9>;
};
usb3-3 {
status = "okay";
#phy-cells = <0x00>;
nvidia,function = "xusb";
phandle = <0x2ce>;
};
};
};
};
ports {
usb2-0 {
status = "okay";
vbus-supply = <0x22>;
mode = "otg";
usb-role-switch;
port {
endpoint {
remote-endpoint = <0x2c5>;
phandle = <0x33>;
};
};
};
usb2-1 {
status = "okay";
vbus-supply = <0x22>;
mode = "host";
};
usb2-2 {
status = "okay";
vbus-supply = <0x22>;
mode = "host";
};
usb2-3 {
status = "okay";
vbus-supply = <0x2c6>;
mode = "host";
};
usb3-0 {
status = "okay";
nvidia,usb2-companion = <0x01>;
};
usb3-1 {
status = "disabled";
};
usb3-2 {
status = "okay";
nvidia,usb2-companion = <0x00>;
};
usb3-3 {
status = "okay";
nvidia,usb2-companion = <0x03>;
nvidia,usb3-gen1-only = <0x01>;
};
};
prod-settings {
#prod-cells = <0x04>;
prod_c_bias {
prod = <0x00 0x284 0x38 0x38>;
};
prod {
prod = <0x00 0x24 0xfff 0x00>;
};
};
};
usb_cd {
compatible = "nvidia,tegra194-usb-cd";
nvidia,xusb-padctl = <0x2c7>;
phys = <0x2c8>;
phy-names = "otg-phy";
status = "okay";
phandle = <0x49f>;
};
xudc@3550000 {
compatible = "nvidia,tegra194-xudc";
reg = <0x00 0x3550000 0x00 0x8000 0x00 0x3558000 0x00 0x1000>;
reg-names = "base\0fpci";
interrupts = <0x00 0xa6 0x04>;
clocks = <0x04 0x109 0x04 0x115 0x04 0x113 0x04 0x110>;
clock-names = "dev\0ss\0ss_src\0fs_src";
power-domains = <0x04 0x0f 0x04 0x0e>;
power-domain-names = "dev\0ss";
nvidia,xusb-padctl = <0x2c7>;
iommus = <0x02 0x1c>;
dma-coherent;
status = "okay";
avdd-usb-supply = <0x2c4>;
phys = <0x2c8 0x2c9>;
phy-names = "usb2-0\0usb3-2";
nvidia,boost_cpu_freq = <0x4b0>;
phandle = <0x4a0>;
};
xhci@3610000 {
compatible = "nvidia,tegra194-xhci\0nvidia,tegra194-xusb";
reg = <0x00 0x3610000 0x00 0x40000 0x00 0x3600000 0x00 0x10000>;
reg-names = "base\0fpci";
interrupts-extended = <0x01 0x00 0xa3 0x04 0x01 0x00 0xa4 0x04 0x01 0x00 0xa7 0x04 0x2be 0x4c 0x04 0x2be 0x4d 0x04 0x2be 0x4e 0x04 0x2be 0x4f 0x04 0x2be 0x50 0x04 0x2be 0x51 0x04 0x2be 0x52 0x04>;
interrupt-names = "xhci\0mbox\0padctl\0wake0\0wake1\0wake2\0wake3\0wake4\0wake5\0wake6";
interconnects = <0x03 0x4a 0x03 0x4b>;
interconnect-names = "dma-mem\0dma-mem";
clocks = <0x04 0x10a 0x04 0x10b 0x04 0x10c 0x04 0x10d 0x04 0x10e 0x04 0x10f 0x04 0x110 0x04 0x111 0x04 0x113 0x04 0x115 0x04 0x67 0x04 0x0e 0x04 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 = <0x04 0x10 0x04 0x0e>;
power-domain-names = "xusb_host\0xusb_ss";
nvidia,xusb-padctl = <0x2c7>;
iommus = <0x02 0x1b>;
dma-coherent;
status = "okay";
phys = <0x2c8 0x2ca 0x2cb 0x2cc 0x2c9 0x2cd 0x2ce>;
phy-names = "usb2-0\0usb2-1\0usb2-3\0usb2-2\0usb3-2\0usb3-0\0usb3-3";
nvidia,boost_emc_freq = <0x1f4>;
phandle = <0x4a1>;
};
i2c@c240000 {
ucsi_ccg@8 {
compatible = "nvidia,ccgx-ucsi";
reg = <0x08>;
interrupt-parent = <0x0c>;
interrupts = <0x0a 0x08>;
status = "okay";
ccgx,firmware-build = "gn";
phandle = <0x31c>;
connector@0 {
compatible = "usb-c-connector";
label = "USB-C";
data-role = "dual";
phandle = <0x31d>;
port {
endpoint {
remote-endpoint = <0x33>;
phandle = <0x2c5>;
};
};
};
};
It looks like you are not using ucsi ccg in your design?
We are using usb crosspoint switch - NXP CBTL08GP053EVY which is controlled by uC in current iteration of hardware. The uC is used to detect usb-c cable orientation and it is switching USB lines by nxp chip, so we don’t need to use ucsi ccg. But the main problems is fact that lsusb is not reporting any usb devices. Every usb port is working correctly in UEFI, but after it doesn’t show up any logs .
Edit:
USB is working correctly with Jetpack 5.1.3(on unmodified orin industrial config), but doesn’t with Jetpack 6.0 rev2.
I was able to configure USB to work with Jetpack 6.0. I removed whole typec@8 node from i2c@c240000 in.
bus@0 {
xusb_padctl: padctl@3520000{
status = "okay";
pads {
usb2 {
lanes {
usb2-0 {
status = "okay";
};
usb2-1 {
status = "okay";
};
usb2-2 {
status = "okay";
};
usb2-3 {
status = "okay";
};
};
};
usb3 {
lanes {
usb3-0 {
status = "disabled";
};
usb3-1 {
status = "okay";
};
usb3-2 {
status = "okay";
};
};
};
};
ports {
usb2-0 {
mode = "otg";
usb-role-switch;
status = "okay";
};
usb2-1 {
mode = "otg";
vbus-supply = <&vdd_5v0_sys>;
status = "okay";
usb-role-switch;
};
usb2-2 {
status = "okay";
vbus-supply = <&vdd_5v0_sys>;
mode = "host";
};
usb2-3 {
status = "okay";
mode = "host";
};
usb3-0 {
status = "disabled";
};
usb3-1 {
status = "okay";
};
usb3-2 {
status = "okay";
nvidia,usb2-companion = <1>;
nvidia,usb3-gen1-only = <1>;
};
};
};
But after flashing procedure is done and when usb cable is still connected to PCI get spamming error message:
usb usb2-port2: Cannot enable. Maybe the USB cable is bad?
How should I change my node to not get this error. Additionally, flashing doesn’t work for nvme disk, but it is working fine for internal eMMC. Ethernet and Nvme disk is configured and working if I use internal eMMC.
Connector used for flashing is usb 3.0 type A.
Why a type A port is labeled as “otg” in the device tree? And no vbos-supply shared.
And why usb2-1 is a otg mode at same time?
My current configuration is like, this but I’m not able to flash device to nvme. If I configure usb 3.0 type A as peripheral it doesn’t report as issue with cable, but it doesn’t show usb devices like devkit. When it setup as host it is able to be used as normal usb host connector.
xusb_padctl: padctl@3520000{
status = "okay";
pads {
usb2 {
lanes {
usb2-0 {
status = "okay";
};
usb2-1 {
status = "okay";
};
usb2-2 {
status = "okay";
};
usb2-3 {
status = "okay";
};
};
};
usb3 {
lanes {
usb3-0 {
status = "disabled";
};
usb3-1 {
status = "okay";
};
usb3-2 {
status = "okay";
};
};
};
};
ports {
usb2-0 {
mode = "peripheral";
usb-role-switch;
status = "okay";
};
usb2-1 {
mode = "otg";
vbus-supply = <&vdd_5v0_sys>;
status = "okay";
usb-role-switch;
};
usb2-2 {
status = "okay";
vbus-supply = <&vdd_5v0_sys>;
mode = "host";
};
usb2-3 {
status = "okay";
mode = "host";
};
usb3-0 {
status = "disabled";
};
usb3-1 {
status = "okay";
nvidia,usb2-companion = <0>;
nvidia,usb3-gen1-only = <1>;
};
usb3-2 {
status = "okay";
nvidia,usb2-companion = <1>;
nvidia,usb3-gen1-only = <1>;
};
};
};
Always share the log when you tried to clarify something…
lsusb -v
lsusb -v
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 3.10
bDeviceClass 9 Hub
bDeviceSubClass 0
bDeviceProtocol 3
bMaxPacketSize0 9
idVendor 0x1d6b Linux Foundation
idProduct 0x0003 3.0 root hub
bcdDevice 5.15
iManufacturer 3 Linux 5.15.136-tegra xhci-hcd
iProduct 2 xHCI Host Controller
iSerial 1 3610000.usb
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 0x001f
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xe0
Self Powered
Remote Wakeup
MaxPower 0mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 9 Hub
bInterfaceSubClass 0
bInterfaceProtocol 0 Full speed (or root) hub
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0004 1x 4 bytes
bInterval 12
bMaxBurst 0
Hub Descriptor:
bLength 12
bDescriptorType 42
nNbrPorts 4
wHubCharacteristic 0x000a
No power switching (usb 1.0)
Per-port overcurrent protection
bPwrOn2PwrGood 50 * 2 milli seconds
bHubContrCurrent 0 milli Ampere
bHubDecLat 0.0 micro seconds
wHubDelay 0 nano seconds
DeviceRemovable 0x00
Hub Port Status:
Port 1: 0000.02a0 lowspeed L1
Port 2: 0000.02a0 lowspeed L1
Port 3: 0000.02a0 lowspeed L1
Port 4: 0000.02a0 lowspeed L1
Binary Object Store Descriptor:
bLength 5
bDescriptorType 15
wTotalLength 0x002b
bNumDeviceCaps 2
SuperSpeed USB Device Capability:
bLength 10
bDescriptorType 16
bDevCapabilityType 3
bmAttributes 0x00
wSpeedsSupported 0x0008
Device can operate at SuperSpeed (5Gbps)
bFunctionalitySupport 1
Lowest fully-functional device speed is Full Speed (12Mbps)
bU1DevExitLat 10 micro seconds
bU2DevExitLat 598 micro seconds
SuperSpeedPlus USB Device Capability:
bLength 28
bDescriptorType 16
bDevCapabilityType 10
bmAttributes 0x00000023
Sublink Speed Attribute count 3
Sublink Speed ID count 1
wFunctionalitySupport 0x1104
bmSublinkSpeedAttr[0] 0x00050034
Speed Attribute ID: 4 5Gb/s Symmetric RX SuperSpeed
bmSublinkSpeedAttr[1] 0x000500b4
Speed Attribute ID: 4 5Gb/s Symmetric TX SuperSpeed
bmSublinkSpeedAttr[2] 0x000a4035
Speed Attribute ID: 5 10Gb/s Symmetric RX SuperSpeedPlus
bmSublinkSpeedAttr[3] 0x000a40b5
Speed Attribute ID: 5 10Gb/s Symmetric TX SuperSpeedPlus
Device Status: 0x0003
Self Powered
Remote Wakeup Enabled
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 9 Hub
bDeviceSubClass 0
bDeviceProtocol 1 Single TT
bMaxPacketSize0 64
idVendor 0x1d6b Linux Foundation
idProduct 0x0002 2.0 root hub
bcdDevice 5.15
iManufacturer 3 Linux 5.15.136-tegra xhci-hcd
iProduct 2 xHCI Host Controller
iSerial 1 3610000.usb
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 0x0019
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xe0
Self Powered
Remote Wakeup
MaxPower 0mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 1
bInterfaceClass 9 Hub
bInterfaceSubClass 0
bInterfaceProtocol 0 Full speed (or root) hub
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0004 1x 4 bytes
bInterval 12
Hub Descriptor:
bLength 9
bDescriptorType 41
nNbrPorts 4
wHubCharacteristic 0x000a
No power switching (usb 1.0)
Per-port overcurrent protection
TT think time 8 FS bits
bPwrOn2PwrGood 10 * 2 milli seconds
bHubContrCurrent 0 milli Ampere
DeviceRemovable 0x00
PortPwrCtrlMask 0xff
Hub Port Status:
Port 1: 0000.0100 power
Port 2: 0000.0100 power
Port 3: 0000.0100 power
Port 4: 0000.0100 power
Device Status: 0x0003
Self Powered
Remote Wakeup Enabled
Dmesg.log
dmesg_usb.log (60.8 KB)
This code snippet is not sufficient to tell what are you trying to do there.
Please read the document first.
https://docs.nvidia.com/jetson/archives/r36.3/DeveloperGuide/HR/JetsonModuleAdaptationAndBringUp/JetsonAgxOrinSeries.html?highlight=universal%20bus#porting-the-universal-serial-bus
For example, we only support one usb device mode only and expected that to be usb2-0…