summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/usb.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/common/usb.c b/common/usb.c
index 5f46831..87fca70 100644
--- a/common/usb.c
+++ b/common/usb.c
@@ -939,8 +939,10 @@ void usb_scan_devices(void)
dev_index = 0;
/* device 0 is always present (root hub, so let it analyze) */
dev = usb_alloc_new_device();
- usb_new_device(dev);
- printf("%d USB Device(s) found\n", dev_index);
+ if (usb_new_device(dev))
+ printf("No USB Device found\n");
+ else
+ printf("%d USB Device(s) found\n", dev_index);
/* insert "driver" if possible */
#ifdef CONFIG_USB_KEYBOARD
drv_usb_kbd_init();