summaryrefslogtreecommitdiffstats
path: root/include/image.h
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2016-02-22 22:55:45 -0700
committerTom Rini <trini@konsulko.com>2016-03-14 19:18:26 -0400
commitaa34fbc087f246cbd83223bed499ca62694787d8 (patch)
tree2702c73e51f50fc822d347b629582f7232873f4d /include/image.h
parent70d41093c5d6d378a8e750d1829063890a3c7ca5 (diff)
downloadblackbird-obmc-uboot-aa34fbc087f246cbd83223bed499ca62694787d8.tar.gz
blackbird-obmc-uboot-aa34fbc087f246cbd83223bed499ca62694787d8.zip
fdt: Allow libfdt to be used in SPL
Add an option to enable libfdt in SPL. This can be useful when decoding FIT files in SPL. We need to make sure this option is not enabled in SPL by this change. Also this option needs to be enabled in host builds. Si add a new IMAGE_USE_LIBFDT #define which can be used in files that are built on the host but must also build for U-Boot and SPL. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/image.h')
-rw-r--r--include/image.h12
1 files changed, 4 insertions, 8 deletions
diff --git a/include/image.h b/include/image.h
index 02ca43bb89..b2fb3d90e0 100644
--- a/include/image.h
+++ b/include/image.h
@@ -26,7 +26,8 @@ struct lmb;
#include <sys/types.h>
/* new uImage format support enabled on host */
-#define IMAGE_ENABLE_FIT 1
+#define IMAGE_ENABLE_FIT 1
+#define IMAGE_ENABLE_OF_LIBFDT 1
#define CONFIG_FIT_VERBOSE 1 /* enable fit_format_{error,warning}() */
#define IMAGE_ENABLE_IGNORE 0
@@ -42,7 +43,8 @@ struct lmb;
#define IMAGE_ENABLE_IGNORE 1
#define IMAGE_INDENT_STRING " "
-#define IMAGE_ENABLE_FIT CONFIG_IS_ENABLED(FIT)
+#define IMAGE_ENABLE_FIT CONFIG_IS_ENABLED(FIT)
+#define IMAGE_ENABLE_OF_LIBFDT CONFIG_IS_ENABLED(OF_LIBFDT)
#endif /* USE_HOSTCC */
@@ -103,12 +105,6 @@ struct lmb;
# define IMAGE_ENABLE_RAMDISK_HIGH 0
#endif
-#ifdef CONFIG_OF_LIBFDT
-# define IMAGE_ENABLE_OF_LIBFDT 1
-#else
-# define IMAGE_ENABLE_OF_LIBFDT 0
-#endif
-
#ifdef CONFIG_SYS_BOOT_GET_CMDLINE
# define IMAGE_BOOT_GET_CMDLINE 1
#else
OpenPOWER on IntegriCloud