Stefan Brüns wrote:
> On Freitag, 4. September 2020 17:43:37 CEST Ludwig Nussel wrote:
>> [...]
>> usb_kbd_probe_dev() USB KBD: found set idle...
>> usb_control_msg() usb_control_msg: request: 0xA, requesttype: 0x21,
>> value 0xA00 index 0x0 length 0x0
>> usb_kbd_probe_dev() USB KBD: enable interrupt pipe...
>> Timeout poll on interrupt endpoint
>> Failed to get keyboard state from device 1d6b:0104
>
> requesttype: 0x21 - Class specific request to interface
> request: 0xA - Set_Idle
> value: 0xA00 - 0xA * 4ms = 40ms report interval during idle, 0x0:
applies to
> all reports
>
> So according to the request, the OTG device should send report at regular
> intervals even without state changes, but the keyboard poll code times
out.

The discussion also reminded me of a USB-PS2 adapter that also doesn't
work in u-boot (bug#1167675). With your patch and LOG_DEBUG in
common/usb{_kbd,}.c:¹

usb_kbd_probe_dev() USB KBD: found interrupt EP: 0x81
usb_kbd_probe_dev() USB KBD: set boot protocol
usb_control_msg() usb_control_msg: request: 0xB, requesttype: 0x21,
value 0x0 index 0x0 length 0x0
usb_kbd_probe_dev() USB KBD: set idle interval...
usb_control_msg() usb_control_msg: request: 0xA, requesttype: 0x21,
value 0xA00 index 0x0 length 0x0
usb_kbd_probe_dev() USB KBD: enable interrupt pipe...
Timeout poll on interrupt endpoint
Failed to get keyboard state from device 04d9:1400

If that is the same problem then at least it's not Linux gadget code
specific but also affects actual hardware devices.

> Maybe an interval is not supported by the gadget code, while U-Boot
requires
> it. Would be interesting what a "Get_Idle" request returns.

How to get that information?

cu
Ludwig

[1] Would it be possible to have some easier way to enable verbose
debug logging in u-boot rather than branching and patching the
package in OBS? Would probably make it easier for people to
contribute useful debug output that don't want to deep dive into
u-boot :-)

-- 
 (o_   Ludwig Nussel
 //\
 V_/_  http://www.suse.com/
SUSE Software Solutions Germany GmbH, GF: Felix Imendörffer
HRB 36809 (AG Nürnberg)
-- 
To unsubscribe, e-mail: [email protected]
To contact the owner, e-mail: [email protected]

Reply via email to