Re: [PATCH v2 2/2] wifi: rtw88: ps: Trigger firmware recovery when failing to leave LPS state

From: Luka Gejak

Date: Sat Nov 07 2026 - 02:48:25 EST


Hi Kalpesh,

Thanks for the quick reply. I just have a few things to add.

[ ... ]

> Clearing RTW_FLAG_RESTARTING (and resetting the hang counter) in
> rtw_ops_stop() sounds like the right way to handle it.

That is fine for the flag, but I think the counter should be reset in
rtw_core_start(), like rtw89 does. A normal recovery never calls
rtw_ops_stop(), so the counter would stay at the limit and the next
single timeout would recover again.

> I can prepare a 2-patch follow-up series:
> 1. wifi: rtw88: ps: trigger recovery only after consecutive LPS leave failures
> 2. wifi: rtw88: clear RTW_FLAG_RESTARTING in rtw_ops_stop()

The RESTARTING gap predates your patch, since 5c831644e1f4 ("rtw88:
handle and recover when firmware crash"), so that one could go on its
own with a Fixes: tag.

For the counter, maybe it is cleaner to revert 2/2 (or rebase and drop
it since it is currently the HEAD commit of rtw-next) and send a new
patch, since it replaces that line anyway and keeps the current
behavior out of the next pull. 1/2 is fine as it is. Ping-Ke, would
that work for you, or do you prefer a follow up?

Also Kalpesh, your replies don't carry In-Reply-To or References, so
lore shows them as separate threads. In case you are using git send-email
git send-email --in-reply-to=<Message-ID>
should fix that.

Best regards,
Luka Gejak