diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2006-09-27 21:31:51 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2006-09-28 21:02:03 -0400 |
commit | 46a97324a5ebdc1e343a0223d993e79551adab0f (patch) | |
tree | 0d33307b5061a94a2d4324780263b72543e15cd7 /include/linux/tcp.h | |
parent | 63007727e0bb09e8d906f73d36a09b9fac0d5893 (diff) |
[IPV4]: TCP headers annotated
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/tcp.h')
-rw-r--r-- | include/linux/tcp.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/include/linux/tcp.h b/include/linux/tcp.h index 8ebf497907f8..543f06371840 100644 --- a/include/linux/tcp.h +++ b/include/linux/tcp.h | |||
@@ -21,10 +21,10 @@ | |||
21 | #include <asm/byteorder.h> | 21 | #include <asm/byteorder.h> |
22 | 22 | ||
23 | struct tcphdr { | 23 | struct tcphdr { |
24 | __u16 source; | 24 | __be16 source; |
25 | __u16 dest; | 25 | __be16 dest; |
26 | __u32 seq; | 26 | __be32 seq; |
27 | __u32 ack_seq; | 27 | __be32 ack_seq; |
28 | #if defined(__LITTLE_ENDIAN_BITFIELD) | 28 | #if defined(__LITTLE_ENDIAN_BITFIELD) |
29 | __u16 res1:4, | 29 | __u16 res1:4, |
30 | doff:4, | 30 | doff:4, |
@@ -50,9 +50,9 @@ struct tcphdr { | |||
50 | #else | 50 | #else |
51 | #error "Adjust your <asm/byteorder.h> defines" | 51 | #error "Adjust your <asm/byteorder.h> defines" |
52 | #endif | 52 | #endif |
53 | __u16 window; | 53 | __be16 window; |
54 | __u16 check; | 54 | __be16 check; |
55 | __u16 urg_ptr; | 55 | __be16 urg_ptr; |
56 | }; | 56 | }; |
57 | 57 | ||
58 | /* | 58 | /* |
@@ -62,7 +62,7 @@ struct tcphdr { | |||
62 | */ | 62 | */ |
63 | union tcp_word_hdr { | 63 | union tcp_word_hdr { |
64 | struct tcphdr hdr; | 64 | struct tcphdr hdr; |
65 | __u32 words[5]; | 65 | __be32 words[5]; |
66 | }; | 66 | }; |
67 | 67 | ||
68 | #define tcp_flag_word(tp) ( ((union tcp_word_hdr *)(tp))->words [3]) | 68 | #define tcp_flag_word(tp) ( ((union tcp_word_hdr *)(tp))->words [3]) |