diff options
author | Hans de Goede <hdegoede@redhat.com> | 2016-04-03 09:18:53 +0200 |
---|---|---|
committer | Marek Vasut <marex@denx.de> | 2016-04-10 17:18:42 +0200 |
commit | 9a80e714350a959caadfd6e2405cd1f7e8ea86d3 (patch) | |
tree | a72b2511810053681941ed63be213f326f507220 /common | |
parent | cfb3f1cd0e022711d69ff040884357b8410865ef (diff) | |
download | u-boot-9a80e714350a959caadfd6e2405cd1f7e8ea86d3.zip u-boot-9a80e714350a959caadfd6e2405cd1f7e8ea86d3.tar.gz u-boot-9a80e714350a959caadfd6e2405cd1f7e8ea86d3.tar.bz2 |
usb: kbd: Do not deregister usbkbd twice when using dm
The dm usb_kbd_remove function() will deregister the usb keyboard for
us on a "usb reset" / "usb stop" so there is no need to manually call
usb_kbd_deregister() in the dm case.
This commit removes usb_kbd_deregister() in the dm case fixing the
following "usb reset" errors:
usb_kbd_remove: warning, ret=-6
device_remove: Device 'usb_kbd' failed to remove, but children are gone
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Diffstat (limited to 'common')
-rw-r--r-- | common/usb_kbd.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/common/usb_kbd.c b/common/usb_kbd.c index d84865f..97f79f8 100644 --- a/common/usb_kbd.c +++ b/common/usb_kbd.c @@ -566,7 +566,6 @@ int drv_usb_kbd_init(void) /* No USB Keyboard found */ return -1; } -#endif /* Deregister the keyboard. */ int usb_kbd_deregister(int force) @@ -599,6 +598,8 @@ int usb_kbd_deregister(int force) #endif } +#endif + #ifdef CONFIG_DM_USB static int usb_kbd_probe(struct udevice *dev) |