aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn W. Linville <linville@tuxdriver.com>2011-02-25 15:51:01 -0500
committerJohn W. Linville <linville@tuxdriver.com>2011-02-25 17:04:09 -0500
commitef33417dc9be8d8daca3c715fb5d1226b250725c (patch)
tree368ec3e17d3c1541c9fadfa07e3dbc703bf08aa1
parent5f16a43617d46cf255a66f4dc193a7f5b2540aaf (diff)
iwlegacy: change some symbols duplicated from iwlwifi directory
drivers/net/wireless/iwlegacy/built-in.o:(.rodata+0x29f0): multiple definition of `iwl_rates' drivers/net/wireless/iwlwifi/built-in.o:(.rodata+0xa68): first defined here powerpc64-linux-ld: Warning: size of symbol `iwl_rates' changed from 143 in drivers/net/wireless/iwlwifi/built-in.o to 130 in drivers/net/wireless/iwlegacy/built-in.o drivers/net/wireless/iwlegacy/built-in.o:(.data+0x0): multiple definition of `bt_coex_active' drivers/net/wireless/iwlwifi/built-in.o:(.data+0x668): first defined here drivers/net/wireless/iwlegacy/built-in.o:(.rodata+0x750): multiple definition of `iwl_eeprom_band_1' drivers/net/wireless/iwlwifi/built-in.o:(.rodata+0x27d0): first defined here drivers/net/wireless/iwlegacy/built-in.o:(.rodata+0x3f0): multiple definition of `iwl_bcast_addr' drivers/net/wireless/iwlwifi/built-in.o:(.rodata+0x24f8): first defined here drivers/net/wireless/iwlegacy/built-in.o:(.bss+0x3d48): multiple definition of `iwl_debug_level' drivers/net/wireless/iwlwifi/built-in.o:(.bss+0x21950): first defined here Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-4965-lib.c4
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-4965-rs.c20
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-4965-sta.c5
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-4965-tx.c2
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-core.c21
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-core.h2
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-debug.h2
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-debugfs.c4
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-dev.h8
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-eeprom.c54
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-eeprom.h2
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-legacy-rs.h4
-rw-r--r--drivers/net/wireless/iwlegacy/iwl-scan.c4
-rw-r--r--drivers/net/wireless/iwlegacy/iwl3945-base.c6
-rw-r--r--drivers/net/wireless/iwlegacy/iwl4965-base.c6
15 files changed, 71 insertions, 73 deletions
diff --git a/drivers/net/wireless/iwlegacy/iwl-4965-lib.c b/drivers/net/wireless/iwlegacy/iwl-4965-lib.c
index bd9618a4269d..5a8a3cce27bc 100644
--- a/drivers/net/wireless/iwlegacy/iwl-4965-lib.c
+++ b/drivers/net/wireless/iwlegacy/iwl-4965-lib.c
@@ -424,7 +424,7 @@ int iwl4965_hwrate_to_mac80211_idx(u32 rate_n_flags, enum ieee80211_band band)
424 if (band == IEEE80211_BAND_5GHZ) 424 if (band == IEEE80211_BAND_5GHZ)
425 band_offset = IWL_FIRST_OFDM_RATE; 425 band_offset = IWL_FIRST_OFDM_RATE;
426 for (idx = band_offset; idx < IWL_RATE_COUNT_LEGACY; idx++) 426 for (idx = band_offset; idx < IWL_RATE_COUNT_LEGACY; idx++)
427 if (iwl_rates[idx].plcp == (rate_n_flags & 0xFF)) 427 if (iwlegacy_rates[idx].plcp == (rate_n_flags & 0xFF))
428 return idx - band_offset; 428 return idx - band_offset;
429 } 429 }
430 430
@@ -995,7 +995,7 @@ int iwl4965_request_scan(struct iwl_priv *priv, struct ieee80211_vif *vif)
995 /* use bcast addr, will not be transmitted but must be valid */ 995 /* use bcast addr, will not be transmitted but must be valid */
996 cmd_len = iwl_legacy_fill_probe_req(priv, 996 cmd_len = iwl_legacy_fill_probe_req(priv,
997 (struct ieee80211_mgmt *)scan->data, 997 (struct ieee80211_mgmt *)scan->data,
998 iwl_bcast_addr, NULL, 0, 998 iwlegacy_bcast_addr, NULL, 0,
999 IWL_MAX_SCAN_SIZE - sizeof(*scan)); 999 IWL_MAX_SCAN_SIZE - sizeof(*scan));
1000 1000
1001 } 1001 }
diff --git a/drivers/net/wireless/iwlegacy/iwl-4965-rs.c b/drivers/net/wireless/iwlegacy/iwl-4965-rs.c
index 69abd2816f8d..31ac672b64e1 100644
--- a/drivers/net/wireless/iwlegacy/iwl-4965-rs.c
+++ b/drivers/net/wireless/iwlegacy/iwl-4965-rs.c
@@ -97,7 +97,7 @@ static const u8 ant_toggle_lookup[] = {
97 * maps to IWL_RATE_INVALID 97 * maps to IWL_RATE_INVALID
98 * 98 *
99 */ 99 */
100const struct iwl_rate_info iwl_rates[IWL_RATE_COUNT] = { 100const struct iwl_rate_info iwlegacy_rates[IWL_RATE_COUNT] = {
101 IWL_DECLARE_RATE_INFO(1, INV, INV, 2, INV, 2, INV, 2), /* 1mbps */ 101 IWL_DECLARE_RATE_INFO(1, INV, INV, 2, INV, 2, INV, 2), /* 1mbps */
102 IWL_DECLARE_RATE_INFO(2, INV, 1, 5, 1, 5, 1, 5), /* 2mbps */ 102 IWL_DECLARE_RATE_INFO(2, INV, 1, 5, 1, 5, 1, 5), /* 2mbps */
103 IWL_DECLARE_RATE_INFO(5, INV, 2, 6, 2, 11, 2, 11), /*5.5mbps */ 103 IWL_DECLARE_RATE_INFO(5, INV, 2, 6, 2, 11, 2, 11), /*5.5mbps */
@@ -133,8 +133,8 @@ static int iwl4965_hwrate_to_plcp_idx(u32 rate_n_flags)
133 133
134 /* legacy rate format, search for match in table */ 134 /* legacy rate format, search for match in table */
135 } else { 135 } else {
136 for (idx = 0; idx < ARRAY_SIZE(iwl_rates); idx++) 136 for (idx = 0; idx < ARRAY_SIZE(iwlegacy_rates); idx++)
137 if (iwl_rates[idx].plcp == (rate_n_flags & 0xFF)) 137 if (iwlegacy_rates[idx].plcp == (rate_n_flags & 0xFF))
138 return idx; 138 return idx;
139 } 139 }
140 140
@@ -500,7 +500,7 @@ static u32 iwl4965_rate_n_flags_from_tbl(struct iwl_priv *priv,
500 u32 rate_n_flags = 0; 500 u32 rate_n_flags = 0;
501 501
502 if (is_legacy(tbl->lq_type)) { 502 if (is_legacy(tbl->lq_type)) {
503 rate_n_flags = iwl_rates[index].plcp; 503 rate_n_flags = iwlegacy_rates[index].plcp;
504 if (index >= IWL_FIRST_CCK_RATE && index <= IWL_LAST_CCK_RATE) 504 if (index >= IWL_FIRST_CCK_RATE && index <= IWL_LAST_CCK_RATE)
505 rate_n_flags |= RATE_MCS_CCK_MSK; 505 rate_n_flags |= RATE_MCS_CCK_MSK;
506 506
@@ -512,9 +512,9 @@ static u32 iwl4965_rate_n_flags_from_tbl(struct iwl_priv *priv,
512 rate_n_flags = RATE_MCS_HT_MSK; 512 rate_n_flags = RATE_MCS_HT_MSK;
513 513
514 if (is_siso(tbl->lq_type)) 514 if (is_siso(tbl->lq_type))
515 rate_n_flags |= iwl_rates[index].plcp_siso; 515 rate_n_flags |= iwlegacy_rates[index].plcp_siso;
516 else 516 else
517 rate_n_flags |= iwl_rates[index].plcp_mimo2; 517 rate_n_flags |= iwlegacy_rates[index].plcp_mimo2;
518 } else { 518 } else {
519 IWL_ERR(priv, "Invalid tbl->lq_type %d\n", tbl->lq_type); 519 IWL_ERR(priv, "Invalid tbl->lq_type %d\n", tbl->lq_type);
520 } 520 }
@@ -703,7 +703,7 @@ iwl4965_rs_get_adjacent_rate(struct iwl_priv *priv, u8 index, u16 rate_mask,
703 703
704 low = index; 704 low = index;
705 while (low != IWL_RATE_INVALID) { 705 while (low != IWL_RATE_INVALID) {
706 low = iwl_rates[low].prev_rs; 706 low = iwlegacy_rates[low].prev_rs;
707 if (low == IWL_RATE_INVALID) 707 if (low == IWL_RATE_INVALID)
708 break; 708 break;
709 if (rate_mask & (1 << low)) 709 if (rate_mask & (1 << low))
@@ -713,7 +713,7 @@ iwl4965_rs_get_adjacent_rate(struct iwl_priv *priv, u8 index, u16 rate_mask,
713 713
714 high = index; 714 high = index;
715 while (high != IWL_RATE_INVALID) { 715 while (high != IWL_RATE_INVALID) {
716 high = iwl_rates[high].next_rs; 716 high = iwlegacy_rates[high].next_rs;
717 if (high == IWL_RATE_INVALID) 717 if (high == IWL_RATE_INVALID)
718 break; 718 break;
719 if (rate_mask & (1 << high)) 719 if (rate_mask & (1 << high))
@@ -2221,7 +2221,7 @@ static void iwl4965_rs_initialize_lq(struct iwl_priv *priv,
2221 if ((i < 0) || (i >= IWL_RATE_COUNT)) 2221 if ((i < 0) || (i >= IWL_RATE_COUNT))
2222 i = 0; 2222 i = 0;
2223 2223
2224 rate = iwl_rates[i].plcp; 2224 rate = iwlegacy_rates[i].plcp;
2225 tbl->ant_type = iwl4965_first_antenna(valid_tx_ant); 2225 tbl->ant_type = iwl4965_first_antenna(valid_tx_ant);
2226 rate |= tbl->ant_type << RATE_MCS_ANT_POS; 2226 rate |= tbl->ant_type << RATE_MCS_ANT_POS;
2227 2227
@@ -2791,7 +2791,7 @@ static ssize_t iwl4965_rs_sta_dbgfs_rate_scale_data_read(struct file *file,
2791 else 2791 else
2792 desc += sprintf(buff+desc, 2792 desc += sprintf(buff+desc,
2793 "Bit Rate= %d Mb/s\n", 2793 "Bit Rate= %d Mb/s\n",
2794 iwl_rates[lq_sta->last_txrate_idx].ieee >> 1); 2794 iwlegacy_rates[lq_sta->last_txrate_idx].ieee >> 1);
2795 2795
2796 ret = simple_read_from_buffer(user_buf, count, ppos, buff, desc); 2796 ret = simple_read_from_buffer(user_buf, count, ppos, buff, desc);
2797 return ret; 2797 return ret;
diff --git a/drivers/net/wireless/iwlegacy/iwl-4965-sta.c b/drivers/net/wireless/iwlegacy/iwl-4965-sta.c
index 057da2c3bf95..a262c23553d2 100644
--- a/drivers/net/wireless/iwlegacy/iwl-4965-sta.c
+++ b/drivers/net/wireless/iwlegacy/iwl-4965-sta.c
@@ -59,7 +59,8 @@ iwl4965_sta_alloc_lq(struct iwl_priv *priv, u8 sta_id)
59 59
60 rate_flags |= iwl4965_first_antenna(priv->hw_params.valid_tx_ant) << 60 rate_flags |= iwl4965_first_antenna(priv->hw_params.valid_tx_ant) <<
61 RATE_MCS_ANT_POS; 61 RATE_MCS_ANT_POS;
62 rate_n_flags = iwl4965_hw_set_rate_n_flags(iwl_rates[r].plcp, rate_flags); 62 rate_n_flags = iwl4965_hw_set_rate_n_flags(iwlegacy_rates[r].plcp,
63 rate_flags);
63 for (i = 0; i < LINK_QUAL_MAX_RETRY_NUM; i++) 64 for (i = 0; i < LINK_QUAL_MAX_RETRY_NUM; i++)
64 link_cmd->rs_table[i].rate_n_flags = rate_n_flags; 65 link_cmd->rs_table[i].rate_n_flags = rate_n_flags;
65 66
@@ -553,7 +554,7 @@ int iwl4965_alloc_bcast_station(struct iwl_priv *priv,
553 u8 sta_id; 554 u8 sta_id;
554 555
555 spin_lock_irqsave(&priv->sta_lock, flags); 556 spin_lock_irqsave(&priv->sta_lock, flags);
556 sta_id = iwl_legacy_prep_station(priv, ctx, iwl_bcast_addr, 557 sta_id = iwl_legacy_prep_station(priv, ctx, iwlegacy_bcast_addr,
557 false, NULL); 558 false, NULL);
558 if (sta_id == IWL_INVALID_STATION) { 559 if (sta_id == IWL_INVALID_STATION) {
559 IWL_ERR(priv, "Unable to prepare broadcast station\n"); 560 IWL_ERR(priv, "Unable to prepare broadcast station\n");
diff --git a/drivers/net/wireless/iwlegacy/iwl-4965-tx.c b/drivers/net/wireless/iwlegacy/iwl-4965-tx.c
index 2e0f0dbf87ec..829db91896b0 100644
--- a/drivers/net/wireless/iwlegacy/iwl-4965-tx.c
+++ b/drivers/net/wireless/iwlegacy/iwl-4965-tx.c
@@ -203,7 +203,7 @@ static void iwl4965_tx_cmd_build_rate(struct iwl_priv *priv,
203 if (info->band == IEEE80211_BAND_5GHZ) 203 if (info->band == IEEE80211_BAND_5GHZ)
204 rate_idx += IWL_FIRST_OFDM_RATE; 204 rate_idx += IWL_FIRST_OFDM_RATE;
205 /* Get PLCP rate for tx_cmd->rate_n_flags */ 205 /* Get PLCP rate for tx_cmd->rate_n_flags */
206 rate_plcp = iwl_rates[rate_idx].plcp; 206 rate_plcp = iwlegacy_rates[rate_idx].plcp;
207 /* Zero out flags for this packet */ 207 /* Zero out flags for this packet */
208 rate_flags = 0; 208 rate_flags = 0;
209 209
diff --git a/drivers/net/wireless/iwlegacy/iwl-core.c b/drivers/net/wireless/iwlegacy/iwl-core.c
index 7cc560bc4f95..d418b647be80 100644
--- a/drivers/net/wireless/iwlegacy/iwl-core.c
+++ b/drivers/net/wireless/iwlegacy/iwl-core.c
@@ -64,16 +64,15 @@ MODULE_LICENSE("GPL");
64 * 64 *
65 * default: bt_coex_active = true (BT_COEX_ENABLE) 65 * default: bt_coex_active = true (BT_COEX_ENABLE)
66 */ 66 */
67bool bt_coex_active = true; 67static bool bt_coex_active = true;
68EXPORT_SYMBOL_GPL(bt_coex_active);
69module_param(bt_coex_active, bool, S_IRUGO); 68module_param(bt_coex_active, bool, S_IRUGO);
70MODULE_PARM_DESC(bt_coex_active, "enable wifi/bluetooth co-exist"); 69MODULE_PARM_DESC(bt_coex_active, "enable wifi/bluetooth co-exist");
71 70
72u32 iwl_debug_level; 71u32 iwlegacy_debug_level;
73EXPORT_SYMBOL(iwl_debug_level); 72EXPORT_SYMBOL(iwlegacy_debug_level);
74 73
75const u8 iwl_bcast_addr[ETH_ALEN] = { 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF }; 74const u8 iwlegacy_bcast_addr[ETH_ALEN] = { 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF };
76EXPORT_SYMBOL(iwl_bcast_addr); 75EXPORT_SYMBOL(iwlegacy_bcast_addr);
77 76
78 77
79/* This function both allocates and initializes hw and priv. */ 78/* This function both allocates and initializes hw and priv. */
@@ -183,7 +182,7 @@ int iwl_legacy_init_geos(struct iwl_priv *priv)
183 182
184 /* 5.2GHz channels start after the 2.4GHz channels */ 183 /* 5.2GHz channels start after the 2.4GHz channels */
185 sband = &priv->bands[IEEE80211_BAND_5GHZ]; 184 sband = &priv->bands[IEEE80211_BAND_5GHZ];
186 sband->channels = &channels[ARRAY_SIZE(iwl_eeprom_band_1)]; 185 sband->channels = &channels[ARRAY_SIZE(iwlegacy_eeprom_band_1)];
187 /* just OFDM */ 186 /* just OFDM */
188 sband->bitrates = &rates[IWL_FIRST_OFDM_RATE]; 187 sband->bitrates = &rates[IWL_FIRST_OFDM_RATE];
189 sband->n_bitrates = IWL_RATE_COUNT_LEGACY - IWL_FIRST_OFDM_RATE; 188 sband->n_bitrates = IWL_RATE_COUNT_LEGACY - IWL_FIRST_OFDM_RATE;
@@ -1489,7 +1488,7 @@ int iwl_legacy_alloc_traffic_mem(struct iwl_priv *priv)
1489{ 1488{
1490 u32 traffic_size = IWL_TRAFFIC_DUMP_SIZE; 1489 u32 traffic_size = IWL_TRAFFIC_DUMP_SIZE;
1491 1490
1492 if (iwl_debug_level & IWL_DL_TX) { 1491 if (iwlegacy_debug_level & IWL_DL_TX) {
1493 if (!priv->tx_traffic) { 1492 if (!priv->tx_traffic) {
1494 priv->tx_traffic = 1493 priv->tx_traffic =
1495 kzalloc(traffic_size, GFP_KERNEL); 1494 kzalloc(traffic_size, GFP_KERNEL);
@@ -1497,7 +1496,7 @@ int iwl_legacy_alloc_traffic_mem(struct iwl_priv *priv)
1497 return -ENOMEM; 1496 return -ENOMEM;
1498 } 1497 }
1499 } 1498 }
1500 if (iwl_debug_level & IWL_DL_RX) { 1499 if (iwlegacy_debug_level & IWL_DL_RX) {
1501 if (!priv->rx_traffic) { 1500 if (!priv->rx_traffic) {
1502 priv->rx_traffic = 1501 priv->rx_traffic =
1503 kzalloc(traffic_size, GFP_KERNEL); 1502 kzalloc(traffic_size, GFP_KERNEL);
@@ -1526,7 +1525,7 @@ void iwl_legacy_dbg_log_tx_data_frame(struct iwl_priv *priv,
1526 __le16 fc; 1525 __le16 fc;
1527 u16 len; 1526 u16 len;
1528 1527
1529 if (likely(!(iwl_debug_level & IWL_DL_TX))) 1528 if (likely(!(iwlegacy_debug_level & IWL_DL_TX)))
1530 return; 1529 return;
1531 1530
1532 if (!priv->tx_traffic) 1531 if (!priv->tx_traffic)
@@ -1551,7 +1550,7 @@ void iwl_legacy_dbg_log_rx_data_frame(struct iwl_priv *priv,
1551 __le16 fc; 1550 __le16 fc;
1552 u16 len; 1551 u16 len;
1553 1552
1554 if (likely(!(iwl_debug_level & IWL_DL_RX))) 1553 if (likely(!(iwlegacy_debug_level & IWL_DL_RX)))
1555 return; 1554 return;
1556 1555
1557 if (!priv->rx_traffic) 1556 if (!priv->rx_traffic)
diff --git a/drivers/net/wireless/iwlegacy/iwl-core.h b/drivers/net/wireless/iwlegacy/iwl-core.h
index 1159b0d255b8..c6d12d7e96b6 100644
--- a/drivers/net/wireless/iwlegacy/iwl-core.h
+++ b/drivers/net/wireless/iwlegacy/iwl-core.h
@@ -628,8 +628,6 @@ static inline const struct ieee80211_supported_band *iwl_get_hw_mode(
628 return priv->hw->wiphy->bands[band]; 628 return priv->hw->wiphy->bands[band];
629} 629}
630 630
631extern bool bt_coex_active;
632
633/* mac80211 handlers */ 631/* mac80211 handlers */
634int iwl_legacy_mac_config(struct ieee80211_hw *hw, u32 changed); 632int iwl_legacy_mac_config(struct ieee80211_hw *hw, u32 changed);
635void iwl_legacy_mac_reset_tsf(struct ieee80211_hw *hw); 633void iwl_legacy_mac_reset_tsf(struct ieee80211_hw *hw);
diff --git a/drivers/net/wireless/iwlegacy/iwl-debug.h b/drivers/net/wireless/iwlegacy/iwl-debug.h
index 665789f3e75d..ae13112701bf 100644
--- a/drivers/net/wireless/iwlegacy/iwl-debug.h
+++ b/drivers/net/wireless/iwlegacy/iwl-debug.h
@@ -30,7 +30,7 @@
30#define __iwl_legacy_debug_h__ 30#define __iwl_legacy_debug_h__
31 31
32struct iwl_priv; 32struct iwl_priv;
33extern u32 iwl_debug_level; 33extern u32 iwlegacy_debug_level;
34 34
35#define IWL_ERR(p, f, a...) dev_err(&((p)->pci_dev->dev), f, ## a) 35#define IWL_ERR(p, f, a...) dev_err(&((p)->pci_dev->dev), f, ## a)
36#define IWL_WARN(p, f, a...) dev_warn(&((p)->pci_dev->dev), f, ## a) 36#define IWL_WARN(p, f, a...) dev_warn(&((p)->pci_dev->dev), f, ## a)
diff --git a/drivers/net/wireless/iwlegacy/iwl-debugfs.c b/drivers/net/wireless/iwlegacy/iwl-debugfs.c
index 6ea9c4fbcd3a..2d32438b4cb8 100644
--- a/drivers/net/wireless/iwlegacy/iwl-debugfs.c
+++ b/drivers/net/wireless/iwlegacy/iwl-debugfs.c
@@ -748,7 +748,7 @@ static ssize_t iwl_legacy_dbgfs_traffic_log_read(struct file *file,
748 "q[%d]: read_ptr: %u, write_ptr: %u\n", 748 "q[%d]: read_ptr: %u, write_ptr: %u\n",
749 cnt, q->read_ptr, q->write_ptr); 749 cnt, q->read_ptr, q->write_ptr);
750 } 750 }
751 if (priv->tx_traffic && (iwl_debug_level & IWL_DL_TX)) { 751 if (priv->tx_traffic && (iwlegacy_debug_level & IWL_DL_TX)) {
752 ptr = priv->tx_traffic; 752 ptr = priv->tx_traffic;
753 pos += scnprintf(buf + pos, bufsz - pos, 753 pos += scnprintf(buf + pos, bufsz - pos,
754 "Tx Traffic idx: %u\n", priv->tx_traffic_idx); 754 "Tx Traffic idx: %u\n", priv->tx_traffic_idx);
@@ -771,7 +771,7 @@ static ssize_t iwl_legacy_dbgfs_traffic_log_read(struct file *file,
771 "read: %u, write: %u\n", 771 "read: %u, write: %u\n",
772 rxq->read, rxq->write); 772 rxq->read, rxq->write);
773 773
774 if (priv->rx_traffic && (iwl_debug_level & IWL_DL_RX)) { 774 if (priv->rx_traffic && (iwlegacy_debug_level & IWL_DL_RX)) {
775 ptr = priv->rx_traffic; 775 ptr = priv->rx_traffic;
776 pos += scnprintf(buf + pos, bufsz - pos, 776 pos += scnprintf(buf + pos, bufsz - pos,
777 "Rx Traffic idx: %u\n", priv->rx_traffic_idx); 777 "Rx Traffic idx: %u\n", priv->rx_traffic_idx);
diff --git a/drivers/net/wireless/iwlegacy/iwl-dev.h b/drivers/net/wireless/iwlegacy/iwl-dev.h
index 25718cf9919a..9ee849d669f3 100644
--- a/drivers/net/wireless/iwlegacy/iwl-dev.h
+++ b/drivers/net/wireless/iwlegacy/iwl-dev.h
@@ -624,7 +624,7 @@ struct iwl_hw_params {
624 * 624 *
625 ****************************************************************************/ 625 ****************************************************************************/
626extern void iwl4965_update_chain_flags(struct iwl_priv *priv); 626extern void iwl4965_update_chain_flags(struct iwl_priv *priv);
627extern const u8 iwl_bcast_addr[ETH_ALEN]; 627extern const u8 iwlegacy_bcast_addr[ETH_ALEN];
628extern int iwl_legacy_queue_space(const struct iwl_queue *q); 628extern int iwl_legacy_queue_space(const struct iwl_queue *q);
629static inline int iwl_legacy_queue_used(const struct iwl_queue *q, int i) 629static inline int iwl_legacy_queue_used(const struct iwl_queue *q, int i)
630{ 630{
@@ -1285,7 +1285,7 @@ struct iwl_priv {
1285#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG 1285#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
1286 /* debugging info */ 1286 /* debugging info */
1287 u32 debug_level; /* per device debugging will override global 1287 u32 debug_level; /* per device debugging will override global
1288 iwl_debug_level if set */ 1288 iwlegacy_debug_level if set */
1289#endif /* CONFIG_IWLWIFI_LEGACY_DEBUG */ 1289#endif /* CONFIG_IWLWIFI_LEGACY_DEBUG */
1290#ifdef CONFIG_IWLWIFI_LEGACY_DEBUGFS 1290#ifdef CONFIG_IWLWIFI_LEGACY_DEBUGFS
1291 /* debugfs */ 1291 /* debugfs */
@@ -1338,12 +1338,12 @@ static inline u32 iwl_legacy_get_debug_level(struct iwl_priv *priv)
1338 if (priv->debug_level) 1338 if (priv->debug_level)
1339 return priv->debug_level; 1339 return priv->debug_level;
1340 else 1340 else
1341 return iwl_debug_level; 1341 return iwlegacy_debug_level;
1342} 1342}
1343#else 1343#else
1344static inline u32 iwl_legacy_get_debug_level(struct iwl_priv *priv) 1344static inline u32 iwl_legacy_get_debug_level(struct iwl_priv *priv)
1345{ 1345{
1346 return iwl_debug_level; 1346 return iwlegacy_debug_level;
1347} 1347}
1348#endif 1348#endif
1349 1349
diff --git a/drivers/net/wireless/iwlegacy/iwl-eeprom.c b/drivers/net/wireless/iwlegacy/iwl-eeprom.c
index 39e577323942..04c5648027df 100644
--- a/drivers/net/wireless/iwlegacy/iwl-eeprom.c
+++ b/drivers/net/wireless/iwlegacy/iwl-eeprom.c
@@ -77,7 +77,7 @@
77 77
78/************************** EEPROM BANDS **************************** 78/************************** EEPROM BANDS ****************************
79 * 79 *
80 * The iwl_eeprom_band definitions below provide the mapping from the 80 * The iwlegacy_eeprom_band definitions below provide the mapping from the
81 * EEPROM contents to the specific channel number supported for each 81 * EEPROM contents to the specific channel number supported for each
82 * band. 82 * band.
83 * 83 *
@@ -107,32 +107,32 @@
107 *********************************************************************/ 107 *********************************************************************/
108 108
109/* 2.4 GHz */ 109/* 2.4 GHz */
110const u8 iwl_eeprom_band_1[14] = { 110const u8 iwlegacy_eeprom_band_1[14] = {
111 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14 111 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14
112}; 112};
113 113
114/* 5.2 GHz bands */ 114/* 5.2 GHz bands */
115static const u8 iwl_eeprom_band_2[] = { /* 4915-5080MHz */ 115static const u8 iwlegacy_eeprom_band_2[] = { /* 4915-5080MHz */
116 183, 184, 185, 187, 188, 189, 192, 196, 7, 8, 11, 12, 16 116 183, 184, 185, 187, 188, 189, 192, 196, 7, 8, 11, 12, 16
117}; 117};
118 118
119static const u8 iwl_eeprom_band_3[] = { /* 5170-5320MHz */ 119static const u8 iwlegacy_eeprom_band_3[] = { /* 5170-5320MHz */
120 34, 36, 38, 40, 42, 44, 46, 48, 52, 56, 60, 64 120 34, 36, 38, 40, 42, 44, 46, 48, 52, 56, 60, 64
121}; 121};
122 122
123static const u8 iwl_eeprom_band_4[] = { /* 5500-5700MHz */ 123static const u8 iwlegacy_eeprom_band_4[] = { /* 5500-5700MHz */
124 100, 104, 108, 112, 116, 120, 124, 128, 132, 136, 140 124 100, 104, 108, 112, 116, 120, 124, 128, 132, 136, 140
125}; 125};
126 126
127static const u8 iwl_eeprom_band_5[] = { /* 5725-5825MHz */ 127static const u8 iwlegacy_eeprom_band_5[] = { /* 5725-5825MHz */
128 145, 149, 153, 157, 161, 165 128 145, 149, 153, 157, 161, 165
129}; 129};
130 130
131static const u8 iwl_eeprom_band_6[] = { /* 2.4 ht40 channel */ 131static const u8 iwlegacy_eeprom_band_6[] = { /* 2.4 ht40 channel */
132 1, 2, 3, 4, 5, 6, 7 132 1, 2, 3, 4, 5, 6, 7
133}; 133};
134 134
135static const u8 iwl_eeprom_band_7[] = { /* 5.2 ht40 channel */ 135static const u8 iwlegacy_eeprom_band_7[] = { /* 5.2 ht40 channel */
136 36, 44, 52, 60, 100, 108, 116, 124, 132, 149, 157 136 36, 44, 52, 60, 100, 108, 116, 124, 132, 149, 157
137}; 137};
138 138
@@ -273,46 +273,46 @@ static void iwl_legacy_init_band_reference(const struct iwl_priv *priv,
273 eeprom_ops.regulatory_bands[eep_band - 1]; 273 eeprom_ops.regulatory_bands[eep_band - 1];
274 switch (eep_band) { 274 switch (eep_band) {
275 case 1: /* 2.4GHz band */ 275 case 1: /* 2.4GHz band */
276 *eeprom_ch_count = ARRAY_SIZE(iwl_eeprom_band_1); 276 *eeprom_ch_count = ARRAY_SIZE(iwlegacy_eeprom_band_1);
277 *eeprom_ch_info = (struct iwl_eeprom_channel *) 277 *eeprom_ch_info = (struct iwl_eeprom_channel *)
278 iwl_legacy_eeprom_query_addr(priv, offset); 278 iwl_legacy_eeprom_query_addr(priv, offset);
279 *eeprom_ch_index = iwl_eeprom_band_1; 279 *eeprom_ch_index = iwlegacy_eeprom_band_1;
280 break; 280 break;
281 case 2: /* 4.9GHz band */ 281 case 2: /* 4.9GHz band */
282 *eeprom_ch_count = ARRAY_SIZE(iwl_eeprom_band_2); 282 *eeprom_ch_count = ARRAY_SIZE(iwlegacy_eeprom_band_2);
283 *eeprom_ch_info = (struct iwl_eeprom_channel *) 283 *eeprom_ch_info = (struct iwl_eeprom_channel *)
284 iwl_legacy_eeprom_query_addr(priv, offset); 284 iwl_legacy_eeprom_query_addr(priv, offset);
285 *eeprom_ch_index = iwl_eeprom_band_2; 285 *eeprom_ch_index = iwlegacy_eeprom_band_2;
286 break; 286 break;
287 case 3: /* 5.2GHz band */ 287 case 3: /* 5.2GHz band */
288 *eeprom_ch_count = ARRAY_SIZE(iwl_eeprom_band_3); 288 *eeprom_ch_count = ARRAY_SIZE(iwlegacy_eeprom_band_3);
289 *eeprom_ch_info = (struct iwl_eeprom_channel *) 289 *eeprom_ch_info = (struct iwl_eeprom_channel *)
290 iwl_legacy_eeprom_query_addr(priv, offset); 290 iwl_legacy_eeprom_query_addr(priv, offset);
291 *eeprom_ch_index = iwl_eeprom_band_3; 291 *eeprom_ch_index = iwlegacy_eeprom_band_3;
292 break; 292 break;
293 case 4: /* 5.5GHz band */ 293 case 4: /* 5.5GHz band */
294 *eeprom_ch_count = ARRAY_SIZE(iwl_eeprom_band_4); 294 *eeprom_ch_count = ARRAY_SIZE(iwlegacy_eeprom_band_4);
295 *eeprom_ch_info = (struct iwl_eeprom_channel *) 295 *eeprom_ch_info = (struct iwl_eeprom_channel *)
296 iwl_legacy_eeprom_query_addr(priv, offset); 296 iwl_legacy_eeprom_query_addr(priv, offset);
297 *eeprom_ch_index = iwl_eeprom_band_4; 297 *eeprom_ch_index = iwlegacy_eeprom_band_4;
298 break; 298 break;
299 case 5: /* 5.7GHz band */ 299 case 5: /* 5.7GHz band */
300 *eeprom_ch_count = ARRAY_SIZE(iwl_eeprom_band_5); 300 *eeprom_ch_count = ARRAY_SIZE(iwlegacy_eeprom_band_5);
301 *eeprom_ch_info = (struct iwl_eeprom_channel *) 301 *eeprom_ch_info = (struct iwl_eeprom_channel *)
302 iwl_legacy_eeprom_query_addr(priv, offset); 302 iwl_legacy_eeprom_query_addr(priv, offset);
303 *eeprom_ch_index = iwl_eeprom_band_5; 303 *eeprom_ch_index = iwlegacy_eeprom_band_5;
304 break; 304 break;
305 case 6: /* 2.4GHz ht40 channels */ 305 case 6: /* 2.4GHz ht40 channels */
306 *eeprom_ch_count = ARRAY_SIZE(iwl_eeprom_band_6); 306 *eeprom_ch_count = ARRAY_SIZE(iwlegacy_eeprom_band_6);
307 *eeprom_ch_info = (struct iwl_eeprom_channel *) 307 *eeprom_ch_info = (struct iwl_eeprom_channel *)
308 iwl_legacy_eeprom_query_addr(priv, offset); 308 iwl_legacy_eeprom_query_addr(priv, offset);
309 *eeprom_ch_index = iwl_eeprom_band_6; 309 *eeprom_ch_index = iwlegacy_eeprom_band_6;
310 break; 310 break;
311 case 7: /* 5 GHz ht40 channels */ 311 case 7: /* 5 GHz ht40 channels */
312 *eeprom_ch_count = ARRAY_SIZE(iwl_eeprom_band_7); 312 *eeprom_ch_count = ARRAY_SIZE(iwlegacy_eeprom_band_7);
313 *eeprom_ch_info = (struct iwl_eeprom_channel *) 313 *eeprom_ch_info = (struct iwl_eeprom_channel *)
314 iwl_legacy_eeprom_query_addr(priv, offset); 314 iwl_legacy_eeprom_query_addr(priv, offset);
315 *eeprom_ch_index = iwl_eeprom_band_7; 315 *eeprom_ch_index = iwlegacy_eeprom_band_7;
316 break; 316 break;
317 default: 317 default:
318 BUG(); 318 BUG();
@@ -388,11 +388,11 @@ int iwl_legacy_init_channel_map(struct iwl_priv *priv)
388 IWL_DEBUG_EEPROM(priv, "Initializing regulatory info from EEPROM\n"); 388 IWL_DEBUG_EEPROM(priv, "Initializing regulatory info from EEPROM\n");
389 389
390 priv->channel_count = 390 priv->channel_count =
391 ARRAY_SIZE(iwl_eeprom_band_1) + 391 ARRAY_SIZE(iwlegacy_eeprom_band_1) +
392 ARRAY_SIZE(iwl_eeprom_band_2) + 392 ARRAY_SIZE(iwlegacy_eeprom_band_2) +
393 ARRAY_SIZE(iwl_eeprom_band_3) + 393 ARRAY_SIZE(iwlegacy_eeprom_band_3) +
394 ARRAY_SIZE(iwl_eeprom_band_4) + 394 ARRAY_SIZE(iwlegacy_eeprom_band_4) +
395 ARRAY_SIZE(iwl_eeprom_band_5); 395 ARRAY_SIZE(iwlegacy_eeprom_band_5);
396 396
397 IWL_DEBUG_EEPROM(priv, "Parsing data for %d channels.\n", 397 IWL_DEBUG_EEPROM(priv, "Parsing data for %d channels.\n",
398 priv->channel_count); 398 priv->channel_count);
diff --git a/drivers/net/wireless/iwlegacy/iwl-eeprom.h b/drivers/net/wireless/iwlegacy/iwl-eeprom.h
index 0744f8da63b4..c59c81002022 100644
--- a/drivers/net/wireless/iwlegacy/iwl-eeprom.h
+++ b/drivers/net/wireless/iwlegacy/iwl-eeprom.h
@@ -144,7 +144,7 @@ struct iwl_eeprom_channel {
144#define EEPROM_4965_BOARD_PBA (2*0x56+1) /* 9 bytes */ 144#define EEPROM_4965_BOARD_PBA (2*0x56+1) /* 9 bytes */
145 145
146/* 2.4 GHz */ 146/* 2.4 GHz */
147extern const u8 iwl_eeprom_band_1[14]; 147extern const u8 iwlegacy_eeprom_band_1[14];
148 148
149/* 149/*
150 * factory calibration data for one txpower level, on one channel, 150 * factory calibration data for one txpower level, on one channel,
diff --git a/drivers/net/wireless/iwlegacy/iwl-legacy-rs.h b/drivers/net/wireless/iwlegacy/iwl-legacy-rs.h
index f66a1b2c0397..38647e481eb0 100644
--- a/drivers/net/wireless/iwlegacy/iwl-legacy-rs.h
+++ b/drivers/net/wireless/iwlegacy/iwl-legacy-rs.h
@@ -56,7 +56,7 @@ struct iwl3945_rate_info {
56 56
57/* 57/*
58 * These serve as indexes into 58 * These serve as indexes into
59 * struct iwl_rate_info iwl_rates[IWL_RATE_COUNT]; 59 * struct iwl_rate_info iwlegacy_rates[IWL_RATE_COUNT];
60 */ 60 */
61enum { 61enum {
62 IWL_RATE_1M_INDEX = 0, 62 IWL_RATE_1M_INDEX = 0,
@@ -268,7 +268,7 @@ enum {
268#define TID_MAX_TIME_DIFF ((TID_QUEUE_MAX_SIZE - 1) * TID_QUEUE_CELL_SPACING) 268#define TID_MAX_TIME_DIFF ((TID_QUEUE_MAX_SIZE - 1) * TID_QUEUE_CELL_SPACING)
269#define TIME_WRAP_AROUND(x, y) (((y) > (x)) ? (y) - (x) : (0-(x)) + (y)) 269#define TIME_WRAP_AROUND(x, y) (((y) > (x)) ? (y) - (x) : (0-(x)) + (y))
270 270
271extern const struct iwl_rate_info iwl_rates[IWL_RATE_COUNT]; 271extern const struct iwl_rate_info iwlegacy_rates[IWL_RATE_COUNT];
272 272
273enum iwl_table_type { 273enum iwl_table_type {
274 LQ_NONE, 274 LQ_NONE,
diff --git a/drivers/net/wireless/iwlegacy/iwl-scan.c b/drivers/net/wireless/iwlegacy/iwl-scan.c
index 842f0b46b6df..60f597f796ca 100644
--- a/drivers/net/wireless/iwlegacy/iwl-scan.c
+++ b/drivers/net/wireless/iwlegacy/iwl-scan.c
@@ -492,9 +492,9 @@ iwl_legacy_fill_probe_req(struct iwl_priv *priv, struct ieee80211_mgmt *frame,
492 return 0; 492 return 0;
493 493
494 frame->frame_control = cpu_to_le16(IEEE80211_STYPE_PROBE_REQ); 494 frame->frame_control = cpu_to_le16(IEEE80211_STYPE_PROBE_REQ);
495 memcpy(frame->da, iwl_bcast_addr, ETH_ALEN); 495 memcpy(frame->da, iwlegacy_bcast_addr, ETH_ALEN);
496 memcpy(frame->sa, ta, ETH_ALEN); 496 memcpy(frame->sa, ta, ETH_ALEN);
497 memcpy(frame->bssid, iwl_bcast_addr, ETH_ALEN); 497 memcpy(frame->bssid, iwlegacy_bcast_addr, ETH_ALEN);
498 frame->seq_ctrl = 0; 498 frame->seq_ctrl = 0;
499 499
500 len += 24; 500 len += 24;
diff --git a/drivers/net/wireless/iwlegacy/iwl3945-base.c b/drivers/net/wireless/iwlegacy/iwl3945-base.c
index a6af9817efce..ab87e1b73529 100644
--- a/drivers/net/wireless/iwlegacy/iwl3945-base.c
+++ b/drivers/net/wireless/iwlegacy/iwl3945-base.c
@@ -2630,7 +2630,7 @@ static int iwl3945_alloc_bcast_station(struct iwl_priv *priv)
2630 2630
2631 spin_lock_irqsave(&priv->sta_lock, flags); 2631 spin_lock_irqsave(&priv->sta_lock, flags);
2632 sta_id = iwl_legacy_prep_station(priv, ctx, 2632 sta_id = iwl_legacy_prep_station(priv, ctx,
2633 iwl_bcast_addr, false, NULL); 2633 iwlegacy_bcast_addr, false, NULL);
2634 if (sta_id == IWL_INVALID_STATION) { 2634 if (sta_id == IWL_INVALID_STATION) {
2635 IWL_ERR(priv, "Unable to prepare broadcast station\n"); 2635 IWL_ERR(priv, "Unable to prepare broadcast station\n");
2636 spin_unlock_irqrestore(&priv->sta_lock, flags); 2636 spin_unlock_irqrestore(&priv->sta_lock, flags);
@@ -2929,7 +2929,7 @@ int iwl3945_request_scan(struct iwl_priv *priv, struct ieee80211_vif *vif)
2929 scan->tx_cmd.len = cpu_to_le16( 2929 scan->tx_cmd.len = cpu_to_le16(
2930 iwl_legacy_fill_probe_req(priv, 2930 iwl_legacy_fill_probe_req(priv,
2931 (struct ieee80211_mgmt *)scan->data, 2931 (struct ieee80211_mgmt *)scan->data,
2932 iwl_bcast_addr, NULL, 0, 2932 iwlegacy_bcast_addr, NULL, 0,
2933 IWL_MAX_SCAN_SIZE - sizeof(*scan))); 2933 IWL_MAX_SCAN_SIZE - sizeof(*scan)));
2934 } 2934 }
2935 /* select Rx antennas */ 2935 /* select Rx antennas */
@@ -4283,7 +4283,7 @@ module_param_named(disable_hw_scan, iwl3945_mod_params.disable_hw_scan,
4283MODULE_PARM_DESC(disable_hw_scan, 4283MODULE_PARM_DESC(disable_hw_scan,
4284 "disable hardware scanning (default 0) (deprecated)"); 4284 "disable hardware scanning (default 0) (deprecated)");
4285#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG 4285#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
4286module_param_named(debug, iwl_debug_level, uint, S_IRUGO | S_IWUSR); 4286module_param_named(debug, iwlegacy_debug_level, uint, S_IRUGO | S_IWUSR);
4287MODULE_PARM_DESC(debug, "debug output mask"); 4287MODULE_PARM_DESC(debug, "debug output mask");
4288#endif 4288#endif
4289module_param_named(fw_restart, iwl3945_mod_params.restart_fw, int, S_IRUGO); 4289module_param_named(fw_restart, iwl3945_mod_params.restart_fw, int, S_IRUGO);
diff --git a/drivers/net/wireless/iwlegacy/iwl4965-base.c b/drivers/net/wireless/iwlegacy/iwl4965-base.c
index 4d53d0ff5fc7..91b3d8b9d7a5 100644
--- a/drivers/net/wireless/iwlegacy/iwl4965-base.c
+++ b/drivers/net/wireless/iwlegacy/iwl4965-base.c
@@ -3057,7 +3057,7 @@ static void iwl4965_init_hw_rates(struct iwl_priv *priv,
3057 int i; 3057 int i;
3058 3058
3059 for (i = 0; i < IWL_RATE_COUNT_LEGACY; i++) { 3059 for (i = 0; i < IWL_RATE_COUNT_LEGACY; i++) {
3060 rates[i].bitrate = iwl_rates[i].ieee * 5; 3060 rates[i].bitrate = iwlegacy_rates[i].ieee * 5;
3061 rates[i].hw_value = i; /* Rate scaling will work on indexes */ 3061 rates[i].hw_value = i; /* Rate scaling will work on indexes */
3062 rates[i].hw_value_short = i; 3062 rates[i].hw_value_short = i;
3063 rates[i].flags = 0; 3063 rates[i].flags = 0;
@@ -3066,7 +3066,7 @@ static void iwl4965_init_hw_rates(struct iwl_priv *priv,
3066 * If CCK != 1M then set short preamble rate flag. 3066 * If CCK != 1M then set short preamble rate flag.
3067 */ 3067 */
3068 rates[i].flags |= 3068 rates[i].flags |=
3069 (iwl_rates[i].plcp == IWL_RATE_1M_PLCP) ? 3069 (iwlegacy_rates[i].plcp == IWL_RATE_1M_PLCP) ?
3070 0 : IEEE80211_RATE_SHORT_PREAMBLE; 3070 0 : IEEE80211_RATE_SHORT_PREAMBLE;
3071 } 3071 }
3072 } 3072 }
@@ -3615,7 +3615,7 @@ module_exit(iwl4965_exit);
3615module_init(iwl4965_init); 3615module_init(iwl4965_init);
3616 3616
3617#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG 3617#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
3618module_param_named(debug, iwl_debug_level, uint, S_IRUGO | S_IWUSR); 3618module_param_named(debug, iwlegacy_debug_level, uint, S_IRUGO | S_IWUSR);
3619MODULE_PARM_DESC(debug, "debug output mask"); 3619MODULE_PARM_DESC(debug, "debug output mask");
3620#endif 3620#endif
3621 3621