]> www.infradead.org Git - mtd-utils.git/commitdiff
Fix swab32 to use standard types
authorJosh Boyer <jwboyer@gmail.com>
Wed, 21 Jun 2006 13:08:25 +0000 (08:08 -0500)
committerJosh Boyer <jwboyer@gmail.com>
Wed, 21 Jun 2006 13:08:25 +0000 (08:08 -0500)
Signed-off-by: Josh Boyer <jwboyer@gmail.com>
include/mtd_swab.h

index a5175dacaf1b74bf1e3755ff8d021482c91e41d7..5c76ed5dcb2434434a7ae74e323ef9496c814a65 100644 (file)
@@ -9,10 +9,10 @@
                 (((uint16_t)(x) & (uint16_t)0xff00U) >> 8) ))
 #define swab32(x) \
         ((uint32_t)( \
-                (((uint32_t)(x) & (__u32)0x000000ffUL) << 24) | \
-                (((uint32_t)(x) & (__u32)0x0000ff00UL) <<  8) | \
-                (((uint32_t)(x) & (__u32)0x00ff0000UL) >>  8) | \
-                (((uint32_t)(x) & (__u32)0xff000000UL) >> 24) ))
+                (((uint32_t)(x) & (uint32_t)0x000000ffUL) << 24) | \
+                (((uint32_t)(x) & (uint32_t)0x0000ff00UL) <<  8) | \
+                (((uint32_t)(x) & (uint32_t)0x00ff0000UL) >>  8) | \
+                (((uint32_t)(x) & (uint32_t)0xff000000UL) >> 24) ))
 
 #if __BYTE_ORDER == __BIG_ENDIAN
 #define cpu_to_le16(x) ({ uint16_t _x = x; swab16(_x); })