
Hi Lukasz,
On Sat, Jul 25, 2015 at 3:11 AM, Lukasz Majewski l.majewski@majess.pl wrote:
This code allows using DFU defined mediums for storing data received via TFTP protocol.
It reuses and preserves functionality of legacy code at common/update.c.
The update_tftp() function now accepts parameters - namely medium device name and its number (e.g. mmc 1).
Without this information passed old behavior is preserved.
Signed-off-by: Lukasz Majewski l.majewski@majess.pl
Changes for v2:
- Remove env variables from update_tftp() function
- Add parameters to update_tftp() function - without them old behavior is preserved
- Stop compilation when legacy flags (CONFIG_UPDATE_TFTP and CONFIG_SYS_NO_FLASH) are wrongly defined
- In the u-boot code legacy calls to update_tftp(0UL) have been changed to update_tftp(0UL, NULL, NULL)
common/Makefile | 1 + common/cmd_fitupd.c | 2 +- common/main.c | 2 +- common/update.c | 40 ++++++++++++++++++++++++++++++---------- include/net.h | 2 +- 5 files changed, 34 insertions(+), 13 deletions(-)
Address Simon's nits and then, Acked-by: Joe Hershberger joe.hershberger@ni.com
diff --git a/common/Makefile b/common/Makefile index d6c1d48..76626f1 100644 --- a/common/Makefile +++ b/common/Makefile @@ -208,6 +208,7 @@ obj-$(CONFIG_LYNXKDI) += lynxkdi.o obj-$(CONFIG_MENU) += menu.o obj-$(CONFIG_MODEM_SUPPORT) += modem.o obj-$(CONFIG_UPDATE_TFTP) += update.o +obj-$(CONFIG_DFU_TFTP) += update.o
Nice. That's much cleaner.
obj-$(CONFIG_USB_KEYBOARD) += usb_kbd.o obj-$(CONFIG_CMD_DFU) += cmd_dfu.o obj-$(CONFIG_CMD_GPT) += cmd_gpt.o