* [PATCH RESEND iproute2-next] ip/bond: add broadcast_neighbor support
@ 2025-09-14 7:06 Tonghao Zhang
2025-09-18 2:45 ` David Ahern
0 siblings, 1 reply; 4+ messages in thread
From: Tonghao Zhang @ 2025-09-14 7:06 UTC (permalink / raw)
To: netdev; +Cc: Tonghao Zhang, Stephen Hemminger, David Ahern
This option has no effect in modes other than 802.3ad mode.
When this option enabled, the bond device will broadcast ARP/ND
packets to all active slaves.
Cc: Stephen Hemminger <stephen@networkplumber.org>
Cc: David Ahern <dsahern@gmail.com>
Signed-off-by: Tonghao Zhang <tonghao@bamaicloud.com>
---
1. no update uapi header. https://marc.info/?l=linux-netdev&m=170614774224160&w=3
2. the kernel patch is accpted, https://patchwork.kernel.org/project/netdevbpf/patch/84d0a044514157bb856a10b6d03a1028c4883561.1751031306.git.tonghao@bamaicloud.com/
---
ip/iplink_bond.c | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/ip/iplink_bond.c b/ip/iplink_bond.c
index a964f547..b1b144fb 100644
--- a/ip/iplink_bond.c
+++ b/ip/iplink_bond.c
@@ -149,6 +149,7 @@ static void print_explain(FILE *f)
" [ lacp_rate LACP_RATE ]\n"
" [ lacp_active LACP_ACTIVE]\n"
" [ coupled_control COUPLED_CONTROL ]\n"
+ " [ broadcast_neighbor BROADCAST_NEIGHBOR ]\n"
" [ ad_select AD_SELECT ]\n"
" [ ad_user_port_key PORTKEY ]\n"
" [ ad_actor_sys_prio SYSPRIO ]\n"
@@ -165,6 +166,7 @@ static void print_explain(FILE *f)
"LACP_RATE := slow|fast\n"
"AD_SELECT := stable|bandwidth|count\n"
"COUPLED_CONTROL := off|on\n"
+ "BROADCAST_NEIGHBOR := off|on\n"
);
}
@@ -184,6 +186,7 @@ static int bond_parse_opt(struct link_util *lu, int argc, char **argv,
__u32 arp_all_targets, resend_igmp, min_links, lp_interval;
__u32 packets_per_slave;
__u8 missed_max;
+ __u8 broadcast_neighbor;
unsigned int ifindex;
int ret;
@@ -376,6 +379,12 @@ static int bond_parse_opt(struct link_util *lu, int argc, char **argv,
if (ret)
return ret;
addattr8(n, 1024, IFLA_BOND_COUPLED_CONTROL, coupled_control);
+ } else if (strcmp(*argv, "broadcast_neighbor") == 0) {
+ NEXT_ARG();
+ broadcast_neighbor = parse_on_off("broadcast_neighbor", *argv, &ret);
+ if (ret)
+ return ret;
+ addattr8(n, 1024, IFLA_BOND_BROADCAST_NEIGH, broadcast_neighbor);
} else if (matches(*argv, "ad_select") == 0) {
NEXT_ARG();
if (get_index(ad_select_tbl, *argv) < 0)
@@ -675,6 +684,13 @@ static void bond_print_opt(struct link_util *lu, FILE *f, struct rtattr *tb[])
rta_getattr_u8(tb[IFLA_BOND_COUPLED_CONTROL]));
}
+ if (tb[IFLA_BOND_BROADCAST_NEIGH]) {
+ print_on_off(PRINT_ANY,
+ "broadcast_neighbor",
+ "broadcast_neighbor %s ",
+ rta_getattr_u8(tb[IFLA_BOND_BROADCAST_NEIGH]));
+ }
+
if (tb[IFLA_BOND_AD_SELECT]) {
const char *ad_select = get_name(ad_select_tbl,
rta_getattr_u8(tb[IFLA_BOND_AD_SELECT]));
--
2.34.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH RESEND iproute2-next] ip/bond: add broadcast_neighbor support
2025-09-14 7:06 [PATCH RESEND iproute2-next] ip/bond: add broadcast_neighbor support Tonghao Zhang
@ 2025-09-18 2:45 ` David Ahern
2025-09-19 9:01 ` Tonghao Zhang
0 siblings, 1 reply; 4+ messages in thread
From: David Ahern @ 2025-09-18 2:45 UTC (permalink / raw)
To: Tonghao Zhang, netdev; +Cc: Stephen Hemminger
On 9/14/25 1:06 AM, Tonghao Zhang wrote:
> This option has no effect in modes other than 802.3ad mode.
> When this option enabled, the bond device will broadcast ARP/ND
> packets to all active slaves.
>
> Cc: Stephen Hemminger <stephen@networkplumber.org>
> Cc: David Ahern <dsahern@gmail.com>
> Signed-off-by: Tonghao Zhang <tonghao@bamaicloud.com>
> ---
> 1. no update uapi header. https://marc.info/?l=linux-netdev&m=170614774224160&w=3
> 2. the kernel patch is accpted, https://patchwork.kernel.org/project/netdevbpf/patch/84d0a044514157bb856a10b6d03a1028c4883561.1751031306.git.tonghao@bamaicloud.com/
> ---
> ip/iplink_bond.c | 16 ++++++++++++++++
you need to update man/man8/ip-link.8.in under the bond section.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH RESEND iproute2-next] ip/bond: add broadcast_neighbor support
2025-09-18 2:45 ` David Ahern
@ 2025-09-19 9:01 ` Tonghao Zhang
2025-09-22 23:09 ` David Ahern
0 siblings, 1 reply; 4+ messages in thread
From: Tonghao Zhang @ 2025-09-19 9:01 UTC (permalink / raw)
To: David Ahern; +Cc: netdev, Stephen Hemminger
> 2025年9月18日 10:45,David Ahern <dsahern@gmail.com> 写道:
>
> On 9/14/25 1:06 AM, Tonghao Zhang wrote:
>> This option has no effect in modes other than 802.3ad mode.
>> When this option enabled, the bond device will broadcast ARP/ND
>> packets to all active slaves.
>>
>> Cc: Stephen Hemminger <stephen@networkplumber.org>
>> Cc: David Ahern <dsahern@gmail.com>
>> Signed-off-by: Tonghao Zhang <tonghao@bamaicloud.com>
>> ---
>> 1. no update uapi header. https://marc.info/?l=linux-netdev&m=170614774224160&w=3
>> 2. the kernel patch is accpted, https://patchwork.kernel.org/project/netdevbpf/patch/84d0a044514157bb856a10b6d03a1028c4883561.1751031306.git.tonghao@bamaicloud.com/
>> ---
>> ip/iplink_bond.c | 16 ++++++++++++++++
>
> you need to update man/man8/ip-link.8.in under the bond section.
>
No option descriptions as follows were found in manpage. There is only a description of bond_slave. I don’t know where to update.
Usage: ... bond [ mode BONDMODE ] [ active_slave SLAVE_DEV ]
[ clear_active_slave ] [ miimon MIIMON ]
[ updelay UPDELAY ] [ downdelay DOWNDELAY ]
[ peer_notify_delay DELAY ]
[ use_carrier USE_CARRIER ]
[ arp_interval ARP_INTERVAL ]
[ arp_validate ARP_VALIDATE ]
[ arp_all_targets ARP_ALL_TARGETS ]
[ arp_ip_target [ ARP_IP_TARGET, ... ] ]
[ ns_ip6_target [ NS_IP6_TARGET, ... ] ]
[ primary SLAVE_DEV ]
[ primary_reselect PRIMARY_RESELECT ]
[ fail_over_mac FAIL_OVER_MAC ]
[ xmit_hash_policy XMIT_HASH_POLICY ]
[ resend_igmp RESEND_IGMP ]
[ num_grat_arp|num_unsol_na NUM_GRAT_ARP|NUM_UNSOL_NA ]
[ all_slaves_active ALL_SLAVES_ACTIVE ]
[ min_links MIN_LINKS ]
[ lp_interval LP_INTERVAL ]
[ packets_per_slave PACKETS_PER_SLAVE ]
[ tlb_dynamic_lb TLB_DYNAMIC_LB ]
[ lacp_rate LACP_RATE ]
[ lacp_active LACP_ACTIVE]
[ coupled_control COUPLED_CONTROL ]
[ broadcast_neighbor BROADCAST_NEIGHBOR ]
[ ad_select AD_SELECT ]
[ ad_user_port_key PORTKEY ]
[ ad_actor_sys_prio SYSPRIO ]
[ ad_actor_system LLADDR ]
[ arp_missed_max MISSED_MAX ]
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH RESEND iproute2-next] ip/bond: add broadcast_neighbor support
2025-09-19 9:01 ` Tonghao Zhang
@ 2025-09-22 23:09 ` David Ahern
0 siblings, 0 replies; 4+ messages in thread
From: David Ahern @ 2025-09-22 23:09 UTC (permalink / raw)
To: Tonghao Zhang; +Cc: netdev, Stephen Hemminger
On 9/19/25 3:01 AM, Tonghao Zhang wrote:
>
>
>> 2025年9月18日 10:45,David Ahern <dsahern@gmail.com> 写道:
>>
>> On 9/14/25 1:06 AM, Tonghao Zhang wrote:
>>> This option has no effect in modes other than 802.3ad mode.
>>> When this option enabled, the bond device will broadcast ARP/ND
>>> packets to all active slaves.
>>>
>>> Cc: Stephen Hemminger <stephen@networkplumber.org>
>>> Cc: David Ahern <dsahern@gmail.com>
>>> Signed-off-by: Tonghao Zhang <tonghao@bamaicloud.com>
>>> ---
>>> 1. no update uapi header. https://marc.info/?l=linux-netdev&m=170614774224160&w=3
>>> 2. the kernel patch is accpted, https://patchwork.kernel.org/project/netdevbpf/patch/84d0a044514157bb856a10b6d03a1028c4883561.1751031306.git.tonghao@bamaicloud.com/
>>> ---
>>> ip/iplink_bond.c | 16 ++++++++++++++++
>>
>> you need to update man/man8/ip-link.8.in under the bond section.
>>
> No option descriptions as follows were found in manpage. There is only a description of bond_slave. I don’t know where to update.
>
ok, looks like we are missing documentation for bond arguments.
repost your patch; no sense holding it up given the current
documentation hole.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-09-22 23:09 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-14 7:06 [PATCH RESEND iproute2-next] ip/bond: add broadcast_neighbor support Tonghao Zhang
2025-09-18 2:45 ` David Ahern
2025-09-19 9:01 ` Tonghao Zhang
2025-09-22 23:09 ` David Ahern
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.