USB error codes and usbmon

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kernel newbies community,

I'm writing a simple usb device implementation using PIC microcontroller 
and using USBMON to debug, i've properly receive the very first 
GET_DESCRIPTOR request and try to send the device descriptor to the host 
and it seems not to be working, but the USBMON and dmesg confuses me and 
don't know if the device isn't sending the descriptor or if it's 
corrupted or if the descriptor is ok but the device don't accept the 
address (not programmed yet in the device).

The USBMON output for the device (address 0) is:

ffff8801c3272480 1145843 S Ci:3:000:0 s 80 06 0100 0000 0040 64 <
ffff8801c3272480 2203609 C Ci:3:000:0 -32 0
ffff8801c3272480 2203652 S Ci:3:000:0 s 80 06 0100 0000 0040 64 <
ffff8801c3272480 2203728 C Ci:3:000:0 -71 0
ffff8801c3272480 2203827 S Ci:3:000:0 s 80 06 0100 0000 0040 64 <
ffff8801c3272480 2203952 C Ci:3:000:0 -71 0

The host request the device descriptor and asks for 64 bytes, from the 
device i (try to) send the descriptor but don't know what the "-32" and 
"-71" errors means, descriptor not received? descriptor bad constructed? 
neither?



the DMESG output is:

[ 3497.029992] usb 3-1.3: new full-speed USB device number 7 using 
xhci_hcd
[ 3498.154446] usb 3-1.3: device descriptor read/64, error -71
[ 3498.324591] usb 3-1.3: device descriptor read/64, error -71
[ 3498.494831] usb 3-1.3: new full-speed USB device number 8 using 
xhci_hcd
[ 3498.561500] usb 3-1.3: device descriptor read/64, error -71
[ 3498.731740] usb 3-1.3: device descriptor read/64, error -71
[ 3498.901870] usb 3-1.3: new full-speed USB device number 9 using 
xhci_hcd
[ 3498.902080] usb 3-1.3: Device not responding to setup address.
[ 3499.105555] usb 3-1.3: Device not responding to setup address.
[ 3499.308882] usb 3-1.3: device not accepting address 9, error -71
[ 3499.375759] usb 3-1.3: new full-speed USB device number 10 using 
xhci_hcd
[ 3499.375892] usb 3-1.3: Device not responding to setup address.
[ 3499.579423] usb 3-1.3: Device not responding to setup address.
[ 3499.782770] usb 3-1.3: device not accepting address 10, error -71
[ 3499.783035] usb 3-1-port3: unable to enumerate USB device


Here the "-71" error is used for both device descriptor read error and 
device not accepting address.

Is there a way to see what the host receives even if the data that is 
sent pretending to be the device descriptor is corrupted (for 
debugging)? and how can i know for sure what those errors tell me so i 
can start looking for the errors in my device code?

Any pointers are much appreciated. Greetings from Ecuador.

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux