2011-04-30 20:23:14

by Adi J. Sieker

[permalink] [raw]
Subject: USB keyboard recognized as HID keyboard but doesn't work

Hello,

the lovely folks from #kernelnewbies suggested I write this mail since
they are at a loss.
I recently got a new USB keyboard which works fine in the BIOS and also
in VBox Windows guests, but not on the host.

The keyboard is a Keysonic KSK-8003 UX product details here:
http://maxpoint.de/de/products/keyboards.php?pid=1_3_7&we_objectID=1220

The menu key and the backspace keys do work. The num lock led is on,
though I can't switch num lock off.
If I attch the keyboard to a VirtualBox VM running WindowsXP as a guest,
it works as expected in the VM.

I'm running 2.6.32-27-generic #49-Ubuntu. I tried the Ubuntu 10.10
LiveCD and that also didn't work. I haven't tried 11.04 yet though.

The output of lsusb -v is available here http://pastie.org/1851416

The relevant part of dmesg output:
[ 6.501902] input: KB USB Keyboard as
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/input/input9
[ 6.502028] generic-usb 0003:060B:0230.0001: input,hidraw0: USB HID
v1.10 Keyboard [KB USB Keyboard] on usb-0000:00:1d.0-1.3/input0
[ 6.503408] Bluetooth: Generic Bluetooth USB driver ver 0.6
[ 6.503508] usbcore: registered new interface driver btusb
[ 6.516681] generic-usb: probe of 0003:060B:0230.0002 failed with
error -22

I'd be grateful for any help and or pointers in the right to get this
keyboard to work.

Regards
Adi


2011-05-01 08:00:09

by Oliver Neukum

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

Am Samstag, 30. April 2011, 22:23:05 schrieb Adi J. Sieker:
> Hello,
>
> the lovely folks from #kernelnewbies suggested I write this mail since
> they are at a loss.
> I recently got a new USB keyboard which works fine in the BIOS and also
> in VBox Windows guests, but not on the host.
>
> The keyboard is a Keysonic KSK-8003 UX product details here:
> http://maxpoint.de/de/products/keyboards.php?pid=1_3_7&we_objectID=1220
>
> The menu key and the backspace keys do work. The num lock led is on,
> though I can't switch num lock off.
> If I attch the keyboard to a VirtualBox VM running WindowsXP as a guest,
> it works as expected in the VM.

This indicates that it is working on the USB level.

> I'm running 2.6.32-27-generic #49-Ubuntu. I tried the Ubuntu 10.10
> LiveCD and that also didn't work. I haven't tried 11.04 yet though.

Do you get anything on the event device? What does udev say when you
plug in the device?

Regards
Oliver

2011-05-01 17:49:10

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 01/05/11 09:53, Oliver Neukum wrote:
> Am Samstag, 30. April 2011, 22:23:05 schrieb Adi J. Sieker:
>> Hello,
>>
>> the lovely folks from #kernelnewbies suggested I write this mail since
>> they are at a loss.
>> I recently got a new USB keyboard which works fine in the BIOS and also
>> in VBox Windows guests, but not on the host.
>>
>> The keyboard is a Keysonic KSK-8003 UX product details here:
>> http://maxpoint.de/de/products/keyboards.php?pid=1_3_7&we_objectID=1220
>>
>> The menu key and the backspace keys do work. The num lock led is on,
>> though I can't switch num lock off.
>> If I attch the keyboard to a VirtualBox VM running WindowsXP as a guest,
>> it works as expected in the VM.
> This indicates that it is working on the USB level.
>
>> I'm running 2.6.32-27-generic #49-Ubuntu. I tried the Ubuntu 10.10
>> LiveCD and that also didn't work. I haven't tried 11.04 yet though.
> Do you get anything on the event device? What does udev say when you
> plug in the device?
>

udevadm monitor output is:
monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent

KERNEL[1304270944.379238] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3 (usb)
KERNEL[1304270944.380140] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0 (usb)
KERNEL[1304270944.380238] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/0003:060B:0230.0004
(hid)
KERNEL[1304270944.389434] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/input/input17
(input)
KERNEL[1304270944.389811] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/input/input17/event7
(input)
KERNEL[1304270944.389863] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/0003:060B:0230.0004/hidraw/hidraw0
(hidraw)
KERNEL[1304270944.389917] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.1 (usb)
KERNEL[1304270944.390031] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.1/0003:060B:0230.0005
(hid)
UDEV [1304270944.396889] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3 (usb)
UDEV [1304270944.398067] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.1 (usb)
UDEV [1304270944.398122] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0 (usb)
UDEV [1304270944.400048] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/0003:060B:0230.0004
(hid)
UDEV [1304270944.400947] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/0003:060B:0230.0004/hidraw/hidraw0
(hidraw)
UDEV [1304270944.401033] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.1/0003:060B:0230.0005
(hid)
UDEV [1304270944.408614] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/input/input17
(input)
UDEV [1304270944.415928] add
/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.3/2-1.3:1.0/input/input17/event7
(input)

one thing I found out is that this keyboard has some special anti
ghosting function for some keys. Where you can press multiple keys
simultaneously
and they are all recognized. This is apparently great for gaming. Which
I'm not interested in...

Cheers
Adi


--
Adi J. Sieker
Steurentalstr. 2
79252 Stegen
mobile: +49 / 178 / 88 5 88 13
tel: +49 / 7661 / 91 92 813
web: http://sieker.io/profile

2011-05-02 14:04:58

by Alan Stern

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Sun, 1 May 2011, Adi J. Sieker wrote:

> On 01/05/11 09:53, Oliver Neukum wrote:
> > Am Samstag, 30. April 2011, 22:23:05 schrieb Adi J. Sieker:
> >> Hello,
> >>
> >> the lovely folks from #kernelnewbies suggested I write this mail since
> >> they are at a loss.
> >> I recently got a new USB keyboard which works fine in the BIOS and also
> >> in VBox Windows guests, but not on the host.
> >>
> >> The keyboard is a Keysonic KSK-8003 UX product details here:
> >> http://maxpoint.de/de/products/keyboards.php?pid=1_3_7&we_objectID=1220
> >>
> >> The menu key and the backspace keys do work. The num lock led is on,
> >> though I can't switch num lock off.
> >> If I attch the keyboard to a VirtualBox VM running WindowsXP as a guest,
> >> it works as expected in the VM.
> > This indicates that it is working on the USB level.
> >
> >> I'm running 2.6.32-27-generic #49-Ubuntu. I tried the Ubuntu 10.10
> >> LiveCD and that also didn't work. I haven't tried 11.04 yet though.
> > Do you get anything on the event device? What does udev say when you
> > plug in the device?

...

> one thing I found out is that this keyboard has some special anti
> ghosting function for some keys. Where you can press multiple keys
> simultaneously
> and they are all recognized. This is apparently great for gaming. Which
> I'm not interested in...

Something else that might help is a usbmon trace showing what happens
when you plug in the keyboard. Instructions are in the kernel source
file Documentation/usb/usbmon.txt. In particular, while running the
test try pressing some of the normal keys that don't work.

Also, it would help to see the output from "lsusb -v" for this device
-- but you'll have to unbind it from the usbhid driver first.

Alan Stern

2011-05-02 19:35:34

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 02/05/11 16:04, Alan Stern wrote:
> On Sun, 1 May 2011, Adi J. Sieker wrote:
>
>> On 01/05/11 09:53, Oliver Neukum wrote:
>>> Am Samstag, 30. April 2011, 22:23:05 schrieb Adi J. Sieker:
>>>> Hello,
>>>>
>>>> the lovely folks from #kernelnewbies suggested I write this mail since
>>>> they are at a loss.
>>>> I recently got a new USB keyboard which works fine in the BIOS and also
>>>> in VBox Windows guests, but not on the host.
>>>>
>>>> The keyboard is a Keysonic KSK-8003 UX product details here:
>>>> http://maxpoint.de/de/products/keyboards.php?pid=1_3_7&we_objectID=1220
>>>>
>>>> The menu key and the backspace keys do work. The num lock led is on,
>>>> though I can't switch num lock off.
>>>> If I attch the keyboard to a VirtualBox VM running WindowsXP as a guest,
>>>> it works as expected in the VM.
>>> This indicates that it is working on the USB level.
>>>
>>>> I'm running 2.6.32-27-generic #49-Ubuntu. I tried the Ubuntu 10.10
>>>> LiveCD and that also didn't work. I haven't tried 11.04 yet though.
>>> Do you get anything on the event device? What does udev say when you
>>> plug in the device?
>
> ...
>
>> one thing I found out is that this keyboard has some special anti
>> ghosting function for some keys. Where you can press multiple keys
>> simultaneously
>> and they are all recognized. This is apparently great for gaming. Which
>> I'm not interested in...
>
> Something else that might help is a usbmon trace showing what happens
> when you plug in the keyboard. Instructions are in the kernel source
> file Documentation/usb/usbmon.txt. In particular, while running the
> test try pressing some of the normal keys that don't work.
>

The attached file usbmon-working.out is the output when I pressed the
backspace key. When I press any of the non working keys which is
everything but the backspace and menu key. I don't get any output even
when using 0u.

> Also, it would help to see the output from "lsusb -v" for this device
> -- but you'll have to unbind it from the usbhid driver first.
>

When attaching the keyboard I get 2 devices in
/sys/bus/usb/drivers/usbhid/2-1.1:1.0 and
/sys/bus/usb/drivers/usbhid/2-1.1:1.1

The output is in the attached lsusb.txt.

Cheers
Adi


Attachments:
lsusb.txt (12.30 kB)
usbmon-working.out (202.00 B)
Download all attachments

2011-05-02 20:27:30

by Alan Stern

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Mon, 2 May 2011, Adi J. Sieker wrote:

> > Something else that might help is a usbmon trace showing what happens
> > when you plug in the keyboard. Instructions are in the kernel source
> > file Documentation/usb/usbmon.txt. In particular, while running the
> > test try pressing some of the normal keys that don't work.
> >
>
> The attached file usbmon-working.out is the output when I pressed the
> backspace key. When I press any of the non working keys which is
> everything but the backspace and menu key. I don't get any output even
> when using 0u.

Sorry, I wasn't clear enough. I meant for you to start the usbmon
trace _before_ plugging in the keyboard, so we can see what happens as
the keyboard is initialized and probed.

> > Also, it would help to see the output from "lsusb -v" for this device
> > -- but you'll have to unbind it from the usbhid driver first.
> >
>
> When attaching the keyboard I get 2 devices in
> /sys/bus/usb/drivers/usbhid/2-1.1:1.0 and
> /sys/bus/usb/drivers/usbhid/2-1.1:1.1
>
> The output is in the attached lsusb.txt.

The output looks good. It doesn't mean much to me, but the people on
the linux-input mailing list should be able to get something out of it.

Alan Stern

2011-05-02 20:50:03

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 02/05/11 22:27, Alan Stern wrote:
> On Mon, 2 May 2011, Adi J. Sieker wrote:
>
>>> Something else that might help is a usbmon trace showing what happens
>>> when you plug in the keyboard. Instructions are in the kernel source
>>> file Documentation/usb/usbmon.txt. In particular, while running the
>>> test try pressing some of the normal keys that don't work.
>>>
>>
>> The attached file usbmon-working.out is the output when I pressed the
>> backspace key. When I press any of the non working keys which is
>> everything but the backspace and menu key. I don't get any output even
>> when using 0u.
>
> Sorry, I wasn't clear enough. I meant for you to start the usbmon
> trace _before_ plugging in the keyboard, so we can see what happens as
> the keyboard is initialized and probed.
>

You were clear enough, I just couldn't read. :)

Attached is the usbmon trace when I plug the keyboard in.

lsusb shows the keyboard as:
Bus 002 Device 008: ID 060b:0230 Solid Year

Relevant section from /sys/kernel/debug/usb/devices
T: Bus=02 Lev=02 Prnt=02 Port=00 Cnt=01 Dev#= 8 Spd=1.5 MxCh= 0
D: Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs= 1
P: Vendor=060b ProdID=0230 Rev= 2.20
S: Manufacturer=KB
S: Product=USB Keyboard
C:* #Ifs= 2 Cfg#= 1 Atr=a0 MxPwr=100mA
I:* If#= 0 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=01 Prot=01 Driver=usbhid
E: Ad=81(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
I:* If#= 1 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=00 Prot=00 Driver=usbhid
E: Ad=82(I) Atr=03(Int.) MxPS= 8 Ivl=10ms


Cheers
Adi


Attachments:
usbmon.out (3.59 kB)

2011-05-02 21:06:21

by Alan Stern

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Mon, 2 May 2011, Adi J. Sieker wrote:

> Attached is the usbmon trace when I plug the keyboard in.
>
> lsusb shows the keyboard as:
> Bus 002 Device 008: ID 060b:0230 Solid Year
>
> Relevant section from /sys/kernel/debug/usb/devices
> T: Bus=02 Lev=02 Prnt=02 Port=00 Cnt=01 Dev#= 8 Spd=1.5 MxCh= 0
> D: Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs= 1
> P: Vendor=060b ProdID=0230 Rev= 2.20
> S: Manufacturer=KB
> S: Product=USB Keyboard
> C:* #Ifs= 2 Cfg#= 1 Atr=a0 MxPwr=100mA
> I:* If#= 0 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=01 Prot=01 Driver=usbhid
> E: Ad=81(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
> I:* If#= 1 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=00 Prot=00 Driver=usbhid
> E: Ad=82(I) Atr=03(Int.) MxPS= 8 Ivl=10ms

Interestingly, the usbmon trace shows that the interrupt endpoint for
interface 1 isn't being used by usbhid. I don't know why, but it
shouldn't make much difference for your purposes since that interface
appears to be associated with the gaming interface. But maybe I'm
wrong and it is important somehow...

The other noticeable thing is that the keyboard didn't accept the
Set-Idle request for interface 1.

You said before that the keyboard worked okay when driven by a guest
Windows OS, right? Can you collect an equivalent usbmon trace for
that? Comparing the two traces may be instructive.

Alan Stern

2011-05-02 21:19:25

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 02/05/11 23:06, Alan Stern wrote:
> On Mon, 2 May 2011, Adi J. Sieker wrote:
>
>> Attached is the usbmon trace when I plug the keyboard in.
>>
>> lsusb shows the keyboard as:
>> Bus 002 Device 008: ID 060b:0230 Solid Year
>>
>> Relevant section from /sys/kernel/debug/usb/devices
>> T: Bus=02 Lev=02 Prnt=02 Port=00 Cnt=01 Dev#= 8 Spd=1.5 MxCh= 0
>> D: Ver= 1.10 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs= 1
>> P: Vendor=060b ProdID=0230 Rev= 2.20
>> S: Manufacturer=KB
>> S: Product=USB Keyboard
>> C:* #Ifs= 2 Cfg#= 1 Atr=a0 MxPwr=100mA
>> I:* If#= 0 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=01 Prot=01 Driver=usbhid
>> E: Ad=81(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
>> I:* If#= 1 Alt= 0 #EPs= 1 Cls=03(HID ) Sub=00 Prot=00 Driver=usbhid
>> E: Ad=82(I) Atr=03(Int.) MxPS= 8 Ivl=10ms
>
> Interestingly, the usbmon trace shows that the interrupt endpoint for
> interface 1 isn't being used by usbhid. I don't know why, but it
> shouldn't make much difference for your purposes since that interface
> appears to be associated with the gaming interface. But maybe I'm
> wrong and it is important somehow...
>
> The other noticeable thing is that the keyboard didn't accept the
> Set-Idle request for interface 1.
>
> You said before that the keyboard worked okay when driven by a guest
> Windows OS, right? Can you collect an equivalent usbmon trace for
> that? Comparing the two traces may be instructive.

I hope this is what you meant. :)
Attached is a usbmon trace when I attach the keyboard to a VBox VM
running a Windows XP guest. I have no idea how to get a USB trace from
within Windows. The last block is when I pressed h twice in the Windows
XP guest.

Cheers
Adi


Attachments:
usbmon-guest.out (4.47 kB)

2011-05-02 22:29:10

by Alan Stern

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Mon, 2 May 2011, Adi J. Sieker wrote:

> > Interestingly, the usbmon trace shows that the interrupt endpoint for
> > interface 1 isn't being used by usbhid. I don't know why, but it
> > shouldn't make much difference for your purposes since that interface
> > appears to be associated with the gaming interface. But maybe I'm
> > wrong and it is important somehow...
> >
> > The other noticeable thing is that the keyboard didn't accept the
> > Set-Idle request for interface 1.
> >
> > You said before that the keyboard worked okay when driven by a guest
> > Windows OS, right? Can you collect an equivalent usbmon trace for
> > that? Comparing the two traces may be instructive.
>
> I hope this is what you meant. :)
> Attached is a usbmon trace when I attach the keyboard to a VBox VM
> running a Windows XP guest. I have no idea how to get a USB trace from
> within Windows. The last block is when I pressed h twice in the Windows
> XP guest.

This is perfect. It shows that the H key is reported using the
interrupt endpoint on interface 1, which explains why it's not working
with usbhid. It also shows that the rejected Set-Idle request doesn't
matter.

At this point I don't know what the problem is, but now there's plenty
of information in the email thread for the people on linux-input to
debug this.

Alan Stern

2011-05-03 09:40:33

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 03/05/11 00:29, Alan Stern wrote:
> On Mon, 2 May 2011, Adi J. Sieker wrote:
>
>>> Interestingly, the usbmon trace shows that the interrupt endpoint for
>>> interface 1 isn't being used by usbhid. I don't know why, but it
>>> shouldn't make much difference for your purposes since that interface
>>> appears to be associated with the gaming interface. But maybe I'm
>>> wrong and it is important somehow...
>>>
>>> The other noticeable thing is that the keyboard didn't accept the
>>> Set-Idle request for interface 1.
>>>
>>> You said before that the keyboard worked okay when driven by a guest
>>> Windows OS, right? Can you collect an equivalent usbmon trace for
>>> that? Comparing the two traces may be instructive.
>>
>> I hope this is what you meant. :)
>> Attached is a usbmon trace when I attach the keyboard to a VBox VM
>> running a Windows XP guest. I have no idea how to get a USB trace from
>> within Windows. The last block is when I pressed h twice in the Windows
>> XP guest.
>
> This is perfect. It shows that the H key is reported using the
> interrupt endpoint on interface 1, which explains why it's not working
> with usbhid. It also shows that the rejected Set-Idle request doesn't
> matter.
>
Do you know of a way for me to tell the kernel/usbhid to use interface 1
and ignore interface 0?

