From: Jakub Kicinski <kuba@kernel.org>
To: Stanislav Fomichev <stfomichev@gmail.com>
Cc: Stanislav Fomichev <sdf@fomichev.me>,
netdev@vger.kernel.org, davem@davemloft.net, edumazet@google.com,
pabeni@redhat.com
Subject: Re: [PATCH net v2 06/11] netdevsim: add dummy device notifiers
Date: Thu, 27 Mar 2025 14:46:09 -0700 [thread overview]
Message-ID: <20250327144609.647403fa@kernel.org> (raw)
In-Reply-To: <Z-W9Rkr07PbY3Qf4@mini-arch>
On Thu, 27 Mar 2025 14:04:06 -0700 Stanislav Fomichev wrote:
> > Can we register empty notifiers in nsim (just to make sure it has
> > a callback) but do the validation in rtnl_net_debug.c
> > I guess we'd need to transform rtnl_net_debug.c a little,
> > make it less rtnl specific, compile under DEBUG_NET and ifdef
> > out the small rtnl parts?
>
> s/rtnl_net_debug.c/notifiers_debug.c/ + DEBUG_NET? Or I can keep the
> name and only do the DEBUG_NET part.
I was thinking lock or locking as in net/core/lock_debug.c
But yeah, it's locking in notifier locking, maybe
net/core/notifier_lock_debug.c then? No strong feelings.
> Not sure what needs to be ifdef-ed out,
> but will take a look (probably just enough to make it compile with
> !CONFIG_DEBUG_NET_SMALL_RTNL ?).
You're right, looking at the code we need all of it.
Somehow I thought its doing extra netns related stuff but it just
register a notifier in each ns.
I guess we may not need any ifdef at all.
> That should work for the regular notifiers,
> but I think register_netdevice_notifier_dev_net needs a netdev?
Hm. Yes. Not sure if we need anything extra in the notifier for nsim
or we just want to make make sure it registers one. If the latter
I guess we could export rtnl_net_debug_event (modulo rename) and
call it from netdevsim? I mean - we would probably have the same
exact asserts in both?
next prev parent reply other threads:[~2025-03-27 21:46 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-27 13:56 [PATCH net v2 00/11] net: hold instance lock during NETDEV_UP/REGISTER/UNREGISTER Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 01/11] net: switch to netif_disable_lro in inetdev_init Stanislav Fomichev
2025-03-27 18:40 ` Jakub Kicinski
2025-03-27 18:59 ` Jakub Kicinski
2025-03-27 21:09 ` Stanislav Fomichev
2025-03-27 21:36 ` Jakub Kicinski
2025-03-28 15:01 ` Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 02/11] net: hold instance lock during NETDEV_REGISTER/UP/UNREGISTER Stanislav Fomichev
2025-03-27 18:58 ` Jakub Kicinski
2025-03-27 13:56 ` [PATCH net v2 03/11] net: use netif_disable_lro in ipv6_add_dev Stanislav Fomichev
2025-03-27 19:02 ` Jakub Kicinski
2025-03-27 21:06 ` Stanislav Fomichev
2025-03-27 21:37 ` Jakub Kicinski
2025-03-28 15:01 ` Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 04/11] net: release instance lock during NETDEV_UNREGISTER for bond/team Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 05/11] net/mlx5e: use netdev_lockdep_set_classes Stanislav Fomichev
2025-03-27 19:08 ` Jakub Kicinski
2025-03-27 21:05 ` Stanislav Fomichev
2025-03-31 8:01 ` Cosmin Ratiu
2025-03-27 13:56 ` [PATCH net v2 06/11] netdevsim: add dummy device notifiers Stanislav Fomichev
2025-03-27 19:12 ` Jakub Kicinski
2025-03-27 21:04 ` Stanislav Fomichev
2025-03-27 21:46 ` Jakub Kicinski [this message]
2025-03-28 6:03 ` Kuniyuki Iwashima
2025-03-28 15:07 ` Stanislav Fomichev
2025-03-28 15:04 ` Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 07/11] net: dummy: request ops lock Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 08/11] docs: net: document netdev notifier expectations Stanislav Fomichev
2025-03-27 19:16 ` Jakub Kicinski
2025-03-27 19:34 ` Jakub Kicinski
2025-03-27 20:57 ` Stanislav Fomichev
2025-03-27 21:50 ` Jakub Kicinski
2025-03-28 15:03 ` Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 09/11] net: designate XSK pool pointers in queues as "ops protected" Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 10/11] netdev: add "ops compat locking" helpers Stanislav Fomichev
2025-03-27 13:56 ` [PATCH net v2 11/11] netdev: don't hold rtnl_lock over nl queue info get when possible Stanislav Fomichev
2025-03-28 8:07 ` [PATCH net v2 00/11] net: hold instance lock during NETDEV_UP/REGISTER/UNREGISTER Taehee Yoo
2025-03-28 15:43 ` Stanislav Fomichev
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=20250327144609.647403fa@kernel.org \
--to=kuba@kernel.org \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=sdf@fomichev.me \
--cc=stfomichev@gmail.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;
as well as URLs for NNTP newsgroup(s).