[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Wed, 03 Mar 2010 17:06:02 +0800
From: Zhu Yi <yi.zhu@...el.com>
To: Eric Dumazet <eric.dumazet@...il.com>
Cc: "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"David S. Miller" <davem@...emloft.net>,
Alexey Kuznetsov <kuznet@....inr.ac.ru>,
"Pekka Savola (ipv6)" <pekkas@...core.fi>,
Patrick McHardy <kaber@...sh.net>
Subject: Re: [PATCH V2 2/7] tcp: use limited socket backlog
On Wed, 2010-03-03 at 16:53 +0800, Eric Dumazet wrote:
> > @@ -1682,8 +1682,10 @@ process:
> > if (!tcp_prequeue(sk, skb))
> > ret = tcp_v4_do_rcv(sk, skb);
> > }
> > - } else
> > - sk_add_backlog(sk, skb);
> > + } else if (sk_add_backlog_limited(sk, skb)) {
> > + bh_unlock_sock(sk);
> > + goto discard_and_relse;
> > + }
> > bh_unlock_sock(sk);
> >
> > sock_put(sk);
>
> So no counter is incremented to reflect this loss, sk->sk_drops (local
> counter) or SNMP ?
I simply follow how the code is originally written. As you can see,
tcp_v4_do_rcv() doesn't always do so. And in the backlog queuing place,
we don't even bother to check.
Thanks,
-yi
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists