aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl3945-base.c
diff options
context:
space:
mode:
authorAbhijeet Kolekar <abhijeet.kolekar@intel.com>2009-04-08 14:26:46 -0400
committerJohn W. Linville <linville@tuxdriver.com>2009-04-22 16:54:43 -0400
commitcbb6ab94b66cfb7136e640191a9628c5a71220a3 (patch)
tree5ac6af3f75d86b005dd76de777b7e2f7c67f6f48 /drivers/net/wireless/iwlwifi/iwl3945-base.c
parent727882d62477ed45d248e8cd6d53cf794537b073 (diff)
iwl3945: use iwl_mac_add_interface from iwlwifi
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/iwl3945-base.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl3945-base.c37
1 files changed, 1 insertions, 36 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
index 666c1fff62b2..955e50a124b5 100644
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
@@ -3380,41 +3380,6 @@ static int iwl3945_mac_tx(struct ieee80211_hw *hw, struct sk_buff *skb)
3380 return NETDEV_TX_OK; 3380 return NETDEV_TX_OK;
3381} 3381}
3382 3382
3383static int iwl3945_mac_add_interface(struct ieee80211_hw *hw,
3384 struct ieee80211_if_init_conf *conf)
3385{
3386 struct iwl_priv *priv = hw->priv;
3387 unsigned long flags;
3388
3389 IWL_DEBUG_MAC80211(priv, "enter: type %d\n", conf->type);
3390
3391 if (priv->vif) {
3392 IWL_DEBUG_MAC80211(priv, "leave - vif != NULL\n");
3393 return -EOPNOTSUPP;
3394 }
3395
3396 spin_lock_irqsave(&priv->lock, flags);
3397 priv->vif = conf->vif;
3398 priv->iw_mode = conf->type;
3399
3400 spin_unlock_irqrestore(&priv->lock, flags);
3401
3402 mutex_lock(&priv->mutex);
3403
3404 if (conf->mac_addr) {
3405 IWL_DEBUG_MAC80211(priv, "Set: %pM\n", conf->mac_addr);
3406 memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN);
3407 }
3408
3409 if (iwl_set_mode(priv, conf->type) == -EAGAIN)
3410 set_bit(STATUS_MODE_PENDING, &priv->status);
3411
3412 mutex_unlock(&priv->mutex);
3413
3414 IWL_DEBUG_MAC80211(priv, "leave\n");
3415 return 0;
3416}
3417
3418/** 3383/**
3419 * iwl3945_mac_config - mac80211 config callback 3384 * iwl3945_mac_config - mac80211 config callback
3420 * 3385 *
@@ -4372,7 +4337,7 @@ static struct ieee80211_ops iwl3945_hw_ops = {
4372 .tx = iwl3945_mac_tx, 4337 .tx = iwl3945_mac_tx,
4373 .start = iwl3945_mac_start, 4338 .start = iwl3945_mac_start,
4374 .stop = iwl3945_mac_stop, 4339 .stop = iwl3945_mac_stop,
4375 .add_interface = iwl3945_mac_add_interface, 4340 .add_interface = iwl_mac_add_interface,
4376 .remove_interface = iwl3945_mac_remove_interface, 4341 .remove_interface = iwl3945_mac_remove_interface,
4377 .config = iwl3945_mac_config, 4342 .config = iwl3945_mac_config,
4378 .config_interface = iwl3945_mac_config_interface, 4343 .config_interface = iwl3945_mac_config_interface,