X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;ds=inline;f=common%2Fcmd_ximg.c;h=d033c15b629cf2a88823bde658110dde23da2903;hb=9ca661642668ad833432a1f2f0086df5101ef48b;hp=ae2714d3728021bdc0d262f2bbe3b4cb54fcfe52;hpb=304f936aeaab0c3cc9d5af438fd3498ac7682991;p=u-boot diff --git a/common/cmd_ximg.c b/common/cmd_ximg.c index ae2714d372..d033c15b62 100644 --- a/common/cmd_ximg.c +++ b/common/cmd_ximg.c @@ -15,6 +15,7 @@ #include #include #include +#include #include #if defined(CONFIG_BZIP2) #include @@ -87,7 +88,8 @@ do_imgextract(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) image_print_contents(hdr); #endif - if (!image_check_type(hdr, IH_TYPE_MULTI)) { + if (!image_check_type(hdr, IH_TYPE_MULTI) && + !image_check_type(hdr, IH_TYPE_SCRIPT)) { printf("Wrong Image Type for %s command\n", cmdtp->name); return 1; @@ -247,6 +249,8 @@ do_imgextract(cmd_tbl_t * cmdtp, int flag, int argc, char * const argv[]) puts("OK\n"); } + flush_cache(dest, len); + setenv_hex("fileaddr", data); setenv_hex("filesize", len);