From: Leon Romanovsky <leon@kernel.org>
To: Eric Dumazet <eric.dumazet@gmail.com>
Cc: "David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>, netdev <netdev@vger.kernel.org>,
Eric Dumazet <edumazet@google.com>,
Moshe Shemesh <moshe@mellanox.com>,
Jacob Keller <jacob.e.keller@intel.com>,
Jiri Pirko <jiri@nvidia.com>
Subject: Re: [PATCH net] devlink: fix netns refcount leak in devlink_nl_cmd_reload()
Date: Mon, 6 Dec 2021 09:16:55 +0200 [thread overview]
Message-ID: <Ya245+a9vajIjYvU@unreal> (raw)
In-Reply-To: <20211205192822.1741045-1-eric.dumazet@gmail.com>
On Sun, Dec 05, 2021 at 11:28:22AM -0800, Eric Dumazet wrote:
> From: Eric Dumazet <edumazet@google.com>
>
> While preparing my patch series adding netns refcount tracking,
> I spotted bugs in devlink_nl_cmd_reload()
>
> Some error paths forgot to release a refcount on a netns.
>
> To fix this, we can reduce the scope of get_net()/put_net()
> section around the call to devlink_reload().
>
> Fixes: ccdf07219da6 ("devlink: Add reload action option to devlink reload command")
> Fixes: dc64cc7c6310 ("devlink: Add devlink reload limit option")
> Signed-off-by: Eric Dumazet <edumazet@google.com>
> Cc: Moshe Shemesh <moshe@mellanox.com>
> Cc: Jakub Kicinski <kuba@kernel.org>
> Cc: Jacob Keller <jacob.e.keller@intel.com>
> Cc: Jiri Pirko <jiri@nvidia.com>
> ---
> net/core/devlink.c | 16 ++++++++--------
> 1 file changed, 8 insertions(+), 8 deletions(-)
>
Thanks,
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
next prev parent reply other threads:[~2021-12-06 7:17 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-05 19:28 [PATCH net] devlink: fix netns refcount leak in devlink_nl_cmd_reload() Eric Dumazet
2021-12-06 7:16 ` Leon Romanovsky [this message]
2021-12-07 1:10 ` patchwork-bot+netdevbpf
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=Ya245+a9vajIjYvU@unreal \
--to=leon@kernel.org \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=eric.dumazet@gmail.com \
--cc=jacob.e.keller@intel.com \
--cc=jiri@nvidia.com \
--cc=kuba@kernel.org \
--cc=moshe@mellanox.com \
--cc=netdev@vger.kernel.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.