[PATCH net-next v2 0/2] bonding: reseed the ARP monitor when it starts
From: Ramses de Norre via B4 Relay
Date: Thu Dec 03 2026 - 10:27:55 EST
bond_enslave() seeds the ARP monitor timestamps of a new slave. When the
monitor starts later, from bond_open() or when arp_interval is set on a
bond that uses miimon, those seeds are as old as the time since
enslavement. The first monitor run then takes the UP slaves down before
a single probe went out.
This is the follow-up I mentioned in the v5 cover letter of the last_rx
series, which is now in net-next.
Patch 1 reseeds the slaves when the monitor starts.
Patch 2 adds a selftest for both start paths. It fails without patch 1
and passes with it.
Link: https://lore.kernel.org/netdev/20261030-bonding-last-rx-v5-0-0b9b653f2f94@xxxxxxxxxxxxxxxx/
Signed-off-by: Ramses de Norre <ramses@xxxxxxxxxxxxxxxx>
---
Changes in v2:
- Patch 1: only give a fresh seed to a slave that is UP and has
carrier. Only move the timestamps of other slaves back, so last_rx of
an active slave that is not UP cannot pass its last_link_up (Sashiko).
- Patch 1: say that recv_probe can still be set when reseeding after a
switch from the ARP monitor to miimon and back (Sashiko).
- Patch 2: use net/lib.sh instead of forwarding/lib.sh and drop
setup_wait (Hangbin).
- Patch 2: fix the comment on why arp_validate is set separately
(Sashiko).
- Link to v1: https://patch.msgid.link/20261201-bonding-arp-reseed-v1-0-984d4a3991cb@xxxxxxxxxxxxxxxx
---
Ramses de Norre (2):
bonding: reseed the ARP monitor when it starts
selftests: bonding: test that the ARP monitor keeps UP slaves when it starts
drivers/net/bonding/bond_main.c | 90 +++++++++---
drivers/net/bonding/bond_options.c | 6 +-
include/net/bonding.h | 1 +
.../testing/selftests/drivers/net/bonding/Makefile | 1 +
.../drivers/net/bonding/bond_arp_monitor_start.sh | 151 +++++++++++++++++++++
5 files changed, 227 insertions(+), 22 deletions(-)
---
base-commit: 02e8a63b4685a4321c60d562edabecc097f4a0d9
change-id: 20261201-bonding-arp-reseed-c24c7b5f99f3
Best regards,
--
Ramses de Norre <ramses@xxxxxxxxxxxxxxxx>