linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Luis R. Rodriguez" <mcgrof@do-not-panic.com>
To: linville@tuxdriver.com, johannes@sipsolutions.net
Cc: linux-wireless@vger.kernel.org, janusz.dziedzic@tieto.com,
	smihir@qti.qualcomm.com, tushnimb@qca.qualcomm.com,
	"Luis R. Rodriguez" <mcgrof@do-not-panic.com>
Subject: [PATCH 3/5] ath: rename ath_reg_apply_active_scan_flags() to ath_reg_apply_ir_flags()
Date: Mon, 21 Oct 2013 19:14:49 +0200	[thread overview]
Message-ID: <1382375691-25476-4-git-send-email-mcgrof@do-not-panic.com> (raw)
In-Reply-To: <1382375691-25476-1-git-send-email-mcgrof@do-not-panic.com>

This also applies the no-ibss flag to the channels or clears it.
The idea here is to clarify no initiated radiation should be
allowed on these channels.

Cc: smihir@qti.qualcomm.com
Cc: tushnimb@qca.qualcomm.com
Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
---
 drivers/net/wireless/ath/regd.c | 11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/drivers/net/wireless/ath/regd.c b/drivers/net/wireless/ath/regd.c
index 48e2368..2188fdd 100644
--- a/drivers/net/wireless/ath/regd.c
+++ b/drivers/net/wireless/ath/regd.c
@@ -189,6 +189,10 @@ static void ath_force_clear_no_ir_chan(struct wiphy *wiphy,
 	if (!(reg_rule->flags & NL80211_RRF_PASSIVE_SCAN))
 		if (ch->flags & IEEE80211_CHAN_PASSIVE_SCAN)
 			ch->flags &= ~IEEE80211_CHAN_PASSIVE_SCAN;
+
+	if (!(reg_rule->flags & IEEE80211_CHAN_NO_IBSS))
+		if (ch->flags & IEEE80211_CHAN_NO_IBSS)
+			ch->flags &= ~IEEE80211_CHAN_NO_IBSS;
 }
 
 static void ath_force_clear_no_ir_freq(struct wiphy *wiphy, u16 center_freq)
@@ -205,6 +209,7 @@ static void ath_force_clear_no_ir_freq(struct wiphy *wiphy, u16 center_freq)
 static void ath_force_no_ir_chan(struct ieee80211_channel *ch)
 {
 	ch->flags |= IEEE80211_CHAN_PASSIVE_SCAN;
+	ch->flags |= IEEE80211_CHAN_NO_IBSS;
 }
 
 static void ath_force_no_ir_freq(struct wiphy *wiphy, u16 center_freq)
@@ -283,7 +288,7 @@ ath_reg_apply_beaconing_flags(struct wiphy *wiphy,
 }
 
 /**
- * ath_reg_apply_active_scan_flags()
+ * ath_reg_apply_ir_flags()
  * @wiphy: the wiphy to use
  * @initiator: the regulatory hint initiator
  *
@@ -297,7 +302,7 @@ ath_reg_apply_beaconing_flags(struct wiphy *wiphy,
  * custom regulatory domain.
  */
 static void
-ath_reg_apply_active_scan_flags(struct wiphy *wiphy,
+ath_reg_apply_ir_flags(struct wiphy *wiphy,
 				enum nl80211_reg_initiator initiator)
 {
 	struct ieee80211_supported_band *sband;
@@ -364,7 +369,7 @@ static void ath_reg_apply_world_flags(struct wiphy *wiphy,
 		break;
 	case 0x68:
 		ath_reg_apply_beaconing_flags(wiphy, initiator);
-		ath_reg_apply_active_scan_flags(wiphy, initiator);
+		ath_reg_apply_ir_flags(wiphy, initiator);
 		break;
 	}
 }
-- 
1.8.4.rc3


  parent reply	other threads:[~2013-10-21 17:15 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-21 17:14 [PATCH 0/5] ath: simplify radar / beaconing flag settings Luis R. Rodriguez
2013-10-21 17:14 ` [PATCH 1/5] ath: fix logic on ath_reg_apply_active_scan_flags() Luis R. Rodriguez
2013-10-21 17:14 ` [PATCH 2/5] ath: clean up ath_reg_apply_active_scan_flags() Luis R. Rodriguez
2013-10-29 16:19   ` Shete, Mihir
2013-10-29 18:34     ` Luis R. Rodriguez
2013-10-21 17:14 ` Luis R. Rodriguez [this message]
2013-10-21 17:14 ` [PATCH 4/5] ath: simplify ath_reg_apply_beaconing_flags() Luis R. Rodriguez
2013-10-21 17:14 ` [PATCH 5/5] ath: move the channel for ath_reg_apply_beaconing_flags() into helper 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=1382375691-25476-4-git-send-email-mcgrof@do-not-panic.com \
    --to=mcgrof@do-not-panic.com \
    --cc=janusz.dziedzic@tieto.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.com \
    --cc=smihir@qti.qualcomm.com \
    --cc=tushnimb@qca.qualcomm.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).