ath11k.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* QCA6390 power saving issue
@ 2022-03-29  8:11 Mark Herbert
  2022-03-30  8:00 ` Kalle Valo
  0 siblings, 1 reply; 4+ messages in thread
From: Mark Herbert @ 2022-03-29  8:11 UTC (permalink / raw)
  To: ath11k

I remember there was a bug preventing CPU entering to deep powersaving 
states so only PC3 was reached.

The but itself is fixed - but I have just noticed a small remaining 
issue. When I start my PC and there is no WIFI that I can connect so 
ath11  is enabled but not connected to any network - it   prevents 
entering into deep PC states again. When I connect to the WiFi network - 
deep PC states become reachable again. And when I disconnect after first 
connection  and keep my ath11k disconnected (exactly same situation as 
immediately after boot)- there is no issue.

So seems that this powersaving feature is not activated on boot but only 
activates when the card connects to access point.  I am not good enough 
in driver development and design a fix myself. So just writing here


-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

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

* Re: QCA6390 power saving issue
  2022-03-29  8:11 QCA6390 power saving issue Mark Herbert
@ 2022-03-30  8:00 ` Kalle Valo
       [not found]   ` <da91be76-d609-ba29-76e6-5365ea1db9d4@gmail.com>
  0 siblings, 1 reply; 4+ messages in thread
From: Kalle Valo @ 2022-03-30  8:00 UTC (permalink / raw)
  To: Mark Herbert; +Cc: ath11k

Mark Herbert <mark.herbert42@gmail.com> writes:

> I remember there was a bug preventing CPU entering to deep powersaving
> states so only PC3 was reached.
>
> The but itself is fixed - but I have just noticed a small remaining
> issue. When I start my PC and there is no WIFI that I can connect so
> ath11  is enabled but not connected to any network - it   prevents
> entering into deep PC states again. When I connect to the WiFi network
> - 
> deep PC states become reachable again. And when I disconnect after
> first connection  and keep my ath11k disconnected (exactly same
> situation as immediately after boot)- there is no issue.
>
> So seems that this powersaving feature is not activated on boot but
> only activates when the card connects to access point.  I am not good
> enough in driver development and design a fix myself. So just writing
> here

Seems very plausible to me. Can you file this to bugzilla, please?
Easier to track that way:

https://wireless.wiki.kernel.org/en/users/drivers/ath11k/bugreport

-- 
https://patchwork.kernel.org/project/linux-wireless/list/

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

-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

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

* Re: QCA6390 power saving issue
       [not found]   ` <da91be76-d609-ba29-76e6-5365ea1db9d4@gmail.com>
@ 2022-03-30 12:47     ` Kalle Valo
  2022-05-17 16:47       ` Mark Herbert
  0 siblings, 1 reply; 4+ messages in thread
From: Kalle Valo @ 2022-03-30 12:47 UTC (permalink / raw)
  To: Mark Herbert; +Cc: ath11k

+ ath11k list

Mark Herbert <mark.herbert42@gmail.com> writes:

> Done - https://bugzilla.kernel.org/show_bug.cgi?id=215775

Thanks!

> Checked the previous bug - the powersave activation is done only on
> change of something - so when the driver is loaded but never connected
> so this IF did not become true at least one time - the powersave is
> not yet enabled and card remains in the initial setting keeping PC3 as
> a lowest state. Seems that when we initialize the driver we need to
> call this ath11k_mac_config_ps(ar) one time - then on each change of
> the connection the current code will handle that.
>
> @@ -2942,6 +3019,16 @@ static void ath11k_mac_op_bss_info_changed(struct ieee80211_hw
> *hw,
> ath11k_mac_txpower_recalc(ar);
> }
> + if (changed & BSS_CHANGED_PS &&
> + ar->ab->hw_params.supports_sta_ps) {
> + arvif->ps = vif->bss_conf.ps;
> +
> + ret = ath11k_mac_config_ps(ar);
> + if (ret)
> + ath11k_warn(ar->ab, "failed to setup ps on vdev %i: %d\n",
> + arvif->vdev_id, ret);
> + }

Didn't check the code, but makes sense. Can you or someone else send a
patch, please?

-- 
https://patchwork.kernel.org/project/linux-wireless/list/

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

-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

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

* Re: QCA6390 power saving issue
  2022-03-30 12:47     ` Kalle Valo
@ 2022-05-17 16:47       ` Mark Herbert
  0 siblings, 0 replies; 4+ messages in thread
From: Mark Herbert @ 2022-05-17 16:47 UTC (permalink / raw)
  To: Kalle Valo; +Cc: ath11k

I have tried modification proposed by Wi - but still same situation.

Also I've tried to go same direction and injected the call to the psmode 
enabling fuction in multiple places of the mac.c file. Enable debug mask 
for mac events - and I see that the code is called many times now. But 
still no effect - until the first connection to network happens no PC 
states more than PC3 are reached.


When first connect happens - all good till reboot or hibernate.


On 3/30/22 15:47, Kalle Valo wrote:
> + ath11k list
>
> Mark Herbert <mark.herbert42@gmail.com> writes:
>
>> Done - https://bugzilla.kernel.org/show_bug.cgi?id=215775
> Thanks!
>
>> Checked the previous bug - the powersave activation is done only on
>> change of something - so when the driver is loaded but never connected
>> so this IF did not become true at least one time - the powersave is
>> not yet enabled and card remains in the initial setting keeping PC3 as
>> a lowest state. Seems that when we initialize the driver we need to
>> call this ath11k_mac_config_ps(ar) one time - then on each change of
>> the connection the current code will handle that.
>>
>> @@ -2942,6 +3019,16 @@ static void ath11k_mac_op_bss_info_changed(struct ieee80211_hw
>> *hw,
>> ath11k_mac_txpower_recalc(ar);
>> }
>> + if (changed & BSS_CHANGED_PS &&
>> + ar->ab->hw_params.supports_sta_ps) {
>> + arvif->ps = vif->bss_conf.ps;
>> +
>> + ret = ath11k_mac_config_ps(ar);
>> + if (ret)
>> + ath11k_warn(ar->ab, "failed to setup ps on vdev %i: %d\n",
>> + arvif->vdev_id, ret);
>> + }
> Didn't check the code, but makes sense. Can you or someone else send a
> patch, please?
>

-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

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

end of thread, other threads:[~2022-05-17 16:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-03-29  8:11 QCA6390 power saving issue Mark Herbert
2022-03-30  8:00 ` Kalle Valo
     [not found]   ` <da91be76-d609-ba29-76e6-5365ea1db9d4@gmail.com>
2022-03-30 12:47     ` Kalle Valo
2022-05-17 16:47       ` Mark Herbert

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).