[PATCH net] net: ethernet: mtk_eth_soc: unregister net_devices in case of probe failure
patchwork-bot+netdevbpf at kernel.org
patchwork-bot+netdevbpf at kernel.org
Fri Sep 18 17:10:06 PDT 2026
Hello:
This patch was applied to netdev/net.git (main)
by Jakub Kicinski <kuba at kernel.org>:
On Wed, 16 Sep 2026 15:30:13 +0200 you wrote:
> If register_netdev() fails for one of the MTK_MAX_DEVS devices in
> mtk_probe(), the error path jumps to err_deinit_ppe, skipping
> mtk_unreg_dev(). The previously registered net_devices are then freed by
> mtk_free_dev() while still in NETREG_REGISTERED state, hitting the
> BUG_ON(dev->reg_state != NETREG_UNREGISTERED).
>
> Route the register_netdev() failure to err_unreg_netdev so the net_devices
> registered so far are properly unregistered before being freed.
>
> [...]
Here is the summary with links:
- [net] net: ethernet: mtk_eth_soc: unregister net_devices in case of probe failure
https://git.kernel.org/netdev/net/c/310d1ac61a4d
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
More information about the linux-arm-kernel
mailing list