diff options
author | Somnath Kotur <somnath.kotur@broadcom.com> | 2023-12-08 01:16:55 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2023-12-09 02:20:26 +0100 |
commit | 9ef7c58f5abe41e6d91f37f28fe2d851ffedd92a (patch) | |
tree | 9327fa557cf78e6809bbdd514c78e89ff5d6de56 /drivers/net/ethernet/broadcom | |
parent | tcp: fix tcp_disordered_ack() vs usec TS resolution (diff) | |
download | linux-9ef7c58f5abe41e6d91f37f28fe2d851ffedd92a.tar.xz linux-9ef7c58f5abe41e6d91f37f28fe2d851ffedd92a.zip |
bnxt_en: Clear resource reservation during resume
We are issuing HWRM_FUNC_RESET cmd to reset the device including
all reserved resources, but not clearing the reservations
within the driver struct. As a result, when the driver re-initializes
as part of resume, it believes that there is no need to do any
resource reservation and goes ahead and tries to allocate rings
which will eventually fail beyond a certain number pre-reserved by
the firmware.
Fixes: 674f50a5b026 ("bnxt_en: Implement new method to reserve rings.")
Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Andy Gospodarek <andrew.gospodarek@broadcom.com>
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Link: https://lore.kernel.org/r/20231208001658.14230-2-michael.chan@broadcom.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
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 d0359b569afe..72f2fc983940 100644 --- a/drivers/net/ethernet/broadcom/bnxt/bnxt.c +++ b/drivers/net/ethernet/broadcom/bnxt/bnxt.c @@ -13940,6 +13940,8 @@ static int bnxt_resume(struct device *device) if (rc) goto resume_exit; + bnxt_clear_reservations(bp, true); + if (bnxt_hwrm_func_drv_rgtr(bp, NULL, 0, false)) { rc = -ENODEV; goto resume_exit; |