aboutsummaryrefslogtreecommitdiff
path: root/common/usb_kbd.c
diff options
context:
space:
mode:
authorMichal Suchanek <msuchanek@suse.de>2019-08-18 10:55:27 +0200
committermarex <marex@chi.lan>2019-09-11 10:11:29 +0200
commit3437121c037f502a3b0faaec97059777034a1ead (patch)
tree37400fd4fb2ce3b28b7f82f0530dc4d7efad1307 /common/usb_kbd.c
parent50dce8fbf0c8b6f55e32c8d2d08ccf6e58168027 (diff)
downloadu-boot-3437121c037f502a3b0faaec97059777034a1ead.zip
u-boot-3437121c037f502a3b0faaec97059777034a1ead.tar.gz
u-boot-3437121c037f502a3b0faaec97059777034a1ead.tar.bz2
usb: Add nonblock argument to submit_int_msg
This will be used to implement non-blocking keyboard polling in case of errors. Signed-off-by: Michal Suchanek <msuchanek@suse.de>
Diffstat (limited to 'common/usb_kbd.c')
-rw-r--r--common/usb_kbd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/common/usb_kbd.c b/common/usb_kbd.c
index ebfd972..d178af2 100644
--- a/common/usb_kbd.c
+++ b/common/usb_kbd.c
@@ -341,7 +341,7 @@ static inline void usb_kbd_poll_for_event(struct usb_device *dev)
/* Submit a interrupt transfer request */
if (usb_int_msg(dev, data->intpipe, &data->new[0],
- data->intpktsize, data->intinterval) >= 0)
+ data->intpktsize, data->intinterval, true) >= 0)
usb_kbd_irq_worker(dev);
#elif defined(CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP) || \
defined(CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE)
@@ -505,7 +505,7 @@ static int usb_kbd_probe_dev(struct usb_device *dev, unsigned int ifnum)
1, 0, data->new, USB_KBD_BOOT_REPORT_SIZE) < 0) {
#else
if (usb_int_msg(dev, data->intpipe, data->new, data->intpktsize,
- data->intinterval) < 0) {
+ data->intinterval, false) < 0) {
#endif
printf("Failed to get keyboard state from device %04x:%04x\n",
dev->descriptor.idVendor, dev->descriptor.idProduct);