diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-09-18 14:02:26 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-09-18 14:02:26 -0400 |
commit | b0e7031ac08fa0aa242531c8d9a0cf9ae8ee276d (patch) | |
tree | 86ae983c51b9df07ead6f00aeddbf276f672c839 /include/net | |
parent | 01a7143586f51f80e1b29ebf240c6e5390657450 (diff) | |
parent | 8e2ec639173f325977818c45011ee176ef2b11f6 (diff) |
Merge git://github.com/davem330/net
* git://github.com/davem330/net: (62 commits)
ipv6: don't use inetpeer to store metrics for routes.
can: ti_hecc: include linux/io.h
IRDA: Fix global type conflicts in net/irda/irsysctl.c v2
net: Handle different key sizes between address families in flow cache
net: Align AF-specific flowi structs to long
ipv4: Fix fib_info->fib_metrics leak
caif: fix a potential NULL dereference
sctp: deal with multiple COOKIE_ECHO chunks
ibmveth: Fix checksum offload failure handling
ibmveth: Checksum offload is always disabled
ibmveth: Fix issue with DMA mapping failure
ibmveth: Fix DMA unmap error
pch_gbe: support ML7831 IOH
pch_gbe: added the process of FIFO over run error
pch_gbe: fixed the issue which receives an unnecessary packet.
sfc: Use 64-bit writes for TX push where possible
Revert "sfc: Use write-combining to reduce TX latency" and follow-ups
bnx2x: Fix ethtool advertisement
bnx2x: Fix 578xx link LED
bnx2x: Fix XMAC loopback test
...
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/flow.h | 25 | ||||
-rw-r--r-- | include/net/request_sock.h | 3 | ||||
-rw-r--r-- | include/net/sctp/command.h | 1 | ||||
-rw-r--r-- | include/net/tcp.h | 3 | ||||
-rw-r--r-- | include/net/transp_v6.h | 1 |
5 files changed, 29 insertions, 4 deletions
diff --git a/include/net/flow.h b/include/net/flow.h index 78113daadd63..a09447749e2d 100644 --- a/include/net/flow.h +++ b/include/net/flow.h | |||
@@ -7,6 +7,7 @@ | |||
7 | #ifndef _NET_FLOW_H | 7 | #ifndef _NET_FLOW_H |
8 | #define _NET_FLOW_H | 8 | #define _NET_FLOW_H |
9 | 9 | ||
10 | #include <linux/socket.h> | ||
10 | #include <linux/in6.h> | 11 | #include <linux/in6.h> |
11 | #include <linux/atomic.h> | 12 | #include <linux/atomic.h> |
12 | 13 | ||
@@ -68,7 +69,7 @@ struct flowi4 { | |||
68 | #define fl4_ipsec_spi uli.spi | 69 | #define fl4_ipsec_spi uli.spi |
69 | #define fl4_mh_type uli.mht.type | 70 | #define fl4_mh_type uli.mht.type |
70 | #define fl4_gre_key uli.gre_key | 71 | #define fl4_gre_key uli.gre_key |
71 | }; | 72 | } __attribute__((__aligned__(BITS_PER_LONG/8))); |
72 | 73 | ||
73 | static inline void flowi4_init_output(struct flowi4 *fl4, int oif, | 74 | static inline void flowi4_init_output(struct flowi4 *fl4, int oif, |
74 | __u32 mark, __u8 tos, __u8 scope, | 75 | __u32 mark, __u8 tos, __u8 scope, |
@@ -112,7 +113,7 @@ struct flowi6 { | |||
112 | #define fl6_ipsec_spi uli.spi | 113 | #define fl6_ipsec_spi uli.spi |
113 | #define fl6_mh_type uli.mht.type | 114 | #define fl6_mh_type uli.mht.type |
114 | #define fl6_gre_key uli.gre_key | 115 | #define fl6_gre_key uli.gre_key |
115 | }; | 116 | } __attribute__((__aligned__(BITS_PER_LONG/8))); |
116 | 117 | ||
117 | struct flowidn { | 118 | struct flowidn { |
118 | struct flowi_common __fl_common; | 119 | struct flowi_common __fl_common; |
@@ -127,7 +128,7 @@ struct flowidn { | |||
127 | union flowi_uli uli; | 128 | union flowi_uli uli; |
128 | #define fld_sport uli.ports.sport | 129 | #define fld_sport uli.ports.sport |
129 | #define fld_dport uli.ports.dport | 130 | #define fld_dport uli.ports.dport |
130 | }; | 131 | } __attribute__((__aligned__(BITS_PER_LONG/8))); |
131 | 132 | ||
132 | struct flowi { | 133 | struct flowi { |
133 | union { | 134 | union { |
@@ -161,6 +162,24 @@ static inline struct flowi *flowidn_to_flowi(struct flowidn *fldn) | |||
161 | return container_of(fldn, struct flowi, u.dn); | 162 | return container_of(fldn, struct flowi, u.dn); |
162 | } | 163 | } |
163 | 164 | ||
165 | typedef unsigned long flow_compare_t; | ||
166 | |||
167 | static inline size_t flow_key_size(u16 family) | ||
168 | { | ||
169 | switch (family) { | ||
170 | case AF_INET: | ||
171 | BUILD_BUG_ON(sizeof(struct flowi4) % sizeof(flow_compare_t)); | ||
172 | return sizeof(struct flowi4) / sizeof(flow_compare_t); | ||
173 | case AF_INET6: | ||
174 | BUILD_BUG_ON(sizeof(struct flowi6) % sizeof(flow_compare_t)); | ||
175 | return sizeof(struct flowi6) / sizeof(flow_compare_t); | ||
176 | case AF_DECnet: | ||
177 | BUILD_BUG_ON(sizeof(struct flowidn) % sizeof(flow_compare_t)); | ||
178 | return sizeof(struct flowidn) / sizeof(flow_compare_t); | ||
179 | } | ||
180 | return 0; | ||
181 | } | ||
182 | |||
164 | #define FLOW_DIR_IN 0 | 183 | #define FLOW_DIR_IN 0 |
165 | #define FLOW_DIR_OUT 1 | 184 | #define FLOW_DIR_OUT 1 |
166 | #define FLOW_DIR_FWD 2 | 185 | #define FLOW_DIR_FWD 2 |
diff --git a/include/net/request_sock.h b/include/net/request_sock.h index 99e6e19b57c2..4c0766e201e3 100644 --- a/include/net/request_sock.h +++ b/include/net/request_sock.h | |||
@@ -96,7 +96,8 @@ extern int sysctl_max_syn_backlog; | |||
96 | */ | 96 | */ |
97 | struct listen_sock { | 97 | struct listen_sock { |
98 | u8 max_qlen_log; | 98 | u8 max_qlen_log; |
99 | /* 3 bytes hole, try to use */ | 99 | u8 synflood_warned; |
100 | /* 2 bytes hole, try to use */ | ||
100 | int qlen; | 101 | int qlen; |
101 | int qlen_young; | 102 | int qlen_young; |
102 | int clock_hand; | 103 | int clock_hand; |
diff --git a/include/net/sctp/command.h b/include/net/sctp/command.h index 6506458ccd33..712b3bebeda7 100644 --- a/include/net/sctp/command.h +++ b/include/net/sctp/command.h | |||
@@ -109,6 +109,7 @@ typedef enum { | |||
109 | SCTP_CMD_SEND_MSG, /* Send the whole use message */ | 109 | SCTP_CMD_SEND_MSG, /* Send the whole use message */ |
110 | SCTP_CMD_SEND_NEXT_ASCONF, /* Send the next ASCONF after ACK */ | 110 | SCTP_CMD_SEND_NEXT_ASCONF, /* Send the next ASCONF after ACK */ |
111 | SCTP_CMD_PURGE_ASCONF_QUEUE, /* Purge all asconf queues.*/ | 111 | SCTP_CMD_PURGE_ASCONF_QUEUE, /* Purge all asconf queues.*/ |
112 | SCTP_CMD_SET_ASOC, /* Restore association context */ | ||
112 | SCTP_CMD_LAST | 113 | SCTP_CMD_LAST |
113 | } sctp_verb_t; | 114 | } sctp_verb_t; |
114 | 115 | ||
diff --git a/include/net/tcp.h b/include/net/tcp.h index 149a415d1e0a..e9b48b094683 100644 --- a/include/net/tcp.h +++ b/include/net/tcp.h | |||
@@ -460,6 +460,9 @@ extern int tcp_write_wakeup(struct sock *); | |||
460 | extern void tcp_send_fin(struct sock *sk); | 460 | extern void tcp_send_fin(struct sock *sk); |
461 | extern void tcp_send_active_reset(struct sock *sk, gfp_t priority); | 461 | extern void tcp_send_active_reset(struct sock *sk, gfp_t priority); |
462 | extern int tcp_send_synack(struct sock *); | 462 | extern int tcp_send_synack(struct sock *); |
463 | extern int tcp_syn_flood_action(struct sock *sk, | ||
464 | const struct sk_buff *skb, | ||
465 | const char *proto); | ||
463 | extern void tcp_push_one(struct sock *, unsigned int mss_now); | 466 | extern void tcp_push_one(struct sock *, unsigned int mss_now); |
464 | extern void tcp_send_ack(struct sock *sk); | 467 | extern void tcp_send_ack(struct sock *sk); |
465 | extern void tcp_send_delayed_ack(struct sock *sk); | 468 | extern void tcp_send_delayed_ack(struct sock *sk); |
diff --git a/include/net/transp_v6.h b/include/net/transp_v6.h index 5271a741c3a3..498433dd067d 100644 --- a/include/net/transp_v6.h +++ b/include/net/transp_v6.h | |||
@@ -39,6 +39,7 @@ extern int datagram_recv_ctl(struct sock *sk, | |||
39 | struct sk_buff *skb); | 39 | struct sk_buff *skb); |
40 | 40 | ||
41 | extern int datagram_send_ctl(struct net *net, | 41 | extern int datagram_send_ctl(struct net *net, |
42 | struct sock *sk, | ||
42 | struct msghdr *msg, | 43 | struct msghdr *msg, |
43 | struct flowi6 *fl6, | 44 | struct flowi6 *fl6, |
44 | struct ipv6_txoptions *opt, | 45 | struct ipv6_txoptions *opt, |