lmac.h 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485
  1. /*
  2. * Intel Wireless Multicomm 3200 WiFi driver
  3. *
  4. * Copyright (C) 2009 Intel Corporation. All rights reserved.
  5. *
  6. * Redistribution and use in source and binary forms, with or without
  7. * modification, are permitted provided that the following conditions
  8. * are met:
  9. *
  10. * * Redistributions of source code must retain the above copyright
  11. * notice, this list of conditions and the following disclaimer.
  12. * * Redistributions in binary form must reproduce the above copyright
  13. * notice, this list of conditions and the following disclaimer in
  14. * the documentation and/or other materials provided with the
  15. * distribution.
  16. * * Neither the name of Intel Corporation nor the names of its
  17. * contributors may be used to endorse or promote products derived
  18. * from this software without specific prior written permission.
  19. *
  20. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  21. * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  22. * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
  23. * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
  24. * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  25. * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  26. * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  27. * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  28. * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  29. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  30. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  31. *
  32. *
  33. * Intel Corporation <ilw@linux.intel.com>
  34. * Samuel Ortiz <samuel.ortiz@intel.com>
  35. * Zhu Yi <yi.zhu@intel.com>
  36. *
  37. */
  38. #ifndef __IWM_LMAC_H__
  39. #define __IWM_LMAC_H__
  40. struct iwm_lmac_hdr {
  41. u8 id;
  42. u8 flags;
  43. __le16 seq_num;
  44. } __packed;
  45. /* LMAC commands */
  46. #define CALIB_CFG_FLAG_SEND_COMPLETE_NTFY_AFTER_MSK 0x1
  47. struct iwm_lmac_cal_cfg_elt {
  48. __le32 enable; /* 1 means LMAC needs to do something */
  49. __le32 start; /* 1 to start calibration, 0 to stop */
  50. __le32 send_res; /* 1 for sending back results */
  51. __le32 apply_res; /* 1 for applying calibration results to HW */
  52. __le32 reserved;
  53. } __packed;
  54. struct iwm_lmac_cal_cfg_status {
  55. struct iwm_lmac_cal_cfg_elt init;
  56. struct iwm_lmac_cal_cfg_elt periodic;
  57. __le32 flags; /* CALIB_CFG_FLAG_SEND_COMPLETE_NTFY_AFTER_MSK */
  58. } __packed;
  59. struct iwm_lmac_cal_cfg_cmd {
  60. struct iwm_lmac_cal_cfg_status ucode_cfg;
  61. struct iwm_lmac_cal_cfg_status driver_cfg;
  62. __le32 reserved;
  63. } __packed;
  64. struct iwm_lmac_cal_cfg_resp {
  65. __le32 status;
  66. } __packed;
  67. #define IWM_CARD_STATE_SW_HW_ENABLED 0x00
  68. #define IWM_CARD_STATE_HW_DISABLED 0x01
  69. #define IWM_CARD_STATE_SW_DISABLED 0x02
  70. #define IWM_CARD_STATE_CTKILL_DISABLED 0x04
  71. #define IWM_CARD_STATE_IS_RXON 0x10
  72. struct iwm_lmac_card_state {
  73. __le32 flags;
  74. } __packed;
  75. /**
  76. * COEX_PRIORITY_TABLE_CMD
  77. *
  78. * Priority entry for each state
  79. * Will keep two tables, for STA and WIPAN
  80. */
  81. enum {
  82. /* UN-ASSOCIATION PART */
  83. COEX_UNASSOC_IDLE = 0,
  84. COEX_UNASSOC_MANUAL_SCAN,
  85. COEX_UNASSOC_AUTO_SCAN,
  86. /* CALIBRATION */
  87. COEX_CALIBRATION,
  88. COEX_PERIODIC_CALIBRATION,
  89. /* CONNECTION */
  90. COEX_CONNECTION_ESTAB,
  91. /* ASSOCIATION PART */
  92. COEX_ASSOCIATED_IDLE,
  93. COEX_ASSOC_MANUAL_SCAN,
  94. COEX_ASSOC_AUTO_SCAN,
  95. COEX_ASSOC_ACTIVE_LEVEL,
  96. /* RF ON/OFF */
  97. COEX_RF_ON,
  98. COEX_RF_OFF,
  99. COEX_STAND_ALONE_DEBUG,
  100. /* IPNN */
  101. COEX_IPAN_ASSOC_LEVEL,
  102. /* RESERVED */
  103. COEX_RSRVD1,
  104. COEX_RSRVD2,
  105. COEX_EVENTS_NUM
  106. };
  107. #define COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK 0x1
  108. #define COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK 0x2
  109. #define COEX_EVT_FLAG_DELAY_MEDIUM_FREE_NTFY_MSK 0x4
  110. struct coex_event {
  111. u8 req_prio;
  112. u8 win_med_prio;
  113. u8 reserved;
  114. u8 flags;
  115. } __packed;
  116. #define COEX_FLAGS_STA_TABLE_VALID_MSK 0x1
  117. #define COEX_FLAGS_UNASSOC_WAKEUP_UMASK_MSK 0x4
  118. #define COEX_FLAGS_ASSOC_WAKEUP_UMASK_MSK 0x8
  119. #define COEX_FLAGS_COEX_ENABLE_MSK 0x80
  120. struct iwm_coex_prio_table_cmd {
  121. u8 flags;
  122. u8 reserved[3];
  123. struct coex_event sta_prio[COEX_EVENTS_NUM];
  124. } __packed;
  125. /* Coexistence definitions
  126. *
  127. * Constants to fill in the Priorities' Tables
  128. * RP - Requested Priority
  129. * WP - Win Medium Priority: priority assigned when the contention has been won
  130. * FLAGS - Combination of COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK and
  131. * COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK
  132. */
  133. #define COEX_UNASSOC_IDLE_FLAGS 0
  134. #define COEX_UNASSOC_MANUAL_SCAN_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  135. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK)
  136. #define COEX_UNASSOC_AUTO_SCAN_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  137. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK)
  138. #define COEX_CALIBRATION_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  139. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK)
  140. #define COEX_PERIODIC_CALIBRATION_FLAGS 0
  141. /* COEX_CONNECTION_ESTAB: we need DELAY_MEDIUM_FREE_NTFY to let WiMAX
  142. * disconnect from network. */
  143. #define COEX_CONNECTION_ESTAB_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  144. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK | \
  145. COEX_EVT_FLAG_DELAY_MEDIUM_FREE_NTFY_MSK)
  146. #define COEX_ASSOCIATED_IDLE_FLAGS 0
  147. #define COEX_ASSOC_MANUAL_SCAN_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  148. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK)
  149. #define COEX_ASSOC_AUTO_SCAN_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  150. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK)
  151. #define COEX_ASSOC_ACTIVE_LEVEL_FLAGS 0
  152. #define COEX_RF_ON_FLAGS 0
  153. #define COEX_RF_OFF_FLAGS 0
  154. #define COEX_STAND_ALONE_DEBUG_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  155. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK)
  156. #define COEX_IPAN_ASSOC_LEVEL_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  157. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK | \
  158. COEX_EVT_FLAG_DELAY_MEDIUM_FREE_NTFY_MSK)
  159. #define COEX_RSRVD1_FLAGS 0
  160. #define COEX_RSRVD2_FLAGS 0
  161. /* XOR_RF_ON is the event wrapping all radio ownership. We need
  162. * DELAY_MEDIUM_FREE_NTFY to let WiMAX disconnect from network. */
  163. #define COEX_XOR_RF_ON_FLAGS (COEX_EVT_FLAG_MEDIUM_FREE_NTFY_MSK | \
  164. COEX_EVT_FLAG_MEDIUM_ACTV_NTFY_MSK | \
  165. COEX_EVT_FLAG_DELAY_MEDIUM_FREE_NTFY_MSK)
  166. /* CT kill config command */
  167. struct iwm_ct_kill_cfg_cmd {
  168. u32 exit_threshold;
  169. u32 reserved;
  170. u32 entry_threshold;
  171. } __packed;
  172. /* LMAC OP CODES */
  173. #define REPLY_PAD 0x0
  174. #define REPLY_ALIVE 0x1
  175. #define REPLY_ERROR 0x2
  176. #define REPLY_ECHO 0x3
  177. #define REPLY_HALT 0x6
  178. /* RXON state commands */
  179. #define REPLY_RX_ON 0x10
  180. #define REPLY_RX_ON_ASSOC 0x11
  181. #define REPLY_RX_OFF 0x12
  182. #define REPLY_QOS_PARAM 0x13
  183. #define REPLY_RX_ON_TIMING 0x14
  184. #define REPLY_INTERNAL_QOS_PARAM 0x15
  185. #define REPLY_RX_INT_TIMEOUT_CNFG 0x16
  186. #define REPLY_NULL 0x17
  187. /* Multi-Station support */
  188. #define REPLY_ADD_STA 0x18
  189. #define REPLY_REMOVE_STA 0x19
  190. #define REPLY_RESET_ALL_STA 0x1a
  191. /* RX, TX */
  192. #define REPLY_ALM_RX 0x1b
  193. #define REPLY_TX 0x1c
  194. #define REPLY_TXFIFO_FLUSH 0x1e
  195. /* MISC commands */
  196. #define REPLY_MGMT_MCAST_KEY 0x1f
  197. #define REPLY_WEPKEY 0x20
  198. #define REPLY_INIT_IV 0x21
  199. #define REPLY_WRITE_MIB 0x22
  200. #define REPLY_READ_MIB 0x23
  201. #define REPLY_RADIO_FE 0x24
  202. #define REPLY_TXFIFO_CFG 0x25
  203. #define REPLY_WRITE_READ 0x26
  204. #define REPLY_INSTALL_SEC_KEY 0x27
  205. #define REPLY_RATE_SCALE 0x47
  206. #define REPLY_LEDS_CMD 0x48
  207. #define REPLY_TX_LINK_QUALITY_CMD 0x4e
  208. #define REPLY_ANA_MIB_OVERRIDE_CMD 0x4f
  209. #define REPLY_WRITE2REG_CMD 0x50
  210. /* winfi-wifi coexistence */
  211. #define COEX_PRIORITY_TABLE_CMD 0x5a
  212. #define COEX_MEDIUM_NOTIFICATION 0x5b
  213. #define COEX_EVENT_CMD 0x5c
  214. /* more Protocol and Protocol-test commands */
  215. #define REPLY_MAX_SLEEP_TIME_CMD 0x61
  216. #define CALIBRATION_CFG_CMD 0x65
  217. #define CALIBRATION_RES_NOTIFICATION 0x66
  218. #define CALIBRATION_COMPLETE_NOTIFICATION 0x67
  219. /* Measurements */
  220. #define REPLY_QUIET_CMD 0x71
  221. #define REPLY_CHANNEL_SWITCH 0x72
  222. #define CHANNEL_SWITCH_NOTIFICATION 0x73
  223. #define REPLY_SPECTRUM_MEASUREMENT_CMD 0x74
  224. #define SPECTRUM_MEASURE_NOTIFICATION 0x75
  225. #define REPLY_MEASUREMENT_ABORT_CMD 0x76
  226. /* Power Management */
  227. #define POWER_TABLE_CMD 0x77
  228. #define SAVE_RESTORE_ADDRESS_CMD 0x78
  229. #define REPLY_WATERMARK_CMD 0x79
  230. #define PM_DEBUG_STATISTIC_NOTIFIC 0x7B
  231. #define PD_FLUSH_N_NOTIFICATION 0x7C
  232. /* Scan commands and notifications */
  233. #define REPLY_SCAN_REQUEST_CMD 0x80
  234. #define REPLY_SCAN_ABORT_CMD 0x81
  235. #define SCAN_START_NOTIFICATION 0x82
  236. #define SCAN_RESULTS_NOTIFICATION 0x83
  237. #define SCAN_COMPLETE_NOTIFICATION 0x84
  238. /* Continuous TX commands */
  239. #define REPLY_CONT_TX_CMD 0x85
  240. #define END_OF_CONT_TX_NOTIFICATION 0x86
  241. /* Timer/Eeprom commands */
  242. #define TIMER_CMD 0x87
  243. #define EEPROM_WRITE_CMD 0x88
  244. /* PAPD commands */
  245. #define FEEDBACK_REQUEST_NOTIFICATION 0x8b
  246. #define REPLY_CW_CMD 0x8c
  247. /* IBSS/AP commands Continue */
  248. #define BEACON_NOTIFICATION 0x90
  249. #define REPLY_TX_BEACON 0x91
  250. #define REPLY_REQUEST_ATIM 0x93
  251. #define WHO_IS_AWAKE_NOTIFICATION 0x94
  252. #define TX_PWR_DBM_LIMIT_CMD 0x95
  253. #define QUIET_NOTIFICATION 0x96
  254. #define TX_PWR_TABLE_CMD 0x97
  255. #define TX_ANT_CONFIGURATION_CMD 0x98
  256. #define MEASURE_ABORT_NOTIFICATION 0x99
  257. #define REPLY_CALIBRATION_TUNE 0x9a
  258. /* bt config command */
  259. #define REPLY_BT_CONFIG 0x9b
  260. #define REPLY_STATISTICS_CMD 0x9c
  261. #define STATISTICS_NOTIFICATION 0x9d
  262. /* RF-KILL commands and notifications */
  263. #define REPLY_CARD_STATE_CMD 0xa0
  264. #define CARD_STATE_NOTIFICATION 0xa1
  265. /* Missed beacons notification */
  266. #define MISSED_BEACONS_NOTIFICATION 0xa2
  267. #define MISSED_BEACONS_NOTIFICATION_TH_CMD 0xa3
  268. #define REPLY_CT_KILL_CONFIG_CMD 0xa4
  269. /* HD commands and notifications */
  270. #define REPLY_HD_PARAMS_CMD 0xa6
  271. #define HD_PARAMS_NOTIFICATION 0xa7
  272. #define SENSITIVITY_CMD 0xa8
  273. #define U_APSD_PARAMS_CMD 0xa9
  274. #define NOISY_PLATFORM_CMD 0xaa
  275. #define ILLEGAL_CMD 0xac
  276. #define REPLY_PHY_CALIBRATION_CMD 0xb0
  277. #define REPLAY_RX_GAIN_CALIB_CMD 0xb1
  278. /* WiPAN commands */
  279. #define REPLY_WIPAN_PARAMS_CMD 0xb2
  280. #define REPLY_WIPAN_RX_ON_CMD 0xb3
  281. #define REPLY_WIPAN_RX_ON_TIMING 0xb4
  282. #define REPLY_WIPAN_TX_PWR_TABLE_CMD 0xb5
  283. #define REPLY_WIPAN_RXON_ASSOC_CMD 0xb6
  284. #define REPLY_WIPAN_QOS_PARAM 0xb7
  285. #define WIPAN_REPLY_WEPKEY 0xb8
  286. /* BeamForming commands */
  287. #define BEAMFORMER_CFG_CMD 0xba
  288. #define BEAMFORMEE_NOTIFICATION 0xbb
  289. /* TGn new Commands */
  290. #define REPLY_RX_PHY_CMD 0xc0
  291. #define REPLY_RX_MPDU_CMD 0xc1
  292. #define REPLY_MULTICAST_HASH 0xc2
  293. #define REPLY_KDR_RX 0xc3
  294. #define REPLY_RX_DSP_EXT_INFO 0xc4
  295. #define REPLY_COMPRESSED_BA 0xc5
  296. /* PNC commands */
  297. #define PNC_CONFIG_CMD 0xc8
  298. #define PNC_UPDATE_TABLE_CMD 0xc9
  299. #define XVT_GENERAL_CTRL_CMD 0xca
  300. #define REPLY_LEGACY_RADIO_FE 0xdd
  301. /* WoWLAN commands */
  302. #define WOWLAN_PATTERNS 0xe0
  303. #define WOWLAN_WAKEUP_FILTER 0xe1
  304. #define WOWLAN_TSC_RSC_PARAM 0xe2
  305. #define WOWLAN_TKIP_PARAM 0xe3
  306. #define WOWLAN_KEK_KCK_MATERIAL 0xe4
  307. #define WOWLAN_GET_STATUSES 0xe5
  308. #define WOWLAN_TX_POWER_PER_DB 0xe6
  309. #define REPLY_WOWLAN_GET_STATUSES WOWLAN_GET_STATUSES
  310. #define REPLY_DEBUG_CMD 0xf0
  311. #define REPLY_DSP_DEBUG_CMD 0xf1
  312. #define REPLY_DEBUG_MONITOR_CMD 0xf2
  313. #define REPLY_DEBUG_XVT_CMD 0xf3
  314. #define REPLY_DEBUG_DC_CALIB 0xf4
  315. #define REPLY_DYNAMIC_BP 0xf5
  316. /* General purpose Commands */
  317. #define REPLY_GP1_CMD 0xfa
  318. #define REPLY_GP2_CMD 0xfb
  319. #define REPLY_GP3_CMD 0xfc
  320. #define REPLY_GP4_CMD 0xfd
  321. #define REPLY_REPLAY_WRAPPER 0xfe
  322. #define REPLY_FRAME_DURATION_CALC_CMD 0xff
  323. #define LMAC_COMMAND_ID_MAX 0xff
  324. #define LMAC_COMMAND_ID_NUM (LMAC_COMMAND_ID_MAX + 1)
  325. /* Calibration */
  326. enum {
  327. PHY_CALIBRATE_DC_CMD = 0,
  328. PHY_CALIBRATE_LO_CMD = 1,
  329. PHY_CALIBRATE_RX_BB_CMD = 2,
  330. PHY_CALIBRATE_TX_IQ_CMD = 3,
  331. PHY_CALIBRATE_RX_IQ_CMD = 4,
  332. PHY_CALIBRATION_NOISE_CMD = 5,
  333. PHY_CALIBRATE_AGC_TABLE_CMD = 6,
  334. PHY_CALIBRATE_CRYSTAL_FRQ_CMD = 7,
  335. PHY_CALIBRATE_OPCODES_NUM,
  336. SHILOH_PHY_CALIBRATE_DC_CMD = 8,
  337. SHILOH_PHY_CALIBRATE_LO_CMD = 9,
  338. SHILOH_PHY_CALIBRATE_RX_BB_CMD = 10,
  339. SHILOH_PHY_CALIBRATE_TX_IQ_CMD = 11,
  340. SHILOH_PHY_CALIBRATE_RX_IQ_CMD = 12,
  341. SHILOH_PHY_CALIBRATION_NOISE_CMD = 13,
  342. SHILOH_PHY_CALIBRATE_AGC_TABLE_CMD = 14,
  343. SHILOH_PHY_CALIBRATE_CRYSTAL_FRQ_CMD = 15,
  344. SHILOH_PHY_CALIBRATE_BASE_BAND_CMD = 16,
  345. SHILOH_PHY_CALIBRATE_TXIQ_PERIODIC_CMD = 17,
  346. CALIBRATION_CMD_NUM,
  347. };
  348. enum {
  349. CALIB_CFG_RX_BB_IDX = 0,
  350. CALIB_CFG_DC_IDX = 1,
  351. CALIB_CFG_LO_IDX = 2,
  352. CALIB_CFG_TX_IQ_IDX = 3,
  353. CALIB_CFG_RX_IQ_IDX = 4,
  354. CALIB_CFG_NOISE_IDX = 5,
  355. CALIB_CFG_CRYSTAL_IDX = 6,
  356. CALIB_CFG_TEMPERATURE_IDX = 7,
  357. CALIB_CFG_PAPD_IDX = 8,
  358. CALIB_CFG_LAST_IDX = CALIB_CFG_PAPD_IDX,
  359. CALIB_CFG_MODULE_NUM,
  360. };
  361. #define IWM_CALIB_MAP_INIT_MSK 0xFFFF
  362. #define IWM_CALIB_MAP_PER_LMAC(m) ((m & 0xFF0000) >> 16)
  363. #define IWM_CALIB_MAP_PER_UMAC(m) ((m & 0xFF000000) >> 24)
  364. #define IWM_CALIB_OPCODE_TO_INDEX(op) (op - PHY_CALIBRATE_OPCODES_NUM)
  365. struct iwm_lmac_calib_hdr {
  366. u8 opcode;
  367. u8 first_grp;
  368. u8 grp_num;
  369. u8 all_data_valid;
  370. } __packed;
  371. #define IWM_LMAC_CALIB_FREQ_GROUPS_NR 7
  372. #define IWM_CALIB_FREQ_GROUPS_NR 5
  373. #define IWM_CALIB_DC_MODES_NR 12
  374. struct iwm_calib_rxiq_entry {
  375. u16 ptam_postdist_ars;
  376. u16 ptam_postdist_arc;
  377. } __packed;
  378. struct iwm_calib_rxiq_group {
  379. struct iwm_calib_rxiq_entry mode[IWM_CALIB_DC_MODES_NR];
  380. } __packed;
  381. struct iwm_lmac_calib_rxiq {
  382. struct iwm_calib_rxiq_group group[IWM_LMAC_CALIB_FREQ_GROUPS_NR];
  383. } __packed;
  384. struct iwm_calib_rxiq {
  385. struct iwm_lmac_calib_hdr hdr;
  386. struct iwm_calib_rxiq_group group[IWM_CALIB_FREQ_GROUPS_NR];
  387. } __packed;
  388. #define LMAC_STA_ID_SEED 0x0f
  389. #define LMAC_STA_ID_POS 0
  390. #define LMAC_STA_COLOR_SEED 0x7
  391. #define LMAC_STA_COLOR_POS 4
  392. struct iwm_lmac_power_report {
  393. u8 pa_status;
  394. u8 pa_integ_res_A[3];
  395. u8 pa_integ_res_B[3];
  396. u8 pa_integ_res_C[3];
  397. } __packed;
  398. struct iwm_lmac_tx_resp {
  399. u8 frame_cnt; /* 1-no aggregation, greater then 1 - aggregation */
  400. u8 bt_kill_cnt;
  401. __le16 retry_cnt;
  402. __le32 initial_tx_rate;
  403. __le16 wireless_media_time;
  404. struct iwm_lmac_power_report power_report;
  405. __le32 tfd_info;
  406. __le16 seq_ctl;
  407. __le16 byte_cnt;
  408. u8 tlc_rate_info;
  409. u8 ra_tid;
  410. __le16 frame_ctl;
  411. __le32 status;
  412. } __packed;
  413. #endif