diff mbox series

[1/6] ath11k: mhi: print a warning if firmware crashed

Message ID 1607609124-17250-2-git-send-email-kvalo@codeaurora.org
State New
Headers show
Series ath11k: QCA6390 stability fixes | expand

Commit Message

Kalle Valo Dec. 10, 2020, 2:05 p.m. UTC
There was no way to detect if the firmware crashed so add a warning. At the
moment the firmware is not restarted or anything like that, so when this
happens ath11k modules need to be reloaded.

Tested-on: QCA6390 hw2.0 PCI WLAN.HST.1.0.1-01740-QCAHSTSWPLZ_V2_TO_X86-1

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
---
 drivers/net/wireless/ath/ath11k/mhi.c | 9 +++++++++
 1 file changed, 9 insertions(+)

Comments

Kalle Valo Dec. 12, 2020, 4:40 a.m. UTC | #1
Kalle Valo <kvalo@codeaurora.org> wrote:

> There was no way to detect if the firmware crashed so add a warning. At the

> moment the firmware is not restarted or anything like that, so when this

> happens ath11k modules need to be reloaded.

> 

> Tested-on: QCA6390 hw2.0 PCI WLAN.HST.1.0.1-01740-QCAHSTSWPLZ_V2_TO_X86-1

> 

> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


6 patches applied to ath-next branch of ath.git, thanks.

fc46e1b2a24a ath11k: mhi: print a warning if firmware crashed
43ed15e1ee01 ath11k: put hw to DBS using WMI_PDEV_SET_HW_MODE_CMDID
babb0ced6acd ath11k: pci: fix hot reset stability issues
0699940755e9 ath11k: pci: fix L1ss clock unstable problem
0ccdf4398827 ath11k: pci: disable VDD4BLOW
f57ad6a9885e ath11k: Fix incorrect tlvs in scan start command

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/1607609124-17250-2-git-send-email-kvalo@codeaurora.org/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
diff mbox series

Patch

diff --git a/drivers/net/wireless/ath/ath11k/mhi.c b/drivers/net/wireless/ath/ath11k/mhi.c
index 47a1ce1bee4f..4cf093718888 100644
--- a/drivers/net/wireless/ath/ath11k/mhi.c
+++ b/drivers/net/wireless/ath/ath11k/mhi.c
@@ -190,6 +190,15 @@  static void ath11k_mhi_op_runtime_put(struct mhi_controller *mhi_cntrl)
 static void ath11k_mhi_op_status_cb(struct mhi_controller *mhi_cntrl,
 				    enum mhi_callback cb)
 {
+	struct ath11k_base *ab = dev_get_drvdata(mhi_cntrl->cntrl_dev);
+
+	switch (cb) {
+	case MHI_CB_SYS_ERROR:
+		ath11k_warn(ab, "firmware crashed: MHI_CB_SYS_ERROR\n");
+		break;
+	default:
+		break;
+	}
 }
 
 static int ath11k_mhi_op_read_reg(struct mhi_controller *mhi_cntrl,