mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 19:30:30 +09:00
bnxt_en: Free context memory after disabling PCI in probe error path.
[ Upstream commit62bfb932a5] Other shutdown code paths will always disable PCI first to shutdown DMA before freeing context memory. Do the same sequence in the error path of probe to be safe and consistent. Fixes:c20dc142dd("bnxt_en: Disable bus master during PCI shutdown and driver unload.") Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
797d6f91c3
commit
0234e8ebb7
@@ -11895,12 +11895,12 @@ init_err_cleanup:
|
||||
init_err_pci_clean:
|
||||
bnxt_free_hwrm_short_cmd_req(bp);
|
||||
bnxt_free_hwrm_resources(bp);
|
||||
bnxt_free_ctx_mem(bp);
|
||||
kfree(bp->ctx);
|
||||
bp->ctx = NULL;
|
||||
kfree(bp->fw_health);
|
||||
bp->fw_health = NULL;
|
||||
bnxt_cleanup_pci(bp);
|
||||
bnxt_free_ctx_mem(bp);
|
||||
kfree(bp->ctx);
|
||||
bp->ctx = NULL;
|
||||
|
||||
init_err_free:
|
||||
free_netdev(dev);
|
||||
|
||||
Reference in New Issue
Block a user