summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--payloads/libpayload/include/armv7/arch/types.h4
-rw-r--r--payloads/libpayload/include/stdint.h8
-rw-r--r--payloads/libpayload/include/x86/arch/types.h4
3 files changed, 12 insertions, 4 deletions
diff --git a/payloads/libpayload/include/armv7/arch/types.h b/payloads/libpayload/include/armv7/arch/types.h
index d6f4aa8b66..bb4025714f 100644
--- a/payloads/libpayload/include/armv7/arch/types.h
+++ b/payloads/libpayload/include/armv7/arch/types.h
@@ -53,8 +53,8 @@ typedef signed long long s64;
typedef long time_t;
typedef long suseconds_t;
-typedef unsigned int size_t;
-typedef int ssize_t;
+typedef unsigned long size_t;
+typedef long ssize_t;
#ifndef NULL
#define NULL ((void *)0)
diff --git a/payloads/libpayload/include/stdint.h b/payloads/libpayload/include/stdint.h
index dd7439d788..966a1ed996 100644
--- a/payloads/libpayload/include/stdint.h
+++ b/payloads/libpayload/include/stdint.h
@@ -29,8 +29,16 @@
#ifndef __STDINT_H
#define __STDINT_H
+
#include <arch/types.h>
+typedef long long int intmax_t;
+typedef unsigned long long uintmax_t;
+
typedef unsigned long uintptr_t;
typedef long intptr_t;
+
+#define UINT32_MAX (4294967295U)
+#define UINT64_MAX (18446744073709551615ULL)
+
#endif
diff --git a/payloads/libpayload/include/x86/arch/types.h b/payloads/libpayload/include/x86/arch/types.h
index d6f4aa8b66..bb4025714f 100644
--- a/payloads/libpayload/include/x86/arch/types.h
+++ b/payloads/libpayload/include/x86/arch/types.h
@@ -53,8 +53,8 @@ typedef signed long long s64;
typedef long time_t;
typedef long suseconds_t;
-typedef unsigned int size_t;
-typedef int ssize_t;
+typedef unsigned long size_t;
+typedef long ssize_t;
#ifndef NULL
#define NULL ((void *)0)