From: Jakub Kicinski <kuba@kernel.org>
To: Hangbin Liu <hangbin.liu@linux.dev>
Cc: Matthieu Baerts <matttbe@kernel.org>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
Hangbin Liu <liuhangbin@kylinos.cn>,
Jay Vosburgh <jv@jvosburgh.net>,
Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>,
Daniel Borkmann <daniel@iogearbox.net>,
Jussi Maki <joamaki@gmail.com>,
Nikolay Aleksandrov <razor@blackwall.org>
Subject: Re: [PATCH net v2] bonding: fix slave_cnt leak on XDP error paths
Date: Thu, 3 Sep 2026 09:22:58 -0700 [thread overview]
Message-ID: <20260903092258.67ea7b65@kernel.org> (raw)
In-Reply-To: <62271715-fbd6-4047-9b69-b2bda40db056@kernel.org>
On Thu, 3 Sep 2026 12:38:14 +0200 Matthieu Baerts wrote:
> On 03/09/2026 10:10, Hangbin Liu wrote:
> > From: Hangbin Liu <liuhangbin@kylinos.cn>
> >
> > When bond_enslave() succeeds up to the XDP setup stage, slave_cnt is
> > already incremented. If XDP setup subsequently fails, the error paths
> > jump directly to err_sysfs_del, bypassing the slave_cnt decrement.
> >
> > This causes slave_cnt to drift upward on each failed enslaving attempt,
> > which would lead to unbalanced traffic distribution with round-robin
> > mode.
> >
> > Fix it by moving the slave_cnt increasement after XDP setup.
> Thank you for the fix, but it looks like it causes multiple KASAN
> issues, see:
>
> - https://netdev.bots.linux.dev/flakes.html?ld-remote=virt-bonding-dbg
Hangbin, this is at least the 3rd time in a week when kernel selftests
find issues in patches you posted. It's really time for you to run
these tests locally.
next prev parent reply other threads:[~2026-09-03 16:23 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-03 8:10 [PATCH net v2] bonding: fix slave_cnt leak on XDP error paths Hangbin Liu
2026-09-03 8:18 ` Nikolay Aleksandrov
2026-09-03 9:27 ` Hangbin Liu
2026-09-03 9:31 ` Nikolay Aleksandrov
2026-09-03 10:38 ` Matthieu Baerts
2026-09-03 11:53 ` Nikolay Aleksandrov
2026-09-04 1:30 ` Hangbin Liu
2026-09-04 1:40 ` Hangbin Liu
2026-09-04 1:58 ` Hangbin Liu
2026-09-03 16:22 ` Jakub Kicinski [this message]
2026-09-04 2:01 ` Hangbin Liu
2026-09-04 14:11 ` [syzbot ci] " syzbot ci
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=20260903092258.67ea7b65@kernel.org \
--to=kuba@kernel.org \
--cc=andrew+netdev@lunn.ch \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hangbin.liu@linux.dev \
--cc=joamaki@gmail.com \
--cc=jv@jvosburgh.net \
--cc=linux-kernel@vger.kernel.org \
--cc=liuhangbin@kylinos.cn \
--cc=matttbe@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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 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.