fw.h 31 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226
  1. /*
  2. * Marvell Wireless LAN device driver: Firmware specific macros & structures
  3. *
  4. * Copyright (C) 2011, Marvell International Ltd.
  5. *
  6. * This software file (the "File") is distributed by Marvell International
  7. * Ltd. under the terms of the GNU General Public License Version 2, June 1991
  8. * (the "License"). You may use, redistribute and/or modify this File in
  9. * accordance with the terms and conditions of the License, a copy of which
  10. * is available by writing to the Free Software Foundation, Inc.,
  11. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA or on the
  12. * worldwide web at http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
  13. *
  14. * THE FILE IS DISTRIBUTED AS-IS, WITHOUT WARRANTY OF ANY KIND, AND THE
  15. * IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE
  16. * ARE EXPRESSLY DISCLAIMED. The License provides additional details about
  17. * this warranty disclaimer.
  18. */
  19. #ifndef _MWIFIEX_FW_H_
  20. #define _MWIFIEX_FW_H_
  21. #include <linux/if_ether.h>
  22. #define INTF_HEADER_LEN 4
  23. struct rfc_1042_hdr {
  24. u8 llc_dsap;
  25. u8 llc_ssap;
  26. u8 llc_ctrl;
  27. u8 snap_oui[3];
  28. u16 snap_type;
  29. };
  30. struct rx_packet_hdr {
  31. struct ethhdr eth803_hdr;
  32. struct rfc_1042_hdr rfc1042_hdr;
  33. };
  34. struct tx_packet_hdr {
  35. struct ethhdr eth803_hdr;
  36. struct rfc_1042_hdr rfc1042_hdr;
  37. };
  38. #define B_SUPPORTED_RATES 5
  39. #define G_SUPPORTED_RATES 9
  40. #define BG_SUPPORTED_RATES 13
  41. #define A_SUPPORTED_RATES 9
  42. #define HOSTCMD_SUPPORTED_RATES 14
  43. #define N_SUPPORTED_RATES 3
  44. #define ALL_802_11_BANDS (BAND_A | BAND_B | BAND_G | BAND_GN)
  45. #define FW_MULTI_BANDS_SUPPORT (BIT(8) | BIT(9) | BIT(10) | BIT(11))
  46. #define IS_SUPPORT_MULTI_BANDS(adapter) \
  47. (adapter->fw_cap_info & FW_MULTI_BANDS_SUPPORT)
  48. #define GET_FW_DEFAULT_BANDS(adapter) \
  49. ((adapter->fw_cap_info >> 8) & ALL_802_11_BANDS)
  50. #define HostCmd_WEP_KEY_INDEX_MASK 0x3fff
  51. #define KEY_INFO_ENABLED 0x01
  52. enum KEY_TYPE_ID {
  53. KEY_TYPE_ID_WEP = 0,
  54. KEY_TYPE_ID_TKIP,
  55. KEY_TYPE_ID_AES,
  56. KEY_TYPE_ID_WAPI,
  57. };
  58. #define KEY_MCAST BIT(0)
  59. #define KEY_UNICAST BIT(1)
  60. #define KEY_ENABLED BIT(2)
  61. #define WAPI_KEY_LEN 50
  62. #define MAX_POLL_TRIES 100
  63. #define MAX_MULTI_INTERFACE_POLL_TRIES 1000
  64. #define MAX_FIRMWARE_POLL_TRIES 100
  65. #define FIRMWARE_READY_SDIO 0xfedc
  66. #define FIRMWARE_READY_PCIE 0xfedcba00
  67. enum MWIFIEX_802_11_PRIVACY_FILTER {
  68. MWIFIEX_802_11_PRIV_FILTER_ACCEPT_ALL,
  69. MWIFIEX_802_11_PRIV_FILTER_8021X_WEP
  70. };
  71. #define CAL_SNR(RSSI, NF) ((s16)((s16)(RSSI)-(s16)(NF)))
  72. #define PROPRIETARY_TLV_BASE_ID 0x0100
  73. #define TLV_TYPE_KEY_MATERIAL (PROPRIETARY_TLV_BASE_ID + 0)
  74. #define TLV_TYPE_CHANLIST (PROPRIETARY_TLV_BASE_ID + 1)
  75. #define TLV_TYPE_NUMPROBES (PROPRIETARY_TLV_BASE_ID + 2)
  76. #define TLV_TYPE_RSSI_LOW (PROPRIETARY_TLV_BASE_ID + 4)
  77. #define TLV_TYPE_PASSTHROUGH (PROPRIETARY_TLV_BASE_ID + 10)
  78. #define TLV_TYPE_WMMQSTATUS (PROPRIETARY_TLV_BASE_ID + 16)
  79. #define TLV_TYPE_WILDCARDSSID (PROPRIETARY_TLV_BASE_ID + 18)
  80. #define TLV_TYPE_TSFTIMESTAMP (PROPRIETARY_TLV_BASE_ID + 19)
  81. #define TLV_TYPE_RSSI_HIGH (PROPRIETARY_TLV_BASE_ID + 22)
  82. #define TLV_TYPE_AUTH_TYPE (PROPRIETARY_TLV_BASE_ID + 31)
  83. #define TLV_TYPE_CHANNELBANDLIST (PROPRIETARY_TLV_BASE_ID + 42)
  84. #define TLV_TYPE_RATE_DROP_CONTROL (PROPRIETARY_TLV_BASE_ID + 82)
  85. #define TLV_TYPE_RATE_SCOPE (PROPRIETARY_TLV_BASE_ID + 83)
  86. #define TLV_TYPE_POWER_GROUP (PROPRIETARY_TLV_BASE_ID + 84)
  87. #define TLV_TYPE_WAPI_IE (PROPRIETARY_TLV_BASE_ID + 94)
  88. #define TLV_TYPE_AUTO_DS_PARAM (PROPRIETARY_TLV_BASE_ID + 113)
  89. #define TLV_TYPE_PS_PARAM (PROPRIETARY_TLV_BASE_ID + 114)
  90. #define MWIFIEX_TX_DATA_BUF_SIZE_2K 2048
  91. #define SSN_MASK 0xfff0
  92. #define BA_RESULT_SUCCESS 0x0
  93. #define BA_RESULT_TIMEOUT 0x2
  94. #define IS_BASTREAM_SETUP(ptr) (ptr->ba_status)
  95. #define BA_STREAM_NOT_ALLOWED 0xff
  96. #define IS_11N_ENABLED(priv) ((priv->adapter->config_bands & BAND_GN || \
  97. priv->adapter->config_bands & BAND_AN) && \
  98. priv->curr_bss_params.bss_descriptor.bcn_ht_cap)
  99. #define INITIATOR_BIT(DelBAParamSet) (((DelBAParamSet) &\
  100. BIT(DELBA_INITIATOR_POS)) >> DELBA_INITIATOR_POS)
  101. #define MWIFIEX_TX_DATA_BUF_SIZE_4K 4096
  102. #define MWIFIEX_TX_DATA_BUF_SIZE_8K 8192
  103. #define ISSUPP_11NENABLED(FwCapInfo) (FwCapInfo & BIT(11))
  104. /* dev_cap bitmap
  105. * BIT
  106. * 0-16 reserved
  107. * 17 IEEE80211_HT_CAP_SUP_WIDTH_20_40
  108. * 18-22 reserved
  109. * 23 IEEE80211_HT_CAP_SGI_20
  110. * 24 IEEE80211_HT_CAP_SGI_40
  111. * 25 IEEE80211_HT_CAP_TX_STBC
  112. * 26 IEEE80211_HT_CAP_RX_STBC
  113. * 27-28 reserved
  114. * 29 IEEE80211_HT_CAP_GRN_FLD
  115. * 30-31 reserved
  116. */
  117. #define ISSUPP_CHANWIDTH40(Dot11nDevCap) (Dot11nDevCap & BIT(17))
  118. #define ISSUPP_SHORTGI20(Dot11nDevCap) (Dot11nDevCap & BIT(23))
  119. #define ISSUPP_SHORTGI40(Dot11nDevCap) (Dot11nDevCap & BIT(24))
  120. #define ISSUPP_TXSTBC(Dot11nDevCap) (Dot11nDevCap & BIT(25))
  121. #define ISSUPP_RXSTBC(Dot11nDevCap) (Dot11nDevCap & BIT(26))
  122. #define ISSUPP_GREENFIELD(Dot11nDevCap) (Dot11nDevCap & BIT(29))
  123. /* httxcfg bitmap
  124. * 0 reserved
  125. * 1 20/40 Mhz enable(1)/disable(0)
  126. * 2-3 reserved
  127. * 4 green field enable(1)/disable(0)
  128. * 5 short GI in 20 Mhz enable(1)/disable(0)
  129. * 6 short GI in 40 Mhz enable(1)/disable(0)
  130. * 7-15 reserved
  131. */
  132. #define MWIFIEX_FW_DEF_HTTXCFG (BIT(1) | BIT(4) | BIT(5) | BIT(6))
  133. #define GET_RXMCSSUPP(DevMCSSupported) (DevMCSSupported & 0x0f)
  134. #define SETHT_MCS32(x) (x[4] |= 1)
  135. #define HT_STREAM_2X2 0x22
  136. #define SET_SECONDARYCHAN(RadioType, SECCHAN) (RadioType |= (SECCHAN << 4))
  137. #define LLC_SNAP_LEN 8
  138. #define MOD_CLASS_HR_DSSS 0x03
  139. #define MOD_CLASS_OFDM 0x07
  140. #define MOD_CLASS_HT 0x08
  141. #define HT_BW_20 0
  142. #define HT_BW_40 1
  143. #define HostCmd_CMD_GET_HW_SPEC 0x0003
  144. #define HostCmd_CMD_802_11_SCAN 0x0006
  145. #define HostCmd_CMD_802_11_GET_LOG 0x000b
  146. #define HostCmd_CMD_MAC_MULTICAST_ADR 0x0010
  147. #define HostCmd_CMD_802_11_EEPROM_ACCESS 0x0059
  148. #define HostCmd_CMD_802_11_ASSOCIATE 0x0012
  149. #define HostCmd_CMD_802_11_SNMP_MIB 0x0016
  150. #define HostCmd_CMD_MAC_REG_ACCESS 0x0019
  151. #define HostCmd_CMD_BBP_REG_ACCESS 0x001a
  152. #define HostCmd_CMD_RF_REG_ACCESS 0x001b
  153. #define HostCmd_CMD_PMIC_REG_ACCESS 0x00ad
  154. #define HostCmd_CMD_802_11_RF_CHANNEL 0x001d
  155. #define HostCmd_CMD_802_11_DEAUTHENTICATE 0x0024
  156. #define HostCmd_CMD_MAC_CONTROL 0x0028
  157. #define HostCmd_CMD_802_11_AD_HOC_START 0x002b
  158. #define HostCmd_CMD_802_11_AD_HOC_JOIN 0x002c
  159. #define HostCmd_CMD_802_11_AD_HOC_STOP 0x0040
  160. #define HostCmd_CMD_802_11_MAC_ADDRESS 0x004D
  161. #define HostCmd_CMD_802_11D_DOMAIN_INFO 0x005b
  162. #define HostCmd_CMD_802_11_KEY_MATERIAL 0x005e
  163. #define HostCmd_CMD_802_11_BG_SCAN_QUERY 0x006c
  164. #define HostCmd_CMD_WMM_GET_STATUS 0x0071
  165. #define HostCmd_CMD_802_11_SUBSCRIBE_EVENT 0x0075
  166. #define HostCmd_CMD_802_11_TX_RATE_QUERY 0x007f
  167. #define HostCmd_CMD_802_11_IBSS_COALESCING_STATUS 0x0083
  168. #define HostCmd_CMD_VERSION_EXT 0x0097
  169. #define HostCmd_CMD_RSSI_INFO 0x00a4
  170. #define HostCmd_CMD_FUNC_INIT 0x00a9
  171. #define HostCmd_CMD_FUNC_SHUTDOWN 0x00aa
  172. #define HostCmd_CMD_11N_CFG 0x00cd
  173. #define HostCmd_CMD_11N_ADDBA_REQ 0x00ce
  174. #define HostCmd_CMD_11N_ADDBA_RSP 0x00cf
  175. #define HostCmd_CMD_11N_DELBA 0x00d0
  176. #define HostCmd_CMD_RECONFIGURE_TX_BUFF 0x00d9
  177. #define HostCmd_CMD_AMSDU_AGGR_CTRL 0x00df
  178. #define HostCmd_CMD_TXPWR_CFG 0x00d1
  179. #define HostCmd_CMD_TX_RATE_CFG 0x00d6
  180. #define HostCmd_CMD_802_11_PS_MODE_ENH 0x00e4
  181. #define HostCmd_CMD_802_11_HS_CFG_ENH 0x00e5
  182. #define HostCmd_CMD_CAU_REG_ACCESS 0x00ed
  183. #define HostCmd_CMD_SET_BSS_MODE 0x00f7
  184. #define HostCmd_CMD_PCIE_DESC_DETAILS 0x00fa
  185. enum ENH_PS_MODES {
  186. EN_PS = 1,
  187. DIS_PS = 2,
  188. EN_AUTO_DS = 3,
  189. DIS_AUTO_DS = 4,
  190. SLEEP_CONFIRM = 5,
  191. GET_PS = 0,
  192. EN_AUTO_PS = 0xff,
  193. DIS_AUTO_PS = 0xfe,
  194. };
  195. #define HostCmd_RET_BIT 0x8000
  196. #define HostCmd_ACT_GEN_GET 0x0000
  197. #define HostCmd_ACT_GEN_SET 0x0001
  198. #define HostCmd_ACT_BITWISE_SET 0x0002
  199. #define HostCmd_ACT_BITWISE_CLR 0x0003
  200. #define HostCmd_RESULT_OK 0x0000
  201. #define HostCmd_ACT_MAC_RX_ON 0x0001
  202. #define HostCmd_ACT_MAC_TX_ON 0x0002
  203. #define HostCmd_ACT_MAC_WEP_ENABLE 0x0008
  204. #define HostCmd_ACT_MAC_ETHERNETII_ENABLE 0x0010
  205. #define HostCmd_ACT_MAC_PROMISCUOUS_ENABLE 0x0080
  206. #define HostCmd_ACT_MAC_ALL_MULTICAST_ENABLE 0x0100
  207. #define HostCmd_ACT_MAC_ADHOC_G_PROTECTION_ON 0x2000
  208. #define HostCmd_BSS_MODE_IBSS 0x0002
  209. #define HostCmd_BSS_MODE_ANY 0x0003
  210. #define HostCmd_SCAN_RADIO_TYPE_BG 0
  211. #define HostCmd_SCAN_RADIO_TYPE_A 1
  212. #define HOST_SLEEP_CFG_CANCEL 0xffffffff
  213. #define HOST_SLEEP_CFG_COND_DEF 0x0000000f
  214. #define HOST_SLEEP_CFG_GPIO_DEF 0xff
  215. #define HOST_SLEEP_CFG_GAP_DEF 0
  216. #define CMD_F_HOSTCMD (1 << 0)
  217. #define CMD_F_CANCELED (1 << 1)
  218. #define HostCmd_CMD_ID_MASK 0x0fff
  219. #define HostCmd_SEQ_NUM_MASK 0x00ff
  220. #define HostCmd_BSS_NUM_MASK 0x0f00
  221. #define HostCmd_BSS_TYPE_MASK 0xf000
  222. #define HostCmd_SET_SEQ_NO_BSS_INFO(seq, num, type) { \
  223. (((seq) & 0x00ff) | \
  224. (((num) & 0x000f) << 8)) | \
  225. (((type) & 0x000f) << 12); }
  226. #define HostCmd_GET_SEQ_NO(seq) \
  227. ((seq) & HostCmd_SEQ_NUM_MASK)
  228. #define HostCmd_GET_BSS_NO(seq) \
  229. (((seq) & HostCmd_BSS_NUM_MASK) >> 8)
  230. #define HostCmd_GET_BSS_TYPE(seq) \
  231. (((seq) & HostCmd_BSS_TYPE_MASK) >> 12)
  232. #define EVENT_DUMMY_HOST_WAKEUP_SIGNAL 0x00000001
  233. #define EVENT_LINK_LOST 0x00000003
  234. #define EVENT_LINK_SENSED 0x00000004
  235. #define EVENT_MIB_CHANGED 0x00000006
  236. #define EVENT_INIT_DONE 0x00000007
  237. #define EVENT_DEAUTHENTICATED 0x00000008
  238. #define EVENT_DISASSOCIATED 0x00000009
  239. #define EVENT_PS_AWAKE 0x0000000a
  240. #define EVENT_PS_SLEEP 0x0000000b
  241. #define EVENT_MIC_ERR_MULTICAST 0x0000000d
  242. #define EVENT_MIC_ERR_UNICAST 0x0000000e
  243. #define EVENT_DEEP_SLEEP_AWAKE 0x00000010
  244. #define EVENT_ADHOC_BCN_LOST 0x00000011
  245. #define EVENT_WMM_STATUS_CHANGE 0x00000017
  246. #define EVENT_BG_SCAN_REPORT 0x00000018
  247. #define EVENT_RSSI_LOW 0x00000019
  248. #define EVENT_SNR_LOW 0x0000001a
  249. #define EVENT_MAX_FAIL 0x0000001b
  250. #define EVENT_RSSI_HIGH 0x0000001c
  251. #define EVENT_SNR_HIGH 0x0000001d
  252. #define EVENT_IBSS_COALESCED 0x0000001e
  253. #define EVENT_DATA_RSSI_LOW 0x00000024
  254. #define EVENT_DATA_SNR_LOW 0x00000025
  255. #define EVENT_DATA_RSSI_HIGH 0x00000026
  256. #define EVENT_DATA_SNR_HIGH 0x00000027
  257. #define EVENT_LINK_QUALITY 0x00000028
  258. #define EVENT_PORT_RELEASE 0x0000002b
  259. #define EVENT_PRE_BEACON_LOST 0x00000031
  260. #define EVENT_ADDBA 0x00000033
  261. #define EVENT_DELBA 0x00000034
  262. #define EVENT_BA_STREAM_TIEMOUT 0x00000037
  263. #define EVENT_AMSDU_AGGR_CTRL 0x00000042
  264. #define EVENT_WEP_ICV_ERR 0x00000046
  265. #define EVENT_HS_ACT_REQ 0x00000047
  266. #define EVENT_BW_CHANGE 0x00000048
  267. #define EVENT_HOSTWAKE_STAIE 0x0000004d
  268. #define EVENT_ID_MASK 0xffff
  269. #define BSS_NUM_MASK 0xf
  270. #define EVENT_GET_BSS_NUM(event_cause) \
  271. (((event_cause) >> 16) & BSS_NUM_MASK)
  272. #define EVENT_GET_BSS_TYPE(event_cause) \
  273. (((event_cause) >> 24) & 0x00ff)
  274. struct mwifiex_ie_types_header {
  275. __le16 type;
  276. __le16 len;
  277. } __packed;
  278. struct mwifiex_ie_types_data {
  279. struct mwifiex_ie_types_header header;
  280. u8 data[1];
  281. } __packed;
  282. #define MWIFIEX_TxPD_POWER_MGMT_NULL_PACKET 0x01
  283. #define MWIFIEX_TxPD_POWER_MGMT_LAST_PACKET 0x08
  284. struct txpd {
  285. u8 bss_type;
  286. u8 bss_num;
  287. __le16 tx_pkt_length;
  288. __le16 tx_pkt_offset;
  289. __le16 tx_pkt_type;
  290. __le32 tx_control;
  291. u8 priority;
  292. u8 flags;
  293. u8 pkt_delay_2ms;
  294. u8 reserved1;
  295. } __packed;
  296. struct rxpd {
  297. u8 bss_type;
  298. u8 bss_num;
  299. u16 rx_pkt_length;
  300. u16 rx_pkt_offset;
  301. u16 rx_pkt_type;
  302. u16 seq_num;
  303. u8 priority;
  304. u8 rx_rate;
  305. s8 snr;
  306. s8 nf;
  307. /* Ht Info [Bit 0] RxRate format: LG=0, HT=1
  308. * [Bit 1] HT Bandwidth: BW20 = 0, BW40 = 1
  309. * [Bit 2] HT Guard Interval: LGI = 0, SGI = 1 */
  310. u8 ht_info;
  311. u8 reserved;
  312. } __packed;
  313. enum mwifiex_chan_scan_mode_bitmasks {
  314. MWIFIEX_PASSIVE_SCAN = BIT(0),
  315. MWIFIEX_DISABLE_CHAN_FILT = BIT(1),
  316. };
  317. struct mwifiex_chan_scan_param_set {
  318. u8 radio_type;
  319. u8 chan_number;
  320. u8 chan_scan_mode_bitmap;
  321. __le16 min_scan_time;
  322. __le16 max_scan_time;
  323. } __packed;
  324. struct mwifiex_ie_types_chan_list_param_set {
  325. struct mwifiex_ie_types_header header;
  326. struct mwifiex_chan_scan_param_set chan_scan_param[1];
  327. } __packed;
  328. struct chan_band_param_set {
  329. u8 radio_type;
  330. u8 chan_number;
  331. };
  332. struct mwifiex_ie_types_chan_band_list_param_set {
  333. struct mwifiex_ie_types_header header;
  334. struct chan_band_param_set chan_band_param[1];
  335. } __packed;
  336. struct mwifiex_ie_types_rates_param_set {
  337. struct mwifiex_ie_types_header header;
  338. u8 rates[1];
  339. } __packed;
  340. struct mwifiex_ie_types_ssid_param_set {
  341. struct mwifiex_ie_types_header header;
  342. u8 ssid[1];
  343. } __packed;
  344. struct mwifiex_ie_types_num_probes {
  345. struct mwifiex_ie_types_header header;
  346. __le16 num_probes;
  347. } __packed;
  348. struct mwifiex_ie_types_wildcard_ssid_params {
  349. struct mwifiex_ie_types_header header;
  350. u8 max_ssid_length;
  351. u8 ssid[1];
  352. } __packed;
  353. #define TSF_DATA_SIZE 8
  354. struct mwifiex_ie_types_tsf_timestamp {
  355. struct mwifiex_ie_types_header header;
  356. u8 tsf_data[1];
  357. } __packed;
  358. struct mwifiex_cf_param_set {
  359. u8 cfp_cnt;
  360. u8 cfp_period;
  361. u16 cfp_max_duration;
  362. u16 cfp_duration_remaining;
  363. } __packed;
  364. struct mwifiex_ibss_param_set {
  365. u16 atim_window;
  366. } __packed;
  367. struct mwifiex_ie_types_ss_param_set {
  368. struct mwifiex_ie_types_header header;
  369. union {
  370. struct mwifiex_cf_param_set cf_param_set[1];
  371. struct mwifiex_ibss_param_set ibss_param_set[1];
  372. } cf_ibss;
  373. } __packed;
  374. struct mwifiex_fh_param_set {
  375. u16 dwell_time;
  376. u8 hop_set;
  377. u8 hop_pattern;
  378. u8 hop_index;
  379. } __packed;
  380. struct mwifiex_ds_param_set {
  381. u8 current_chan;
  382. } __packed;
  383. struct mwifiex_ie_types_phy_param_set {
  384. struct mwifiex_ie_types_header header;
  385. union {
  386. struct mwifiex_fh_param_set fh_param_set[1];
  387. struct mwifiex_ds_param_set ds_param_set[1];
  388. } fh_ds;
  389. } __packed;
  390. struct mwifiex_ie_types_auth_type {
  391. struct mwifiex_ie_types_header header;
  392. __le16 auth_type;
  393. } __packed;
  394. struct mwifiex_ie_types_vendor_param_set {
  395. struct mwifiex_ie_types_header header;
  396. u8 ie[MWIFIEX_MAX_VSIE_LEN];
  397. };
  398. struct mwifiex_ie_types_rsn_param_set {
  399. struct mwifiex_ie_types_header header;
  400. u8 rsn_ie[1];
  401. } __packed;
  402. #define KEYPARAMSET_FIXED_LEN 6
  403. struct mwifiex_ie_type_key_param_set {
  404. __le16 type;
  405. __le16 length;
  406. __le16 key_type_id;
  407. __le16 key_info;
  408. __le16 key_len;
  409. u8 key[50];
  410. } __packed;
  411. struct host_cmd_ds_802_11_key_material {
  412. __le16 action;
  413. struct mwifiex_ie_type_key_param_set key_param_set;
  414. } __packed;
  415. struct host_cmd_ds_gen {
  416. u16 command;
  417. u16 size;
  418. u16 seq_num;
  419. u16 result;
  420. };
  421. #define S_DS_GEN sizeof(struct host_cmd_ds_gen)
  422. enum sleep_resp_ctrl {
  423. RESP_NOT_NEEDED = 0,
  424. RESP_NEEDED,
  425. };
  426. struct mwifiex_ps_param {
  427. __le16 null_pkt_interval;
  428. __le16 multiple_dtims;
  429. __le16 bcn_miss_timeout;
  430. __le16 local_listen_interval;
  431. __le16 adhoc_wake_period;
  432. __le16 mode;
  433. __le16 delay_to_ps;
  434. };
  435. #define BITMAP_AUTO_DS 0x01
  436. #define BITMAP_STA_PS 0x10
  437. struct mwifiex_ie_types_auto_ds_param {
  438. struct mwifiex_ie_types_header header;
  439. __le16 deep_sleep_timeout;
  440. } __packed;
  441. struct mwifiex_ie_types_ps_param {
  442. struct mwifiex_ie_types_header header;
  443. struct mwifiex_ps_param param;
  444. } __packed;
  445. struct host_cmd_ds_802_11_ps_mode_enh {
  446. __le16 action;
  447. union {
  448. struct mwifiex_ps_param opt_ps;
  449. __le16 ps_bitmap;
  450. } params;
  451. } __packed;
  452. struct host_cmd_ds_get_hw_spec {
  453. __le16 hw_if_version;
  454. __le16 version;
  455. __le16 reserved;
  456. __le16 num_of_mcast_adr;
  457. u8 permanent_addr[ETH_ALEN];
  458. __le16 region_code;
  459. __le16 number_of_antenna;
  460. __le32 fw_release_number;
  461. __le32 reserved_1;
  462. __le32 reserved_2;
  463. __le32 reserved_3;
  464. __le32 fw_cap_info;
  465. __le32 dot_11n_dev_cap;
  466. u8 dev_mcs_support;
  467. __le16 mp_end_port; /* SDIO only, reserved for other interfacces */
  468. __le16 reserved_4;
  469. } __packed;
  470. struct host_cmd_ds_802_11_rssi_info {
  471. __le16 action;
  472. __le16 ndata;
  473. __le16 nbcn;
  474. __le16 reserved[9];
  475. long long reserved_1;
  476. };
  477. struct host_cmd_ds_802_11_rssi_info_rsp {
  478. __le16 action;
  479. __le16 ndata;
  480. __le16 nbcn;
  481. __le16 data_rssi_last;
  482. __le16 data_nf_last;
  483. __le16 data_rssi_avg;
  484. __le16 data_nf_avg;
  485. __le16 bcn_rssi_last;
  486. __le16 bcn_nf_last;
  487. __le16 bcn_rssi_avg;
  488. __le16 bcn_nf_avg;
  489. long long tsf_bcn;
  490. };
  491. struct host_cmd_ds_802_11_mac_address {
  492. __le16 action;
  493. u8 mac_addr[ETH_ALEN];
  494. };
  495. struct host_cmd_ds_mac_control {
  496. __le16 action;
  497. __le16 reserved;
  498. };
  499. struct host_cmd_ds_mac_multicast_adr {
  500. __le16 action;
  501. __le16 num_of_adrs;
  502. u8 mac_list[MWIFIEX_MAX_MULTICAST_LIST_SIZE][ETH_ALEN];
  503. } __packed;
  504. struct host_cmd_ds_802_11_deauthenticate {
  505. u8 mac_addr[ETH_ALEN];
  506. __le16 reason_code;
  507. } __packed;
  508. struct host_cmd_ds_802_11_associate {
  509. u8 peer_sta_addr[ETH_ALEN];
  510. __le16 cap_info_bitmap;
  511. __le16 listen_interval;
  512. __le16 beacon_period;
  513. u8 dtim_period;
  514. } __packed;
  515. struct ieee_types_assoc_rsp {
  516. __le16 cap_info_bitmap;
  517. __le16 status_code;
  518. __le16 a_id;
  519. u8 ie_buffer[1];
  520. } __packed;
  521. struct host_cmd_ds_802_11_associate_rsp {
  522. struct ieee_types_assoc_rsp assoc_rsp;
  523. } __packed;
  524. struct ieee_types_cf_param_set {
  525. u8 element_id;
  526. u8 len;
  527. u8 cfp_cnt;
  528. u8 cfp_period;
  529. u16 cfp_max_duration;
  530. u16 cfp_duration_remaining;
  531. } __packed;
  532. struct ieee_types_ibss_param_set {
  533. u8 element_id;
  534. u8 len;
  535. __le16 atim_window;
  536. } __packed;
  537. union ieee_types_ss_param_set {
  538. struct ieee_types_cf_param_set cf_param_set;
  539. struct ieee_types_ibss_param_set ibss_param_set;
  540. } __packed;
  541. struct ieee_types_fh_param_set {
  542. u8 element_id;
  543. u8 len;
  544. __le16 dwell_time;
  545. u8 hop_set;
  546. u8 hop_pattern;
  547. u8 hop_index;
  548. } __packed;
  549. struct ieee_types_ds_param_set {
  550. u8 element_id;
  551. u8 len;
  552. u8 current_chan;
  553. } __packed;
  554. union ieee_types_phy_param_set {
  555. struct ieee_types_fh_param_set fh_param_set;
  556. struct ieee_types_ds_param_set ds_param_set;
  557. } __packed;
  558. struct host_cmd_ds_802_11_ad_hoc_start {
  559. u8 ssid[IEEE80211_MAX_SSID_LEN];
  560. u8 bss_mode;
  561. __le16 beacon_period;
  562. u8 dtim_period;
  563. union ieee_types_ss_param_set ss_param_set;
  564. union ieee_types_phy_param_set phy_param_set;
  565. u16 reserved1;
  566. __le16 cap_info_bitmap;
  567. u8 data_rate[HOSTCMD_SUPPORTED_RATES];
  568. } __packed;
  569. struct host_cmd_ds_802_11_ad_hoc_result {
  570. u8 pad[3];
  571. u8 bssid[ETH_ALEN];
  572. } __packed;
  573. struct adhoc_bss_desc {
  574. u8 bssid[ETH_ALEN];
  575. u8 ssid[IEEE80211_MAX_SSID_LEN];
  576. u8 bss_mode;
  577. __le16 beacon_period;
  578. u8 dtim_period;
  579. u8 time_stamp[8];
  580. u8 local_time[8];
  581. union ieee_types_phy_param_set phy_param_set;
  582. union ieee_types_ss_param_set ss_param_set;
  583. __le16 cap_info_bitmap;
  584. u8 data_rates[HOSTCMD_SUPPORTED_RATES];
  585. /*
  586. * DO NOT ADD ANY FIELDS TO THIS STRUCTURE.
  587. * It is used in the Adhoc join command and will cause a
  588. * binary layout mismatch with the firmware
  589. */
  590. } __packed;
  591. struct host_cmd_ds_802_11_ad_hoc_join {
  592. struct adhoc_bss_desc bss_descriptor;
  593. u16 reserved1;
  594. u16 reserved2;
  595. } __packed;
  596. struct host_cmd_ds_802_11_get_log {
  597. __le32 mcast_tx_frame;
  598. __le32 failed;
  599. __le32 retry;
  600. __le32 multi_retry;
  601. __le32 frame_dup;
  602. __le32 rts_success;
  603. __le32 rts_failure;
  604. __le32 ack_failure;
  605. __le32 rx_frag;
  606. __le32 mcast_rx_frame;
  607. __le32 fcs_error;
  608. __le32 tx_frame;
  609. __le32 reserved;
  610. __le32 wep_icv_err_cnt[4];
  611. };
  612. struct host_cmd_ds_tx_rate_query {
  613. u8 tx_rate;
  614. /* Ht Info [Bit 0] RxRate format: LG=0, HT=1
  615. * [Bit 1] HT Bandwidth: BW20 = 0, BW40 = 1
  616. * [Bit 2] HT Guard Interval: LGI = 0, SGI = 1 */
  617. u8 ht_info;
  618. } __packed;
  619. enum Host_Sleep_Action {
  620. HS_CONFIGURE = 0x0001,
  621. HS_ACTIVATE = 0x0002,
  622. };
  623. struct mwifiex_hs_config_param {
  624. __le32 conditions;
  625. u8 gpio;
  626. u8 gap;
  627. } __packed;
  628. struct hs_activate_param {
  629. u16 resp_ctrl;
  630. } __packed;
  631. struct host_cmd_ds_802_11_hs_cfg_enh {
  632. __le16 action;
  633. union {
  634. struct mwifiex_hs_config_param hs_config;
  635. struct hs_activate_param hs_activate;
  636. } params;
  637. } __packed;
  638. enum SNMP_MIB_INDEX {
  639. OP_RATE_SET_I = 1,
  640. DTIM_PERIOD_I = 3,
  641. RTS_THRESH_I = 5,
  642. SHORT_RETRY_LIM_I = 6,
  643. LONG_RETRY_LIM_I = 7,
  644. FRAG_THRESH_I = 8,
  645. DOT11D_I = 9,
  646. };
  647. #define MAX_SNMP_BUF_SIZE 128
  648. struct host_cmd_ds_802_11_snmp_mib {
  649. __le16 query_type;
  650. __le16 oid;
  651. __le16 buf_size;
  652. u8 value[1];
  653. } __packed;
  654. struct mwifiex_rate_scope {
  655. __le16 type;
  656. __le16 length;
  657. __le16 hr_dsss_rate_bitmap;
  658. __le16 ofdm_rate_bitmap;
  659. __le16 ht_mcs_rate_bitmap[8];
  660. } __packed;
  661. struct mwifiex_rate_drop_pattern {
  662. __le16 type;
  663. __le16 length;
  664. __le32 rate_drop_mode;
  665. } __packed;
  666. struct host_cmd_ds_tx_rate_cfg {
  667. __le16 action;
  668. __le16 cfg_index;
  669. } __packed;
  670. struct mwifiex_power_group {
  671. u8 modulation_class;
  672. u8 first_rate_code;
  673. u8 last_rate_code;
  674. s8 power_step;
  675. s8 power_min;
  676. s8 power_max;
  677. u8 ht_bandwidth;
  678. u8 reserved;
  679. } __packed;
  680. struct mwifiex_types_power_group {
  681. u16 type;
  682. u16 length;
  683. } __packed;
  684. struct host_cmd_ds_txpwr_cfg {
  685. __le16 action;
  686. __le16 cfg_index;
  687. __le32 mode;
  688. } __packed;
  689. struct mwifiex_bcn_param {
  690. u8 bssid[ETH_ALEN];
  691. u8 rssi;
  692. __le32 timestamp[2];
  693. __le16 beacon_period;
  694. __le16 cap_info_bitmap;
  695. } __packed;
  696. #define MWIFIEX_USER_SCAN_CHAN_MAX 50
  697. #define MWIFIEX_MAX_SSID_LIST_LENGTH 10
  698. struct mwifiex_scan_cmd_config {
  699. /*
  700. * BSS mode to be sent in the firmware command
  701. */
  702. u8 bss_mode;
  703. /* Specific BSSID used to filter scan results in the firmware */
  704. u8 specific_bssid[ETH_ALEN];
  705. /* Length of TLVs sent in command starting at tlvBuffer */
  706. u32 tlv_buf_len;
  707. /*
  708. * SSID TLV(s) and ChanList TLVs to be sent in the firmware command
  709. *
  710. * TLV_TYPE_CHANLIST, mwifiex_ie_types_chan_list_param_set
  711. * WLAN_EID_SSID, mwifiex_ie_types_ssid_param_set
  712. */
  713. u8 tlv_buf[1]; /* SSID TLV(s) and ChanList TLVs are stored
  714. here */
  715. } __packed;
  716. struct mwifiex_user_scan_chan {
  717. u8 chan_number;
  718. u8 radio_type;
  719. u8 scan_type;
  720. u8 reserved;
  721. u32 scan_time;
  722. } __packed;
  723. struct mwifiex_user_scan_cfg {
  724. /*
  725. * BSS mode to be sent in the firmware command
  726. */
  727. u8 bss_mode;
  728. /* Configure the number of probe requests for active chan scans */
  729. u8 num_probes;
  730. u8 reserved;
  731. /* BSSID filter sent in the firmware command to limit the results */
  732. u8 specific_bssid[ETH_ALEN];
  733. /* SSID filter list used in the firmware to limit the scan results */
  734. struct cfg80211_ssid *ssid_list;
  735. u8 num_ssids;
  736. /* Variable number (fixed maximum) of channels to scan up */
  737. struct mwifiex_user_scan_chan chan_list[MWIFIEX_USER_SCAN_CHAN_MAX];
  738. } __packed;
  739. struct ie_body {
  740. u8 grp_key_oui[4];
  741. u8 ptk_cnt[2];
  742. u8 ptk_body[4];
  743. } __packed;
  744. struct host_cmd_ds_802_11_scan {
  745. u8 bss_mode;
  746. u8 bssid[ETH_ALEN];
  747. u8 tlv_buffer[1];
  748. } __packed;
  749. struct host_cmd_ds_802_11_scan_rsp {
  750. __le16 bss_descript_size;
  751. u8 number_of_sets;
  752. u8 bss_desc_and_tlv_buffer[1];
  753. } __packed;
  754. struct host_cmd_ds_802_11_bg_scan_query {
  755. u8 flush;
  756. } __packed;
  757. struct host_cmd_ds_802_11_bg_scan_query_rsp {
  758. u32 report_condition;
  759. struct host_cmd_ds_802_11_scan_rsp scan_resp;
  760. } __packed;
  761. struct mwifiex_ietypes_domain_param_set {
  762. struct mwifiex_ie_types_header header;
  763. u8 country_code[IEEE80211_COUNTRY_STRING_LEN];
  764. struct ieee80211_country_ie_triplet triplet[1];
  765. } __packed;
  766. struct host_cmd_ds_802_11d_domain_info {
  767. __le16 action;
  768. struct mwifiex_ietypes_domain_param_set domain;
  769. } __packed;
  770. struct host_cmd_ds_802_11d_domain_info_rsp {
  771. __le16 action;
  772. struct mwifiex_ietypes_domain_param_set domain;
  773. } __packed;
  774. struct host_cmd_ds_11n_addba_req {
  775. u8 add_req_result;
  776. u8 peer_mac_addr[ETH_ALEN];
  777. u8 dialog_token;
  778. __le16 block_ack_param_set;
  779. __le16 block_ack_tmo;
  780. __le16 ssn;
  781. } __packed;
  782. struct host_cmd_ds_11n_addba_rsp {
  783. u8 add_rsp_result;
  784. u8 peer_mac_addr[ETH_ALEN];
  785. u8 dialog_token;
  786. __le16 status_code;
  787. __le16 block_ack_param_set;
  788. __le16 block_ack_tmo;
  789. __le16 ssn;
  790. } __packed;
  791. struct host_cmd_ds_11n_delba {
  792. u8 del_result;
  793. u8 peer_mac_addr[ETH_ALEN];
  794. __le16 del_ba_param_set;
  795. __le16 reason_code;
  796. u8 reserved;
  797. } __packed;
  798. struct host_cmd_ds_11n_batimeout {
  799. u8 tid;
  800. u8 peer_mac_addr[ETH_ALEN];
  801. u8 origninator;
  802. } __packed;
  803. struct host_cmd_ds_11n_cfg {
  804. __le16 action;
  805. __le16 ht_tx_cap;
  806. __le16 ht_tx_info;
  807. } __packed;
  808. struct host_cmd_ds_txbuf_cfg {
  809. __le16 action;
  810. __le16 buff_size;
  811. __le16 mp_end_port; /* SDIO only, reserved for other interfacces */
  812. __le16 reserved3;
  813. } __packed;
  814. struct host_cmd_ds_amsdu_aggr_ctrl {
  815. __le16 action;
  816. __le16 enable;
  817. __le16 curr_buf_size;
  818. } __packed;
  819. struct mwifiex_ie_types_wmm_param_set {
  820. struct mwifiex_ie_types_header header;
  821. u8 wmm_ie[1];
  822. };
  823. struct mwifiex_ie_types_wmm_queue_status {
  824. struct mwifiex_ie_types_header header;
  825. u8 queue_index;
  826. u8 disabled;
  827. u16 medium_time;
  828. u8 flow_required;
  829. u8 flow_created;
  830. u32 reserved;
  831. };
  832. struct ieee_types_vendor_header {
  833. u8 element_id;
  834. u8 len;
  835. u8 oui[3];
  836. u8 oui_type;
  837. u8 oui_subtype;
  838. u8 version;
  839. } __packed;
  840. struct ieee_types_wmm_ac_parameters {
  841. u8 aci_aifsn_bitmap;
  842. u8 ecw_bitmap;
  843. __le16 tx_op_limit;
  844. } __packed;
  845. struct ieee_types_wmm_parameter {
  846. /*
  847. * WMM Parameter IE - Vendor Specific Header:
  848. * element_id [221/0xdd]
  849. * Len [24]
  850. * Oui [00:50:f2]
  851. * OuiType [2]
  852. * OuiSubType [1]
  853. * Version [1]
  854. */
  855. struct ieee_types_vendor_header vend_hdr;
  856. u8 qos_info_bitmap;
  857. u8 reserved;
  858. struct ieee_types_wmm_ac_parameters ac_params[IEEE80211_MAX_QUEUES];
  859. } __packed;
  860. struct ieee_types_wmm_info {
  861. /*
  862. * WMM Info IE - Vendor Specific Header:
  863. * element_id [221/0xdd]
  864. * Len [7]
  865. * Oui [00:50:f2]
  866. * OuiType [2]
  867. * OuiSubType [0]
  868. * Version [1]
  869. */
  870. struct ieee_types_vendor_header vend_hdr;
  871. u8 qos_info_bitmap;
  872. } __packed;
  873. struct host_cmd_ds_wmm_get_status {
  874. u8 queue_status_tlv[sizeof(struct mwifiex_ie_types_wmm_queue_status) *
  875. IEEE80211_MAX_QUEUES];
  876. u8 wmm_param_tlv[sizeof(struct ieee_types_wmm_parameter) + 2];
  877. } __packed;
  878. struct mwifiex_wmm_ac_status {
  879. u8 disabled;
  880. u8 flow_required;
  881. u8 flow_created;
  882. };
  883. struct mwifiex_ie_types_htcap {
  884. struct mwifiex_ie_types_header header;
  885. struct ieee80211_ht_cap ht_cap;
  886. } __packed;
  887. struct mwifiex_ie_types_htinfo {
  888. struct mwifiex_ie_types_header header;
  889. struct ieee80211_ht_operation ht_oper;
  890. } __packed;
  891. struct mwifiex_ie_types_2040bssco {
  892. struct mwifiex_ie_types_header header;
  893. u8 bss_co_2040;
  894. } __packed;
  895. struct mwifiex_ie_types_extcap {
  896. struct mwifiex_ie_types_header header;
  897. u8 ext_cap;
  898. } __packed;
  899. struct host_cmd_ds_mac_reg_access {
  900. __le16 action;
  901. __le16 offset;
  902. __le32 value;
  903. } __packed;
  904. struct host_cmd_ds_bbp_reg_access {
  905. __le16 action;
  906. __le16 offset;
  907. u8 value;
  908. u8 reserved[3];
  909. } __packed;
  910. struct host_cmd_ds_rf_reg_access {
  911. __le16 action;
  912. __le16 offset;
  913. u8 value;
  914. u8 reserved[3];
  915. } __packed;
  916. struct host_cmd_ds_pmic_reg_access {
  917. __le16 action;
  918. __le16 offset;
  919. u8 value;
  920. u8 reserved[3];
  921. } __packed;
  922. struct host_cmd_ds_802_11_eeprom_access {
  923. __le16 action;
  924. __le16 offset;
  925. __le16 byte_count;
  926. u8 value;
  927. } __packed;
  928. struct host_cmd_ds_802_11_rf_channel {
  929. __le16 action;
  930. __le16 current_channel;
  931. __le16 rf_type;
  932. __le16 reserved;
  933. u8 reserved_1[32];
  934. } __packed;
  935. struct host_cmd_ds_version_ext {
  936. u8 version_str_sel;
  937. char version_str[128];
  938. } __packed;
  939. struct host_cmd_ds_802_11_ibss_status {
  940. __le16 action;
  941. __le16 enable;
  942. u8 bssid[ETH_ALEN];
  943. __le16 beacon_interval;
  944. __le16 atim_window;
  945. __le16 use_g_rate_protect;
  946. } __packed;
  947. #define CONNECTION_TYPE_INFRA 0
  948. #define CONNECTION_TYPE_ADHOC 1
  949. struct host_cmd_ds_set_bss_mode {
  950. u8 con_type;
  951. } __packed;
  952. struct host_cmd_ds_pcie_details {
  953. /* TX buffer descriptor ring address */
  954. u32 txbd_addr_lo;
  955. u32 txbd_addr_hi;
  956. /* TX buffer descriptor ring count */
  957. u32 txbd_count;
  958. /* RX buffer descriptor ring address */
  959. u32 rxbd_addr_lo;
  960. u32 rxbd_addr_hi;
  961. /* RX buffer descriptor ring count */
  962. u32 rxbd_count;
  963. /* Event buffer descriptor ring address */
  964. u32 evtbd_addr_lo;
  965. u32 evtbd_addr_hi;
  966. /* Event buffer descriptor ring count */
  967. u32 evtbd_count;
  968. /* Sleep cookie buffer physical address */
  969. u32 sleep_cookie_addr_lo;
  970. u32 sleep_cookie_addr_hi;
  971. } __packed;
  972. struct mwifiex_ie_types_rssi_threshold {
  973. struct mwifiex_ie_types_header header;
  974. u8 abs_value;
  975. u8 evt_freq;
  976. } __packed;
  977. struct host_cmd_ds_802_11_subsc_evt {
  978. __le16 action;
  979. __le16 events;
  980. } __packed;
  981. struct host_cmd_ds_command {
  982. __le16 command;
  983. __le16 size;
  984. __le16 seq_num;
  985. __le16 result;
  986. union {
  987. struct host_cmd_ds_get_hw_spec hw_spec;
  988. struct host_cmd_ds_mac_control mac_ctrl;
  989. struct host_cmd_ds_802_11_mac_address mac_addr;
  990. struct host_cmd_ds_mac_multicast_adr mc_addr;
  991. struct host_cmd_ds_802_11_get_log get_log;
  992. struct host_cmd_ds_802_11_rssi_info rssi_info;
  993. struct host_cmd_ds_802_11_rssi_info_rsp rssi_info_rsp;
  994. struct host_cmd_ds_802_11_snmp_mib smib;
  995. struct host_cmd_ds_802_11_rf_channel rf_channel;
  996. struct host_cmd_ds_tx_rate_query tx_rate;
  997. struct host_cmd_ds_tx_rate_cfg tx_rate_cfg;
  998. struct host_cmd_ds_txpwr_cfg txp_cfg;
  999. struct host_cmd_ds_802_11_ps_mode_enh psmode_enh;
  1000. struct host_cmd_ds_802_11_hs_cfg_enh opt_hs_cfg;
  1001. struct host_cmd_ds_802_11_scan scan;
  1002. struct host_cmd_ds_802_11_scan_rsp scan_resp;
  1003. struct host_cmd_ds_802_11_bg_scan_query bg_scan_query;
  1004. struct host_cmd_ds_802_11_bg_scan_query_rsp bg_scan_query_resp;
  1005. struct host_cmd_ds_802_11_associate associate;
  1006. struct host_cmd_ds_802_11_associate_rsp associate_rsp;
  1007. struct host_cmd_ds_802_11_deauthenticate deauth;
  1008. struct host_cmd_ds_802_11_ad_hoc_start adhoc_start;
  1009. struct host_cmd_ds_802_11_ad_hoc_result adhoc_result;
  1010. struct host_cmd_ds_802_11_ad_hoc_join adhoc_join;
  1011. struct host_cmd_ds_802_11d_domain_info domain_info;
  1012. struct host_cmd_ds_802_11d_domain_info_rsp domain_info_resp;
  1013. struct host_cmd_ds_11n_addba_req add_ba_req;
  1014. struct host_cmd_ds_11n_addba_rsp add_ba_rsp;
  1015. struct host_cmd_ds_11n_delba del_ba;
  1016. struct host_cmd_ds_txbuf_cfg tx_buf;
  1017. struct host_cmd_ds_amsdu_aggr_ctrl amsdu_aggr_ctrl;
  1018. struct host_cmd_ds_11n_cfg htcfg;
  1019. struct host_cmd_ds_wmm_get_status get_wmm_status;
  1020. struct host_cmd_ds_802_11_key_material key_material;
  1021. struct host_cmd_ds_version_ext verext;
  1022. struct host_cmd_ds_802_11_ibss_status ibss_coalescing;
  1023. struct host_cmd_ds_mac_reg_access mac_reg;
  1024. struct host_cmd_ds_bbp_reg_access bbp_reg;
  1025. struct host_cmd_ds_rf_reg_access rf_reg;
  1026. struct host_cmd_ds_pmic_reg_access pmic_reg;
  1027. struct host_cmd_ds_set_bss_mode bss_mode;
  1028. struct host_cmd_ds_pcie_details pcie_host_spec;
  1029. struct host_cmd_ds_802_11_eeprom_access eeprom;
  1030. struct host_cmd_ds_802_11_subsc_evt subsc_evt;
  1031. } params;
  1032. } __packed;
  1033. struct mwifiex_opt_sleep_confirm {
  1034. __le16 command;
  1035. __le16 size;
  1036. __le16 seq_num;
  1037. __le16 result;
  1038. __le16 action;
  1039. __le16 resp_ctrl;
  1040. } __packed;
  1041. #endif /* !_MWIFIEX_FW_H_ */