Thanks
Adi

2011-05-03 13:49:15

by Alan Stern

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Tue, 3 May 2011, Adi J. Sieker wrote:

> Do you know of a way for me to tell the kernel/usbhid to use interface 1
> and ignore interface 0?

Well, you can always unbind interface 0 from usbhid -- it corresponds
to the 2-1.1:1.0 file in /sys/bus/usb/drivers/usbhid/. If you do that,
you'll probably find the few keys which _do_ currently work suddenly
stop working.

But there's nothing to be done immediately about interface 1; usbhid is
_already_ using it. It just isn't using it correctly.

Alan Stern

2011-05-06 12:58:18

by Jiri Kosina

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Tue, 3 May 2011, Alan Stern wrote:

> > Do you know of a way for me to tell the kernel/usbhid to use interface 1
> > and ignore interface 0?
>
> Well, you can always unbind interface 0 from usbhid -- it corresponds
> to the 2-1.1:1.0 file in /sys/bus/usb/drivers/usbhid/. If you do that,
> you'll probably find the few keys which _do_ currently work suddenly
> stop working.
>
> But there's nothing to be done immediately about interface 1; usbhid is
> _already_ using it. It just isn't using it correctly.

Adi,

could you please provide output of

cat /syse/kernel/debug/hid/<keyboard>/rdesc

anytime after the keyboard has been plugged, and

cat /syse/kernel/debug/hid/<keyboard>/events

from the time you press any of the working and non-working keys? (both
cases will be interesting).

Oh, and the above assumes that you have debugfs mounted under
/sys/kernel/debug.

Thanks,

--
Jiri Kosina
SUSE Labs

2011-05-06 13:59:44

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 06/05/11 14:58, Jiri Kosina wrote:
> On Tue, 3 May 2011, Alan Stern wrote:
>
>>> Do you know of a way for me to tell the kernel/usbhid to use interface 1
>>> and ignore interface 0?
>>
>> Well, you can always unbind interface 0 from usbhid -- it corresponds
>> to the 2-1.1:1.0 file in /sys/bus/usb/drivers/usbhid/. If you do that,
>> you'll probably find the few keys which _do_ currently work suddenly
>> stop working.
>>
>> But there's nothing to be done immediately about interface 1; usbhid is
>> _already_ using it. It just isn't using it correctly.
>
> Adi,
>
> could you please provide output of
>
> cat /syse/kernel/debug/hid/<keyboard>/rdesc
>
> anytime after the keyboard has been plugged, and

