All of lore.kernel.org
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Rajkumar Manoharan <rmanoharan@atheros.com>
Cc: linville@tuxdriver.com, linux-wireless@vger.kernel.org
Subject: Re: [PATCH 1/2] mac80211: add monitor interface into PS disable list
Date: Mon, 14 Feb 2011 13:06:27 +0100	[thread overview]
Message-ID: <1297685187.3785.30.camel@jlt3.sipsolutions.net> (raw)
In-Reply-To: <1297253799-9688-1-git-send-email-rmanoharan@atheros.com>

On Wed, 2011-02-09 at 17:46 +0530, Rajkumar Manoharan wrote:
> PS should be disabled in the presence of monitor interface.

I'm not really sure -- should it? You can have monitors with no flags to
do see what you're receiving locally, so I prefer the current behaviour.
If you really want to monitor everything you pretty much need to
disconnect anyway, I think?

johannes

> Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
> ---
>  net/mac80211/mlme.c |   12 ++++++------
>  1 files changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
> index f77adf1..8fc6d35 100644
> --- a/net/mac80211/mlme.c
> +++ b/net/mac80211/mlme.c
> @@ -630,13 +630,13 @@ void ieee80211_recalc_ps(struct ieee80211_local *local, s32 latency)
>  	list_for_each_entry(sdata, &local->interfaces, list) {
>  		if (!ieee80211_sdata_running(sdata))
>  			continue;
> -		if (sdata->vif.type == NL80211_IFTYPE_AP) {
> -			/* If an AP vif is found, then disable PS
> -			 * by setting the count to zero thereby setting
> -			 * ps_sdata to NULL.
> +		if ((sdata->vif.type == NL80211_IFTYPE_AP) ||
> +		    (sdata->vif.type == NL80211_IFTYPE_MONITOR)) {
> +			/* If an AP/monitor vif is found, then disable PS
> +			 * by setting ps_sdata to NULL.
>  			 */
> -			count = 0;
> -			break;
> +			local->ps_sdata = NULL;
> +			goto change;
>  		}
>  		if (sdata->vif.type != NL80211_IFTYPE_STATION)
>  			continue;



  parent reply	other threads:[~2011-02-14 12:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-09 12:16 [PATCH 1/2] mac80211: add monitor interface into PS disable list Rajkumar Manoharan
2011-02-09 12:16 ` [PATCH 2/2] ath9k: disable beaconing before stopping beacon queue Rajkumar Manoharan
2011-02-14 12:06 ` Johannes Berg [this message]
2011-02-14 13:45   ` [PATCH 1/2] mac80211: add monitor interface into PS disable list Rajkumar Manoharan

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=1297685187.3785.30.camel@jlt3.sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=rmanoharan@atheros.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.