}
} else if (fit_image_check_type(fit, noffset,
IH_TYPE_FIRMWARE)) {
- ret = dfu_write_by_name(fit_image_name, update_addr,
+ ret = dfu_write_by_name(fit_image_name,
+ (void *)update_addr,
update_size, interface,
devstring);
if (ret)
*
* Return: 0 - on success, error code - otherwise
*/
-int dfu_write_by_name(char *dfu_entity_name, unsigned int addr,
+int dfu_write_by_name(char *dfu_entity_name, void *addr,
unsigned int len, char *interface, char *devstring)
{
char *s, *sb;
int alt_setting_num, ret;
struct dfu_entity *dfu;
- debug("%s: name: %s addr: 0x%x len: %d device: %s:%s\n", __func__,
+ debug("%s: name: %s addr: 0x%p len: %d device: %s:%s\n", __func__,
dfu_entity_name, addr, len, interface, devstring);
ret = dfu_init_env_entities(interface, devstring);
goto done;
}
- ret = dfu_write_from_mem_addr(dfu, (void *)(uintptr_t)addr, len);
+ ret = dfu_write_from_mem_addr(dfu, (void *)addr, len);
done:
dfu_free_entities();
* Return: 0 - on success, error code - otherwise
*/
#if CONFIG_IS_ENABLED(DFU_WRITE_ALT)
-int dfu_write_by_name(char *dfu_entity_name, unsigned int addr,
+int dfu_write_by_name(char *dfu_entity_name, void *addr,
unsigned int len, char *interface, char *devstring);
#else
-static inline int dfu_write_by_name(char *dfu_entity_name, unsigned int addr,
+static inline int dfu_write_by_name(char *dfu_entity_name, void *addr,
unsigned int len, char *interface,
char *devstring)
{