Netdev List
 help / color / mirror / Atom feed
From: Paolo Abeni <pabeni@redhat.com>
To: Kuniyuki Iwashima <kuniyu@google.com>,
	"David S . Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>,
	Andrew Lunn <andrew+netdev@lunn.ch>
Cc: Simon Horman <horms@kernel.org>,
	Kuniyuki Iwashima <kuni1840@gmail.com>,
	netdev@vger.kernel.org
Subject: Re: [PATCH v2 net-next 13/14] ipvlan: Protect ipvl_port.ipvlans with mutex.
Date: Fri, 10 Jul 2026 13:08:16 +0200	[thread overview]
Message-ID: <71f1aba1-78b6-4e7b-8dc9-092b50402e07@redhat.com> (raw)
In-Reply-To: <20260703001009.1572444-14-kuniyu@google.com>

On 7/3/26 2:09 AM, Kuniyuki Iwashima wrote:
> @@ -800,9 +831,15 @@ static int ipvlan_device_event(struct notifier_block *unused,
>  		if (dev->reg_state != NETREG_UNREGISTERING)
>  			break;
>  
> -		list_for_each_entry_safe(ipvlan, next, &port->ipvlans, pnode)
> -			ipvlan->dev->rtnl_link_ops->dellink(ipvlan->dev,
> -							    &lst_kill);
> +		list_for_each_entry_safe(ipvlan, next, &port->ipvlans, pnode) {
> +#if IS_ENABLED(CONFIG_IPVTAP)
> +			if (ipvlan->dev->rtnl_link_ops != &ipvlan_link_ops)
> +				__ipvtap_dellink_ptr(ipvlan->dev, &lst_kill);
> +			else
> +#endif
> +				__ipvlan_link_delete(ipvlan->dev, &lst_kill);

I'm not sure if it's worthy a repost, but what about adding a
link_delete_unlocked() cb to `struct ipvl_dev *`? IMHO should make this
code more straight forward.

/P


  reply	other threads:[~2026-07-10 11:08 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-03  0:09 [PATCH v2 net-next 00/14] net: Support per-netns device unregistration Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 01/14] rtnetlink: Lock sock_net(skb->sk) in rtnl_newlink() Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 02/14] rtnetlink: Call unregister_netdevice_many() only once in rtnl_link_unregister() Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 03/14] rtnetlink: Add per-netns rtnl_work Kuniyuki Iwashima
2026-07-06 16:23   ` Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 04/14] net: Wrap default_device_exit_net() with __rtnl_net_lock() Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 05/14] net: Hold __rtnl_net_lock() in netdev_wait_allrefs_any() Kuniyuki Iwashima
2026-07-06 16:30   ` Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 06/14] net: Add per-netns netdev unregistration infra Kuniyuki Iwashima
2026-07-06 16:34   ` Kuniyuki Iwashima
2026-07-10 11:11   ` Paolo Abeni
2026-07-03  0:09 ` [PATCH v2 net-next 07/14] net: Call unregister_netdevice_many() per netns Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 08/14] veth: Support per-netns device unregistration Kuniyuki Iwashima
2026-07-06 16:43   ` Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 09/14] bareudp: Protect bareudp_list with mutex Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 10/14] bareudp: Support per-netns netdev unregistration Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 11/14] ipvlan: Convert ipvl_port.count to refcount_t Kuniyuki Iwashima
2026-07-06 16:50   ` Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 12/14] ipvlan: Synchronise ipvlan_init() and ipvlan_uninit() for the same lower dev Kuniyuki Iwashima
2026-07-06 16:54   ` Kuniyuki Iwashima
2026-07-03  0:09 ` [PATCH v2 net-next 13/14] ipvlan: Protect ipvl_port.ipvlans with mutex Kuniyuki Iwashima
2026-07-10 11:08   ` Paolo Abeni [this message]
2026-07-10 16:15     ` Kuniyuki Iwashima
2026-07-11 10:21       ` Paolo Abeni
2026-07-03  0:09 ` [PATCH v2 net-next 14/14] ipvlan: Support per-netns netdev unregistration Kuniyuki Iwashima
2026-07-11 11:10 ` [PATCH v2 net-next 00/14] net: Support per-netns device unregistration 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=71f1aba1-78b6-4e7b-8dc9-092b50402e07@redhat.com \
    --to=pabeni@redhat.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=kuni1840@gmail.com \
    --cc=kuniyu@google.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox