Subject: Re: [PATCH net] net: txgbe: fix RTNL assertion warning when remove module

From: "Russell King (Oracle)" <[email-masked]>
Date: Tue, 31 Mar 2026 14:07:46 +0100

On Tue, Mar 31, 2026 at 03:11:07PM +0800, Jiawen Wu wrote:
> For the copper NIC with external PHY, the driver called
> phylink_connect_phy() during probe and phylink_disconnect_phy() during
> remove. It caused an RTNL assertion warning in phylink_disconnect_phy()
> upon module remove.
> 
> To fix this, move the phylink connect/disconnect PHY to ndo_open/close.

Wouldn't it be simpler to just wrap the phylink_disconnect_phy() in the
remove function with rtnl_lock()..rtnl_unlock() ?

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!