Subject: Re: [PATCH RFC net-next v1] page_pool: import Jesper's page_pool benchmark

From: Toke Høiland-Jørgensen <[email-masked]>
Date: Mon, 10 Mar 2025 10:15:48 +0100

Mina Almasry <[email-masked]> writes:

> From: Jesper Dangaard Brouer <[email-masked]>
>
> We frequently consult with Jesper's out-of-tree page_pool benchmark to
> evaluate page_pool changes.
>
> Consider importing the benchmark into the upstream linux kernel tree so
> that (a) we're all running the same version, (b) pave the way for shared
> improvements, and (c) maybe one day integrate it with nipa, if possible.
>
> I imported the bench_page_pool_simple from commit 35b1716d0c30 ("Add
> page_bench06_walk_all"), from this repository:
> https://github.com/netoptimizer/prototype-kernel.git
>
> I imported the benchmark, largely as-is. I only fixed build or
> checkpatch issues.
>
> Cc: Jesper Dangaard Brouer <[email-masked]>
> Cc: Ilias Apalodimas <[email-masked]>
> Cc: Jakub Kicinski <[email-masked]>
> Cc: Toke Høiland-Jørgensen <[email-masked]>
> Cc: [email-masked]
> Signed-off-by: Mina Almasry <[email-masked]>
>
> ---
>
> RFC discussion points:
> - Desirable to import it?

I think so, yeah.

> - Can the benchmark be imported as-is for an initial version? Or needs
>   lots of modifications?

One thing that I was discussing with Jesper the other day is that the
current version allocates the page_pool itself in softirq context, which
leads to some "may sleep" warning. I think we should fix that before
upstreaming.

> - Code location. I retained the location in Jesper's tree, but a path
>   like net/core/bench/ may make more sense.

No strong opinion on this...

-Toke