linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Kalle Valo <kalle.valo@nokia.com>
Cc: linux-wireless@vger.kernel.org
Subject: Re: [RFC PATCH v1 1/3] mac80211: decrease execution of the associated timer
Date: Mon, 23 Feb 2009 18:13:53 -0800	[thread overview]
Message-ID: <1235441633.4455.61.camel@johannes.local> (raw)
In-Reply-To: <20090223163724.20939.22893.stgit@tikku>

[-- Attachment #1: Type: text/plain, Size: 2188 bytes --]

On Mon, 2009-02-23 at 18:37 +0200, Kalle Valo wrote:
> Currently the timer is triggering every two seconds
> (IEEE80211_MONITORING_INTERVAL). Decrease the timer to only trigger when
> nothing is received to avoid waking up CPU.
> 
> Now there's a functional change that probe requests are sent only when the
> data path is idle, earlier they were sent also while there was activity
> on the data path.
> 
> This is also preparation for beacon filtering support. Thanks to Johannes
> Berg for the idea.
> 
> Signed-off-by: Kalle Valo <kalle.valo@nokia.com>
> ---
> 
>  net/mac80211/ieee80211_i.h |    1 +
>  net/mac80211/mlme.c        |    7 +++++++
>  net/mac80211/rx.c          |    3 +++
>  3 files changed, 11 insertions(+), 0 deletions(-)
> 
> diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h
> index d06c757..7851135 100644
> --- a/net/mac80211/ieee80211_i.h
> +++ b/net/mac80211/ieee80211_i.h
> @@ -1078,6 +1078,7 @@ void ieee80211_dynamic_ps_timer(unsigned long data);
>  void ieee80211_send_nullfunc(struct ieee80211_local *local,
>  			     struct ieee80211_sub_if_data *sdata,
>  			     int powersave);
> +void ieee80211_rx_trigger(struct ieee80211_sub_if_data *sdata);

I think that could have a better name maybe? _sta_rx_notify?

>  void ieee80211_wake_queues_by_reason(struct ieee80211_hw *hw,
>  				     enum queue_stop_reason reason);
> diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
> index 5a49779..b3caac0 100644
> --- a/net/mac80211/mlme.c
> +++ b/net/mac80211/mlme.c
> @@ -911,6 +911,13 @@ static void ieee80211_associate(struct ieee80211_sub_if_data *sdata)
>  	mod_timer(&ifmgd->timer, jiffies + IEEE80211_ASSOC_TIMEOUT);
>  }
>  
> +void ieee80211_rx_trigger(struct ieee80211_sub_if_data *sdata)
> +{
> +	if (sdata->vif.type == NL80211_IFTYPE_STATION) {
> +		mod_timer(&sdata->u.mgd.timer,
> +			  jiffies + IEEE80211_MONITORING_INTERVAL);
> +	}

Should we have the sta check outside the function? Seems a little odd to
have a check in a file that only contains STATION mode code.

Other than that, looks good to me. I'd have thought this would be more
complicated :)

johannes

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2009-02-24  2:55 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-23 16:37 [RFC PATCH v1 0/3] mac80211: beacon filtering Kalle Valo
2009-02-23 16:37 ` [RFC PATCH v1 1/3] mac80211: decrease execution of the associated timer Kalle Valo
2009-02-24  2:13   ` Johannes Berg [this message]
2009-02-24 18:40     ` Kalle Valo
2009-02-23 16:37 ` [RFC PATCH v1 2/3] mac80211: track beacons separately from the rx path activity Kalle Valo
2009-02-24  2:15   ` Johannes Berg
2009-02-24 18:52     ` Kalle Valo
2009-02-23 16:37 ` [RFC PATCH v1 3/3] mac80211: add beacon filtering support Kalle Valo
2009-02-23 17:47   ` Luis R. Rodriguez
2009-02-23 19:06     ` Kalle Valo
2009-02-23 19:11       ` Luis R. Rodriguez
2009-02-23 19:31         ` Kalle Valo
2009-02-23 19:58           ` Luis R. Rodriguez
2009-02-24  4:46           ` Luis R. Rodriguez
2009-02-24  5:17             ` Johannes Berg
2009-02-24  8:58             ` Jouni Malinen
2009-02-24  2:18       ` Johannes Berg
2009-02-24 20:34         ` Kalle Valo
2009-02-24  2:20   ` Johannes Berg
2009-02-24  9:01     ` Jouni Malinen
2009-02-24 18:36       ` Kalle Valo
2009-02-24 18:43         ` Jouni Malinen
2009-02-24 19:02           ` Kalle Valo
2009-02-24 18:30     ` Kalle Valo
2009-02-23 17:15 ` [PATCH] stlc45xx: " Kalle Valo

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=1235441633.4455.61.camel@johannes.local \
    --to=johannes@sipsolutions.net \
    --cc=kalle.valo@nokia.com \
    --cc=linux-wireless@vger.kernel.org \
    /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).