mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Howells <dhowells@redhat.com>
To: torvalds@osdl.org, akpm@linux-foundation.org
Cc: linux-am33-list@redhat.com, linux-kernel@vger.kernel.org,
	David Howells <dhowells@redhat.com>
Subject: [PATCH 2/6] MN10300: Fix size_t and ssize_t
Date: Thu, 12 Aug 2010 16:54:41 +0100	[thread overview]
Message-ID: <20100812155441.17015.89963.stgit@warthog.procyon.org.uk> (raw)
In-Reply-To: <20100812155436.17015.78424.stgit@warthog.procyon.org.uk>

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>
---

 arch/mn10300/include/asm/posix_types.h |    7 ++++++-
 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 077567c..56ffbc1 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;


  reply	other threads:[~2010-08-12 15:55 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-12 15:54 [PATCH 1/6] MN10300: Fix RTC routines David Howells
2010-08-12 15:54 ` David Howells [this message]
2010-08-12 15:54 ` [PATCH 3/6] MN10300: Permit .GCC-command-line sections David Howells
2010-08-12 15:54 ` [PATCH 4/6] MN10300: Don't try and #include <linux/slab.h> in lib/inflate.c from bootloader David Howells
2010-08-12 15:54 ` [PATCH 5/6] Add a dummy printk function for the maintenance of unused printks David Howells
2010-08-12 15:55 ` [PATCH 6/6] MN10300: Use no_printk() for disabled gdbstub debugging functions David Howells

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100812155441.17015.89963.stgit@warthog.procyon.org.uk \
    --to=dhowells@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-am33-list@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome