Skip to content
Commit c60ed825 authored by Vikas Gupta's avatar Vikas Gupta Committed by Greg Kroah-Hartman
Browse files

bnxt_en: Fix possible memory leak in bnxt_rdma_aux_device_init()



[ Upstream commit 7ac10c7d ]

If ulp = kzalloc() fails, the allocated edev will leak because it is
not properly assigned and the cleanup path will not be able to free it.
Fix it by assigning it properly immediately after allocation.

Fixes: 30343221 ("bnxt_en: Remove runtime interrupt vector allocation")
Reviewed-by: default avatarAndy Gospodarek <andrew.gospodarek@broadcom.com>
Signed-off-by: default avatarVikas Gupta <vikas.gupta@broadcom.com>
Signed-off-by: default avatarMichael Chan <michael.chan@broadcom.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 1e917752
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment