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