summaryrefslogtreecommitdiff
path: root/common/update.c
diff options
context:
space:
mode:
authorAKASHI Takahiro <takahiro.akashi@linaro.org>2020-10-29 13:47:41 +0900
committerHeinrich Schuchardt <xypron.glpk@gmx.de>2020-10-30 14:20:27 +0100
commit045fd8b13dc7b08a309043c28fc764c8fd2fde14 (patch)
tree3fe5fad33b5adfacd8b694659290631f3b18f029 /common/update.c
parent31393564462ac706c080fbd9625382540a41d27c (diff)
dfu: rename dfu_tftp_write() to dfu_write_by_name()
This function is essentially independent from tftp, and will also be utilised in implementing UEFI capsule update in a later commit. So just give it a more generic name. In addition, a new configuration option, CONFIG_DFU_WRITE_ALT, was introduced so that the file will be compiled with different options, particularly one added in a later commit. Signed-off-by: AKASHI Takahiro <takahiro.akashi@linaro.org> Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'common/update.c')
-rw-r--r--common/update.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/common/update.c b/common/update.c
index 36b6b7523d..39946776d7 100644
--- a/common/update.c
+++ b/common/update.c
@@ -324,8 +324,9 @@ got_update_file:
}
} else if (fit_image_check_type(fit, noffset,
IH_TYPE_FIRMWARE)) {
- ret = dfu_tftp_write(fit_image_name, update_addr,
- update_size, interface, devstring);
+ ret = dfu_write_by_name(fit_image_name, update_addr,
+ update_size, interface,
+ devstring);
if (ret)
return ret;
}