]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: mvneta: fix race condition in mvneta_tx()
authorEric Dumazet <edumazet@google.com>
Tue, 2 Dec 2014 12:30:59 +0000 (04:30 -0800)
committerJiri Slaby <jslaby@suse.cz>
Tue, 6 Jan 2015 12:59:53 +0000 (13:59 +0100)
commit2ffe53f9735a9fb7be8a2a1f78487db8bd603f53
tree548698ccd2a1f6d5603165c5b0e41f6a27639542
parent844969652b9b11b8b33779c35c1ae11d8cb30a96
net: mvneta: fix race condition in mvneta_tx()

[ Upstream commit 5f478b41033606d325e420df693162e2524c2b94 ]

mvneta_tx() dereferences skb to get skb->len too late,
as hardware might have completed the transmit and TX completion
could have freed the skb from another cpu.

Fixes: 71f6d1b31fb1 ("net: mvneta: replace Tx timer with a real interrupt")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/net/ethernet/marvell/mvneta.c