diff options
| author | 2026-05-28 16:33:45 -0700 | |
|---|---|---|
| committer | 2026-05-28 16:33:45 -0700 | |
| commit | ab4ac5a93b1b76aa6b12cadcba30450868d21a6f (patch) | |
| tree | b19f7f767091dc36ff861907752ada81a3c8a841 /tools/docs/ssh:/git@git.zx2c4.com | |
| parent | Merge tag 'net-7.1-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net (diff) | |
| parent | net: mana: Skip redundant detach on already-detached port (diff) | |
Merge branch 'net-mana-fix-null-dereferences-during-teardown-after-attach-failure'
Dipayaan Roy says:
====================
net: mana: Fix NULL dereferences during teardown after attach failure
When mana_attach() fails (e.g. during queue allocation), the error
cleanup frees apc->tx_qp and apc->rxqs and sets them to NULL. Multiple
subsequent teardown paths can then dereference these NULL pointers,
causing kernel panics.
Patch 1 adds NULL guards in the low-level teardown functions
(mana_fence_rqs, mana_destroy_vport, mana_dealloc_queues) so they are
safe to call regardless of queue initialization state. This covers all
callers: mana_remove(), mana_change_mtu() recovery, and internal error
paths in mana_alloc_queues().
Patch 2 adds an early exit in mana_detach() for already-detached ports,
making it safe for non-close callers. This allows the queue reset
handler to safely retry mana_attach() without redundant teardown.
====================
Link: https://patch.msgid.link/20260525081129.1230035-1-dipayanroy@linux.microsoft.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'tools/docs/ssh:/git@git.zx2c4.com')
0 files changed, 0 insertions, 0 deletions
