diff options
author | Johannes Berg <johannes@sipsolutions.net> | 2008-10-27 18:59:26 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-10-27 20:06:18 -0400 |
commit | e174961ca1a0b28f7abf0be47973ad57cb74e5f0 (patch) | |
tree | e8f74ecd420a0e380a71670e5aec5c2a0c15640a /drivers/net/wireless/iwlwifi | |
parent | 0c68ae2605dbcf67414d8d1f19af93be44b355fb (diff) |
net: convert print_mac to %pM
This converts pretty much everything to print_mac. There were
a few things that had conflicts which I have just dropped for
now, no harm done.
I've built an allyesconfig with this and looked at the files
that weren't built very carefully, but it's a huge patch.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/wireless/iwlwifi')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-3945-rs.c | 5 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-3945.c | 5 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn-rs.c | 18 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn.c | 47 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-debugfs.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-sta.c | 38 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-tx.c | 17 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl3945-base.c | 54 |
8 files changed, 66 insertions, 120 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c b/drivers/net/wireless/iwlwifi/iwl-3945-rs.c index 6fc5e7361f26..bb91353c443e 100644 --- a/drivers/net/wireless/iwlwifi/iwl-3945-rs.c +++ b/drivers/net/wireless/iwlwifi/iwl-3945-rs.c | |||
@@ -649,7 +649,6 @@ static void rs_get_rate(void *priv_r, struct ieee80211_supported_band *sband, | |||
649 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; | 649 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data; |
650 | u16 fc, rate_mask; | 650 | u16 fc, rate_mask; |
651 | struct iwl3945_priv *priv = (struct iwl3945_priv *)priv_r; | 651 | struct iwl3945_priv *priv = (struct iwl3945_priv *)priv_r; |
652 | DECLARE_MAC_BUF(mac); | ||
653 | 652 | ||
654 | IWL_DEBUG_RATE("enter\n"); | 653 | IWL_DEBUG_RATE("enter\n"); |
655 | 654 | ||
@@ -675,8 +674,8 @@ static void rs_get_rate(void *priv_r, struct ieee80211_supported_band *sband, | |||
675 | u8 sta_id = iwl3945_hw_find_station(priv, hdr->addr1); | 674 | u8 sta_id = iwl3945_hw_find_station(priv, hdr->addr1); |
676 | 675 | ||
677 | if (sta_id == IWL_INVALID_STATION) { | 676 | if (sta_id == IWL_INVALID_STATION) { |
678 | IWL_DEBUG_RATE("LQ: ADD station %s\n", | 677 | IWL_DEBUG_RATE("LQ: ADD station %pm\n", |
679 | print_mac(mac, hdr->addr1)); | 678 | hdr->addr1); |
680 | sta_id = iwl3945_add_station(priv, | 679 | sta_id = iwl3945_add_station(priv, |
681 | hdr->addr1, 0, CMD_ASYNC); | 680 | hdr->addr1, 0, CMD_ASYNC); |
682 | } | 681 | } |
diff --git a/drivers/net/wireless/iwlwifi/iwl-3945.c b/drivers/net/wireless/iwlwifi/iwl-3945.c index 7ca5627cc078..8a00245be51e 100644 --- a/drivers/net/wireless/iwlwifi/iwl-3945.c +++ b/drivers/net/wireless/iwlwifi/iwl-3945.c | |||
@@ -759,7 +759,6 @@ u8 iwl3945_hw_find_station(struct iwl3945_priv *priv, const u8 *addr) | |||
759 | int i; | 759 | int i; |
760 | int ret = IWL_INVALID_STATION; | 760 | int ret = IWL_INVALID_STATION; |
761 | unsigned long flags; | 761 | unsigned long flags; |
762 | DECLARE_MAC_BUF(mac); | ||
763 | 762 | ||
764 | spin_lock_irqsave(&priv->sta_lock, flags); | 763 | spin_lock_irqsave(&priv->sta_lock, flags); |
765 | for (i = IWL_STA_ID; i < priv->hw_setting.max_stations; i++) | 764 | for (i = IWL_STA_ID; i < priv->hw_setting.max_stations; i++) |
@@ -770,8 +769,8 @@ u8 iwl3945_hw_find_station(struct iwl3945_priv *priv, const u8 *addr) | |||
770 | goto out; | 769 | goto out; |
771 | } | 770 | } |
772 | 771 | ||
773 | IWL_DEBUG_INFO("can not find STA %s (total %d)\n", | 772 | IWL_DEBUG_INFO("can not find STA %pM (total %d)\n", |
774 | print_mac(mac, addr), priv->num_stations); | 773 | addr, priv->num_stations); |
775 | out: | 774 | out: |
776 | spin_unlock_irqrestore(&priv->sta_lock, flags); | 775 | spin_unlock_irqrestore(&priv->sta_lock, flags); |
777 | return ret; | 776 | return ret; |
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c index e2a58e477036..b497d40dc396 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn-rs.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn-rs.c | |||
@@ -357,11 +357,9 @@ static void rs_tl_turn_on_agg_for_tid(struct iwl_priv *priv, | |||
357 | struct iwl_lq_sta *lq_data, u8 tid, | 357 | struct iwl_lq_sta *lq_data, u8 tid, |
358 | struct ieee80211_sta *sta) | 358 | struct ieee80211_sta *sta) |
359 | { | 359 | { |
360 | DECLARE_MAC_BUF(mac); | ||
361 | |||
362 | if (rs_tl_get_load(lq_data, tid) > IWL_AGG_LOAD_THRESHOLD) { | 360 | if (rs_tl_get_load(lq_data, tid) > IWL_AGG_LOAD_THRESHOLD) { |
363 | IWL_DEBUG_HT("Starting Tx agg: STA: %s tid: %d\n", | 361 | IWL_DEBUG_HT("Starting Tx agg: STA: %pM tid: %d\n", |
364 | print_mac(mac, sta->addr), tid); | 362 | sta->addr, tid); |
365 | ieee80211_start_tx_ba_session(priv->hw, sta->addr, tid); | 363 | ieee80211_start_tx_ba_session(priv->hw, sta->addr, tid); |
366 | } | 364 | } |
367 | } | 365 | } |
@@ -2132,11 +2130,10 @@ static void rs_get_rate(void *priv_r, struct ieee80211_supported_band *sband, | |||
2132 | if ((priv->iw_mode == NL80211_IFTYPE_ADHOC) && | 2130 | if ((priv->iw_mode == NL80211_IFTYPE_ADHOC) && |
2133 | !lq_sta->ibss_sta_added) { | 2131 | !lq_sta->ibss_sta_added) { |
2134 | u8 sta_id = iwl_find_station(priv, hdr->addr1); | 2132 | u8 sta_id = iwl_find_station(priv, hdr->addr1); |
2135 | DECLARE_MAC_BUF(mac); | ||
2136 | 2133 | ||
2137 | if (sta_id == IWL_INVALID_STATION) { | 2134 | if (sta_id == IWL_INVALID_STATION) { |
2138 | IWL_DEBUG_RATE("LQ: ADD station %s\n", | 2135 | IWL_DEBUG_RATE("LQ: ADD station %pM\n", |
2139 | print_mac(mac, hdr->addr1)); | 2136 | hdr->addr1); |
2140 | sta_id = iwl_add_station_flags(priv, hdr->addr1, | 2137 | sta_id = iwl_add_station_flags(priv, hdr->addr1, |
2141 | 0, CMD_ASYNC, NULL); | 2138 | 0, CMD_ASYNC, NULL); |
2142 | } | 2139 | } |
@@ -2205,15 +2202,12 @@ static void rs_rate_init(void *priv_r, struct ieee80211_supported_band *sband, | |||
2205 | lq_sta->ibss_sta_added = 0; | 2202 | lq_sta->ibss_sta_added = 0; |
2206 | if (priv->iw_mode == NL80211_IFTYPE_AP) { | 2203 | if (priv->iw_mode == NL80211_IFTYPE_AP) { |
2207 | u8 sta_id = iwl_find_station(priv, sta->addr); | 2204 | u8 sta_id = iwl_find_station(priv, sta->addr); |
2208 | DECLARE_MAC_BUF(mac); | ||
2209 | 2205 | ||
2210 | /* for IBSS the call are from tasklet */ | 2206 | /* for IBSS the call are from tasklet */ |
2211 | IWL_DEBUG_RATE("LQ: ADD station %s\n", | 2207 | IWL_DEBUG_RATE("LQ: ADD station %pM\n", sta->addr); |
2212 | print_mac(mac, sta->addr)); | ||
2213 | 2208 | ||
2214 | if (sta_id == IWL_INVALID_STATION) { | 2209 | if (sta_id == IWL_INVALID_STATION) { |
2215 | IWL_DEBUG_RATE("LQ: ADD station %s\n", | 2210 | IWL_DEBUG_RATE("LQ: ADD station %pM\n", sta->addr); |
2216 | print_mac(mac, sta->addr)); | ||
2217 | sta_id = iwl_add_station_flags(priv, sta->addr, | 2211 | sta_id = iwl_add_station_flags(priv, sta->addr, |
2218 | 0, CMD_ASYNC, NULL); | 2212 | 0, CMD_ASYNC, NULL); |
2219 | } | 2213 | } |
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c index 24a1aeb6448f..2af9a14446e4 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn.c +++ b/drivers/net/wireless/iwlwifi/iwl-agn.c | |||
@@ -239,7 +239,6 @@ static int iwl4965_commit_rxon(struct iwl_priv *priv) | |||
239 | { | 239 | { |
240 | /* cast away the const for active_rxon in this function */ | 240 | /* cast away the const for active_rxon in this function */ |
241 | struct iwl_rxon_cmd *active_rxon = (void *)&priv->active_rxon; | 241 | struct iwl_rxon_cmd *active_rxon = (void *)&priv->active_rxon; |
242 | DECLARE_MAC_BUF(mac); | ||
243 | int ret; | 242 | int ret; |
244 | bool new_assoc = | 243 | bool new_assoc = |
245 | !!(priv->staging_rxon.filter_flags & RXON_FILTER_ASSOC_MSK); | 244 | !!(priv->staging_rxon.filter_flags & RXON_FILTER_ASSOC_MSK); |
@@ -300,10 +299,10 @@ static int iwl4965_commit_rxon(struct iwl_priv *priv) | |||
300 | IWL_DEBUG_INFO("Sending RXON\n" | 299 | IWL_DEBUG_INFO("Sending RXON\n" |
301 | "* with%s RXON_FILTER_ASSOC_MSK\n" | 300 | "* with%s RXON_FILTER_ASSOC_MSK\n" |
302 | "* channel = %d\n" | 301 | "* channel = %d\n" |
303 | "* bssid = %s\n", | 302 | "* bssid = %pM\n", |
304 | (new_assoc ? "" : "out"), | 303 | (new_assoc ? "" : "out"), |
305 | le16_to_cpu(priv->staging_rxon.channel), | 304 | le16_to_cpu(priv->staging_rxon.channel), |
306 | print_mac(mac, priv->staging_rxon.bssid_addr)); | 305 | priv->staging_rxon.bssid_addr); |
307 | 306 | ||
308 | iwl4965_set_rxon_hwcrypto(priv, !priv->hw_params.sw_crypto); | 307 | iwl4965_set_rxon_hwcrypto(priv, !priv->hw_params.sw_crypto); |
309 | 308 | ||
@@ -1464,7 +1463,6 @@ void iwl_rx_handle(struct iwl_priv *priv) | |||
1464 | static void iwl4965_print_rx_config_cmd(struct iwl_priv *priv) | 1463 | static void iwl4965_print_rx_config_cmd(struct iwl_priv *priv) |
1465 | { | 1464 | { |
1466 | struct iwl_rxon_cmd *rxon = &priv->staging_rxon; | 1465 | struct iwl_rxon_cmd *rxon = &priv->staging_rxon; |
1467 | DECLARE_MAC_BUF(mac); | ||
1468 | 1466 | ||
1469 | IWL_DEBUG_RADIO("RX CONFIG:\n"); | 1467 | IWL_DEBUG_RADIO("RX CONFIG:\n"); |
1470 | iwl_print_hex_dump(priv, IWL_DL_RADIO, (u8 *) rxon, sizeof(*rxon)); | 1468 | iwl_print_hex_dump(priv, IWL_DL_RADIO, (u8 *) rxon, sizeof(*rxon)); |
@@ -1476,10 +1474,8 @@ static void iwl4965_print_rx_config_cmd(struct iwl_priv *priv) | |||
1476 | IWL_DEBUG_RADIO("u8 ofdm_basic_rates: 0x%02x\n", | 1474 | IWL_DEBUG_RADIO("u8 ofdm_basic_rates: 0x%02x\n", |
1477 | rxon->ofdm_basic_rates); | 1475 | rxon->ofdm_basic_rates); |
1478 | IWL_DEBUG_RADIO("u8 cck_basic_rates: 0x%02x\n", rxon->cck_basic_rates); | 1476 | IWL_DEBUG_RADIO("u8 cck_basic_rates: 0x%02x\n", rxon->cck_basic_rates); |
1479 | IWL_DEBUG_RADIO("u8[6] node_addr: %s\n", | 1477 | IWL_DEBUG_RADIO("u8[6] node_addr: %pM\n", rxon->node_addr); |
1480 | print_mac(mac, rxon->node_addr)); | 1478 | IWL_DEBUG_RADIO("u8[6] bssid_addr: %pM\n", rxon->bssid_addr); |
1481 | IWL_DEBUG_RADIO("u8[6] bssid_addr: %s\n", | ||
1482 | print_mac(mac, rxon->bssid_addr)); | ||
1483 | IWL_DEBUG_RADIO("u16 assoc_id: 0x%x\n", le16_to_cpu(rxon->assoc_id)); | 1479 | IWL_DEBUG_RADIO("u16 assoc_id: 0x%x\n", le16_to_cpu(rxon->assoc_id)); |
1484 | } | 1480 | } |
1485 | #endif | 1481 | #endif |
@@ -2466,7 +2462,6 @@ static void iwl4965_post_associate(struct iwl_priv *priv) | |||
2466 | { | 2462 | { |
2467 | struct ieee80211_conf *conf = NULL; | 2463 | struct ieee80211_conf *conf = NULL; |
2468 | int ret = 0; | 2464 | int ret = 0; |
2469 | DECLARE_MAC_BUF(mac); | ||
2470 | unsigned long flags; | 2465 | unsigned long flags; |
2471 | 2466 | ||
2472 | if (priv->iw_mode == NL80211_IFTYPE_AP) { | 2467 | if (priv->iw_mode == NL80211_IFTYPE_AP) { |
@@ -2474,9 +2469,8 @@ static void iwl4965_post_associate(struct iwl_priv *priv) | |||
2474 | return; | 2469 | return; |
2475 | } | 2470 | } |
2476 | 2471 | ||
2477 | IWL_DEBUG_ASSOC("Associated as %d to: %s\n", | 2472 | IWL_DEBUG_ASSOC("Associated as %d to: %pM\n", |
2478 | priv->assoc_id, | 2473 | priv->assoc_id, priv->active_rxon.bssid_addr); |
2479 | print_mac(mac, priv->active_rxon.bssid_addr)); | ||
2480 | 2474 | ||
2481 | 2475 | ||
2482 | if (test_bit(STATUS_EXIT_PENDING, &priv->status)) | 2476 | if (test_bit(STATUS_EXIT_PENDING, &priv->status)) |
@@ -2722,7 +2716,6 @@ static int iwl4965_mac_add_interface(struct ieee80211_hw *hw, | |||
2722 | { | 2716 | { |
2723 | struct iwl_priv *priv = hw->priv; | 2717 | struct iwl_priv *priv = hw->priv; |
2724 | unsigned long flags; | 2718 | unsigned long flags; |
2725 | DECLARE_MAC_BUF(mac); | ||
2726 | 2719 | ||
2727 | IWL_DEBUG_MAC80211("enter: type %d\n", conf->type); | 2720 | IWL_DEBUG_MAC80211("enter: type %d\n", conf->type); |
2728 | 2721 | ||
@@ -2739,7 +2732,7 @@ static int iwl4965_mac_add_interface(struct ieee80211_hw *hw, | |||
2739 | mutex_lock(&priv->mutex); | 2732 | mutex_lock(&priv->mutex); |
2740 | 2733 | ||
2741 | if (conf->mac_addr) { | 2734 | if (conf->mac_addr) { |
2742 | IWL_DEBUG_MAC80211("Set %s\n", print_mac(mac, conf->mac_addr)); | 2735 | IWL_DEBUG_MAC80211("Set %pM\n", conf->mac_addr); |
2743 | memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN); | 2736 | memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN); |
2744 | } | 2737 | } |
2745 | 2738 | ||
@@ -2948,7 +2941,6 @@ static int iwl4965_mac_config_interface(struct ieee80211_hw *hw, | |||
2948 | struct ieee80211_if_conf *conf) | 2941 | struct ieee80211_if_conf *conf) |
2949 | { | 2942 | { |
2950 | struct iwl_priv *priv = hw->priv; | 2943 | struct iwl_priv *priv = hw->priv; |
2951 | DECLARE_MAC_BUF(mac); | ||
2952 | unsigned long flags; | 2944 | unsigned long flags; |
2953 | int rc; | 2945 | int rc; |
2954 | 2946 | ||
@@ -2983,8 +2975,7 @@ static int iwl4965_mac_config_interface(struct ieee80211_hw *hw, | |||
2983 | mutex_lock(&priv->mutex); | 2975 | mutex_lock(&priv->mutex); |
2984 | 2976 | ||
2985 | if (conf->bssid) | 2977 | if (conf->bssid) |
2986 | IWL_DEBUG_MAC80211("bssid: %s\n", | 2978 | IWL_DEBUG_MAC80211("bssid: %pM\n", conf->bssid); |
2987 | print_mac(mac, conf->bssid)); | ||
2988 | 2979 | ||
2989 | /* | 2980 | /* |
2990 | * very dubious code was here; the probe filtering flag is never set: | 2981 | * very dubious code was here; the probe filtering flag is never set: |
@@ -2997,8 +2988,8 @@ static int iwl4965_mac_config_interface(struct ieee80211_hw *hw, | |||
2997 | if (!conf->bssid) { | 2988 | if (!conf->bssid) { |
2998 | conf->bssid = priv->mac_addr; | 2989 | conf->bssid = priv->mac_addr; |
2999 | memcpy(priv->bssid, priv->mac_addr, ETH_ALEN); | 2990 | memcpy(priv->bssid, priv->mac_addr, ETH_ALEN); |
3000 | IWL_DEBUG_MAC80211("bssid was set to: %s\n", | 2991 | IWL_DEBUG_MAC80211("bssid was set to: %pM\n", |
3001 | print_mac(mac, conf->bssid)); | 2992 | conf->bssid); |
3002 | } | 2993 | } |
3003 | if (priv->ibss_beacon) | 2994 | if (priv->ibss_beacon) |
3004 | dev_kfree_skb(priv->ibss_beacon); | 2995 | dev_kfree_skb(priv->ibss_beacon); |
@@ -3241,14 +3232,13 @@ static void iwl4965_mac_update_tkip_key(struct ieee80211_hw *hw, | |||
3241 | unsigned long flags; | 3232 | unsigned long flags; |
3242 | __le16 key_flags = 0; | 3233 | __le16 key_flags = 0; |
3243 | int i; | 3234 | int i; |
3244 | DECLARE_MAC_BUF(mac); | ||
3245 | 3235 | ||
3246 | IWL_DEBUG_MAC80211("enter\n"); | 3236 | IWL_DEBUG_MAC80211("enter\n"); |
3247 | 3237 | ||
3248 | sta_id = iwl_find_station(priv, addr); | 3238 | sta_id = iwl_find_station(priv, addr); |
3249 | if (sta_id == IWL_INVALID_STATION) { | 3239 | if (sta_id == IWL_INVALID_STATION) { |
3250 | IWL_DEBUG_MAC80211("leave - %s not in station map.\n", | 3240 | IWL_DEBUG_MAC80211("leave - %pM not in station map.\n", |
3251 | print_mac(mac, addr)); | 3241 | addr); |
3252 | return; | 3242 | return; |
3253 | } | 3243 | } |
3254 | 3244 | ||
@@ -3285,7 +3275,6 @@ static int iwl4965_mac_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd, | |||
3285 | struct ieee80211_key_conf *key) | 3275 | struct ieee80211_key_conf *key) |
3286 | { | 3276 | { |
3287 | struct iwl_priv *priv = hw->priv; | 3277 | struct iwl_priv *priv = hw->priv; |
3288 | DECLARE_MAC_BUF(mac); | ||
3289 | int ret = 0; | 3278 | int ret = 0; |
3290 | u8 sta_id = IWL_INVALID_STATION; | 3279 | u8 sta_id = IWL_INVALID_STATION; |
3291 | u8 is_default_wep_key = 0; | 3280 | u8 is_default_wep_key = 0; |
@@ -3303,8 +3292,8 @@ static int iwl4965_mac_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd, | |||
3303 | 3292 | ||
3304 | sta_id = iwl_find_station(priv, addr); | 3293 | sta_id = iwl_find_station(priv, addr); |
3305 | if (sta_id == IWL_INVALID_STATION) { | 3294 | if (sta_id == IWL_INVALID_STATION) { |
3306 | IWL_DEBUG_MAC80211("leave - %s not in station map.\n", | 3295 | IWL_DEBUG_MAC80211("leave - %pM not in station map.\n", |
3307 | print_mac(mac, addr)); | 3296 | addr); |
3308 | return -EINVAL; | 3297 | return -EINVAL; |
3309 | 3298 | ||
3310 | } | 3299 | } |
@@ -3405,10 +3394,9 @@ static int iwl4965_mac_ampdu_action(struct ieee80211_hw *hw, | |||
3405 | struct ieee80211_sta *sta, u16 tid, u16 *ssn) | 3394 | struct ieee80211_sta *sta, u16 tid, u16 *ssn) |
3406 | { | 3395 | { |
3407 | struct iwl_priv *priv = hw->priv; | 3396 | struct iwl_priv *priv = hw->priv; |
3408 | DECLARE_MAC_BUF(mac); | ||
3409 | 3397 | ||
3410 | IWL_DEBUG_HT("A-MPDU action on addr %s tid %d\n", | 3398 | IWL_DEBUG_HT("A-MPDU action on addr %pM tid %d\n", |
3411 | print_mac(mac, sta->addr), tid); | 3399 | sta->addr, tid); |
3412 | 3400 | ||
3413 | if (!(priv->cfg->sku & IWL_SKU_N)) | 3401 | if (!(priv->cfg->sku & IWL_SKU_N)) |
3414 | return -EACCES; | 3402 | return -EACCES; |
@@ -4171,7 +4159,6 @@ static int iwl4965_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e | |||
4171 | struct ieee80211_hw *hw; | 4159 | struct ieee80211_hw *hw; |
4172 | struct iwl_cfg *cfg = (struct iwl_cfg *)(ent->driver_data); | 4160 | struct iwl_cfg *cfg = (struct iwl_cfg *)(ent->driver_data); |
4173 | unsigned long flags; | 4161 | unsigned long flags; |
4174 | DECLARE_MAC_BUF(mac); | ||
4175 | 4162 | ||
4176 | /************************ | 4163 | /************************ |
4177 | * 1. Allocating HW data | 4164 | * 1. Allocating HW data |
@@ -4280,7 +4267,7 @@ static int iwl4965_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e | |||
4280 | 4267 | ||
4281 | /* extract MAC Address */ | 4268 | /* extract MAC Address */ |
4282 | iwl_eeprom_get_mac(priv, priv->mac_addr); | 4269 | iwl_eeprom_get_mac(priv, priv->mac_addr); |
4283 | IWL_DEBUG_INFO("MAC address: %s\n", print_mac(mac, priv->mac_addr)); | 4270 | IWL_DEBUG_INFO("MAC address: %pM\n", priv->mac_addr); |
4284 | SET_IEEE80211_PERM_ADDR(priv->hw, priv->mac_addr); | 4271 | SET_IEEE80211_PERM_ADDR(priv->hw, priv->mac_addr); |
4285 | 4272 | ||
4286 | /************************ | 4273 | /************************ |
diff --git a/drivers/net/wireless/iwlwifi/iwl-debugfs.c b/drivers/net/wireless/iwlwifi/iwl-debugfs.c index 20db0eb636a8..753f9387aa68 100644 --- a/drivers/net/wireless/iwlwifi/iwl-debugfs.c +++ b/drivers/net/wireless/iwlwifi/iwl-debugfs.c | |||
@@ -228,7 +228,6 @@ static ssize_t iwl_dbgfs_stations_read(struct file *file, char __user *user_buf, | |||
228 | ssize_t ret; | 228 | ssize_t ret; |
229 | /* Add 30 for initial string */ | 229 | /* Add 30 for initial string */ |
230 | const size_t bufsz = 30 + sizeof(char) * 500 * (priv->num_stations); | 230 | const size_t bufsz = 30 + sizeof(char) * 500 * (priv->num_stations); |
231 | DECLARE_MAC_BUF(mac); | ||
232 | 231 | ||
233 | buf = kmalloc(bufsz, GFP_KERNEL); | 232 | buf = kmalloc(bufsz, GFP_KERNEL); |
234 | if (!buf) | 233 | if (!buf) |
@@ -242,7 +241,6 @@ static ssize_t iwl_dbgfs_stations_read(struct file *file, char __user *user_buf, | |||
242 | if (station->used) { | 241 | if (station->used) { |
243 | pos += scnprintf(buf + pos, bufsz - pos, | 242 | pos += scnprintf(buf + pos, bufsz - pos, |
244 | "station %d:\ngeneral data:\n", i+1); | 243 | "station %d:\ngeneral data:\n", i+1); |
245 | print_mac(mac, station->sta.sta.addr); | ||
246 | pos += scnprintf(buf + pos, bufsz - pos, "id: %u\n", | 244 | pos += scnprintf(buf + pos, bufsz - pos, "id: %u\n", |
247 | station->sta.sta.sta_id); | 245 | station->sta.sta.sta_id); |
248 | pos += scnprintf(buf + pos, bufsz - pos, "mode: %u\n", | 246 | pos += scnprintf(buf + pos, bufsz - pos, "mode: %u\n", |
diff --git a/drivers/net/wireless/iwlwifi/iwl-sta.c b/drivers/net/wireless/iwlwifi/iwl-sta.c index 61797f3f8d5c..e02c4717c93c 100644 --- a/drivers/net/wireless/iwlwifi/iwl-sta.c +++ b/drivers/net/wireless/iwlwifi/iwl-sta.c | |||
@@ -45,7 +45,6 @@ u8 iwl_find_station(struct iwl_priv *priv, const u8 *addr) | |||
45 | int start = 0; | 45 | int start = 0; |
46 | int ret = IWL_INVALID_STATION; | 46 | int ret = IWL_INVALID_STATION; |
47 | unsigned long flags; | 47 | unsigned long flags; |
48 | DECLARE_MAC_BUF(mac); | ||
49 | 48 | ||
50 | if ((priv->iw_mode == NL80211_IFTYPE_ADHOC) || | 49 | if ((priv->iw_mode == NL80211_IFTYPE_ADHOC) || |
51 | (priv->iw_mode == NL80211_IFTYPE_AP)) | 50 | (priv->iw_mode == NL80211_IFTYPE_AP)) |
@@ -63,8 +62,8 @@ u8 iwl_find_station(struct iwl_priv *priv, const u8 *addr) | |||
63 | goto out; | 62 | goto out; |
64 | } | 63 | } |
65 | 64 | ||
66 | IWL_DEBUG_ASSOC_LIMIT("can not find STA %s total %d\n", | 65 | IWL_DEBUG_ASSOC_LIMIT("can not find STA %pM total %d\n", |
67 | print_mac(mac, addr), priv->num_stations); | 66 | addr, priv->num_stations); |
68 | 67 | ||
69 | out: | 68 | out: |
70 | spin_unlock_irqrestore(&priv->sta_lock, flags); | 69 | spin_unlock_irqrestore(&priv->sta_lock, flags); |
@@ -86,7 +85,6 @@ EXPORT_SYMBOL(iwl_get_ra_sta_id); | |||
86 | static void iwl_sta_ucode_activate(struct iwl_priv *priv, u8 sta_id) | 85 | static void iwl_sta_ucode_activate(struct iwl_priv *priv, u8 sta_id) |
87 | { | 86 | { |
88 | unsigned long flags; | 87 | unsigned long flags; |
89 | DECLARE_MAC_BUF(mac); | ||
90 | 88 | ||
91 | spin_lock_irqsave(&priv->sta_lock, flags); | 89 | spin_lock_irqsave(&priv->sta_lock, flags); |
92 | 90 | ||
@@ -94,8 +92,8 @@ static void iwl_sta_ucode_activate(struct iwl_priv *priv, u8 sta_id) | |||
94 | IWL_ERROR("ACTIVATE a non DRIVER active station %d\n", sta_id); | 92 | IWL_ERROR("ACTIVATE a non DRIVER active station %d\n", sta_id); |
95 | 93 | ||
96 | priv->stations[sta_id].used |= IWL_STA_UCODE_ACTIVE; | 94 | priv->stations[sta_id].used |= IWL_STA_UCODE_ACTIVE; |
97 | IWL_DEBUG_ASSOC("Added STA to Ucode: %s\n", | 95 | IWL_DEBUG_ASSOC("Added STA to Ucode: %pM\n", |
98 | print_mac(mac, priv->stations[sta_id].sta.sta.addr)); | 96 | priv->stations[sta_id].sta.sta.addr); |
99 | 97 | ||
100 | spin_unlock_irqrestore(&priv->sta_lock, flags); | 98 | spin_unlock_irqrestore(&priv->sta_lock, flags); |
101 | } | 99 | } |
@@ -237,7 +235,6 @@ u8 iwl_add_station_flags(struct iwl_priv *priv, const u8 *addr, int is_ap, | |||
237 | int sta_id = IWL_INVALID_STATION; | 235 | int sta_id = IWL_INVALID_STATION; |
238 | struct iwl_station_entry *station; | 236 | struct iwl_station_entry *station; |
239 | unsigned long flags_spin; | 237 | unsigned long flags_spin; |
240 | DECLARE_MAC_BUF(mac); | ||
241 | 238 | ||
242 | spin_lock_irqsave(&priv->sta_lock, flags_spin); | 239 | spin_lock_irqsave(&priv->sta_lock, flags_spin); |
243 | if (is_ap) | 240 | if (is_ap) |
@@ -273,8 +270,8 @@ u8 iwl_add_station_flags(struct iwl_priv *priv, const u8 *addr, int is_ap, | |||
273 | 270 | ||
274 | station = &priv->stations[sta_id]; | 271 | station = &priv->stations[sta_id]; |
275 | station->used = IWL_STA_DRIVER_ACTIVE; | 272 | station->used = IWL_STA_DRIVER_ACTIVE; |
276 | IWL_DEBUG_ASSOC("Add STA to driver ID %d: %s\n", | 273 | IWL_DEBUG_ASSOC("Add STA to driver ID %d: %pM\n", |
277 | sta_id, print_mac(mac, addr)); | 274 | sta_id, addr); |
278 | priv->num_stations++; | 275 | priv->num_stations++; |
279 | 276 | ||
280 | /* Set up the REPLY_ADD_STA command to send to device */ | 277 | /* Set up the REPLY_ADD_STA command to send to device */ |
@@ -301,14 +298,11 @@ EXPORT_SYMBOL(iwl_add_station_flags); | |||
301 | static void iwl_sta_ucode_deactivate(struct iwl_priv *priv, const char *addr) | 298 | static void iwl_sta_ucode_deactivate(struct iwl_priv *priv, const char *addr) |
302 | { | 299 | { |
303 | unsigned long flags; | 300 | unsigned long flags; |
304 | DECLARE_MAC_BUF(mac); | ||
305 | |||
306 | u8 sta_id = iwl_find_station(priv, addr); | 301 | u8 sta_id = iwl_find_station(priv, addr); |
307 | 302 | ||
308 | BUG_ON(sta_id == IWL_INVALID_STATION); | 303 | BUG_ON(sta_id == IWL_INVALID_STATION); |
309 | 304 | ||
310 | IWL_DEBUG_ASSOC("Removed STA from Ucode: %s\n", | 305 | IWL_DEBUG_ASSOC("Removed STA from Ucode: %pM\n", addr); |
311 | print_mac(mac, addr)); | ||
312 | 306 | ||
313 | spin_lock_irqsave(&priv->sta_lock, flags); | 307 | spin_lock_irqsave(&priv->sta_lock, flags); |
314 | 308 | ||
@@ -415,7 +409,6 @@ int iwl_remove_station(struct iwl_priv *priv, const u8 *addr, int is_ap) | |||
415 | int sta_id = IWL_INVALID_STATION; | 409 | int sta_id = IWL_INVALID_STATION; |
416 | int i, ret = -EINVAL; | 410 | int i, ret = -EINVAL; |
417 | unsigned long flags; | 411 | unsigned long flags; |
418 | DECLARE_MAC_BUF(mac); | ||
419 | 412 | ||
420 | spin_lock_irqsave(&priv->sta_lock, flags); | 413 | spin_lock_irqsave(&priv->sta_lock, flags); |
421 | 414 | ||
@@ -435,18 +428,18 @@ int iwl_remove_station(struct iwl_priv *priv, const u8 *addr, int is_ap) | |||
435 | if (unlikely(sta_id == IWL_INVALID_STATION)) | 428 | if (unlikely(sta_id == IWL_INVALID_STATION)) |
436 | goto out; | 429 | goto out; |
437 | 430 | ||
438 | IWL_DEBUG_ASSOC("Removing STA from driver:%d %s\n", | 431 | IWL_DEBUG_ASSOC("Removing STA from driver:%d %pM\n", |
439 | sta_id, print_mac(mac, addr)); | 432 | sta_id, addr); |
440 | 433 | ||
441 | if (!(priv->stations[sta_id].used & IWL_STA_DRIVER_ACTIVE)) { | 434 | if (!(priv->stations[sta_id].used & IWL_STA_DRIVER_ACTIVE)) { |
442 | IWL_ERROR("Removing %s but non DRIVER active\n", | 435 | IWL_ERROR("Removing %pM but non DRIVER active\n", |
443 | print_mac(mac, addr)); | 436 | addr); |
444 | goto out; | 437 | goto out; |
445 | } | 438 | } |
446 | 439 | ||
447 | if (!(priv->stations[sta_id].used & IWL_STA_UCODE_ACTIVE)) { | 440 | if (!(priv->stations[sta_id].used & IWL_STA_UCODE_ACTIVE)) { |
448 | IWL_ERROR("Removing %s but non UCODE active\n", | 441 | IWL_ERROR("Removing %pM but non UCODE active\n", |
449 | print_mac(mac, addr)); | 442 | addr); |
450 | goto out; | 443 | goto out; |
451 | } | 444 | } |
452 | 445 | ||
@@ -927,7 +920,6 @@ int iwl_get_sta_id(struct iwl_priv *priv, struct ieee80211_hdr *hdr) | |||
927 | { | 920 | { |
928 | int sta_id; | 921 | int sta_id; |
929 | u16 fc = le16_to_cpu(hdr->frame_control); | 922 | u16 fc = le16_to_cpu(hdr->frame_control); |
930 | DECLARE_MAC_BUF(mac); | ||
931 | 923 | ||
932 | /* If this frame is broadcast or management, use broadcast station id */ | 924 | /* If this frame is broadcast or management, use broadcast station id */ |
933 | if (((fc & IEEE80211_FCTL_FTYPE) != IEEE80211_FTYPE_DATA) || | 925 | if (((fc & IEEE80211_FCTL_FTYPE) != IEEE80211_FTYPE_DATA) || |
@@ -962,9 +954,9 @@ int iwl_get_sta_id(struct iwl_priv *priv, struct ieee80211_hdr *hdr) | |||
962 | if (sta_id != IWL_INVALID_STATION) | 954 | if (sta_id != IWL_INVALID_STATION) |
963 | return sta_id; | 955 | return sta_id; |
964 | 956 | ||
965 | IWL_DEBUG_DROP("Station %s not in station map. " | 957 | IWL_DEBUG_DROP("Station %pM not in station map. " |
966 | "Defaulting to broadcast...\n", | 958 | "Defaulting to broadcast...\n", |
967 | print_mac(mac, hdr->addr1)); | 959 | hdr->addr1); |
968 | iwl_print_hex_dump(priv, IWL_DL_DROP, (u8 *) hdr, sizeof(*hdr)); | 960 | iwl_print_hex_dump(priv, IWL_DL_DROP, (u8 *) hdr, sizeof(*hdr)); |
969 | return priv->hw_params.bcast_sta_id; | 961 | return priv->hw_params.bcast_sta_id; |
970 | 962 | ||
diff --git a/drivers/net/wireless/iwlwifi/iwl-tx.c b/drivers/net/wireless/iwlwifi/iwl-tx.c index 907a53ebc6e4..37ebcff409e2 100644 --- a/drivers/net/wireless/iwlwifi/iwl-tx.c +++ b/drivers/net/wireless/iwlwifi/iwl-tx.c | |||
@@ -830,10 +830,8 @@ int iwl_tx_skb(struct iwl_priv *priv, struct sk_buff *skb) | |||
830 | /* Find (or create) index into station table for destination station */ | 830 | /* Find (or create) index into station table for destination station */ |
831 | sta_id = iwl_get_sta_id(priv, hdr); | 831 | sta_id = iwl_get_sta_id(priv, hdr); |
832 | if (sta_id == IWL_INVALID_STATION) { | 832 | if (sta_id == IWL_INVALID_STATION) { |
833 | DECLARE_MAC_BUF(mac); | 833 | IWL_DEBUG_DROP("Dropping - INVALID STATION: %pM\n", |
834 | 834 | hdr->addr1); | |
835 | IWL_DEBUG_DROP("Dropping - INVALID STATION: %s\n", | ||
836 | print_mac(mac, hdr->addr1)); | ||
837 | goto drop; | 835 | goto drop; |
838 | } | 836 | } |
839 | 837 | ||
@@ -1248,15 +1246,14 @@ int iwl_tx_agg_start(struct iwl_priv *priv, const u8 *ra, u16 tid, u16 *ssn) | |||
1248 | int ret; | 1246 | int ret; |
1249 | unsigned long flags; | 1247 | unsigned long flags; |
1250 | struct iwl_tid_data *tid_data; | 1248 | struct iwl_tid_data *tid_data; |
1251 | DECLARE_MAC_BUF(mac); | ||
1252 | 1249 | ||
1253 | if (likely(tid < ARRAY_SIZE(default_tid_to_tx_fifo))) | 1250 | if (likely(tid < ARRAY_SIZE(default_tid_to_tx_fifo))) |
1254 | tx_fifo = default_tid_to_tx_fifo[tid]; | 1251 | tx_fifo = default_tid_to_tx_fifo[tid]; |
1255 | else | 1252 | else |
1256 | return -EINVAL; | 1253 | return -EINVAL; |
1257 | 1254 | ||
1258 | IWL_WARNING("%s on ra = %s tid = %d\n", | 1255 | IWL_WARNING("%s on ra = %pM tid = %d\n", |
1259 | __func__, print_mac(mac, ra), tid); | 1256 | __func__, ra, tid); |
1260 | 1257 | ||
1261 | sta_id = iwl_find_station(priv, ra); | 1258 | sta_id = iwl_find_station(priv, ra); |
1262 | if (sta_id == IWL_INVALID_STATION) | 1259 | if (sta_id == IWL_INVALID_STATION) |
@@ -1301,7 +1298,6 @@ int iwl_tx_agg_stop(struct iwl_priv *priv , const u8 *ra, u16 tid) | |||
1301 | struct iwl_tid_data *tid_data; | 1298 | struct iwl_tid_data *tid_data; |
1302 | int ret, write_ptr, read_ptr; | 1299 | int ret, write_ptr, read_ptr; |
1303 | unsigned long flags; | 1300 | unsigned long flags; |
1304 | DECLARE_MAC_BUF(mac); | ||
1305 | 1301 | ||
1306 | if (!ra) { | 1302 | if (!ra) { |
1307 | IWL_ERROR("ra = NULL\n"); | 1303 | IWL_ERROR("ra = NULL\n"); |
@@ -1467,7 +1463,6 @@ void iwl_rx_reply_compressed_ba(struct iwl_priv *priv, | |||
1467 | int index; | 1463 | int index; |
1468 | struct iwl_tx_queue *txq = NULL; | 1464 | struct iwl_tx_queue *txq = NULL; |
1469 | struct iwl_ht_agg *agg; | 1465 | struct iwl_ht_agg *agg; |
1470 | DECLARE_MAC_BUF(mac); | ||
1471 | 1466 | ||
1472 | /* "flow" corresponds to Tx queue */ | 1467 | /* "flow" corresponds to Tx queue */ |
1473 | u16 scd_flow = le16_to_cpu(ba_resp->scd_flow); | 1468 | u16 scd_flow = le16_to_cpu(ba_resp->scd_flow); |
@@ -1489,10 +1484,10 @@ void iwl_rx_reply_compressed_ba(struct iwl_priv *priv, | |||
1489 | 1484 | ||
1490 | /* TODO: Need to get this copy more safely - now good for debug */ | 1485 | /* TODO: Need to get this copy more safely - now good for debug */ |
1491 | 1486 | ||
1492 | IWL_DEBUG_TX_REPLY("REPLY_COMPRESSED_BA [%d]Received from %s, " | 1487 | IWL_DEBUG_TX_REPLY("REPLY_COMPRESSED_BA [%d]Received from %pM, " |
1493 | "sta_id = %d\n", | 1488 | "sta_id = %d\n", |
1494 | agg->wait_for_ba, | 1489 | agg->wait_for_ba, |
1495 | print_mac(mac, (u8 *) &ba_resp->sta_addr_lo32), | 1490 | (u8 *) &ba_resp->sta_addr_lo32, |
1496 | ba_resp->sta_id); | 1491 | ba_resp->sta_id); |
1497 | IWL_DEBUG_TX_REPLY("TID = %d, SeqCtl = %d, bitmap = 0x%llx, scd_flow = " | 1492 | IWL_DEBUG_TX_REPLY("TID = %d, SeqCtl = %d, bitmap = 0x%llx, scd_flow = " |
1498 | "%d, scd_ssn = %d\n", | 1493 | "%d, scd_ssn = %d\n", |
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c index d15a2c997954..d3a2966d9181 100644 --- a/drivers/net/wireless/iwlwifi/iwl3945-base.c +++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c | |||
@@ -446,7 +446,6 @@ u8 iwl3945_add_station(struct iwl3945_priv *priv, const u8 *addr, int is_ap, u8 | |||
446 | int index = IWL_INVALID_STATION; | 446 | int index = IWL_INVALID_STATION; |
447 | struct iwl3945_station_entry *station; | 447 | struct iwl3945_station_entry *station; |
448 | unsigned long flags_spin; | 448 | unsigned long flags_spin; |
449 | DECLARE_MAC_BUF(mac); | ||
450 | u8 rate; | 449 | u8 rate; |
451 | 450 | ||
452 | spin_lock_irqsave(&priv->sta_lock, flags_spin); | 451 | spin_lock_irqsave(&priv->sta_lock, flags_spin); |
@@ -480,7 +479,7 @@ u8 iwl3945_add_station(struct iwl3945_priv *priv, const u8 *addr, int is_ap, u8 | |||
480 | return index; | 479 | return index; |
481 | } | 480 | } |
482 | 481 | ||
483 | IWL_DEBUG_ASSOC("Add STA ID %d: %s\n", index, print_mac(mac, addr)); | 482 | IWL_DEBUG_ASSOC("Add STA ID %d: %pM\n", index, addr); |
484 | station = &priv->stations[index]; | 483 | station = &priv->stations[index]; |
485 | station->used = 1; | 484 | station->used = 1; |
486 | priv->num_stations++; | 485 | priv->num_stations++; |
@@ -1063,7 +1062,6 @@ static int iwl3945_commit_rxon(struct iwl3945_priv *priv) | |||
1063 | /* cast away the const for active_rxon in this function */ | 1062 | /* cast away the const for active_rxon in this function */ |
1064 | struct iwl3945_rxon_cmd *active_rxon = (void *)&priv->active_rxon; | 1063 | struct iwl3945_rxon_cmd *active_rxon = (void *)&priv->active_rxon; |
1065 | int rc = 0; | 1064 | int rc = 0; |
1066 | DECLARE_MAC_BUF(mac); | ||
1067 | 1065 | ||
1068 | if (!iwl3945_is_alive(priv)) | 1066 | if (!iwl3945_is_alive(priv)) |
1069 | return -1; | 1067 | return -1; |
@@ -1124,11 +1122,11 @@ static int iwl3945_commit_rxon(struct iwl3945_priv *priv) | |||
1124 | IWL_DEBUG_INFO("Sending RXON\n" | 1122 | IWL_DEBUG_INFO("Sending RXON\n" |
1125 | "* with%s RXON_FILTER_ASSOC_MSK\n" | 1123 | "* with%s RXON_FILTER_ASSOC_MSK\n" |
1126 | "* channel = %d\n" | 1124 | "* channel = %d\n" |
1127 | "* bssid = %s\n", | 1125 | "* bssid = %pM\n", |
1128 | ((priv->staging_rxon.filter_flags & | 1126 | ((priv->staging_rxon.filter_flags & |
1129 | RXON_FILTER_ASSOC_MSK) ? "" : "out"), | 1127 | RXON_FILTER_ASSOC_MSK) ? "" : "out"), |
1130 | le16_to_cpu(priv->staging_rxon.channel), | 1128 | le16_to_cpu(priv->staging_rxon.channel), |
1131 | print_mac(mac, priv->staging_rxon.bssid_addr)); | 1129 | priv->staging_rxon.bssid_addr); |
1132 | 1130 | ||
1133 | /* Apply the new configuration */ | 1131 | /* Apply the new configuration */ |
1134 | rc = iwl3945_send_cmd_pdu(priv, REPLY_RXON, | 1132 | rc = iwl3945_send_cmd_pdu(priv, REPLY_RXON, |
@@ -2482,8 +2480,6 @@ static int iwl3945_get_sta_id(struct iwl3945_priv *priv, struct ieee80211_hdr *h | |||
2482 | /* If this frame is going out to an IBSS network, find the station, | 2480 | /* If this frame is going out to an IBSS network, find the station, |
2483 | * or create a new station table entry */ | 2481 | * or create a new station table entry */ |
2484 | case NL80211_IFTYPE_ADHOC: { | 2482 | case NL80211_IFTYPE_ADHOC: { |
2485 | DECLARE_MAC_BUF(mac); | ||
2486 | |||
2487 | /* Create new station table entry */ | 2483 | /* Create new station table entry */ |
2488 | sta_id = iwl3945_hw_find_station(priv, hdr->addr1); | 2484 | sta_id = iwl3945_hw_find_station(priv, hdr->addr1); |
2489 | if (sta_id != IWL_INVALID_STATION) | 2485 | if (sta_id != IWL_INVALID_STATION) |
@@ -2494,9 +2490,9 @@ static int iwl3945_get_sta_id(struct iwl3945_priv *priv, struct ieee80211_hdr *h | |||
2494 | if (sta_id != IWL_INVALID_STATION) | 2490 | if (sta_id != IWL_INVALID_STATION) |
2495 | return sta_id; | 2491 | return sta_id; |
2496 | 2492 | ||
2497 | IWL_DEBUG_DROP("Station %s not in station map. " | 2493 | IWL_DEBUG_DROP("Station %pM not in station map. " |
2498 | "Defaulting to broadcast...\n", | 2494 | "Defaulting to broadcast...\n", |
2499 | print_mac(mac, hdr->addr1)); | 2495 | hdr->addr1); |
2500 | iwl3945_print_hex_dump(IWL_DL_DROP, (u8 *) hdr, sizeof(*hdr)); | 2496 | iwl3945_print_hex_dump(IWL_DL_DROP, (u8 *) hdr, sizeof(*hdr)); |
2501 | return priv->hw_setting.bcast_sta_id; | 2497 | return priv->hw_setting.bcast_sta_id; |
2502 | } | 2498 | } |
@@ -2579,10 +2575,8 @@ static int iwl3945_tx_skb(struct iwl3945_priv *priv, struct sk_buff *skb) | |||
2579 | /* Find (or create) index into station table for destination station */ | 2575 | /* Find (or create) index into station table for destination station */ |
2580 | sta_id = iwl3945_get_sta_id(priv, hdr); | 2576 | sta_id = iwl3945_get_sta_id(priv, hdr); |
2581 | if (sta_id == IWL_INVALID_STATION) { | 2577 | if (sta_id == IWL_INVALID_STATION) { |
2582 | DECLARE_MAC_BUF(mac); | 2578 | IWL_DEBUG_DROP("Dropping - INVALID STATION: %pM\n", |
2583 | 2579 | hdr->addr1); | |
2584 | IWL_DEBUG_DROP("Dropping - INVALID STATION: %s\n", | ||
2585 | print_mac(mac, hdr->addr1)); | ||
2586 | goto drop; | 2580 | goto drop; |
2587 | } | 2581 | } |
2588 | 2582 | ||
@@ -4019,8 +4013,6 @@ static int iwl3945_tx_queue_update_write_ptr(struct iwl3945_priv *priv, | |||
4019 | #ifdef CONFIG_IWL3945_DEBUG | 4013 | #ifdef CONFIG_IWL3945_DEBUG |
4020 | static void iwl3945_print_rx_config_cmd(struct iwl3945_rxon_cmd *rxon) | 4014 | static void iwl3945_print_rx_config_cmd(struct iwl3945_rxon_cmd *rxon) |
4021 | { | 4015 | { |
4022 | DECLARE_MAC_BUF(mac); | ||
4023 | |||
4024 | IWL_DEBUG_RADIO("RX CONFIG:\n"); | 4016 | IWL_DEBUG_RADIO("RX CONFIG:\n"); |
4025 | iwl3945_print_hex_dump(IWL_DL_RADIO, (u8 *) rxon, sizeof(*rxon)); | 4017 | iwl3945_print_hex_dump(IWL_DL_RADIO, (u8 *) rxon, sizeof(*rxon)); |
4026 | IWL_DEBUG_RADIO("u16 channel: 0x%x\n", le16_to_cpu(rxon->channel)); | 4018 | IWL_DEBUG_RADIO("u16 channel: 0x%x\n", le16_to_cpu(rxon->channel)); |
@@ -4031,10 +4023,8 @@ static void iwl3945_print_rx_config_cmd(struct iwl3945_rxon_cmd *rxon) | |||
4031 | IWL_DEBUG_RADIO("u8 ofdm_basic_rates: 0x%02x\n", | 4023 | IWL_DEBUG_RADIO("u8 ofdm_basic_rates: 0x%02x\n", |
4032 | rxon->ofdm_basic_rates); | 4024 | rxon->ofdm_basic_rates); |
4033 | IWL_DEBUG_RADIO("u8 cck_basic_rates: 0x%02x\n", rxon->cck_basic_rates); | 4025 | IWL_DEBUG_RADIO("u8 cck_basic_rates: 0x%02x\n", rxon->cck_basic_rates); |
4034 | IWL_DEBUG_RADIO("u8[6] node_addr: %s\n", | 4026 | IWL_DEBUG_RADIO("u8[6] node_addr: %pM\n", rxon->node_addr); |
4035 | print_mac(mac, rxon->node_addr)); | 4027 | IWL_DEBUG_RADIO("u8[6] bssid_addr: %pM\n", rxon->bssid_addr); |
4036 | IWL_DEBUG_RADIO("u8[6] bssid_addr: %s\n", | ||
4037 | print_mac(mac, rxon->bssid_addr)); | ||
4038 | IWL_DEBUG_RADIO("u16 assoc_id: 0x%x\n", le16_to_cpu(rxon->assoc_id)); | 4028 | IWL_DEBUG_RADIO("u16 assoc_id: 0x%x\n", le16_to_cpu(rxon->assoc_id)); |
4039 | } | 4029 | } |
4040 | #endif | 4030 | #endif |
@@ -6321,7 +6311,6 @@ static void iwl3945_post_associate(struct iwl3945_priv *priv) | |||
6321 | { | 6311 | { |
6322 | int rc = 0; | 6312 | int rc = 0; |
6323 | struct ieee80211_conf *conf = NULL; | 6313 | struct ieee80211_conf *conf = NULL; |
6324 | DECLARE_MAC_BUF(mac); | ||
6325 | 6314 | ||
6326 | if (priv->iw_mode == NL80211_IFTYPE_AP) { | 6315 | if (priv->iw_mode == NL80211_IFTYPE_AP) { |
6327 | IWL_ERROR("%s Should not be called in AP mode\n", __func__); | 6316 | IWL_ERROR("%s Should not be called in AP mode\n", __func__); |
@@ -6329,9 +6318,8 @@ static void iwl3945_post_associate(struct iwl3945_priv *priv) | |||
6329 | } | 6318 | } |
6330 | 6319 | ||
6331 | 6320 | ||
6332 | IWL_DEBUG_ASSOC("Associated as %d to: %s\n", | 6321 | IWL_DEBUG_ASSOC("Associated as %d to: %pM\n", |
6333 | priv->assoc_id, | 6322 | priv->assoc_id, priv->active_rxon.bssid_addr); |
6334 | print_mac(mac, priv->active_rxon.bssid_addr)); | ||
6335 | 6323 | ||
6336 | if (test_bit(STATUS_EXIT_PENDING, &priv->status)) | 6324 | if (test_bit(STATUS_EXIT_PENDING, &priv->status)) |
6337 | return; | 6325 | return; |
@@ -6592,7 +6580,6 @@ static int iwl3945_mac_add_interface(struct ieee80211_hw *hw, | |||
6592 | { | 6580 | { |
6593 | struct iwl3945_priv *priv = hw->priv; | 6581 | struct iwl3945_priv *priv = hw->priv; |
6594 | unsigned long flags; | 6582 | unsigned long flags; |
6595 | DECLARE_MAC_BUF(mac); | ||
6596 | 6583 | ||
6597 | IWL_DEBUG_MAC80211("enter: type %d\n", conf->type); | 6584 | IWL_DEBUG_MAC80211("enter: type %d\n", conf->type); |
6598 | 6585 | ||
@@ -6609,7 +6596,7 @@ static int iwl3945_mac_add_interface(struct ieee80211_hw *hw, | |||
6609 | mutex_lock(&priv->mutex); | 6596 | mutex_lock(&priv->mutex); |
6610 | 6597 | ||
6611 | if (conf->mac_addr) { | 6598 | if (conf->mac_addr) { |
6612 | IWL_DEBUG_MAC80211("Set: %s\n", print_mac(mac, conf->mac_addr)); | 6599 | IWL_DEBUG_MAC80211("Set: %pM\n", conf->mac_addr); |
6613 | memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN); | 6600 | memcpy(priv->mac_addr, conf->mac_addr, ETH_ALEN); |
6614 | } | 6601 | } |
6615 | 6602 | ||
@@ -6778,7 +6765,6 @@ static int iwl3945_mac_config_interface(struct ieee80211_hw *hw, | |||
6778 | struct ieee80211_if_conf *conf) | 6765 | struct ieee80211_if_conf *conf) |
6779 | { | 6766 | { |
6780 | struct iwl3945_priv *priv = hw->priv; | 6767 | struct iwl3945_priv *priv = hw->priv; |
6781 | DECLARE_MAC_BUF(mac); | ||
6782 | unsigned long flags; | 6768 | unsigned long flags; |
6783 | int rc; | 6769 | int rc; |
6784 | 6770 | ||
@@ -6816,8 +6802,7 @@ static int iwl3945_mac_config_interface(struct ieee80211_hw *hw, | |||
6816 | mutex_lock(&priv->mutex); | 6802 | mutex_lock(&priv->mutex); |
6817 | 6803 | ||
6818 | if (conf->bssid) | 6804 | if (conf->bssid) |
6819 | IWL_DEBUG_MAC80211("bssid: %s\n", | 6805 | IWL_DEBUG_MAC80211("bssid: %pM\n", conf->bssid); |
6820 | print_mac(mac, conf->bssid)); | ||
6821 | 6806 | ||
6822 | /* | 6807 | /* |
6823 | * very dubious code was here; the probe filtering flag is never set: | 6808 | * very dubious code was here; the probe filtering flag is never set: |
@@ -6830,8 +6815,8 @@ static int iwl3945_mac_config_interface(struct ieee80211_hw *hw, | |||
6830 | if (!conf->bssid) { | 6815 | if (!conf->bssid) { |
6831 | conf->bssid = priv->mac_addr; | 6816 | conf->bssid = priv->mac_addr; |
6832 | memcpy(priv->bssid, priv->mac_addr, ETH_ALEN); | 6817 | memcpy(priv->bssid, priv->mac_addr, ETH_ALEN); |
6833 | IWL_DEBUG_MAC80211("bssid was set to: %s\n", | 6818 | IWL_DEBUG_MAC80211("bssid was set to: %pM\n", |
6834 | print_mac(mac, conf->bssid)); | 6819 | conf->bssid); |
6835 | } | 6820 | } |
6836 | if (priv->ibss_beacon) | 6821 | if (priv->ibss_beacon) |
6837 | dev_kfree_skb(priv->ibss_beacon); | 6822 | dev_kfree_skb(priv->ibss_beacon); |
@@ -7072,10 +7057,8 @@ static int iwl3945_mac_set_key(struct ieee80211_hw *hw, enum set_key_cmd cmd, | |||
7072 | 7057 | ||
7073 | sta_id = iwl3945_hw_find_station(priv, addr); | 7058 | sta_id = iwl3945_hw_find_station(priv, addr); |
7074 | if (sta_id == IWL_INVALID_STATION) { | 7059 | if (sta_id == IWL_INVALID_STATION) { |
7075 | DECLARE_MAC_BUF(mac); | 7060 | IWL_DEBUG_MAC80211("leave - %pM not in station map.\n", |
7076 | 7061 | addr); | |
7077 | IWL_DEBUG_MAC80211("leave - %s not in station map.\n", | ||
7078 | print_mac(mac, addr)); | ||
7079 | return -EINVAL; | 7062 | return -EINVAL; |
7080 | } | 7063 | } |
7081 | 7064 | ||
@@ -7870,7 +7853,6 @@ static int iwl3945_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e | |||
7870 | struct ieee80211_hw *hw; | 7853 | struct ieee80211_hw *hw; |
7871 | struct iwl_3945_cfg *cfg = (struct iwl_3945_cfg *)(ent->driver_data); | 7854 | struct iwl_3945_cfg *cfg = (struct iwl_3945_cfg *)(ent->driver_data); |
7872 | unsigned long flags; | 7855 | unsigned long flags; |
7873 | DECLARE_MAC_BUF(mac); | ||
7874 | 7856 | ||
7875 | /* Disabling hardware scan means that mac80211 will perform scans | 7857 | /* Disabling hardware scan means that mac80211 will perform scans |
7876 | * "the hard way", rather than using device's scan. */ | 7858 | * "the hard way", rather than using device's scan. */ |
@@ -8045,7 +8027,7 @@ static int iwl3945_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e | |||
8045 | } | 8027 | } |
8046 | /* MAC Address location in EEPROM same for 3945/4965 */ | 8028 | /* MAC Address location in EEPROM same for 3945/4965 */ |
8047 | get_eeprom_mac(priv, priv->mac_addr); | 8029 | get_eeprom_mac(priv, priv->mac_addr); |
8048 | IWL_DEBUG_INFO("MAC address: %s\n", print_mac(mac, priv->mac_addr)); | 8030 | IWL_DEBUG_INFO("MAC address: %pM\n", priv->mac_addr); |
8049 | SET_IEEE80211_PERM_ADDR(priv->hw, priv->mac_addr); | 8031 | SET_IEEE80211_PERM_ADDR(priv->hw, priv->mac_addr); |
8050 | 8032 | ||
8051 | err = iwl3945_init_channel_map(priv); | 8033 | err = iwl3945_init_channel_map(priv); |