Skip to content

Commit

Permalink
bnxt_en: Wait for FLR to complete during probe
Browse files Browse the repository at this point in the history
[ Upstream commit 3c1069f ]

The first message to firmware may fail if the device is undergoing FLR.
The driver has some recovery logic for this failure scenario but we must
wait 100 msec for FLR to complete before proceeding.  Otherwise the
recovery will always fail.

Fixes: ba02629 ("bnxt_en: log firmware status on firmware init failure")
Reviewed-by: Damodharam Ammepalli <[email protected]>
Signed-off-by: Michael Chan <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
Signed-off-by: Sasha Levin <[email protected]>
  • Loading branch information
Michael Chan authored and gregkh committed Feb 1, 2024
1 parent 3982fe7 commit 4bc28ba
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions drivers/net/ethernet/broadcom/bnxt/bnxt.c
Original file line number Diff line number Diff line change
Expand Up @@ -12298,6 +12298,11 @@ static int bnxt_fw_init_one_p1(struct bnxt *bp)

bp->fw_cap = 0;
rc = bnxt_hwrm_ver_get(bp);
/* FW may be unresponsive after FLR. FLR must complete within 100 msec
* so wait before continuing with recovery.
*/
if (rc)
msleep(100);
bnxt_try_map_fw_health_reg(bp);
if (rc) {
rc = bnxt_try_recover_fw(bp);
Expand Down

0 comments on commit 4bc28ba

Please sign in to comment.