]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/asm-sh/byteorder.h
sh: types: use <asm-generic/int-*.h> for the sh architecture
[linux-2.6-omap-h63xx.git] / include / asm-sh / byteorder.h
index 0eb9904b6545be3be0b7a99c6b258c25828fc2fa..4c13e61175632c3dc8f5a60712dda405eb177b66 100644 (file)
 static inline __attribute_const__ __u32 ___arch__swab32(__u32 x)
 {
        __asm__(
-#ifdef CONFIG_SUPERH32
+#ifdef __SH5__
+               "byterev        %0, %0\n\t"
+               "shari          %0, 32, %0"
+#else
                "swap.b         %0, %0\n\t"
                "swap.w         %0, %0\n\t"
                "swap.b         %0, %0"
-#else
-               "byterev        %0, %0\n\t"
-               "shari          %0, 32, %0"
 #endif
                : "=r" (x)
                : "0" (x));
@@ -28,12 +28,11 @@ static inline __attribute_const__ __u32 ___arch__swab32(__u32 x)
 static inline __attribute_const__ __u16 ___arch__swab16(__u16 x)
 {
        __asm__(
-#ifdef CONFIG_SUPERH32
-               "swap.b         %0, %0"
-#else
+#ifdef __SH5__
                "byterev        %0, %0\n\t"
                "shari          %0, 32, %0"
-
+#else
+               "swap.b         %0, %0"
 #endif
                : "=r" (x)
                :  "0" (x));