image: Avoid -ENODATA in host tools
Unfortunately -ENODATA is not available in OpenBSD. Use -EBADMSG
instead, to indicate a missing timestamp.
Fixes: c5819701a3d image: Adjust the workings of fit_check_format()
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Mark Kettenis <kettenis@openbsd.org>
diff --git a/common/image-fit.c b/common/image-fit.c
index 28b3d2b..94501b1 100644
--- a/common/image-fit.c
+++ b/common/image-fit.c
@@ -1651,7 +1651,7 @@
/* mandatory / node 'timestamp' property */
if (!fdt_getprop(fit, 0, FIT_TIMESTAMP_PROP, NULL)) {
log_debug("Wrong FIT format: no timestamp\n");
- return -ENODATA;
+ return -EBADMSG;
}
}