aboutsummaryrefslogtreecommitdiff
path: root/common/cmd_dfu.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/cmd_dfu.c')
-rw-r--r--common/cmd_dfu.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/common/cmd_dfu.c b/common/cmd_dfu.c
index e975abebc9..857148f8af 100644
--- a/common/cmd_dfu.c
+++ b/common/cmd_dfu.c
@@ -9,6 +9,7 @@
*/
#include <common.h>
+#include <watchdog.h>
#include <dfu.h>
#include <g_dnl.h>
#include <usb.h>
@@ -64,10 +65,12 @@ static int do_dfu(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
if (ctrlc())
goto exit;
- usb_gadget_handle_interrupts();
+ WATCHDOG_RESET();
+ usb_gadget_handle_interrupts(controller_index);
}
exit:
g_dnl_unregister();
+ board_usb_cleanup(controller_index, USB_INIT_DEVICE);
done:
dfu_free_entities();