]> git.karo-electronics.de Git - karo-tx-uboot.git/blobdiff - common/cmd_usb_mass_storage.c
usb: dfu: fix boards wo USB cable detection
[karo-tx-uboot.git] / common / cmd_usb_mass_storage.c
index 5f557d5f857df2916cc5f818abbd8ac1b5e08b1c..14a5b6ae5ea1fcc9e855746a8f20a55f59e2a1b8 100644 (file)
@@ -45,10 +45,14 @@ int do_usb_mass_storage(cmd_tbl_t *cmdtp, int flag,
        /* Timeout unit: seconds */
        int cable_ready_timeout = UMS_CABLE_READY_TIMEOUT;
 
-       if (!usb_cable_connected()) {
+       if (!g_dnl_board_usb_cable_connected()) {
+               /*
+                * Won't execute if we don't know whether the cable is
+                * connected.
+                */
                puts("Please connect USB cable.\n");
 
-               while (!usb_cable_connected()) {
+               while (!g_dnl_board_usb_cable_connected()) {
                        if (ctrlc()) {
                                puts("\rCTRL+C - Operation aborted.\n");
                                goto exit;