[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z7ZmYcjUJaTx2OB8@mini-arch>
Date: Wed, 19 Feb 2025 15:16:49 -0800
From: Stanislav Fomichev <stfomichev@...il.com>
To: Michael Chan <michael.chan@...adcom.com>
Cc: Stanislav Fomichev <sdf@...ichev.me>, netdev@...r.kernel.org,
davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org,
pabeni@...hat.com, Saeed Mahameed <saeed@...nel.org>
Subject: Re: [PATCH net-next v5 12/12] eth: bnxt: remove most dependencies on
RTNL
On 02/19, Michael Chan wrote:
> On Wed, Feb 19, 2025 at 12:30 PM Stanislav Fomichev <sdf@...ichev.me> wrote:
> >
> > Only devlink and sriov paths are grabbing rtnl explicitly. The rest is
> > covered by netdev instance lock which the core now grabs, so there is
> > no need to manage rtnl in most places anymore.
> >
> > On the core side we can now try to drop rtnl in some places
> > (do_setlink for example) for the drivers that signal non-rtnl
> > mode (TBD).
> >
> > Boot-tested and with `ethtool -L eth1 combined 24` to trigger reset.
> >
> > Cc: Saeed Mahameed <saeed@...nel.org>
> > Signed-off-by: Stanislav Fomichev <sdf@...ichev.me>
>
> A typo in a comment below. Otherwise it looks good to me.
>
> Reviewed-by: Michael Chan <michael.chan@...adcom.com>
>
> > @@ -13965,30 +13967,30 @@ static void bnxt_timer(struct timer_list *t)
> > mod_timer(&bp->timer, jiffies + bp->current_interval);
> > }
> >
> > -static void bnxt_rtnl_lock_sp(struct bnxt *bp)
> > +static void bnxt_lock_sp(struct bnxt *bp)
> > {
> > /* We are called from bnxt_sp_task which has BNXT_STATE_IN_SP_TASK
> > * set. If the device is being closed, bnxt_close() may be holding
> > - * rtnl() and waiting for BNXT_STATE_IN_SP_TASK to clear. So we
> > - * must clear BNXT_STATE_IN_SP_TASK before holding rtnl().
> > + * netdev instance lock and waiting for BNXT_STATE_IN_SP_TASK to clear.
> > + * So we must clear BNXT_STATE_IN_SP_TASK before holding rtnl().
>
> ... before holding netdev instance lock.
Thanks for the review! Will fix and repost tomorrow (unless Jakub pulls
and fixes on his side)
Powered by blists - more mailing lists