diff options
author | Zhang Wei <wei.zhang@freescale.com> | 2007-06-06 10:08:13 +0200 |
---|---|---|
committer | Markus Klotzbuecher <mk@pollux.denx.de> | 2007-06-06 10:08:13 +0200 |
commit | fdcfaa1b02268b2899e374b35adf936c911a47eb (patch) | |
tree | 7d0f9122da78789b93f1c2758c6e5e8c14867c76 /common/usb_kbd.c | |
parent | 9a1d00fa47c1e05e3fdb60b33213af4e18d4c18e (diff) |
USB event poll support
This patch adds USB event poll support, which could be used in usbkbd
and other usb devices driver when the asynchronous interrupt
processing is supported.
Signed-off-by: Zhang Wei <wei.zhang@freescale.com
Diffstat (limited to 'common/usb_kbd.c')
-rw-r--r-- | common/usb_kbd.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/common/usb_kbd.c b/common/usb_kbd.c index 56c21660fa0..aec558ad203 100644 --- a/common/usb_kbd.c +++ b/common/usb_kbd.c @@ -129,7 +129,11 @@ static int usb_kbd_testc(void) static int usb_kbd_getc(void) { char c; - while(usb_in_pointer==usb_out_pointer); + while(usb_in_pointer==usb_out_pointer) { +#ifdef CFG_USB_EVENT_POLL + usb_event_poll(); +#endif + } if((usb_out_pointer+1)==USB_KBD_BUFFER_LEN) usb_out_pointer=0; else |