mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hangbin Liu <hangbin.liu@linux.dev>
To: Nikolay Aleksandrov <razor@blackwall.org>
Cc: jv@jvosburgh.net, andrew+netdev@lunn.ch, davem@davemloft.net,
	edumazet@google.com, kuba@kernel.org, pabeni@redhat.com,
	daniel@iogearbox.net, linux-kernel@vger.kernel.org,
	liuhangbin@kylinos.cn
Subject: Re: [PATCH net v3] bonding: fix slave_cnt leak on XDP error paths
Date: Fri, 11 Sep 2026 16:09:15 +0800	[thread overview]
Message-ID: <aqO3Kw-ydibVisXK@fedora> (raw)
In-Reply-To: <8149fce5-04c3-4a14-969c-c65a75dcf699@blackwall.org>

On Fri, Sep 11, 2026 at 10:23:26AM +0300, Nikolay Aleksandrov wrote:
> > Oh, hold one. I miss read the comment. It's not about the
> > bond_update_slave_arr() at bond_enslave() we moved to.
> > 
> > This is the bond_update_slave_arr() called by bond_uses_primary(), which
> > is before the ndo_bpf ops. We need to either also move the
> > if (bond_uses_primary(bond)) block after bond_update_slave_arr().
> > Or just use my patch v1 version, that add a new err out.
> > 
> > Nikolay, what do you think?
> > 
> > pw-bot: changes-requested
> > 
> > Thanks
> > Hangbin
> 
> Oh well, it is becoming too dangerous. I'd go with your v1. That is the safest bet
> that can be easily backported. Sorry for leading you down this path, I missed
> we can still reach the slave arr update via active slave selection.

bond_update_slave_arr() is somewhat hidden, and I also missed it :(

The settings in bond_enslave() are growing increasingly complex and
interdependent. Moving any line around becomes risky.

Thanks
Hangbin

      reply	other threads:[~2026-09-11  8:09 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-07  7:07 Hangbin Liu
2026-09-07  7:41 ` Nikolay Aleksandrov
2026-09-07  8:22   ` Hangbin Liu
2026-09-08 19:09 ` netdev-bot+sashiko
2026-09-10  3:31   ` Hangbin Liu
2026-09-11  7:19   ` Hangbin Liu
2026-09-11  7:23     ` Nikolay Aleksandrov
2026-09-11  8:09       ` Hangbin Liu [this message]

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=aqO3Kw-ydibVisXK@fedora \
    --to=hangbin.liu@linux.dev \
    --cc=andrew+netdev@lunn.ch \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=jv@jvosburgh.net \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=liuhangbin@kylinos.cn \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®