bridge.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Petr Machata <petrm@nvidia.com>
Cc: "David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>, <netdev@vger.kernel.org>,
	Simon Horman <horms@kernel.org>,
	Nikolay Aleksandrov <razor@blackwall.org>,
	Ido Schimmel <idosch@nvidia.com>, <bridge@lists.linux.dev>,
	<mlxsw@nvidia.com>
Subject: Re: [PATCH net-next 02/10] net: bridge: BROPT_FDB_LOCAL_VLAN_0: Look up FDB on VLAN 0 on miss
Date: Mon, 8 Sep 2025 19:15:50 -0700	[thread overview]
Message-ID: <20250908191550.11beb208@kernel.org> (raw)
In-Reply-To: <8087475009dce360fb68d873b1ed9c80827da302.1757004393.git.petrm@nvidia.com>

On Thu, 4 Sep 2025 19:07:19 +0200 Petr Machata wrote:
>  		dst = br_fdb_find_rcu(br, eth_hdr(skb)->h_dest, vid);
> +		if (unlikely(!dst && vid &&
> +			     br_opt_get(br, BROPT_FDB_LOCAL_VLAN_0))) {

What does the assembly look like for this? I wonder if we're not better
off with:

	unlikely(!dst) && vid && br_opt..

Checking dst will be very fast here, and if we missed we're already 
on the slow path. So maybe we're better off moving the rest of the
condition out of the fast path, too?

  reply	other threads:[~2025-09-09  2:15 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-04 17:07 [PATCH net-next 00/10] bridge: Allow keeping local FDB entries only on VLAN 0 Petr Machata
2025-09-04 17:07 ` [PATCH net-next 01/10] net: bridge: Introduce BROPT_FDB_LOCAL_VLAN_0 Petr Machata
2025-09-04 17:07 ` [PATCH net-next 02/10] net: bridge: BROPT_FDB_LOCAL_VLAN_0: Look up FDB on VLAN 0 on miss Petr Machata
2025-09-09  2:15   ` Jakub Kicinski [this message]
2025-09-09 13:34     ` Petr Machata
2025-09-04 17:07 ` [PATCH net-next 03/10] net: bridge: BROPT_FDB_LOCAL_VLAN_0: On port changeaddr, skip per-VLAN FDBs Petr Machata
2025-09-04 17:07 ` [PATCH net-next 04/10] net: bridge: BROPT_FDB_LOCAL_VLAN_0: On bridge " Petr Machata
2025-09-04 17:07 ` [PATCH net-next 05/10] net: bridge: BROPT_FDB_LOCAL_VLAN_0: Skip local FDBs on VLAN creation Petr Machata
2025-09-04 17:07 ` [PATCH net-next 06/10] net: bridge: Introduce UAPI for BR_BOOLOPT_FDB_LOCAL_VLAN_0 Petr Machata
2025-09-04 17:07 ` [PATCH net-next 07/10] selftests: defer: Allow spaces in arguments of deferred commands Petr Machata
2025-09-04 17:07 ` [PATCH net-next 08/10] selftests: defer: Introduce DEFER_PAUSE_ON_FAIL Petr Machata
2025-09-04 17:07 ` [PATCH net-next 09/10] selftests: net: lib.sh: Don't defer failed commands Petr Machata
2025-09-04 17:07 ` [PATCH net-next 10/10] selftests: forwarding: Add test for BR_BOOLOPT_FDB_LOCAL_VLAN_0 Petr Machata
2025-09-06 18:16 ` [PATCH net-next 00/10] bridge: Allow keeping local FDB entries only on VLAN 0 Nikolay Aleksandrov
2025-09-09  2:27 ` Jakub Kicinski
2025-09-09  9:07   ` Nikolay Aleksandrov
2025-09-09  9:19     ` Nikolay Aleksandrov
2025-10-04 13:19     ` Linus Lüssing
2025-10-04 14:31       ` Nikolay Aleksandrov
2025-09-09 12:12   ` Petr Machata
2025-09-12  2:05 ` Jakub Kicinski
2025-09-12  2:10 ` patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250908191550.11beb208@kernel.org \
    --to=kuba@kernel.org \
    --cc=bridge@lists.linux.dev \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=idosch@nvidia.com \
    --cc=mlxsw@nvidia.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=petrm@nvidia.com \
    --cc=razor@blackwall.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).