diff options
author | Michael Trimarchi <michael@amarulasolutions.com> | 2022-05-18 09:20:07 +0300 |
---|---|---|
committer | Paolo Abeni <pabeni@redhat.com> | 2022-05-19 12:38:02 +0300 |
commit | b885aab3d39d1c81709e957324c7fb9aeac02c38 (patch) | |
tree | fce5168d79f5122aa8c54feaf59510e9cece8550 | |
parent | d935053a62fa11d06c757c1725782e46e7e823db (diff) | |
download | linux-b885aab3d39d1c81709e957324c7fb9aeac02c38.tar.xz |
net: fec: Avoid allocating rx buffer using ATOMIC in ndo_open
Make ndo_open less sensitive to memory pressure.
Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Reviewed-by: Jakub Kicinski <kuba@kernel.org>
Link: https://lore.kernel.org/r/20220518062007.10056-1-michael@amarulasolutions.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
-rw-r--r-- | drivers/net/ethernet/freescale/fec_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/freescale/fec_main.c b/drivers/net/ethernet/freescale/fec_main.c index 6e52f3ad182f..3cb298f1d69c 100644 --- a/drivers/net/ethernet/freescale/fec_main.c +++ b/drivers/net/ethernet/freescale/fec_main.c @@ -3076,7 +3076,7 @@ fec_enet_alloc_rxq_buffers(struct net_device *ndev, unsigned int queue) rxq = fep->rx_queue[queue]; bdp = rxq->bd.base; for (i = 0; i < rxq->bd.ring_size; i++) { - skb = netdev_alloc_skb(ndev, FEC_ENET_RX_FRSIZE); + skb = __netdev_alloc_skb(ndev, FEC_ENET_RX_FRSIZE, GFP_KERNEL); if (!skb) goto err_alloc; |