diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2007-03-13 13:28:48 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-04-26 01:25:22 -0400 |
commit | 4bedb45203eab92a87b4c863fe2d0cded633427f (patch) | |
tree | d46e43d0a08253cf85ee2db64df6aee5e4ff5a07 /include/linux | |
parent | d9edf9e2be0f7661558984c32bd53867a7037fd3 (diff) |
[SK_BUFF]: Introduce udp_hdr(), remove skb->h.uh
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/skbuff.h | 1 | ||||
-rw-r--r-- | include/linux/udp.h | 9 |
2 files changed, 9 insertions, 1 deletions
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 0a4a7ac034fa..cb1ac48cc808 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h | |||
@@ -238,7 +238,6 @@ struct sk_buff { | |||
238 | 238 | ||
239 | union { | 239 | union { |
240 | struct tcphdr *th; | 240 | struct tcphdr *th; |
241 | struct udphdr *uh; | ||
242 | struct icmphdr *icmph; | 241 | struct icmphdr *icmph; |
243 | struct iphdr *ipiph; | 242 | struct iphdr *ipiph; |
244 | struct ipv6hdr *ipv6h; | 243 | struct ipv6hdr *ipv6h; |
diff --git a/include/linux/udp.h b/include/linux/udp.h index 7e08c07efe0f..1f58503af9a6 100644 --- a/include/linux/udp.h +++ b/include/linux/udp.h | |||
@@ -26,6 +26,15 @@ struct udphdr { | |||
26 | __sum16 check; | 26 | __sum16 check; |
27 | }; | 27 | }; |
28 | 28 | ||
29 | #ifdef __KERNEL__ | ||
30 | #include <linux/skbuff.h> | ||
31 | |||
32 | static inline struct udphdr *udp_hdr(const struct sk_buff *skb) | ||
33 | { | ||
34 | return (struct udphdr *)skb->h.raw; | ||
35 | } | ||
36 | #endif | ||
37 | |||
29 | /* UDP socket options */ | 38 | /* UDP socket options */ |
30 | #define UDP_CORK 1 /* Never send partially complete segments */ | 39 | #define UDP_CORK 1 /* Never send partially complete segments */ |
31 | #define UDP_ENCAP 100 /* Set the socket to accept encapsulated packets */ | 40 | #define UDP_ENCAP 100 /* Set the socket to accept encapsulated packets */ |