summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Howells2010-08-12 17:54:41 +0200
committerLinus Torvalds2010-08-12 18:51:35 +0200
commit3ad001c04f1ad21b87a7648450b53e7f04194f2a (patch)
tree7f3212be8095b0fedd3dc19b1267bbc394db48d2
parentMN10300: Fix RTC routines (diff)
downloadkernel-qcow2-linux-3ad001c04f1ad21b87a7648450b53e7f04194f2a.tar.gz
kernel-qcow2-linux-3ad001c04f1ad21b87a7648450b53e7f04194f2a.tar.xz
kernel-qcow2-linux-3ad001c04f1ad21b87a7648450b53e7f04194f2a.zip
MN10300: Fix size_t and ssize_t
With the newer compilers, size_t and ssize_t are expected to be (un)signed int rather than (un)signed long. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--arch/mn10300/include/asm/posix_types.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/arch/mn10300/include/asm/posix_types.h b/arch/mn10300/include/asm/posix_types.h
index 077567c37798..56ffbc158798 100644
--- a/arch/mn10300/include/asm/posix_types.h
+++ b/arch/mn10300/include/asm/posix_types.h
@@ -25,8 +25,13 @@ typedef int __kernel_pid_t;
typedef unsigned short __kernel_ipc_pid_t;
typedef unsigned short __kernel_uid_t;
typedef unsigned short __kernel_gid_t;
+#if __GNUC__ == 4
+typedef unsigned int __kernel_size_t;
+typedef signed int __kernel_ssize_t;
+#else
typedef unsigned long __kernel_size_t;
-typedef long __kernel_ssize_t;
+typedef signed long __kernel_ssize_t;
+#endif
typedef int __kernel_ptrdiff_t;
typedef long __kernel_time_t;
typedef long __kernel_suseconds_t;