I’m working with the Nvidia Orin Nano developer kit to create a USB custom gadget driver to transfer the data from the device to the Ubuntu host computer. The USB IN/OUT endpoints are configured with bulk transfer type, and the data rate is set to USB super speed. When the driver is probed, the USB device is registered and listed on the Ubuntu host. The 10 bytes of test data are transferred from the USB gadget driver to the host. Using the Wireshark application, the USB data packets are monitored, and it didn’t receive on the host PC.
Can you please confirm the Nvidia system supports both USB SuperSpeed (5 Gbps) and Plus (10 Gbps) for the USB gadget driver?
From the USB custom gadget driver, it queues the data to the function tegra_xudc_ep_queue of “drivers/usb/gadget/udc/tegra-xudc.c.” The kernel crashed after the consecutive times it tried to send the data. Please check the driver source file and kernel crashing dmesg logs.
For the question 2, the kernel crashes from the UDC controller driver tegra-xudc.c
. Can you please look at the dmesg logs and your help is much appreciated.
The zip contains the readme, kernel driver source and ko file. Please follow the steps mentioned in the readme file to reproduce the issue on your side
Hi,
We will need some time to set up to replicate the issue. Will update once there is further finding. We will set up latest Jetpack 6.1. It would be great if you can also try the version.
$ sudo insmod /usr/lib/modules/5.15.148-tegra/kernel/drivers/usb/gadget/usb_bulk_gadget.ko
insmod: ERROR: could not insert module /usr/lib/modules/5.15.148-tegra/kernel/drivers/usb/gadget/usb_bulk_gadget.ko: Unknown symbol in module
[dmesg]
[ 563.063511] usb_bulk_gadget: Unknown symbol usb_get_function_instance (err -2)
[ 563.063553] usb_bulk_gadget: Unknown symbol usb_add_config_only (err -2)
[ 563.063574] usb_bulk_gadget: Unknown symbol usb_string_ids_tab (err -2)
[ 563.063607] usb_bulk_gadget: Unknown symbol usb_get_function (err -2)
[ 563.063630] usb_bulk_gadget: Unknown symbol usb_composite_unregister (err -2)
[ 563.063649] usb_bulk_gadget: Unknown symbol usb_put_function (err -2)
[ 563.063673] usb_bulk_gadget: Unknown symbol usb_add_function (err -2)
[ 563.063688] usb_bulk_gadget: Unknown symbol usb_composite_probe (err -2)
[ 563.063710] usb_bulk_gadget: Unknown symbol usb_composite_overwrite_options (err -2)
[ 563.063732] usb_bulk_gadget: Unknown symbol usb_otg_descriptor_alloc (err -2)
[ 563.063755] usb_bulk_gadget: Unknown symbol usb_put_function_instance (err -2)
[ 563.063776] usb_bulk_gadget: Unknown symbol usb_otg_descriptor_init (err -2)
[ 563.063808] usb_bulk_gadget: Unknown symbol usb_ep_autoconfig_ss (err -2)
Do you have idea how to fix it? We can successfully buid usb_bulk_gadget.c but hit the error while inserting the module.
$ sudo insmod /usr/lib/modules/5.15.148-tegra/kernel/drivers/usb/gadget/usb_bulk_gadget.ko
insmod: ERROR: could not insert module /usr/lib/modules/5.15.148-tegra/kernel/drivers/usb/gadget/usb_bulk_gadget.ko: Unknown symbol in module
[dmesg]
[ 96.933888] bulk_bind: Entered
[ 96.933900] bulk_bind: Max Packet size: 1024
[ 96.933902] bulk_bind: bulk in and out endpoints configured
[ 96.937299] udc 3550000.usb: failed to start bulk_driver: -2
Is there a chance you can set up Jetpack 6.1 and check? To help replicate the issue on Jetpack 6.1.