aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2010-01-23 03:31:06 -0500
committerDavid S. Miller <davem@davemloft.net>2010-01-23 03:31:06 -0500
commit51c24aaacaea90c8e87f1dec75a2ac7622b593f8 (patch)
tree9f54936c87764bef75e97395cb56b7d1e0df24c6 /drivers/net/wireless/iwlwifi
parent4276e47e2d1c85a2477caf0d22b91c4f2377fba8 (diff)
parent6be325719b3e54624397e413efd4b33a997e55a3 (diff)
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Diffstat (limited to 'drivers/net/wireless/iwlwifi')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-4965.c2
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-5000.c5
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-core.c45
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-dev.h2
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-devtrace.c26
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-devtrace.h26
6 files changed, 84 insertions, 22 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c
index cee368d4859f..6a004abb5973 100644
--- a/drivers/net/wireless/iwlwifi/iwl-4965.c
+++ b/drivers/net/wireless/iwlwifi/iwl-4965.c
@@ -1961,7 +1961,7 @@ static void iwl4965_rx_reply_tx(struct iwl_priv *priv,
1961 struct ieee80211_tx_info *info; 1961 struct ieee80211_tx_info *info;
1962 struct iwl4965_tx_resp *tx_resp = (void *)&pkt->u.raw[0]; 1962 struct iwl4965_tx_resp *tx_resp = (void *)&pkt->u.raw[0];
1963 u32 status = le32_to_cpu(tx_resp->u.status); 1963 u32 status = le32_to_cpu(tx_resp->u.status);
1964 int tid = MAX_TID_COUNT - 1; 1964 int uninitialized_var(tid);
1965 int sta_id; 1965 int sta_id;
1966 int freed; 1966 int freed;
1967 u8 *qc = NULL; 1967 u8 *qc = NULL;
diff --git a/drivers/net/wireless/iwlwifi/iwl-5000.c b/drivers/net/wireless/iwlwifi/iwl-5000.c
index c3f8ec0a38b1..c6120f0b8f98 100644
--- a/drivers/net/wireless/iwlwifi/iwl-5000.c
+++ b/drivers/net/wireless/iwlwifi/iwl-5000.c
@@ -1600,6 +1600,7 @@ struct iwl_cfg iwl5300_agn_cfg = {
1600 .use_bsm = false, 1600 .use_bsm = false,
1601 .ht_greenfield_support = true, 1601 .ht_greenfield_support = true,
1602 .led_compensation = 51, 1602 .led_compensation = 51,
1603 .use_rts_for_ht = true, /* use rts/cts protection */
1603 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, 1604 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1604}; 1605};
1605 1606
@@ -1623,6 +1624,7 @@ struct iwl_cfg iwl5100_bgn_cfg = {
1623 .use_bsm = false, 1624 .use_bsm = false,
1624 .ht_greenfield_support = true, 1625 .ht_greenfield_support = true,
1625 .led_compensation = 51, 1626 .led_compensation = 51,
1627 .use_rts_for_ht = true, /* use rts/cts protection */
1626 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, 1628 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1627}; 1629};
1628 1630
@@ -1668,6 +1670,7 @@ struct iwl_cfg iwl5100_agn_cfg = {
1668 .use_bsm = false, 1670 .use_bsm = false,
1669 .ht_greenfield_support = true, 1671 .ht_greenfield_support = true,
1670 .led_compensation = 51, 1672 .led_compensation = 51,
1673 .use_rts_for_ht = true, /* use rts/cts protection */
1671 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, 1674 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1672}; 1675};
1673 1676
@@ -1691,6 +1694,7 @@ struct iwl_cfg iwl5350_agn_cfg = {
1691 .use_bsm = false, 1694 .use_bsm = false,
1692 .ht_greenfield_support = true, 1695 .ht_greenfield_support = true,
1693 .led_compensation = 51, 1696 .led_compensation = 51,
1697 .use_rts_for_ht = true, /* use rts/cts protection */
1694 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, 1698 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1695}; 1699};
1696 1700
@@ -1714,6 +1718,7 @@ struct iwl_cfg iwl5150_agn_cfg = {
1714 .use_bsm = false, 1718 .use_bsm = false,
1715 .ht_greenfield_support = true, 1719 .ht_greenfield_support = true,
1716 .led_compensation = 51, 1720 .led_compensation = 51,
1721 .use_rts_for_ht = true, /* use rts/cts protection */
1717 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, 1722 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1718}; 1723};
1719 1724
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c
index 14f482960d7f..5b56307a3812 100644
--- a/drivers/net/wireless/iwlwifi/iwl-core.c
+++ b/drivers/net/wireless/iwlwifi/iwl-core.c
@@ -2334,6 +2334,21 @@ static void iwl_ht_conf(struct iwl_priv *priv,
2334 IWL_DEBUG_MAC80211(priv, "leave\n"); 2334 IWL_DEBUG_MAC80211(priv, "leave\n");
2335} 2335}
2336 2336
2337static inline void iwl_set_no_assoc(struct iwl_priv *priv)
2338{
2339 priv->assoc_id = 0;
2340 iwl_led_disassociate(priv);
2341 /*
2342 * inform the ucode that there is no longer an
2343 * association and that no more packets should be
2344 * sent
2345 */
2346 priv->staging_rxon.filter_flags &=
2347 ~RXON_FILTER_ASSOC_MSK;
2348 priv->staging_rxon.assoc_id = 0;
2349 iwlcore_commit_rxon(priv);
2350}
2351
2337#define IWL_DELAY_NEXT_SCAN_AFTER_ASSOC (HZ*6) 2352#define IWL_DELAY_NEXT_SCAN_AFTER_ASSOC (HZ*6)
2338void iwl_bss_info_changed(struct ieee80211_hw *hw, 2353void iwl_bss_info_changed(struct ieee80211_hw *hw,
2339 struct ieee80211_vif *vif, 2354 struct ieee80211_vif *vif,
@@ -2465,20 +2480,8 @@ void iwl_bss_info_changed(struct ieee80211_hw *hw,
2465 IWL_DELAY_NEXT_SCAN_AFTER_ASSOC; 2480 IWL_DELAY_NEXT_SCAN_AFTER_ASSOC;
2466 if (!iwl_is_rfkill(priv)) 2481 if (!iwl_is_rfkill(priv))
2467 priv->cfg->ops->lib->post_associate(priv); 2482 priv->cfg->ops->lib->post_associate(priv);
2468 } else { 2483 } else
2469 priv->assoc_id = 0; 2484 iwl_set_no_assoc(priv);
2470 iwl_led_disassociate(priv);
2471
2472 /*
2473 * inform the ucode that there is no longer an
2474 * association and that no more packets should be
2475 * send
2476 */
2477 priv->staging_rxon.filter_flags &=
2478 ~RXON_FILTER_ASSOC_MSK;
2479 priv->staging_rxon.assoc_id = 0;
2480 iwlcore_commit_rxon(priv);
2481 }
2482 } 2485 }
2483 2486
2484 if (changes && iwl_is_associated(priv) && priv->assoc_id) { 2487 if (changes && iwl_is_associated(priv) && priv->assoc_id) {
@@ -2493,12 +2496,14 @@ void iwl_bss_info_changed(struct ieee80211_hw *hw,
2493 } 2496 }
2494 } 2497 }
2495 2498
2496 if ((changes & BSS_CHANGED_BEACON_ENABLED) && 2499 if (changes & BSS_CHANGED_BEACON_ENABLED) {
2497 vif->bss_conf.enable_beacon) { 2500 if (vif->bss_conf.enable_beacon) {
2498 memcpy(priv->staging_rxon.bssid_addr, 2501 memcpy(priv->staging_rxon.bssid_addr,
2499 bss_conf->bssid, ETH_ALEN); 2502 bss_conf->bssid, ETH_ALEN);
2500 memcpy(priv->bssid, bss_conf->bssid, ETH_ALEN); 2503 memcpy(priv->bssid, bss_conf->bssid, ETH_ALEN);
2501 iwlcore_config_ap(priv); 2504 iwlcore_config_ap(priv);
2505 } else
2506 iwl_set_no_assoc(priv);
2502 } 2507 }
2503 2508
2504 mutex_unlock(&priv->mutex); 2509 mutex_unlock(&priv->mutex);
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h
index 42f9b17327c3..70f0e79c8e4a 100644
--- a/drivers/net/wireless/iwlwifi/iwl-dev.h
+++ b/drivers/net/wireless/iwlwifi/iwl-dev.h
@@ -712,7 +712,7 @@ extern void iwl_txq_ctx_stop(struct iwl_priv *priv);
712extern int iwl_queue_space(const struct iwl_queue *q); 712extern int iwl_queue_space(const struct iwl_queue *q);
713static inline int iwl_queue_used(const struct iwl_queue *q, int i) 713static inline int iwl_queue_used(const struct iwl_queue *q, int i)
714{ 714{
715 return q->write_ptr > q->read_ptr ? 715 return q->write_ptr >= q->read_ptr ?
716 (i >= q->read_ptr && i < q->write_ptr) : 716 (i >= q->read_ptr && i < q->write_ptr) :
717 !(i < q->read_ptr && i >= q->write_ptr); 717 !(i < q->read_ptr && i >= q->write_ptr);
718} 718}
diff --git a/drivers/net/wireless/iwlwifi/iwl-devtrace.c b/drivers/net/wireless/iwlwifi/iwl-devtrace.c
index bf46308b17fa..36580d8d8b8d 100644
--- a/drivers/net/wireless/iwlwifi/iwl-devtrace.c
+++ b/drivers/net/wireless/iwlwifi/iwl-devtrace.c
@@ -1,3 +1,29 @@
1/******************************************************************************
2 *
3 * Copyright(c) 2009 - 2010 Intel Corporation. All rights reserved.
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of version 2 of the GNU General Public License as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along with
15 * this program; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
17 *
18 * The full GNU General Public License is included in this distribution in the
19 * file called LICENSE.
20 *
21 * Contact Information:
22 * Intel Linux Wireless <ilw@linux.intel.com>
23 * Intel Corporation, 5200 N.E. Elam Young Parkway, Hillsboro, OR 97124-6497
24 *
25 *****************************************************************************/
26
1#include <linux/module.h> 27#include <linux/module.h>
2 28
3/* sparse doesn't like tracepoint macros */ 29/* sparse doesn't like tracepoint macros */
diff --git a/drivers/net/wireless/iwlwifi/iwl-devtrace.h b/drivers/net/wireless/iwlwifi/iwl-devtrace.h
index 0819f990be6c..ff4d012ce260 100644
--- a/drivers/net/wireless/iwlwifi/iwl-devtrace.h
+++ b/drivers/net/wireless/iwlwifi/iwl-devtrace.h
@@ -1,3 +1,29 @@
1/******************************************************************************
2 *
3 * Copyright(c) 2009 - 2010 Intel Corporation. All rights reserved.
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of version 2 of the GNU General Public License as
7 * published by the Free Software Foundation.
8 *
9 * This program is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12 * more details.
13 *
14 * You should have received a copy of the GNU General Public License along with
15 * this program; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
17 *
18 * The full GNU General Public License is included in this distribution in the
19 * file called LICENSE.
20 *
21 * Contact Information:
22 * Intel Linux Wireless <ilw@linux.intel.com>
23 * Intel Corporation, 5200 N.E. Elam Young Parkway, Hillsboro, OR 97124-6497
24 *
25 *****************************************************************************/
26
1#if !defined(__IWLWIFI_DEVICE_TRACE) || defined(TRACE_HEADER_MULTI_READ) 27#if !defined(__IWLWIFI_DEVICE_TRACE) || defined(TRACE_HEADER_MULTI_READ)
2#define __IWLWIFI_DEVICE_TRACE 28#define __IWLWIFI_DEVICE_TRACE
3 29