]> git.sur5r.net Git - u-boot/blobdiff - common/usb_kbd.c
mips: Use the generic bitops headers
[u-boot] / common / usb_kbd.c
index 49bfc096e40904f03cdf978f37f040d81150fa65..0302e5bc933be8b3581f608b1f7fee19febd0878 100644 (file)
@@ -11,6 +11,7 @@
 #include <dm.h>
 #include <errno.h>
 #include <malloc.h>
+#include <memalign.h>
 #include <stdio_dev.h>
 #include <asm/byteorder.h>
 
@@ -460,10 +461,12 @@ static int usb_kbd_probe(struct usb_device *dev, unsigned int ifnum)
        /* We found a USB Keyboard, install it. */
        usb_set_protocol(dev, iface->desc.bInterfaceNumber, 0);
 
+       debug("USB KBD: found set idle...\n");
 #if !defined(CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP) && \
     !defined(CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE)
-       debug("USB KBD: found set idle...\n");
        usb_set_idle(dev, iface->desc.bInterfaceNumber, REPEAT_RATE / 4, 0);
+#else
+       usb_set_idle(dev, iface->desc.bInterfaceNumber, 0, 0);
 #endif
 
        debug("USB KBD: enable interrupt pipe...\n");
@@ -500,7 +503,7 @@ static int probe_usb_keyboard(struct usb_device *dev)
        debug("USB KBD: register.\n");
        memset(&usb_kbd_dev, 0, sizeof(struct stdio_dev));
        strcpy(usb_kbd_dev.name, DEVNAME);
-       usb_kbd_dev.flags =  DEV_FLAGS_INPUT | DEV_FLAGS_SYSTEM;
+       usb_kbd_dev.flags =  DEV_FLAGS_INPUT;
        usb_kbd_dev.getc = usb_kbd_getc;
        usb_kbd_dev.tstc = usb_kbd_testc;
        usb_kbd_dev.priv = (void *)dev;
@@ -538,8 +541,8 @@ int drv_usb_kbd_init(void)
        debug("%s: Probing for keyboard\n", __func__);
 #ifdef CONFIG_DM_USB
        /*
-        * TODO: We should add USB_DEVICE() declarations to each USB ethernet
-        * driver and then most of this file can be removed.
+        * TODO: We should add U_BOOT_USB_DEVICE() declarations to each USB
+        * keyboard driver and then most of this file can be removed.
         */
        struct udevice *bus;
        struct uclass *uc;