From: Jakub Kicinski <kuba@kernel.org>
To: Ren Wei <weir@nebusec.ai>
Cc: netdev@vger.kernel.org, jiri@resnulli.us, davem@davemloft.net,
edumazet@kernel.org, pabeni@redhat.com, horms@kernel.org,
vega@nebusec.ai, petalzu987@gmail.com
Subject: Re: [PATCH net 1/1] net: devlink: fix reload error on netns teardown
Date: Thu, 8 Oct 2026 18:51:20 -0700 [thread overview]
Message-ID: <20261008185120.45c9b4c5@kernel.org> (raw)
In-Reply-To: <51b31e529d844b075e34a3595ba9b0eb183d325f.1791019703.git.petalzu987@gmail.com>
On Sun, 4 Oct 2026 02:14:42 +0800 Ren Wei wrote:
> err = devlink->ops->reload_down(devlink, !!dest_net, action, limit, extack);
> - if (err)
> + if (err) {
> + curr_net = devlink_net(devlink);
> + if (dest_net && curr_net->is_dying &&
> + !net_eq(dest_net, curr_net))
> + devlink_reload_netns_change(devlink, curr_net, dest_net);
> return err;
> + }
A bit of a weird place to put this code, and IDK why you're using
is_dying instead of check_net()?
I think the check belongs in devlink_pernet_pre_exit(), where we
know the curr_net is dying. Instead of trying to work backwards
from the netns state in the generic helper.
--
pw-bot: cr
prev parent reply other threads:[~2026-10-09 1:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-03 18:14 [PATCH net 0/1] net: devlink: fix reload error on netns teardown Ren Wei
2026-10-03 18:14 ` [PATCH net 1/1] " Ren Wei
2026-10-09 1:51 ` Jakub Kicinski [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=20261008185120.45c9b4c5@kernel.org \
--to=kuba@kernel.org \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=horms@kernel.org \
--cc=jiri@resnulli.us \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=petalzu987@gmail.com \
--cc=vega@nebusec.ai \
--cc=weir@nebusec.ai \
/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.