common: Kconfig.boot: Add FIT_PRINT config option
authorRavik Hasija <rahasij@linux.microsoft.com>
Wed, 27 Jan 2021 22:01:48 +0000 (14:01 -0800)
committerTom Rini <trini@konsulko.com>
Mon, 1 Feb 2021 21:32:06 +0000 (16:32 -0500)
Config allows to disable printing contents of fitImage to optimize boottime.

Signed-off-by: Ravik Hasija <rahasij@linux.microsoft.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
common/Kconfig.boot
common/image-fit.c

index 4525a12..5eaabdf 100644 (file)
@@ -140,6 +140,12 @@ config FIT_IMAGE_POST_PROCESS
          injected into the FIT creation (i.e. the blobs would have been pre-
          processed before being added to the FIT image).
 
+config FIT_PRINT
+        bool "Support FIT printing"
+        default y
+        help
+          Support printing the content of the fitImage in a verbose manner.
+
 if SPL
 
 config SPL_FIT
index 8660c3f..33210ef 100644 (file)
@@ -162,7 +162,7 @@ int fit_get_subimage_count(const void *fit, int images_noffset)
        return count;
 }
 
-#if !defined(CONFIG_SPL_BUILD) || defined(CONFIG_SPL_FIT_PRINT)
+#if CONFIG_IS_ENABLED(FIT_PRINT) || CONFIG_IS_ENABLED(SPL_FIT_PRINT)
 /**
  * fit_image_print_data() - prints out the hash node details
  * @fit: pointer to the FIT format image header
@@ -570,7 +570,7 @@ void fit_image_print(const void *fit, int image_noffset, const char *p)
 #else
 void fit_print_contents(const void *fit) { }
 void fit_image_print(const void *fit, int image_noffset, const char *p) { }
-#endif /* !defined(CONFIG_SPL_BUILD) || defined(CONFIG_SPL_FIT_PRINT) */
+#endif /* CONFIG_IS_ENABLED(FIR_PRINT) || CONFIG_IS_ENABLED(SPL_FIT_PRINT) */
 
 /**
  * fit_get_desc - get node description property