mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-22 07:01:39 +00:00
[new uImage] Compilation and new uImage handling fixes for imxtract
Fix imxtract command not being compiled-in despite CONFIG_CMD_XIMG being in include/config_cmd_default.h. Fix few warnings and handling of new format images. Signed-off-by: Bartlomiej Sieka <tur@semihalf.com>
This commit is contained in:
parent
36cc8cbb33
commit
fbe7a15502
1 changed files with 4 additions and 8 deletions
|
@ -24,7 +24,6 @@
|
||||||
* MA 02111-1307 USA
|
* MA 02111-1307 USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if defined(CONFIG_CMD_XIMG)
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Multi Image extract
|
* Multi Image extract
|
||||||
|
@ -40,13 +39,12 @@ do_imgextract(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
|
||||||
ulong addr = load_addr;
|
ulong addr = load_addr;
|
||||||
ulong dest = 0;
|
ulong dest = 0;
|
||||||
ulong data, len, count;
|
ulong data, len, count;
|
||||||
int i, verify;
|
int verify;
|
||||||
int part = 0;
|
int part = 0;
|
||||||
char pbuf[10];
|
char pbuf[10];
|
||||||
char *s;
|
|
||||||
image_header_t *hdr;
|
image_header_t *hdr;
|
||||||
#if defined(CONFIG_FIT)
|
#if defined(CONFIG_FIT)
|
||||||
const char *uname;
|
const char *uname = NULL;
|
||||||
const void* fit_hdr;
|
const void* fit_hdr;
|
||||||
int noffset;
|
int noffset;
|
||||||
const void *fit_data;
|
const void *fit_data;
|
||||||
|
@ -134,7 +132,7 @@ do_imgextract(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
|
||||||
}
|
}
|
||||||
|
|
||||||
/* get subimage node offset */
|
/* get subimage node offset */
|
||||||
noffset = fit_image_get_node (fit_hdr, fit_uname);
|
noffset = fit_image_get_node (fit_hdr, uname);
|
||||||
if (noffset < 0) {
|
if (noffset < 0) {
|
||||||
printf ("Can't find '%s' FIT subimage\n", uname);
|
printf ("Can't find '%s' FIT subimage\n", uname);
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -160,7 +158,7 @@ do_imgextract(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
data = (ulong *)fit_data;
|
data = (ulong)fit_data;
|
||||||
len = (ulong)fit_len;
|
len = (ulong)fit_len;
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
@ -190,5 +188,3 @@ U_BOOT_CMD(imxtract, 4, 1, do_imgextract,
|
||||||
" - extract <uname> subimage from FIT image at <addr> and copy to <dest>\n"
|
" - extract <uname> subimage from FIT image at <addr> and copy to <dest>\n"
|
||||||
#endif
|
#endif
|
||||||
);
|
);
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue