Linux wireless drivers development
 help / color / mirror / Atom feed
From: Tomas Winkler <tomas.winkler@intel.com>
To: linville@tuxdriver.com, johannes@sipsolutions.net, yi.zhu@intel.com
Cc: linux-wireless@vger.kernel.org, Assaf Krauss <assaf.krauss@intel.com>
Subject: [RFC PATCH 2/2] mac80211: workaround for resetting the tx power
Date: Thu, 19 Jun 2008 21:35:12 +0300	[thread overview]
Message-ID: <1213900512-21565-2-git-send-email-tomas.winkler@intel.com> (raw)
In-Reply-To: <1213900512-21565-1-git-send-email-tomas.winkler@intel.com>

From: Assaf Krauss <assaf.krauss@intel.com>

This patch is a workaround for the unreliable disassociation
flow. The resetting of the tx power is now performed upon
association/reassociation.

Signed-off-by: Assaf Krauss <assaf.krauss@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
---
 net/mac80211/mlme.c |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
index 313b02a..378ccd5 100644
--- a/net/mac80211/mlme.c
+++ b/net/mac80211/mlme.c
@@ -2148,6 +2148,19 @@ static void ieee80211_rx_mgmt_assoc_resp(struct ieee80211_sub_if_data *sdata,
 	/* AssocResp and ReassocResp have identical structure, so process both
 	 * of them in this function. */
 
+	/***********************************************************
+	 * Workaround - Until disassociation flow is trustworthy...
+	 ***********************************************************/
+	/* Reset power level. Get the tx power from the current channel/user.*/
+	if (ifsta->country_max_pwr || local->hw.conf.tpc_pwr_limit) {
+		ifsta->country_max_pwr = 0;
+		local->hw.conf.tpc_pwr_limit = 0;
+		ieee80211_hw_config(local);
+	}
+	/***********************************************************
+	 * End of Workaround
+	 ***********************************************************/
+
 	if (ifsta->state != IEEE80211_ASSOCIATE) {
 		printk(KERN_DEBUG "%s: association frame received from "
 		       "%s, but not in associate state - ignored\n",
-- 
1.5.4.1

---------------------------------------------------------------------
Intel Israel (74) Limited

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


  reply	other threads:[~2008-06-19 18:35 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-19 18:35 [RFC PATCH 1/2] mac80211: 11d Handling - Country Information Element Tomas Winkler
2008-06-19 18:35 ` Tomas Winkler [this message]
2008-06-19 19:04   ` [RFC PATCH 2/2] mac80211: workaround for resetting the tx power Johannes Berg
2008-06-19 20:26     ` Tomas Winkler
2008-06-19 19:03 ` [RFC PATCH 1/2] mac80211: 11d Handling - Country Information Element Johannes Berg
2008-06-19 20:16   ` Tomas Winkler
2008-06-19 20:18     ` Johannes Berg
2008-06-19 20:29       ` Tomas Winkler
2008-06-19 22:04         ` David Miller
2008-06-19 22:32           ` Tomas Winkler
2008-07-23 13:15             ` Luis R. Rodriguez
2008-07-23 15:02               ` Tomas Winkler

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=1213900512-21565-2-git-send-email-tomas.winkler@intel.com \
    --to=tomas.winkler@intel.com \
    --cc=assaf.krauss@intel.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.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