Re: [PATCH net] net: mediatek: Fix potential NULL pointer dereference in dummy net_device handling

From: patchwork-bot+netdevbpf
Date: Thu Jul 25 2024 - 05:30:44 EST


Hello:

This patch was applied to netdev/net.git (main)
by Paolo Abeni <pabeni@xxxxxxxxxx>:

On Wed, 24 Jul 2024 01:05:23 -0700 you wrote:
> Move the freeing of the dummy net_device from mtk_free_dev() to
> mtk_remove().
>
> Previously, if alloc_netdev_dummy() failed in mtk_probe(),
> eth->dummy_dev would be NULL. The error path would then call
> mtk_free_dev(), which in turn called free_netdev() assuming dummy_dev
> was allocated (but it was not), potentially causing a NULL pointer
> dereference.
>
> [...]

Here is the summary with links:
- [net] net: mediatek: Fix potential NULL pointer dereference in dummy net_device handling
https://git.kernel.org/netdev/net/c/16f3a28cf5f8

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html