1 /******************************************************************************
3 * Copyright(c) 2008 - 2010 Intel Corporation. All rights reserved.
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.
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
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
18 * The full GNU General Public License is included in this distribution in the
19 * file called LICENSE.
21 * Contact Information:
22 * Intel Linux Wireless <ilw@linux.intel.com>
23 * Intel Corporation, 5200 N.E. Elam Young Parkway, Hillsboro, OR 97124-6497
25 *****************************************************************************/
27 #include <linux/kernel.h>
28 #include <linux/module.h>
29 #include <linux/init.h>
30 #include <linux/pci.h>
31 #include <linux/dma-mapping.h>
32 #include <linux/delay.h>
33 #include <linux/skbuff.h>
34 #include <linux/netdevice.h>
35 #include <linux/wireless.h>
36 #include <net/mac80211.h>
37 #include <linux/etherdevice.h>
38 #include <asm/unaligned.h>
40 #include "iwl-eeprom.h"
46 #include "iwl-helpers.h"
47 #include "iwl-agn-hw.h"
48 #include "iwl-6000-hw.h"
49 #include "iwl-agn-led.h"
50 #include "iwl-agn-debugfs.h"
52 /* Highest firmware API version supported */
53 #define IWL6000_UCODE_API_MAX 4
54 #define IWL6050_UCODE_API_MAX 5
55 #define IWL6000G2_UCODE_API_MAX 5
56 #define IWL130_UCODE_API_MAX 5
58 /* Lowest firmware API version supported */
59 #define IWL6000_UCODE_API_MIN 4
60 #define IWL6050_UCODE_API_MIN 4
61 #define IWL6000G2_UCODE_API_MIN 4
62 #define IWL130_UCODE_API_MIN 5
64 #define IWL6000_FW_PRE "iwlwifi-6000-"
65 #define _IWL6000_MODULE_FIRMWARE(api) IWL6000_FW_PRE #api ".ucode"
66 #define IWL6000_MODULE_FIRMWARE(api) _IWL6000_MODULE_FIRMWARE(api)
68 #define IWL6050_FW_PRE "iwlwifi-6050-"
69 #define _IWL6050_MODULE_FIRMWARE(api) IWL6050_FW_PRE #api ".ucode"
70 #define IWL6050_MODULE_FIRMWARE(api) _IWL6050_MODULE_FIRMWARE(api)
72 #define IWL6000G2A_FW_PRE "iwlwifi-6000g2a-"
73 #define _IWL6000G2A_MODULE_FIRMWARE(api) IWL6000G2A_FW_PRE #api ".ucode"
74 #define IWL6000G2A_MODULE_FIRMWARE(api) _IWL6000G2A_MODULE_FIRMWARE(api)
76 #define IWL6000G2B_FW_PRE "iwlwifi-6000g2b-"
77 #define _IWL6000G2B_MODULE_FIRMWARE(api) IWL6000G2B_FW_PRE #api ".ucode"
78 #define IWL6000G2B_MODULE_FIRMWARE(api) _IWL6000G2B_MODULE_FIRMWARE(api)
80 #define IWL130_FW_PRE "iwlwifi-130-"
81 #define _IWL130_MODULE_FIRMWARE(api) IWL130_FW_PRE #api ".ucode"
82 #define IWL130_MODULE_FIRMWARE(api) _IWL130_MODULE_FIRMWARE(api)
84 static void iwl6000_set_ct_threshold(struct iwl_priv *priv)
87 priv->hw_params.ct_kill_threshold = CT_KILL_THRESHOLD;
88 priv->hw_params.ct_kill_exit_threshold = CT_KILL_EXIT_THRESHOLD;
91 static void iwl6050_additional_nic_config(struct iwl_priv *priv)
93 /* Indicate calibration version to uCode. */
94 if (priv->cfg->ops->lib->eeprom_ops.calib_version(priv) >= 6)
95 iwl_set_bit(priv, CSR_GP_DRIVER_REG,
96 CSR_GP_DRIVER_REG_BIT_CALIB_VERSION6);
99 static void iwl6050g2_additional_nic_config(struct iwl_priv *priv)
101 /* Indicate calibration version to uCode. */
102 if (priv->cfg->ops->lib->eeprom_ops.calib_version(priv) >= 6)
103 iwl_set_bit(priv, CSR_GP_DRIVER_REG,
104 CSR_GP_DRIVER_REG_BIT_CALIB_VERSION6);
105 iwl_set_bit(priv, CSR_GP_DRIVER_REG,
106 CSR_GP_DRIVER_REG_BIT_6050_1x2);
109 /* NIC configuration for 6000 series */
110 static void iwl6000_nic_config(struct iwl_priv *priv)
114 radio_cfg = iwl_eeprom_query16(priv, EEPROM_RADIO_CONFIG);
116 /* write radio config values to register */
117 if (EEPROM_RF_CFG_TYPE_MSK(radio_cfg) <= EEPROM_RF_CONFIG_TYPE_MAX)
118 iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG,
119 EEPROM_RF_CFG_TYPE_MSK(radio_cfg) |
120 EEPROM_RF_CFG_STEP_MSK(radio_cfg) |
121 EEPROM_RF_CFG_DASH_MSK(radio_cfg));
123 /* set CSR_HW_CONFIG_REG for uCode use */
124 iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG,
125 CSR_HW_IF_CONFIG_REG_BIT_RADIO_SI |
126 CSR_HW_IF_CONFIG_REG_BIT_MAC_SI);
128 /* no locking required for register write */
129 if (priv->cfg->pa_type == IWL_PA_INTERNAL) {
130 /* 2x2 IPA phy type */
131 iwl_write32(priv, CSR_GP_DRIVER_REG,
132 CSR_GP_DRIVER_REG_BIT_RADIO_SKU_2x2_IPA);
134 /* do additional nic configuration if needed */
135 if (priv->cfg->ops->nic &&
136 priv->cfg->ops->nic->additional_nic_config) {
137 priv->cfg->ops->nic->additional_nic_config(priv);
141 static struct iwl_sensitivity_ranges iwl6000_sensitivity = {
143 .max_nrg_cck = 0, /* not used, set to 0 */
144 .auto_corr_min_ofdm = 80,
145 .auto_corr_min_ofdm_mrc = 128,
146 .auto_corr_min_ofdm_x1 = 105,
147 .auto_corr_min_ofdm_mrc_x1 = 192,
149 .auto_corr_max_ofdm = 145,
150 .auto_corr_max_ofdm_mrc = 232,
151 .auto_corr_max_ofdm_x1 = 110,
152 .auto_corr_max_ofdm_mrc_x1 = 232,
154 .auto_corr_min_cck = 125,
155 .auto_corr_max_cck = 175,
156 .auto_corr_min_cck_mrc = 160,
157 .auto_corr_max_cck_mrc = 310,
161 .barker_corr_th_min = 190,
162 .barker_corr_th_min_mrc = 390,
166 static int iwl6000_hw_set_hw_params(struct iwl_priv *priv)
168 if (priv->cfg->mod_params->num_of_queues >= IWL_MIN_NUM_QUEUES &&
169 priv->cfg->mod_params->num_of_queues <= IWLAGN_NUM_QUEUES)
170 priv->cfg->base_params->num_of_queues =
171 priv->cfg->mod_params->num_of_queues;
173 priv->hw_params.max_txq_num = priv->cfg->base_params->num_of_queues;
174 priv->hw_params.dma_chnl_num = FH50_TCSR_CHNL_NUM;
175 priv->hw_params.scd_bc_tbls_size =
176 priv->cfg->base_params->num_of_queues *
177 sizeof(struct iwlagn_scd_bc_tbl);
178 priv->hw_params.tfd_size = sizeof(struct iwl_tfd);
179 priv->hw_params.max_stations = IWLAGN_STATION_COUNT;
180 priv->contexts[IWL_RXON_CTX_BSS].bcast_sta_id = IWLAGN_BROADCAST_ID;
182 priv->hw_params.max_data_size = IWL60_RTC_DATA_SIZE;
183 priv->hw_params.max_inst_size = IWL60_RTC_INST_SIZE;
185 priv->hw_params.max_bsm_size = 0;
186 priv->hw_params.ht40_channel = BIT(IEEE80211_BAND_2GHZ) |
187 BIT(IEEE80211_BAND_5GHZ);
188 priv->hw_params.rx_wrt_ptr_reg = FH_RSCSR_CHNL0_WPTR;
190 priv->hw_params.tx_chains_num = num_of_ant(priv->cfg->valid_tx_ant);
191 priv->hw_params.rx_chains_num = num_of_ant(priv->cfg->valid_rx_ant);
192 priv->hw_params.valid_tx_ant = priv->cfg->valid_tx_ant;
193 priv->hw_params.valid_rx_ant = priv->cfg->valid_rx_ant;
195 iwl6000_set_ct_threshold(priv);
197 /* Set initial sensitivity parameters */
198 /* Set initial calibration set */
199 priv->hw_params.sens = &iwl6000_sensitivity;
200 priv->hw_params.calib_init_cfg =
201 BIT(IWL_CALIB_XTAL) |
203 BIT(IWL_CALIB_TX_IQ) |
204 BIT(IWL_CALIB_BASE_BAND);
205 if (priv->cfg->need_dc_calib)
206 priv->hw_params.calib_rt_cfg |= BIT(IWL_CALIB_CFG_DC_IDX);
207 if (priv->cfg->need_temp_offset_calib)
208 priv->hw_params.calib_init_cfg |= BIT(IWL_CALIB_TEMP_OFFSET);
210 priv->hw_params.beacon_time_tsf_bits = IWLAGN_EXT_BEACON_TIME_POS;
215 static int iwl6000_hw_channel_switch(struct iwl_priv *priv,
216 struct ieee80211_channel_switch *ch_switch)
220 * See iwl_mac_channel_switch.
222 struct iwl_rxon_context *ctx = &priv->contexts[IWL_RXON_CTX_BSS];
223 struct iwl6000_channel_switch_cmd cmd;
224 const struct iwl_channel_info *ch_info;
225 u32 switch_time_in_usec, ucode_switch_time;
229 u16 beacon_interval = le16_to_cpu(ctx->timing.beacon_interval);
230 struct ieee80211_vif *vif = ctx->vif;
231 struct iwl_host_cmd hcmd = {
232 .id = REPLY_CHANNEL_SWITCH,
238 cmd.band = priv->band == IEEE80211_BAND_2GHZ;
239 ch = ch_switch->channel->hw_value;
240 IWL_DEBUG_11H(priv, "channel switch from %u to %u\n",
241 ctx->active.channel, ch);
242 cmd.channel = cpu_to_le16(ch);
243 cmd.rxon_flags = ctx->staging.flags;
244 cmd.rxon_filter_flags = ctx->staging.filter_flags;
245 switch_count = ch_switch->count;
246 tsf_low = ch_switch->timestamp & 0x0ffffffff;
248 * calculate the ucode channel switch time
249 * adding TSF as one of the factor for when to switch
251 if ((priv->ucode_beacon_time > tsf_low) && beacon_interval) {
252 if (switch_count > ((priv->ucode_beacon_time - tsf_low) /
254 switch_count -= (priv->ucode_beacon_time -
255 tsf_low) / beacon_interval;
259 if (switch_count <= 1)
260 cmd.switch_time = cpu_to_le32(priv->ucode_beacon_time);
262 switch_time_in_usec =
263 vif->bss_conf.beacon_int * switch_count * TIME_UNIT;
264 ucode_switch_time = iwl_usecs_to_beacons(priv,
267 cmd.switch_time = iwl_add_beacon_time(priv,
268 priv->ucode_beacon_time,
272 IWL_DEBUG_11H(priv, "uCode time for the switch is 0x%x\n",
274 ch_info = iwl_get_channel_info(priv, priv->band, ch);
276 cmd.expect_beacon = is_channel_radar(ch_info);
278 IWL_ERR(priv, "invalid channel switch from %u to %u\n",
279 ctx->active.channel, ch);
282 priv->switch_rxon.channel = cmd.channel;
283 priv->switch_rxon.switch_in_progress = true;
285 return iwl_send_cmd_sync(priv, &hcmd);
288 static struct iwl_lib_ops iwl6000_lib = {
289 .set_hw_params = iwl6000_hw_set_hw_params,
290 .txq_update_byte_cnt_tbl = iwlagn_txq_update_byte_cnt_tbl,
291 .txq_inval_byte_cnt_tbl = iwlagn_txq_inval_byte_cnt_tbl,
292 .txq_set_sched = iwlagn_txq_set_sched,
293 .txq_agg_enable = iwlagn_txq_agg_enable,
294 .txq_agg_disable = iwlagn_txq_agg_disable,
295 .txq_attach_buf_to_tfd = iwl_hw_txq_attach_buf_to_tfd,
296 .txq_free_tfd = iwl_hw_txq_free_tfd,
297 .txq_init = iwl_hw_tx_queue_init,
298 .rx_handler_setup = iwlagn_rx_handler_setup,
299 .setup_deferred_work = iwlagn_setup_deferred_work,
300 .is_valid_rtc_data_addr = iwlagn_hw_valid_rtc_data_addr,
301 .load_ucode = iwlagn_load_ucode,
302 .dump_nic_event_log = iwl_dump_nic_event_log,
303 .dump_nic_error_log = iwl_dump_nic_error_log,
304 .dump_csr = iwl_dump_csr,
305 .dump_fh = iwl_dump_fh,
306 .init_alive_start = iwlagn_init_alive_start,
307 .alive_notify = iwlagn_alive_notify,
308 .send_tx_power = iwlagn_send_tx_power,
309 .update_chain_flags = iwl_update_chain_flags,
310 .set_channel_switch = iwl6000_hw_channel_switch,
312 .init = iwl_apm_init,
313 .config = iwl6000_nic_config,
316 .regulatory_bands = {
317 EEPROM_REG_BAND_1_CHANNELS,
318 EEPROM_REG_BAND_2_CHANNELS,
319 EEPROM_REG_BAND_3_CHANNELS,
320 EEPROM_REG_BAND_4_CHANNELS,
321 EEPROM_REG_BAND_5_CHANNELS,
322 EEPROM_6000_REG_BAND_24_HT40_CHANNELS,
323 EEPROM_REG_BAND_52_HT40_CHANNELS
325 .acquire_semaphore = iwlcore_eeprom_acquire_semaphore,
326 .release_semaphore = iwlcore_eeprom_release_semaphore,
327 .calib_version = iwlagn_eeprom_calib_version,
328 .query_addr = iwlagn_eeprom_query_addr,
329 .update_enhanced_txpower = iwlcore_eeprom_enhanced_txpower,
333 .temperature = iwlagn_temperature,
336 .rx_stats_read = iwl_ucode_rx_stats_read,
337 .tx_stats_read = iwl_ucode_tx_stats_read,
338 .general_stats_read = iwl_ucode_general_stats_read,
339 .bt_stats_read = iwl_ucode_bt_stats_read,
340 .reply_tx_error = iwl_reply_tx_error_read,
342 .recover_from_tx_stall = iwl_bg_monitor_recover,
343 .check_plcp_health = iwl_good_plcp_health,
344 .check_ack_health = iwl_good_ack_health,
345 .txfifo_flush = iwlagn_txfifo_flush,
346 .dev_txfifo_flush = iwlagn_dev_txfifo_flush,
348 .lower_power_detection = iwl_tt_is_low_power_state,
349 .tt_power_mode = iwl_tt_current_power_mode,
350 .ct_kill_check = iwl_check_for_ct_kill,
354 static struct iwl_lib_ops iwl6000g2b_lib = {
355 .set_hw_params = iwl6000_hw_set_hw_params,
356 .txq_update_byte_cnt_tbl = iwlagn_txq_update_byte_cnt_tbl,
357 .txq_inval_byte_cnt_tbl = iwlagn_txq_inval_byte_cnt_tbl,
358 .txq_set_sched = iwlagn_txq_set_sched,
359 .txq_agg_enable = iwlagn_txq_agg_enable,
360 .txq_agg_disable = iwlagn_txq_agg_disable,
361 .txq_attach_buf_to_tfd = iwl_hw_txq_attach_buf_to_tfd,
362 .txq_free_tfd = iwl_hw_txq_free_tfd,
363 .txq_init = iwl_hw_tx_queue_init,
364 .rx_handler_setup = iwlagn_bt_rx_handler_setup,
365 .setup_deferred_work = iwlagn_bt_setup_deferred_work,
366 .cancel_deferred_work = iwlagn_bt_cancel_deferred_work,
367 .is_valid_rtc_data_addr = iwlagn_hw_valid_rtc_data_addr,
368 .load_ucode = iwlagn_load_ucode,
369 .dump_nic_event_log = iwl_dump_nic_event_log,
370 .dump_nic_error_log = iwl_dump_nic_error_log,
371 .dump_csr = iwl_dump_csr,
372 .dump_fh = iwl_dump_fh,
373 .init_alive_start = iwlagn_init_alive_start,
374 .alive_notify = iwlagn_alive_notify,
375 .send_tx_power = iwlagn_send_tx_power,
376 .update_chain_flags = iwl_update_chain_flags,
377 .set_channel_switch = iwl6000_hw_channel_switch,
379 .init = iwl_apm_init,
380 .config = iwl6000_nic_config,
383 .regulatory_bands = {
384 EEPROM_REG_BAND_1_CHANNELS,
385 EEPROM_REG_BAND_2_CHANNELS,
386 EEPROM_REG_BAND_3_CHANNELS,
387 EEPROM_REG_BAND_4_CHANNELS,
388 EEPROM_REG_BAND_5_CHANNELS,
389 EEPROM_6000_REG_BAND_24_HT40_CHANNELS,
390 EEPROM_REG_BAND_52_HT40_CHANNELS
392 .acquire_semaphore = iwlcore_eeprom_acquire_semaphore,
393 .release_semaphore = iwlcore_eeprom_release_semaphore,
394 .calib_version = iwlagn_eeprom_calib_version,
395 .query_addr = iwlagn_eeprom_query_addr,
396 .update_enhanced_txpower = iwlcore_eeprom_enhanced_txpower,
400 .temperature = iwlagn_temperature,
403 .rx_stats_read = iwl_ucode_rx_stats_read,
404 .tx_stats_read = iwl_ucode_tx_stats_read,
405 .general_stats_read = iwl_ucode_general_stats_read,
406 .bt_stats_read = iwl_ucode_bt_stats_read,
407 .reply_tx_error = iwl_reply_tx_error_read,
409 .recover_from_tx_stall = iwl_bg_monitor_recover,
410 .check_plcp_health = iwl_good_plcp_health,
411 .check_ack_health = iwl_good_ack_health,
412 .txfifo_flush = iwlagn_txfifo_flush,
413 .dev_txfifo_flush = iwlagn_dev_txfifo_flush,
415 .lower_power_detection = iwl_tt_is_low_power_state,
416 .tt_power_mode = iwl_tt_current_power_mode,
417 .ct_kill_check = iwl_check_for_ct_kill,
421 static struct iwl_nic_ops iwl6050_nic_ops = {
422 .additional_nic_config = &iwl6050_additional_nic_config,
425 static struct iwl_nic_ops iwl6050g2_nic_ops = {
426 .additional_nic_config = &iwl6050g2_additional_nic_config,
429 static const struct iwl_ops iwl6000_ops = {
431 .hcmd = &iwlagn_hcmd,
432 .utils = &iwlagn_hcmd_utils,
433 .led = &iwlagn_led_ops,
434 .ieee80211_ops = &iwlagn_hw_ops,
437 static const struct iwl_ops iwl6050_ops = {
439 .hcmd = &iwlagn_hcmd,
440 .utils = &iwlagn_hcmd_utils,
441 .led = &iwlagn_led_ops,
442 .nic = &iwl6050_nic_ops,
443 .ieee80211_ops = &iwlagn_hw_ops,
446 static const struct iwl_ops iwl6050g2_ops = {
448 .hcmd = &iwlagn_hcmd,
449 .utils = &iwlagn_hcmd_utils,
450 .led = &iwlagn_led_ops,
451 .nic = &iwl6050g2_nic_ops,
452 .ieee80211_ops = &iwlagn_hw_ops,
455 static const struct iwl_ops iwl6000g2b_ops = {
456 .lib = &iwl6000g2b_lib,
457 .hcmd = &iwlagn_bt_hcmd,
458 .utils = &iwlagn_hcmd_utils,
459 .led = &iwlagn_led_ops,
460 .ieee80211_ops = &iwlagn_hw_ops,
463 static struct iwl_base_params iwl6000_base_params = {
464 .eeprom_size = OTP_LOW_IMAGE_SIZE,
465 .num_of_queues = IWLAGN_NUM_QUEUES,
466 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
470 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
471 .shadow_ram_support = true,
472 .led_compensation = 51,
473 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
474 .supports_idle = true,
475 .adv_thermal_throttle = true,
476 .support_ct_kill_exit = true,
477 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
478 .chain_noise_scale = 1000,
479 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
480 .max_event_log_size = 512,
481 .ucode_tracing = true,
482 .sensitivity_calib_by_driver = true,
483 .chain_noise_calib_by_driver = true,
486 static struct iwl_base_params iwl6050_base_params = {
487 .eeprom_size = OTP_LOW_IMAGE_SIZE,
488 .num_of_queues = IWLAGN_NUM_QUEUES,
489 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
493 .max_ll_items = OTP_MAX_LL_ITEMS_6x50,
494 .shadow_ram_support = true,
495 .led_compensation = 51,
496 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
497 .supports_idle = true,
498 .adv_thermal_throttle = true,
499 .support_ct_kill_exit = true,
500 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
501 .chain_noise_scale = 1500,
502 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
503 .max_event_log_size = 1024,
504 .ucode_tracing = true,
505 .sensitivity_calib_by_driver = true,
506 .chain_noise_calib_by_driver = true,
508 static struct iwl_base_params iwl6000_coex_base_params = {
509 .eeprom_size = OTP_LOW_IMAGE_SIZE,
510 .num_of_queues = IWLAGN_NUM_QUEUES,
511 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
515 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
516 .shadow_ram_support = true,
517 .led_compensation = 51,
518 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
519 .supports_idle = true,
520 .adv_thermal_throttle = true,
521 .support_ct_kill_exit = true,
522 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
523 .chain_noise_scale = 1000,
524 .monitor_recover_period = IWL_LONG_MONITORING_PERIOD,
525 .max_event_log_size = 512,
526 .ucode_tracing = true,
527 .sensitivity_calib_by_driver = true,
528 .chain_noise_calib_by_driver = true,
531 static struct iwl_ht_params iwl6000_ht_params = {
532 .ht_greenfield_support = true,
533 .use_rts_for_aggregation = true, /* use rts/cts protection */
536 static struct iwl_bt_params iwl6000_bt_params = {
537 .bt_statistics = true,
538 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
539 .advanced_bt_coexist = true,
540 .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
541 .bt_prio_boost = IWLAGN_BT_PRIO_BOOST_DEFAULT,
544 struct iwl_cfg iwl6000g2a_2agn_cfg = {
545 .name = "6000 Series 2x2 AGN Gen2a",
546 .fw_name_pre = IWL6000G2A_FW_PRE,
547 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
548 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
549 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
550 .valid_tx_ant = ANT_AB,
551 .valid_rx_ant = ANT_AB,
552 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
553 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
555 .mod_params = &iwlagn_mod_params,
556 .base_params = &iwl6000_base_params,
557 .ht_params = &iwl6000_ht_params,
558 .need_dc_calib = true,
559 .need_temp_offset_calib = true,
562 struct iwl_cfg iwl6000g2a_2abg_cfg = {
563 .name = "6000 Series 2x2 ABG Gen2a",
564 .fw_name_pre = IWL6000G2A_FW_PRE,
565 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
566 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
567 .sku = IWL_SKU_A|IWL_SKU_G,
568 .valid_tx_ant = ANT_AB,
569 .valid_rx_ant = ANT_AB,
570 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
571 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
573 .mod_params = &iwlagn_mod_params,
574 .base_params = &iwl6000_base_params,
575 .need_dc_calib = true,
576 .need_temp_offset_calib = true,
579 struct iwl_cfg iwl6000g2a_2bg_cfg = {
580 .name = "6000 Series 2x2 BG Gen2a",
581 .fw_name_pre = IWL6000G2A_FW_PRE,
582 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
583 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
585 .valid_tx_ant = ANT_AB,
586 .valid_rx_ant = ANT_AB,
587 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
588 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
590 .mod_params = &iwlagn_mod_params,
591 .base_params = &iwl6000_base_params,
592 .need_dc_calib = true,
593 .need_temp_offset_calib = true,
596 struct iwl_cfg iwl6000g2b_2agn_cfg = {
597 .name = "6000 Series 2x2 AGN Gen2b",
598 .fw_name_pre = IWL6000G2B_FW_PRE,
599 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
600 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
601 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
602 .valid_tx_ant = ANT_AB,
603 .valid_rx_ant = ANT_AB,
604 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
605 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
606 .ops = &iwl6000g2b_ops,
607 .mod_params = &iwlagn_mod_params,
608 .base_params = &iwl6000_coex_base_params,
609 .bt_params = &iwl6000_bt_params,
610 .ht_params = &iwl6000_ht_params,
611 .need_dc_calib = true,
612 .need_temp_offset_calib = true,
613 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
614 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
617 struct iwl_cfg iwl6000g2b_2abg_cfg = {
618 .name = "6000 Series 2x2 ABG Gen2b",
619 .fw_name_pre = IWL6000G2B_FW_PRE,
620 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
621 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
622 .sku = IWL_SKU_A|IWL_SKU_G,
623 .valid_tx_ant = ANT_AB,
624 .valid_rx_ant = ANT_AB,
625 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
626 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
627 .ops = &iwl6000g2b_ops,
628 .mod_params = &iwlagn_mod_params,
629 .base_params = &iwl6000_coex_base_params,
630 .bt_params = &iwl6000_bt_params,
631 .need_dc_calib = true,
632 .need_temp_offset_calib = true,
633 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
634 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
637 struct iwl_cfg iwl6000g2b_2bgn_cfg = {
638 .name = "6000 Series 2x2 BGN Gen2b",
639 .fw_name_pre = IWL6000G2B_FW_PRE,
640 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
641 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
642 .sku = IWL_SKU_G|IWL_SKU_N,
643 .valid_tx_ant = ANT_AB,
644 .valid_rx_ant = ANT_AB,
645 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
646 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
647 .ops = &iwl6000g2b_ops,
648 .mod_params = &iwlagn_mod_params,
649 .base_params = &iwl6000_coex_base_params,
650 .bt_params = &iwl6000_bt_params,
651 .ht_params = &iwl6000_ht_params,
652 .need_dc_calib = true,
653 .need_temp_offset_calib = true,
654 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
655 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
658 struct iwl_cfg iwl6000g2b_2bg_cfg = {
659 .name = "6000 Series 2x2 BG Gen2b",
660 .fw_name_pre = IWL6000G2B_FW_PRE,
661 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
662 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
664 .valid_tx_ant = ANT_AB,
665 .valid_rx_ant = ANT_AB,
666 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
667 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
668 .ops = &iwl6000g2b_ops,
669 .mod_params = &iwlagn_mod_params,
670 .base_params = &iwl6000_coex_base_params,
671 .bt_params = &iwl6000_bt_params,
672 .need_dc_calib = true,
673 .need_temp_offset_calib = true,
674 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
675 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
678 struct iwl_cfg iwl6000g2b_bgn_cfg = {
679 .name = "6000 Series 1x2 BGN Gen2b",
680 .fw_name_pre = IWL6000G2B_FW_PRE,
681 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
682 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
683 .sku = IWL_SKU_G|IWL_SKU_N,
684 .valid_tx_ant = ANT_A,
685 .valid_rx_ant = ANT_AB,
686 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
687 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
688 .ops = &iwl6000g2b_ops,
689 .mod_params = &iwlagn_mod_params,
690 .base_params = &iwl6000_coex_base_params,
691 .bt_params = &iwl6000_bt_params,
692 .ht_params = &iwl6000_ht_params,
693 .need_dc_calib = true,
694 .need_temp_offset_calib = true,
695 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
696 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
699 struct iwl_cfg iwl6000g2b_bg_cfg = {
700 .name = "6000 Series 1x2 BG Gen2b",
701 .fw_name_pre = IWL6000G2B_FW_PRE,
702 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
703 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
705 .valid_tx_ant = ANT_A,
706 .valid_rx_ant = ANT_AB,
707 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
708 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
709 .ops = &iwl6000g2b_ops,
710 .mod_params = &iwlagn_mod_params,
711 .base_params = &iwl6000_coex_base_params,
712 .bt_params = &iwl6000_bt_params,
713 .need_dc_calib = true,
714 .need_temp_offset_calib = true,
715 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
716 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
720 * "i": Internal configuration, use internal Power Amplifier
722 struct iwl_cfg iwl6000i_2agn_cfg = {
723 .name = "Intel(R) Centrino(R) Advanced-N 6200 AGN",
724 .fw_name_pre = IWL6000_FW_PRE,
725 .ucode_api_max = IWL6000_UCODE_API_MAX,
726 .ucode_api_min = IWL6000_UCODE_API_MIN,
727 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
728 .valid_tx_ant = ANT_BC,
729 .valid_rx_ant = ANT_BC,
730 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
731 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
733 .mod_params = &iwlagn_mod_params,
734 .base_params = &iwl6000_base_params,
735 .ht_params = &iwl6000_ht_params,
736 .pa_type = IWL_PA_INTERNAL,
739 struct iwl_cfg iwl6000i_2abg_cfg = {
740 .name = "Intel(R) Centrino(R) Advanced-N 6200 ABG",
741 .fw_name_pre = IWL6000_FW_PRE,
742 .ucode_api_max = IWL6000_UCODE_API_MAX,
743 .ucode_api_min = IWL6000_UCODE_API_MIN,
744 .sku = IWL_SKU_A|IWL_SKU_G,
745 .valid_tx_ant = ANT_BC,
746 .valid_rx_ant = ANT_BC,
747 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
748 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
750 .mod_params = &iwlagn_mod_params,
751 .base_params = &iwl6000_base_params,
752 .pa_type = IWL_PA_INTERNAL,
755 struct iwl_cfg iwl6000i_2bg_cfg = {
756 .name = "Intel(R) Centrino(R) Advanced-N 6200 BG",
757 .fw_name_pre = IWL6000_FW_PRE,
758 .ucode_api_max = IWL6000_UCODE_API_MAX,
759 .ucode_api_min = IWL6000_UCODE_API_MIN,
761 .valid_tx_ant = ANT_BC,
762 .valid_rx_ant = ANT_BC,
763 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
764 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
766 .mod_params = &iwlagn_mod_params,
767 .base_params = &iwl6000_base_params,
768 .pa_type = IWL_PA_INTERNAL,
771 struct iwl_cfg iwl6050_2agn_cfg = {
772 .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 AGN",
773 .fw_name_pre = IWL6050_FW_PRE,
774 .ucode_api_max = IWL6050_UCODE_API_MAX,
775 .ucode_api_min = IWL6050_UCODE_API_MIN,
776 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
777 .valid_tx_ant = ANT_AB,
778 .valid_rx_ant = ANT_AB,
780 .eeprom_ver = EEPROM_6050_EEPROM_VERSION,
781 .eeprom_calib_ver = EEPROM_6050_TX_POWER_VERSION,
782 .mod_params = &iwlagn_mod_params,
783 .base_params = &iwl6050_base_params,
784 .ht_params = &iwl6000_ht_params,
785 .need_dc_calib = true,
788 struct iwl_cfg iwl6050g2_bgn_cfg = {
789 .name = "6050 Series 1x2 BGN Gen2",
790 .fw_name_pre = IWL6050_FW_PRE,
791 .ucode_api_max = IWL6050_UCODE_API_MAX,
792 .ucode_api_min = IWL6050_UCODE_API_MIN,
793 .sku = IWL_SKU_G|IWL_SKU_N,
794 .valid_tx_ant = ANT_A,
795 .valid_rx_ant = ANT_AB,
796 .eeprom_ver = EEPROM_6050G2_EEPROM_VERSION,
797 .eeprom_calib_ver = EEPROM_6050G2_TX_POWER_VERSION,
798 .ops = &iwl6050g2_ops,
799 .mod_params = &iwlagn_mod_params,
800 .base_params = &iwl6050_base_params,
801 .ht_params = &iwl6000_ht_params,
802 .need_dc_calib = true,
805 struct iwl_cfg iwl6050_2abg_cfg = {
806 .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 ABG",
807 .fw_name_pre = IWL6050_FW_PRE,
808 .ucode_api_max = IWL6050_UCODE_API_MAX,
809 .ucode_api_min = IWL6050_UCODE_API_MIN,
810 .sku = IWL_SKU_A|IWL_SKU_G,
811 .valid_tx_ant = ANT_AB,
812 .valid_rx_ant = ANT_AB,
813 .eeprom_ver = EEPROM_6050_EEPROM_VERSION,
814 .eeprom_calib_ver = EEPROM_6050_TX_POWER_VERSION,
816 .mod_params = &iwlagn_mod_params,
817 .base_params = &iwl6050_base_params,
818 .need_dc_calib = true,
821 struct iwl_cfg iwl6000_3agn_cfg = {
822 .name = "Intel(R) Centrino(R) Ultimate-N 6300 AGN",
823 .fw_name_pre = IWL6000_FW_PRE,
824 .ucode_api_max = IWL6000_UCODE_API_MAX,
825 .ucode_api_min = IWL6000_UCODE_API_MIN,
826 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
827 .valid_tx_ant = ANT_ABC,
828 .valid_rx_ant = ANT_ABC,
829 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
830 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
832 .mod_params = &iwlagn_mod_params,
833 .base_params = &iwl6000_base_params,
834 .ht_params = &iwl6000_ht_params,
835 .need_dc_calib = true,
838 struct iwl_cfg iwl130_bgn_cfg = {
839 .name = "Intel(R) 130 Series 1x1 BGN",
840 .fw_name_pre = IWL6000G2B_FW_PRE,
841 .ucode_api_max = IWL130_UCODE_API_MAX,
842 .ucode_api_min = IWL130_UCODE_API_MIN,
843 .sku = IWL_SKU_G|IWL_SKU_N,
844 .valid_tx_ant = ANT_A,
845 .valid_rx_ant = ANT_A,
846 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
847 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
848 .ops = &iwl6000g2b_ops,
849 .mod_params = &iwlagn_mod_params,
850 .base_params = &iwl6000_coex_base_params,
851 .bt_params = &iwl6000_bt_params,
852 .ht_params = &iwl6000_ht_params,
853 .need_dc_calib = true,
854 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
855 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
858 struct iwl_cfg iwl130_bg_cfg = {
859 .name = "Intel(R) 130 Series 1x2 BG",
860 .fw_name_pre = IWL6000G2B_FW_PRE,
861 .ucode_api_max = IWL130_UCODE_API_MAX,
862 .ucode_api_min = IWL130_UCODE_API_MIN,
864 .valid_tx_ant = ANT_A,
865 .valid_rx_ant = ANT_A,
866 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
867 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
868 .ops = &iwl6000g2b_ops,
869 .mod_params = &iwlagn_mod_params,
870 .base_params = &iwl6000_coex_base_params,
871 .bt_params = &iwl6000_bt_params,
872 .need_dc_calib = true,
873 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
874 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
877 MODULE_FIRMWARE(IWL6000_MODULE_FIRMWARE(IWL6000_UCODE_API_MAX));
878 MODULE_FIRMWARE(IWL6050_MODULE_FIRMWARE(IWL6050_UCODE_API_MAX));
879 MODULE_FIRMWARE(IWL6000G2A_MODULE_FIRMWARE(IWL6000G2_UCODE_API_MAX));
880 MODULE_FIRMWARE(IWL6000G2B_MODULE_FIRMWARE(IWL6000G2_UCODE_API_MAX));
881 MODULE_FIRMWARE(IWL130_MODULE_FIRMWARE(IWL130_UCODE_API_MAX));