mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/4] wifi: ath12k: recover from a firmware crash during resume
@ 2026-11-12 11:00 Vladyslav Tymoshchuk
  2026-11-12 11:00 ` [PATCH 1/4] wifi: ath12k: disable and enable the CE interrupts only once Vladyslav Tymoshchuk
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Vladyslav Tymoshchuk @ 2026-11-12 11:00 UTC (permalink / raw)
  To: Jeff Johnson; +Cc: Baochen Qiang, linux-wireless, ath12k, linux-kernel

On my device the firmware sometimes crashes during the cold boot of a
resume from s2idle (no WoWLAN, so the device is powered down in
suspend). Without these patches the driver does not recover: the resume
takes 20 s longer, pci_pm_resume returns -110 and the device is dead
until a reboot. Patches 1 and 2 fix that. Patches 3 and 4 fix two
oopses I hit when the firmware crashed more than once in a row while
testing them.

Platform: OnePlus Pad 3 (SM8750) with a WCN7880 hw2.0 (PCI 17cb:110e),
firmware WLAN.GNG.1.0-03342-QCAGNGSWPL_V1.0_V2.0_SILICONZ-1.81206.153.
ath-next does not support this chip; I run it with an out-of-tree patch
that adds it as a WCN7850 derivative, on v7.3-rc5 plus board patches.
For that reason the patches carry no Tested-on tag. On ath-next
(ff4c7359e310) the series is only build tested.

The firmware crash itself is not addressed here; I am sending a
separate report about it. It happened in 1 of 64 and in 1 of 240
suspend cycles.

Tests, all on the tree described above:

- Patches 1-3, crash forced with ath12k_mhi_force_rddm() at the
  ATH12K_QMI_EVENT_FW_READY event of the resume boot: 6 of 6 resumes
  recovered, the link was back 16 s after the resume (6 s without a
  crash). The same build without patch 1 fails like the natural crash
  ("Service connect timeout", "failed to connect to HTT: -110").
- Patches 1-3, no forced crash: 240 suspend cycles, the firmware
  crashed once and the driver recovered, 16 s.
- Patch 4, two forced crashes in a row, the second 3 to 9 s after
  "pdev 0 successfully recovered", followed by "iw scan trigger":
  without the patch the oops in 2 of 2 runs, on the first pair; with
  it 12 pairs without one.

The test hook is not part of the series; I can post it if it is of
use.

Two things I would like comments on:

- Patch 2 lets ath12k_core_resume() return while the reset is still
  running. The alternative I tried, keeping the MHI devices over the
  reset as suspend does (ath12k_hif_power_down(ab, true)), does not
  work: QMI stays silent after the second power up.
- With the series a crash during resume still ends in "Hardware became
  unavailable upon resume" from ieee80211_reconfig(), as the device is
  not up yet when mac80211 resumes, and userspace has to bring the
  interface up again. That is where the 16 s come from. I have not
  tried to change that.

I used an AI assistant (Claude) for the analysis and to draft the
patches and their descriptions; I reviewed the result and ran the tests
on my device.

Vladyslav Tymoshchuk (4):
  wifi: ath12k: disable and enable the CE interrupts only once
  wifi: ath12k: do not wait in resume for a reset that cannot finish
    there
  wifi: ath12k: unregister the thermal devices of a radio only once
  wifi: ath12k: skip the links without a radio when a scan fails

 drivers/net/wireless/ath/ath12k/core.c    | 6 ++++++
 drivers/net/wireless/ath/ath12k/core.h    | 1 +
 drivers/net/wireless/ath/ath12k/mac.c     | 3 +++
 drivers/net/wireless/ath/ath12k/pci.c     | 6 ++++--
 drivers/net/wireless/ath/ath12k/thermal.c | 2 +-
 5 files changed, 15 insertions(+), 3 deletions(-)


base-commit: ff4c7359e310744a7abe53cf66d921fa2969eb19
-- 
2.43.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-11-12 11:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-12 11:00 [PATCH 0/4] wifi: ath12k: recover from a firmware crash during resume Vladyslav Tymoshchuk
2026-11-12 11:00 ` [PATCH 1/4] wifi: ath12k: disable and enable the CE interrupts only once Vladyslav Tymoshchuk
2026-11-12 11:00 ` [PATCH 2/4] wifi: ath12k: do not wait in resume for a reset that cannot finish there Vladyslav Tymoshchuk
2026-11-12 11:00 ` [PATCH 3/4] wifi: ath12k: unregister the thermal devices of a radio only once Vladyslav Tymoshchuk
2026-11-12 11:00 ` [PATCH 4/4] wifi: ath12k: skip the links without a radio when a scan fails Vladyslav Tymoshchuk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®