Re: [patch] revert: [NET]: Fix races in net_rx_action vs netpoll

From: Olaf Kirch
Date: Tue Jul 17 2007 - 04:19:22 EST


On Monday 16 July 2007 23:40, Linus Torvalds wrote:
> - The change seems to always set the LIST_FROZEN bit when calling
> ->poll(), and at least on e1000, the NAPI poll() routine ends up doing
> that netif_rx_complete(), so we're *guaranteed* to always take the
> early exit and not do anything.

That is only in the poll_napi case, where netpoll tries to push pending
frames. The default caller for dev->poll() is net_rx_action.

We only ever get into this particular code branch in poll_napi when
the RX_SCHED bit is already set, ie someone put the device on the NAPI
poll_list and raised the softirq. poll_napi is just doing manually what
net_rx_action would do anyway once the softirq is serviced.

> - The early return from netif_rx_complete() ends up meaning that an
> edge-triggered interrupt isn't handled properly, and will this never
> happen again, since it never goes away.

Sorry, I may be sitting on my brain this morning, but I don't understand
how skipping netif_rx_complete would affect ACKing of interrupts.

Olaf
--
Olaf Kirch | --- o --- Nous sommes du soleil we love when we play
okir@xxxxxx | / | \ sol.dhoop.naytheet.ah kin.ir.samse.qurax
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/