in /sys/kernel/debug/hid I have two devices for the keyboard. One is
0003:060B:0230.0002 and the other 0003:060B:0230.0003

attached are the rdesc files for both devices.

>
> cat /syse/kernel/debug/hid/<keyboard>/events
> from the time you press any of the working and non-working keys? (both
> cases will be interesting).

I only get events for the working keys on the *:0002 device.
All other files were empty after I pressed some keys.

The events for the working keys are attached in the *.events file.
I first pressed backspace and then the menu key.

Cheers
Adi


Attachments:
0003:060B:0230.0002.rdesc (8.86 kB)
0003:060B:0230.0002-working-keys.events (1.01 kB)
0003:060B:0230.0003.rdesc (769.00 B)
Download all attachments

2011-05-07 22:25:03

by Christoph Fritz

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Fri, 2011-05-06 at 15:59 +0200, Adi J. Sieker wrote:
> On 06/05/11 14:58, Jiri Kosina wrote:
> > On Tue, 3 May 2011, Alan Stern wrote:
> >
> >>> Do you know of a way for me to tell the kernel/usbhid to use interface 1
> >>> and ignore interface 0?
> >>
> >> Well, you can always unbind interface 0 from usbhid -- it corresponds
> >> to the 2-1.1:1.0 file in /sys/bus/usb/drivers/usbhid/. If you do that,
> >> you'll probably find the few keys which _do_ currently work suddenly
> >> stop working.
> >>
> >> But there's nothing to be done immediately about interface 1; usbhid is
> >> _already_ using it. It just isn't using it correctly.
> >
> > Adi,
> >
> > could you please provide output of
> >
> > cat /syse/kernel/debug/hid/<keyboard>/rdesc
> >
> > anytime after the keyboard has been plugged, and
>
> in /sys/kernel/debug/hid I have two devices for the keyboard. One is
> 0003:060B:0230.0002 and the other 0003:060B:0230.0003
>
> attached are the rdesc files for both devices.
>
> >
> > cat /syse/kernel/debug/hid/<keyboard>/events
> > from the time you press any of the working and non-working keys? (both
> > cases will be interesting).
>
> I only get events for the working keys on the *:0002 device.
> All other files were empty after I pressed some keys.
>
> The events for the working keys are attached in the *.events file.
> I first pressed backspace and then the menu key.

Hi Adi,

I'm not sure about my patch below because of interface one, maybe you
can give it a try.

Thanks,
-- chf

---
Subject: [PATCH] HID: add quirk for Solid Year keyboard ACK231

This patch adds HID_QUIRK_MULTI_INPUT to Solid Year keyboard ACK231
which reports keystrokes from inside a firmware-configuration
interface instead of using its own interface.

diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
index 00a94b5..abbace9 100644
--- a/drivers/hid/hid-ids.h
+++ b/drivers/hid/hid-ids.h
@@ -528,6 +528,9 @@
#define USB_VENDOR_ID_SKYCABLE 0x1223
#define USB_DEVICE_ID_SKYCABLE_WIRELESS_PRESENTER 0x3F07

+#define USB_VENDOR_ID_SOLIDYEAR 0x060b
+#define USB_DEVICE_ID_SOLIDYEAR_KEYBOARD_ACK231 0x0230
+
#define USB_VENDOR_ID_SONY 0x054c
#define USB_DEVICE_ID_SONY_VAIO_VGX_MOUSE 0x024b
#define USB_DEVICE_ID_SONY_PS3_CONTROLLER 0x0268
diff --git a/drivers/hid/usbhid/hid-quirks.c b/drivers/hid/usbhid/hid-quirks.c
index a8426f1..b099380 100644
--- a/drivers/hid/usbhid/hid-quirks.c
+++ b/drivers/hid/usbhid/hid-quirks.c
@@ -49,6 +49,7 @@
{ USB_VENDOR_ID_ETURBOTOUCH, USB_DEVICE_ID_ETURBOTOUCH, HID_QUIRK_MULTI_INPUT },
{ USB_VENDOR_ID_PANTHERLORD, USB_DEVICE_ID_PANTHERLORD_TWIN_USB_JOYSTICK, HID_QUIRK_MULTI_INPUT | HID_QUIRK_SKIP_OUTPUT_REPORTS },
{ USB_VENDOR_ID_PLAYDOTCOM, USB_DEVICE_ID_PLAYDOTCOM_EMS_USBII, HID_QUIRK_MULTI_INPUT },
+ { USB_VENDOR_ID_SOLIDYEAR, USB_DEVICE_ID_SOLIDYEAR_KEYBOARD_ACK231, HID_QUIRK_MULTI_INPUT },
{ USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS, HID_QUIRK_MULTI_INPUT },

{ USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_UC100KM, HID_QUIRK_NOGET },

2011-05-08 19:51:50

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 08/05/11 00:24, Christoph Fritz wrote:
> On Fri, 2011-05-06 at 15:59 +0200, Adi J. Sieker wrote:
>> On 06/05/11 14:58, Jiri Kosina wrote:
>>> On Tue, 3 May 2011, Alan Stern wrote:
>>>
>>>>> Do you know of a way for me to tell the kernel/usbhid to use interface 1
>>>>> and ignore interface 0?
>>>>
>>>> Well, you can always unbind interface 0 from usbhid -- it corresponds
>>>> to the 2-1.1:1.0 file in /sys/bus/usb/drivers/usbhid/. If you do that,
>>>> you'll probably find the few keys which _do_ currently work suddenly
>>>> stop working.
>>>>
>>>> But there's nothing to be done immediately about interface 1; usbhid is
>>>> _already_ using it. It just isn't using it correctly.
>>>
>>> Adi,
>>>
>>> could you please provide output of
>>>
>>> cat /syse/kernel/debug/hid/<keyboard>/rdesc
>>>
>>> anytime after the keyboard has been plugged, and
>>
>> in /sys/kernel/debug/hid I have two devices for the keyboard. One is
>> 0003:060B:0230.0002 and the other 0003:060B:0230.0003
>>
>> attached are the rdesc files for both devices.
>>
>>>
>>> cat /syse/kernel/debug/hid/<keyboard>/events
>> > from the time you press any of the working and non-working keys? (both
>> > cases will be interesting).
>>
>> I only get events for the working keys on the *:0002 device.
>> All other files were empty after I pressed some keys.
>>
>> The events for the working keys are attached in the *.events file.
>> I first pressed backspace and then the menu key.
>
> Hi Adi,
>
> I'm not sure about my patch below because of interface one, maybe you
> can give it a try.
>
What kernel version do I need? I'm running Ubuntu 10.04, so can I apply
this to a 2.6.32 Ubuntu kernel or do I need a current 2.6.39?

Any ideas if I'll run into problems if I run Ubuntu 10.04 on a 2.6.39
kernel.

Cheers
Adi

2011-05-08 21:34:27

by Christoph Fritz

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On Sun, May 08, 2011 at 09:51:42PM +0200, Adi J. Sieker wrote:
> On 08/05/11 00:24, Christoph Fritz wrote:
> >
> > I'm not sure about my patch below because of interface one, maybe you
> >can give it a try.
> >
> What kernel version do I need? I'm running Ubuntu 10.04, so can I
> apply this to a 2.6.32 Ubuntu kernel or do I need a current 2.6.39?

A current kernel is recommended.


bye,
-- chf

2011-05-10 08:24:24

by Adi J. Sieker

[permalink] [raw]
Subject: Re: USB keyboard recognized as HID keyboard but doesn't work

