Skip to contentSkip to conversation

Where is netif_rx() not safe to use?

DISCUSSION Jeff Garzik 2 participants 3 messages May 12, 2003 1 message not in the archive

Subsystems (2)
lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive
Quoted 5 lines · Rask Ingemann Lambertsen

Hi.

I'd like to know if there are situations where netif_rx() is not safe to use. For example, is it safe to call from a timer or from dev->poll()?

Sure, that's fine.

Jeff

#2 lore raw
Quoted 4 lines · [email protected] said:
Quoted 2 lines

I'd like to know if there are situations where netif_rx() is not safe to use. For example, is it safe to call from a timer or from dev->poll()?

Sure, that's fine.

from dev->poll()? It could work, but that's abusing the napi design. netif_rx() is for non-napi drivers. If a dev has a ->poll() method, it should use netif_receive_skb().

Jason

#3 lore raw
Quoted 9 lines · Jason Lunz
Quoted 4 lines · [email protected] said:
Quoted 2 lines

I'd like to know if there are situations where netif_rx() is not safe to use. For example, is it safe to call from a timer or from dev->poll()?

Sure, that's fine.

from dev->poll()? It could work, but that's abusing the napi design. netif_rx() is for non-napi drivers. If a dev has a ->poll() method, it should use netif_receive_skb().

agreed.

Jeff