diff options
author | Vasundhara Volam <vasundhara-v.volam@broadcom.com> | 2020-03-08 23:45:54 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-03-09 05:54:46 +0100 |
commit | 0fcfc7a1c3d14fd5d80e3c615efbd581381a138b (patch) | |
tree | 48536e650383242bffdc509a64efda0e45eb2dde /drivers/net/ethernet/broadcom | |
parent | bnxt_en: Return -EAGAIN if fw command returns BUSY (diff) | |
download | linux-0fcfc7a1c3d14fd5d80e3c615efbd581381a138b.tar.xz linux-0fcfc7a1c3d14fd5d80e3c615efbd581381a138b.zip |
bnxt_en: Call devlink_port_type_clear() in remove()
Similar to other drivers, properly clear the devlink port type when
removing the device before unregistration.
Cc: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: Vasundhara Volam <vasundhara-v.volam@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom')
-rw-r--r-- | drivers/net/ethernet/broadcom/bnxt/bnxt.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 02ac718db92f..4c9696a3978a 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c @@ -11429,6 +11429,8 @@ static void bnxt_remove_one(struct pci_dev *pdev) bnxt_sriov_disable(bp); bnxt_dl_fw_reporters_destroy(bp, true); + if (BNXT_PF(bp)) + devlink_port_type_clear(&bp->dl_port); pci_disable_pcie_error_reporting(pdev); unregister_netdev(dev); bnxt_dl_unregister(bp); |