]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - net/ipv6/syncookies.c
Merge branch 'for-2.6.31' of git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6
[mv-sheeva.git] / net / ipv6 / syncookies.c
index 711175e0571f754539f5bc74975ebb5b83e1f54a..8c2513982b616d35d28d7c9df36ef1b440d57f66 100644 (file)
@@ -131,7 +131,7 @@ __u32 cookie_v6_init_sequence(struct sock *sk, struct sk_buff *skb, __u16 *mssp)
        int mssind;
        const __u16 mss = *mssp;
 
-       tcp_sk(sk)->last_synq_overflow = jiffies;
+       tcp_synq_overflow(sk);
 
        for (mssind = 0; mss > msstab[mssind + 1]; mssind++)
                ;
@@ -175,7 +175,7 @@ struct sock *cookie_v6_check(struct sock *sk, struct sk_buff *skb)
        if (!sysctl_tcp_syncookies || !th->ack)
                goto out;
 
-       if (time_after(jiffies, tp->last_synq_overflow + TCP_TIMEOUT_INIT) ||
+       if (tcp_synq_no_recent_overflow(sk) ||
                (mss = cookie_check(skb, cookie)) == 0) {
                NET_INC_STATS_BH(sock_net(sk), LINUX_MIB_SYNCOOKIESFAILED);
                goto out;