Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 1 | /****************************************************************************** |
| 2 | * |
Reinette Chatre | 1f44780 | 2010-01-15 13:43:41 -0800 | [diff] [blame] | 3 | * Copyright(c) 2008 - 2010 Intel Corporation. All rights reserved. |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 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" |
Johannes Berg | a117512 | 2010-01-21 06:21:10 -0800 | [diff] [blame] | 45 | #include "iwl-agn.h" |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 46 | #include "iwl-helpers.h" |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 47 | #include "iwl-agn-hw.h" |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 48 | #include "iwl-6000-hw.h" |
Johannes Berg | e932a60 | 2009-10-02 13:44:03 -0700 | [diff] [blame] | 49 | #include "iwl-agn-led.h" |
Abhijeet Kolekar | b8c7626 | 2010-04-08 15:29:07 -0700 | [diff] [blame^] | 50 | #include "iwl-agn-debugfs.h" |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 51 | |
| 52 | /* Highest firmware API version supported */ |
Wey-Yi Guy | fcbaf8b | 2009-08-21 13:34:18 -0700 | [diff] [blame] | 53 | #define IWL6000_UCODE_API_MAX 4 |
| 54 | #define IWL6050_UCODE_API_MAX 4 |
Shanyu Zhao | 4b3e806 | 2010-04-07 18:06:36 -0700 | [diff] [blame] | 55 | #define IWL6000G2_UCODE_API_MAX 4 |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 56 | |
| 57 | /* Lowest firmware API version supported */ |
Wey-Yi Guy | 4424642 | 2009-10-23 13:42:34 -0700 | [diff] [blame] | 58 | #define IWL6000_UCODE_API_MIN 4 |
| 59 | #define IWL6050_UCODE_API_MIN 4 |
Shanyu Zhao | 4b3e806 | 2010-04-07 18:06:36 -0700 | [diff] [blame] | 60 | #define IWL6000G2_UCODE_API_MIN 4 |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 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 | |
Shanyu Zhao | 4b3e806 | 2010-04-07 18:06:36 -0700 | [diff] [blame] | 70 | #define IWL6000G2_FW_PRE "iwlwifi-6005-" |
| 71 | #define _IWL6000G2_MODULE_FIRMWARE(api) IWL6000G2_FW_PRE #api ".ucode" |
| 72 | #define IWL6000G2_MODULE_FIRMWARE(api) _IWL6000G2_MODULE_FIRMWARE(api) |
| 73 | |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 74 | static void iwl6000_set_ct_threshold(struct iwl_priv *priv) |
| 75 | { |
| 76 | /* want Celsius */ |
| 77 | priv->hw_params.ct_kill_threshold = CT_KILL_THRESHOLD; |
| 78 | priv->hw_params.ct_kill_exit_threshold = CT_KILL_EXIT_THRESHOLD; |
| 79 | } |
| 80 | |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 81 | /* Indicate calibration version to uCode. */ |
| 82 | static void iwl6050_set_calib_version(struct iwl_priv *priv) |
| 83 | { |
| 84 | if (priv->cfg->ops->lib->eeprom_ops.calib_version(priv) >= 6) |
| 85 | iwl_set_bit(priv, CSR_GP_DRIVER_REG, |
| 86 | CSR_GP_DRIVER_REG_BIT_CALIB_VERSION6); |
| 87 | } |
| 88 | |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 89 | /* NIC configuration for 6000 series */ |
| 90 | static void iwl6000_nic_config(struct iwl_priv *priv) |
| 91 | { |
Wey-Yi Guy | 9371d4e | 2009-09-11 10:38:10 -0700 | [diff] [blame] | 92 | u16 radio_cfg; |
| 93 | |
| 94 | radio_cfg = iwl_eeprom_query16(priv, EEPROM_RADIO_CONFIG); |
| 95 | |
| 96 | /* write radio config values to register */ |
| 97 | if (EEPROM_RF_CFG_TYPE_MSK(radio_cfg) <= EEPROM_RF_CONFIG_TYPE_MAX) |
| 98 | iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG, |
| 99 | EEPROM_RF_CFG_TYPE_MSK(radio_cfg) | |
| 100 | EEPROM_RF_CFG_STEP_MSK(radio_cfg) | |
| 101 | EEPROM_RF_CFG_DASH_MSK(radio_cfg)); |
| 102 | |
| 103 | /* set CSR_HW_CONFIG_REG for uCode use */ |
| 104 | iwl_set_bit(priv, CSR_HW_IF_CONFIG_REG, |
| 105 | CSR_HW_IF_CONFIG_REG_BIT_RADIO_SI | |
| 106 | CSR_HW_IF_CONFIG_REG_BIT_MAC_SI); |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 107 | |
| 108 | /* no locking required for register write */ |
Wey-Yi Guy | 740e7f5 | 2009-11-06 14:52:55 -0800 | [diff] [blame] | 109 | if (priv->cfg->pa_type == IWL_PA_INTERNAL) { |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 110 | /* 2x2 IPA phy type */ |
| 111 | iwl_write32(priv, CSR_GP_DRIVER_REG, |
| 112 | CSR_GP_DRIVER_REG_BIT_RADIO_SKU_2x2_IPA); |
| 113 | } |
| 114 | /* else do nothing, uCode configured */ |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 115 | if (priv->cfg->ops->lib->temp_ops.set_calib_version) |
| 116 | priv->cfg->ops->lib->temp_ops.set_calib_version(priv); |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 117 | } |
| 118 | |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 119 | static struct iwl_sensitivity_ranges iwl6000_sensitivity = { |
| 120 | .min_nrg_cck = 97, |
| 121 | .max_nrg_cck = 0, /* not used, set to 0 */ |
| 122 | .auto_corr_min_ofdm = 80, |
| 123 | .auto_corr_min_ofdm_mrc = 128, |
| 124 | .auto_corr_min_ofdm_x1 = 105, |
| 125 | .auto_corr_min_ofdm_mrc_x1 = 192, |
| 126 | |
| 127 | .auto_corr_max_ofdm = 145, |
| 128 | .auto_corr_max_ofdm_mrc = 232, |
Wey-Yi Guy | 2494f63 | 2010-01-20 12:22:52 -0800 | [diff] [blame] | 129 | .auto_corr_max_ofdm_x1 = 110, |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 130 | .auto_corr_max_ofdm_mrc_x1 = 232, |
| 131 | |
| 132 | .auto_corr_min_cck = 125, |
| 133 | .auto_corr_max_cck = 175, |
| 134 | .auto_corr_min_cck_mrc = 160, |
| 135 | .auto_corr_max_cck_mrc = 310, |
| 136 | .nrg_th_cck = 97, |
| 137 | .nrg_th_ofdm = 100, |
Wey-Yi Guy | 55036d6 | 2009-10-09 13:20:24 -0700 | [diff] [blame] | 138 | |
| 139 | .barker_corr_th_min = 190, |
| 140 | .barker_corr_th_min_mrc = 390, |
| 141 | .nrg_th_cca = 62, |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 142 | }; |
| 143 | |
| 144 | static int iwl6000_hw_set_hw_params(struct iwl_priv *priv) |
| 145 | { |
Wey-Yi Guy | 88804e2 | 2009-10-09 13:20:28 -0700 | [diff] [blame] | 146 | if (priv->cfg->mod_params->num_of_queues >= IWL_MIN_NUM_QUEUES && |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 147 | priv->cfg->mod_params->num_of_queues <= IWLAGN_NUM_QUEUES) |
Wey-Yi Guy | 88804e2 | 2009-10-09 13:20:28 -0700 | [diff] [blame] | 148 | priv->cfg->num_of_queues = |
| 149 | priv->cfg->mod_params->num_of_queues; |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 150 | |
Wey-Yi Guy | 88804e2 | 2009-10-09 13:20:28 -0700 | [diff] [blame] | 151 | priv->hw_params.max_txq_num = priv->cfg->num_of_queues; |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 152 | priv->hw_params.dma_chnl_num = FH50_TCSR_CHNL_NUM; |
| 153 | priv->hw_params.scd_bc_tbls_size = |
Wey-Yi Guy | 88804e2 | 2009-10-09 13:20:28 -0700 | [diff] [blame] | 154 | priv->cfg->num_of_queues * |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 155 | sizeof(struct iwlagn_scd_bc_tbl); |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 156 | priv->hw_params.tfd_size = sizeof(struct iwl_tfd); |
| 157 | priv->hw_params.max_stations = IWL5000_STATION_COUNT; |
| 158 | priv->hw_params.bcast_sta_id = IWL5000_BROADCAST_ID; |
| 159 | |
| 160 | priv->hw_params.max_data_size = IWL60_RTC_DATA_SIZE; |
| 161 | priv->hw_params.max_inst_size = IWL60_RTC_INST_SIZE; |
| 162 | |
| 163 | priv->hw_params.max_bsm_size = 0; |
| 164 | priv->hw_params.ht40_channel = BIT(IEEE80211_BAND_2GHZ) | |
| 165 | BIT(IEEE80211_BAND_5GHZ); |
| 166 | priv->hw_params.rx_wrt_ptr_reg = FH_RSCSR_CHNL0_WPTR; |
| 167 | |
| 168 | priv->hw_params.tx_chains_num = num_of_ant(priv->cfg->valid_tx_ant); |
| 169 | priv->hw_params.rx_chains_num = num_of_ant(priv->cfg->valid_rx_ant); |
| 170 | priv->hw_params.valid_tx_ant = priv->cfg->valid_tx_ant; |
| 171 | priv->hw_params.valid_rx_ant = priv->cfg->valid_rx_ant; |
| 172 | |
| 173 | if (priv->cfg->ops->lib->temp_ops.set_ct_kill) |
| 174 | priv->cfg->ops->lib->temp_ops.set_ct_kill(priv); |
| 175 | |
| 176 | /* Set initial sensitivity parameters */ |
| 177 | /* Set initial calibration set */ |
| 178 | priv->hw_params.sens = &iwl6000_sensitivity; |
Abhijeet Kolekar | 07f33f9 | 2010-01-22 14:22:47 -0800 | [diff] [blame] | 179 | switch (priv->hw_rev & CSR_HW_REV_TYPE_MSK) { |
| 180 | case CSR_HW_REV_TYPE_6x50: |
| 181 | priv->hw_params.calib_init_cfg = |
| 182 | BIT(IWL_CALIB_XTAL) | |
| 183 | BIT(IWL_CALIB_DC) | |
| 184 | BIT(IWL_CALIB_LO) | |
| 185 | BIT(IWL_CALIB_TX_IQ) | |
| 186 | BIT(IWL_CALIB_BASE_BAND); |
| 187 | |
| 188 | break; |
| 189 | default: |
| 190 | priv->hw_params.calib_init_cfg = |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 191 | BIT(IWL_CALIB_XTAL) | |
| 192 | BIT(IWL_CALIB_LO) | |
| 193 | BIT(IWL_CALIB_TX_IQ) | |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 194 | BIT(IWL_CALIB_BASE_BAND); |
Abhijeet Kolekar | 07f33f9 | 2010-01-22 14:22:47 -0800 | [diff] [blame] | 195 | break; |
| 196 | } |
| 197 | |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 198 | return 0; |
| 199 | } |
| 200 | |
Wey-Yi Guy | 4a56e96 | 2009-10-23 13:42:29 -0700 | [diff] [blame] | 201 | static int iwl6000_hw_channel_switch(struct iwl_priv *priv, u16 channel) |
| 202 | { |
| 203 | struct iwl6000_channel_switch_cmd cmd; |
| 204 | const struct iwl_channel_info *ch_info; |
| 205 | struct iwl_host_cmd hcmd = { |
| 206 | .id = REPLY_CHANNEL_SWITCH, |
| 207 | .len = sizeof(cmd), |
| 208 | .flags = CMD_SIZE_HUGE, |
| 209 | .data = &cmd, |
| 210 | }; |
| 211 | |
| 212 | IWL_DEBUG_11H(priv, "channel switch from %d to %d\n", |
| 213 | priv->active_rxon.channel, channel); |
| 214 | |
| 215 | cmd.band = priv->band == IEEE80211_BAND_2GHZ; |
| 216 | cmd.channel = cpu_to_le16(channel); |
Wey-Yi Guy | 0924e519 | 2009-11-06 14:52:54 -0800 | [diff] [blame] | 217 | cmd.rxon_flags = priv->staging_rxon.flags; |
| 218 | cmd.rxon_filter_flags = priv->staging_rxon.filter_flags; |
Wey-Yi Guy | 4a56e96 | 2009-10-23 13:42:29 -0700 | [diff] [blame] | 219 | cmd.switch_time = cpu_to_le32(priv->ucode_beacon_time); |
| 220 | ch_info = iwl_get_channel_info(priv, priv->band, channel); |
| 221 | if (ch_info) |
| 222 | cmd.expect_beacon = is_channel_radar(ch_info); |
| 223 | else { |
| 224 | IWL_ERR(priv, "invalid channel switch from %u to %u\n", |
| 225 | priv->active_rxon.channel, channel); |
| 226 | return -EFAULT; |
| 227 | } |
Wey-Yi Guy | 0924e519 | 2009-11-06 14:52:54 -0800 | [diff] [blame] | 228 | priv->switch_rxon.channel = cpu_to_le16(channel); |
| 229 | priv->switch_rxon.switch_in_progress = true; |
Wey-Yi Guy | 4a56e96 | 2009-10-23 13:42:29 -0700 | [diff] [blame] | 230 | |
| 231 | return iwl_send_cmd_sync(priv, &hcmd); |
| 232 | } |
| 233 | |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 234 | static struct iwl_lib_ops iwl6000_lib = { |
Wey-Yi Guy | f3a2a42 | 2009-09-11 10:38:11 -0700 | [diff] [blame] | 235 | .set_hw_params = iwl6000_hw_set_hw_params, |
Wey-Yi Guy | b305a08 | 2010-03-16 17:41:22 -0700 | [diff] [blame] | 236 | .txq_update_byte_cnt_tbl = iwlagn_txq_update_byte_cnt_tbl, |
| 237 | .txq_inval_byte_cnt_tbl = iwlagn_txq_inval_byte_cnt_tbl, |
| 238 | .txq_set_sched = iwlagn_txq_set_sched, |
| 239 | .txq_agg_enable = iwlagn_txq_agg_enable, |
| 240 | .txq_agg_disable = iwlagn_txq_agg_disable, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 241 | .txq_attach_buf_to_tfd = iwl_hw_txq_attach_buf_to_tfd, |
| 242 | .txq_free_tfd = iwl_hw_txq_free_tfd, |
| 243 | .txq_init = iwl_hw_tx_queue_init, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 244 | .rx_handler_setup = iwlagn_rx_handler_setup, |
| 245 | .setup_deferred_work = iwlagn_setup_deferred_work, |
| 246 | .is_valid_rtc_data_addr = iwlagn_hw_valid_rtc_data_addr, |
Wey-Yi Guy | 81b8176 | 2010-03-16 10:23:30 -0700 | [diff] [blame] | 247 | .load_ucode = iwlagn_load_ucode, |
Reinette Chatre | b7a7940 | 2009-09-25 14:24:23 -0700 | [diff] [blame] | 248 | .dump_nic_event_log = iwl_dump_nic_event_log, |
| 249 | .dump_nic_error_log = iwl_dump_nic_error_log, |
Wey-Yi Guy | 696bdee | 2009-12-10 14:37:25 -0800 | [diff] [blame] | 250 | .dump_csr = iwl_dump_csr, |
Wey-Yi Guy | 1b3eb82 | 2010-01-15 13:43:39 -0800 | [diff] [blame] | 251 | .dump_fh = iwl_dump_fh, |
Wey-Yi Guy | 741a626 | 2010-03-16 12:37:24 -0700 | [diff] [blame] | 252 | .init_alive_start = iwlagn_init_alive_start, |
| 253 | .alive_notify = iwlagn_alive_notify, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 254 | .send_tx_power = iwlagn_send_tx_power, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 255 | .update_chain_flags = iwl_update_chain_flags, |
Wey-Yi Guy | 4a56e96 | 2009-10-23 13:42:29 -0700 | [diff] [blame] | 256 | .set_channel_switch = iwl6000_hw_channel_switch, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 257 | .apm_ops = { |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 258 | .init = iwl_apm_init, |
Abhijeet Kolekar | d68b603 | 2009-10-02 13:44:04 -0700 | [diff] [blame] | 259 | .stop = iwl_apm_stop, |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 260 | .config = iwl6000_nic_config, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 261 | .set_pwr_src = iwl_set_pwr_src, |
| 262 | }, |
| 263 | .eeprom_ops = { |
| 264 | .regulatory_bands = { |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 265 | EEPROM_REG_BAND_1_CHANNELS, |
| 266 | EEPROM_REG_BAND_2_CHANNELS, |
| 267 | EEPROM_REG_BAND_3_CHANNELS, |
| 268 | EEPROM_REG_BAND_4_CHANNELS, |
| 269 | EEPROM_REG_BAND_5_CHANNELS, |
Shanyu Zhao | f2fa1b0 | 2010-04-07 18:37:52 -0700 | [diff] [blame] | 270 | EEPROM_6000_REG_BAND_24_HT40_CHANNELS, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 271 | EEPROM_REG_BAND_52_HT40_CHANNELS |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 272 | }, |
| 273 | .verify_signature = iwlcore_eeprom_verify_signature, |
| 274 | .acquire_semaphore = iwlcore_eeprom_acquire_semaphore, |
| 275 | .release_semaphore = iwlcore_eeprom_release_semaphore, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 276 | .calib_version = iwlagn_eeprom_calib_version, |
| 277 | .query_addr = iwlagn_eeprom_query_addr, |
Wey-Yi Guy | ab9fd1b | 2009-08-21 13:34:23 -0700 | [diff] [blame] | 278 | .update_enhanced_txpower = iwlcore_eeprom_enhanced_txpower, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 279 | }, |
| 280 | .post_associate = iwl_post_associate, |
| 281 | .isr = iwl_isr_ict, |
| 282 | .config_ap = iwl_config_ap, |
| 283 | .temp_ops = { |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 284 | .temperature = iwlagn_temperature, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 285 | .set_ct_kill = iwl6000_set_ct_threshold, |
| 286 | }, |
Reinette Chatre | 3459ab5 | 2010-01-22 14:22:49 -0800 | [diff] [blame] | 287 | .add_bcast_station = iwl_add_bcast_station, |
Abhijeet Kolekar | b8c7626 | 2010-04-08 15:29:07 -0700 | [diff] [blame^] | 288 | .debugfs_ops = { |
| 289 | .rx_stats_read = iwl_ucode_rx_stats_read, |
| 290 | .tx_stats_read = iwl_ucode_tx_stats_read, |
| 291 | .general_stats_read = iwl_ucode_general_stats_read, |
| 292 | }, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 293 | .recover_from_tx_stall = iwl_bg_monitor_recover, |
Wey-Yi Guy | fa8f130c | 2010-03-05 14:22:46 -0800 | [diff] [blame] | 294 | .check_plcp_health = iwl_good_plcp_health, |
| 295 | .check_ack_health = iwl_good_ack_health, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 296 | }; |
| 297 | |
Emese Revfy | 45d5d80 | 2009-12-14 00:59:53 +0100 | [diff] [blame] | 298 | static const struct iwl_ops iwl6000_ops = { |
Wey-Yi Guy | 792bc3c | 2010-03-16 10:23:29 -0700 | [diff] [blame] | 299 | .ucode = &iwlagn_ucode, |
Wey-Yi Guy | 672639d | 2009-07-24 11:13:01 -0700 | [diff] [blame] | 300 | .lib = &iwl6000_lib, |
Wey-Yi Guy | 7dc77db | 2010-03-16 10:23:31 -0700 | [diff] [blame] | 301 | .hcmd = &iwlagn_hcmd, |
| 302 | .utils = &iwlagn_hcmd_utils, |
Johannes Berg | e932a60 | 2009-10-02 13:44:03 -0700 | [diff] [blame] | 303 | .led = &iwlagn_led_ops, |
Jay Sternberg | 29f35c1 | 2009-01-29 11:09:16 -0800 | [diff] [blame] | 304 | }; |
| 305 | |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 306 | static struct iwl_lib_ops iwl6050_lib = { |
| 307 | .set_hw_params = iwl6000_hw_set_hw_params, |
Wey-Yi Guy | b305a08 | 2010-03-16 17:41:22 -0700 | [diff] [blame] | 308 | .txq_update_byte_cnt_tbl = iwlagn_txq_update_byte_cnt_tbl, |
| 309 | .txq_inval_byte_cnt_tbl = iwlagn_txq_inval_byte_cnt_tbl, |
| 310 | .txq_set_sched = iwlagn_txq_set_sched, |
| 311 | .txq_agg_enable = iwlagn_txq_agg_enable, |
| 312 | .txq_agg_disable = iwlagn_txq_agg_disable, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 313 | .txq_attach_buf_to_tfd = iwl_hw_txq_attach_buf_to_tfd, |
| 314 | .txq_free_tfd = iwl_hw_txq_free_tfd, |
| 315 | .txq_init = iwl_hw_tx_queue_init, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 316 | .rx_handler_setup = iwlagn_rx_handler_setup, |
| 317 | .setup_deferred_work = iwlagn_setup_deferred_work, |
| 318 | .is_valid_rtc_data_addr = iwlagn_hw_valid_rtc_data_addr, |
Wey-Yi Guy | 81b8176 | 2010-03-16 10:23:30 -0700 | [diff] [blame] | 319 | .load_ucode = iwlagn_load_ucode, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 320 | .dump_nic_event_log = iwl_dump_nic_event_log, |
| 321 | .dump_nic_error_log = iwl_dump_nic_error_log, |
| 322 | .dump_csr = iwl_dump_csr, |
| 323 | .dump_fh = iwl_dump_fh, |
Wey-Yi Guy | 741a626 | 2010-03-16 12:37:24 -0700 | [diff] [blame] | 324 | .init_alive_start = iwlagn_init_alive_start, |
| 325 | .alive_notify = iwlagn_alive_notify, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 326 | .send_tx_power = iwlagn_send_tx_power, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 327 | .update_chain_flags = iwl_update_chain_flags, |
| 328 | .set_channel_switch = iwl6000_hw_channel_switch, |
| 329 | .apm_ops = { |
| 330 | .init = iwl_apm_init, |
| 331 | .stop = iwl_apm_stop, |
| 332 | .config = iwl6000_nic_config, |
| 333 | .set_pwr_src = iwl_set_pwr_src, |
| 334 | }, |
| 335 | .eeprom_ops = { |
| 336 | .regulatory_bands = { |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 337 | EEPROM_REG_BAND_1_CHANNELS, |
| 338 | EEPROM_REG_BAND_2_CHANNELS, |
| 339 | EEPROM_REG_BAND_3_CHANNELS, |
| 340 | EEPROM_REG_BAND_4_CHANNELS, |
| 341 | EEPROM_REG_BAND_5_CHANNELS, |
Shanyu Zhao | f2fa1b0 | 2010-04-07 18:37:52 -0700 | [diff] [blame] | 342 | EEPROM_6000_REG_BAND_24_HT40_CHANNELS, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 343 | EEPROM_REG_BAND_52_HT40_CHANNELS |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 344 | }, |
| 345 | .verify_signature = iwlcore_eeprom_verify_signature, |
| 346 | .acquire_semaphore = iwlcore_eeprom_acquire_semaphore, |
| 347 | .release_semaphore = iwlcore_eeprom_release_semaphore, |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 348 | .calib_version = iwlagn_eeprom_calib_version, |
| 349 | .query_addr = iwlagn_eeprom_query_addr, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 350 | .update_enhanced_txpower = iwlcore_eeprom_enhanced_txpower, |
| 351 | }, |
| 352 | .post_associate = iwl_post_associate, |
| 353 | .isr = iwl_isr_ict, |
| 354 | .config_ap = iwl_config_ap, |
| 355 | .temp_ops = { |
Wey-Yi Guy | e04ed0a | 2010-03-16 17:47:58 -0700 | [diff] [blame] | 356 | .temperature = iwlagn_temperature, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 357 | .set_ct_kill = iwl6000_set_ct_threshold, |
| 358 | .set_calib_version = iwl6050_set_calib_version, |
| 359 | }, |
| 360 | .add_bcast_station = iwl_add_bcast_station, |
Abhijeet Kolekar | b8c7626 | 2010-04-08 15:29:07 -0700 | [diff] [blame^] | 361 | .debugfs_ops = { |
| 362 | .rx_stats_read = iwl_ucode_rx_stats_read, |
| 363 | .tx_stats_read = iwl_ucode_tx_stats_read, |
| 364 | .general_stats_read = iwl_ucode_general_stats_read, |
| 365 | }, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 366 | .recover_from_tx_stall = iwl_bg_monitor_recover, |
Wey-Yi Guy | fa8f130c | 2010-03-05 14:22:46 -0800 | [diff] [blame] | 367 | .check_plcp_health = iwl_good_plcp_health, |
| 368 | .check_ack_health = iwl_good_ack_health, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 369 | }; |
| 370 | |
| 371 | static const struct iwl_ops iwl6050_ops = { |
Wey-Yi Guy | 792bc3c | 2010-03-16 10:23:29 -0700 | [diff] [blame] | 372 | .ucode = &iwlagn_ucode, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 373 | .lib = &iwl6050_lib, |
Wey-Yi Guy | 7dc77db | 2010-03-16 10:23:31 -0700 | [diff] [blame] | 374 | .hcmd = &iwlagn_hcmd, |
| 375 | .utils = &iwlagn_hcmd_utils, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 376 | .led = &iwlagn_led_ops, |
| 377 | }; |
| 378 | |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 379 | /* |
| 380 | * "i": Internal configuration, use internal Power Amplifier |
| 381 | */ |
Shanyu Zhao | 4b3e806 | 2010-04-07 18:06:36 -0700 | [diff] [blame] | 382 | struct iwl_cfg iwl6000g2i_2agn_cfg = { |
Jay Sternberg | 0b5af20 | 2010-03-17 16:16:12 -0700 | [diff] [blame] | 383 | .name = "6000 Series 2x2 AGN Gen2", |
Shanyu Zhao | 4b3e806 | 2010-04-07 18:06:36 -0700 | [diff] [blame] | 384 | .fw_name_pre = IWL6000G2_FW_PRE, |
| 385 | .ucode_api_max = IWL6000G2_UCODE_API_MAX, |
| 386 | .ucode_api_min = IWL6000G2_UCODE_API_MIN, |
Jay Sternberg | 0b5af20 | 2010-03-17 16:16:12 -0700 | [diff] [blame] | 387 | .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, |
| 388 | .ops = &iwl6000_ops, |
| 389 | .eeprom_size = OTP_LOW_IMAGE_SIZE, |
Shanyu Zhao | 4b3e806 | 2010-04-07 18:06:36 -0700 | [diff] [blame] | 390 | .eeprom_ver = EEPROM_6000G2_EEPROM_VERSION, |
| 391 | .eeprom_calib_ver = EEPROM_6000G2_TX_POWER_VERSION, |
Jay Sternberg | 0b5af20 | 2010-03-17 16:16:12 -0700 | [diff] [blame] | 392 | .num_of_queues = IWLAGN_NUM_QUEUES, |
| 393 | .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, |
| 394 | .mod_params = &iwlagn_mod_params, |
| 395 | .valid_tx_ant = ANT_AB, |
| 396 | .valid_rx_ant = ANT_AB, |
| 397 | .pll_cfg_val = 0, |
| 398 | .set_l0s = true, |
| 399 | .use_bsm = false, |
| 400 | .pa_type = IWL_PA_INTERNAL, |
| 401 | .max_ll_items = OTP_MAX_LL_ITEMS_6x00, |
| 402 | .shadow_ram_support = true, |
| 403 | .ht_greenfield_support = true, |
| 404 | .led_compensation = 51, |
| 405 | .use_rts_for_ht = true, /* use rts/cts protection */ |
| 406 | .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, |
| 407 | .supports_idle = true, |
| 408 | .adv_thermal_throttle = true, |
| 409 | .support_ct_kill_exit = true, |
| 410 | .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF, |
| 411 | .chain_noise_scale = 1000, |
| 412 | .monitor_recover_period = IWL_MONITORING_PERIOD, |
Wey-Yi Guy | 678b385 | 2010-03-26 12:54:37 -0700 | [diff] [blame] | 413 | .max_event_log_size = 1024, |
Jay Sternberg | 0b5af20 | 2010-03-17 16:16:12 -0700 | [diff] [blame] | 414 | }; |
| 415 | |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 416 | struct iwl_cfg iwl6000i_2agn_cfg = { |
Shanyu Zhao | c11362c | 2010-03-05 17:05:20 -0800 | [diff] [blame] | 417 | .name = "Intel(R) Centrino(R) Advanced-N 6200 AGN", |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 418 | .fw_name_pre = IWL6000_FW_PRE, |
| 419 | .ucode_api_max = IWL6000_UCODE_API_MAX, |
| 420 | .ucode_api_min = IWL6000_UCODE_API_MIN, |
| 421 | .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, |
| 422 | .ops = &iwl6000_ops, |
Wey-Yi Guy | 415e499 | 2009-08-13 13:30:54 -0700 | [diff] [blame] | 423 | .eeprom_size = OTP_LOW_IMAGE_SIZE, |
Wey-Yi Guy | 1f4b966 | 2009-09-17 10:43:46 -0700 | [diff] [blame] | 424 | .eeprom_ver = EEPROM_6000_EEPROM_VERSION, |
Wey-Yi Guy | 00e7059 | 2010-03-16 12:37:26 -0700 | [diff] [blame] | 425 | .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION, |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 426 | .num_of_queues = IWLAGN_NUM_QUEUES, |
| 427 | .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, |
Wey-Yi Guy | 348ee7cd | 2010-03-16 12:37:27 -0700 | [diff] [blame] | 428 | .mod_params = &iwlagn_mod_params, |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 429 | .valid_tx_ant = ANT_BC, |
| 430 | .valid_rx_ant = ANT_BC, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 431 | .pll_cfg_val = 0, |
Ben Cahill | a6c5c73 | 2009-10-30 14:36:07 -0700 | [diff] [blame] | 432 | .set_l0s = true, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 433 | .use_bsm = false, |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 434 | .pa_type = IWL_PA_INTERNAL, |
Wey-Yi Guy | 415e499 | 2009-08-13 13:30:54 -0700 | [diff] [blame] | 435 | .max_ll_items = OTP_MAX_LL_ITEMS_6x00, |
| 436 | .shadow_ram_support = true, |
Daniel C Halperin | b261793 | 2009-08-13 13:30:59 -0700 | [diff] [blame] | 437 | .ht_greenfield_support = true, |
Wey-Yi Guy | f2d0d0e | 2009-09-11 10:38:14 -0700 | [diff] [blame] | 438 | .led_compensation = 51, |
Wey-Yi Guy | 47eef9b | 2009-09-17 10:43:44 -0700 | [diff] [blame] | 439 | .use_rts_for_ht = true, /* use rts/cts protection */ |
Wey-Yi Guy | d8c07e7 | 2009-09-25 14:24:26 -0700 | [diff] [blame] | 440 | .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, |
Johannes Berg | 78f5fb7 | 2009-09-25 14:24:27 -0700 | [diff] [blame] | 441 | .supports_idle = true, |
Wey-Yi Guy | 6047b4f | 2009-10-23 13:42:27 -0700 | [diff] [blame] | 442 | .adv_thermal_throttle = true, |
Wey-Yi Guy | 480e840 | 2009-10-23 13:42:28 -0700 | [diff] [blame] | 443 | .support_ct_kill_exit = true, |
Trieu 'Andrew' Nguyen | 3e4fb5f | 2010-01-22 14:22:46 -0800 | [diff] [blame] | 444 | .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF, |
Ben Cahill | d4fe5ac | 2010-02-05 11:33:46 -0800 | [diff] [blame] | 445 | .chain_noise_scale = 1000, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 446 | .monitor_recover_period = IWL_MONITORING_PERIOD, |
Wey-Yi Guy | 678b385 | 2010-03-26 12:54:37 -0700 | [diff] [blame] | 447 | .max_event_log_size = 1024, |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 448 | }; |
| 449 | |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 450 | struct iwl_cfg iwl6000i_2abg_cfg = { |
Shanyu Zhao | c11362c | 2010-03-05 17:05:20 -0800 | [diff] [blame] | 451 | .name = "Intel(R) Centrino(R) Advanced-N 6200 ABG", |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 452 | .fw_name_pre = IWL6000_FW_PRE, |
| 453 | .ucode_api_max = IWL6000_UCODE_API_MAX, |
| 454 | .ucode_api_min = IWL6000_UCODE_API_MIN, |
| 455 | .sku = IWL_SKU_A|IWL_SKU_G, |
| 456 | .ops = &iwl6000_ops, |
| 457 | .eeprom_size = OTP_LOW_IMAGE_SIZE, |
| 458 | .eeprom_ver = EEPROM_6000_EEPROM_VERSION, |
Wey-Yi Guy | 00e7059 | 2010-03-16 12:37:26 -0700 | [diff] [blame] | 459 | .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION, |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 460 | .num_of_queues = IWLAGN_NUM_QUEUES, |
| 461 | .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, |
Wey-Yi Guy | 348ee7cd | 2010-03-16 12:37:27 -0700 | [diff] [blame] | 462 | .mod_params = &iwlagn_mod_params, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 463 | .valid_tx_ant = ANT_BC, |
| 464 | .valid_rx_ant = ANT_BC, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 465 | .pll_cfg_val = 0, |
Ben Cahill | a6c5c73 | 2009-10-30 14:36:07 -0700 | [diff] [blame] | 466 | .set_l0s = true, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 467 | .use_bsm = false, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 468 | .pa_type = IWL_PA_INTERNAL, |
| 469 | .max_ll_items = OTP_MAX_LL_ITEMS_6x00, |
| 470 | .shadow_ram_support = true, |
| 471 | .ht_greenfield_support = true, |
| 472 | .led_compensation = 51, |
Wey-Yi Guy | d8c07e7 | 2009-09-25 14:24:26 -0700 | [diff] [blame] | 473 | .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, |
Johannes Berg | 78f5fb7 | 2009-09-25 14:24:27 -0700 | [diff] [blame] | 474 | .supports_idle = true, |
Wey-Yi Guy | 6047b4f | 2009-10-23 13:42:27 -0700 | [diff] [blame] | 475 | .adv_thermal_throttle = true, |
Wey-Yi Guy | 480e840 | 2009-10-23 13:42:28 -0700 | [diff] [blame] | 476 | .support_ct_kill_exit = true, |
Trieu 'Andrew' Nguyen | 3e4fb5f | 2010-01-22 14:22:46 -0800 | [diff] [blame] | 477 | .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF, |
Ben Cahill | d4fe5ac | 2010-02-05 11:33:46 -0800 | [diff] [blame] | 478 | .chain_noise_scale = 1000, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 479 | .monitor_recover_period = IWL_MONITORING_PERIOD, |
Wey-Yi Guy | 678b385 | 2010-03-26 12:54:37 -0700 | [diff] [blame] | 480 | .max_event_log_size = 1024, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 481 | }; |
| 482 | |
| 483 | struct iwl_cfg iwl6000i_2bg_cfg = { |
Shanyu Zhao | c11362c | 2010-03-05 17:05:20 -0800 | [diff] [blame] | 484 | .name = "Intel(R) Centrino(R) Advanced-N 6200 BG", |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 485 | .fw_name_pre = IWL6000_FW_PRE, |
| 486 | .ucode_api_max = IWL6000_UCODE_API_MAX, |
| 487 | .ucode_api_min = IWL6000_UCODE_API_MIN, |
| 488 | .sku = IWL_SKU_G, |
| 489 | .ops = &iwl6000_ops, |
| 490 | .eeprom_size = OTP_LOW_IMAGE_SIZE, |
| 491 | .eeprom_ver = EEPROM_6000_EEPROM_VERSION, |
Wey-Yi Guy | 00e7059 | 2010-03-16 12:37:26 -0700 | [diff] [blame] | 492 | .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION, |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 493 | .num_of_queues = IWLAGN_NUM_QUEUES, |
| 494 | .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, |
Wey-Yi Guy | 348ee7cd | 2010-03-16 12:37:27 -0700 | [diff] [blame] | 495 | .mod_params = &iwlagn_mod_params, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 496 | .valid_tx_ant = ANT_BC, |
| 497 | .valid_rx_ant = ANT_BC, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 498 | .pll_cfg_val = 0, |
Ben Cahill | a6c5c73 | 2009-10-30 14:36:07 -0700 | [diff] [blame] | 499 | .set_l0s = true, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 500 | .use_bsm = false, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 501 | .pa_type = IWL_PA_INTERNAL, |
| 502 | .max_ll_items = OTP_MAX_LL_ITEMS_6x00, |
| 503 | .shadow_ram_support = true, |
| 504 | .ht_greenfield_support = true, |
| 505 | .led_compensation = 51, |
Wey-Yi Guy | d8c07e7 | 2009-09-25 14:24:26 -0700 | [diff] [blame] | 506 | .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, |
Johannes Berg | 78f5fb7 | 2009-09-25 14:24:27 -0700 | [diff] [blame] | 507 | .supports_idle = true, |
Wey-Yi Guy | 6047b4f | 2009-10-23 13:42:27 -0700 | [diff] [blame] | 508 | .adv_thermal_throttle = true, |
Wey-Yi Guy | 480e840 | 2009-10-23 13:42:28 -0700 | [diff] [blame] | 509 | .support_ct_kill_exit = true, |
Trieu 'Andrew' Nguyen | 3e4fb5f | 2010-01-22 14:22:46 -0800 | [diff] [blame] | 510 | .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF, |
Ben Cahill | d4fe5ac | 2010-02-05 11:33:46 -0800 | [diff] [blame] | 511 | .chain_noise_scale = 1000, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 512 | .monitor_recover_period = IWL_MONITORING_PERIOD, |
Wey-Yi Guy | 678b385 | 2010-03-26 12:54:37 -0700 | [diff] [blame] | 513 | .max_event_log_size = 1024, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 514 | }; |
| 515 | |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 516 | struct iwl_cfg iwl6050_2agn_cfg = { |
Shanyu Zhao | c11362c | 2010-03-05 17:05:20 -0800 | [diff] [blame] | 517 | .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 AGN", |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 518 | .fw_name_pre = IWL6050_FW_PRE, |
| 519 | .ucode_api_max = IWL6050_UCODE_API_MAX, |
| 520 | .ucode_api_min = IWL6050_UCODE_API_MIN, |
| 521 | .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 522 | .ops = &iwl6050_ops, |
Wey-Yi Guy | 415e499 | 2009-08-13 13:30:54 -0700 | [diff] [blame] | 523 | .eeprom_size = OTP_LOW_IMAGE_SIZE, |
Wey-Yi Guy | 32b7e24 | 2009-10-16 14:25:51 -0700 | [diff] [blame] | 524 | .eeprom_ver = EEPROM_6050_EEPROM_VERSION, |
Wey-Yi Guy | 00e7059 | 2010-03-16 12:37:26 -0700 | [diff] [blame] | 525 | .eeprom_calib_ver = EEPROM_6050_TX_POWER_VERSION, |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 526 | .num_of_queues = IWLAGN_NUM_QUEUES, |
| 527 | .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, |
Wey-Yi Guy | 348ee7cd | 2010-03-16 12:37:27 -0700 | [diff] [blame] | 528 | .mod_params = &iwlagn_mod_params, |
Jay Sternberg | 542cc79 | 2009-05-08 13:44:46 -0700 | [diff] [blame] | 529 | .valid_tx_ant = ANT_AB, |
| 530 | .valid_rx_ant = ANT_AB, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 531 | .pll_cfg_val = 0, |
Ben Cahill | a6c5c73 | 2009-10-30 14:36:07 -0700 | [diff] [blame] | 532 | .set_l0s = true, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 533 | .use_bsm = false, |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 534 | .pa_type = IWL_PA_SYSTEM, |
Wey-Yi Guy | 3ab312a | 2009-10-16 14:25:52 -0700 | [diff] [blame] | 535 | .max_ll_items = OTP_MAX_LL_ITEMS_6x50, |
Wey-Yi Guy | 415e499 | 2009-08-13 13:30:54 -0700 | [diff] [blame] | 536 | .shadow_ram_support = true, |
Daniel C Halperin | b261793 | 2009-08-13 13:30:59 -0700 | [diff] [blame] | 537 | .ht_greenfield_support = true, |
Wey-Yi Guy | f2d0d0e | 2009-09-11 10:38:14 -0700 | [diff] [blame] | 538 | .led_compensation = 51, |
Wey-Yi Guy | 47eef9b | 2009-09-17 10:43:44 -0700 | [diff] [blame] | 539 | .use_rts_for_ht = true, /* use rts/cts protection */ |
Wey-Yi Guy | d8c07e7 | 2009-09-25 14:24:26 -0700 | [diff] [blame] | 540 | .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, |
Johannes Berg | 78f5fb7 | 2009-09-25 14:24:27 -0700 | [diff] [blame] | 541 | .supports_idle = true, |
Wey-Yi Guy | 6047b4f | 2009-10-23 13:42:27 -0700 | [diff] [blame] | 542 | .adv_thermal_throttle = true, |
Wey-Yi Guy | 480e840 | 2009-10-23 13:42:28 -0700 | [diff] [blame] | 543 | .support_ct_kill_exit = true, |
Trieu 'Andrew' Nguyen | 3e4fb5f | 2010-01-22 14:22:46 -0800 | [diff] [blame] | 544 | .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF, |
Ben Cahill | d4fe5ac | 2010-02-05 11:33:46 -0800 | [diff] [blame] | 545 | .chain_noise_scale = 1500, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 546 | .monitor_recover_period = IWL_MONITORING_PERIOD, |
Wey-Yi Guy | 678b385 | 2010-03-26 12:54:37 -0700 | [diff] [blame] | 547 | .max_event_log_size = 1024, |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 548 | }; |
| 549 | |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 550 | struct iwl_cfg iwl6050_2abg_cfg = { |
Shanyu Zhao | c11362c | 2010-03-05 17:05:20 -0800 | [diff] [blame] | 551 | .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 ABG", |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 552 | .fw_name_pre = IWL6050_FW_PRE, |
| 553 | .ucode_api_max = IWL6050_UCODE_API_MAX, |
| 554 | .ucode_api_min = IWL6050_UCODE_API_MIN, |
| 555 | .sku = IWL_SKU_A|IWL_SKU_G, |
Abhijeet Kolekar | d575593 | 2010-02-18 22:03:05 -0800 | [diff] [blame] | 556 | .ops = &iwl6050_ops, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 557 | .eeprom_size = OTP_LOW_IMAGE_SIZE, |
Wey-Yi Guy | 32b7e24 | 2009-10-16 14:25:51 -0700 | [diff] [blame] | 558 | .eeprom_ver = EEPROM_6050_EEPROM_VERSION, |
Wey-Yi Guy | 00e7059 | 2010-03-16 12:37:26 -0700 | [diff] [blame] | 559 | .eeprom_calib_ver = EEPROM_6050_TX_POWER_VERSION, |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 560 | .num_of_queues = IWLAGN_NUM_QUEUES, |
| 561 | .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, |
Wey-Yi Guy | 348ee7cd | 2010-03-16 12:37:27 -0700 | [diff] [blame] | 562 | .mod_params = &iwlagn_mod_params, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 563 | .valid_tx_ant = ANT_AB, |
| 564 | .valid_rx_ant = ANT_AB, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 565 | .pll_cfg_val = 0, |
Ben Cahill | a6c5c73 | 2009-10-30 14:36:07 -0700 | [diff] [blame] | 566 | .set_l0s = true, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 567 | .use_bsm = false, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 568 | .pa_type = IWL_PA_SYSTEM, |
Wey-Yi Guy | 3ab312a | 2009-10-16 14:25:52 -0700 | [diff] [blame] | 569 | .max_ll_items = OTP_MAX_LL_ITEMS_6x50, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 570 | .shadow_ram_support = true, |
| 571 | .ht_greenfield_support = true, |
| 572 | .led_compensation = 51, |
Wey-Yi Guy | d8c07e7 | 2009-09-25 14:24:26 -0700 | [diff] [blame] | 573 | .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, |
Johannes Berg | 78f5fb7 | 2009-09-25 14:24:27 -0700 | [diff] [blame] | 574 | .supports_idle = true, |
Wey-Yi Guy | 6047b4f | 2009-10-23 13:42:27 -0700 | [diff] [blame] | 575 | .adv_thermal_throttle = true, |
Wey-Yi Guy | 480e840 | 2009-10-23 13:42:28 -0700 | [diff] [blame] | 576 | .support_ct_kill_exit = true, |
Trieu 'Andrew' Nguyen | 3e4fb5f | 2010-01-22 14:22:46 -0800 | [diff] [blame] | 577 | .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF, |
Ben Cahill | d4fe5ac | 2010-02-05 11:33:46 -0800 | [diff] [blame] | 578 | .chain_noise_scale = 1500, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 579 | .monitor_recover_period = IWL_MONITORING_PERIOD, |
Wey-Yi Guy | 678b385 | 2010-03-26 12:54:37 -0700 | [diff] [blame] | 580 | .max_event_log_size = 1024, |
Wey-Yi Guy | 5953a62 | 2009-09-17 10:43:53 -0700 | [diff] [blame] | 581 | }; |
| 582 | |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 583 | struct iwl_cfg iwl6000_3agn_cfg = { |
Shanyu Zhao | c11362c | 2010-03-05 17:05:20 -0800 | [diff] [blame] | 584 | .name = "Intel(R) Centrino(R) Ultimate-N 6300 AGN", |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 585 | .fw_name_pre = IWL6000_FW_PRE, |
| 586 | .ucode_api_max = IWL6000_UCODE_API_MAX, |
| 587 | .ucode_api_min = IWL6000_UCODE_API_MIN, |
| 588 | .sku = IWL_SKU_A|IWL_SKU_G|IWL_SKU_N, |
Jay Sternberg | 29f35c1 | 2009-01-29 11:09:16 -0800 | [diff] [blame] | 589 | .ops = &iwl6000_ops, |
Wey-Yi Guy | 415e499 | 2009-08-13 13:30:54 -0700 | [diff] [blame] | 590 | .eeprom_size = OTP_LOW_IMAGE_SIZE, |
Wey-Yi Guy | 1f4b966 | 2009-09-17 10:43:46 -0700 | [diff] [blame] | 591 | .eeprom_ver = EEPROM_6000_EEPROM_VERSION, |
Wey-Yi Guy | 00e7059 | 2010-03-16 12:37:26 -0700 | [diff] [blame] | 592 | .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION, |
Wey-Yi Guy | 19e6cda | 2010-03-16 17:41:23 -0700 | [diff] [blame] | 593 | .num_of_queues = IWLAGN_NUM_QUEUES, |
| 594 | .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES, |
Wey-Yi Guy | 348ee7cd | 2010-03-16 12:37:27 -0700 | [diff] [blame] | 595 | .mod_params = &iwlagn_mod_params, |
Jay Sternberg | c0bac76 | 2009-02-02 16:21:14 -0800 | [diff] [blame] | 596 | .valid_tx_ant = ANT_ABC, |
| 597 | .valid_rx_ant = ANT_ABC, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 598 | .pll_cfg_val = 0, |
Ben Cahill | a6c5c73 | 2009-10-30 14:36:07 -0700 | [diff] [blame] | 599 | .set_l0s = true, |
Ben Cahill | fadb358 | 2009-10-23 13:42:21 -0700 | [diff] [blame] | 600 | .use_bsm = false, |
Wey-Yi Guy | 65b7998 | 2009-07-31 14:28:07 -0700 | [diff] [blame] | 601 | .pa_type = IWL_PA_SYSTEM, |
Wey-Yi Guy | 415e499 | 2009-08-13 13:30:54 -0700 | [diff] [blame] | 602 | .max_ll_items = OTP_MAX_LL_ITEMS_6x00, |
| 603 | .shadow_ram_support = true, |
Daniel C Halperin | b261793 | 2009-08-13 13:30:59 -0700 | [diff] [blame] | 604 | .ht_greenfield_support = true, |
Wey-Yi Guy | f2d0d0e | 2009-09-11 10:38:14 -0700 | [diff] [blame] | 605 | .led_compensation = 51, |
Wey-Yi Guy | 47eef9b | 2009-09-17 10:43:44 -0700 | [diff] [blame] | 606 | .use_rts_for_ht = true, /* use rts/cts protection */ |
Wey-Yi Guy | d8c07e7 | 2009-09-25 14:24:26 -0700 | [diff] [blame] | 607 | .chain_noise_num_beacons = IWL_CAL_NUM_BEACONS, |
Johannes Berg | 78f5fb7 | 2009-09-25 14:24:27 -0700 | [diff] [blame] | 608 | .supports_idle = true, |
Wey-Yi Guy | 6047b4f | 2009-10-23 13:42:27 -0700 | [diff] [blame] | 609 | .adv_thermal_throttle = true, |
Wey-Yi Guy | 480e840 | 2009-10-23 13:42:28 -0700 | [diff] [blame] | 610 | .support_ct_kill_exit = true, |
Trieu 'Andrew' Nguyen | 3e4fb5f | 2010-01-22 14:22:46 -0800 | [diff] [blame] | 611 | .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF, |
Ben Cahill | d4fe5ac | 2010-02-05 11:33:46 -0800 | [diff] [blame] | 612 | .chain_noise_scale = 1000, |
Wey-Yi Guy | b74e31a | 2010-03-01 17:23:50 -0800 | [diff] [blame] | 613 | .monitor_recover_period = IWL_MONITORING_PERIOD, |
Wey-Yi Guy | 678b385 | 2010-03-26 12:54:37 -0700 | [diff] [blame] | 614 | .max_event_log_size = 1024, |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 615 | }; |
| 616 | |
Jay Sternberg | e122837 | 2009-01-19 15:30:34 -0800 | [diff] [blame] | 617 | MODULE_FIRMWARE(IWL6000_MODULE_FIRMWARE(IWL6000_UCODE_API_MAX)); |
| 618 | MODULE_FIRMWARE(IWL6050_MODULE_FIRMWARE(IWL6050_UCODE_API_MAX)); |
Shanyu Zhao | 4b3e806 | 2010-04-07 18:06:36 -0700 | [diff] [blame] | 619 | MODULE_FIRMWARE(IWL6000G2_MODULE_FIRMWARE(IWL6000G2_UCODE_API_MAX)); |