Skip to content

Commit

Permalink
can: mcp251x: fix NOHZ local_softirq_pending 08 warning
Browse files Browse the repository at this point in the history
This patch replaces netif_rx() with netif_rx_ni() which has to be used
from the threaded interrupt i.e. process context context.

Thanks to Christian Pellegrin for pointing at the right fix:
481a819 by Oliver Hartkopp.

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Acked-by: Wolfgang Grandegger <wg@grandegger.com>
  • Loading branch information
Marc Kleine-Budde committed Oct 18, 2010
1 parent 724829b commit 57d3c7b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/can/mcp251x.c
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,7 @@ static void mcp251x_hw_rx(struct spi_device *spi, int buf_idx)

priv->net->stats.rx_packets++;
priv->net->stats.rx_bytes += frame->can_dlc;
netif_rx(skb);
netif_rx_ni(skb);
}

static void mcp251x_hw_sleep(struct spi_device *spi)
Expand Down Expand Up @@ -676,7 +676,7 @@ static void mcp251x_error_skb(struct net_device *net, int can_id, int data1)
if (skb) {
frame->can_id = can_id;
frame->data[1] = data1;
netif_rx(skb);
netif_rx_ni(skb);
} else {
dev_err(&net->dev,
"cannot allocate error skb\n");
Expand Down

0 comments on commit 57d3c7b

Please sign in to comment.