Hi all,
   I'm having trouble getting a few devices to work, and I'm not sure
where to go next. As far as I can tell, the usbhid driver attaches to
the device, but an event device never gets created.

This is kernel 3.3.8 on a wifi pineapple. The distro is based off
open-wrt (attitude-adjustment, the latest).
[    0.000000] CPU revision is: 00019374 (MIPS 24Kc)
[    0.000000] SoC: Atheros AR9330 rev 1

The device is a USB DragonRise Gamepad.

##########
# lsusb  -v -d 0079:

Bus 001 Device 011: ID 0079:0011 DragonRise Inc. Gamepad
Device Descriptor:
  bLength                18
  bDescriptorType         1
  bcdUSB               1.00
  bDeviceClass            0 (Defined at Interface level)
  bDeviceSubClass         0
  bDeviceProtocol         0
  bMaxPacketSize0         8
  idVendor           0x0079 DragonRise Inc.
  idProduct          0x0011 Gamepad
  bcdDevice            1.06
  iManufacturer           0
  iProduct                2 USB Gamepad
  iSerial                 0
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           34
    bNumInterfaces          1
    bConfigurationValue     1
    iConfiguration          0
    bmAttributes         0x80
      (Bus Powered)
    MaxPower              100mA
    Interface Descriptor:
      bLength                 9
      bDescriptorType         4
      bInterfaceNumber        0
      bAlternateSetting       0
      bNumEndpoints           1
      bInterfaceClass         3 Human Interface Device
      bInterfaceSubClass      0 No Subclass
      bInterfaceProtocol      0 None
      iInterface              0
        HID Device Descriptor:
          bLength                 9
          bDescriptorType        33
          bcdHID               1.10
          bCountryCode           33 US
          bNumDescriptors         1
          bDescriptorType        34 Report
          wDescriptorLength     101
         Report Descriptors:
           ** UNAVAILABLE **
      Endpoint Descriptor:
        bLength                 7
        bDescriptorType         5
        bEndpointAddress     0x81  EP 1 IN
        bmAttributes            3
          Transfer Type            Interrupt
          Synch Type               None
          Usage Type               Data
        wMaxPacketSize     0x0008  1x 8 bytes
        bInterval              10
Device Status:     0x0000
  (Bus Powered)
##########


Here's the verbose messages when it's inserted:
##########
[   78.710000] hub 1-1:1.0: state 7 ports 4 chg 0000 evt 0004
[   78.710000] hub 1-1:1.0: port 2, status 0301, change 0001, 1.5 Mb/s
[   78.870000] hub 1-1:1.0: debounce: port 2: total 100ms stable 100ms
status 0x301
[   78.950000] usb 1-1.2: new low-speed USB device number 6 using ehci-platform
[   78.970000] hub 1-1:1.0: port 2 not reset yet, waiting 10ms
[   79.080000] usb 1-1.2: skipped 1 descriptor after interface
[   79.080000] usb 1-1.2: default language 0x0409
[   79.080000] usb 1-1.2: udev 6, busnum 1, minor = 5
[   79.080000] usb 1-1.2: New USB device found, idVendor=0079, idProduct=0011
[   79.080000] usb 1-1.2: New USB device strings: Mfr=0, Product=2,
SerialNumber=0
[   79.090000] usb 1-1.2: Product: USB Gamepad
[   79.100000] usb 1-1.2: usb_probe_device
[   79.100000] usb 1-1.2: configuration #1 chosen from 1 choice
[   79.100000] usb 1-1.2: adding 1-1.2:1.0 (config #1, interface 0)
[   79.100000] usbserial_generic 1-1.2:1.0: usb_probe_interface
[   79.100000] usbserial_generic 1-1.2:1.0: usb_probe_interface - got id
[   79.100000] usbhid 1-1.2:1.0: usb_probe_interface
[   79.100000] usbhid 1-1.2:1.0: usb_probe_interface - got id
[   79.100000] drivers/usb/core/inode.c: creating file '006'
##########
and then nothing.


I have another similar device that works on the same system, and it
looks like the next thing that should happen is that an event device
gets created:
##########
[  272.630000] usbserial_generic 1-1.2:1.0: usb_probe_interface - got id
[  272.630000] usbhid 1-1.2:1.0: usb_probe_interface
[  272.630000] usbhid 1-1.2:1.0: usb_probe_interface - got id
[  272.650000] input: Saitek Cyborg USB Stick as
/devices/platform/ehci-platform/usb1/1-1/1-1.2/1-1.2:1.0/input/input0
[  272.660000] generic-usb 0003:06A3:0464.0003: input,hidraw0: USB HID
v1.00 Joystick [Saitek Cyborg USB Stick] on
usb-ehci-platform-1.2/input0
[  272.670000] drivers/usb/core/inode.c: creating file '009'
##########

I have made sure that support for my device is compiled in
(HID_DRAGONRISE kernel option). That module has the appropriate vendor
and device IDs that match my device. As far as I can tell, usbhid is
attaching to it just fine.

According to /proc/bus/usb/devices:
##########
T:  Bus=01 Lev=02 Prnt=02 Port=01 Cnt=02 Dev#= 11 Spd=1.5  MxCh= 0
D:  Ver= 1.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1
P:  Vendor=0079 ProdID=0011 Rev= 1.06
S:  Product=USB Gamepad
C:* #Ifs= 1 Cfg#= 1 Atr=80 MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=03(HID  ) Sub=00 Prot=00 Driver=usbhid
E:  Ad=81(I) Atr=03(Int.) MxPS=   8 Ivl=10ms
##########

As a side note, I cannot also get a Sony PS3 controller or a MS
Xbox360 controller working (both over USB, and both which should end
up with event devices). Support for both is enabled in my modules. No
idea if it's related or not, but the symptoms are the same (usbhid
attaches, but no event device is created)

