[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <632c55ba-9adb-8afb-3558-94ea5f0168f8@blackwall.org>
Date: Thu, 19 Oct 2023 16:12:29 +0300
From: Nikolay Aleksandrov <razor@...ckwall.org>
To: Johannes Nixdorf <jnixdorf-oss@....de>, David Ahern <dsahern@...il.com>,
Roopa Prabhu <roopa@...dia.com>, Ido Schimmel <idosch@...dia.com>,
Petr Machata <petrm@...dia.com>
Cc: bridge@...ts.linux-foundation.org, netdev@...r.kernel.org
Subject: Re: [PATCH iproute2-next v5] iplink: bridge: Add support for bridge
FDB learning limits
On 10/18/23 10:04, Johannes Nixdorf wrote:
> Support setting the FDB limit through ip link. The arguments is:
> - fdb_max_learned: A 32-bit unsigned integer specifying the maximum
> number of learned FDB entries, with 0 disabling
> the limit.
>
> Also support reading back the current number of learned FDB entries in
> the bridge by this count. The returned value's name is:
> - fdb_n_learned: A 32-bit unsigned integer specifying the current number
> of learned FDB entries.
>
> Example:
>
> # ip -d -j -p link show br0
> [ {
> ...
> "linkinfo": {
> "info_kind": "bridge",
> "info_data": {
> ...
> "fdb_n_learned": 2,
> "fdb_max_learned": 0,
> ...
> }
> },
> ...
> } ]
> # ip link set br0 type bridge fdb_max_learned 1024
> # ip -d -j -p link show br0
> [ {
> ...
> "linkinfo": {
> "info_kind": "bridge",
> "info_data": {
> ...
> "fdb_n_learned": 2,
> "fdb_max_learned": 1024,
> ...
> }
> },
> ...
> } ]
>
> Signed-off-by: Johannes Nixdorf <jnixdorf-oss@....de>
> ---
> The corresponding kernel changes are in net-next.git as commit
> ddd1ad68826d ("net: bridge: Add netlink knobs for number / max learned
> FDB entries").
> ---
> Changes in v5:
> - Removed the RFC status again, as the kernel changes landed.
> - Link to v4: https://lore.kernel.org/r/20230919-fdb_limit-v4-1-b4d2dc4df30f@avm.de
>
> Changes in v4:
> - Removed _entries from the names. (from review)
> - Removed the UAPI change, to be synced from linux separately by the
> maintainer. (from review)
> For local testing e.g. `make CCOPTS="-O2 -pipe
> -I${path_to_dev_kernel_headers}"` works as a workaround.
> - Downgraded to an RFC until the kernel changes land.
> - Link to v3: https://lore.kernel.org/netdev/20230905-fdb_limit-v3-1-34bb124556d8@avm.de/
>
> Changes in v3:
> - Properly split the net-next and iproute2-next threads. (from review)
> - Changed to *_n_* instead of *_cur_*. (from review)
> - Use strcmp() instead of matches(). (from review)
> - Made names in code and documentation consistent. (from review)
> - Various documentation fixes. (from review)
> - Link to v2: https://lore.kernel.org/netdev/20230619071444.14625-1-jnixdorf-oss@avm.de/
>
> Changes in v2:
> - Sent out the first corresponding iproute2 patches.
> - Link to v1: https://lore.kernel.org/netdev/20230515085046.4457-1-jnixdorf-oss@avm.de/
> ---
> ip/iplink_bridge.c | 21 +++++++++++++++++++++
> man/man8/ip-link.8.in | 10 ++++++++++
> 2 files changed, 31 insertions(+)
>
Acked-by: Nikolay Aleksandrov <razor@...ckwall.org>
Powered by blists - more mailing lists