Andi Kleen wrote:
The netif_wake_queue is lost. It's only deadly when clean some packets
clears the full TX ring, otherwise it will likely recover with the
next TX finished interrupt but give suboptimal performance.
Fix is to do the my queue is full -> netif_stop_queue inside the spinlock.
"a fix" not "the fix" :)
You can also do what some drivers do, and move the netif_queue_stop
above the queue-packet-to-hw section of driver's ->hard_start_xmit.
Then when this uncommon race occurs, you are guaranteed another
TX-complete interrupt, even if the queue is stopped prematurely.
A lot of drivers netif_stop_queue after, not before, so this is indeed
an issue that needs paying attention to.
Jeff
|