I am looking for a way to use the RTL8156 USB ethernet adapter with the correct driver on OpenWrt on PC hardware (x86/64)
This device is recognized as an ethernet device just by plugging it in, but the cdc_ncm driver is selected, and has problems such as low throughput.
root@OpenWrt:~# lsusb
Bus 002 Device 002: ID 0bda:8156 Realtek USB 10/100/1G/2.5G LAN
I installed "kmod-usb-net-rtl8152" and related packages in my OpenWrt 22.03 environment and found that other Linux systems such as ArchLinux could solve this situation by installing the r8152 package,
I ran the command echo 1 > /sys/bus/usb/devices/2-1/bConfigurationValue
based on the following post (A huge thank you to bmork and the users of the forum).
As a result, the r8152 driver detected the device, but an error "r8152 2-1:1.0: Unknown version 0x7410" is printed.
(I suspect this is because the current driver supports the series up to RTL8153 and not the newer RTL8156 devices.)
So I tried a snapshot build of kernel 5.15.114 and tried the same thing, and was able to confirm that the r8152 driver recognizes this adapter, but it outputs logs like this, and although communication is possible I encountered some problems, such as not linking up at 2.5GbaseT.
(I tried to force a link speed change with ethtool just to be sure, but could not change it from 1000base-T)
[ 8.368490] usb 2-1: reset SuperSpeed USB device number 2 using xhci_hcd
[ 8.411750] r8152 2-1:1.0: ram code speedup mode fail
[ 8.412077] r8152 2-1:1.0: load rtl8156b-2 v2 04/27/23 successfully
[ 8.458695] r8152 2-1:1.0 (unnamed net_device) (uninitialized): netif_napi_add() called with weight 256
[ 8.459761] r8152 2-1:1.0 eth4: v1.12.13
Any advice on how to use 2.5G/full speed with this RTL8156 device?
I don't have the ability to modify the source code, but I think I can check the logs of the device if needed or create an image using the Build system from another PC.
Any help will be appreciated. Thank you.