Flint AX1800 4.1.0 release 4 usb issue

In this release 4, there is an issue in USB:

lsusb -v shows
can’t get device qualifier: Resource temporarily unavailable
can’t get debug qualifier: Resource temporarily unavailable
in the output, and my APC UPS is not detected with usb-hid driver (appears in lsusb but no communication).

This issue remains in release 5

Does it works in older firmware?

Yes it was working in release2, broke in release3 and newer

@alzhao If there’s any troubleshooting steps, you would like me to do, I can do it.

My APC UPS talks over usb normally with USB HID driver, it’s almost acting like the USB HID driver doesn’t have the hwid of the APC UPS so it ignores it (aka the kernel sees the device on the bus and can talk with it but no driver “activates” it)

In dmesg, usbhid is loading fine, but the line which mentions “American power conversion hid” is missing.

Here’s attached lsusb -v if it will help.
debug.zip (3.8 KB)
dmesg.zip (11.3 KB)

updated zip with errors also.

I tried modprobe usbhid:

[136888.450521] usbcore: registered new interface driver usbhid
[136888.450548] usbhid: USB HID core driver

That’s all the UPS is ignored.

I tried
echo “051d 0003” > /sys/bus/usb/drivers/usbhid/new_id

that’s the id of the ups from lsusb.
It gives write error: invalid argument
then nothing happens

I asked @hansome to have a check. Maybe he updated the report and changed some drivers.

I noticed in the lsusb, it’s actually failing to read the usb descriptor, it’s definitely some kind of usb communication bug. Thanks for follow up, hope it gets fixed soon!

Another info also: since flint has only 1 usb port. I am using a small USB 3.0 hub. In one port of this hub is a USB flash drive which I am mounting in /opt (this one is working), in the other port of this hub is the UPS.

Does it work without the USB hub?
Does it need to install some extra ipk to support the UPS?
Do you have dmesg and debug info using release2 firmware?
In release 3 we added some USB modem support, but it doesn’t impact HID devices.
Please add this command output:

cat /sys/kernel/debug/usb/devices

Thank you very much.

@hansome

T:  Bus=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=5000 MxCh= 1
B:  Alloc=  0/800 us ( 0%), #Int=  0, #Iso=  0
D:  Ver= 3.00 Cls=09(hub  ) Sub=00 Prot=03 MxPS= 9 #Cfgs=  1
P:  Vendor=1d6b ProdID=0003 Rev= 4.04
S:  Manufacturer=Linux 4.4.60 xhci-hcd
S:  Product=xHCI Host Controller
S:  SerialNumber=xhci-hcd.0.auto
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   4 Ivl=256ms

T:  Bus=02 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=5000 MxCh= 4
D:  Ver= 3.00 Cls=09(hub  ) Sub=00 Prot=03 MxPS= 9 #Cfgs=  1
P:  Vendor=045b ProdID=0210 Rev= 1.00
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=13(Int.) MxPS=   2 Ivl=16ms

T:  Bus=02 Lev=02 Prnt=02 Port=03 Cnt=01 Dev#=  3 Spd=5000 MxCh= 0
D:  Ver= 3.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 9 #Cfgs=  1
P:  Vendor=0781 ProdID=5583 Rev= 1.00
S:  Manufacturer=SanDisk
S:  Product=Ultra Fit
S:  SerialNumber=4C530001200618112531
C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=896mA
I:* If#= 0 Alt= 0 #EPs= 2 Cls=08(stor.) Sub=06 Prot=50 Driver=usb-storage
E:  Ad=81(I) Atr=02(Bulk) MxPS=1024 Ivl=0ms
E:  Ad=02(O) Atr=02(Bulk) MxPS=1024 Ivl=0ms

