0001
0002 #ifndef LIBFDT_ENV_H
0003 #define LIBFDT_ENV_H
0004
0005 #include <linux/limits.h> /* For INT_MAX */
0006 #include <linux/string.h>
0007
0008 #include <asm/byteorder.h>
0009
0010 #define INT32_MAX S32_MAX
0011 #define UINT32_MAX U32_MAX
0012
0013 typedef __be16 fdt16_t;
0014 typedef __be32 fdt32_t;
0015 typedef __be64 fdt64_t;
0016
0017 #define fdt32_to_cpu(x) be32_to_cpu(x)
0018 #define cpu_to_fdt32(x) cpu_to_be32(x)
0019 #define fdt64_to_cpu(x) be64_to_cpu(x)
0020 #define cpu_to_fdt64(x) cpu_to_be64(x)
0021
0022 #endif