summaryrefslogtreecommitdiffstats
path: root/sys/mips/include/_limits.h
diff options
context:
space:
mode:
authorjmallett <jmallett@FreeBSD.org>2010-04-16 23:54:56 +0000
committerjmallett <jmallett@FreeBSD.org>2010-04-16 23:54:56 +0000
commit1bf63ac57f7893887306e1ee448ae41287cff503 (patch)
tree8b63e5938c970141105ab8d711d60dfebea75500 /sys/mips/include/_limits.h
parent30418e2d5b795311d028a21d8348e55de9682a03 (diff)
downloadFreeBSD-src-1bf63ac57f7893887306e1ee448ae41287cff503.zip
FreeBSD-src-1bf63ac57f7893887306e1ee448ae41287cff503.tar.gz
Adjust limits and formats for ABIs with 64-bit longs.
Diffstat (limited to 'sys/mips/include/_limits.h')
-rw-r--r--sys/mips/include/_limits.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/sys/mips/include/_limits.h b/sys/mips/include/_limits.h
index d544305..e160a7f4 100644
--- a/sys/mips/include/_limits.h
+++ b/sys/mips/include/_limits.h
@@ -34,6 +34,10 @@
#ifndef _MACHINE__LIMITS_H_
#define _MACHINE__LIMITS_H_
+#if _MIPS_SZLONG == 64
+#define _LARGE_LONG
+#endif
+
/*
* According to ANSI (section 2.2.4.2), the values below must be usable by
* #if preprocessing directives. Additionally, the expression must have the
@@ -76,9 +80,9 @@
#define __LLONG_MAX 0x7fffffffffffffffLL /* max value for a long long */
#define __LLONG_MIN (-0x7fffffffffffffffLL - 1) /* min for a long long */
-#define __SSIZE_MAX __INT_MAX /* max value for a ssize_t */
+#define __SSIZE_MAX __LONG_MAX /* max value for a ssize_t */
-#define __SIZE_T_MAX __UINT_MAX /* max value for a size_t */
+#define __SIZE_T_MAX __ULONG_MAX /* max value for a size_t */
#define __OFF_MAX __LLONG_MAX /* max value for an off_t */
#define __OFF_MIN __LLONG_MIN /* min value for an off_t */
OpenPOWER on IntegriCloud