
Commit bac17b78dace ("image-fit: switch ENOLINK to ENOENT") changed fit_get_node_from_config to return -ENOENT when a property doesn't exist, but didn't change any of its callers which check return values. Notably it didn't change boot_get_ramdisk, which leads to U-Boot failing to boot FIT images which don't include ramdisks with the following message:
Ramdisk image is corrupt or invalid
The offending commit seems to dislike ENOLINK due to it not existing on OpenBSD, but I'm not sure why that matters as we define it in include/asm-generic/errno.h anyway so simply revert the commit to fix FIT image handling.
This reverts commit bac17b78dace ("image-fit: switch ENOLINK to ENOENT").
Signed-off-by: Paul Burton paul.burton@imgtec.com Cc: Jonathan Gray jsg@jsg.id.au
---
common/image-fit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/common/image-fit.c b/common/image-fit.c index 9ce68f1..f833fe3 100644 --- a/common/image-fit.c +++ b/common/image-fit.c @@ -1566,7 +1566,7 @@ int fit_get_node_from_config(bootm_headers_t *images, const char *prop_name, noffset = fit_conf_get_prop_node(fit_hdr, cfg_noffset, prop_name); if (noffset < 0) { debug("* %s: no '%s' in config\n", prop_name, prop_name); - return -ENOENT; + return -ENOLINK; }
return noffset;