summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2017-01-17 10:26:03 -0500
committerTom Rini <trini@konsulko.com>2017-01-17 10:26:03 -0500
commit373ae16c9282cf6dfb39cd6e1b8ad26098635ca2 (patch)
treec563331cc0b91eaefe5985ae0f560add51b79d93 /common
parentf253f2933b7373556329c0174dd5b101039a4056 (diff)
parent65c389d27902f6376bd057609b66b7339b219cf1 (diff)
downloadu-boot-imx-373ae16c9282cf6dfb39cd6e1b8ad26098635ca2.zip
u-boot-imx-373ae16c9282cf6dfb39cd6e1b8ad26098635ca2.tar.gz
u-boot-imx-373ae16c9282cf6dfb39cd6e1b8ad26098635ca2.tar.bz2
Merge branch 'master' of git://git.denx.de/u-boot-usb
Diffstat (limited to 'common')
-rw-r--r--common/usb_storage.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/common/usb_storage.c b/common/usb_storage.c
index 0345aa2..b524a15 100644
--- a/common/usb_storage.c
+++ b/common/usb_storage.c
@@ -303,7 +303,6 @@ void usb_stor_reset(void)
usb_max_devs = 0;
}
-#ifndef CONFIG_DM_USB
/*******************************************************************************
* scan the usb and reports device info
* to the user if mode = 1
@@ -311,11 +310,12 @@ void usb_stor_reset(void)
*/
int usb_stor_scan(int mode)
{
- unsigned char i;
-
if (mode == 1)
printf(" scanning usb for storage devices... ");
+#ifndef CONFIG_DM_USB
+ unsigned char i;
+
usb_disable_asynch(1); /* asynch transfer not allowed */
usb_stor_reset();
@@ -329,12 +329,12 @@ int usb_stor_scan(int mode)
} /* for */
usb_disable_asynch(0); /* asynch transfer allowed */
+#endif
printf("%d Storage Device(s) found\n", usb_max_devs);
if (usb_max_devs > 0)
return 0;
return -1;
}
-#endif
static int usb_stor_irq(struct usb_device *dev)
{