aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-agn.c
diff options
context:
space:
mode:
authorAbhijeet Kolekar <abhijeet.kolekar@intel.com>2009-04-08 14:26:44 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-04-22 16:54:42 -0400
commit45823531662028a8cbd68906c20e887bb287c85e (patch)
treee8dc18b6372a1aacbc4f5bf50b1aec091e8f91d0 /drivers/net/wireless/iwlwifi/iwl-agn.c
parentf5d3026683da45e00c49a24999ad0d256e4651d5 (diff)
iwlwifi: add set_rxon_chain op
add set_rxon_chain op to iwlwifi cfg ops in preparation of future 3945 porting work. Signed-off-by: Abhijeet Kolekar <abhijeet.kolekar@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/iwl-agn.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-agn.c23
1 files changed, 17 insertions, 6 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c
index 565a441052eb..11e17923ad01 100644
--- a/drivers/net/wireless/iwlwifi/iwl-agn.c
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
@@ -246,7 +246,8 @@ int iwl_commit_rxon(struct iwl_priv *priv)
246void iwl_update_chain_flags(struct iwl_priv *priv) 246void iwl_update_chain_flags(struct iwl_priv *priv)
247{ 247{
248 248
249 iwl_set_rxon_chain(priv); 249 if (priv->cfg->ops->hcmd->set_rxon_chain)
250 priv->cfg->ops->hcmd->set_rxon_chain(priv);
250 iwlcore_commit_rxon(priv); 251 iwlcore_commit_rxon(priv);
251} 252}
252 253
@@ -590,7 +591,10 @@ static void iwl_setup_rxon_timing(struct iwl_priv *priv)
590static int iwl_set_mode(struct iwl_priv *priv, int mode) 591static int iwl_set_mode(struct iwl_priv *priv, int mode)
591{ 592{
592 iwl_connection_init_rx_config(priv, mode); 593 iwl_connection_init_rx_config(priv, mode);
593 iwl_set_rxon_chain(priv); 594
595 if (priv->cfg->ops->hcmd->set_rxon_chain)
596 priv->cfg->ops->hcmd->set_rxon_chain(priv);
597
594 memcpy(priv->staging_rxon.node_addr, priv->mac_addr, ETH_ALEN); 598 memcpy(priv->staging_rxon.node_addr, priv->mac_addr, ETH_ALEN);
595 599
596 priv->cfg->ops->smgmt->clear_station_table(priv); 600 priv->cfg->ops->smgmt->clear_station_table(priv);
@@ -1499,7 +1503,10 @@ static void iwl_alive_start(struct iwl_priv *priv)
1499 } else { 1503 } else {
1500 /* Initialize our rx_config data */ 1504 /* Initialize our rx_config data */
1501 iwl_connection_init_rx_config(priv, priv->iw_mode); 1505 iwl_connection_init_rx_config(priv, priv->iw_mode);
1502 iwl_set_rxon_chain(priv); 1506
1507 if (priv->cfg->ops->hcmd->set_rxon_chain)
1508 priv->cfg->ops->hcmd->set_rxon_chain(priv);
1509
1503 memcpy(priv->staging_rxon.node_addr, priv->mac_addr, ETH_ALEN); 1510 memcpy(priv->staging_rxon.node_addr, priv->mac_addr, ETH_ALEN);
1504 } 1511 }
1505 1512
@@ -1878,7 +1885,9 @@ void iwl_post_associate(struct iwl_priv *priv)
1878 1885
1879 iwl_set_rxon_ht(priv, &priv->current_ht_config); 1886 iwl_set_rxon_ht(priv, &priv->current_ht_config);
1880 1887
1881 iwl_set_rxon_chain(priv); 1888 if (priv->cfg->ops->hcmd->set_rxon_chain)
1889 priv->cfg->ops->hcmd->set_rxon_chain(priv);
1890
1882 priv->staging_rxon.assoc_id = cpu_to_le16(priv->assoc_id); 1891 priv->staging_rxon.assoc_id = cpu_to_le16(priv->assoc_id);
1883 1892
1884 IWL_DEBUG_ASSOC(priv, "assoc id %d beacon interval %d\n", 1893 IWL_DEBUG_ASSOC(priv, "assoc id %d beacon interval %d\n",
@@ -2182,7 +2191,8 @@ static int iwl_mac_config(struct ieee80211_hw *hw, u32 changed)
2182 } 2191 }
2183 2192
2184 /* call to ensure that 4965 rx_chain is set properly in monitor mode */ 2193 /* call to ensure that 4965 rx_chain is set properly in monitor mode */
2185 iwl_set_rxon_chain(priv); 2194 if (priv->cfg->ops->hcmd->set_rxon_chain)
2195 priv->cfg->ops->hcmd->set_rxon_chain(priv);
2186 2196
2187 if (changed & IEEE80211_CONF_CHANGE_RADIO_ENABLED) { 2197 if (changed & IEEE80211_CONF_CHANGE_RADIO_ENABLED) {
2188 if (conf->radio_enabled && 2198 if (conf->radio_enabled &&
@@ -2245,7 +2255,8 @@ static void iwl_config_ap(struct iwl_priv *priv)
2245 IWL_WARN(priv, "REPLY_RXON_TIMING failed - " 2255 IWL_WARN(priv, "REPLY_RXON_TIMING failed - "
2246 "Attempting to continue.\n"); 2256 "Attempting to continue.\n");
2247 2257
2248 iwl_set_rxon_chain(priv); 2258 if (priv->cfg->ops->hcmd->set_rxon_chain)
2259 priv->cfg->ops->hcmd->set_rxon_chain(priv);
2249 2260
2250 /* FIXME: what should be the assoc_id for AP? */ 2261 /* FIXME: what should be the assoc_id for AP? */
2251 priv->staging_rxon.assoc_id = cpu_to_le16(priv->assoc_id); 2262 priv->staging_rxon.assoc_id = cpu_to_le16(priv->assoc_id);