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

patchwork-bot+netdevbpf at kernel.org patchwork-bot+netdevbpf at kernel.org
Thu Jul 25 02:30:31 PDT 2024


Hello:

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

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





More information about the linux-arm-kernel mailing list