From: Paul Kocialkowski Date: Sat, 28 Mar 2015 17:22:49 +0000 (+0100) Subject: fastboot: Proper download gadget unregister and clear when cable is missing X-Git-Tag: v2015.07-rc1~346 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=a32d27912961040230320268d6cde80e9442dc33;p=u-boot fastboot: Proper download gadget unregister and clear when cable is missing Signed-off-by: Paul Kocialkowski --- diff --git a/common/cmd_fastboot.c b/common/cmd_fastboot.c index 30bfc9b709..d52ccfb310 100644 --- a/common/cmd_fastboot.c +++ b/common/cmd_fastboot.c @@ -23,6 +23,8 @@ static int do_fastboot(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[]) if (!g_dnl_board_usb_cable_connected()) { puts("\rUSB cable not detected.\n" \ "Command exit.\n"); + g_dnl_unregister(); + g_dnl_clear_detach(); return CMD_RET_FAILURE; }