diff mbox

[U-Boot,01/14] mkimage: Honour the default image type with auto-fit

Message ID 1467305540-13607-2-git-send-email-sjg@chromium.org
State Accepted
Commit 20deaddd465aeab6f6939fb1b660622d763791a9
Delegated to: Tom Rini
Headers show

Commit Message

Simon Glass June 30, 2016, 4:52 p.m. UTC
The default image type is supposed to be IH_TYPE_KERNEL, as set in the
'params' variable. Honour this with auto-fit also.

Signed-off-by: Simon Glass <sjg@chromium.org>
---

 tools/mkimage.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Tom Rini July 2, 2016, 1:36 a.m. UTC | #1
On Thu, Jun 30, 2016 at 10:52:07AM -0600, Simon Glass wrote:

> The default image type is supposed to be IH_TYPE_KERNEL, as set in the
> 'params' variable. Honour this with auto-fit also.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>

Reviewed-by: Tom Rini <trini@konsulko.com>
Tom Rini July 16, 2016, 1:48 p.m. UTC | #2
On Thu, Jun 30, 2016 at 10:52:07AM -0600, Simon Glass wrote:

> The default image type is supposed to be IH_TYPE_KERNEL, as set in the
> 'params' variable. Honour this with auto-fit also.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>
> Reviewed-by: Tom Rini <trini@konsulko.com>

Applied to u-boot/master, thanks!
diff mbox

Patch

diff --git a/tools/mkimage.c b/tools/mkimage.c
index ff3024a..53fa8bb 100644
--- a/tools/mkimage.c
+++ b/tools/mkimage.c
@@ -272,7 +272,7 @@  static void process_args(int argc, char **argv)
 	 * will always be IH_TYPE_FLATDT in this case).
 	 */
 	if (params.type == IH_TYPE_FLATDT) {
-		params.fit_image_type = type;
+		params.fit_image_type = type ? type : IH_TYPE_KERNEL;
 		if (!params.auto_its)
 			params.datafile = datafile;
 	} else if (type != IH_TYPE_INVALID) {