All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stanislav Fomichev <stfomichev@gmail.com>
To: Jakub Kicinski <kuba@kernel.org>
Cc: Stanislav Fomichev <sdf@fomichev.me>,
	netdev@vger.kernel.org, davem@davemloft.net, edumazet@google.com,
	pabeni@redhat.com, Cosmin Ratiu <cratiu@nvidia.com>
Subject: Re: [PATCH net v5 02/11] net: hold instance lock during NETDEV_REGISTER/UP
Date: Wed, 2 Apr 2025 19:34:56 -0700	[thread overview]
Message-ID: <Z-3z0MUidedMwpLt@mini-arch> (raw)
In-Reply-To: <20250402171213.10f809d6@kernel.org>

On 04/02, Jakub Kicinski wrote:
> On Wed, 2 Apr 2025 17:02:20 -0700 Jakub Kicinski wrote:
> > Is there a reason we don't hold the instance lock over
> > unlist_netdevice() in unregister_netdevice_many_notify()
> > but we do here? We need a separate fix for that..

No particular reason. It felt better to flip list/unlist and reg_state
'atomically', but I agree that it doesn't make much sense since the
other paths don't look at the device listed/unlisted state.

> I deleted too much here. I meant to say that we need a fix
> for netns changing while netdev_get_by_index_lock() is
> grabbing the device.

A fix for somebody grabbing the device in between two locks?

  reply	other threads:[~2025-04-03  2:34 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-01 16:34 [PATCH net v5 00/11] net: hold instance lock during NETDEV_UP/REGISTER Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 01/11] net: switch to netif_disable_lro in inetdev_init Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 02/11] net: hold instance lock during NETDEV_REGISTER/UP Stanislav Fomichev
2025-04-03  0:02   ` Jakub Kicinski
2025-04-03  0:12     ` Jakub Kicinski
2025-04-03  2:34       ` Stanislav Fomichev [this message]
2025-04-01 16:34 ` [PATCH net v5 03/11] net: use netif_disable_lro in ipv6_add_dev Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 04/11] net: rename rtnl_net_debug to lock_debug Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 05/11] netdevsim: add dummy device notifiers Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 06/11] net: dummy: request ops lock Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 07/11] docs: net: document netdev notifier expectations Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 08/11] selftests: net: use netdevsim in netns test Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 09/11] net: designate XSK pool pointers in queues as "ops protected" Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 10/11] netdev: add "ops compat locking" helpers Stanislav Fomichev
2025-04-01 16:34 ` [PATCH net v5 11/11] netdev: don't hold rtnl_lock over nl queue info get when possible Stanislav Fomichev
2025-04-03  0:05 ` [PATCH net v5 00/11] net: hold instance lock during NETDEV_UP/REGISTER Jakub Kicinski
2025-04-03 22:50 ` 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=Z-3z0MUidedMwpLt@mini-arch \
    --to=stfomichev@gmail.com \
    --cc=cratiu@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=sdf@fomichev.me \
    /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.