Search Linux Wireless

Re: [RFC] wl1251: Add support for idle mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Moro Jarkko,

Jarkko Nikula <jhnikula@xxxxxxxxx> writes:

> This patch adds support for the mac80211 idle notifications. Chip is put into
> idle very much the same way when entering into PSM by utilizing the Extreme
> Low Power (ELP) mode. I.e. idle is entered by first setting necessary
> conditions with psm flag set and then via calling the wl1251_ps_elp_sleep.

Good stuff! Thank you very much for working on this.

> It seems it is just enough the authorize ELP mode followed by
> CMD_DISCONNECT (thanks to Kalle Valo about the idea to use it).

Actually I was expecting that you would first issue the disconnect
command and only then enable elp. The thing is that for sending
commands we need to wakeup firmware from elp, so enabling elp last
makes more sense. Was there a reason why you did it in this order?

> - There is still problem that the consumtion jumps again ~+180 mA after
>   disconnection happens. Reason is the BSS_LOSE_EVENT which puts the chip
>   again into active mode and driver doesn't receive an idle mode request
>   after that. For me it looks the driver doesn't notify the mac80211
>   properly and thus no idle mode request is coming.

Yes, that's an existing bug in wl1251. It should call either
mac80211_beacon_loss() or mac80211_connection_loss() after the event.

> As this patch doesn't affect that I see that is better to handle
> separately.

Agreed.

> --- a/drivers/net/wireless/wl1251/cmd.h
> +++ b/drivers/net/wireless/wl1251/cmd.h
> @@ -314,7 +314,8 @@ struct wl1251_cmd_vbm_update {
>  
>  enum wl1251_cmd_ps_mode {
>  	STATION_ACTIVE_MODE,
> -	STATION_POWER_SAVE_MODE
> +	STATION_POWER_SAVE_MODE,
> +	STATION_IDLE,
>  };

My idea was that cmd and acx files contain only the firmware
interface, nothing more. I assume that firmware knows nothing this new
value, right?

Another way to do this would be that you create a new state enum to
wl1251.h with the three states above and then change
wl1251_ps_set_mode(), and it's callers, to use the new enum. That way
you can keep cmd.h intact.

Also I'm guessing that in the future we need to store the new state
enum to struct wl1251.

-- 
Kalle Valo
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux