mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: GOTO Masanori <gotom@debian.or.jp>
To: torvalds@osdl.org, akpm@osdl.org, linux-kernel@vger.kernel.org
Cc: gotom@debian.or.jp
Subject: [PATCH] headers 1/4: Enable ppc64 ___arch__swab16 and ___arch__swab32
Date: Mon, 20 Jun 2005 13:53:35 +0900	[thread overview]
Message-ID: <81mzpl7ho0.wl@omega.webmasters.gr.jp> (raw)

This patch cleans up asm-ppc64/byteorder.h to enable ___arch__swab16
and ___arch__swab32 which are marked TODO currently.  It removes
___arch__swab64 because ppc64 does not have short instruction
combinations for swab64, the recent gcc generates enough smart code
that is equivalent to hand assembled code under my tests.

Signed-off-by: GOTO Masanori <gotom@debian.or.jp>

Regards,
-- gotom


 byteorder.h |   10 ----------
 1 files changed, 10 deletions(-)

--- linux-2.6.12/include/asm-ppc64/byteorder.h	2005-06-18 04:48:29.000000000 +0900
+++ linux-2.6.12.gotom/include/asm-ppc64/byteorder.h	2005-06-20 13:11:43.049687818 +0900
@@ -40,7 +40,6 @@ static __inline__ void st_le32(volatile 
 	__asm__ __volatile__ ("stwbrx %1,0,%2" : "=m" (*addr) : "r" (val), "r" (addr));
 }
 
-#if 0
 static __inline__ __attribute_const__ __u16 ___arch__swab16(__u16 value)
 {
 	__u16 result;
@@ -63,17 +62,8 @@ static __inline__ __attribute_const__ __
 	return result;
 }
 
-static __inline__ __attribute_const__ __u64 ___arch__swab64(__u64 value)
-{
-	__u64 result;
-#error implement me
-}
-
 #define __arch__swab16(x) ___arch__swab16(x)
 #define __arch__swab32(x) ___arch__swab32(x)
-#define __arch__swab64(x) ___arch__swab64(x)
-
-#endif
 
 /* The same, but returns converted value from the location pointer by addr. */
 #define __arch__swab16p(addr) ld_le16(addr)

                 reply	other threads:[~2005-06-20  4:53 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=81mzpl7ho0.wl@omega.webmasters.gr.jp \
    --to=gotom@debian.or.jp \
    --cc=akpm@osdl.org \
    --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

all inboxes | Powered by JetHome®