From: Mark Huang Date: Mon, 7 Feb 2005 23:26:04 +0000 (+0000) Subject: - merge revision 1.13.2.2 X-Git-Tag: before-fedora-2_6_18-1_2239_FC5-vs2_0_2_2-rc6-merge~261 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=3e9d7f26a9b3cf7295655ac4c4fa073165654131;p=linux-2.6.git - merge revision 1.13.2.2 date: 2005/02/07 23:05:42; author: mlhuang; state: Exp; lines: +10 -3 - PL4167 fix: Transfer ownership of reusable TIME_WAIT buckets to whomever VNET decided should own the packet. --- diff --git a/net/ipv4/tcp_ipv4.c b/net/ipv4/tcp_ipv4.c index 40643a19d..b25b06f72 100644 --- a/net/ipv4/tcp_ipv4.c +++ b/net/ipv4/tcp_ipv4.c @@ -5,7 +5,7 @@ * * Implementation of the Transmission Control Protocol(TCP). * - * Version: $Id: tcp_ipv4.c,v 1.240 2002/02/01 22:01:04 davem Exp $ + * Version: $Id$ * * IPv4 specific functions * @@ -1813,9 +1813,16 @@ process: /* Silently drop if VNET is active and the context is not * entitled to read the packet. */ - if (vnet_active && - (int) sk->sk_xid > 0 && sk->sk_xid != skb->xid) - goto discard_it; + if (vnet_active) { + /* Transfer ownership of reusable TIME_WAIT buckets to + * whomever VNET decided should own the packet. + */ + if (sk->sk_state == TCP_TIME_WAIT) + sk->sk_xid = skb->xid; + + if ((int) sk->sk_xid > 0 && sk->sk_xid != skb->xid) + goto discard_it; + } #endif if (sk->sk_state == TCP_TIME_WAIT)