]> Git Repo - linux.git/commitdiff
bnxt_en: Clear resource reservation during resume
authorSomnath Kotur <[email protected]>
Fri, 8 Dec 2023 00:16:55 +0000 (16:16 -0800)
committerJakub Kicinski <[email protected]>
Sat, 9 Dec 2023 01:20:26 +0000 (17:20 -0800)
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 <[email protected]>
Reviewed-by: Ajit Khaparde <[email protected]>
Reviewed-by: Andy Gospodarek <[email protected]>
Signed-off-by: Somnath Kotur <[email protected]>
Signed-off-by: Michael Chan <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
drivers/net/ethernet/broadcom/bnxt/bnxt.c

index d0359b569afeb17e3ef1340bac5b3645636af237..72f2fc9839404bc20c9bb9001c52cb6346216270 100644 (file)
@@ -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;
This page took 0.077294 seconds and 4 git commands to generate.