]> git.baikalelectronics.ru Git - kernel.git/commit
net: ethernet: microchip: lan743x: Fix skb allocation failure
authorYuiko Oshino <yuiko.oshino@microchip.com>
Wed, 27 Oct 2021 18:23:02 +0000 (14:23 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 6 Nov 2021 12:59:44 +0000 (13:59 +0100)
commitef4ef462a4787dc0679533ee3e5f4686d130243d
tree473942ce3c2dd485b5942b64498f6fe486e908ab
parent79da3670f83b976c8359f213d230b6577f202d1a
net: ethernet: microchip: lan743x: Fix skb allocation failure

commit e8684db191e4164f3f5f3ad7dec04a6734c25f1c upstream.

The driver allocates skb during ndo_open with GFP_ATOMIC which has high chance of failure when there are multiple instances.
GFP_KERNEL is enough while open and use GFP_ATOMIC only from interrupt context.

Fixes: 308800c59cf1 ("lan743x: Add main source files for new lan743x driver")
Signed-off-by: Yuiko Oshino <yuiko.oshino@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/microchip/lan743x_main.c