Skip to contentSkip to conversation

octeontx2-pf: Unregister devlink on probe failure

PATCH Applied Hariprasad Kelam 2 participants 2 messages Feb 6 – Feb 11

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 octeontx2-pf: Unregister devlink on probe failure

When probe fails after devlink registration, the missing devlink unregister call causing a memory leak.

Fixes 2da489432747 ("octeontx2-pf: devlink params support to set mcam entry count")
---
 drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c | 1 +
 1 file changed, 1 insertion(+)
drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c +1 -0
index 6b2d8559f0eb..444bb67494ab 100644
@@ -3315,6 +3315,7 @@ static int otx2_probe(struct pci_dev *pdev, const struct pci_device_id *id)
 err_sriov_cleannup:
 	otx2_sriov_vfcfg_cleanup(pf);
 err_pf_sriov_init:
+	otx2_unregister_dl(pf);
 	otx2_shutdown_tc(pf);
 err_mcam_flow_del:
 	otx2_mcam_flow_del(pf);
Signature · 1 line
2.34.1
#1 lore raw
This patch was applied to netdev/net.git (main) by Paolo Abeni <[email protected]>:

Hello:

This patch was applied to netdev/net.git (main)
by Paolo Abeni <[email protected]>:

Quoted 8 lines · On Fri, 6 Feb 2026 23:56:45 +0530 you wrote:

When probe fails after devlink registration, the missing devlink unregister call causing a memory leak.

Fixes 2da489432747 ("octeontx2-pf: devlink params support to set mcam entry count")
---
 drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c | 1 +
 1 file changed, 1 insertion(+)

Here is the summary with links:
- [net] octeontx2-pf: Unregister devlink on probe failure

    https://git.kernel.org/netdev/net/c/943f3b8bfbf2

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html