30dc1f3342022a242f8010dd2463487ffeb3006b
[deliverable/linux.git] / drivers / net / wireless / iwlwifi / iwl-6000.c
1 /******************************************************************************
2 *
3 * Copyright(c) 2008 - 2010 Intel Corporation. All rights reserved.
4 *
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.
8 *
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
12 * more details.
13 *
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
17 *
18 * The full GNU General Public License is included in this distribution in the
19 * file called LICENSE.
20 *
21 * Contact Information:
22 * Intel Linux Wireless <ilw@linux.intel.com>
23 * Intel Corporation, 5200 N.E. Elam Young Parkway, Hillsboro, OR 97124-6497
24 *
25 *****************************************************************************/
26
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>
39
40 #include "iwl-eeprom.h"
41 #include "iwl-dev.h"
42 #include "iwl-core.h"
43 #include "iwl-io.h"
44 #include "iwl-sta.h"
45 #include "iwl-agn.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"
51
52 /* Highest firmware API version supported */
53 #define IWL6000_UCODE_API_MAX 4
54 #define IWL6050_UCODE_API_MAX 4
55 #define IWL6000G2_UCODE_API_MAX 5
56
57 /* Lowest firmware API version supported */
58 #define IWL6000_UCODE_API_MIN 4
59 #define IWL6050_UCODE_API_MIN 4
60 #define IWL6000G2_UCODE_API_MIN 4
61
62 #define IWL6000_FW_PRE "iwlwifi-6000-"
63 #define _IWL6000_MODULE_FIRMWARE(api) IWL6000_FW_PRE #api ".ucode"
64 #define IWL6000_MODULE_FIRMWARE(api) _IWL6000_MODULE_FIRMWARE(api)
65
66 #define IWL6050_FW_PRE "iwlwifi-6050-"
67 #define _IWL6050_MODULE_FIRMWARE(api) IWL6050_FW_PRE #api ".ucode"
68 #define IWL6050_MODULE_FIRMWARE(api) _IWL6050_MODULE_FIRMWARE(api)
69
70 #define IWL6000G2A_FW_PRE "iwlwifi-6000g2a-"
71 #define _IWL6000G2A_MODULE_FIRMWARE(api) IWL6000G2A_FW_PRE #api ".ucode"
72 #define IWL6000G2A_MODULE_FIRMWARE(api) _IWL6000G2A_MODULE_FIRMWARE(api)
73
74 #define IWL6000G2B_FW_PRE "iwlwifi-6000g2b-"
75 #define _IWL6000G2B_MODULE_FIRMWARE(api) IWL6000G2B_FW_PRE #api ".ucode"
76 #define IWL6000G2B_MODULE_FIRMWARE(api) _IWL6000G2B_MODULE_FIRMWARE(api)
77
78
79 static void iwl6000_set_ct_threshold(struct iwl_priv *priv)
80 {
81 /* want Celsius */
82 priv->hw_params.ct_kill_threshold = CT_KILL_THRESHOLD;
83 priv->hw_params.ct_kill_exit_threshold = CT_KILL_EXIT_THRESHOLD;
84 }
85
86 /* Indicate calibration version to uCode. */
87 static void iwl6000_set_calib_version(struct iwl_priv *priv)
88 {
89 if (priv->cfg->need_dc_calib &&
90 (priv->cfg->ops->lib->eeprom_ops.calib_version(priv) >= 6))
91 iwl_set_bit(priv, CSR_GP_DRIVER_REG,
92 CSR_GP_DRIVER_REG_BIT_CALIB_VERSION6);
93 }
94
95 /* NIC configuration for 6000 series */
96 static void iwl6000_nic_config(struct iwl_priv *priv)
97 {
98 u16 radio_cfg;
99
100 radio_cfg = iwl_eeprom_query16(priv, EEPROM_RADIO_CONFIG);
101
102 /* write radio config values to register */
103 if (EEPROM_RF_CFG_TYPE_MSK(radio_cfg) <= EEPROM_RF_CONFIG_TYPE_MAX)
104 iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG,
105 EEPROM_RF_CFG_TYPE_MSK(radio_cfg) |
106 EEPROM_RF_CFG_STEP_MSK(radio_cfg) |
107 EEPROM_RF_CFG_DASH_MSK(radio_cfg));
108
109 /* set CSR_HW_CONFIG_REG for uCode use */
110 iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG,
111 CSR_HW_IF_CONFIG_REG_BIT_RADIO_SI |
112 CSR_HW_IF_CONFIG_REG_BIT_MAC_SI);
113
114 /* no locking required for register write */
115 if (priv->cfg->pa_type == IWL_PA_INTERNAL) {
116 /* 2x2 IPA phy type */
117 iwl_write32(priv, CSR_GP_DRIVER_REG,
118 CSR_GP_DRIVER_REG_BIT_RADIO_SKU_2x2_IPA);
119 }
120 /* else do nothing, uCode configured */
121 if (priv->cfg->ops->lib->temp_ops.set_calib_version)
122 priv->cfg->ops->lib->temp_ops.set_calib_version(priv);
123 }
124
125 /*
126 * Macros to access the lookup table.
127 *
128 * The lookup table has 7 inputs: bt3_prio, bt3_txrx, bt_rf_act, wifi_req,
129 * wifi_prio, wifi_txrx and wifi_sh_ant_req.
130 *
131 * It has three outputs: WLAN_ACTIVE, WLAN_KILL and ANT_SWITCH
132 *
133 * The format is that "registers" 8 through 11 contain the WLAN_ACTIVE bits
134 * one after another in 32-bit registers, and "registers" 0 through 7 contain
135 * the WLAN_KILL and ANT_SWITCH bits interleaved (in that order).
136 *
137 * These macros encode that format.
138 */
139 #define LUT_VALUE(bt3_prio, bt3_txrx, bt_rf_act, wifi_req, wifi_prio, \
140 wifi_txrx, wifi_sh_ant_req) \
141 (bt3_prio | (bt3_txrx << 1) | (bt_rf_act << 2) | (wifi_req << 3) | \
142 (wifi_prio << 4) | (wifi_txrx << 5) | (wifi_sh_ant_req << 6))
143
144 #define LUT_PTA_WLAN_ACTIVE_OP(lut, op, val) \
145 lut[8 + ((val) >> 5)] op (cpu_to_le32(BIT((val) & 0x1f)))
146 #define LUT_TEST_PTA_WLAN_ACTIVE(lut, bt3_prio, bt3_txrx, bt_rf_act, \
147 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req) \
148 (!!(LUT_PTA_WLAN_ACTIVE_OP(lut, &, LUT_VALUE(bt3_prio, bt3_txrx,\
149 bt_rf_act, wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))))
150 #define LUT_SET_PTA_WLAN_ACTIVE(lut, bt3_prio, bt3_txrx, bt_rf_act, \
151 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req) \
152 LUT_PTA_WLAN_ACTIVE_OP(lut, |=, LUT_VALUE(bt3_prio, bt3_txrx, \
153 bt_rf_act, wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))
154 #define LUT_CLEAR_PTA_WLAN_ACTIVE(lut, bt3_prio, bt3_txrx, bt_rf_act, \
155 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req) \
156 LUT_PTA_WLAN_ACTIVE_OP(lut, &= ~, LUT_VALUE(bt3_prio, bt3_txrx, \
157 bt_rf_act, wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))
158
159 #define LUT_WLAN_KILL_OP(lut, op, val) \
160 lut[(val) >> 4] op (cpu_to_le32(BIT(((val) << 1) & 0x1e)))
161 #define LUT_TEST_WLAN_KILL(lut, bt3_prio, bt3_txrx, bt_rf_act, wifi_req, \
162 wifi_prio, wifi_txrx, wifi_sh_ant_req) \
163 (!!(LUT_WLAN_KILL_OP(lut, &, LUT_VALUE(bt3_prio, bt3_txrx, bt_rf_act, \
164 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))))
165 #define LUT_SET_WLAN_KILL(lut, bt3_prio, bt3_txrx, bt_rf_act, wifi_req, \
166 wifi_prio, wifi_txrx, wifi_sh_ant_req) \
167 LUT_WLAN_KILL_OP(lut, |=, LUT_VALUE(bt3_prio, bt3_txrx, bt_rf_act, \
168 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))
169 #define LUT_CLEAR_WLAN_KILL(lut, bt3_prio, bt3_txrx, bt_rf_act, wifi_req, \
170 wifi_prio, wifi_txrx, wifi_sh_ant_req) \
171 LUT_WLAN_KILL_OP(lut, &= ~, LUT_VALUE(bt3_prio, bt3_txrx, bt_rf_act, \
172 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))
173
174 #define LUT_ANT_SWITCH_OP(lut, op, val) \
175 lut[(val) >> 4] op (cpu_to_le32(BIT((((val) << 1) & 0x1e) + 1)))
176 #define LUT_TEST_ANT_SWITCH(lut, bt3_prio, bt3_txrx, bt_rf_act, wifi_req, \
177 wifi_prio, wifi_txrx, wifi_sh_ant_req) \
178 (!!(LUT_ANT_SWITCH_OP(lut, &, LUT_VALUE(bt3_prio, bt3_txrx, bt_rf_act, \
179 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))))
180 #define LUT_SET_ANT_SWITCH(lut, bt3_prio, bt3_txrx, bt_rf_act, wifi_req, \
181 wifi_prio, wifi_txrx, wifi_sh_ant_req) \
182 LUT_ANT_SWITCH_OP(lut, |=, LUT_VALUE(bt3_prio, bt3_txrx, bt_rf_act, \
183 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))
184 #define LUT_CLEAR_ANT_SWITCH(lut, bt3_prio, bt3_txrx, bt_rf_act, wifi_req, \
185 wifi_prio, wifi_txrx, wifi_sh_ant_req) \
186 LUT_ANT_SWITCH_OP(lut, &= ~, LUT_VALUE(bt3_prio, bt3_txrx, bt_rf_act, \
187 wifi_req, wifi_prio, wifi_txrx, wifi_sh_ant_req))
188
189 static const __le32 iwl6000g2b_def_3w_lookup[12] = {
190 cpu_to_le32(0xaaaaaaaa),
191 cpu_to_le32(0xaaaaaaaa),
192 cpu_to_le32(0xaeaaaaaa),
193 cpu_to_le32(0xaaaaaaaa),
194 cpu_to_le32(0xcc00ff28),
195 cpu_to_le32(0x0000aaaa),
196 cpu_to_le32(0xcc00aaaa),
197 cpu_to_le32(0x0000aaaa),
198 cpu_to_le32(0xc0004000),
199 cpu_to_le32(0x00004000),
200 cpu_to_le32(0xf0005000),
201 cpu_to_le32(0xf0004000),
202 };
203
204 static const __le32 iwl6000g2b_concurrent_lookup[12] = {
205 cpu_to_le32(0xaaaaaaaa),
206 cpu_to_le32(0xaaaaaaaa),
207 cpu_to_le32(0xaaaaaaaa),
208 cpu_to_le32(0xaaaaaaaa),
209 cpu_to_le32(0xaaaaaaaa),
210 cpu_to_le32(0xaaaaaaaa),
211 cpu_to_le32(0xaaaaaaaa),
212 cpu_to_le32(0xaaaaaaaa),
213 cpu_to_le32(0x00000000),
214 cpu_to_le32(0x00000000),
215 cpu_to_le32(0x00000000),
216 cpu_to_le32(0x00000000),
217 };
218
219 static void iwl6000g2b_send_bt_config(struct iwl_priv *priv)
220 {
221 struct iwl6000g2b_bt_cmd bt_cmd = {
222 .max_kill = IWL6000G2B_BT_MAX_KILL_DEFAULT,
223 .bt3_timer_t7_value = IWL6000G2B_BT3_T7_DEFAULT,
224 .bt3_prio_sample_time = IWL6000G2B_BT3_PRIO_SAMPLE_DEFAULT,
225 .bt3_timer_t2_value = IWL6000G2B_BT3_T2_DEFAULT,
226 };
227
228 BUILD_BUG_ON(sizeof(iwl6000g2b_def_3w_lookup) !=
229 sizeof(bt_cmd.bt3_lookup_table));
230
231 bt_cmd.prio_boost = priv->cfg->bt_prio_boost;
232 bt_cmd.kill_ack_mask = priv->kill_ack_mask;
233 bt_cmd.kill_cts_mask = priv->kill_cts_mask;
234 bt_cmd.valid = priv->bt_valid;
235
236 /*
237 * Configure BT coex mode to "no coexistence" when the
238 * user disabled BT coexistence, we have no interface
239 * user disabled BT coexistence, or the interface is in
240 * IBSS mode (no proper uCode support for coex then).
241 */
242 if (!bt_coex_active || priv->iw_mode == NL80211_IFTYPE_ADHOC) {
243 bt_cmd.flags = 0;
244 } else {
245 bt_cmd.flags = IWL6000G2B_BT_FLAG_COEX_MODE_3W <<
246 IWL6000G2B_BT_FLAG_COEX_MODE_SHIFT;
247 if (priv->bt_ch_announce)
248 bt_cmd.flags |= IWL6000G2B_BT_FLAG_CHANNEL_INHIBITION;
249 IWL_DEBUG_INFO(priv, "BT coex flag: 0X%x\n", bt_cmd.flags);
250 }
251
252 if (priv->bt_full_concurrent)
253 memcpy(bt_cmd.bt3_lookup_table, iwl6000g2b_concurrent_lookup,
254 sizeof(iwl6000g2b_concurrent_lookup));
255 else
256 memcpy(bt_cmd.bt3_lookup_table, iwl6000g2b_def_3w_lookup,
257 sizeof(iwl6000g2b_def_3w_lookup));
258
259 IWL_DEBUG_INFO(priv, "BT coex %s in %s mode\n",
260 bt_cmd.flags ? "active" : "disabled",
261 priv->bt_full_concurrent ?
262 "full concurrency" : "3-wire");
263
264 if (iwl_send_cmd_pdu(priv, REPLY_BT_CONFIG, sizeof(bt_cmd), &bt_cmd))
265 IWL_ERR(priv, "failed to send BT Coex Config\n");
266
267 /*
268 * When we are doing a restart, need to also reconfigure BT
269 * SCO to the device. If not doing a restart, bt_sco_active
270 * will always be false, so there's no need to have an extra
271 * variable to check for it.
272 */
273 if (priv->bt_sco_active) {
274 struct iwl6000g2b_bt_sco_cmd sco_cmd = { .flags = 0 };
275
276 if (priv->bt_sco_active)
277 sco_cmd.flags |= IWL6000G2B_BT_SCO_ACTIVE;
278 if (iwl_send_cmd_pdu(priv, REPLY_BT_COEX_SCO,
279 sizeof(sco_cmd), &sco_cmd))
280 IWL_ERR(priv, "failed to send BT SCO command\n");
281 }
282 }
283
284 static struct iwl_sensitivity_ranges iwl6000_sensitivity = {
285 .min_nrg_cck = 97,
286 .max_nrg_cck = 0, /* not used, set to 0 */
287 .auto_corr_min_ofdm = 80,
288 .auto_corr_min_ofdm_mrc = 128,
289 .auto_corr_min_ofdm_x1 = 105,
290 .auto_corr_min_ofdm_mrc_x1 = 192,
291
292 .auto_corr_max_ofdm = 145,
293 .auto_corr_max_ofdm_mrc = 232,
294 .auto_corr_max_ofdm_x1 = 110,
295 .auto_corr_max_ofdm_mrc_x1 = 232,
296
297 .auto_corr_min_cck = 125,
298 .auto_corr_max_cck = 175,
299 .auto_corr_min_cck_mrc = 160,
300 .auto_corr_max_cck_mrc = 310,
301 .nrg_th_cck = 97,
302 .nrg_th_ofdm = 100,
303
304 .barker_corr_th_min = 190,
305 .barker_corr_th_min_mrc = 390,
306 .nrg_th_cca = 62,
307 };
308
309 static int iwl6000_hw_set_hw_params(struct iwl_priv *priv)
310 {
311 if (priv->cfg->mod_params->num_of_queues >= IWL_MIN_NUM_QUEUES &&
312 priv->cfg->mod_params->num_of_queues <= IWLAGN_NUM_QUEUES)
313 priv->cfg->num_of_queues =
314 priv->cfg->mod_params->num_of_queues;
315
316 priv->hw_params.max_txq_num = priv->cfg->num_of_queues;
317 priv->hw_params.dma_chnl_num = FH50_TCSR_CHNL_NUM;
318 priv->hw_params.scd_bc_tbls_size =
319 priv->cfg->num_of_queues *
320 sizeof(struct iwlagn_scd_bc_tbl);
321 priv->hw_params.tfd_size = sizeof(struct iwl_tfd);
322 priv->hw_params.max_stations = IWLAGN_STATION_COUNT;
323 priv->hw_params.bcast_sta_id = IWLAGN_BROADCAST_ID;
324
325 priv->hw_params.max_data_size = IWL60_RTC_DATA_SIZE;
326 priv->hw_params.max_inst_size = IWL60_RTC_INST_SIZE;
327
328 priv->hw_params.max_bsm_size = 0;
329 priv->hw_params.ht40_channel = BIT(IEEE80211_BAND_2GHZ) |
330 BIT(IEEE80211_BAND_5GHZ);
331 priv->hw_params.rx_wrt_ptr_reg = FH_RSCSR_CHNL0_WPTR;
332
333 priv->hw_params.tx_chains_num = num_of_ant(priv->cfg->valid_tx_ant);
334 priv->hw_params.rx_chains_num = num_of_ant(priv->cfg->valid_rx_ant);
335 priv->hw_params.valid_tx_ant = priv->cfg->valid_tx_ant;
336 priv->hw_params.valid_rx_ant = priv->cfg->valid_rx_ant;
337
338 if (priv->cfg->ops->lib->temp_ops.set_ct_kill)
339 priv->cfg->ops->lib->temp_ops.set_ct_kill(priv);
340
341 /* Set initial sensitivity parameters */
342 /* Set initial calibration set */
343 priv->hw_params.sens = &iwl6000_sensitivity;
344 priv->hw_params.calib_init_cfg =
345 BIT(IWL_CALIB_XTAL) |
346 BIT(IWL_CALIB_LO) |
347 BIT(IWL_CALIB_TX_IQ) |
348 BIT(IWL_CALIB_BASE_BAND);
349 if (priv->cfg->need_dc_calib)
350 priv->hw_params.calib_init_cfg |= BIT(IWL_CALIB_DC);
351
352 priv->hw_params.beacon_time_tsf_bits = IWLAGN_EXT_BEACON_TIME_POS;
353
354 return 0;
355 }
356
357 static int iwl6000_hw_channel_switch(struct iwl_priv *priv,
358 struct ieee80211_channel_switch *ch_switch)
359 {
360 struct iwl6000_channel_switch_cmd cmd;
361 const struct iwl_channel_info *ch_info;
362 u32 switch_time_in_usec, ucode_switch_time;
363 u16 ch;
364 u32 tsf_low;
365 u8 switch_count;
366 u16 beacon_interval = le16_to_cpu(priv->rxon_timing.beacon_interval);
367 struct ieee80211_vif *vif = priv->vif;
368 struct iwl_host_cmd hcmd = {
369 .id = REPLY_CHANNEL_SWITCH,
370 .len = sizeof(cmd),
371 .flags = CMD_SYNC,
372 .data = &cmd,
373 };
374
375 cmd.band = priv->band == IEEE80211_BAND_2GHZ;
376 ch = ch_switch->channel->hw_value;
377 IWL_DEBUG_11H(priv, "channel switch from %u to %u\n",
378 priv->active_rxon.channel, ch);
379 cmd.channel = cpu_to_le16(ch);
380 cmd.rxon_flags = priv->staging_rxon.flags;
381 cmd.rxon_filter_flags = priv->staging_rxon.filter_flags;
382 switch_count = ch_switch->count;
383 tsf_low = ch_switch->timestamp & 0x0ffffffff;
384 /*
385 * calculate the ucode channel switch time
386 * adding TSF as one of the factor for when to switch
387 */
388 if ((priv->ucode_beacon_time > tsf_low) && beacon_interval) {
389 if (switch_count > ((priv->ucode_beacon_time - tsf_low) /
390 beacon_interval)) {
391 switch_count -= (priv->ucode_beacon_time -
392 tsf_low) / beacon_interval;
393 } else
394 switch_count = 0;
395 }
396 if (switch_count <= 1)
397 cmd.switch_time = cpu_to_le32(priv->ucode_beacon_time);
398 else {
399 switch_time_in_usec =
400 vif->bss_conf.beacon_int * switch_count * TIME_UNIT;
401 ucode_switch_time = iwl_usecs_to_beacons(priv,
402 switch_time_in_usec,
403 beacon_interval);
404 cmd.switch_time = iwl_add_beacon_time(priv,
405 priv->ucode_beacon_time,
406 ucode_switch_time,
407 beacon_interval);
408 }
409 IWL_DEBUG_11H(priv, "uCode time for the switch is 0x%x\n",
410 cmd.switch_time);
411 ch_info = iwl_get_channel_info(priv, priv->band, ch);
412 if (ch_info)
413 cmd.expect_beacon = is_channel_radar(ch_info);
414 else {
415 IWL_ERR(priv, "invalid channel switch from %u to %u\n",
416 priv->active_rxon.channel, ch);
417 return -EFAULT;
418 }
419 priv->switch_rxon.channel = cmd.channel;
420 priv->switch_rxon.switch_in_progress = true;
421
422 return iwl_send_cmd_sync(priv, &hcmd);
423 }
424
425 static void iwl6000g2b_bt_traffic_change_work(struct work_struct *work)
426 {
427 struct iwl_priv *priv =
428 container_of(work, struct iwl_priv, bt_traffic_change_work);
429 int smps_request = -1;
430
431 IWL_DEBUG_INFO(priv, "BT traffic load changes: %d\n",
432 priv->bt_traffic_load);
433
434 switch (priv->bt_traffic_load) {
435 case IWL_BT_COEX_TRAFFIC_LOAD_NONE:
436 smps_request = IEEE80211_SMPS_AUTOMATIC;
437 break;
438 case IWL_BT_COEX_TRAFFIC_LOAD_LOW:
439 smps_request = IEEE80211_SMPS_DYNAMIC;
440 break;
441 case IWL_BT_COEX_TRAFFIC_LOAD_HIGH:
442 case IWL_BT_COEX_TRAFFIC_LOAD_CONTINUOUS:
443 smps_request = IEEE80211_SMPS_STATIC;
444 break;
445 default:
446 IWL_ERR(priv, "Invalid BT traffic load: %d\n",
447 priv->bt_traffic_load);
448 break;
449 }
450
451 mutex_lock(&priv->mutex);
452
453 if (priv->cfg->ops->lib->update_chain_flags)
454 priv->cfg->ops->lib->update_chain_flags(priv);
455
456 if (smps_request != -1 &&
457 priv->vif && priv->vif->type == NL80211_IFTYPE_STATION)
458 ieee80211_request_smps(priv->vif, smps_request);
459
460 mutex_unlock(&priv->mutex);
461 }
462
463 static void iwlagn_print_uartmsg(struct iwl_priv *priv,
464 struct iwl_bt_uart_msg *uart_msg)
465 {
466 IWL_DEBUG_NOTIF(priv, "Message Type = 0x%X, SSN = 0x%X, "
467 "Update Req = 0x%X",
468 (BT_UART_MSG_FRAME1MSGTYPE_MSK & uart_msg->frame1) >>
469 BT_UART_MSG_FRAME1MSGTYPE_POS,
470 (BT_UART_MSG_FRAME1SSN_MSK & uart_msg->frame1) >>
471 BT_UART_MSG_FRAME1SSN_POS,
472 (BT_UART_MSG_FRAME1UPDATEREQ_MSK & uart_msg->frame1) >>
473 BT_UART_MSG_FRAME1UPDATEREQ_POS);
474
475 IWL_DEBUG_NOTIF(priv, "Open connections = 0x%X, Traffic load = 0x%X, "
476 "Chl_SeqN = 0x%X, In band = 0x%X",
477 (BT_UART_MSG_FRAME2OPENCONNECTIONS_MSK & uart_msg->frame2) >>
478 BT_UART_MSG_FRAME2OPENCONNECTIONS_POS,
479 (BT_UART_MSG_FRAME2TRAFFICLOAD_MSK & uart_msg->frame2) >>
480 BT_UART_MSG_FRAME2TRAFFICLOAD_POS,
481 (BT_UART_MSG_FRAME2CHLSEQN_MSK & uart_msg->frame2) >>
482 BT_UART_MSG_FRAME2CHLSEQN_POS,
483 (BT_UART_MSG_FRAME2INBAND_MSK & uart_msg->frame2) >>
484 BT_UART_MSG_FRAME2INBAND_POS);
485
486 IWL_DEBUG_NOTIF(priv, "SCO/eSCO = 0x%X, Sniff = 0x%X, A2DP = 0x%X, "
487 "ACL = 0x%X, Master = 0x%X, OBEX = 0x%X",
488 (BT_UART_MSG_FRAME3SCOESCO_MSK & uart_msg->frame3) >>
489 BT_UART_MSG_FRAME3SCOESCO_POS,
490 (BT_UART_MSG_FRAME3SNIFF_MSK & uart_msg->frame3) >>
491 BT_UART_MSG_FRAME3SNIFF_POS,
492 (BT_UART_MSG_FRAME3A2DP_MSK & uart_msg->frame3) >>
493 BT_UART_MSG_FRAME3A2DP_POS,
494 (BT_UART_MSG_FRAME3ACL_MSK & uart_msg->frame3) >>
495 BT_UART_MSG_FRAME3ACL_POS,
496 (BT_UART_MSG_FRAME3MASTER_MSK & uart_msg->frame3) >>
497 BT_UART_MSG_FRAME3MASTER_POS,
498 (BT_UART_MSG_FRAME3OBEX_MSK & uart_msg->frame3) >>
499 BT_UART_MSG_FRAME3OBEX_POS);
500
501 IWL_DEBUG_NOTIF(priv, "Idle duration = 0x%X",
502 (BT_UART_MSG_FRAME4IDLEDURATION_MSK & uart_msg->frame4) >>
503 BT_UART_MSG_FRAME4IDLEDURATION_POS);
504
505 IWL_DEBUG_NOTIF(priv, "Tx Activity = 0x%X, Rx Activity = 0x%X, "
506 "eSCO Retransmissions = 0x%X",
507 (BT_UART_MSG_FRAME5TXACTIVITY_MSK & uart_msg->frame5) >>
508 BT_UART_MSG_FRAME5TXACTIVITY_POS,
509 (BT_UART_MSG_FRAME5RXACTIVITY_MSK & uart_msg->frame5) >>
510 BT_UART_MSG_FRAME5RXACTIVITY_POS,
511 (BT_UART_MSG_FRAME5ESCORETRANSMIT_MSK & uart_msg->frame5) >>
512 BT_UART_MSG_FRAME5ESCORETRANSMIT_POS);
513
514 IWL_DEBUG_NOTIF(priv, "Sniff Interval = 0x%X, Discoverable = 0x%X",
515 (BT_UART_MSG_FRAME6SNIFFINTERVAL_MSK & uart_msg->frame6) >>
516 BT_UART_MSG_FRAME6SNIFFINTERVAL_POS,
517 (BT_UART_MSG_FRAME6DISCOVERABLE_MSK & uart_msg->frame6) >>
518 BT_UART_MSG_FRAME6DISCOVERABLE_POS);
519
520 IWL_DEBUG_NOTIF(priv, "Sniff Activity = 0x%X, Inquiry/Page SR Mode = "
521 "0x%X, Connectable = 0x%X",
522 (BT_UART_MSG_FRAME7SNIFFACTIVITY_MSK & uart_msg->frame7) >>
523 BT_UART_MSG_FRAME7SNIFFACTIVITY_POS,
524 (BT_UART_MSG_FRAME7INQUIRYPAGESRMODE_MSK & uart_msg->frame7) >>
525 BT_UART_MSG_FRAME7INQUIRYPAGESRMODE_POS,
526 (BT_UART_MSG_FRAME7CONNECTABLE_MSK & uart_msg->frame7) >>
527 BT_UART_MSG_FRAME7CONNECTABLE_POS);
528 }
529
530 static void iwl6000g2b_set_kill_ack_msk(struct iwl_priv *priv,
531 struct iwl_bt_uart_msg *uart_msg)
532 {
533 u8 kill_ack_msk;
534 __le32 bt_kill_ack_msg[2] = {
535 cpu_to_le32(0xFFFFFFF), cpu_to_le32(0xFFFFFC00) };
536
537 kill_ack_msk = (((BT_UART_MSG_FRAME3A2DP_MSK |
538 BT_UART_MSG_FRAME3SNIFF_MSK |
539 BT_UART_MSG_FRAME3SCOESCO_MSK) &
540 uart_msg->frame3) == 0) ? 1 : 0;
541 if (priv->kill_ack_mask != bt_kill_ack_msg[kill_ack_msk]) {
542 priv->bt_valid |= IWL6000G2B_BT_VALID_KILL_ACK_MASK;
543 priv->kill_ack_mask = bt_kill_ack_msg[kill_ack_msk];
544 /* schedule to send runtime bt_config */
545 queue_work(priv->workqueue, &priv->bt_runtime_config);
546 }
547
548 }
549
550 static void iwl6000g2b_bt_coex_profile_notif(struct iwl_priv *priv,
551 struct iwl_rx_mem_buffer *rxb)
552 {
553 unsigned long flags;
554 struct iwl_rx_packet *pkt = rxb_addr(rxb);
555 struct iwl_bt_coex_profile_notif *coex = &pkt->u.bt_coex_profile_notif;
556 struct iwl6000g2b_bt_sco_cmd sco_cmd = { .flags = 0 };
557 struct iwl_bt_uart_msg *uart_msg = &coex->last_bt_uart_msg;
558 u8 last_traffic_load;
559
560 IWL_DEBUG_NOTIF(priv, "BT Coex notification:\n");
561 IWL_DEBUG_NOTIF(priv, " status: %d\n", coex->bt_status);
562 IWL_DEBUG_NOTIF(priv, " traffic load: %d\n", coex->bt_traffic_load);
563 IWL_DEBUG_NOTIF(priv, " CI compliance: %d\n", coex->bt_ci_compliance);
564 iwlagn_print_uartmsg(priv, uart_msg);
565
566 last_traffic_load = priv->notif_bt_traffic_load;
567 priv->notif_bt_traffic_load = coex->bt_traffic_load;
568 if (priv->iw_mode != NL80211_IFTYPE_ADHOC) {
569 if (priv->bt_status != coex->bt_status ||
570 last_traffic_load != coex->bt_traffic_load) {
571 if (coex->bt_status) {
572 /* BT on */
573 if (!priv->bt_ch_announce)
574 priv->bt_traffic_load =
575 IWL_BT_COEX_TRAFFIC_LOAD_HIGH;
576 else
577 priv->bt_traffic_load =
578 coex->bt_traffic_load;
579 } else {
580 /* BT off */
581 priv->bt_traffic_load =
582 IWL_BT_COEX_TRAFFIC_LOAD_NONE;
583 }
584 priv->bt_status = coex->bt_status;
585 queue_work(priv->workqueue,
586 &priv->bt_traffic_change_work);
587 }
588 if (priv->bt_sco_active !=
589 (uart_msg->frame3 & BT_UART_MSG_FRAME3SCOESCO_MSK)) {
590 priv->bt_sco_active = uart_msg->frame3 &
591 BT_UART_MSG_FRAME3SCOESCO_MSK;
592 if (priv->bt_sco_active)
593 sco_cmd.flags |= IWL6000G2B_BT_SCO_ACTIVE;
594 iwl_send_cmd_pdu_async(priv, REPLY_BT_COEX_SCO,
595 sizeof(sco_cmd), &sco_cmd, NULL);
596 }
597 }
598
599 iwl6000g2b_set_kill_ack_msk(priv, uart_msg);
600
601 /* FIXME: based on notification, adjust the prio_boost */
602
603 spin_lock_irqsave(&priv->lock, flags);
604 priv->bt_ci_compliance = coex->bt_ci_compliance;
605 spin_unlock_irqrestore(&priv->lock, flags);
606 }
607
608 void iwl6000g2b_rx_handler_setup(struct iwl_priv *priv)
609 {
610 iwlagn_rx_handler_setup(priv);
611 priv->rx_handlers[REPLY_BT_COEX_PROFILE_NOTIF] =
612 iwl6000g2b_bt_coex_profile_notif;
613 }
614
615 static void iwl6000g2b_bt_setup_deferred_work(struct iwl_priv *priv)
616 {
617 iwlagn_setup_deferred_work(priv);
618
619 INIT_WORK(&priv->bt_traffic_change_work,
620 iwl6000g2b_bt_traffic_change_work);
621
622 }
623
624 static void iwl6000g2b_bt_cancel_deferred_work(struct iwl_priv *priv)
625 {
626 cancel_work_sync(&priv->bt_traffic_change_work);
627 }
628
629 static struct iwl_lib_ops iwl6000_lib = {
630 .set_hw_params = iwl6000_hw_set_hw_params,
631 .txq_update_byte_cnt_tbl = iwlagn_txq_update_byte_cnt_tbl,
632 .txq_inval_byte_cnt_tbl = iwlagn_txq_inval_byte_cnt_tbl,
633 .txq_set_sched = iwlagn_txq_set_sched,
634 .txq_agg_enable = iwlagn_txq_agg_enable,
635 .txq_agg_disable = iwlagn_txq_agg_disable,
636 .txq_attach_buf_to_tfd = iwl_hw_txq_attach_buf_to_tfd,
637 .txq_free_tfd = iwl_hw_txq_free_tfd,
638 .txq_init = iwl_hw_tx_queue_init,
639 .rx_handler_setup = iwlagn_rx_handler_setup,
640 .setup_deferred_work = iwlagn_setup_deferred_work,
641 .is_valid_rtc_data_addr = iwlagn_hw_valid_rtc_data_addr,
642 .load_ucode = iwlagn_load_ucode,
643 .dump_nic_event_log = iwl_dump_nic_event_log,
644 .dump_nic_error_log = iwl_dump_nic_error_log,
645 .dump_csr = iwl_dump_csr,
646 .dump_fh = iwl_dump_fh,
647 .init_alive_start = iwlagn_init_alive_start,
648 .alive_notify = iwlagn_alive_notify,
649 .send_tx_power = iwlagn_send_tx_power,
650 .update_chain_flags = iwl_update_chain_flags,
651 .set_channel_switch = iwl6000_hw_channel_switch,
652 .apm_ops = {
653 .init = iwl_apm_init,
654 .stop = iwl_apm_stop,
655 .config = iwl6000_nic_config,
656 .set_pwr_src = iwl_set_pwr_src,
657 },
658 .eeprom_ops = {
659 .regulatory_bands = {
660 EEPROM_REG_BAND_1_CHANNELS,
661 EEPROM_REG_BAND_2_CHANNELS,
662 EEPROM_REG_BAND_3_CHANNELS,
663 EEPROM_REG_BAND_4_CHANNELS,
664 EEPROM_REG_BAND_5_CHANNELS,
665 EEPROM_6000_REG_BAND_24_HT40_CHANNELS,
666 EEPROM_REG_BAND_52_HT40_CHANNELS
667 },
668 .verify_signature = iwlcore_eeprom_verify_signature,
669 .acquire_semaphore = iwlcore_eeprom_acquire_semaphore,
670 .release_semaphore = iwlcore_eeprom_release_semaphore,
671 .calib_version = iwlagn_eeprom_calib_version,
672 .query_addr = iwlagn_eeprom_query_addr,
673 .update_enhanced_txpower = iwlcore_eeprom_enhanced_txpower,
674 },
675 .post_associate = iwl_post_associate,
676 .isr = iwl_isr_ict,
677 .config_ap = iwl_config_ap,
678 .temp_ops = {
679 .temperature = iwlagn_temperature,
680 .set_ct_kill = iwl6000_set_ct_threshold,
681 .set_calib_version = iwl6000_set_calib_version,
682 },
683 .manage_ibss_station = iwlagn_manage_ibss_station,
684 .update_bcast_station = iwl_update_bcast_station,
685 .debugfs_ops = {
686 .rx_stats_read = iwl_ucode_rx_stats_read,
687 .tx_stats_read = iwl_ucode_tx_stats_read,
688 .general_stats_read = iwl_ucode_general_stats_read,
689 .bt_stats_read = iwl_ucode_bt_stats_read,
690 },
691 .recover_from_tx_stall = iwl_bg_monitor_recover,
692 .check_plcp_health = iwl_good_plcp_health,
693 .check_ack_health = iwl_good_ack_health,
694 .txfifo_flush = iwlagn_txfifo_flush,
695 .dev_txfifo_flush = iwlagn_dev_txfifo_flush,
696 .tt_ops = {
697 .lower_power_detection = iwl_tt_is_low_power_state,
698 .tt_power_mode = iwl_tt_current_power_mode,
699 .ct_kill_check = iwl_check_for_ct_kill,
700 }
701 };
702
703 static struct iwl_lib_ops iwl6000g2b_lib = {
704 .set_hw_params = iwl6000_hw_set_hw_params,
705 .txq_update_byte_cnt_tbl = iwlagn_txq_update_byte_cnt_tbl,
706 .txq_inval_byte_cnt_tbl = iwlagn_txq_inval_byte_cnt_tbl,
707 .txq_set_sched = iwlagn_txq_set_sched,
708 .txq_agg_enable = iwlagn_txq_agg_enable,
709 .txq_agg_disable = iwlagn_txq_agg_disable,
710 .txq_attach_buf_to_tfd = iwl_hw_txq_attach_buf_to_tfd,
711 .txq_free_tfd = iwl_hw_txq_free_tfd,
712 .txq_init = iwl_hw_tx_queue_init,
713 .rx_handler_setup = iwl6000g2b_rx_handler_setup,
714 .setup_deferred_work = iwl6000g2b_bt_setup_deferred_work,
715 .cancel_deferred_work = iwl6000g2b_bt_cancel_deferred_work,
716 .is_valid_rtc_data_addr = iwlagn_hw_valid_rtc_data_addr,
717 .load_ucode = iwlagn_load_ucode,
718 .dump_nic_event_log = iwl_dump_nic_event_log,
719 .dump_nic_error_log = iwl_dump_nic_error_log,
720 .dump_csr = iwl_dump_csr,
721 .dump_fh = iwl_dump_fh,
722 .init_alive_start = iwlagn_init_alive_start,
723 .alive_notify = iwlagn_alive_notify,
724 .send_tx_power = iwlagn_send_tx_power,
725 .update_chain_flags = iwl_update_chain_flags,
726 .set_channel_switch = iwl6000_hw_channel_switch,
727 .apm_ops = {
728 .init = iwl_apm_init,
729 .stop = iwl_apm_stop,
730 .config = iwl6000_nic_config,
731 .set_pwr_src = iwl_set_pwr_src,
732 },
733 .eeprom_ops = {
734 .regulatory_bands = {
735 EEPROM_REG_BAND_1_CHANNELS,
736 EEPROM_REG_BAND_2_CHANNELS,
737 EEPROM_REG_BAND_3_CHANNELS,
738 EEPROM_REG_BAND_4_CHANNELS,
739 EEPROM_REG_BAND_5_CHANNELS,
740 EEPROM_6000_REG_BAND_24_HT40_CHANNELS,
741 EEPROM_REG_BAND_52_HT40_CHANNELS
742 },
743 .verify_signature = iwlcore_eeprom_verify_signature,
744 .acquire_semaphore = iwlcore_eeprom_acquire_semaphore,
745 .release_semaphore = iwlcore_eeprom_release_semaphore,
746 .calib_version = iwlagn_eeprom_calib_version,
747 .query_addr = iwlagn_eeprom_query_addr,
748 .update_enhanced_txpower = iwlcore_eeprom_enhanced_txpower,
749 },
750 .post_associate = iwl_post_associate,
751 .isr = iwl_isr_ict,
752 .config_ap = iwl_config_ap,
753 .temp_ops = {
754 .temperature = iwlagn_temperature,
755 .set_ct_kill = iwl6000_set_ct_threshold,
756 .set_calib_version = iwl6000_set_calib_version,
757 },
758 .manage_ibss_station = iwlagn_manage_ibss_station,
759 .update_bcast_station = iwl_update_bcast_station,
760 .debugfs_ops = {
761 .rx_stats_read = iwl_ucode_rx_stats_read,
762 .tx_stats_read = iwl_ucode_tx_stats_read,
763 .general_stats_read = iwl_ucode_general_stats_read,
764 .bt_stats_read = iwl_ucode_bt_stats_read,
765 },
766 .recover_from_tx_stall = iwl_bg_monitor_recover,
767 .check_plcp_health = iwl_good_plcp_health,
768 .check_ack_health = iwl_good_ack_health,
769 .txfifo_flush = iwlagn_txfifo_flush,
770 .dev_txfifo_flush = iwlagn_dev_txfifo_flush,
771 .tt_ops = {
772 .lower_power_detection = iwl_tt_is_low_power_state,
773 .tt_power_mode = iwl_tt_current_power_mode,
774 .ct_kill_check = iwl_check_for_ct_kill,
775 }
776 };
777
778 static const struct iwl_ops iwl6000_ops = {
779 .lib = &iwl6000_lib,
780 .hcmd = &iwlagn_hcmd,
781 .utils = &iwlagn_hcmd_utils,
782 .led = &iwlagn_led_ops,
783 };
784
785 static struct iwl_hcmd_ops iwl6000g2b_hcmd = {
786 .rxon_assoc = iwlagn_send_rxon_assoc,
787 .commit_rxon = iwl_commit_rxon,
788 .set_rxon_chain = iwl_set_rxon_chain,
789 .set_tx_ant = iwlagn_send_tx_ant_config,
790 .send_bt_config = iwl6000g2b_send_bt_config,
791 };
792
793 static const struct iwl_ops iwl6000g2b_ops = {
794 .lib = &iwl6000g2b_lib,
795 .hcmd = &iwl6000g2b_hcmd,
796 .utils = &iwlagn_hcmd_utils,
797 .led = &iwlagn_led_ops,
798 };
799
800 struct iwl_cfg iwl6000g2a_2agn_cfg = {
801 .name = "6000 Series 2x2 AGN Gen2a",
802 .fw_name_pre = IWL6000G2A_FW_PRE,
803 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
804 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
805 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
806 .ops = &iwl6000_ops,
807 .eeprom_size = OTP_LOW_IMAGE_SIZE,
808 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
809 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
810 .num_of_queues = IWLAGN_NUM_QUEUES,
811 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
812 .mod_params = &iwlagn_mod_params,
813 .valid_tx_ant = ANT_AB,
814 .valid_rx_ant = ANT_AB,
815 .pll_cfg_val = 0,
816 .set_l0s = true,
817 .use_bsm = false,
818 .pa_type = IWL_PA_SYSTEM,
819 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
820 .shadow_ram_support = true,
821 .ht_greenfield_support = true,
822 .led_compensation = 51,
823 .use_rts_for_aggregation = true, /* use rts/cts protection */
824 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
825 .supports_idle = true,
826 .adv_thermal_throttle = true,
827 .support_ct_kill_exit = true,
828 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
829 .chain_noise_scale = 1000,
830 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
831 .max_event_log_size = 512,
832 .ucode_tracing = true,
833 .sensitivity_calib_by_driver = true,
834 .chain_noise_calib_by_driver = true,
835 .need_dc_calib = true,
836 };
837
838 struct iwl_cfg iwl6000g2a_2abg_cfg = {
839 .name = "6000 Series 2x2 ABG Gen2a",
840 .fw_name_pre = IWL6000G2A_FW_PRE,
841 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
842 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
843 .sku = IWL_SKU_A|IWL_SKU_G,
844 .ops = &iwl6000_ops,
845 .eeprom_size = OTP_LOW_IMAGE_SIZE,
846 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
847 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
848 .num_of_queues = IWLAGN_NUM_QUEUES,
849 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
850 .mod_params = &iwlagn_mod_params,
851 .valid_tx_ant = ANT_AB,
852 .valid_rx_ant = ANT_AB,
853 .pll_cfg_val = 0,
854 .set_l0s = true,
855 .use_bsm = false,
856 .pa_type = IWL_PA_SYSTEM,
857 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
858 .shadow_ram_support = true,
859 .led_compensation = 51,
860 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
861 .supports_idle = true,
862 .adv_thermal_throttle = true,
863 .support_ct_kill_exit = true,
864 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
865 .chain_noise_scale = 1000,
866 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
867 .max_event_log_size = 512,
868 .sensitivity_calib_by_driver = true,
869 .chain_noise_calib_by_driver = true,
870 .need_dc_calib = true,
871 };
872
873 struct iwl_cfg iwl6000g2a_2bg_cfg = {
874 .name = "6000 Series 2x2 BG Gen2a",
875 .fw_name_pre = IWL6000G2A_FW_PRE,
876 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
877 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
878 .sku = IWL_SKU_G,
879 .ops = &iwl6000_ops,
880 .eeprom_size = OTP_LOW_IMAGE_SIZE,
881 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
882 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
883 .num_of_queues = IWLAGN_NUM_QUEUES,
884 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
885 .mod_params = &iwlagn_mod_params,
886 .valid_tx_ant = ANT_AB,
887 .valid_rx_ant = ANT_AB,
888 .pll_cfg_val = 0,
889 .set_l0s = true,
890 .use_bsm = false,
891 .pa_type = IWL_PA_SYSTEM,
892 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
893 .shadow_ram_support = true,
894 .led_compensation = 51,
895 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
896 .supports_idle = true,
897 .adv_thermal_throttle = true,
898 .support_ct_kill_exit = true,
899 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
900 .chain_noise_scale = 1000,
901 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
902 .max_event_log_size = 512,
903 .sensitivity_calib_by_driver = true,
904 .chain_noise_calib_by_driver = true,
905 .need_dc_calib = true,
906 };
907
908 struct iwl_cfg iwl6000g2b_2agn_cfg = {
909 .name = "6000 Series 2x2 AGN Gen2b",
910 .fw_name_pre = IWL6000G2B_FW_PRE,
911 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
912 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
913 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
914 .ops = &iwl6000g2b_ops,
915 .eeprom_size = OTP_LOW_IMAGE_SIZE,
916 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
917 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
918 .num_of_queues = IWLAGN_NUM_QUEUES,
919 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
920 .mod_params = &iwlagn_mod_params,
921 .valid_tx_ant = ANT_AB,
922 .valid_rx_ant = ANT_AB,
923 .pll_cfg_val = 0,
924 .set_l0s = true,
925 .use_bsm = false,
926 .pa_type = IWL_PA_SYSTEM,
927 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
928 .shadow_ram_support = true,
929 .ht_greenfield_support = true,
930 .led_compensation = 51,
931 .use_rts_for_aggregation = true, /* use rts/cts protection */
932 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
933 .supports_idle = true,
934 .adv_thermal_throttle = true,
935 .support_ct_kill_exit = true,
936 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE,
937 .chain_noise_scale = 1000,
938 .monitor_recover_period = IWL_LONG_MONITORING_PERIOD,
939 .max_event_log_size = 512,
940 .sensitivity_calib_by_driver = true,
941 .chain_noise_calib_by_driver = true,
942 .need_dc_calib = true,
943 .bt_statistics = true,
944 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
945 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
946 .advanced_bt_coexist = true,
947 .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
948 .bt_prio_boost = IWL6000G2B_BT_PRIO_BOOST_DEFAULT,
949 };
950
951 struct iwl_cfg iwl6000g2b_2abg_cfg = {
952 .name = "6000 Series 2x2 ABG Gen2b",
953 .fw_name_pre = IWL6000G2B_FW_PRE,
954 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
955 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
956 .sku = IWL_SKU_A|IWL_SKU_G,
957 .ops = &iwl6000g2b_ops,
958 .eeprom_size = OTP_LOW_IMAGE_SIZE,
959 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
960 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
961 .num_of_queues = IWLAGN_NUM_QUEUES,
962 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
963 .mod_params = &iwlagn_mod_params,
964 .valid_tx_ant = ANT_AB,
965 .valid_rx_ant = ANT_AB,
966 .pll_cfg_val = 0,
967 .set_l0s = true,
968 .use_bsm = false,
969 .pa_type = IWL_PA_SYSTEM,
970 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
971 .shadow_ram_support = true,
972 .led_compensation = 51,
973 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
974 .supports_idle = true,
975 .adv_thermal_throttle = true,
976 .support_ct_kill_exit = true,
977 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE,
978 .chain_noise_scale = 1000,
979 .monitor_recover_period = IWL_LONG_MONITORING_PERIOD,
980 .max_event_log_size = 512,
981 .sensitivity_calib_by_driver = true,
982 .chain_noise_calib_by_driver = true,
983 .need_dc_calib = true,
984 .bt_statistics = true,
985 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
986 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
987 .advanced_bt_coexist = true,
988 .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
989 .bt_prio_boost = IWL6000G2B_BT_PRIO_BOOST_DEFAULT,
990 };
991
992 struct iwl_cfg iwl6000g2b_2bgn_cfg = {
993 .name = "6000 Series 2x2 BGN Gen2b",
994 .fw_name_pre = IWL6000G2B_FW_PRE,
995 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
996 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
997 .sku = IWL_SKU_G|IWL_SKU_N,
998 .ops = &iwl6000g2b_ops,
999 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1000 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
1001 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
1002 .num_of_queues = IWLAGN_NUM_QUEUES,
1003 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1004 .mod_params = &iwlagn_mod_params,
1005 .valid_tx_ant = ANT_AB,
1006 .valid_rx_ant = ANT_AB,
1007 .pll_cfg_val = 0,
1008 .set_l0s = true,
1009 .use_bsm = false,
1010 .pa_type = IWL_PA_SYSTEM,
1011 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1012 .shadow_ram_support = true,
1013 .ht_greenfield_support = true,
1014 .led_compensation = 51,
1015 .use_rts_for_aggregation = true, /* use rts/cts protection */
1016 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1017 .supports_idle = true,
1018 .adv_thermal_throttle = true,
1019 .support_ct_kill_exit = true,
1020 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE,
1021 .chain_noise_scale = 1000,
1022 .monitor_recover_period = IWL_LONG_MONITORING_PERIOD,
1023 .max_event_log_size = 512,
1024 .sensitivity_calib_by_driver = true,
1025 .chain_noise_calib_by_driver = true,
1026 .need_dc_calib = true,
1027 .bt_statistics = true,
1028 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
1029 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
1030 .advanced_bt_coexist = true,
1031 .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
1032 .bt_prio_boost = IWL6000G2B_BT_PRIO_BOOST_DEFAULT,
1033 };
1034
1035 struct iwl_cfg iwl6000g2b_2bg_cfg = {
1036 .name = "6000 Series 2x2 BG Gen2b",
1037 .fw_name_pre = IWL6000G2B_FW_PRE,
1038 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
1039 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
1040 .sku = IWL_SKU_G,
1041 .ops = &iwl6000g2b_ops,
1042 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1043 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
1044 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
1045 .num_of_queues = IWLAGN_NUM_QUEUES,
1046 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1047 .mod_params = &iwlagn_mod_params,
1048 .valid_tx_ant = ANT_AB,
1049 .valid_rx_ant = ANT_AB,
1050 .pll_cfg_val = 0,
1051 .set_l0s = true,
1052 .use_bsm = false,
1053 .pa_type = IWL_PA_SYSTEM,
1054 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1055 .shadow_ram_support = true,
1056 .led_compensation = 51,
1057 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1058 .supports_idle = true,
1059 .adv_thermal_throttle = true,
1060 .support_ct_kill_exit = true,
1061 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE,
1062 .chain_noise_scale = 1000,
1063 .monitor_recover_period = IWL_LONG_MONITORING_PERIOD,
1064 .max_event_log_size = 512,
1065 .sensitivity_calib_by_driver = true,
1066 .chain_noise_calib_by_driver = true,
1067 .need_dc_calib = true,
1068 .bt_statistics = true,
1069 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
1070 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
1071 .advanced_bt_coexist = true,
1072 .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
1073 .bt_prio_boost = IWL6000G2B_BT_PRIO_BOOST_DEFAULT,
1074 };
1075
1076 struct iwl_cfg iwl6000g2b_bgn_cfg = {
1077 .name = "6000 Series 1x2 BGN Gen2b",
1078 .fw_name_pre = IWL6000G2B_FW_PRE,
1079 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
1080 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
1081 .sku = IWL_SKU_G|IWL_SKU_N,
1082 .ops = &iwl6000g2b_ops,
1083 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1084 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
1085 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
1086 .num_of_queues = IWLAGN_NUM_QUEUES,
1087 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1088 .mod_params = &iwlagn_mod_params,
1089 .valid_tx_ant = ANT_A,
1090 .valid_rx_ant = ANT_AB,
1091 .pll_cfg_val = 0,
1092 .set_l0s = true,
1093 .use_bsm = false,
1094 .pa_type = IWL_PA_SYSTEM,
1095 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1096 .shadow_ram_support = true,
1097 .ht_greenfield_support = true,
1098 .led_compensation = 51,
1099 .use_rts_for_aggregation = true, /* use rts/cts protection */
1100 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1101 .supports_idle = true,
1102 .adv_thermal_throttle = true,
1103 .support_ct_kill_exit = true,
1104 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE,
1105 .chain_noise_scale = 1000,
1106 .monitor_recover_period = IWL_LONG_MONITORING_PERIOD,
1107 .max_event_log_size = 512,
1108 .sensitivity_calib_by_driver = true,
1109 .chain_noise_calib_by_driver = true,
1110 .need_dc_calib = true,
1111 .bt_statistics = true,
1112 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
1113 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
1114 .advanced_bt_coexist = true,
1115 .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
1116 .bt_prio_boost = IWL6000G2B_BT_PRIO_BOOST_DEFAULT,
1117 };
1118
1119 struct iwl_cfg iwl6000g2b_bg_cfg = {
1120 .name = "6000 Series 1x2 BG Gen2b",
1121 .fw_name_pre = IWL6000G2B_FW_PRE,
1122 .ucode_api_max = IWL6000G2_UCODE_API_MAX,
1123 .ucode_api_min = IWL6000G2_UCODE_API_MIN,
1124 .sku = IWL_SKU_G,
1125 .ops = &iwl6000g2b_ops,
1126 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1127 .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION,
1128 .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION,
1129 .num_of_queues = IWLAGN_NUM_QUEUES,
1130 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1131 .mod_params = &iwlagn_mod_params,
1132 .valid_tx_ant = ANT_A,
1133 .valid_rx_ant = ANT_AB,
1134 .pll_cfg_val = 0,
1135 .set_l0s = true,
1136 .use_bsm = false,
1137 .pa_type = IWL_PA_SYSTEM,
1138 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1139 .shadow_ram_support = true,
1140 .led_compensation = 51,
1141 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1142 .supports_idle = true,
1143 .adv_thermal_throttle = true,
1144 .support_ct_kill_exit = true,
1145 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE,
1146 .chain_noise_scale = 1000,
1147 .monitor_recover_period = IWL_LONG_MONITORING_PERIOD,
1148 .max_event_log_size = 512,
1149 .sensitivity_calib_by_driver = true,
1150 .chain_noise_calib_by_driver = true,
1151 .need_dc_calib = true,
1152 .bt_statistics = true,
1153 /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
1154 .scan_tx_antennas[IEEE80211_BAND_2GHZ] = ANT_A,
1155 .advanced_bt_coexist = true,
1156 .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
1157 .bt_prio_boost = IWL6000G2B_BT_PRIO_BOOST_DEFAULT,
1158 };
1159
1160 /*
1161 * "i": Internal configuration, use internal Power Amplifier
1162 */
1163 struct iwl_cfg iwl6000i_2agn_cfg = {
1164 .name = "Intel(R) Centrino(R) Advanced-N 6200 AGN",
1165 .fw_name_pre = IWL6000_FW_PRE,
1166 .ucode_api_max = IWL6000_UCODE_API_MAX,
1167 .ucode_api_min = IWL6000_UCODE_API_MIN,
1168 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
1169 .ops = &iwl6000_ops,
1170 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1171 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
1172 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
1173 .num_of_queues = IWLAGN_NUM_QUEUES,
1174 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1175 .mod_params = &iwlagn_mod_params,
1176 .valid_tx_ant = ANT_BC,
1177 .valid_rx_ant = ANT_BC,
1178 .pll_cfg_val = 0,
1179 .set_l0s = true,
1180 .use_bsm = false,
1181 .pa_type = IWL_PA_INTERNAL,
1182 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1183 .shadow_ram_support = true,
1184 .ht_greenfield_support = true,
1185 .led_compensation = 51,
1186 .use_rts_for_aggregation = true, /* use rts/cts protection */
1187 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1188 .supports_idle = true,
1189 .adv_thermal_throttle = true,
1190 .support_ct_kill_exit = true,
1191 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
1192 .chain_noise_scale = 1000,
1193 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
1194 .max_event_log_size = 1024,
1195 .ucode_tracing = true,
1196 .sensitivity_calib_by_driver = true,
1197 .chain_noise_calib_by_driver = true,
1198 };
1199
1200 struct iwl_cfg iwl6000i_2abg_cfg = {
1201 .name = "Intel(R) Centrino(R) Advanced-N 6200 ABG",
1202 .fw_name_pre = IWL6000_FW_PRE,
1203 .ucode_api_max = IWL6000_UCODE_API_MAX,
1204 .ucode_api_min = IWL6000_UCODE_API_MIN,
1205 .sku = IWL_SKU_A|IWL_SKU_G,
1206 .ops = &iwl6000_ops,
1207 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1208 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
1209 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
1210 .num_of_queues = IWLAGN_NUM_QUEUES,
1211 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1212 .mod_params = &iwlagn_mod_params,
1213 .valid_tx_ant = ANT_BC,
1214 .valid_rx_ant = ANT_BC,
1215 .pll_cfg_val = 0,
1216 .set_l0s = true,
1217 .use_bsm = false,
1218 .pa_type = IWL_PA_INTERNAL,
1219 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1220 .shadow_ram_support = true,
1221 .led_compensation = 51,
1222 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1223 .supports_idle = true,
1224 .adv_thermal_throttle = true,
1225 .support_ct_kill_exit = true,
1226 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
1227 .chain_noise_scale = 1000,
1228 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
1229 .max_event_log_size = 1024,
1230 .ucode_tracing = true,
1231 .sensitivity_calib_by_driver = true,
1232 .chain_noise_calib_by_driver = true,
1233 };
1234
1235 struct iwl_cfg iwl6000i_2bg_cfg = {
1236 .name = "Intel(R) Centrino(R) Advanced-N 6200 BG",
1237 .fw_name_pre = IWL6000_FW_PRE,
1238 .ucode_api_max = IWL6000_UCODE_API_MAX,
1239 .ucode_api_min = IWL6000_UCODE_API_MIN,
1240 .sku = IWL_SKU_G,
1241 .ops = &iwl6000_ops,
1242 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1243 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
1244 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
1245 .num_of_queues = IWLAGN_NUM_QUEUES,
1246 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1247 .mod_params = &iwlagn_mod_params,
1248 .valid_tx_ant = ANT_BC,
1249 .valid_rx_ant = ANT_BC,
1250 .pll_cfg_val = 0,
1251 .set_l0s = true,
1252 .use_bsm = false,
1253 .pa_type = IWL_PA_INTERNAL,
1254 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1255 .shadow_ram_support = true,
1256 .led_compensation = 51,
1257 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1258 .supports_idle = true,
1259 .adv_thermal_throttle = true,
1260 .support_ct_kill_exit = true,
1261 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
1262 .chain_noise_scale = 1000,
1263 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
1264 .max_event_log_size = 1024,
1265 .ucode_tracing = true,
1266 .sensitivity_calib_by_driver = true,
1267 .chain_noise_calib_by_driver = true,
1268 };
1269
1270 struct iwl_cfg iwl6050_2agn_cfg = {
1271 .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 AGN",
1272 .fw_name_pre = IWL6050_FW_PRE,
1273 .ucode_api_max = IWL6050_UCODE_API_MAX,
1274 .ucode_api_min = IWL6050_UCODE_API_MIN,
1275 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
1276 .ops = &iwl6000_ops,
1277 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1278 .eeprom_ver = EEPROM_6050_EEPROM_VERSION,
1279 .eeprom_calib_ver = EEPROM_6050_TX_POWER_VERSION,
1280 .num_of_queues = IWLAGN_NUM_QUEUES,
1281 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1282 .mod_params = &iwlagn_mod_params,
1283 .valid_tx_ant = ANT_AB,
1284 .valid_rx_ant = ANT_AB,
1285 .pll_cfg_val = 0,
1286 .set_l0s = true,
1287 .use_bsm = false,
1288 .pa_type = IWL_PA_SYSTEM,
1289 .max_ll_items = OTP_MAX_LL_ITEMS_6x50,
1290 .shadow_ram_support = true,
1291 .ht_greenfield_support = true,
1292 .led_compensation = 51,
1293 .use_rts_for_aggregation = true, /* use rts/cts protection */
1294 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1295 .supports_idle = true,
1296 .adv_thermal_throttle = true,
1297 .support_ct_kill_exit = true,
1298 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
1299 .chain_noise_scale = 1500,
1300 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
1301 .max_event_log_size = 1024,
1302 .ucode_tracing = true,
1303 .sensitivity_calib_by_driver = true,
1304 .chain_noise_calib_by_driver = true,
1305 .need_dc_calib = true,
1306 };
1307
1308 struct iwl_cfg iwl6050g2_bgn_cfg = {
1309 .name = "6050 Series 1x2 BGN Gen2",
1310 .fw_name_pre = IWL6050_FW_PRE,
1311 .ucode_api_max = IWL6050_UCODE_API_MAX,
1312 .ucode_api_min = IWL6050_UCODE_API_MIN,
1313 .sku = IWL_SKU_G|IWL_SKU_N,
1314 .ops = &iwl6000_ops,
1315 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1316 .eeprom_ver = EEPROM_6050G2_EEPROM_VERSION,
1317 .eeprom_calib_ver = EEPROM_6050G2_TX_POWER_VERSION,
1318 .num_of_queues = IWLAGN_NUM_QUEUES,
1319 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1320 .mod_params = &iwlagn_mod_params,
1321 .valid_tx_ant = ANT_A,
1322 .valid_rx_ant = ANT_AB,
1323 .pll_cfg_val = 0,
1324 .set_l0s = true,
1325 .use_bsm = false,
1326 .pa_type = IWL_PA_SYSTEM,
1327 .max_ll_items = OTP_MAX_LL_ITEMS_6x50,
1328 .shadow_ram_support = true,
1329 .ht_greenfield_support = true,
1330 .led_compensation = 51,
1331 .use_rts_for_aggregation = true, /* use rts/cts protection */
1332 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1333 .supports_idle = true,
1334 .adv_thermal_throttle = true,
1335 .support_ct_kill_exit = true,
1336 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
1337 .chain_noise_scale = 1500,
1338 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
1339 .max_event_log_size = 1024,
1340 .ucode_tracing = true,
1341 .sensitivity_calib_by_driver = true,
1342 .chain_noise_calib_by_driver = true,
1343 .need_dc_calib = true,
1344 };
1345
1346 struct iwl_cfg iwl6050_2abg_cfg = {
1347 .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 ABG",
1348 .fw_name_pre = IWL6050_FW_PRE,
1349 .ucode_api_max = IWL6050_UCODE_API_MAX,
1350 .ucode_api_min = IWL6050_UCODE_API_MIN,
1351 .sku = IWL_SKU_A|IWL_SKU_G,
1352 .ops = &iwl6000_ops,
1353 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1354 .eeprom_ver = EEPROM_6050_EEPROM_VERSION,
1355 .eeprom_calib_ver = EEPROM_6050_TX_POWER_VERSION,
1356 .num_of_queues = IWLAGN_NUM_QUEUES,
1357 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1358 .mod_params = &iwlagn_mod_params,
1359 .valid_tx_ant = ANT_AB,
1360 .valid_rx_ant = ANT_AB,
1361 .pll_cfg_val = 0,
1362 .set_l0s = true,
1363 .use_bsm = false,
1364 .pa_type = IWL_PA_SYSTEM,
1365 .max_ll_items = OTP_MAX_LL_ITEMS_6x50,
1366 .shadow_ram_support = true,
1367 .led_compensation = 51,
1368 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1369 .supports_idle = true,
1370 .adv_thermal_throttle = true,
1371 .support_ct_kill_exit = true,
1372 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
1373 .chain_noise_scale = 1500,
1374 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
1375 .max_event_log_size = 1024,
1376 .ucode_tracing = true,
1377 .sensitivity_calib_by_driver = true,
1378 .chain_noise_calib_by_driver = true,
1379 .need_dc_calib = true,
1380 };
1381
1382 struct iwl_cfg iwl6000_3agn_cfg = {
1383 .name = "Intel(R) Centrino(R) Ultimate-N 6300 AGN",
1384 .fw_name_pre = IWL6000_FW_PRE,
1385 .ucode_api_max = IWL6000_UCODE_API_MAX,
1386 .ucode_api_min = IWL6000_UCODE_API_MIN,
1387 .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N,
1388 .ops = &iwl6000_ops,
1389 .eeprom_size = OTP_LOW_IMAGE_SIZE,
1390 .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
1391 .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
1392 .num_of_queues = IWLAGN_NUM_QUEUES,
1393 .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
1394 .mod_params = &iwlagn_mod_params,
1395 .valid_tx_ant = ANT_ABC,
1396 .valid_rx_ant = ANT_ABC,
1397 .pll_cfg_val = 0,
1398 .set_l0s = true,
1399 .use_bsm = false,
1400 .pa_type = IWL_PA_SYSTEM,
1401 .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
1402 .shadow_ram_support = true,
1403 .ht_greenfield_support = true,
1404 .led_compensation = 51,
1405 .use_rts_for_aggregation = true, /* use rts/cts protection */
1406 .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS,
1407 .supports_idle = true,
1408 .adv_thermal_throttle = true,
1409 .support_ct_kill_exit = true,
1410 .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
1411 .chain_noise_scale = 1000,
1412 .monitor_recover_period = IWL_DEF_MONITORING_PERIOD,
1413 .max_event_log_size = 1024,
1414 .ucode_tracing = true,
1415 .sensitivity_calib_by_driver = true,
1416 .chain_noise_calib_by_driver = true,
1417 };
1418
1419 MODULE_FIRMWARE(IWL6000_MODULE_FIRMWARE(IWL6000_UCODE_API_MAX));
1420 MODULE_FIRMWARE(IWL6050_MODULE_FIRMWARE(IWL6050_UCODE_API_MAX));
1421 MODULE_FIRMWARE(IWL6000G2A_MODULE_FIRMWARE(IWL6000G2_UCODE_API_MAX));
1422 MODULE_FIRMWARE(IWL6000G2B_MODULE_FIRMWARE(IWL6000G2_UCODE_API_MAX));
This page took 0.060222 seconds and 4 git commands to generate.