linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kalle Valo <kalle.valo@nokia.com>
To: "Johannes Berg" <johannes@sipsolutions.net>
Cc: "Luis R. Rodriguez" <mcgrof@gmail.com>,
	linux-wireless <linux-wireless@vger.kernel.org>,
	Zhu Yi <yi.zhu@intel.com>
Subject: Re: Power saving on mac80211
Date: Sun, 19 Oct 2008 14:00:52 +0300	[thread overview]
Message-ID: <871vyc7st7.fsf@nokia.com> (raw)
In-Reply-To: <1224412006.6324.45.camel@johannes.berg> (ext Johannes Berg's message of "Sun\, 19 Oct 2008 12\:26\:46 +0200")

Johannes Berg <johannes@sipsolutions.net> writes:

> On Sun, 2008-10-19 at 10:24 +0300, Kalle Valo wrote:
>
>> Oh, I forgot about beacon filtering. stlc45xx firmware (but no support
>> in driver yet) supports beacon filtering in PSM mode, meaning that the
>> beacons are not delivered to the host (not even DTIM beacons). This
>> improves power consumption because the host CPU is not woken up all
>> the time.
>> 
>> I'm sure that stlc4560 isn't the only chip supporting this feature
>> because it's quite essential in low power devices. I have been
>> planning to implement support to mac80211 in the near future. Though
>> don't know yet what is needed, I haven't investigated this at all.
>
> I thought about it recently, it's fairly easy.

Marvellous :)

> As a preliminary step, I'd change mac80211 to not trigger the timer
> continuously, but rather reset it ever time we get a beacon from the AP,
> so that the timer only fires when we haven't seen a beacon for too long.
> This helps with powersave already because then we only wake up for
> beacons, not for the timer too.

This makes sense, all extra timers are bad. I'll try come up with a
patch next week.

> Then add a new flag to mac80211 hw description that says "driver will
> watch beacons". This means that the code above that rearms the timer for
> the future 'nothing from AP' check is skipped.

I will. I need to check that if the "firmware beacon watch" is enabled
only when PSM is enabled. If it is, we might have to make the flag
dynamic.

> Also add a way for mac80211 to tell the driver after how many beacons
> (or calculate the timeout in ms, it's convertible) it should tell
> mac80211 about the situation. Finally, to make it possible to have the
> driver tell mac80211, extend the MLME callback (ieee80211_notify_mac)

The beacon filtering in stlc4560 works so that a beacon is passed to
the host only when the TIM bit for the AID is set. There isn't any
timeout for delivering beacons to the host, if the data path is idle
for 24 hours, mac80211 will not receive any beacons for the 24 hours.
I don't see why we need a timeout here.

I believe that there's also a feature in stlc4560 that the driver can
provide a checksum of the beacon and the firmware will send the beacon
if checksum doesn't match. But I don't yet know how that works in
practise.

-- 
Kalle Valo

  reply	other threads:[~2008-10-19 11:01 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-18  1:10 Power saving on mac80211 Luis R. Rodriguez
2008-10-18  1:14 ` Luis R. Rodriguez
2008-10-18  1:45 ` Bob Copeland
2008-10-19  5:41 ` Kalle Valo
2008-10-19  7:24   ` Kalle Valo
2008-10-19 10:26     ` Johannes Berg
2008-10-19 11:00       ` Kalle Valo [this message]
2008-10-19 16:48         ` Johannes Berg
2008-10-19 18:12           ` Kalle Valo
2008-10-19 18:49             ` Johannes Berg
2008-10-20  1:46             ` Luis R. Rodriguez
2008-10-20  5:23               ` Kalle Valo
2008-10-20  6:34                 ` Luis R. Rodriguez
2008-10-20  6:15               ` Johannes Berg
2008-10-20  8:24                 ` Tomas Winkler
2008-10-20  5:23 ` Zhu Yi
2008-10-23  2:42 ` Luis R. Rodriguez

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=871vyc7st7.fsf@nokia.com \
    --to=kalle.valo@nokia.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=mcgrof@gmail.com \
    --cc=yi.zhu@intel.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;
as well as URLs for NNTP newsgroup(s).