diff options
author | Marek Szyprowski <m.szyprowski@samsung.com> | 2020-12-22 11:32:23 +0100 |
---|---|---|
committer | Marek Vasut <marex@denx.de> | 2021-01-31 14:08:56 +0100 |
commit | 9129f2f16488e95f8a71bb87937397aaf333bc1b (patch) | |
tree | 418451b37dd45ec8b6878d7a6f18b8170301e1cc /common | |
parent | c533f94c102127b94abda206dbe41fe026bcde76 (diff) | |
download | u-boot-9129f2f16488e95f8a71bb87937397aaf333bc1b.tar.gz |
dfu: add support for the dfu_alt_info reintialization from the flashed script
Reinitialize DFU USB gadget after flashing the 'SCRIPT' entity to ensure
that the potential changes to the 'dfu_alt_info' environment variable are
applied.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
[lukma - I've moved the bool retry to avoid build (CI) errors]
Diffstat (limited to 'common')
-rw-r--r-- | common/dfu.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/common/dfu.c b/common/dfu.c index d23cf67f19..16bd1ba588 100644 --- a/common/dfu.c +++ b/common/dfu.c @@ -98,6 +98,9 @@ int run_usb_dnl_gadget(int usbctrl_index, char *usb_dnl_gadget) } #endif + if (dfu_reinit_needed) + goto exit; + WATCHDOG_RESET(); usb_gadget_handle_interrupts(usbctrl_index); } |