[PATCH 1/2] lib: fdt: define INT32_MAX for in-barebox use

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx>

The upcoming v1.5.1 version of libfdt adds a dependency on the C99
INT32_MAX symbol.
This is ok for use in the host tool, but libfdt can also be embedded
into barebox, where it would fail as we don't define this anywhere.

Fix this by providing an appropriate definition.

Reported-by: Rouven Czerwinski <r.czerwinski@xxxxxxxxxxxxxx>
Signed-off-by: Ahmad Fatoum <a.fatoum@xxxxxxxxxxxxxx>
---
 include/linux/libfdt_env.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/linux/libfdt_env.h b/include/linux/libfdt_env.h
index edb0f0c30904..bac4670d6d7e 100644
--- a/include/linux/libfdt_env.h
+++ b/include/linux/libfdt_env.h
@@ -16,4 +16,6 @@ typedef __be64 fdt64_t;
 #define fdt64_to_cpu(x) be64_to_cpu(x)
 #define cpu_to_fdt64(x) cpu_to_be64(x)
 
+#define INT32_MAX	2147483647
+
 #endif /* LIBFDT_ENV_H */
-- 
2.20.1


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux