projects
/
oweals
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
common: Move do_tftpb() to net.h
[oweals/u-boot.git]
/
cmd
/
fastboot.c
diff --git
a/cmd/fastboot.c
b/cmd/fastboot.c
index ae3a5f627f117a9a92a462db5a132aa599649ac5..1b4215114d7e5d7e7393667f9b3365457fa07459 100644
(file)
--- a/
cmd/fastboot.c
+++ b/
cmd/fastboot.c
@@
-13,6
+13,7
@@
#include <fastboot.h>
#include <net.h>
#include <usb.h>
#include <fastboot.h>
#include <net.h>
#include <usb.h>
+#include <watchdog.h>
static int do_fastboot_udp(int argc, char *const argv[],
uintptr_t buf_addr, size_t buf_size)
static int do_fastboot_udp(int argc, char *const argv[],
uintptr_t buf_addr, size_t buf_size)
@@
-51,7
+52,7
@@
static int do_fastboot_usb(int argc, char *const argv[],
return CMD_RET_FAILURE;
}
return CMD_RET_FAILURE;
}
- ret =
board_usb_init(controller_index, USB_INIT_DEVICE
);
+ ret =
usb_gadget_initialize(controller_index
);
if (ret) {
pr_err("USB init failed: %d\n", ret);
return CMD_RET_FAILURE;
if (ret) {
pr_err("USB init failed: %d\n", ret);
return CMD_RET_FAILURE;
@@
-74,6
+75,7
@@
static int do_fastboot_usb(int argc, char *const argv[],
break;
if (ctrlc())
break;
break;
if (ctrlc())
break;
+ WATCHDOG_RESET();
usb_gadget_handle_interrupts(controller_index);
}
usb_gadget_handle_interrupts(controller_index);
}
@@
-82,7
+84,7
@@
static int do_fastboot_usb(int argc, char *const argv[],
exit:
g_dnl_unregister();
g_dnl_clear_detach();
exit:
g_dnl_unregister();
g_dnl_clear_detach();
-
board_usb_cleanup(controller_index, USB_INIT_DEVICE
);
+
usb_gadget_release(controller_index
);
return ret;
#else
return ret;
#else