From: Krystian Kaniewski <krystianmkaniewski@gmail.com>
To: Jakub Kicinski <kuba@kernel.org>
Cc: netdev@vger.kernel.org, Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>,
syzkaller-bugs@googlegroups.com, dskr99@gmail.com,
Kees Cook <kees@kernel.org>,
linux-kernel@vger.kernel.org, syzbot@lists.linux.dev,
syzbot+5fe14f2ff4ccbace9a26@syzkaller.appspotmail.com
Subject: Re: [PATCH net v2] ipvlan: keep lower device alive until private destruction
Date: Fri, 7 Aug 2026 13:54:53 +0200 [thread overview]
Message-ID: <8df5c003-f28f-4fce-ad4d-9c6247d06892@gmail.com> (raw)
In-Reply-To: <20260806083834.28db4cde@kernel.org>
You're right. I treated the netdev reference as a guarantee that the
device was still usable, while it only keeps struct net_device
allocated. It does not guarantee that the device is still operational
after unregister has started.
Keeping the lower device referenced for longer in ipvlan is therefore
not the right solution. The caller that wants to operate on the device
needs to verify that it is still alive.
Thank you for the review and for clarifying this. I will prepare a v3
later with the fix on the caller side.
On 8/6/2026 5:38 PM, Jakub Kicinski wrote:
> On Mon, 3 Aug 2026 14:11:39 +0200 Krystian Kaniewski wrote:
>> Specifically, RXE acts as an asynchronous owner in this scenario. RXE
>> queues RDMA device removal on NETDEV_UNREGISTER, meaning it can retain a
>> reference to the ipvlan netdev after ndo_uninit has completed.
> The netdev reference only guarantees that struct net_device does not
> go away. Caller must check that the device is still alive if it is
> trying to operate on it without a guarantee that it's still live.
prev parent reply other threads:[~2026-08-07 11:54 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-03 12:11 [PATCH net v2] ipvlan: keep lower device alive until private destruction Krystian Kaniewski
2026-08-03 16:57 ` [syzbot ci] " syzbot ci
2026-08-06 15:38 ` [PATCH net v2] " Jakub Kicinski
2026-08-07 11:54 ` Krystian Kaniewski [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=8df5c003-f28f-4fce-ad4d-9c6247d06892@gmail.com \
--to=krystianmkaniewski@gmail.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=dskr99@gmail.com \
--cc=edumazet@google.com \
--cc=kees@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=syzbot+5fe14f2ff4ccbace9a26@syzkaller.appspotmail.com \
--cc=syzbot@lists.linux.dev \
--cc=syzkaller-bugs@googlegroups.com \
/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