iwl-6000.c 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599
  1. /******************************************************************************
  2. *
  3. * Copyright(c) 2008 - 2012 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. #include <linux/kernel.h>
  27. #include <linux/module.h>
  28. #include <linux/init.h>
  29. #include <linux/delay.h>
  30. #include <linux/skbuff.h>
  31. #include <linux/netdevice.h>
  32. #include <net/mac80211.h>
  33. #include <linux/etherdevice.h>
  34. #include <asm/unaligned.h>
  35. #include <linux/stringify.h>
  36. #include "iwl-eeprom.h"
  37. #include "iwl-dev.h"
  38. #include "iwl-core.h"
  39. #include "iwl-io.h"
  40. #include "iwl-agn.h"
  41. #include "iwl-agn-hw.h"
  42. #include "iwl-trans.h"
  43. #include "iwl-shared.h"
  44. #include "iwl-cfg.h"
  45. /* Highest firmware API version supported */
  46. #define IWL6000_UCODE_API_MAX 6
  47. #define IWL6050_UCODE_API_MAX 5
  48. #define IWL6000G2_UCODE_API_MAX 6
  49. #define IWL6035_UCODE_API_MAX 6
  50. /* Oldest version we won't warn about */
  51. #define IWL6000_UCODE_API_OK 4
  52. #define IWL6000G2_UCODE_API_OK 5
  53. #define IWL6050_UCODE_API_OK 5
  54. #define IWL6000G2B_UCODE_API_OK 6
  55. #define IWL6035_UCODE_API_OK 6
  56. /* Lowest firmware API version supported */
  57. #define IWL6000_UCODE_API_MIN 4
  58. #define IWL6050_UCODE_API_MIN 4
  59. #define IWL6000G2_UCODE_API_MIN 5
  60. #define IWL6035_UCODE_API_MIN 6
  61. #define IWL6000_FW_PRE "iwlwifi-6000-"
  62. #define IWL6000_MODULE_FIRMWARE(api) IWL6000_FW_PRE __stringify(api) ".ucode"
  63. #define IWL6050_FW_PRE "iwlwifi-6050-"
  64. #define IWL6050_MODULE_FIRMWARE(api) IWL6050_FW_PRE __stringify(api) ".ucode"
  65. #define IWL6005_FW_PRE "iwlwifi-6000g2a-"
  66. #define IWL6005_MODULE_FIRMWARE(api) IWL6005_FW_PRE __stringify(api) ".ucode"
  67. #define IWL6030_FW_PRE "iwlwifi-6000g2b-"
  68. #define IWL6030_MODULE_FIRMWARE(api) IWL6030_FW_PRE __stringify(api) ".ucode"
  69. static void iwl6000_set_ct_threshold(struct iwl_priv *priv)
  70. {
  71. /* want Celsius */
  72. hw_params(priv).ct_kill_threshold = CT_KILL_THRESHOLD;
  73. hw_params(priv).ct_kill_exit_threshold = CT_KILL_EXIT_THRESHOLD;
  74. }
  75. static void iwl6050_additional_nic_config(struct iwl_priv *priv)
  76. {
  77. /* Indicate calibration version to uCode. */
  78. if (iwl_eeprom_calib_version(priv->shrd) >= 6)
  79. iwl_set_bit(trans(priv), CSR_GP_DRIVER_REG,
  80. CSR_GP_DRIVER_REG_BIT_CALIB_VERSION6);
  81. }
  82. static void iwl6150_additional_nic_config(struct iwl_priv *priv)
  83. {
  84. /* Indicate calibration version to uCode. */
  85. if (iwl_eeprom_calib_version(priv->shrd) >= 6)
  86. iwl_set_bit(trans(priv), CSR_GP_DRIVER_REG,
  87. CSR_GP_DRIVER_REG_BIT_CALIB_VERSION6);
  88. iwl_set_bit(trans(priv), CSR_GP_DRIVER_REG,
  89. CSR_GP_DRIVER_REG_BIT_6050_1x2);
  90. }
  91. static void iwl6000i_additional_nic_config(struct iwl_priv *priv)
  92. {
  93. /* 2x2 IPA phy type */
  94. iwl_write32(trans(priv), CSR_GP_DRIVER_REG,
  95. CSR_GP_DRIVER_REG_BIT_RADIO_SKU_2x2_IPA);
  96. }
  97. /* NIC configuration for 6000 series */
  98. static void iwl6000_nic_config(struct iwl_priv *priv)
  99. {
  100. iwl_rf_config(priv);
  101. /* do additional nic configuration if needed */
  102. if (cfg(priv)->additional_nic_config)
  103. cfg(priv)->additional_nic_config(priv);
  104. }
  105. static const struct iwl_sensitivity_ranges iwl6000_sensitivity = {
  106. .min_nrg_cck = 110,
  107. .auto_corr_min_ofdm = 80,
  108. .auto_corr_min_ofdm_mrc = 128,
  109. .auto_corr_min_ofdm_x1 = 105,
  110. .auto_corr_min_ofdm_mrc_x1 = 192,
  111. .auto_corr_max_ofdm = 145,
  112. .auto_corr_max_ofdm_mrc = 232,
  113. .auto_corr_max_ofdm_x1 = 110,
  114. .auto_corr_max_ofdm_mrc_x1 = 232,
  115. .auto_corr_min_cck = 125,
  116. .auto_corr_max_cck = 175,
  117. .auto_corr_min_cck_mrc = 160,
  118. .auto_corr_max_cck_mrc = 310,
  119. .nrg_th_cck = 110,
  120. .nrg_th_ofdm = 110,
  121. .barker_corr_th_min = 190,
  122. .barker_corr_th_min_mrc = 336,
  123. .nrg_th_cca = 62,
  124. };
  125. static void iwl6000_hw_set_hw_params(struct iwl_priv *priv)
  126. {
  127. hw_params(priv).ht40_channel = BIT(IEEE80211_BAND_2GHZ) |
  128. BIT(IEEE80211_BAND_5GHZ);
  129. hw_params(priv).tx_chains_num =
  130. num_of_ant(hw_params(priv).valid_tx_ant);
  131. if (cfg(priv)->rx_with_siso_diversity)
  132. hw_params(priv).rx_chains_num = 1;
  133. else
  134. hw_params(priv).rx_chains_num =
  135. num_of_ant(hw_params(priv).valid_rx_ant);
  136. iwl6000_set_ct_threshold(priv);
  137. /* Set initial sensitivity parameters */
  138. hw_params(priv).sens = &iwl6000_sensitivity;
  139. }
  140. static int iwl6000_hw_channel_switch(struct iwl_priv *priv,
  141. struct ieee80211_channel_switch *ch_switch)
  142. {
  143. /*
  144. * MULTI-FIXME
  145. * See iwlagn_mac_channel_switch.
  146. */
  147. struct iwl_rxon_context *ctx = &priv->contexts[IWL_RXON_CTX_BSS];
  148. struct iwl6000_channel_switch_cmd *cmd;
  149. const struct iwl_channel_info *ch_info;
  150. u32 switch_time_in_usec, ucode_switch_time;
  151. u16 ch;
  152. u32 tsf_low;
  153. u8 switch_count;
  154. u16 beacon_interval = le16_to_cpu(ctx->timing.beacon_interval);
  155. struct ieee80211_vif *vif = ctx->vif;
  156. struct iwl_host_cmd hcmd = {
  157. .id = REPLY_CHANNEL_SWITCH,
  158. .len = { sizeof(*cmd), },
  159. .flags = CMD_SYNC,
  160. .dataflags[0] = IWL_HCMD_DFL_NOCOPY,
  161. };
  162. int err;
  163. cmd = kzalloc(sizeof(*cmd), GFP_KERNEL);
  164. if (!cmd)
  165. return -ENOMEM;
  166. hcmd.data[0] = cmd;
  167. cmd->band = priv->band == IEEE80211_BAND_2GHZ;
  168. ch = ch_switch->channel->hw_value;
  169. IWL_DEBUG_11H(priv, "channel switch from %u to %u\n",
  170. ctx->active.channel, ch);
  171. cmd->channel = cpu_to_le16(ch);
  172. cmd->rxon_flags = ctx->staging.flags;
  173. cmd->rxon_filter_flags = ctx->staging.filter_flags;
  174. switch_count = ch_switch->count;
  175. tsf_low = ch_switch->timestamp & 0x0ffffffff;
  176. /*
  177. * calculate the ucode channel switch time
  178. * adding TSF as one of the factor for when to switch
  179. */
  180. if ((priv->ucode_beacon_time > tsf_low) && beacon_interval) {
  181. if (switch_count > ((priv->ucode_beacon_time - tsf_low) /
  182. beacon_interval)) {
  183. switch_count -= (priv->ucode_beacon_time -
  184. tsf_low) / beacon_interval;
  185. } else
  186. switch_count = 0;
  187. }
  188. if (switch_count <= 1)
  189. cmd->switch_time = cpu_to_le32(priv->ucode_beacon_time);
  190. else {
  191. switch_time_in_usec =
  192. vif->bss_conf.beacon_int * switch_count * TIME_UNIT;
  193. ucode_switch_time = iwl_usecs_to_beacons(priv,
  194. switch_time_in_usec,
  195. beacon_interval);
  196. cmd->switch_time = iwl_add_beacon_time(priv,
  197. priv->ucode_beacon_time,
  198. ucode_switch_time,
  199. beacon_interval);
  200. }
  201. IWL_DEBUG_11H(priv, "uCode time for the switch is 0x%x\n",
  202. cmd->switch_time);
  203. ch_info = iwl_get_channel_info(priv, priv->band, ch);
  204. if (ch_info)
  205. cmd->expect_beacon = is_channel_radar(ch_info);
  206. else {
  207. IWL_ERR(priv, "invalid channel switch from %u to %u\n",
  208. ctx->active.channel, ch);
  209. return -EFAULT;
  210. }
  211. err = iwl_dvm_send_cmd(priv, &hcmd);
  212. kfree(cmd);
  213. return err;
  214. }
  215. static struct iwl_lib_ops iwl6000_lib = {
  216. .set_hw_params = iwl6000_hw_set_hw_params,
  217. .set_channel_switch = iwl6000_hw_channel_switch,
  218. .nic_config = iwl6000_nic_config,
  219. .eeprom_ops = {
  220. .regulatory_bands = {
  221. EEPROM_REG_BAND_1_CHANNELS,
  222. EEPROM_REG_BAND_2_CHANNELS,
  223. EEPROM_REG_BAND_3_CHANNELS,
  224. EEPROM_REG_BAND_4_CHANNELS,
  225. EEPROM_REG_BAND_5_CHANNELS,
  226. EEPROM_6000_REG_BAND_24_HT40_CHANNELS,
  227. EEPROM_REG_BAND_52_HT40_CHANNELS
  228. },
  229. .enhanced_txpower = true,
  230. },
  231. .temperature = iwlagn_temperature,
  232. };
  233. static struct iwl_lib_ops iwl6030_lib = {
  234. .set_hw_params = iwl6000_hw_set_hw_params,
  235. .set_channel_switch = iwl6000_hw_channel_switch,
  236. .nic_config = iwl6000_nic_config,
  237. .eeprom_ops = {
  238. .regulatory_bands = {
  239. EEPROM_REG_BAND_1_CHANNELS,
  240. EEPROM_REG_BAND_2_CHANNELS,
  241. EEPROM_REG_BAND_3_CHANNELS,
  242. EEPROM_REG_BAND_4_CHANNELS,
  243. EEPROM_REG_BAND_5_CHANNELS,
  244. EEPROM_6000_REG_BAND_24_HT40_CHANNELS,
  245. EEPROM_REG_BAND_52_HT40_CHANNELS
  246. },
  247. .enhanced_txpower = true,
  248. },
  249. .temperature = iwlagn_temperature,
  250. };
  251. static const struct iwl_base_params iwl6000_base_params = {
  252. .eeprom_size = OTP_LOW_IMAGE_SIZE,
  253. .num_of_queues = IWLAGN_NUM_QUEUES,
  254. .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
  255. .pll_cfg_val = 0,
  256. .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
  257. .shadow_ram_support = true,
  258. .led_compensation = 51,
  259. .adv_thermal_throttle = true,
  260. .support_ct_kill_exit = true,
  261. .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
  262. .chain_noise_scale = 1000,
  263. .wd_timeout = IWL_DEF_WD_TIMEOUT,
  264. .max_event_log_size = 512,
  265. .shadow_reg_enable = false, /* TODO: fix bugs using this feature */
  266. };
  267. static const struct iwl_base_params iwl6050_base_params = {
  268. .eeprom_size = OTP_LOW_IMAGE_SIZE,
  269. .num_of_queues = IWLAGN_NUM_QUEUES,
  270. .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
  271. .pll_cfg_val = 0,
  272. .max_ll_items = OTP_MAX_LL_ITEMS_6x50,
  273. .shadow_ram_support = true,
  274. .led_compensation = 51,
  275. .adv_thermal_throttle = true,
  276. .support_ct_kill_exit = true,
  277. .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
  278. .chain_noise_scale = 1500,
  279. .wd_timeout = IWL_DEF_WD_TIMEOUT,
  280. .max_event_log_size = 1024,
  281. .shadow_reg_enable = false, /* TODO: fix bugs using this feature */
  282. };
  283. static const struct iwl_base_params iwl6000_g2_base_params = {
  284. .eeprom_size = OTP_LOW_IMAGE_SIZE,
  285. .num_of_queues = IWLAGN_NUM_QUEUES,
  286. .num_of_ampdu_queues = IWLAGN_NUM_AMPDU_QUEUES,
  287. .pll_cfg_val = 0,
  288. .max_ll_items = OTP_MAX_LL_ITEMS_6x00,
  289. .shadow_ram_support = true,
  290. .led_compensation = 57,
  291. .adv_thermal_throttle = true,
  292. .support_ct_kill_exit = true,
  293. .plcp_delta_threshold = IWL_MAX_PLCP_ERR_THRESHOLD_DEF,
  294. .chain_noise_scale = 1000,
  295. .wd_timeout = IWL_LONG_WD_TIMEOUT,
  296. .max_event_log_size = 512,
  297. .shadow_reg_enable = false, /* TODO: fix bugs using this feature */
  298. };
  299. static const struct iwl_ht_params iwl6000_ht_params = {
  300. .ht_greenfield_support = true,
  301. .use_rts_for_aggregation = true, /* use rts/cts protection */
  302. };
  303. static const struct iwl_bt_params iwl6000_bt_params = {
  304. /* Due to bluetooth, we transmit 2.4 GHz probes only on antenna A */
  305. .advanced_bt_coexist = true,
  306. .agg_time_limit = BT_AGG_THRESHOLD_DEF,
  307. .bt_init_traffic_load = IWL_BT_COEX_TRAFFIC_LOAD_NONE,
  308. .bt_prio_boost = IWLAGN_BT_PRIO_BOOST_DEFAULT,
  309. .bt_sco_disable = true,
  310. };
  311. #define IWL_DEVICE_6005 \
  312. .fw_name_pre = IWL6005_FW_PRE, \
  313. .ucode_api_max = IWL6000G2_UCODE_API_MAX, \
  314. .ucode_api_ok = IWL6000G2_UCODE_API_OK, \
  315. .ucode_api_min = IWL6000G2_UCODE_API_MIN, \
  316. .max_inst_size = IWL60_RTC_INST_SIZE, \
  317. .max_data_size = IWL60_RTC_DATA_SIZE, \
  318. .eeprom_ver = EEPROM_6005_EEPROM_VERSION, \
  319. .eeprom_calib_ver = EEPROM_6005_TX_POWER_VERSION, \
  320. .lib = &iwl6000_lib, \
  321. .base_params = &iwl6000_g2_base_params, \
  322. .need_temp_offset_calib = true, \
  323. .led_mode = IWL_LED_RF_STATE
  324. const struct iwl_cfg iwl6005_2agn_cfg = {
  325. .name = "Intel(R) Centrino(R) Advanced-N 6205 AGN",
  326. IWL_DEVICE_6005,
  327. .ht_params = &iwl6000_ht_params,
  328. };
  329. const struct iwl_cfg iwl6005_2abg_cfg = {
  330. .name = "Intel(R) Centrino(R) Advanced-N 6205 ABG",
  331. IWL_DEVICE_6005,
  332. };
  333. const struct iwl_cfg iwl6005_2bg_cfg = {
  334. .name = "Intel(R) Centrino(R) Advanced-N 6205 BG",
  335. IWL_DEVICE_6005,
  336. };
  337. const struct iwl_cfg iwl6005_2agn_sff_cfg = {
  338. .name = "Intel(R) Centrino(R) Advanced-N 6205S AGN",
  339. IWL_DEVICE_6005,
  340. .ht_params = &iwl6000_ht_params,
  341. };
  342. const struct iwl_cfg iwl6005_2agn_d_cfg = {
  343. .name = "Intel(R) Centrino(R) Advanced-N 6205D AGN",
  344. IWL_DEVICE_6005,
  345. .ht_params = &iwl6000_ht_params,
  346. };
  347. const struct iwl_cfg iwl6005_2agn_mow1_cfg = {
  348. .name = "Intel(R) Centrino(R) Advanced-N 6206 AGN",
  349. IWL_DEVICE_6005,
  350. .ht_params = &iwl6000_ht_params,
  351. };
  352. const struct iwl_cfg iwl6005_2agn_mow2_cfg = {
  353. .name = "Intel(R) Centrino(R) Advanced-N 6207 AGN",
  354. IWL_DEVICE_6005,
  355. .ht_params = &iwl6000_ht_params,
  356. };
  357. #define IWL_DEVICE_6030 \
  358. .fw_name_pre = IWL6030_FW_PRE, \
  359. .ucode_api_max = IWL6000G2_UCODE_API_MAX, \
  360. .ucode_api_ok = IWL6000G2B_UCODE_API_OK, \
  361. .ucode_api_min = IWL6000G2_UCODE_API_MIN, \
  362. .max_inst_size = IWL60_RTC_INST_SIZE, \
  363. .max_data_size = IWL60_RTC_DATA_SIZE, \
  364. .eeprom_ver = EEPROM_6030_EEPROM_VERSION, \
  365. .eeprom_calib_ver = EEPROM_6030_TX_POWER_VERSION, \
  366. .lib = &iwl6030_lib, \
  367. .base_params = &iwl6000_g2_base_params, \
  368. .bt_params = &iwl6000_bt_params, \
  369. .need_temp_offset_calib = true, \
  370. .led_mode = IWL_LED_RF_STATE, \
  371. .adv_pm = true \
  372. const struct iwl_cfg iwl6030_2agn_cfg = {
  373. .name = "Intel(R) Centrino(R) Advanced-N 6230 AGN",
  374. IWL_DEVICE_6030,
  375. .ht_params = &iwl6000_ht_params,
  376. };
  377. const struct iwl_cfg iwl6030_2abg_cfg = {
  378. .name = "Intel(R) Centrino(R) Advanced-N 6230 ABG",
  379. IWL_DEVICE_6030,
  380. };
  381. const struct iwl_cfg iwl6030_2bgn_cfg = {
  382. .name = "Intel(R) Centrino(R) Advanced-N 6230 BGN",
  383. IWL_DEVICE_6030,
  384. .ht_params = &iwl6000_ht_params,
  385. };
  386. const struct iwl_cfg iwl6030_2bg_cfg = {
  387. .name = "Intel(R) Centrino(R) Advanced-N 6230 BG",
  388. IWL_DEVICE_6030,
  389. };
  390. #define IWL_DEVICE_6035 \
  391. .fw_name_pre = IWL6030_FW_PRE, \
  392. .ucode_api_max = IWL6035_UCODE_API_MAX, \
  393. .ucode_api_ok = IWL6035_UCODE_API_OK, \
  394. .ucode_api_min = IWL6035_UCODE_API_MIN, \
  395. .max_inst_size = IWL60_RTC_INST_SIZE, \
  396. .max_data_size = IWL60_RTC_DATA_SIZE, \
  397. .eeprom_ver = EEPROM_6030_EEPROM_VERSION, \
  398. .eeprom_calib_ver = EEPROM_6030_TX_POWER_VERSION, \
  399. .lib = &iwl6030_lib, \
  400. .base_params = &iwl6000_g2_base_params, \
  401. .bt_params = &iwl6000_bt_params, \
  402. .need_temp_offset_calib = true, \
  403. .led_mode = IWL_LED_RF_STATE, \
  404. .adv_pm = true
  405. const struct iwl_cfg iwl6035_2agn_cfg = {
  406. .name = "Intel(R) Centrino(R) Advanced-N 6235 AGN",
  407. IWL_DEVICE_6035,
  408. .ht_params = &iwl6000_ht_params,
  409. };
  410. const struct iwl_cfg iwl6035_2agn_sff_cfg = {
  411. .name = "Intel(R) Centrino(R) Ultimate-N 6235 AGN",
  412. IWL_DEVICE_6035,
  413. .ht_params = &iwl6000_ht_params,
  414. };
  415. const struct iwl_cfg iwl1030_bgn_cfg = {
  416. .name = "Intel(R) Centrino(R) Wireless-N 1030 BGN",
  417. IWL_DEVICE_6030,
  418. .ht_params = &iwl6000_ht_params,
  419. };
  420. const struct iwl_cfg iwl1030_bg_cfg = {
  421. .name = "Intel(R) Centrino(R) Wireless-N 1030 BG",
  422. IWL_DEVICE_6030,
  423. };
  424. const struct iwl_cfg iwl130_bgn_cfg = {
  425. .name = "Intel(R) Centrino(R) Wireless-N 130 BGN",
  426. IWL_DEVICE_6030,
  427. .ht_params = &iwl6000_ht_params,
  428. .rx_with_siso_diversity = true,
  429. };
  430. const struct iwl_cfg iwl130_bg_cfg = {
  431. .name = "Intel(R) Centrino(R) Wireless-N 130 BG",
  432. IWL_DEVICE_6030,
  433. .rx_with_siso_diversity = true,
  434. };
  435. /*
  436. * "i": Internal configuration, use internal Power Amplifier
  437. */
  438. #define IWL_DEVICE_6000i \
  439. .fw_name_pre = IWL6000_FW_PRE, \
  440. .ucode_api_max = IWL6000_UCODE_API_MAX, \
  441. .ucode_api_ok = IWL6000_UCODE_API_OK, \
  442. .ucode_api_min = IWL6000_UCODE_API_MIN, \
  443. .max_inst_size = IWL60_RTC_INST_SIZE, \
  444. .max_data_size = IWL60_RTC_DATA_SIZE, \
  445. .valid_tx_ant = ANT_BC, /* .cfg overwrite */ \
  446. .valid_rx_ant = ANT_BC, /* .cfg overwrite */ \
  447. .eeprom_ver = EEPROM_6000_EEPROM_VERSION, \
  448. .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION, \
  449. .lib = &iwl6000_lib, \
  450. .additional_nic_config = iwl6000i_additional_nic_config,\
  451. .base_params = &iwl6000_base_params, \
  452. .led_mode = IWL_LED_BLINK
  453. const struct iwl_cfg iwl6000i_2agn_cfg = {
  454. .name = "Intel(R) Centrino(R) Advanced-N 6200 AGN",
  455. IWL_DEVICE_6000i,
  456. .ht_params = &iwl6000_ht_params,
  457. };
  458. const struct iwl_cfg iwl6000i_2abg_cfg = {
  459. .name = "Intel(R) Centrino(R) Advanced-N 6200 ABG",
  460. IWL_DEVICE_6000i,
  461. };
  462. const struct iwl_cfg iwl6000i_2bg_cfg = {
  463. .name = "Intel(R) Centrino(R) Advanced-N 6200 BG",
  464. IWL_DEVICE_6000i,
  465. };
  466. #define IWL_DEVICE_6050 \
  467. .fw_name_pre = IWL6050_FW_PRE, \
  468. .ucode_api_max = IWL6050_UCODE_API_MAX, \
  469. .ucode_api_min = IWL6050_UCODE_API_MIN, \
  470. .max_inst_size = IWL60_RTC_INST_SIZE, \
  471. .max_data_size = IWL60_RTC_DATA_SIZE, \
  472. .valid_tx_ant = ANT_AB, /* .cfg overwrite */ \
  473. .valid_rx_ant = ANT_AB, /* .cfg overwrite */ \
  474. .lib = &iwl6000_lib, \
  475. .additional_nic_config = iwl6050_additional_nic_config, \
  476. .eeprom_ver = EEPROM_6050_EEPROM_VERSION, \
  477. .eeprom_calib_ver = EEPROM_6050_TX_POWER_VERSION, \
  478. .base_params = &iwl6050_base_params, \
  479. .led_mode = IWL_LED_BLINK, \
  480. .internal_wimax_coex = true
  481. const struct iwl_cfg iwl6050_2agn_cfg = {
  482. .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 AGN",
  483. IWL_DEVICE_6050,
  484. .ht_params = &iwl6000_ht_params,
  485. };
  486. const struct iwl_cfg iwl6050_2abg_cfg = {
  487. .name = "Intel(R) Centrino(R) Advanced-N + WiMAX 6250 ABG",
  488. IWL_DEVICE_6050,
  489. };
  490. #define IWL_DEVICE_6150 \
  491. .fw_name_pre = IWL6050_FW_PRE, \
  492. .ucode_api_max = IWL6050_UCODE_API_MAX, \
  493. .ucode_api_min = IWL6050_UCODE_API_MIN, \
  494. .max_inst_size = IWL60_RTC_INST_SIZE, \
  495. .max_data_size = IWL60_RTC_DATA_SIZE, \
  496. .lib = &iwl6000_lib, \
  497. .additional_nic_config = iwl6150_additional_nic_config, \
  498. .eeprom_ver = EEPROM_6150_EEPROM_VERSION, \
  499. .eeprom_calib_ver = EEPROM_6150_TX_POWER_VERSION, \
  500. .base_params = &iwl6050_base_params, \
  501. .led_mode = IWL_LED_BLINK, \
  502. .internal_wimax_coex = true
  503. const struct iwl_cfg iwl6150_bgn_cfg = {
  504. .name = "Intel(R) Centrino(R) Wireless-N + WiMAX 6150 BGN",
  505. IWL_DEVICE_6150,
  506. .ht_params = &iwl6000_ht_params,
  507. };
  508. const struct iwl_cfg iwl6150_bg_cfg = {
  509. .name = "Intel(R) Centrino(R) Wireless-N + WiMAX 6150 BG",
  510. IWL_DEVICE_6150,
  511. };
  512. const struct iwl_cfg iwl6000_3agn_cfg = {
  513. .name = "Intel(R) Centrino(R) Ultimate-N 6300 AGN",
  514. .fw_name_pre = IWL6000_FW_PRE,
  515. .ucode_api_max = IWL6000_UCODE_API_MAX,
  516. .ucode_api_ok = IWL6000_UCODE_API_OK,
  517. .ucode_api_min = IWL6000_UCODE_API_MIN,
  518. .max_inst_size = IWL60_RTC_INST_SIZE,
  519. .max_data_size = IWL60_RTC_DATA_SIZE,
  520. .eeprom_ver = EEPROM_6000_EEPROM_VERSION,
  521. .eeprom_calib_ver = EEPROM_6000_TX_POWER_VERSION,
  522. .lib = &iwl6000_lib,
  523. .base_params = &iwl6000_base_params,
  524. .ht_params = &iwl6000_ht_params,
  525. .led_mode = IWL_LED_BLINK,
  526. };
  527. MODULE_FIRMWARE(IWL6000_MODULE_FIRMWARE(IWL6000_UCODE_API_OK));
  528. MODULE_FIRMWARE(IWL6050_MODULE_FIRMWARE(IWL6050_UCODE_API_OK));
  529. MODULE_FIRMWARE(IWL6005_MODULE_FIRMWARE(IWL6000G2_UCODE_API_OK));
  530. MODULE_FIRMWARE(IWL6030_MODULE_FIRMWARE(IWL6000G2B_UCODE_API_OK));