I feel like I'm missing the link between the input-evdev module and
the usbhid driver. Does anyone have any suggestions on where I should
head next on this?

Here's the root hub:
##########

[    8.510000] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    8.510000] ehci_hcd: block sizes: qh 64 qtd 96 itd 160 sitd 96
[    8.510000] ehci-platform ehci-platform: Generic Platform EHCI Controller
[    8.520000] drivers/usb/core/inode.c: creating file 'devices'
[    8.520000] drivers/usb/core/inode.c: creating file '001'
[    8.520000] ehci-platform ehci-platform: new USB bus registered,
assigned bus number 1
[    8.530000] ehci-platform ehci-platform: reset hcs_params 0x10011
dbg=0 ind cc=0 pcc=0 ordered ports=1
[    8.530000] ehci-platform ehci-platform: reset hcc_params 0006
thresh 0 uframes 256/512/1024 park
[    8.530000] ehci-platform ehci-platform: park 0
[    8.530000] ehci-platform ehci-platform: reset command 0080002
(park)=0 ithresh=8 period=1024 Reset HALT
[    8.530000] ehci-platform ehci-platform: ...powerdown ports...
[    8.560000] ehci-platform ehci-platform: irq 3, io mem 0x1b000000
[    8.560000] ehci-platform ehci-platform: init command 0010005
(park)=0 ithresh=1 period=512 RUN
[    8.580000] ehci-platform ehci-platform: USB 2.0 started, EHCI 1.00
[    8.580000] usb usb1: default language 0x0409
[    8.580000] usb usb1: udev 1, busnum 1, minor = 0
[    8.580000] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    8.590000] usb usb1: New USB device strings: Mfr=3, Product=2,
SerialNumber=1
[    8.590000] usb usb1: Product: Generic Platform EHCI Controller
[    8.600000] usb usb1: Manufacturer: Linux 3.3.8 ehci_hcd
[    8.610000] usb usb1: SerialNumber: ehci-platform
[    8.610000] usb usb1: usb_probe_device
[    8.610000] usb usb1: configuration #1 chosen from 1 choice
[    8.610000] usb usb1: adding 1-0:1.0 (config #1, interface 0)

[    8.670000] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    8.670000] ohci_hcd: block sizes: ed 64 td 64
[    8.720000] ehci-platform ehci-platform: GetStatus port:1 status
10001803 8  ACK POWER sig=j CSC CONNECT
[    8.720000] hub 1-0:1.0: port 1: status 0101 change 0001
[    8.820000] hub 1-0:1.0: state 7 ports 1 chg 0002 evt 0000
[    8.820000] hub 1-0:1.0: port 1, status 0101, change 0000, 12 Mb/s
[    8.820000] uhci_hcd: USB Universal Host Controller Interface driver
[    8.880000] ehci-platform ehci-platform: port 1 high speed


# lsusb  -v -d 1d6b:
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 Unused
  bDeviceProtocol         1 Single TT
  bMaxPacketSize0        64
  idVendor           0x1d6b Linux Foundation
  idProduct          0x0002 2.0 root hub
  bcdDevice            3.03
  iManufacturer           3 Linux 3.3.8 ehci_hcd
  iProduct                2 Generic Platform EHCI Controller
  iSerial                 1 ehci-platform
  bNumConfigurations      1
  Configuration Descriptor:
    bLength                 9
    bDescriptorType         2
    wTotalLength           25
    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 Unused
      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             1
  wHubCharacteristic 0x0009
    Per-port power switching
    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.0503 highspeed power enable connect
Device Status:     0x0001
  Self Powered
##########

--Doug
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to