]> git.baikalelectronics.ru Git - kernel.git/commit
net: usb: lan78xx: fix possible skb leak
authorEric Dumazet <edumazet@google.com>
Tue, 7 Jan 2020 18:57:01 +0000 (10:57 -0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 7 Jan 2020 22:09:28 +0000 (14:09 -0800)
commitc063e6dadce50674e4d518dc5755879dd5bf19ff
treec177df1bb0e0ac39692942c7006954bd52d911c9
parent3e333561e8eb52d45f9c4279270e69645d35ef01
net: usb: lan78xx: fix possible skb leak

If skb_linearize() fails, we need to free the skb.

TSO makes skb bigger, and this bug might be the reason
Raspberry Pi 3B+ users had to disable TSO.

Fixes: f98af78833e9 ("Microchip's LAN7800 family USB 2/3 to 10/100/1000 Ethernet device driver")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reported-by: RENARD Pierre-Francois <pfrenard@gmail.com>
Cc: Stefan Wahren <stefan.wahren@i2se.com>
Cc: Woojung Huh <woojung.huh@microchip.com>
Cc: Microchip Linux Driver Support <UNGLinuxDriver@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/lan78xx.c