Thread View: linux.kernel.netdev
1 messages
1 total messages
Started by David Ahern
Wed, 14 Oct 2026 13:36
Re: [PATCH net-next 2/2] ipv4: Do not pass netns to fib_table_lookup()
Author: David Ahern
Date: Wed, 14 Oct 2026 13:36
Date: Wed, 14 Oct 2026 13:36
33 lines
6722 bytes
6722 bytes
On 10/14/26 2:26 AM, Ido Schimmel wrote:
> Commit c436a624f89e ("ipv4: Pass netns to fib_table_lookup()") added the
> network namespace as an argument of fib_table_lookup() so that it could
> be passed to the fib_table_lookup tracepoint. However, the function is
> called in the data path and the namespace is only needed when the
> tracepoint is enabled, so the additional argument is unnecessary
> overhead.
>
> Instead, pass the namespace that is now stored in the FIB table to the
> tracepoint. This way, the namespace is only read when the tracepoint is
> enabled. Revert the signature of fib_table_lookup() and its callers to
> what they were before the above commit. The tracepoint itself is
> unchanged.
>
> No functional changes intended.
>
> Suggested-by: Paolo Abeni <pabeni@redhat.com>
> Link: https://lore.kernel.org/netdev/43857d08-c4f4-44ce-a0b3-0e7fcc56bf90@redhat.com/
> Assisted-by: LLM
> Signed-off-by: Ido Schimmel <idosch@nvidia.com>
> ---
> include/net/ip_fib.h | 12 +++++-------
> net/core/filter.c | 2 +-
> net/ipv4/devinet.c | 3 +--
> net/ipv4/fib_frontend.c | 6 ++----
> net/ipv4/fib_rules.c | 2 +-
> net/ipv4/fib_semantics.c | 2 +-
> net/ipv4/fib_trie.c | 16 +++++++++-------
> 7 files changed, 20 insertions(+), 23 deletions(-)
>
Reviewed-by: David Ahern <dsahern@kernel.org>
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads