File: byteorder.patch

package info (click to toggle)
linux-kernel-headers 2.5.999-test7-bk-17
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 28,268 kB
  • ctags: 214,024
  • sloc: ansic: 324,929; cpp: 783; makefile: 79; asm: 61; sh: 61
file content (67 lines) | stat: -rw-r--r-- 2,073 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
diff -urp include.b/linux/byteorder/swab.h include/linux/byteorder/swab.h
--- include.b/linux/byteorder/swab.h	2003-11-21 19:42:21.000000000 -0500
+++ include/linux/byteorder/swab.h	2003-11-21 22:31:33.000000000 -0500
@@ -19,7 +19,7 @@
  * how U/UL/ULL map to __u16, __u32, __u64. At least not in a portable way.
  */
 #define ___swab16(x) \
-({ \
+__extension__ ({ \
 	__u16 __x = (x); \
 	((__u16)( \
 		(((__u16)(__x) & (__u16)0x00ffU) << 8) | \
@@ -27,7 +27,7 @@
 })
 
 #define ___swab32(x) \
-({ \
+__extension__ ({ \
 	__u32 __x = (x); \
 	((__u32)( \
 		(((__u32)(__x) & (__u32)0x000000ffUL) << 24) | \
@@ -37,7 +37,7 @@
 })
 
 #define ___swab64(x) \
-({ \
+__extension__ ({ \
 	__u64 __x = (x); \
 	((__u64)( \
 		(__u64)(((__u64)(__x) & (__u64)0x00000000000000ffULL) << 56) | \
@@ -75,13 +75,13 @@
  * provide defaults when no architecture-specific optimization is detected
  */
 #ifndef __arch__swab16
-#  define __arch__swab16(x) ({ __u16 __tmp = (x) ; ___swab16(__tmp); })
+#  define __arch__swab16(x) __extension__ ({ __u16 __tmp = (x) ; ___swab16(__tmp); })
 #endif
 #ifndef __arch__swab32
-#  define __arch__swab32(x) ({ __u32 __tmp = (x) ; ___swab32(__tmp); })
+#  define __arch__swab32(x) __extension__ ({ __u32 __tmp = (x) ; ___swab32(__tmp); })
 #endif
 #ifndef __arch__swab64
-#  define __arch__swab64(x) ({ __u64 __tmp = (x) ; ___swab64(__tmp); })
+#  define __arch__swab64(x) __extension__ ({ __u64 __tmp = (x) ; ___swab64(__tmp); })
 #endif
 
 #ifndef __arch__swab16p
diff -urp include.b/linux/byteorder/swabb.h include/linux/byteorder/swabb.h
--- include.b/linux/byteorder/swabb.h	2003-11-21 19:42:21.000000000 -0500
+++ include/linux/byteorder/swabb.h	2003-11-21 22:31:33.000000000 -0500
@@ -26,14 +26,14 @@
  */
 
 #define ___swahw32(x) \
-({ \
+__extension__ ({ \
 	__u32 __x = (x); \
 	((__u32)( \
 		(((__u32)(__x) & (__u32)0x0000ffffUL) << 16) | \
 		(((__u32)(__x) & (__u32)0xffff0000UL) >> 16) )); \
 })
 #define ___swahb32(x) \
-({ \
+__extension__ ({ \
 	__u32 __x = (x); \
 	((__u32)( \
 		(((__u32)(__x) & (__u32)0x00ff00ffUL) << 8) | \