aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/tcp_ipv6.c
diff options
context:
space:
mode:
authorFlorian Westphal <fw@strlen.de>2010-06-21 11:48:45 +0000
committerDavid S. Miller <davem@davemloft.net>2010-06-26 22:00:03 -0700
commit172d69e63c7f1e8300d0e1c1bbd8eb0f630faa15 (patch)
treec71118ddc86186e235a920b9529c457db5e9aae5 /net/ipv6/tcp_ipv6.c
parent734f614bc1e7c6bf075d201f6bd9a555b8b4a984 (diff)
downloadkernel_samsung_smdk4412-172d69e63c7f1e8300d0e1c1bbd8eb0f630faa15.zip
kernel_samsung_smdk4412-172d69e63c7f1e8300d0e1c1bbd8eb0f630faa15.tar.gz
kernel_samsung_smdk4412-172d69e63c7f1e8300d0e1c1bbd8eb0f630faa15.tar.bz2
syncookies: add support for ECN
Allows use of ECN when syncookies are in effect by encoding ecn_ok into the syn-ack tcp timestamp. While at it, remove a uneeded #ifdef CONFIG_SYN_COOKIES. With CONFIG_SYN_COOKIES=nm want_cookie is ifdef'd to 0 and gcc removes the "if (0)". Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/tcp_ipv6.c')
-rw-r--r--net/ipv6/tcp_ipv6.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c
index f875345..5ebc27e 100644
--- a/net/ipv6/tcp_ipv6.c
+++ b/net/ipv6/tcp_ipv6.c
@@ -1269,7 +1269,7 @@ static int tcp_v6_conn_request(struct sock *sk, struct sk_buff *skb)
treq = inet6_rsk(req);
ipv6_addr_copy(&treq->rmt_addr, &ipv6_hdr(skb)->saddr);
ipv6_addr_copy(&treq->loc_addr, &ipv6_hdr(skb)->daddr);
- if (!want_cookie)
+ if (!want_cookie || tmp_opt.tstamp_ok)
TCP_ECN_create_request(req, tcp_hdr(skb));
if (!isn) {