From: Stanislav Fomichev <stfomichev@gmail.com>
To: Saeed Mahameed <saeed@kernel.org>
Cc: Stanislav Fomichev <sdf@fomichev.me>,
netdev@vger.kernel.org, davem@davemloft.net, edumazet@google.com,
kuba@kernel.org, pabeni@redhat.com
Subject: Re: [RFC net-next 0/4] net: Hold netdev instance lock during ndo operations
Date: Thu, 13 Feb 2025 18:55:34 -0800 [thread overview]
Message-ID: <Z66wpiW71N42uLSL@mini-arch> (raw)
In-Reply-To: <Z66mEzg1YU02mr43@x130>
On 02/13, Saeed Mahameed wrote:
> On 04 Feb 15:00, Stanislav Fomichev wrote:
> > As the gradual purging of rtnl continues, start grabbing netdev
> > instance lock in more places so we can get to the state where
> > most paths are working without rtnl. Start with requiring the
> > drivers that use shaper api (and later queue mgmt api) to work
> > with both rtnl and netdev instance lock. Eventually we might
> > attempt to drop rtnl. This mostly affects iavf, gve, bnxt and
> > netdev sim (as the drivers that implement shaper/queue mgmt)
> > so those drivers are converted in the process.
> >
> > This is part one of the process, the next step is to do similar locking
> > for the rest of ndo handlers that are being called from sysfs/ethtool/netlink.
>
> Hi Stan, thanks for the patch, sorry I didn't have the time that week to
> look at it and it fill between the cracks, I've glanced through the patches
> quickly and they seem reasonable. but obviously we need much more, so what's
> the plan? currently I am not able to personally work on
> this.
>
> Also the locking scheme is still not well define with this opt-in idea the
> locking shceme is actually still not clear to me? for me it should be as easy
> as netdev_lock protects all paths including, ndos/ioctl/netlinks/etc .. paths
> that will access the netdev's underlying driver queues.
Hey Saeed,
There is a follow up which locks the other paths:
https://lore.kernel.org/netdev/20250210192043.439074-1-sdf@fomichev.me/
I'm gonna try to do a v2 tomorrow to address Jakub's feedback. There is no
opt-in currently; any driver that uses shaper/queue-mgmt API will have
its ndo running with the instance lock. Can you try to run your mlx5
queue-mgmt changes on top of it? (v1 should be good enough, no need to
wait for v2)
prev parent reply other threads:[~2025-02-14 2:55 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-04 23:00 [RFC net-next 0/4] net: Hold netdev instance lock during ndo operations Stanislav Fomichev
2025-02-04 23:00 ` [RFC net-next 1/4] net: Hold netdev instance lock during ndo_open/ndo_stop Stanislav Fomichev
2025-02-05 19:32 ` Joe Damato
2025-02-05 21:31 ` Stanislav Fomichev
2025-02-05 22:32 ` Joe Damato
2025-02-04 23:00 ` [RFC net-next 2/4] net: Hold netdev instance lock during ndo_setup_tc Stanislav Fomichev
2025-02-05 15:44 ` kernel test robot
2025-02-04 23:00 ` [RFC net-next 3/4] net: Hold netdev instance lock for more NDOs Stanislav Fomichev
2025-02-04 23:00 ` [RFC net-next 4/4] net: Hold netdev instance lock during queue operations Stanislav Fomichev
2025-02-14 2:10 ` [RFC net-next 0/4] net: Hold netdev instance lock during ndo operations Saeed Mahameed
2025-02-14 2:55 ` Stanislav Fomichev [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=Z66wpiW71N42uLSL@mini-arch \
--to=stfomichev@gmail.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=saeed@kernel.org \
--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.