On Fri Nov 6, 2026 at 11:54 AM GMT, Breno Leitao wrote: > On Fri, Nov 06, 2026 at 09:41:31AM +0000, Troy Mitchell wrote: >> On Thu, 5 Nov 2026 23:28:31 +0100, Vadim Fedorenko wrote: >> > > This would work, but I am wondering if it would be possible to call >> > > rtnl inside the _open function, when dealing with the PHY? in other >> > > words, shrink the time rtnl is held. >> > >> > +1, especially in emac_open() rtnl is needed only in error path case >> >> emac_open() and emac_stop() are also the driver's .ndo_open and >> .ndo_stop, which the core already calls with RTNL held, see >> Documentation/networking/netdevices.rst +214. Taking rtnl_lock() >> inside them would deadlock on every open and close, so the lock has to >> stay in the PM callbacks. > > That makes sense to me. > > Reviewed-by: Breno Leitao This tag is deprecated. Version 2 will use a different approach [1] Link: https://lore.kernel.org/all/c55c5878-d9c1-4863-bc55-99d334ba2ede@gmail.com/ [1] -- Troy Mitchell