diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-11-02 12:11:20 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-11-02 12:11:20 -0600 |
commit | 9c84d7131b36c9845454c10d3afcf6c4a60b8fa8 (patch) | |
tree | e91104cc8574bfcc6cb2a97f4e6de8c09f1ef4d3 /nuttx/arch | |
parent | 0a8c84a67af2815440f1df241f04a5072ad8407e (diff) | |
download | nuttx-9c84d7131b36c9845454c10d3afcf6c4a60b8fa8.tar.gz nuttx-9c84d7131b36c9845454c10d3afcf6c4a60b8fa8.tar.bz2 nuttx-9c84d7131b36c9845454c10d3afcf6c4a60b8fa8.zip |
MM: Minimum memory allocation must to up to 32 if sizeof pointer is 8-bytes
Diffstat (limited to 'nuttx/arch')
-rw-r--r-- | nuttx/arch/sim/include/limits.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/nuttx/arch/sim/include/limits.h b/nuttx/arch/sim/include/limits.h index 5a8d7c54e..fabb97d8e 100644 --- a/nuttx/arch/sim/include/limits.h +++ b/nuttx/arch/sim/include/limits.h @@ -77,10 +77,15 @@ #define LLONG_MAX 9223372036854775807LL #define ULLONG_MAX 18446744073709551615ULL -/* A pointer is 4 bytes */ +/* A pointer is 4 or 8 bytes */ #define PTR_MIN (-PTR_MAX - 1) -#define PTR_MAX 2147483647 -#define UPTR_MAX 4294967295U +#if !defined(CONFIG_HOST_X86_64) || defined(CONFIG_SIM_M32) +# define PTR_MAX 2147483647 +# define UPTR_MAX 4294967295U +#else +# define PTR_MAX 9223372036854775807LL +# define UPTR_MAX 18446744073709551615ULL +#endif #endif /* __ARCH_SIM_INCLUDE_LIMITS_H */ |