T:  Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=480  MxCh= 1
B:  Alloc=  0/800 us ( 0%), #Int=  0, #Iso=  0
D:  Ver= 2.00 Cls=09(hub  ) Sub=00 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=1d6b ProdID=0002 Rev= 4.04
S:  Manufacturer=Linux 4.4.60 xhci-hcd
S:  Product=xHCI Host Controller
S:  SerialNumber=xhci-hcd.0.auto
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   4 Ivl=256ms

T:  Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#=  2 Spd=480  MxCh= 4
D:  Ver= 2.10 Cls=09(hub  ) Sub=00 Prot=01 MxPS=64 #Cfgs=  1
P:  Vendor=045b ProdID=0209 Rev= 1.00
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub
E:  Ad=81(I) Atr=03(Int.) MxPS=   1 Ivl=256ms

T:  Bus=01 Lev=02 Prnt=02 Port=02 Cnt=01 Dev#=  3 Spd=12   MxCh= 0
D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1
P:  Vendor=051d ProdID=0003 Rev= 1.06
S:  Manufacturer=American Power Conversion 
S:  Product=Smart-UPS C 2000 FW:UPS 11.0 / ID=1007
S:  SerialNumber=AS1705243455  
C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  2mA
I:* If#= 0 Alt= 0 #EPs= 2 Cls=03(HID  ) Sub=00 Prot=00 Driver=usbhid
E:  Ad=81(I) Atr=03(Int.) MxPS=  64 Ivl=20ms
E:  Ad=01(O) Atr=03(Int.) MxPS=  64 Ivl=10ms

… For testing with release 2, I will try to make time as this will be a disruption to my work. I will also test without the hub.

No difference removing hub. Messages in dmesg with unplug replug from different hub ports and finally direct plug in to the router:

[136888.450521] usbcore: registered new interface driver usbhid
[136888.450548] usbhid: USB HID core driver
[147386.839047] usb 1-1.3: USB disconnect, device number 3
[147388.613227] usb 1-1.2: new full-speed USB device number 4 using xhci-hcd
[147388.714879] usb 1-1.2: ep 0x81 - rounding interval to 128 microframes, ep desc says 160 microframes
[147388.714925] usb 1-1.2: ep 0x1 - rounding interval to 64 microframes, ep desc says 80 microframes
[147392.983055] usb 1-1.2: USB disconnect, device number 4
[147396.673245] usb 1-1.1: new full-speed USB device number 5 using xhci-hcd
[147396.774972] usb 1-1.1: ep 0x81 - rounding interval to 128 microframes, ep desc says 160 microframes
[147396.775019] usb 1-1.1: ep 0x1 - rounding interval to 64 microframes, ep desc says 80 microframes
[147402.711053] usb 1-1.1: USB disconnect, device number 5
[147406.263668] usb 2-1: USB disconnect, device number 2
[147406.263697] usb 2-1.4: USB disconnect, device number 3
[147406.353238] usb 1-1: USB disconnect, device number 2
[147409.853209] usb 1-1: new full-speed USB device number 6 using xhci-hcd
[147409.994862] usb 1-1: ep 0x81 - rounding interval to 128 microframes, ep desc says 160 microframes
[147409.994908] usb 1-1: ep 0x1 - rounding interval to 64 microframes, ep desc says 80 microframes

Yes i needed to install kmod-usb-hid to get it to work the first time. @hansome

@hansome i was finally able to make it work, I needed to modprobe hid-generic in addition to usbhid. I guess there’s no bug, or maybe the bug is in autoloading of modules.

Yes indeed, I found /etc/modules.d doesn’t have any entry for hid-generic and no symlink in /etc/modules-boot.d I think that’s the actual bug.

Maybe you removed it to save RAM.

For completion’s sake: Here’s a zip file containing dmesg and usb debug and lsusb -v with it working for future reference. I added modprobe hid-generic in /etc/rc.local

debug2.zip (14.2 KB)

1 Like

I test again the hid_generic is loaded automatically after installing kmod-hid-generic. Maybe the installation process the first time is not complete for network reasons. Glad you made it work.