diff options
author | Wey-Yi Guy <wey-yi.w.guy@intel.com> | 2009-04-20 17:37:00 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-04-22 16:57:19 -0400 |
commit | 279b05d4362472ae9269f982f00e644265bdbf94 (patch) | |
tree | ab919727ebb69a6d88e4285beb45254a0891eae0 /drivers/net/wireless/iwlwifi/iwl3945-base.c | |
parent | 86ddbf62c2daefebba13e3c79f88cbdfde766176 (diff) |
iwlwifi: clean up unused NL80211_IFTYPE_MONITOR for Monitor mode
This patch clean up the code for NL80211_IFTYPE_MONITOR mode,
priv->iw_mode is set in add_interface, but add_interface is never called
for monitor mode.
The only way mac80211 informs us about monitor mode is through
configuring filter; since iw_mode will never set to
NL80211_IFTYPE_MONITOR, modify and remove all the code refer to
NL80211_IFTYPE_MONITOR and replace with iwl_is_monitor_mode() function
call.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl3945-base.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl3945-base.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index 562dd76226cc..c9fde0e0c982 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c | |||
@@ -729,7 +729,7 @@ static int iwl3945_tx_skb(struct iwl_priv *priv, struct sk_buff *skb) | |||
729 | 729 | ||
730 | /* drop all data frame if we are not associated */ | 730 | /* drop all data frame if we are not associated */ |
731 | if (ieee80211_is_data(fc) && | 731 | if (ieee80211_is_data(fc) && |
732 | (priv->iw_mode != NL80211_IFTYPE_MONITOR) && /* packet injection */ | 732 | (!iwl_is_monitor_mode(priv)) && /* packet injection */ |
733 | (!iwl_is_associated(priv) || | 733 | (!iwl_is_associated(priv) || |
734 | ((priv->iw_mode == NL80211_IFTYPE_STATION) && !priv->assoc_id))) { | 734 | ((priv->iw_mode == NL80211_IFTYPE_STATION) && !priv->assoc_id))) { |
735 | IWL_DEBUG_DROP(priv, "Dropping - !iwl_is_associated\n"); | 735 | IWL_DEBUG_DROP(priv, "Dropping - !iwl_is_associated\n"); |
@@ -3113,7 +3113,7 @@ static void iwl3945_bg_request_scan(struct work_struct *data) | |||
3113 | /* select Rx antennas */ | 3113 | /* select Rx antennas */ |
3114 | scan->flags |= iwl3945_get_antenna_flags(priv); | 3114 | scan->flags |= iwl3945_get_antenna_flags(priv); |
3115 | 3115 | ||
3116 | if (priv->iw_mode == NL80211_IFTYPE_MONITOR) | 3116 | if (iwl_is_monitor_mode(priv)) |
3117 | scan->filter_flags = RXON_FILTER_PROMISC_MSK; | 3117 | scan->filter_flags = RXON_FILTER_PROMISC_MSK; |
3118 | 3118 | ||
3119 | scan->channel_count = | 3119 | scan->channel_count = |