]> git.karo-electronics.de Git - karo-tx-linux.git/commit
net: fix sk_forward_alloc corruption
authorEric Dumazet <eric.dumazet@gmail.com>
Mon, 16 Nov 2009 04:50:00 +0000 (20:50 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 8 Dec 2009 18:22:01 +0000 (10:22 -0800)
commit5213d268ccd71d4e294650d83161cd93cfb6a21e
tree83cb7d0fe342b3028e6cf6c6da5cbc3173c0fc1f
parentfb97d3d0b3bab856c9419e727d543e4497da24b9
net: fix sk_forward_alloc corruption

[ Upstream commit: 9d410c796067686b1e032d54ce475b7055537138 ]

On UDP sockets, we must call skb_free_datagram() with socket locked,
or risk sk_forward_alloc corruption. This requirement is not respected
in SUNRPC.

Add a convenient helper, skb_free_datagram_locked() and use it in SUNRPC

Reported-by: Francis Moreau <francis.moro@gmail.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
include/linux/skbuff.h
net/core/datagram.c
net/ipv4/udp.c
net/ipv6/udp.c
net/sunrpc/svcsock.c