Messages in this thread | | | From | Eric Dumazet <> | Date | Sun, 26 Mar 2023 10:35:13 -0700 | Subject | Re: [PATCH net] net: fix raising a softirq on the current cpu with rps enabled |
| |
> > Forgive me. Really I need some coffee. I made a mistake. This line > above should be: > > + if (!test_bit(NAPI_STATE_SCHED, &mysd->backlog.state)) > > But the whole thing doesn't feel right. I need a few days to dig into > this part until Eric can help me with more of it. >
I am still traveling, and this is weekend time :/
It should not be too hard to read net/core/dev.c and remember that not _all_ drivers (or some core networking functions) use the NAPI model.
eg look at netif_rx() and ask yourself why your patch is buggy.
Just look at callers of enqueue_to_backlog() and ask yourself if all of them are called from net_rx_action()
[The answer is no, just in case you wonder]
In order to add your optimization, more work is needed, like adding new parameters so that we do not miss critical __raise_softirq_irqoff(NET_RX_SOFTIRQ) when _needed_.
We keep going circles around softirq deficiencies, I feel you are trying to fix a second-order 'issue'.
Real cause is elsewhere, look at recent patches from Jakub.
Thanks.
| |