From e072751515d489b799c50b8c254367d4373403ee Mon Sep 17 00:00:00 2001 From: Marek Vasut Date: Fri, 29 Apr 2016 00:44:55 +0200 Subject: SPL: Add CONFIG_SPL_ABORT_ON_RAW_IMAGE When defined, SPL will proceed to another boot method if the image it has loaded does not have a signature. This is useful if the subsequent boot methods are much more complex. Signed-off-by: Marek Vasut Cc: Tom Rini Cc: Stefano Babic Cc: Peng Fan Cc: Fabio Estevam --- common/spl/spl.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'common/spl/spl.c') diff --git a/common/spl/spl.c b/common/spl/spl.c index 7259619..93f9bd1 100644 --- a/common/spl/spl.c +++ b/common/spl/spl.c @@ -111,6 +111,9 @@ int spl_parse_image_header(const struct image_header *header) * is bad, and thus should be skipped silently. */ panic("** no mkimage signature but raw image not supported"); +#elif defined(CONFIG_SPL_ABORT_ON_RAW_IMAGE) + /* Signature not found, proceed to other boot methods. */ + return -EINVAL; #else /* Signature not found - assume u-boot.bin */ debug("mkimage signature not found - ih_magic = %x\n", -- cgit v1.1