[PATCH] wpa_supplicant, nl80211: ieee80211 power save support

Janusz Dziedzic janusz.dziedzic at gmail.com
Fri Nov 25 09:10:49 EST 2011


2011/11/25 Jouni Malinen <j at w1.fi>:
> On Wed, Jul 20, 2011 at 10:54:27AM +0300, Janusz.Dziedzic at tieto.com wrote:
>> Support for enabling/disabling/monitoring
>> current mode of ieee80211 power save.
>
>> diff --git a/src/drivers/driver.h b/src/drivers/driver.h
>> @@ -2274,6 +2274,28 @@ struct wpa_driver_ops {
>> +     int (*set_powersave)(void *priv, int enable);
>
> A new driver_ops callback is not really needed for this. The existing
> set_p2p_powersave() can be used for this (legacy_ps parameter).
>
>> +     int (*get_powersave)(void *priv, int *enabled);
>
> What is the use case for this?
>
>> diff --git a/wpa_supplicant/wpa_cli.c b/wpa_supplicant/wpa_cli.c
>> +     { "ieee80211_ps", wpa_cli_ieee80211_ps,
>> +       cli_cmd_flag_none,
>> +       "<enable|disable|show>" },
>
> "p2p_set ps <0/1>" can be used to enable/disable legacy PS.
>
> I added an initial set_p2p_powersave() implementation for nl80211, so
> the enabling/disabling part should now be available and I don't think we
> need the additional commands from this patch.
>
What in case we don't support p2p then?

I posted this change long time ago.
This commands were very usefull during features veryfication with/without PS.
Currently we enabled this by default in the driver.

I also saw some implementation that disable/enabled PS in android
environtment "DRIVER POWERMODE" - why, I am not sure. I can suspect,
they enable PS after will get IP address from DHCP. With some APs
there are problems with getting IP address via DHCP when PS enabled.
Seems some workaround activated from usermode.

BR
Janusz


More information about the HostAP mailing list