On 08/05/11 00:24, Christoph Fritz wrote:
> On Fri, 2011-05-06 at 15:59 +0200, Adi J. Sieker wrote:
>> On 06/05/11 14:58, Jiri Kosina wrote:
>>> On Tue, 3 May 2011, Alan Stern wrote:
>>>
>>>>> Do you know of a way for me to tell the kernel/usbhid to use interface 1
>>>>> and ignore interface 0?
>>>>
>>>> Well, you can always unbind interface 0 from usbhid -- it corresponds
>>>> to the 2-1.1:1.0 file in /sys/bus/usb/drivers/usbhid/. If you do that,
>>>> you'll probably find the few keys which _do_ currently work suddenly
>>>> stop working.
>>>>
>>>> But there's nothing to be done immediately about interface 1; usbhid is
>>>> _already_ using it. It just isn't using it correctly.
>>>
>>> Adi,
>>>
>>> could you please provide output of
>>>
>>> cat /syse/kernel/debug/hid/<keyboard>/rdesc
>>>
>>> anytime after the keyboard has been plugged, and
>>
>> in /sys/kernel/debug/hid I have two devices for the keyboard. One is
>> 0003:060B:0230.0002 and the other 0003:060B:0230.0003
>>
>> attached are the rdesc files for both devices.
>>
>>>
>>> cat /syse/kernel/debug/hid/<keyboard>/events
>> > from the time you press any of the working and non-working keys? (both
>> > cases will be interesting).
>>
>> I only get events for the working keys on the *:0002 device.
>> All other files were empty after I pressed some keys.
>>
>> The events for the working keys are attached in the *.events file.
>> I first pressed backspace and then the menu key.
>
> Hi Adi,
>
> I'm not sure about my patch below because of interface one, maybe you
> can give it a try.
>
Hi Christoph,

I haven't gotten around to compiling a new kernel yet.
Tzy-Jye Daniel Lin mentioned in a mail to me that adding
usbhid.quirks=0x060b:0x0230:0x0040 to the kernel command line
would achieve the same as the patch you posted.
I did try that on a 2.6.32 kernel and that didn't help.
I'll still generate a new kernel with your patch applied it's probably
going to take a couple of days though.

Cheers
Adi


the suppllied patch


> Thanks,
> -- chf
>
> ---
> Subject: [PATCH] HID: add quirk for Solid Year keyboard ACK231
>
> This patch adds HID_QUIRK_MULTI_INPUT to Solid Year keyboard ACK231
> which reports keystrokes from inside a firmware-configuration
> interface instead of using its own interface.
>
> diff --git a/drivers/hid/hid-ids.h b/drivers/hid/hid-ids.h
> index 00a94b5..abbace9 100644
> --- a/drivers/hid/hid-ids.h
> +++ b/drivers/hid/hid-ids.h
> @@ -528,6 +528,9 @@
> #define USB_VENDOR_ID_SKYCABLE 0x1223
> #define USB_DEVICE_ID_SKYCABLE_WIRELESS_PRESENTER 0x3F07
>
> +#define USB_VENDOR_ID_SOLIDYEAR 0x060b
> +#define USB_DEVICE_ID_SOLIDYEAR_KEYBOARD_ACK231 0x0230
> +
> #define USB_VENDOR_ID_SONY 0x054c
> #define USB_DEVICE_ID_SONY_VAIO_VGX_MOUSE 0x024b
> #define USB_DEVICE_ID_SONY_PS3_CONTROLLER 0x0268
> diff --git a/drivers/hid/usbhid/hid-quirks.c b/drivers/hid/usbhid/hid-quirks.c
> index a8426f1..b099380 100644
> --- a/drivers/hid/usbhid/hid-quirks.c
> +++ b/drivers/hid/usbhid/hid-quirks.c
> @@ -49,6 +49,7 @@
> { USB_VENDOR_ID_ETURBOTOUCH, USB_DEVICE_ID_ETURBOTOUCH, HID_QUIRK_MULTI_INPUT },
> { USB_VENDOR_ID_PANTHERLORD, USB_DEVICE_ID_PANTHERLORD_TWIN_USB_JOYSTICK, HID_QUIRK_MULTI_INPUT | HID_QUIRK_SKIP_OUTPUT_REPORTS },
> { USB_VENDOR_ID_PLAYDOTCOM, USB_DEVICE_ID_PLAYDOTCOM_EMS_USBII, HID_QUIRK_MULTI_INPUT },
> + { USB_VENDOR_ID_SOLIDYEAR, USB_DEVICE_ID_SOLIDYEAR_KEYBOARD_ACK231, HID_QUIRK_MULTI_INPUT },
> { USB_VENDOR_ID_TOUCHPACK, USB_DEVICE_ID_TOUCHPACK_RTS, HID_QUIRK_MULTI_INPUT },
>
> { USB_VENDOR_ID_ATEN, USB_DEVICE_ID_ATEN_UC100KM, HID_QUIRK_NOGET },
>
>