From 1a35ae9353cdd8c5b3cba6bf8293a705abd219ce Mon Sep 17 00:00:00 2001 From: Navdeep Parhar Date: Fri, 4 Jan 2019 04:15:17 +0000 Subject: [PATCH] cxgbe(4): Clear FW_OK if the firmware reports an error. Sponsored by: Chelsio Communications --- sys/dev/cxgbe/common/t4_hw.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/dev/cxgbe/common/t4_hw.c b/sys/dev/cxgbe/common/t4_hw.c index 90317e500424..7116b38b1639 100644 --- a/sys/dev/cxgbe/common/t4_hw.c +++ b/sys/dev/cxgbe/common/t4_hw.c @@ -211,9 +211,11 @@ static void t4_report_fw_error(struct adapter *adap) u32 pcie_fw; pcie_fw = t4_read_reg(adap, A_PCIE_FW); - if (pcie_fw & F_PCIE_FW_ERR) + if (pcie_fw & F_PCIE_FW_ERR) { CH_ERR(adap, "Firmware reports adapter error: %s\n", reason[G_PCIE_FW_EVAL(pcie_fw)]); + adap->flags &= ~FW_OK; + } } /*