lmac.h 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476
  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. } __attribute__ ((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. } __attribute__ ((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. } __attribute__ ((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. } __attribute__ ((packed));
  64. struct iwm_lmac_cal_cfg_resp {
  65. __le32 status;
  66. } __attribute__ ((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. } __attribute__ ((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. } __attribute__ ((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. } __attribute__ ((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. /* LMAC OP CODES */
  167. #define REPLY_PAD 0x0
  168. #define REPLY_ALIVE 0x1
  169. #define REPLY_ERROR 0x2
  170. #define REPLY_ECHO 0x3
  171. #define REPLY_HALT 0x6
  172. /* RXON state commands */
  173. #define REPLY_RX_ON 0x10
  174. #define REPLY_RX_ON_ASSOC 0x11
  175. #define REPLY_RX_OFF 0x12
  176. #define REPLY_QOS_PARAM 0x13
  177. #define REPLY_RX_ON_TIMING 0x14
  178. #define REPLY_INTERNAL_QOS_PARAM 0x15
  179. #define REPLY_RX_INT_TIMEOUT_CNFG 0x16
  180. #define REPLY_NULL 0x17
  181. /* Multi-Station support */
  182. #define REPLY_ADD_STA 0x18
  183. #define REPLY_REMOVE_STA 0x19
  184. #define REPLY_RESET_ALL_STA 0x1a
  185. /* RX, TX */
  186. #define REPLY_ALM_RX 0x1b
  187. #define REPLY_TX 0x1c
  188. #define REPLY_TXFIFO_FLUSH 0x1e
  189. /* MISC commands */
  190. #define REPLY_MGMT_MCAST_KEY 0x1f
  191. #define REPLY_WEPKEY 0x20
  192. #define REPLY_INIT_IV 0x21
  193. #define REPLY_WRITE_MIB 0x22
  194. #define REPLY_READ_MIB 0x23
  195. #define REPLY_RADIO_FE 0x24
  196. #define REPLY_TXFIFO_CFG 0x25
  197. #define REPLY_WRITE_READ 0x26
  198. #define REPLY_INSTALL_SEC_KEY 0x27
  199. #define REPLY_RATE_SCALE 0x47
  200. #define REPLY_LEDS_CMD 0x48
  201. #define REPLY_TX_LINK_QUALITY_CMD 0x4e
  202. #define REPLY_ANA_MIB_OVERRIDE_CMD 0x4f
  203. #define REPLY_WRITE2REG_CMD 0x50
  204. /* winfi-wifi coexistence */
  205. #define COEX_PRIORITY_TABLE_CMD 0x5a
  206. #define COEX_MEDIUM_NOTIFICATION 0x5b
  207. #define COEX_EVENT_CMD 0x5c
  208. /* more Protocol and Protocol-test commands */
  209. #define REPLY_MAX_SLEEP_TIME_CMD 0x61
  210. #define CALIBRATION_CFG_CMD 0x65
  211. #define CALIBRATION_RES_NOTIFICATION 0x66
  212. #define CALIBRATION_COMPLETE_NOTIFICATION 0x67
  213. /* Measurements */
  214. #define REPLY_QUIET_CMD 0x71
  215. #define REPLY_CHANNEL_SWITCH 0x72
  216. #define CHANNEL_SWITCH_NOTIFICATION 0x73
  217. #define REPLY_SPECTRUM_MEASUREMENT_CMD 0x74
  218. #define SPECTRUM_MEASURE_NOTIFICATION 0x75
  219. #define REPLY_MEASUREMENT_ABORT_CMD 0x76
  220. /* Power Management */
  221. #define POWER_TABLE_CMD 0x77
  222. #define SAVE_RESTORE_ADRESS_CMD 0x78
  223. #define REPLY_WATERMARK_CMD 0x79
  224. #define PM_DEBUG_STATISTIC_NOTIFIC 0x7B
  225. #define PD_FLUSH_N_NOTIFICATION 0x7C
  226. /* Scan commands and notifications */
  227. #define REPLY_SCAN_REQUEST_CMD 0x80
  228. #define REPLY_SCAN_ABORT_CMD 0x81
  229. #define SCAN_START_NOTIFICATION 0x82
  230. #define SCAN_RESULTS_NOTIFICATION 0x83
  231. #define SCAN_COMPLETE_NOTIFICATION 0x84
  232. /* Continuous TX commands */
  233. #define REPLY_CONT_TX_CMD 0x85
  234. #define END_OF_CONT_TX_NOTIFICATION 0x86
  235. /* Timer/Eeprom commands */
  236. #define TIMER_CMD 0x87
  237. #define EEPROM_WRITE_CMD 0x88
  238. /* PAPD commands */
  239. #define FEEDBACK_REQUEST_NOTIFICATION 0x8b
  240. #define REPLY_CW_CMD 0x8c
  241. /* IBSS/AP commands Continue */
  242. #define BEACON_NOTIFICATION 0x90
  243. #define REPLY_TX_BEACON 0x91
  244. #define REPLY_REQUEST_ATIM 0x93
  245. #define WHO_IS_AWAKE_NOTIFICATION 0x94
  246. #define TX_PWR_DBM_LIMIT_CMD 0x95
  247. #define QUIET_NOTIFICATION 0x96
  248. #define TX_PWR_TABLE_CMD 0x97
  249. #define TX_ANT_CONFIGURATION_CMD 0x98
  250. #define MEASURE_ABORT_NOTIFICATION 0x99
  251. #define REPLY_CALIBRATION_TUNE 0x9a
  252. /* bt config command */
  253. #define REPLY_BT_CONFIG 0x9b
  254. #define REPLY_STATISTICS_CMD 0x9c
  255. #define STATISTICS_NOTIFICATION 0x9d
  256. /* RF-KILL commands and notifications */
  257. #define REPLY_CARD_STATE_CMD 0xa0
  258. #define CARD_STATE_NOTIFICATION 0xa1
  259. /* Missed beacons notification */
  260. #define MISSED_BEACONS_NOTIFICATION 0xa2
  261. #define MISSED_BEACONS_NOTIFICATION_TH_CMD 0xa3
  262. #define REPLY_CT_KILL_CONFIG_CMD 0xa4
  263. /* HD commands and notifications */
  264. #define REPLY_HD_PARAMS_CMD 0xa6
  265. #define HD_PARAMS_NOTIFICATION 0xa7
  266. #define SENSITIVITY_CMD 0xa8
  267. #define U_APSD_PARAMS_CMD 0xa9
  268. #define NOISY_PLATFORM_CMD 0xaa
  269. #define ILLEGAL_CMD 0xac
  270. #define REPLY_PHY_CALIBRATION_CMD 0xb0
  271. #define REPLAY_RX_GAIN_CALIB_CMD 0xb1
  272. /* WiPAN commands */
  273. #define REPLY_WIPAN_PARAMS_CMD 0xb2
  274. #define REPLY_WIPAN_RX_ON_CMD 0xb3
  275. #define REPLY_WIPAN_RX_ON_TIMING 0xb4
  276. #define REPLY_WIPAN_TX_PWR_TABLE_CMD 0xb5
  277. #define REPLY_WIPAN_RXON_ASSOC_CMD 0xb6
  278. #define REPLY_WIPAN_QOS_PARAM 0xb7
  279. #define WIPAN_REPLY_WEPKEY 0xb8
  280. /* BeamForming commands */
  281. #define BEAMFORMER_CFG_CMD 0xba
  282. #define BEAMFORMEE_NOTIFICATION 0xbb
  283. /* TGn new Commands */
  284. #define REPLY_RX_PHY_CMD 0xc0
  285. #define REPLY_RX_MPDU_CMD 0xc1
  286. #define REPLY_MULTICAST_HASH 0xc2
  287. #define REPLY_KDR_RX 0xc3
  288. #define REPLY_RX_DSP_EXT_INFO 0xc4
  289. #define REPLY_COMPRESSED_BA 0xc5
  290. /* PNC commands */
  291. #define PNC_CONFIG_CMD 0xc8
  292. #define PNC_UPDATE_TABLE_CMD 0xc9
  293. #define XVT_GENERAL_CTRL_CMD 0xca
  294. #define REPLY_LEGACY_RADIO_FE 0xdd
  295. /* WoWLAN commands */
  296. #define WOWLAN_PATTERNS 0xe0
  297. #define WOWLAN_WAKEUP_FILTER 0xe1
  298. #define WOWLAN_TSC_RSC_PARAM 0xe2
  299. #define WOWLAN_TKIP_PARAM 0xe3
  300. #define WOWLAN_KEK_KCK_MATERIAL 0xe4
  301. #define WOWLAN_GET_STATUSES 0xe5
  302. #define WOWLAN_TX_POWER_PER_DB 0xe6
  303. #define REPLY_WOWLAN_GET_STATUSES WOWLAN_GET_STATUSES
  304. #define REPLY_DEBUG_CMD 0xf0
  305. #define REPLY_DSP_DEBUG_CMD 0xf1
  306. #define REPLY_DEBUG_MONITOR_CMD 0xf2
  307. #define REPLY_DEBUG_XVT_CMD 0xf3
  308. #define REPLY_DEBUG_DC_CALIB 0xf4
  309. #define REPLY_DYNAMIC_BP 0xf5
  310. /* General purpose Commands */
  311. #define REPLY_GP1_CMD 0xfa
  312. #define REPLY_GP2_CMD 0xfb
  313. #define REPLY_GP3_CMD 0xfc
  314. #define REPLY_GP4_CMD 0xfd
  315. #define REPLY_REPLAY_WRAPPER 0xfe
  316. #define REPLY_FRAME_DURATION_CALC_CMD 0xff
  317. #define LMAC_COMMAND_ID_MAX 0xff
  318. #define LMAC_COMMAND_ID_NUM (LMAC_COMMAND_ID_MAX + 1)
  319. /* Calibration */
  320. enum {
  321. PHY_CALIBRATE_DC_CMD = 0,
  322. PHY_CALIBRATE_LO_CMD = 1,
  323. PHY_CALIBRATE_RX_BB_CMD = 2,
  324. PHY_CALIBRATE_TX_IQ_CMD = 3,
  325. PHY_CALIBRATE_RX_IQ_CMD = 4,
  326. PHY_CALIBRATION_NOISE_CMD = 5,
  327. PHY_CALIBRATE_AGC_TABLE_CMD = 6,
  328. PHY_CALIBRATE_CRYSTAL_FRQ_CMD = 7,
  329. PHY_CALIBRATE_OPCODES_NUM,
  330. SHILOH_PHY_CALIBRATE_DC_CMD = 8,
  331. SHILOH_PHY_CALIBRATE_LO_CMD = 9,
  332. SHILOH_PHY_CALIBRATE_RX_BB_CMD = 10,
  333. SHILOH_PHY_CALIBRATE_TX_IQ_CMD = 11,
  334. SHILOH_PHY_CALIBRATE_RX_IQ_CMD = 12,
  335. SHILOH_PHY_CALIBRATION_NOISE_CMD = 13,
  336. SHILOH_PHY_CALIBRATE_AGC_TABLE_CMD = 14,
  337. SHILOH_PHY_CALIBRATE_CRYSTAL_FRQ_CMD = 15,
  338. SHILOH_PHY_CALIBRATE_BASE_BAND_CMD = 16,
  339. SHILOH_PHY_CALIBRATE_TXIQ_PERIODIC_CMD = 17,
  340. CALIBRATION_CMD_NUM,
  341. };
  342. enum {
  343. CALIB_CFG_RX_BB_IDX = 0,
  344. CALIB_CFG_DC_IDX = 1,
  345. CALIB_CFG_LO_IDX = 2,
  346. CALIB_CFG_TX_IQ_IDX = 3,
  347. CALIB_CFG_RX_IQ_IDX = 4,
  348. CALIB_CFG_NOISE_IDX = 5,
  349. CALIB_CFG_CRYSTAL_IDX = 6,
  350. CALIB_CFG_TEMPERATURE_IDX = 7,
  351. CALIB_CFG_PAPD_IDX = 8,
  352. CALIB_CFG_LAST_IDX = CALIB_CFG_PAPD_IDX,
  353. CALIB_CFG_MODULE_NUM,
  354. };
  355. #define IWM_CALIB_MAP_INIT_MSK 0xFFFF
  356. #define IWM_CALIB_MAP_PER_LMAC(m) ((m & 0xFF0000) >> 16)
  357. #define IWM_CALIB_MAP_PER_UMAC(m) ((m & 0xFF000000) >> 24)
  358. #define IWM_CALIB_OPCODE_TO_INDEX(op) (op - PHY_CALIBRATE_OPCODES_NUM)
  359. struct iwm_lmac_calib_hdr {
  360. u8 opcode;
  361. u8 first_grp;
  362. u8 grp_num;
  363. u8 all_data_valid;
  364. } __attribute__ ((packed));
  365. #define IWM_LMAC_CALIB_FREQ_GROUPS_NR 7
  366. #define IWM_CALIB_FREQ_GROUPS_NR 5
  367. #define IWM_CALIB_DC_MODES_NR 12
  368. struct iwm_calib_rxiq_entry {
  369. u16 ptam_postdist_ars;
  370. u16 ptam_postdist_arc;
  371. } __attribute__ ((packed));
  372. struct iwm_calib_rxiq_group {
  373. struct iwm_calib_rxiq_entry mode[IWM_CALIB_DC_MODES_NR];
  374. } __attribute__ ((packed));
  375. struct iwm_lmac_calib_rxiq {
  376. struct iwm_calib_rxiq_group group[IWM_LMAC_CALIB_FREQ_GROUPS_NR];
  377. } __attribute__ ((packed));
  378. struct iwm_calib_rxiq {
  379. struct iwm_lmac_calib_hdr hdr;
  380. struct iwm_calib_rxiq_group group[IWM_CALIB_FREQ_GROUPS_NR];
  381. } __attribute__ ((packed));
  382. #define LMAC_STA_ID_SEED 0x0f
  383. #define LMAC_STA_ID_POS 0
  384. #define LMAC_STA_COLOR_SEED 0x7
  385. #define LMAC_STA_COLOR_POS 4
  386. struct iwm_lmac_power_report {
  387. u8 pa_status;
  388. u8 pa_integ_res_A[3];
  389. u8 pa_integ_res_B[3];
  390. u8 pa_integ_res_C[3];
  391. } __attribute__ ((packed));
  392. struct iwm_lmac_tx_resp {
  393. u8 frame_cnt; /* 1-no aggregation, greater then 1 - aggregation */
  394. u8 bt_kill_cnt;
  395. __le16 retry_cnt;
  396. __le32 initial_tx_rate;
  397. __le16 wireless_media_time;
  398. struct iwm_lmac_power_report power_report;
  399. __le32 tfd_info;
  400. __le16 seq_ctl;
  401. __le16 byte_cnt;
  402. u8 tlc_rate_info;
  403. u8 ra_tid;
  404. __le16 frame_ctl;
  405. __le32 status;
  406. } __attribute__ ((packed));
  407. #endif