Re: [RFC v3] net/core: add optional threading for backlog processing

From: Eric Dumazet
Date: Sun Feb 19 2023 - 16:00:48 EST


On Sun, Feb 19, 2023 at 4:08 PM Felix Fietkau <nbd@xxxxxxxx> wrote:
>
> On 19.02.23 14:10, Felix Fietkau wrote:
> > When dealing with few flows or an imbalance on CPU utilization, static RPS
> > CPU assignment can be too inflexible. Add support for enabling threaded NAPI
> > for backlog processing in order to allow the scheduler to better balance
> > processing. This helps better spread the load across idle CPUs.
> >
> > Signed-off-by: Felix Fietkau <nbd@xxxxxxxx>


> Sorry, the patch was missing these lines:

Also make sure the following loop won't leak kthreads.

while :
do
echo 1 >/proc/sys/net/core/backlog_threaded
echo 0 >/proc/sys/net/core/backlog_threaded
done

Some documentation would also be welcomed (
Documentation/admin-guide/sysctl/net.rst &
Documentation/networking/scaling.rst )