Skip to content

Commit 3554e54

Browse files
Doug Bergerdavem330
authored andcommitted
net: systemport: suppress warnings on failed Rx SKB allocations
The driver is designed to drop Rx packets and reclaim the buffers when an allocation fails, and the network interface needs to safely handle this packet loss. Therefore, an allocation failure of Rx SKBs is relatively benign. However, the output of the warning message occurs with a high scheduling priority that can cause excessive jitter/latency for other high priority processing. This commit suppresses the warning messages to prevent scheduling problems while retaining the failure count in the statistics of the network interface. Signed-off-by: Doug Berger <[email protected]> Acked-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent ecaeceb commit 3554e54

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/net/ethernet/broadcom/bcmsysport.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -664,7 +664,8 @@ static struct sk_buff *bcm_sysport_rx_refill(struct bcm_sysport_priv *priv,
664664
dma_addr_t mapping;
665665

666666
/* Allocate a new SKB for a new packet */
667-
skb = netdev_alloc_skb(priv->netdev, RX_BUF_LENGTH);
667+
skb = __netdev_alloc_skb(priv->netdev, RX_BUF_LENGTH,
668+
GFP_ATOMIC | __GFP_NOWARN);
668669
if (!skb) {
669670
priv->mib.alloc_rx_buff_failed++;
670671
netif_err(priv, rx_err, ndev, "SKB alloc failed\n");

0 commit comments

Comments
 (0)