]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
tcp: fix tcp fin memory accounting
authorJosh Hunt <johunt@akamai.com>
Thu, 19 Mar 2015 23:19:30 +0000 (19:19 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 26 Mar 2015 12:59:35 +0000 (13:59 +0100)
commit179d478522bf66ad33b6b075066a27f6b0945fcd
tree9224bf3b49c3d846167c7ea18de9120741394997
parent8f1e9a5da7b864ee71a230e9a0d590c65c05079b
tcp: fix tcp fin memory accounting

[ Upstream commit d22e1537181188e5dc8cbc51451832625035bdc2 ]

tcp_send_fin() does not account for the memory it allocates properly, so
sk_forward_alloc can be negative in cases where we've sent a FIN:

ss example output (ss -amn | grep -B1 f4294):
tcp    FIN-WAIT-1 0      1            192.168.0.1:45520         192.0.2.1:8080
skmem:(r0,rb87380,t0,tb87380,f4294966016,w1280,o0,bl0)
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/ipv4/tcp_output.c