summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorDavid S. Miller <davem@nuts.davemloft.net>2005-01-13 21:21:31 -0800
committerDavid S. Miller <davem@nuts.davemloft.net>2005-01-13 21:21:31 -0800
commit3ca3167cd074882f01bf45d9fa982aaa0ef998ce (patch)
tree80feb8969997bf60fcc6ec25b4833a4625c394c8 /include/linux
parent812ab7f31be1ebce3afdd3209c08b596903a9bef (diff)
parentdfdae3a1fb466b4145e053460a99dcd13abe115d (diff)
Merge bk://kernel.bkbits.net/acme/connection_sock-2.6
into nuts.davemloft.net:/disk1/BK/net-2.6
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/ipv6.h3
-rw-r--r--include/linux/udp.h22
2 files changed, 10 insertions, 15 deletions
diff --git a/include/linux/ipv6.h b/include/linux/ipv6.h
index 9d2999715321..f80c4b3f84a3 100644
--- a/include/linux/ipv6.h
+++ b/include/linux/ipv6.h
@@ -262,8 +262,7 @@ struct raw6_sock {
};
struct udp6_sock {
- struct inet_sock inet;
- struct udp_opt udp;
+ struct udp_sock udp;
struct ipv6_pinfo inet6;
};
diff --git a/include/linux/udp.h b/include/linux/udp.h
index 831a3f532a10..b60e0b4a25c4 100644
--- a/include/linux/udp.h
+++ b/include/linux/udp.h
@@ -40,26 +40,22 @@ struct udphdr {
#include <net/sock.h>
#include <linux/ip.h>
-struct udp_opt {
- int pending; /* Any pending frames ? */
- unsigned int corkflag; /* Cork is required */
- __u16 encap_type; /* Is this an Encapsulation socket? */
+struct udp_sock {
+ /* inet_sock has to be the first member */
+ struct inet_sock inet;
+ int pending; /* Any pending frames ? */
+ unsigned int corkflag; /* Cork is required */
+ __u16 encap_type; /* Is this an Encapsulation socket? */
/*
* Following member retains the infomation to create a UDP header
* when the socket is uncorked.
*/
- __u16 len; /* total length of pending frames */
-};
-
-/* WARNING: don't change the layout of the members in udp_sock! */
-struct udp_sock {
- struct inet_sock inet;
- struct udp_opt udp;
+ __u16 len; /* total length of pending frames */
};
-static inline struct udp_opt * udp_sk(const struct sock *__sk)
+static inline struct udp_sock *udp_sk(const struct sock *sk)
{
- return &((struct udp_sock *)__sk)->udp;
+ return (struct udp_sock *)sk;
}
#endif