summaryrefslogtreecommitdiffstats
path: root/common/spl
diff options
context:
space:
mode:
authorMarek Vasut <marex@denx.de>2016-04-29 00:44:55 +0200
committerStefano Babic <sbabic@denx.de>2016-05-17 17:52:20 +0200
commite072751515d489b799c50b8c254367d4373403ee (patch)
treebfd2e1ee9bb84f8b774b0d9480b2c72e9857a501 /common/spl
parent7e0f22674ae871460706f9cc8653487bb51e0804 (diff)
downloadu-boot-e072751515d489b799c50b8c254367d4373403ee.tar.gz
u-boot-e072751515d489b799c50b8c254367d4373403ee.tar.xz
u-boot-e072751515d489b799c50b8c254367d4373403ee.zip
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 <marex@denx.de> Cc: Tom Rini <trini@konsulko.com> Cc: Stefano Babic <sbabic@denx.de> Cc: Peng Fan <van.freenix@gmail.com> Cc: Fabio Estevam <fabio.estevam@nxp.com>
Diffstat (limited to 'common/spl')
-rw-r--r--common/spl/spl.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/common/spl/spl.c b/common/spl/spl.c
index 7259619516..93f9bd13fc 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",