From: Dirk Eibach <dirk.eib...@gdsys.cc>

sha256 has some beefy memory footprint.
Make it optional for constrained systems.


Signed-off-by: Dirk Eibach <dirk.eib...@gdsys.cc>
---

Changes in v3: None
Changes in v2:
- make sha256 support optional

 include/configs/dlvision-10g.h | 1 +
 include/configs/io.h           | 1 +
 include/configs/iocon.h        | 1 +
 include/configs/neo.h          | 1 +
 include/image.h                | 5 +++++
 5 files changed, 9 insertions(+)

diff --git a/include/configs/dlvision-10g.h b/include/configs/dlvision-10g.h
index 2567a22..6153a40 100644
--- a/include/configs/dlvision-10g.h
+++ b/include/configs/dlvision-10g.h
@@ -40,6 +40,7 @@
 /* new uImage format support */
 #define CONFIG_FIT
 #define CONFIG_FIT_VERBOSE     /* enable fit_format_{error,warning}() */
+#define CONFIG_FIT_DISABLE_SHA256
 
 #define CONFIG_ENV_IS_IN_FLASH /* use FLASH for environment vars */
 
diff --git a/include/configs/io.h b/include/configs/io.h
index 649c0fb..8e32c25 100644
--- a/include/configs/io.h
+++ b/include/configs/io.h
@@ -40,6 +40,7 @@
 /* new uImage format support */
 #define CONFIG_FIT
 #define CONFIG_FIT_VERBOSE     /* enable fit_format_{error,warning}() */
+#define CONFIG_FIT_DISABLE_SHA256
 
 #define CONFIG_ENV_IS_IN_FLASH /* use FLASH for environment vars */
 
diff --git a/include/configs/iocon.h b/include/configs/iocon.h
index 35ba1bd..ae05bcb 100644
--- a/include/configs/iocon.h
+++ b/include/configs/iocon.h
@@ -39,6 +39,7 @@
 /* new uImage format support */
 #define CONFIG_FIT
 #define CONFIG_FIT_VERBOSE     /* enable fit_format_{error,warning}() */
+#define CONFIG_FIT_DISABLE_SHA256
 
 #define CONFIG_ENV_IS_IN_FLASH /* use FLASH for environment vars */
 
diff --git a/include/configs/neo.h b/include/configs/neo.h
index 75dc862..4937730 100644
--- a/include/configs/neo.h
+++ b/include/configs/neo.h
@@ -37,6 +37,7 @@
 /* new uImage format support */
 #define CONFIG_FIT
 #define CONFIG_FIT_VERBOSE     /* enable fit_format_{error,warning}() */
+#define CONFIG_FIT_DISABLE_SHA256
 
 #define CONFIG_ENV_IS_IN_FLASH /* use FLASH for environment vars */
 
diff --git a/include/image.h b/include/image.h
index b71e4ba..61d5885 100644
--- a/include/image.h
+++ b/include/image.h
@@ -72,6 +72,11 @@ struct lmb;
 #  define IMAGE_ENABLE_SHA256  1
 # endif
 
+#ifdef CONFIG_FIT_DISABLE_SHA256
+#undef CONFIG_SHA256
+#undef IMAGE_ENABLE_SHA256
+#endif
+
 #ifndef IMAGE_ENABLE_CRC32
 #define IMAGE_ENABLE_CRC32     0
 #endif
-- 
1.8.3

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to