From: Michael Auer <mick@yoxcu.de>
To: Jeff Johnson <jjohnson@kernel.org>,
Loic Poulain <loic.poulain@oss.qualcomm.com>
Cc: linux-wireless@vger.kernel.org, ath10k@lists.infradead.org,
linux-kernel@vger.kernel.org, Michael Auer <mick@yoxcu.de>
Subject: [PATCH 2/2] wifi: ath10k: report WoW wakeups to the PM core
Date: Fri, 20 Nov 2026 21:26:52 +0100 [thread overview]
Message-ID: <20261120202652.344435-3-mick@yoxcu.de> (raw)
In-Reply-To: <20261120202652.344435-1-mick@yoxcu.de>
ath10k does not report a WoW wakeup to the PM core, so the wakeup
source of the device never counts it, and user space cannot tell a
network wakeup from other resumes. Plasma's powerdevil, for example,
checks the wakeup_count of each wakeup source after resume. It keeps
the display off after a network wakeup and turns it on otherwise.
Call pm_wakeup_event() when the firmware reports a wake reason other
than WOW_REASON_UNSPECIFIED, which it uses when the host resumed for
another reason. iwlwifi does the same since commit 06ae2ad413d2
("iwlwifi: mvm: report wakeup for wowlan").
On a OnePlus 6 the wakeup source of the WLAN device now counts WoW
wakeups, and powerdevil keeps the display off for them.
Tested-on: WCN3990 hw1.0 SNOC WLAN.HL.2.0.c8-00050-QCAHLSWMTPLZ-1
Signed-off-by: Michael Auer <mick@yoxcu.de>
---
drivers/net/wireless/ath/ath10k/wmi.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/net/wireless/ath/ath10k/wmi.c b/drivers/net/wireless/ath/ath10k/wmi.c
index eca6bb189577..c171cd96ac6f 100644
--- a/drivers/net/wireless/ath/ath10k/wmi.c
+++ b/drivers/net/wireless/ath/ath10k/wmi.c
@@ -4675,6 +4675,10 @@ void ath10k_wmi_event_wow_wakeup_host(struct ath10k *ar, struct sk_buff *skb)
ath10k_dbg(ar, ATH10K_DBG_WMI, "wow wakeup host reason %d %s\n",
ev.wake_reason, wow_reason(ev.wake_reason));
+
+ /* UNSPECIFIED: the host resumed for another reason */
+ if (ev.wake_reason != WOW_REASON_UNSPECIFIED)
+ pm_wakeup_event(ar->dev, 0);
}
void ath10k_wmi_event_dcs_interference(struct ath10k *ar, struct sk_buff *skb)
--
2.43.0
prev parent reply other threads:[~2026-11-20 20:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-20 20:26 [PATCH 0/2] wifi: ath10k: Fix WoW wakeups on WCN3990 Michael Auer
2026-11-20 20:26 ` [PATCH 1/2] wifi: ath10k: configure the WoW action frame wakeup filter Michael Auer
2026-11-20 20:26 ` Michael Auer [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261120202652.344435-3-mick@yoxcu.de \
--to=mick@yoxcu.de \
--cc=ath10k@lists.infradead.org \
--cc=jjohnson@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=loic.poulain@oss.qualcomm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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®