blob: 6a703ea18800b417f839ecc284a8d05a74ea6c9f [file] [log] [blame]
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001/*
2 * Marvell Wireless LAN device driver: Firmware specific macros & structures
3 *
Xinming Hu65da33f2014-06-19 21:38:57 -07004 * Copyright (C) 2011-2014, Marvell International Ltd.
Bing Zhao5e6e3a92011-03-21 18:00:50 -07005 *
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];
Amitkumar Karwara6efc5b2013-12-02 23:17:49 -080033 __be16 snap_type;
Bing Zhao5e6e3a92011-03-21 18:00:50 -070034};
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
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -080052#define ALL_802_11_BANDS (BAND_A | BAND_B | BAND_G | BAND_GN | \
Bing Zhaof25b1432014-02-07 16:21:01 -080053 BAND_AN | BAND_AAC)
Bing Zhao5e6e3a92011-03-21 18:00:50 -070054
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -080055#define FW_MULTI_BANDS_SUPPORT (BIT(8) | BIT(9) | BIT(10) | BIT(11) | \
Bing Zhaof25b1432014-02-07 16:21:01 -080056 BIT(13))
Bing Zhao5e6e3a92011-03-21 18:00:50 -070057#define IS_SUPPORT_MULTI_BANDS(adapter) \
58 (adapter->fw_cap_info & FW_MULTI_BANDS_SUPPORT)
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -080059
Bing Zhaof25b1432014-02-07 16:21:01 -080060/* bit 13: 11ac BAND_AAC
61 * bit 12: reserved for lab testing, will be reused for BAND_AN
62 * bit 11: 11n BAND_GN
63 * bit 10: 11a BAND_A
64 * bit 9: 11g BAND_G
65 * bit 8: 11b BAND_B
66 * Map these bits to band capability by right shifting 8 bits.
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -080067 */
Bing Zhao5e6e3a92011-03-21 18:00:50 -070068#define GET_FW_DEFAULT_BANDS(adapter) \
Bing Zhaof25b1432014-02-07 16:21:01 -080069 (((adapter->fw_cap_info & 0x2f00) >> 8) & \
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -080070 ALL_802_11_BANDS)
Bing Zhao5e6e3a92011-03-21 18:00:50 -070071
Bing Zhao5e6e3a92011-03-21 18:00:50 -070072#define HostCmd_WEP_KEY_INDEX_MASK 0x3fff
73
74#define KEY_INFO_ENABLED 0x01
75enum KEY_TYPE_ID {
76 KEY_TYPE_ID_WEP = 0,
77 KEY_TYPE_ID_TKIP,
78 KEY_TYPE_ID_AES,
79 KEY_TYPE_ID_WAPI,
Ying Luob877f4c2012-08-03 18:06:14 -070080 KEY_TYPE_ID_AES_CMAC,
Bing Zhao5e6e3a92011-03-21 18:00:50 -070081};
Avinash Patile57f1732014-02-07 16:32:35 -080082
83#define WPA_PN_SIZE 8
84#define KEY_PARAMS_FIXED_LEN 10
85#define KEY_INDEX_MASK 0xf
Amitkumar Karwar4b9fede2014-08-19 08:24:25 -040086#define KEY_API_VER_MAJOR_V2 2
Avinash Patile57f1732014-02-07 16:32:35 -080087
Yogesh Ashok Powar6a35a0a2011-04-06 16:46:56 -070088#define KEY_MCAST BIT(0)
89#define KEY_UNICAST BIT(1)
90#define KEY_ENABLED BIT(2)
Avinash Patile57f1732014-02-07 16:32:35 -080091#define KEY_DEFAULT BIT(3)
92#define KEY_TX_KEY BIT(4)
93#define KEY_RX_KEY BIT(5)
Ying Luob877f4c2012-08-03 18:06:14 -070094#define KEY_IGTK BIT(10)
Bing Zhao5e6e3a92011-03-21 18:00:50 -070095
Avinash Patile57f1732014-02-07 16:32:35 -080096#define WAPI_KEY_LEN (WLAN_KEY_LEN_SMS4 + PN_LEN + 2)
Bing Zhao5e6e3a92011-03-21 18:00:50 -070097
Bing Zhao5e6e3a92011-03-21 18:00:50 -070098#define MAX_POLL_TRIES 100
Bing Zhao5e6e3a92011-03-21 18:00:50 -070099#define MAX_FIRMWARE_POLL_TRIES 100
100
Amitkumar Karward930fae2011-10-11 17:41:21 -0700101#define FIRMWARE_READY_SDIO 0xfedc
102#define FIRMWARE_READY_PCIE 0xfedcba00
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700103
Amitkumar Karwar4daffe32012-04-18 20:08:28 -0700104enum mwifiex_usb_ep {
105 MWIFIEX_USB_EP_CMD_EVENT = 1,
106 MWIFIEX_USB_EP_DATA = 2,
107};
108
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700109enum MWIFIEX_802_11_PRIVACY_FILTER {
110 MWIFIEX_802_11_PRIV_FILTER_ACCEPT_ALL,
111 MWIFIEX_802_11_PRIV_FILTER_8021X_WEP
112};
113
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700114#define CAL_SNR(RSSI, NF) ((s16)((s16)(RSSI)-(s16)(NF)))
Stone Piao2dbaf752012-09-25 20:23:35 -0700115#define CAL_RSSI(SNR, NF) ((s16)((s16)(SNR)+(s16)(NF)))
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700116
Avinash Patile76268d2012-05-08 18:30:27 -0700117#define UAP_BSS_PARAMS_I 0
Avinash Patilede98bf2012-05-08 18:30:28 -0700118#define UAP_CUSTOM_IE_I 1
119#define MWIFIEX_AUTO_IDX_MASK 0xffff
120#define MWIFIEX_DELETE_MASK 0x0000
Avinash Patilf31acab2012-05-08 18:30:29 -0700121#define MGMT_MASK_ASSOC_REQ 0x01
122#define MGMT_MASK_REASSOC_REQ 0x04
123#define MGMT_MASK_ASSOC_RESP 0x02
124#define MGMT_MASK_REASSOC_RESP 0x08
125#define MGMT_MASK_PROBE_REQ 0x10
126#define MGMT_MASK_PROBE_RESP 0x20
127#define MGMT_MASK_BEACON 0x100
Avinash Patile76268d2012-05-08 18:30:27 -0700128
Avinash Patil12190c52012-05-08 18:30:24 -0700129#define TLV_TYPE_UAP_SSID 0x0000
Avinash Patila3c2c4f2012-08-27 20:32:53 -0700130#define TLV_TYPE_UAP_RATES 0x0001
Avinash Patil12190c52012-05-08 18:30:24 -0700131
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700132#define PROPRIETARY_TLV_BASE_ID 0x0100
133#define TLV_TYPE_KEY_MATERIAL (PROPRIETARY_TLV_BASE_ID + 0)
134#define TLV_TYPE_CHANLIST (PROPRIETARY_TLV_BASE_ID + 1)
135#define TLV_TYPE_NUMPROBES (PROPRIETARY_TLV_BASE_ID + 2)
Amitkumar Karwarfa444bf2012-03-15 20:51:51 -0700136#define TLV_TYPE_RSSI_LOW (PROPRIETARY_TLV_BASE_ID + 4)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700137#define TLV_TYPE_PASSTHROUGH (PROPRIETARY_TLV_BASE_ID + 10)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700138#define TLV_TYPE_WMMQSTATUS (PROPRIETARY_TLV_BASE_ID + 16)
139#define TLV_TYPE_WILDCARDSSID (PROPRIETARY_TLV_BASE_ID + 18)
140#define TLV_TYPE_TSFTIMESTAMP (PROPRIETARY_TLV_BASE_ID + 19)
Amitkumar Karwarfa444bf2012-03-15 20:51:51 -0700141#define TLV_TYPE_RSSI_HIGH (PROPRIETARY_TLV_BASE_ID + 22)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700142#define TLV_TYPE_AUTH_TYPE (PROPRIETARY_TLV_BASE_ID + 31)
Avinash Patil75edd2c2012-05-08 18:30:18 -0700143#define TLV_TYPE_STA_MAC_ADDR (PROPRIETARY_TLV_BASE_ID + 32)
Amitkumar Karwar21f58d202014-02-11 18:39:56 -0800144#define TLV_TYPE_BSSID (PROPRIETARY_TLV_BASE_ID + 35)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700145#define TLV_TYPE_CHANNELBANDLIST (PROPRIETARY_TLV_BASE_ID + 42)
Avinash Patil12190c52012-05-08 18:30:24 -0700146#define TLV_TYPE_UAP_BEACON_PERIOD (PROPRIETARY_TLV_BASE_ID + 44)
147#define TLV_TYPE_UAP_DTIM_PERIOD (PROPRIETARY_TLV_BASE_ID + 45)
Avinash Patil605b73a2012-05-16 21:24:55 -0700148#define TLV_TYPE_UAP_BCAST_SSID (PROPRIETARY_TLV_BASE_ID + 48)
Avinash Patil9b930ea2012-05-08 18:30:23 -0700149#define TLV_TYPE_UAP_RTS_THRESHOLD (PROPRIETARY_TLV_BASE_ID + 51)
Kevin Gan8b4509f2012-09-25 20:23:45 -0700150#define TLV_TYPE_UAP_AO_TIMER (PROPRIETARY_TLV_BASE_ID + 57)
Avinash Patil96893532012-06-15 12:21:55 -0700151#define TLV_TYPE_UAP_WEP_KEY (PROPRIETARY_TLV_BASE_ID + 59)
Avinash Patilf752dcd2012-05-08 18:30:26 -0700152#define TLV_TYPE_UAP_WPA_PASSPHRASE (PROPRIETARY_TLV_BASE_ID + 60)
153#define TLV_TYPE_UAP_ENCRY_PROTOCOL (PROPRIETARY_TLV_BASE_ID + 64)
154#define TLV_TYPE_UAP_AKMP (PROPRIETARY_TLV_BASE_ID + 65)
Avinash Patil9b930ea2012-05-08 18:30:23 -0700155#define TLV_TYPE_UAP_FRAG_THRESHOLD (PROPRIETARY_TLV_BASE_ID + 70)
Marc Yang2b06bdb2011-03-30 18:12:44 -0700156#define TLV_TYPE_RATE_DROP_CONTROL (PROPRIETARY_TLV_BASE_ID + 82)
157#define TLV_TYPE_RATE_SCOPE (PROPRIETARY_TLV_BASE_ID + 83)
158#define TLV_TYPE_POWER_GROUP (PROPRIETARY_TLV_BASE_ID + 84)
Amitkumar Karwar21f58d202014-02-11 18:39:56 -0800159#define TLV_TYPE_BSS_SCAN_RSP (PROPRIETARY_TLV_BASE_ID + 86)
160#define TLV_TYPE_BSS_SCAN_INFO (PROPRIETARY_TLV_BASE_ID + 87)
Avinash Patil9b930ea2012-05-08 18:30:23 -0700161#define TLV_TYPE_UAP_RETRY_LIMIT (PROPRIETARY_TLV_BASE_ID + 93)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700162#define TLV_TYPE_WAPI_IE (PROPRIETARY_TLV_BASE_ID + 94)
Avinash Patile5686342012-05-08 18:30:25 -0700163#define TLV_TYPE_UAP_MGMT_FRAME (PROPRIETARY_TLV_BASE_ID + 104)
Avinash Patil13d7ba72012-04-09 20:06:56 -0700164#define TLV_TYPE_MGMT_IE (PROPRIETARY_TLV_BASE_ID + 105)
Marc Yang2b06bdb2011-03-30 18:12:44 -0700165#define TLV_TYPE_AUTO_DS_PARAM (PROPRIETARY_TLV_BASE_ID + 113)
166#define TLV_TYPE_PS_PARAM (PROPRIETARY_TLV_BASE_ID + 114)
Kevin Gan8b4509f2012-09-25 20:23:45 -0700167#define TLV_TYPE_UAP_PS_AO_TIMER (PROPRIETARY_TLV_BASE_ID + 123)
Avinash Patilf752dcd2012-05-08 18:30:26 -0700168#define TLV_TYPE_PWK_CIPHER (PROPRIETARY_TLV_BASE_ID + 145)
169#define TLV_TYPE_GWK_CIPHER (PROPRIETARY_TLV_BASE_ID + 146)
Amitkumar Karwar562fc5b2013-08-05 18:52:00 -0700170#define TLV_TYPE_COALESCE_RULE (PROPRIETARY_TLV_BASE_ID + 154)
Avinash Patile57f1732014-02-07 16:32:35 -0800171#define TLV_TYPE_KEY_PARAM_V2 (PROPRIETARY_TLV_BASE_ID + 156)
Avinash Patild29caf22014-05-06 22:02:43 -0700172#define TLV_TYPE_TDLS_IDLE_TIMEOUT (PROPRIETARY_TLV_BASE_ID + 194)
Amitkumar Karwar4b9fede2014-08-19 08:24:25 -0400173#define TLV_TYPE_API_REV (PROPRIETARY_TLV_BASE_ID + 199)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700174
175#define MWIFIEX_TX_DATA_BUF_SIZE_2K 2048
176
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700177#define SSN_MASK 0xfff0
178
179#define BA_RESULT_SUCCESS 0x0
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700180#define BA_RESULT_TIMEOUT 0x2
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700181
182#define IS_BASTREAM_SETUP(ptr) (ptr->ba_status)
183
184#define BA_STREAM_NOT_ALLOWED 0xff
185
186#define IS_11N_ENABLED(priv) ((priv->adapter->config_bands & BAND_GN || \
Yogesh Ashok Powar931f1582012-03-13 19:22:36 -0700187 priv->adapter->config_bands & BAND_AN) && \
188 priv->curr_bss_params.bss_descriptor.bcn_ht_cap)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700189#define INITIATOR_BIT(DelBAParamSet) (((DelBAParamSet) &\
190 BIT(DELBA_INITIATOR_POS)) >> DELBA_INITIATOR_POS)
191
192#define MWIFIEX_TX_DATA_BUF_SIZE_4K 4096
193#define MWIFIEX_TX_DATA_BUF_SIZE_8K 8192
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700194
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700195#define ISSUPP_11NENABLED(FwCapInfo) (FwCapInfo & BIT(11))
Avinash Patilb23bce22014-02-07 16:27:32 -0800196#define ISSUPP_TDLS_ENABLED(FwCapInfo) (FwCapInfo & BIT(14))
Marc Yang6d2bd912011-03-25 19:47:02 -0700197
Avinash Patil22281252012-06-15 12:21:53 -0700198#define MWIFIEX_DEF_HT_CAP (IEEE80211_HT_CAP_DSSSCCK40 | \
199 (1 << IEEE80211_HT_CAP_RX_STBC_SHIFT) | \
200 IEEE80211_HT_CAP_SM_PS)
201
Amitkumar Karwar645097c2014-02-07 16:27:26 -0800202#define MWIFIEX_DEF_11N_TX_BF_CAP 0x09E1E008
203
Avinash Patil22281252012-06-15 12:21:53 -0700204#define MWIFIEX_DEF_AMPDU IEEE80211_HT_AMPDU_PARM_FACTOR
205
Maithili Hinge474a41e2014-03-18 22:24:10 -0700206#define GET_RXSTBC(x) (x & IEEE80211_HT_CAP_RX_STBC)
207#define MWIFIEX_RX_STBC1 0x0100
208#define MWIFIEX_RX_STBC12 0x0200
209#define MWIFIEX_RX_STBC123 0x0300
210
Marc Yang6d2bd912011-03-25 19:47:02 -0700211/* dev_cap bitmap
212 * BIT
213 * 0-16 reserved
214 * 17 IEEE80211_HT_CAP_SUP_WIDTH_20_40
215 * 18-22 reserved
216 * 23 IEEE80211_HT_CAP_SGI_20
217 * 24 IEEE80211_HT_CAP_SGI_40
218 * 25 IEEE80211_HT_CAP_TX_STBC
219 * 26 IEEE80211_HT_CAP_RX_STBC
220 * 27-28 reserved
221 * 29 IEEE80211_HT_CAP_GRN_FLD
222 * 30-31 reserved
223 */
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700224#define ISSUPP_CHANWIDTH40(Dot11nDevCap) (Dot11nDevCap & BIT(17))
Marc Yang6d2bd912011-03-25 19:47:02 -0700225#define ISSUPP_SHORTGI20(Dot11nDevCap) (Dot11nDevCap & BIT(23))
226#define ISSUPP_SHORTGI40(Dot11nDevCap) (Dot11nDevCap & BIT(24))
227#define ISSUPP_TXSTBC(Dot11nDevCap) (Dot11nDevCap & BIT(25))
228#define ISSUPP_RXSTBC(Dot11nDevCap) (Dot11nDevCap & BIT(26))
229#define ISSUPP_GREENFIELD(Dot11nDevCap) (Dot11nDevCap & BIT(29))
Avinash Patildd0d83c2012-11-27 12:09:20 -0800230#define ISENABLED_40MHZ_INTOLERANT(Dot11nDevCap) (Dot11nDevCap & BIT(8))
231#define ISSUPP_RXLDPC(Dot11nDevCap) (Dot11nDevCap & BIT(22))
Amitkumar Karwar645097c2014-02-07 16:27:26 -0800232#define ISSUPP_BEAMFORMING(Dot11nDevCap) (Dot11nDevCap & BIT(30))
Avinash Patil396939f2014-05-06 22:02:45 -0700233#define ISALLOWED_CHANWIDTH40(ht_param) (ht_param & BIT(2))
Marc Yang6d2bd912011-03-25 19:47:02 -0700234
Amitkumar Karwarcd27bc32011-07-08 20:40:30 -0700235/* httxcfg bitmap
236 * 0 reserved
237 * 1 20/40 Mhz enable(1)/disable(0)
238 * 2-3 reserved
239 * 4 green field enable(1)/disable(0)
240 * 5 short GI in 20 Mhz enable(1)/disable(0)
241 * 6 short GI in 40 Mhz enable(1)/disable(0)
242 * 7-15 reserved
243 */
244#define MWIFIEX_FW_DEF_HTTXCFG (BIT(1) | BIT(4) | BIT(5) | BIT(6))
245
Amitkumar Karwara5333912014-02-27 19:35:18 -0800246/* 11AC Tx and Rx MCS map for 1x1 mode:
247 * IEEE80211_VHT_MCS_SUPPORT_0_9 for stream 1
248 * IEEE80211_VHT_MCS_NOT_SUPPORTED for remaining 7 streams
249 */
250#define MWIFIEX_11AC_MCS_MAP_1X1 0xfffefffe
251
252/* 11AC Tx and Rx MCS map for 2x2 mode:
253 * IEEE80211_VHT_MCS_SUPPORT_0_9 for stream 1 and 2
254 * IEEE80211_VHT_MCS_NOT_SUPPORTED for remaining 6 streams
255 */
256#define MWIFIEX_11AC_MCS_MAP_2X2 0xfffafffa
257
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700258#define GET_RXMCSSUPP(DevMCSSupported) (DevMCSSupported & 0x0f)
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700259#define SETHT_MCS32(x) (x[4] |= 1)
Amitkumar Karwara5333912014-02-27 19:35:18 -0800260#define HT_STREAM_1X1 0x11
Bing Zhaoe3bea1c2011-11-16 20:40:35 -0800261#define HT_STREAM_2X2 0x22
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700262
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700263#define SET_SECONDARYCHAN(RadioType, SECCHAN) (RadioType |= (SECCHAN << 4))
264
265#define LLC_SNAP_LEN 8
266
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800267/* HW_SPEC fw_cap_info */
268
Bing Zhaof25b1432014-02-07 16:21:01 -0800269#define ISSUPP_11ACENABLED(fw_cap_info) (fw_cap_info & BIT(13))
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800270
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800271#define GET_VHTCAP_CHWDSET(vht_cap_info) ((vht_cap_info >> 2) & 0x3)
272#define GET_VHTNSSMCS(mcs_mapset, nss) ((mcs_mapset >> (2 * (nss - 1))) & 0x3)
273#define SET_VHTNSSMCS(mcs_mapset, nss, value) (mcs_mapset |= (value & 0x3) << \
274 (2 * (nss - 1)))
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800275#define GET_DEVTXMCSMAP(dev_mcs_map) (dev_mcs_map >> 16)
276#define GET_DEVRXMCSMAP(dev_mcs_map) (dev_mcs_map & 0xFFFF)
277
Amitkumar Karwar79d9a542014-02-07 16:27:27 -0800278/* Clear SU Beanformer, MU beanformer, MU beanformee and
279 * sounding dimensions bits
280 */
281#define MWIFIEX_DEF_11AC_CAP_BF_RESET_MASK \
282 (IEEE80211_VHT_CAP_SU_BEAMFORMER_CAPABLE | \
283 IEEE80211_VHT_CAP_MU_BEAMFORMER_CAPABLE | \
284 IEEE80211_VHT_CAP_MU_BEAMFORMEE_CAPABLE | \
285 IEEE80211_VHT_CAP_SOUNDING_DIMENSIONS_MASK)
286
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700287#define MOD_CLASS_HR_DSSS 0x03
288#define MOD_CLASS_OFDM 0x07
289#define MOD_CLASS_HT 0x08
290#define HT_BW_20 0
291#define HT_BW_40 1
292
Amitkumar Karwarb8876642013-06-18 16:36:58 -0700293#define DFS_CHAN_MOVE_TIME 10000
294
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700295#define HostCmd_CMD_GET_HW_SPEC 0x0003
296#define HostCmd_CMD_802_11_SCAN 0x0006
297#define HostCmd_CMD_802_11_GET_LOG 0x000b
298#define HostCmd_CMD_MAC_MULTICAST_ADR 0x0010
299#define HostCmd_CMD_802_11_EEPROM_ACCESS 0x0059
300#define HostCmd_CMD_802_11_ASSOCIATE 0x0012
301#define HostCmd_CMD_802_11_SNMP_MIB 0x0016
302#define HostCmd_CMD_MAC_REG_ACCESS 0x0019
303#define HostCmd_CMD_BBP_REG_ACCESS 0x001a
304#define HostCmd_CMD_RF_REG_ACCESS 0x001b
305#define HostCmd_CMD_PMIC_REG_ACCESS 0x00ad
Amitkumar Karwarcaa89842012-06-27 19:57:57 -0700306#define HostCmd_CMD_RF_TX_PWR 0x001e
Amitkumar Karwar8a279d52012-07-02 19:32:33 -0700307#define HostCmd_CMD_RF_ANTENNA 0x0020
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700308#define HostCmd_CMD_802_11_DEAUTHENTICATE 0x0024
309#define HostCmd_CMD_MAC_CONTROL 0x0028
310#define HostCmd_CMD_802_11_AD_HOC_START 0x002b
311#define HostCmd_CMD_802_11_AD_HOC_JOIN 0x002c
312#define HostCmd_CMD_802_11_AD_HOC_STOP 0x0040
313#define HostCmd_CMD_802_11_MAC_ADDRESS 0x004D
314#define HostCmd_CMD_802_11D_DOMAIN_INFO 0x005b
315#define HostCmd_CMD_802_11_KEY_MATERIAL 0x005e
316#define HostCmd_CMD_802_11_BG_SCAN_QUERY 0x006c
317#define HostCmd_CMD_WMM_GET_STATUS 0x0071
Amitkumar Karwarfa444bf2012-03-15 20:51:51 -0700318#define HostCmd_CMD_802_11_SUBSCRIBE_EVENT 0x0075
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700319#define HostCmd_CMD_802_11_TX_RATE_QUERY 0x007f
320#define HostCmd_CMD_802_11_IBSS_COALESCING_STATUS 0x0083
Amitkumar Karwar388ec382013-05-17 17:50:25 -0700321#define HostCmd_CMD_CFG_DATA 0x008f
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700322#define HostCmd_CMD_VERSION_EXT 0x0097
Amitkumar Karwar7da060c2013-03-04 16:27:59 -0800323#define HostCmd_CMD_MEF_CFG 0x009a
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700324#define HostCmd_CMD_RSSI_INFO 0x00a4
325#define HostCmd_CMD_FUNC_INIT 0x00a9
326#define HostCmd_CMD_FUNC_SHUTDOWN 0x00aa
Avinash Patil40d07032012-05-08 18:30:19 -0700327#define HostCmd_CMD_UAP_SYS_CONFIG 0x00b0
328#define HostCmd_CMD_UAP_BSS_START 0x00b1
329#define HostCmd_CMD_UAP_BSS_STOP 0x00b2
Avinash Patil0f9e9b82013-05-17 17:50:23 -0700330#define HostCmd_CMD_UAP_STA_DEAUTH 0x00b5
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700331#define HostCmd_CMD_11N_CFG 0x00cd
332#define HostCmd_CMD_11N_ADDBA_REQ 0x00ce
333#define HostCmd_CMD_11N_ADDBA_RSP 0x00cf
334#define HostCmd_CMD_11N_DELBA 0x00d0
335#define HostCmd_CMD_RECONFIGURE_TX_BUFF 0x00d9
336#define HostCmd_CMD_AMSDU_AGGR_CTRL 0x00df
337#define HostCmd_CMD_TXPWR_CFG 0x00d1
338#define HostCmd_CMD_TX_RATE_CFG 0x00d6
339#define HostCmd_CMD_802_11_PS_MODE_ENH 0x00e4
340#define HostCmd_CMD_802_11_HS_CFG_ENH 0x00e5
Stone Piaoe1a2b7a2012-09-25 20:23:41 -0700341#define HostCmd_CMD_P2P_MODE_CFG 0x00eb
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700342#define HostCmd_CMD_CAU_REG_ACCESS 0x00ed
343#define HostCmd_CMD_SET_BSS_MODE 0x00f7
Amitkumar Karward930fae2011-10-11 17:41:21 -0700344#define HostCmd_CMD_PCIE_DESC_DETAILS 0x00fa
Amitkumar Karwar21f58d202014-02-11 18:39:56 -0800345#define HostCmd_CMD_802_11_SCAN_EXT 0x0107
Amitkumar Karwar562fc5b2013-08-05 18:52:00 -0700346#define HostCmd_CMD_COALESCE_CFG 0x010a
Stone Piao3cec6872012-09-25 20:23:34 -0700347#define HostCmd_CMD_MGMT_FRAME_REG 0x010c
Stone Piao7feb4c42012-09-25 20:23:36 -0700348#define HostCmd_CMD_REMAIN_ON_CHAN 0x010d
Yogesh Ashok Powar83c78da2013-03-18 20:06:03 -0700349#define HostCmd_CMD_11AC_CFG 0x0112
Avinash Patil429d90d2014-02-07 16:27:34 -0800350#define HostCmd_CMD_TDLS_OPER 0x0122
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700351
Avinash Patilf752dcd2012-05-08 18:30:26 -0700352#define PROTOCOL_NO_SECURITY 0x01
353#define PROTOCOL_STATIC_WEP 0x02
354#define PROTOCOL_WPA 0x08
355#define PROTOCOL_WPA2 0x20
356#define PROTOCOL_WPA2_MIXED 0x28
357#define PROTOCOL_EAP 0x40
358#define KEY_MGMT_NONE 0x04
359#define KEY_MGMT_PSK 0x02
360#define KEY_MGMT_EAP 0x01
361#define CIPHER_TKIP 0x04
362#define CIPHER_AES_CCMP 0x08
363#define VALID_CIPHER_BITMAP 0x0c
364
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700365enum ENH_PS_MODES {
366 EN_PS = 1,
367 DIS_PS = 2,
368 EN_AUTO_DS = 3,
369 DIS_AUTO_DS = 4,
370 SLEEP_CONFIRM = 5,
371 GET_PS = 0,
372 EN_AUTO_PS = 0xff,
373 DIS_AUTO_PS = 0xfe,
374};
375
Stone Piaoe1a2b7a2012-09-25 20:23:41 -0700376enum P2P_MODES {
377 P2P_MODE_DISABLE = 0,
378 P2P_MODE_DEVICE = 1,
379 P2P_MODE_GO = 2,
380 P2P_MODE_CLIENT = 3,
381};
382
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700383#define HostCmd_RET_BIT 0x8000
384#define HostCmd_ACT_GEN_GET 0x0000
385#define HostCmd_ACT_GEN_SET 0x0001
Stone Piao7feb4c42012-09-25 20:23:36 -0700386#define HostCmd_ACT_GEN_REMOVE 0x0004
Amitkumar Karwarfa444bf2012-03-15 20:51:51 -0700387#define HostCmd_ACT_BITWISE_SET 0x0002
388#define HostCmd_ACT_BITWISE_CLR 0x0003
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700389#define HostCmd_RESULT_OK 0x0000
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700390
391#define HostCmd_ACT_MAC_RX_ON 0x0001
392#define HostCmd_ACT_MAC_TX_ON 0x0002
393#define HostCmd_ACT_MAC_WEP_ENABLE 0x0008
394#define HostCmd_ACT_MAC_ETHERNETII_ENABLE 0x0010
395#define HostCmd_ACT_MAC_PROMISCUOUS_ENABLE 0x0080
396#define HostCmd_ACT_MAC_ALL_MULTICAST_ENABLE 0x0100
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700397#define HostCmd_ACT_MAC_ADHOC_G_PROTECTION_ON 0x2000
398
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700399#define HostCmd_BSS_MODE_IBSS 0x0002
400#define HostCmd_BSS_MODE_ANY 0x0003
401
402#define HostCmd_SCAN_RADIO_TYPE_BG 0
403#define HostCmd_SCAN_RADIO_TYPE_A 1
404
Amitkumar Karwarcc0b5a62013-03-04 16:27:57 -0800405#define HS_CFG_CANCEL 0xffffffff
406#define HS_CFG_COND_DEF 0x00000000
407#define HS_CFG_GPIO_DEF 0xff
Bing Zhao915f36d2014-05-27 21:39:34 -0700408#define HS_CFG_GAP_DEF 0xff
Amitkumar Karwar0d7f53e2013-03-04 16:27:58 -0800409#define HS_CFG_COND_BROADCAST_DATA 0x00000001
410#define HS_CFG_COND_UNICAST_DATA 0x00000002
411#define HS_CFG_COND_MAC_EVENT 0x00000004
412#define HS_CFG_COND_MULTICAST_DATA 0x00000008
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700413
Amitkumar Karwar7532c7d2013-01-17 17:41:57 -0800414#define MWIFIEX_TIMEOUT_FOR_AP_RESP 0xfffc
415#define MWIFIEX_STATUS_CODE_AUTH_TIMEOUT 2
416
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700417#define CMD_F_HOSTCMD (1 << 0)
418#define CMD_F_CANCELED (1 << 1)
419
420#define HostCmd_CMD_ID_MASK 0x0fff
421
422#define HostCmd_SEQ_NUM_MASK 0x00ff
423
424#define HostCmd_BSS_NUM_MASK 0x0f00
425
426#define HostCmd_BSS_TYPE_MASK 0xf000
427
Amitkumar Karwar8a279d52012-07-02 19:32:33 -0700428#define HostCmd_ACT_SET_RX 0x0001
429#define HostCmd_ACT_SET_TX 0x0002
430#define HostCmd_ACT_SET_BOTH 0x0003
431
432#define RF_ANTENNA_AUTO 0xFFFF
433
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700434#define HostCmd_SET_SEQ_NO_BSS_INFO(seq, num, type) { \
435 (((seq) & 0x00ff) | \
436 (((num) & 0x000f) << 8)) | \
437 (((type) & 0x000f) << 12); }
438
439#define HostCmd_GET_SEQ_NO(seq) \
440 ((seq) & HostCmd_SEQ_NUM_MASK)
441
442#define HostCmd_GET_BSS_NO(seq) \
443 (((seq) & HostCmd_BSS_NUM_MASK) >> 8)
444
445#define HostCmd_GET_BSS_TYPE(seq) \
446 (((seq) & HostCmd_BSS_TYPE_MASK) >> 12)
447
448#define EVENT_DUMMY_HOST_WAKEUP_SIGNAL 0x00000001
449#define EVENT_LINK_LOST 0x00000003
450#define EVENT_LINK_SENSED 0x00000004
451#define EVENT_MIB_CHANGED 0x00000006
452#define EVENT_INIT_DONE 0x00000007
453#define EVENT_DEAUTHENTICATED 0x00000008
454#define EVENT_DISASSOCIATED 0x00000009
455#define EVENT_PS_AWAKE 0x0000000a
456#define EVENT_PS_SLEEP 0x0000000b
457#define EVENT_MIC_ERR_MULTICAST 0x0000000d
458#define EVENT_MIC_ERR_UNICAST 0x0000000e
459#define EVENT_DEEP_SLEEP_AWAKE 0x00000010
460#define EVENT_ADHOC_BCN_LOST 0x00000011
461
462#define EVENT_WMM_STATUS_CHANGE 0x00000017
463#define EVENT_BG_SCAN_REPORT 0x00000018
464#define EVENT_RSSI_LOW 0x00000019
465#define EVENT_SNR_LOW 0x0000001a
466#define EVENT_MAX_FAIL 0x0000001b
467#define EVENT_RSSI_HIGH 0x0000001c
468#define EVENT_SNR_HIGH 0x0000001d
469#define EVENT_IBSS_COALESCED 0x0000001e
470#define EVENT_DATA_RSSI_LOW 0x00000024
471#define EVENT_DATA_SNR_LOW 0x00000025
472#define EVENT_DATA_RSSI_HIGH 0x00000026
473#define EVENT_DATA_SNR_HIGH 0x00000027
474#define EVENT_LINK_QUALITY 0x00000028
475#define EVENT_PORT_RELEASE 0x0000002b
Avinash Patile5686342012-05-08 18:30:25 -0700476#define EVENT_UAP_STA_DEAUTH 0x0000002c
477#define EVENT_UAP_STA_ASSOC 0x0000002d
478#define EVENT_UAP_BSS_START 0x0000002e
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700479#define EVENT_PRE_BEACON_LOST 0x00000031
480#define EVENT_ADDBA 0x00000033
481#define EVENT_DELBA 0x00000034
482#define EVENT_BA_STREAM_TIEMOUT 0x00000037
483#define EVENT_AMSDU_AGGR_CTRL 0x00000042
Avinash Patile5686342012-05-08 18:30:25 -0700484#define EVENT_UAP_BSS_IDLE 0x00000043
485#define EVENT_UAP_BSS_ACTIVE 0x00000044
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700486#define EVENT_WEP_ICV_ERR 0x00000046
487#define EVENT_HS_ACT_REQ 0x00000047
488#define EVENT_BW_CHANGE 0x00000048
Avinash Patile5686342012-05-08 18:30:25 -0700489#define EVENT_UAP_MIC_COUNTERMEASURES 0x0000004c
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700490#define EVENT_HOSTWAKE_STAIE 0x0000004d
Amitkumar Karwar2a7305c2013-06-19 08:49:05 -0700491#define EVENT_CHANNEL_SWITCH_ANN 0x00000050
Avinash Patil79ff4342014-05-06 22:02:44 -0700492#define EVENT_TDLS_GENERIC_EVENT 0x00000052
Amitkumar Karwar21f58d202014-02-11 18:39:56 -0800493#define EVENT_EXT_SCAN_REPORT 0x00000058
Stone Piaoeab1c762012-09-25 20:23:37 -0700494#define EVENT_REMAIN_ON_CHAN_EXPIRED 0x0000005f
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700495
496#define EVENT_ID_MASK 0xffff
497#define BSS_NUM_MASK 0xf
498
499#define EVENT_GET_BSS_NUM(event_cause) \
500 (((event_cause) >> 16) & BSS_NUM_MASK)
501
502#define EVENT_GET_BSS_TYPE(event_cause) \
503 (((event_cause) >> 24) & 0x00ff)
504
Amitkumar Karwar7da060c2013-03-04 16:27:59 -0800505#define MWIFIEX_MAX_PATTERN_LEN 20
Amitkumar Karwarafd84de42013-08-05 18:51:59 -0700506#define MWIFIEX_MAX_OFFSET_LEN 100
Amitkumar Karwar7da060c2013-03-04 16:27:59 -0800507#define STACK_NBYTES 100
508#define TYPE_DNUM 1
509#define TYPE_BYTESEQ 2
510#define MAX_OPERAND 0x40
511#define TYPE_EQ (MAX_OPERAND+1)
512#define TYPE_EQ_DNUM (MAX_OPERAND+2)
513#define TYPE_EQ_BIT (MAX_OPERAND+3)
514#define TYPE_AND (MAX_OPERAND+4)
515#define TYPE_OR (MAX_OPERAND+5)
516#define MEF_MODE_HOST_SLEEP 1
517#define MEF_ACTION_ALLOW_AND_WAKEUP_HOST 3
518#define MWIFIEX_CRITERIA_BROADCAST BIT(0)
519#define MWIFIEX_CRITERIA_UNICAST BIT(1)
520#define MWIFIEX_CRITERIA_MULTICAST BIT(3)
521
Avinash Patil429d90d2014-02-07 16:27:34 -0800522#define ACT_TDLS_DELETE 0x00
523#define ACT_TDLS_CREATE 0x01
524#define ACT_TDLS_CONFIG 0x02
Avinash Patil79ff4342014-05-06 22:02:44 -0700525#define TDLS_EVENT_LINK_TEAR_DOWN 3
Avinash Patil429d90d2014-02-07 16:27:34 -0800526
Amitkumar Karwar8e17ea22014-03-07 19:41:26 -0800527#define MWIFIEX_FW_V15 15
528
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700529struct mwifiex_ie_types_header {
530 __le16 type;
531 __le16 len;
532} __packed;
533
534struct mwifiex_ie_types_data {
535 struct mwifiex_ie_types_header header;
536 u8 data[1];
537} __packed;
538
539#define MWIFIEX_TxPD_POWER_MGMT_NULL_PACKET 0x01
540#define MWIFIEX_TxPD_POWER_MGMT_LAST_PACKET 0x08
Avinash Patilb23bce22014-02-07 16:27:32 -0800541#define MWIFIEX_TXPD_FLAGS_TDLS_PACKET 0x10
Avinash Patil09869492014-05-21 22:02:31 -0700542#define MWIFIEX_RXPD_FLAGS_TDLS_PACKET 0x01
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700543
544struct txpd {
545 u8 bss_type;
546 u8 bss_num;
547 __le16 tx_pkt_length;
548 __le16 tx_pkt_offset;
549 __le16 tx_pkt_type;
550 __le32 tx_control;
551 u8 priority;
552 u8 flags;
553 u8 pkt_delay_2ms;
554 u8 reserved1;
555} __packed;
556
557struct rxpd {
558 u8 bss_type;
559 u8 bss_num;
Amitkumar Karwared1ea6f2012-08-03 18:06:02 -0700560 __le16 rx_pkt_length;
561 __le16 rx_pkt_offset;
562 __le16 rx_pkt_type;
563 __le16 seq_num;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700564 u8 priority;
565 u8 rx_rate;
566 s8 snr;
567 s8 nf;
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800568
569 /* For: Non-802.11 AC cards
570 *
571 * Ht Info [Bit 0] RxRate format: LG=0, HT=1
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700572 * [Bit 1] HT Bandwidth: BW20 = 0, BW40 = 1
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800573 * [Bit 2] HT Guard Interval: LGI = 0, SGI = 1
574 *
575 * For: 802.11 AC cards
576 * [Bit 1] [Bit 0] RxRate format: legacy rate = 00 HT = 01 VHT = 10
577 * [Bit 3] [Bit 2] HT/VHT Bandwidth BW20 = 00 BW40 = 01
578 * BW80 = 10 BW160 = 11
579 * [Bit 4] HT/VHT Guard interval LGI = 0 SGI = 1
580 * [Bit 5] STBC support Enabled = 1
581 * [Bit 6] LDPC support Enabled = 1
582 * [Bit 7] Reserved
583 */
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700584 u8 ht_info;
Avinash Patil09869492014-05-21 22:02:31 -0700585 u8 flags;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700586} __packed;
587
Avinash Patil838e4f42012-08-03 18:06:08 -0700588struct uap_txpd {
589 u8 bss_type;
590 u8 bss_num;
591 __le16 tx_pkt_length;
592 __le16 tx_pkt_offset;
593 __le16 tx_pkt_type;
594 __le32 tx_control;
595 u8 priority;
596 u8 flags;
597 u8 pkt_delay_2ms;
598 u8 reserved1;
599 __le32 reserved2;
600};
601
602struct uap_rxpd {
603 u8 bss_type;
604 u8 bss_num;
605 __le16 rx_pkt_length;
606 __le16 rx_pkt_offset;
607 __le16 rx_pkt_type;
608 __le16 seq_num;
609 u8 priority;
610 u8 reserved1;
611};
612
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700613enum mwifiex_chan_scan_mode_bitmasks {
614 MWIFIEX_PASSIVE_SCAN = BIT(0),
615 MWIFIEX_DISABLE_CHAN_FILT = BIT(1),
616};
617
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700618struct mwifiex_chan_scan_param_set {
619 u8 radio_type;
620 u8 chan_number;
621 u8 chan_scan_mode_bitmap;
622 __le16 min_scan_time;
623 __le16 max_scan_time;
624} __packed;
625
626struct mwifiex_ie_types_chan_list_param_set {
627 struct mwifiex_ie_types_header header;
628 struct mwifiex_chan_scan_param_set chan_scan_param[1];
629} __packed;
630
631struct chan_band_param_set {
632 u8 radio_type;
633 u8 chan_number;
634};
635
636struct mwifiex_ie_types_chan_band_list_param_set {
637 struct mwifiex_ie_types_header header;
638 struct chan_band_param_set chan_band_param[1];
639} __packed;
640
641struct mwifiex_ie_types_rates_param_set {
642 struct mwifiex_ie_types_header header;
643 u8 rates[1];
644} __packed;
645
646struct mwifiex_ie_types_ssid_param_set {
647 struct mwifiex_ie_types_header header;
648 u8 ssid[1];
649} __packed;
650
651struct mwifiex_ie_types_num_probes {
652 struct mwifiex_ie_types_header header;
653 __le16 num_probes;
654} __packed;
655
656struct mwifiex_ie_types_wildcard_ssid_params {
657 struct mwifiex_ie_types_header header;
658 u8 max_ssid_length;
659 u8 ssid[1];
660} __packed;
661
662#define TSF_DATA_SIZE 8
663struct mwifiex_ie_types_tsf_timestamp {
664 struct mwifiex_ie_types_header header;
665 u8 tsf_data[1];
666} __packed;
667
668struct mwifiex_cf_param_set {
669 u8 cfp_cnt;
670 u8 cfp_period;
Ujjal Roy4348d082013-12-02 23:17:48 -0800671 __le16 cfp_max_duration;
672 __le16 cfp_duration_remaining;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700673} __packed;
674
675struct mwifiex_ibss_param_set {
Ujjal Roy4348d082013-12-02 23:17:48 -0800676 __le16 atim_window;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700677} __packed;
678
679struct mwifiex_ie_types_ss_param_set {
680 struct mwifiex_ie_types_header header;
681 union {
682 struct mwifiex_cf_param_set cf_param_set[1];
683 struct mwifiex_ibss_param_set ibss_param_set[1];
684 } cf_ibss;
685} __packed;
686
687struct mwifiex_fh_param_set {
Ujjal Roy4348d082013-12-02 23:17:48 -0800688 __le16 dwell_time;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700689 u8 hop_set;
690 u8 hop_pattern;
691 u8 hop_index;
692} __packed;
693
694struct mwifiex_ds_param_set {
695 u8 current_chan;
696} __packed;
697
698struct mwifiex_ie_types_phy_param_set {
699 struct mwifiex_ie_types_header header;
700 union {
701 struct mwifiex_fh_param_set fh_param_set[1];
702 struct mwifiex_ds_param_set ds_param_set[1];
703 } fh_ds;
704} __packed;
705
706struct mwifiex_ie_types_auth_type {
707 struct mwifiex_ie_types_header header;
708 __le16 auth_type;
709} __packed;
710
711struct mwifiex_ie_types_vendor_param_set {
712 struct mwifiex_ie_types_header header;
713 u8 ie[MWIFIEX_MAX_VSIE_LEN];
714};
715
Bing Zhao30fa51c2014-07-11 20:57:13 -0700716#define MWIFIEX_TDLS_IDLE_TIMEOUT_IN_SEC 60
Avinash Patild29caf22014-05-06 22:02:43 -0700717
718struct mwifiex_ie_types_tdls_idle_timeout {
719 struct mwifiex_ie_types_header header;
720 __le16 value;
721} __packed;
722
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700723struct mwifiex_ie_types_rsn_param_set {
724 struct mwifiex_ie_types_header header;
725 u8 rsn_ie[1];
726} __packed;
727
728#define KEYPARAMSET_FIXED_LEN 6
729
730struct mwifiex_ie_type_key_param_set {
731 __le16 type;
732 __le16 length;
733 __le16 key_type_id;
734 __le16 key_info;
735 __le16 key_len;
736 u8 key[50];
737} __packed;
738
Ying Luob877f4c2012-08-03 18:06:14 -0700739#define IGTK_PN_LEN 8
740
741struct mwifiex_cmac_param {
742 u8 ipn[IGTK_PN_LEN];
743 u8 key[WLAN_KEY_LEN_AES_CMAC];
744} __packed;
745
Avinash Patile57f1732014-02-07 16:32:35 -0800746struct mwifiex_wep_param {
747 __le16 key_len;
748 u8 key[WLAN_KEY_LEN_WEP104];
749} __packed;
750
751struct mwifiex_tkip_param {
752 u8 pn[WPA_PN_SIZE];
753 __le16 key_len;
754 u8 key[WLAN_KEY_LEN_TKIP];
755} __packed;
756
757struct mwifiex_aes_param {
758 u8 pn[WPA_PN_SIZE];
759 __le16 key_len;
760 u8 key[WLAN_KEY_LEN_CCMP];
761} __packed;
762
763struct mwifiex_wapi_param {
764 u8 pn[PN_LEN];
765 __le16 key_len;
766 u8 key[WLAN_KEY_LEN_SMS4];
767} __packed;
768
769struct mwifiex_cmac_aes_param {
770 u8 ipn[IGTK_PN_LEN];
771 __le16 key_len;
772 u8 key[WLAN_KEY_LEN_AES_CMAC];
773} __packed;
774
775struct mwifiex_ie_type_key_param_set_v2 {
776 __le16 type;
777 __le16 len;
778 u8 mac_addr[ETH_ALEN];
779 u8 key_idx;
780 u8 key_type;
781 __le16 key_info;
782 union {
783 struct mwifiex_wep_param wep;
784 struct mwifiex_tkip_param tkip;
785 struct mwifiex_aes_param aes;
786 struct mwifiex_wapi_param wapi;
787 struct mwifiex_cmac_aes_param cmac_aes;
788 } key_params;
789} __packed;
790
791struct host_cmd_ds_802_11_key_material_v2 {
792 __le16 action;
793 struct mwifiex_ie_type_key_param_set_v2 key_param_set;
794} __packed;
795
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700796struct host_cmd_ds_802_11_key_material {
797 __le16 action;
798 struct mwifiex_ie_type_key_param_set key_param_set;
799} __packed;
800
801struct host_cmd_ds_gen {
Ujjal Roy4348d082013-12-02 23:17:48 -0800802 __le16 command;
803 __le16 size;
804 __le16 seq_num;
805 __le16 result;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700806};
807
808#define S_DS_GEN sizeof(struct host_cmd_ds_gen)
809
810enum sleep_resp_ctrl {
811 RESP_NOT_NEEDED = 0,
812 RESP_NEEDED,
813};
814
815struct mwifiex_ps_param {
816 __le16 null_pkt_interval;
817 __le16 multiple_dtims;
818 __le16 bcn_miss_timeout;
819 __le16 local_listen_interval;
820 __le16 adhoc_wake_period;
821 __le16 mode;
822 __le16 delay_to_ps;
823};
824
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700825#define BITMAP_AUTO_DS 0x01
826#define BITMAP_STA_PS 0x10
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700827
828struct mwifiex_ie_types_auto_ds_param {
829 struct mwifiex_ie_types_header header;
Marc Yang2b06bdb2011-03-30 18:12:44 -0700830 __le16 deep_sleep_timeout;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700831} __packed;
832
833struct mwifiex_ie_types_ps_param {
834 struct mwifiex_ie_types_header header;
835 struct mwifiex_ps_param param;
836} __packed;
837
838struct host_cmd_ds_802_11_ps_mode_enh {
839 __le16 action;
840
841 union {
842 struct mwifiex_ps_param opt_ps;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700843 __le16 ps_bitmap;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700844 } params;
845} __packed;
846
Amitkumar Karwar4b9fede2014-08-19 08:24:25 -0400847enum API_VER_ID {
Avinash Patil7f445d02014-02-07 16:30:42 -0800848 KEY_API_VER_ID = 1,
Amitkumar Karwar89be7ce2014-08-19 08:24:26 -0400849 FW_API_VER_ID = 2,
Avinash Patil7f445d02014-02-07 16:30:42 -0800850};
851
Amitkumar Karwar4b9fede2014-08-19 08:24:25 -0400852struct hw_spec_api_rev {
Avinash Patil7f445d02014-02-07 16:30:42 -0800853 struct mwifiex_ie_types_header header;
854 __le16 api_id;
855 u8 major_ver;
856 u8 minor_ver;
857} __packed;
858
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700859struct host_cmd_ds_get_hw_spec {
860 __le16 hw_if_version;
861 __le16 version;
862 __le16 reserved;
863 __le16 num_of_mcast_adr;
864 u8 permanent_addr[ETH_ALEN];
865 __le16 region_code;
866 __le16 number_of_antenna;
867 __le32 fw_release_number;
868 __le32 reserved_1;
869 __le32 reserved_2;
870 __le32 reserved_3;
871 __le32 fw_cap_info;
872 __le32 dot_11n_dev_cap;
873 u8 dev_mcs_support;
874 __le16 mp_end_port; /* SDIO only, reserved for other interfacces */
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800875 __le16 mgmt_buf_count; /* mgmt IE buffer count */
876 __le32 reserved_5;
877 __le32 reserved_6;
878 __le32 dot_11ac_dev_cap;
879 __le32 dot_11ac_mcs_support;
Avinash Patil7f445d02014-02-07 16:30:42 -0800880 u8 tlvs[0];
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700881} __packed;
882
883struct host_cmd_ds_802_11_rssi_info {
884 __le16 action;
885 __le16 ndata;
886 __le16 nbcn;
887 __le16 reserved[9];
888 long long reserved_1;
889};
890
891struct host_cmd_ds_802_11_rssi_info_rsp {
892 __le16 action;
893 __le16 ndata;
894 __le16 nbcn;
895 __le16 data_rssi_last;
896 __le16 data_nf_last;
897 __le16 data_rssi_avg;
898 __le16 data_nf_avg;
899 __le16 bcn_rssi_last;
900 __le16 bcn_nf_last;
901 __le16 bcn_rssi_avg;
902 __le16 bcn_nf_avg;
903 long long tsf_bcn;
904};
905
906struct host_cmd_ds_802_11_mac_address {
907 __le16 action;
908 u8 mac_addr[ETH_ALEN];
909};
910
911struct host_cmd_ds_mac_control {
912 __le16 action;
913 __le16 reserved;
914};
915
916struct host_cmd_ds_mac_multicast_adr {
917 __le16 action;
918 __le16 num_of_adrs;
919 u8 mac_list[MWIFIEX_MAX_MULTICAST_LIST_SIZE][ETH_ALEN];
920} __packed;
921
922struct host_cmd_ds_802_11_deauthenticate {
923 u8 mac_addr[ETH_ALEN];
924 __le16 reason_code;
925} __packed;
926
927struct host_cmd_ds_802_11_associate {
928 u8 peer_sta_addr[ETH_ALEN];
929 __le16 cap_info_bitmap;
930 __le16 listen_interval;
931 __le16 beacon_period;
932 u8 dtim_period;
933} __packed;
934
935struct ieee_types_assoc_rsp {
936 __le16 cap_info_bitmap;
937 __le16 status_code;
938 __le16 a_id;
939 u8 ie_buffer[1];
940} __packed;
941
942struct host_cmd_ds_802_11_associate_rsp {
943 struct ieee_types_assoc_rsp assoc_rsp;
944} __packed;
945
946struct ieee_types_cf_param_set {
947 u8 element_id;
948 u8 len;
949 u8 cfp_cnt;
950 u8 cfp_period;
Ujjal Roy4348d082013-12-02 23:17:48 -0800951 __le16 cfp_max_duration;
952 __le16 cfp_duration_remaining;
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700953} __packed;
954
955struct ieee_types_ibss_param_set {
956 u8 element_id;
957 u8 len;
958 __le16 atim_window;
959} __packed;
960
961union ieee_types_ss_param_set {
962 struct ieee_types_cf_param_set cf_param_set;
963 struct ieee_types_ibss_param_set ibss_param_set;
964} __packed;
965
966struct ieee_types_fh_param_set {
967 u8 element_id;
968 u8 len;
969 __le16 dwell_time;
970 u8 hop_set;
971 u8 hop_pattern;
972 u8 hop_index;
973} __packed;
974
975struct ieee_types_ds_param_set {
976 u8 element_id;
977 u8 len;
978 u8 current_chan;
979} __packed;
980
981union ieee_types_phy_param_set {
982 struct ieee_types_fh_param_set fh_param_set;
983 struct ieee_types_ds_param_set ds_param_set;
984} __packed;
985
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -0800986struct ieee_types_oper_mode_ntf {
987 u8 element_id;
988 u8 len;
989 u8 oper_mode;
990} __packed;
991
Bing Zhao5e6e3a92011-03-21 18:00:50 -0700992struct host_cmd_ds_802_11_ad_hoc_start {
993 u8 ssid[IEEE80211_MAX_SSID_LEN];
994 u8 bss_mode;
995 __le16 beacon_period;
996 u8 dtim_period;
997 union ieee_types_ss_param_set ss_param_set;
998 union ieee_types_phy_param_set phy_param_set;
999 u16 reserved1;
1000 __le16 cap_info_bitmap;
Yogesh Ashok Powar63af6332011-11-07 21:41:09 -08001001 u8 data_rate[HOSTCMD_SUPPORTED_RATES];
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001002} __packed;
1003
1004struct host_cmd_ds_802_11_ad_hoc_result {
1005 u8 pad[3];
1006 u8 bssid[ETH_ALEN];
1007} __packed;
1008
1009struct adhoc_bss_desc {
1010 u8 bssid[ETH_ALEN];
1011 u8 ssid[IEEE80211_MAX_SSID_LEN];
1012 u8 bss_mode;
1013 __le16 beacon_period;
1014 u8 dtim_period;
1015 u8 time_stamp[8];
1016 u8 local_time[8];
1017 union ieee_types_phy_param_set phy_param_set;
1018 union ieee_types_ss_param_set ss_param_set;
1019 __le16 cap_info_bitmap;
1020 u8 data_rates[HOSTCMD_SUPPORTED_RATES];
1021
1022 /*
1023 * DO NOT ADD ANY FIELDS TO THIS STRUCTURE.
1024 * It is used in the Adhoc join command and will cause a
1025 * binary layout mismatch with the firmware
1026 */
1027} __packed;
1028
1029struct host_cmd_ds_802_11_ad_hoc_join {
1030 struct adhoc_bss_desc bss_descriptor;
1031 u16 reserved1;
1032 u16 reserved2;
1033} __packed;
1034
1035struct host_cmd_ds_802_11_get_log {
1036 __le32 mcast_tx_frame;
1037 __le32 failed;
1038 __le32 retry;
1039 __le32 multi_retry;
1040 __le32 frame_dup;
1041 __le32 rts_success;
1042 __le32 rts_failure;
1043 __le32 ack_failure;
1044 __le32 rx_frag;
1045 __le32 mcast_rx_frame;
1046 __le32 fcs_error;
1047 __le32 tx_frame;
1048 __le32 reserved;
1049 __le32 wep_icv_err_cnt[4];
1050};
1051
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -08001052/* Enumeration for rate format */
1053enum _mwifiex_rate_format {
1054 MWIFIEX_RATE_FORMAT_LG = 0,
1055 MWIFIEX_RATE_FORMAT_HT,
1056 MWIFIEX_RATE_FORMAT_VHT,
1057 MWIFIEX_RATE_FORMAT_AUTO = 0xFF,
1058};
1059
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001060struct host_cmd_ds_tx_rate_query {
1061 u8 tx_rate;
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -08001062 /* Tx Rate Info: For 802.11 AC cards
1063 *
1064 * [Bit 0-1] tx rate formate: LG = 0, HT = 1, VHT = 2
1065 * [Bit 2-3] HT/VHT Bandwidth: BW20 = 0, BW40 = 1, BW80 = 2, BW160 = 3
1066 * [Bit 4] HT/VHT Guard Interval: LGI = 0, SGI = 1
1067 *
1068 * For non-802.11 AC cards
1069 * Ht Info [Bit 0] RxRate format: LG=0, HT=1
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001070 * [Bit 1] HT Bandwidth: BW20 = 0, BW40 = 1
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -08001071 * [Bit 2] HT Guard Interval: LGI = 0, SGI = 1
1072 */
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001073 u8 ht_info;
1074} __packed;
1075
1076enum Host_Sleep_Action {
1077 HS_CONFIGURE = 0x0001,
1078 HS_ACTIVATE = 0x0002,
1079};
1080
1081struct mwifiex_hs_config_param {
1082 __le32 conditions;
1083 u8 gpio;
1084 u8 gap;
1085} __packed;
1086
1087struct hs_activate_param {
Ujjal Roy4348d082013-12-02 23:17:48 -08001088 __le16 resp_ctrl;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001089} __packed;
1090
1091struct host_cmd_ds_802_11_hs_cfg_enh {
1092 __le16 action;
1093
1094 union {
1095 struct mwifiex_hs_config_param hs_config;
1096 struct hs_activate_param hs_activate;
1097 } params;
1098} __packed;
1099
1100enum SNMP_MIB_INDEX {
1101 OP_RATE_SET_I = 1,
1102 DTIM_PERIOD_I = 3,
1103 RTS_THRESH_I = 5,
1104 SHORT_RETRY_LIM_I = 6,
1105 LONG_RETRY_LIM_I = 7,
1106 FRAG_THRESH_I = 8,
1107 DOT11D_I = 9,
Amitkumar Karwar2a7305c2013-06-19 08:49:05 -07001108 DOT11H_I = 10,
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001109};
1110
1111#define MAX_SNMP_BUF_SIZE 128
1112
1113struct host_cmd_ds_802_11_snmp_mib {
1114 __le16 query_type;
1115 __le16 oid;
1116 __le16 buf_size;
1117 u8 value[1];
1118} __packed;
1119
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001120struct mwifiex_rate_scope {
1121 __le16 type;
1122 __le16 length;
1123 __le16 hr_dsss_rate_bitmap;
1124 __le16 ofdm_rate_bitmap;
1125 __le16 ht_mcs_rate_bitmap[8];
Amitkumar Karwara0b7315a2014-03-07 19:41:27 -08001126 __le16 vht_mcs_rate_bitmap[8];
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001127} __packed;
1128
1129struct mwifiex_rate_drop_pattern {
1130 __le16 type;
1131 __le16 length;
1132 __le32 rate_drop_mode;
1133} __packed;
1134
1135struct host_cmd_ds_tx_rate_cfg {
1136 __le16 action;
1137 __le16 cfg_index;
1138} __packed;
1139
1140struct mwifiex_power_group {
1141 u8 modulation_class;
1142 u8 first_rate_code;
1143 u8 last_rate_code;
1144 s8 power_step;
1145 s8 power_min;
1146 s8 power_max;
1147 u8 ht_bandwidth;
1148 u8 reserved;
1149} __packed;
1150
1151struct mwifiex_types_power_group {
Amitkumar Karwar930fd352013-10-22 15:24:43 -07001152 __le16 type;
1153 __le16 length;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001154} __packed;
1155
1156struct host_cmd_ds_txpwr_cfg {
1157 __le16 action;
1158 __le16 cfg_index;
1159 __le32 mode;
1160} __packed;
1161
Amitkumar Karwarcaa89842012-06-27 19:57:57 -07001162struct host_cmd_ds_rf_tx_pwr {
1163 __le16 action;
1164 __le16 cur_level;
1165 u8 max_power;
1166 u8 min_power;
1167} __packed;
1168
Amitkumar Karwar8a279d52012-07-02 19:32:33 -07001169struct host_cmd_ds_rf_ant_mimo {
1170 __le16 action_tx;
1171 __le16 tx_ant_mode;
1172 __le16 action_rx;
1173 __le16 rx_ant_mode;
1174};
1175
1176struct host_cmd_ds_rf_ant_siso {
1177 __le16 action;
1178 __le16 ant_mode;
1179};
1180
Avinash Patil429d90d2014-02-07 16:27:34 -08001181struct host_cmd_ds_tdls_oper {
1182 __le16 tdls_action;
1183 __le16 reason;
1184 u8 peer_mac[ETH_ALEN];
1185} __packed;
1186
Amitkumar Karwarb8b3ece2014-02-07 16:23:34 -08001187struct mwifiex_fixed_bcn_param {
Amitkumar Karwarb5abcf02012-04-16 21:36:52 -07001188 __le64 timestamp;
Amitkumar Karwar7c6fa2a2011-08-10 18:53:57 -07001189 __le16 beacon_period;
1190 __le16 cap_info_bitmap;
1191} __packed;
1192
Amitkumar Karwar21f58d202014-02-11 18:39:56 -08001193struct mwifiex_event_scan_result {
1194 __le16 event_id;
1195 u8 bss_index;
1196 u8 bss_type;
1197 u8 more_event;
1198 u8 reserved[3];
1199 __le16 buf_size;
1200 u8 num_of_set;
1201} __packed;
1202
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001203#define MWIFIEX_USER_SCAN_CHAN_MAX 50
1204
1205#define MWIFIEX_MAX_SSID_LIST_LENGTH 10
1206
1207struct mwifiex_scan_cmd_config {
1208 /*
Bing Zhaoa8c48562011-05-10 20:47:36 -07001209 * BSS mode to be sent in the firmware command
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001210 */
1211 u8 bss_mode;
1212
1213 /* Specific BSSID used to filter scan results in the firmware */
1214 u8 specific_bssid[ETH_ALEN];
1215
1216 /* Length of TLVs sent in command starting at tlvBuffer */
1217 u32 tlv_buf_len;
1218
1219 /*
1220 * SSID TLV(s) and ChanList TLVs to be sent in the firmware command
1221 *
1222 * TLV_TYPE_CHANLIST, mwifiex_ie_types_chan_list_param_set
1223 * WLAN_EID_SSID, mwifiex_ie_types_ssid_param_set
1224 */
1225 u8 tlv_buf[1]; /* SSID TLV(s) and ChanList TLVs are stored
1226 here */
1227} __packed;
1228
1229struct mwifiex_user_scan_chan {
1230 u8 chan_number;
1231 u8 radio_type;
1232 u8 scan_type;
1233 u8 reserved;
1234 u32 scan_time;
1235} __packed;
1236
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001237struct mwifiex_user_scan_cfg {
1238 /*
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001239 * BSS mode to be sent in the firmware command
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001240 */
1241 u8 bss_mode;
1242 /* Configure the number of probe requests for active chan scans */
1243 u8 num_probes;
1244 u8 reserved;
1245 /* BSSID filter sent in the firmware command to limit the results */
1246 u8 specific_bssid[ETH_ALEN];
Amitkumar Karwarbe0b2812012-02-27 22:04:15 -08001247 /* SSID filter list used in the firmware to limit the scan results */
1248 struct cfg80211_ssid *ssid_list;
1249 u8 num_ssids;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001250 /* Variable number (fixed maximum) of channels to scan up */
1251 struct mwifiex_user_scan_chan chan_list[MWIFIEX_USER_SCAN_CHAN_MAX];
1252} __packed;
1253
1254struct ie_body {
1255 u8 grp_key_oui[4];
1256 u8 ptk_cnt[2];
1257 u8 ptk_body[4];
1258} __packed;
1259
1260struct host_cmd_ds_802_11_scan {
1261 u8 bss_mode;
1262 u8 bssid[ETH_ALEN];
1263 u8 tlv_buffer[1];
1264} __packed;
1265
1266struct host_cmd_ds_802_11_scan_rsp {
1267 __le16 bss_descript_size;
1268 u8 number_of_sets;
1269 u8 bss_desc_and_tlv_buffer[1];
1270} __packed;
1271
Amitkumar Karwar21f58d202014-02-11 18:39:56 -08001272struct host_cmd_ds_802_11_scan_ext {
1273 u32 reserved;
1274 u8 tlv_buffer[1];
1275} __packed;
1276
1277struct mwifiex_ie_types_bss_scan_rsp {
1278 struct mwifiex_ie_types_header header;
1279 u8 bssid[ETH_ALEN];
1280 u8 frame_body[1];
1281} __packed;
1282
1283struct mwifiex_ie_types_bss_scan_info {
1284 struct mwifiex_ie_types_header header;
1285 __le16 rssi;
1286 __le16 anpi;
1287 u8 cca_busy_fraction;
1288 u8 radio_type;
1289 u8 channel;
1290 u8 reserved;
1291 __le64 tsf;
1292} __packed;
1293
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001294struct host_cmd_ds_802_11_bg_scan_query {
1295 u8 flush;
1296} __packed;
1297
1298struct host_cmd_ds_802_11_bg_scan_query_rsp {
Ujjal Roy4348d082013-12-02 23:17:48 -08001299 __le32 report_condition;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001300 struct host_cmd_ds_802_11_scan_rsp scan_resp;
1301} __packed;
1302
1303struct mwifiex_ietypes_domain_param_set {
1304 struct mwifiex_ie_types_header header;
1305 u8 country_code[IEEE80211_COUNTRY_STRING_LEN];
1306 struct ieee80211_country_ie_triplet triplet[1];
1307} __packed;
1308
1309struct host_cmd_ds_802_11d_domain_info {
1310 __le16 action;
1311 struct mwifiex_ietypes_domain_param_set domain;
1312} __packed;
1313
1314struct host_cmd_ds_802_11d_domain_info_rsp {
1315 __le16 action;
1316 struct mwifiex_ietypes_domain_param_set domain;
1317} __packed;
1318
1319struct host_cmd_ds_11n_addba_req {
1320 u8 add_req_result;
1321 u8 peer_mac_addr[ETH_ALEN];
1322 u8 dialog_token;
1323 __le16 block_ack_param_set;
1324 __le16 block_ack_tmo;
1325 __le16 ssn;
1326} __packed;
1327
1328struct host_cmd_ds_11n_addba_rsp {
1329 u8 add_rsp_result;
1330 u8 peer_mac_addr[ETH_ALEN];
1331 u8 dialog_token;
1332 __le16 status_code;
1333 __le16 block_ack_param_set;
1334 __le16 block_ack_tmo;
1335 __le16 ssn;
1336} __packed;
1337
1338struct host_cmd_ds_11n_delba {
1339 u8 del_result;
1340 u8 peer_mac_addr[ETH_ALEN];
1341 __le16 del_ba_param_set;
1342 __le16 reason_code;
1343 u8 reserved;
1344} __packed;
1345
1346struct host_cmd_ds_11n_batimeout {
1347 u8 tid;
1348 u8 peer_mac_addr[ETH_ALEN];
1349 u8 origninator;
1350} __packed;
1351
1352struct host_cmd_ds_11n_cfg {
1353 __le16 action;
1354 __le16 ht_tx_cap;
1355 __le16 ht_tx_info;
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -08001356 __le16 misc_config; /* Needed for 802.11AC cards only */
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001357} __packed;
1358
1359struct host_cmd_ds_txbuf_cfg {
1360 __le16 action;
1361 __le16 buff_size;
1362 __le16 mp_end_port; /* SDIO only, reserved for other interfacces */
1363 __le16 reserved3;
1364} __packed;
1365
1366struct host_cmd_ds_amsdu_aggr_ctrl {
1367 __le16 action;
1368 __le16 enable;
1369 __le16 curr_buf_size;
1370} __packed;
1371
Avinash Patil0f9e9b82013-05-17 17:50:23 -07001372struct host_cmd_ds_sta_deauth {
1373 u8 mac[ETH_ALEN];
1374 __le16 reason;
1375} __packed;
1376
Amitkumar Karwar2a7305c2013-06-19 08:49:05 -07001377struct mwifiex_ie_types_pwr_capability {
1378 struct mwifiex_ie_types_header header;
1379 s8 min_pwr;
1380 s8 max_pwr;
1381};
1382
1383struct mwifiex_ie_types_local_pwr_constraint {
1384 struct mwifiex_ie_types_header header;
1385 u8 chan;
1386 u8 constraint;
1387};
1388
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001389struct mwifiex_ie_types_wmm_param_set {
1390 struct mwifiex_ie_types_header header;
1391 u8 wmm_ie[1];
1392};
1393
1394struct mwifiex_ie_types_wmm_queue_status {
1395 struct mwifiex_ie_types_header header;
1396 u8 queue_index;
1397 u8 disabled;
Ujjal Roy4348d082013-12-02 23:17:48 -08001398 __le16 medium_time;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001399 u8 flow_required;
1400 u8 flow_created;
1401 u32 reserved;
1402};
1403
1404struct ieee_types_vendor_header {
1405 u8 element_id;
1406 u8 len;
Amitkumar Karwar2e4c14a2012-04-26 13:02:57 -07001407 u8 oui[4]; /* 0~2: oui, 3: oui_type */
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001408 u8 oui_subtype;
1409 u8 version;
1410} __packed;
1411
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001412struct ieee_types_wmm_parameter {
1413 /*
1414 * WMM Parameter IE - Vendor Specific Header:
1415 * element_id [221/0xdd]
1416 * Len [24]
1417 * Oui [00:50:f2]
1418 * OuiType [2]
1419 * OuiSubType [1]
1420 * Version [1]
1421 */
1422 struct ieee_types_vendor_header vend_hdr;
1423 u8 qos_info_bitmap;
1424 u8 reserved;
Johannes Berg99fec5d2012-03-27 14:07:59 +02001425 struct ieee_types_wmm_ac_parameters ac_params[IEEE80211_NUM_ACS];
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001426} __packed;
1427
1428struct ieee_types_wmm_info {
1429
1430 /*
1431 * WMM Info IE - Vendor Specific Header:
1432 * element_id [221/0xdd]
1433 * Len [7]
1434 * Oui [00:50:f2]
1435 * OuiType [2]
1436 * OuiSubType [0]
1437 * Version [1]
1438 */
1439 struct ieee_types_vendor_header vend_hdr;
1440
1441 u8 qos_info_bitmap;
1442} __packed;
1443
1444struct host_cmd_ds_wmm_get_status {
1445 u8 queue_status_tlv[sizeof(struct mwifiex_ie_types_wmm_queue_status) *
Johannes Berg99fec5d2012-03-27 14:07:59 +02001446 IEEE80211_NUM_ACS];
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001447 u8 wmm_param_tlv[sizeof(struct ieee_types_wmm_parameter) + 2];
1448} __packed;
1449
1450struct mwifiex_wmm_ac_status {
1451 u8 disabled;
1452 u8 flow_required;
1453 u8 flow_created;
1454};
1455
1456struct mwifiex_ie_types_htcap {
1457 struct mwifiex_ie_types_header header;
1458 struct ieee80211_ht_cap ht_cap;
1459} __packed;
1460
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -08001461struct mwifiex_ie_types_vhtcap {
1462 struct mwifiex_ie_types_header header;
1463 struct ieee80211_vht_cap vht_cap;
1464} __packed;
1465
Avinash Patil5f6d5982014-02-07 16:30:39 -08001466struct mwifiex_ie_types_aid {
1467 struct mwifiex_ie_types_header header;
1468 __le16 aid;
1469} __packed;
1470
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -08001471struct mwifiex_ie_types_oper_mode_ntf {
1472 struct mwifiex_ie_types_header header;
1473 u8 oper_mode;
1474} __packed;
1475
1476/* VHT Operations IE */
1477struct mwifiex_ie_types_vht_oper {
1478 struct mwifiex_ie_types_header header;
1479 u8 chan_width;
1480 u8 chan_center_freq_1;
1481 u8 chan_center_freq_2;
1482 /* Basic MCS set map, each 2 bits stands for a NSS */
Ujjal Roy4348d082013-12-02 23:17:48 -08001483 __le16 basic_mcs_map;
Yogesh Ashok Powara5f39052013-02-15 21:44:30 -08001484} __packed;
1485
Avinash Patil54428c52013-01-02 16:56:01 -08001486struct mwifiex_ie_types_wmmcap {
1487 struct mwifiex_ie_types_header header;
1488 struct mwifiex_types_wmm_info wmm_info;
1489} __packed;
1490
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001491struct mwifiex_ie_types_htinfo {
1492 struct mwifiex_ie_types_header header;
Johannes Berg074d46d2012-03-15 19:45:16 +01001493 struct ieee80211_ht_operation ht_oper;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001494} __packed;
1495
1496struct mwifiex_ie_types_2040bssco {
1497 struct mwifiex_ie_types_header header;
1498 u8 bss_co_2040;
1499} __packed;
1500
1501struct mwifiex_ie_types_extcap {
1502 struct mwifiex_ie_types_header header;
Avinash Patil68f95b092013-08-23 16:48:22 -07001503 u8 ext_capab[0];
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001504} __packed;
1505
Avinash Patil1f4dfd82014-02-07 16:30:34 -08001506struct mwifiex_ie_types_qos_info {
1507 struct mwifiex_ie_types_header header;
1508 u8 qos_info;
1509} __packed;
1510
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001511struct host_cmd_ds_mac_reg_access {
1512 __le16 action;
1513 __le16 offset;
1514 __le32 value;
1515} __packed;
1516
1517struct host_cmd_ds_bbp_reg_access {
1518 __le16 action;
1519 __le16 offset;
1520 u8 value;
1521 u8 reserved[3];
1522} __packed;
1523
1524struct host_cmd_ds_rf_reg_access {
1525 __le16 action;
1526 __le16 offset;
1527 u8 value;
1528 u8 reserved[3];
1529} __packed;
1530
1531struct host_cmd_ds_pmic_reg_access {
1532 __le16 action;
1533 __le16 offset;
1534 u8 value;
1535 u8 reserved[3];
1536} __packed;
1537
1538struct host_cmd_ds_802_11_eeprom_access {
1539 __le16 action;
1540
1541 __le16 offset;
1542 __le16 byte_count;
1543 u8 value;
1544} __packed;
1545
Avinash Patile5686342012-05-08 18:30:25 -07001546struct mwifiex_assoc_event {
1547 u8 sta_addr[ETH_ALEN];
1548 __le16 type;
1549 __le16 len;
1550 __le16 frame_control;
1551 __le16 cap_info;
1552 __le16 listen_interval;
1553 u8 data[0];
1554} __packed;
1555
Avinash Patil4db16a12012-05-08 18:30:20 -07001556struct host_cmd_ds_sys_config {
1557 __le16 action;
1558 u8 tlv[0];
1559};
Avinash Patilf752dcd2012-05-08 18:30:26 -07001560
Yogesh Ashok Powar83c78da2013-03-18 20:06:03 -07001561struct host_cmd_11ac_vht_cfg {
1562 __le16 action;
1563 u8 band_config;
1564 u8 misc_config;
1565 __le32 cap_info;
1566 __le32 mcs_tx_set;
1567 __le32 mcs_rx_set;
1568} __packed;
1569
Avinash Patilf752dcd2012-05-08 18:30:26 -07001570struct host_cmd_tlv_akmp {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001571 struct mwifiex_ie_types_header header;
Avinash Patilf752dcd2012-05-08 18:30:26 -07001572 __le16 key_mgmt;
1573 __le16 key_mgmt_operation;
1574} __packed;
1575
1576struct host_cmd_tlv_pwk_cipher {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001577 struct mwifiex_ie_types_header header;
Avinash Patilf752dcd2012-05-08 18:30:26 -07001578 __le16 proto;
1579 u8 cipher;
1580 u8 reserved;
1581} __packed;
1582
1583struct host_cmd_tlv_gwk_cipher {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001584 struct mwifiex_ie_types_header header;
Avinash Patilf752dcd2012-05-08 18:30:26 -07001585 u8 cipher;
1586 u8 reserved;
1587} __packed;
1588
1589struct host_cmd_tlv_passphrase {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001590 struct mwifiex_ie_types_header header;
Avinash Patilf752dcd2012-05-08 18:30:26 -07001591 u8 passphrase[0];
1592} __packed;
1593
Avinash Patil96893532012-06-15 12:21:55 -07001594struct host_cmd_tlv_wep_key {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001595 struct mwifiex_ie_types_header header;
Avinash Patil96893532012-06-15 12:21:55 -07001596 u8 key_index;
1597 u8 is_default;
1598 u8 key[1];
1599};
1600
Avinash Patilf752dcd2012-05-08 18:30:26 -07001601struct host_cmd_tlv_auth_type {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001602 struct mwifiex_ie_types_header header;
Avinash Patilf752dcd2012-05-08 18:30:26 -07001603 u8 auth_type;
1604} __packed;
1605
1606struct host_cmd_tlv_encrypt_protocol {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001607 struct mwifiex_ie_types_header header;
Avinash Patilf752dcd2012-05-08 18:30:26 -07001608 __le16 proto;
1609} __packed;
1610
Avinash Patil12190c52012-05-08 18:30:24 -07001611struct host_cmd_tlv_ssid {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001612 struct mwifiex_ie_types_header header;
Avinash Patil12190c52012-05-08 18:30:24 -07001613 u8 ssid[0];
1614} __packed;
1615
Avinash Patila3c2c4f2012-08-27 20:32:53 -07001616struct host_cmd_tlv_rates {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001617 struct mwifiex_ie_types_header header;
Avinash Patila3c2c4f2012-08-27 20:32:53 -07001618 u8 rates[0];
1619} __packed;
1620
Amitkumar Karwar21f58d202014-02-11 18:39:56 -08001621struct mwifiex_ie_types_bssid_list {
1622 struct mwifiex_ie_types_header header;
1623 u8 bssid[ETH_ALEN];
1624} __packed;
1625
Avinash Patil605b73a2012-05-16 21:24:55 -07001626struct host_cmd_tlv_bcast_ssid {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001627 struct mwifiex_ie_types_header header;
Avinash Patil605b73a2012-05-16 21:24:55 -07001628 u8 bcast_ctl;
1629} __packed;
1630
Avinash Patil12190c52012-05-08 18:30:24 -07001631struct host_cmd_tlv_beacon_period {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001632 struct mwifiex_ie_types_header header;
Avinash Patil12190c52012-05-08 18:30:24 -07001633 __le16 period;
1634} __packed;
1635
1636struct host_cmd_tlv_dtim_period {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001637 struct mwifiex_ie_types_header header;
Avinash Patil12190c52012-05-08 18:30:24 -07001638 u8 period;
1639} __packed;
Avinash Patil4db16a12012-05-08 18:30:20 -07001640
Avinash Patil9b930ea2012-05-08 18:30:23 -07001641struct host_cmd_tlv_frag_threshold {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001642 struct mwifiex_ie_types_header header;
Avinash Patil9b930ea2012-05-08 18:30:23 -07001643 __le16 frag_thr;
1644} __packed;
1645
1646struct host_cmd_tlv_rts_threshold {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001647 struct mwifiex_ie_types_header header;
Avinash Patil9b930ea2012-05-08 18:30:23 -07001648 __le16 rts_thr;
1649} __packed;
1650
1651struct host_cmd_tlv_retry_limit {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001652 struct mwifiex_ie_types_header header;
Avinash Patil9b930ea2012-05-08 18:30:23 -07001653 u8 limit;
1654} __packed;
1655
Avinash Patil75edd2c2012-05-08 18:30:18 -07001656struct host_cmd_tlv_mac_addr {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001657 struct mwifiex_ie_types_header header;
Avinash Patil75edd2c2012-05-08 18:30:18 -07001658 u8 mac_addr[ETH_ALEN];
1659} __packed;
1660
Avinash Patil4db16a12012-05-08 18:30:20 -07001661struct host_cmd_tlv_channel_band {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001662 struct mwifiex_ie_types_header header;
Avinash Patil4db16a12012-05-08 18:30:20 -07001663 u8 band_config;
1664 u8 channel;
1665} __packed;
1666
Kevin Gan8b4509f2012-09-25 20:23:45 -07001667struct host_cmd_tlv_ageout_timer {
Amitkumar Karwar6b21a692013-07-22 19:17:57 -07001668 struct mwifiex_ie_types_header header;
Kevin Gan8b4509f2012-09-25 20:23:45 -07001669 __le32 sta_ao_timer;
1670} __packed;
1671
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001672struct host_cmd_ds_version_ext {
1673 u8 version_str_sel;
1674 char version_str[128];
1675} __packed;
1676
Stone Piao3cec6872012-09-25 20:23:34 -07001677struct host_cmd_ds_mgmt_frame_reg {
1678 __le16 action;
1679 __le32 mask;
1680} __packed;
1681
Stone Piaoe1a2b7a2012-09-25 20:23:41 -07001682struct host_cmd_ds_p2p_mode_cfg {
1683 __le16 action;
1684 __le16 mode;
1685} __packed;
1686
Stone Piao7feb4c42012-09-25 20:23:36 -07001687struct host_cmd_ds_remain_on_chan {
1688 __le16 action;
1689 u8 status;
1690 u8 reserved;
1691 u8 band_cfg;
1692 u8 channel;
1693 __le32 duration;
1694} __packed;
1695
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001696struct host_cmd_ds_802_11_ibss_status {
1697 __le16 action;
1698 __le16 enable;
1699 u8 bssid[ETH_ALEN];
1700 __le16 beacon_interval;
1701 __le16 atim_window;
1702 __le16 use_g_rate_protect;
1703} __packed;
1704
Amitkumar Karwar7da060c2013-03-04 16:27:59 -08001705struct mwifiex_fw_mef_entry {
1706 u8 mode;
1707 u8 action;
1708 __le16 exprsize;
1709 u8 expr[0];
1710} __packed;
1711
1712struct host_cmd_ds_mef_cfg {
1713 __le32 criteria;
1714 __le16 num_entries;
1715 struct mwifiex_fw_mef_entry mef_entry[0];
1716} __packed;
1717
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001718#define CONNECTION_TYPE_INFRA 0
1719#define CONNECTION_TYPE_ADHOC 1
Stone Piao9197ab92012-09-25 20:23:42 -07001720#define CONNECTION_TYPE_AP 2
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001721
1722struct host_cmd_ds_set_bss_mode {
1723 u8 con_type;
1724} __packed;
1725
Amitkumar Karward930fae2011-10-11 17:41:21 -07001726struct host_cmd_ds_pcie_details {
1727 /* TX buffer descriptor ring address */
1728 u32 txbd_addr_lo;
1729 u32 txbd_addr_hi;
1730 /* TX buffer descriptor ring count */
1731 u32 txbd_count;
1732
1733 /* RX buffer descriptor ring address */
1734 u32 rxbd_addr_lo;
1735 u32 rxbd_addr_hi;
1736 /* RX buffer descriptor ring count */
1737 u32 rxbd_count;
1738
1739 /* Event buffer descriptor ring address */
1740 u32 evtbd_addr_lo;
1741 u32 evtbd_addr_hi;
1742 /* Event buffer descriptor ring count */
1743 u32 evtbd_count;
1744
1745 /* Sleep cookie buffer physical address */
1746 u32 sleep_cookie_addr_lo;
1747 u32 sleep_cookie_addr_hi;
1748} __packed;
1749
Amitkumar Karwarfa444bf2012-03-15 20:51:51 -07001750struct mwifiex_ie_types_rssi_threshold {
1751 struct mwifiex_ie_types_header header;
1752 u8 abs_value;
1753 u8 evt_freq;
1754} __packed;
1755
1756struct host_cmd_ds_802_11_subsc_evt {
1757 __le16 action;
1758 __le16 events;
1759} __packed;
1760
Avinash Patil79ff4342014-05-06 22:02:44 -07001761struct mwifiex_tdls_generic_event {
1762 __le16 type;
1763 u8 peer_mac[ETH_ALEN];
1764 union {
1765 __le16 reason_code;
1766 __le16 reserved;
1767 } u;
1768} __packed;
1769
Avinash Patilede98bf2012-05-08 18:30:28 -07001770struct mwifiex_ie {
1771 __le16 ie_index;
1772 __le16 mgmt_subtype_mask;
1773 __le16 ie_length;
1774 u8 ie_buffer[IEEE_MAX_IE_SIZE];
1775} __packed;
1776
1777#define MAX_MGMT_IE_INDEX 16
1778struct mwifiex_ie_list {
1779 __le16 type;
1780 __le16 len;
1781 struct mwifiex_ie ie_list[MAX_MGMT_IE_INDEX];
1782} __packed;
1783
Amitkumar Karwar562fc5b2013-08-05 18:52:00 -07001784struct coalesce_filt_field_param {
1785 u8 operation;
1786 u8 operand_len;
1787 __le16 offset;
1788 u8 operand_byte_stream[4];
1789};
1790
1791struct coalesce_receive_filt_rule {
1792 struct mwifiex_ie_types_header header;
1793 u8 num_of_fields;
1794 u8 pkt_type;
1795 __le16 max_coalescing_delay;
1796 struct coalesce_filt_field_param params[0];
1797} __packed;
1798
1799struct host_cmd_ds_coalesce_cfg {
1800 __le16 action;
1801 __le16 num_of_rules;
1802 struct coalesce_receive_filt_rule rule[0];
1803} __packed;
1804
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001805struct host_cmd_ds_command {
1806 __le16 command;
1807 __le16 size;
1808 __le16 seq_num;
1809 __le16 result;
1810 union {
1811 struct host_cmd_ds_get_hw_spec hw_spec;
1812 struct host_cmd_ds_mac_control mac_ctrl;
1813 struct host_cmd_ds_802_11_mac_address mac_addr;
1814 struct host_cmd_ds_mac_multicast_adr mc_addr;
1815 struct host_cmd_ds_802_11_get_log get_log;
1816 struct host_cmd_ds_802_11_rssi_info rssi_info;
1817 struct host_cmd_ds_802_11_rssi_info_rsp rssi_info_rsp;
1818 struct host_cmd_ds_802_11_snmp_mib smib;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001819 struct host_cmd_ds_tx_rate_query tx_rate;
1820 struct host_cmd_ds_tx_rate_cfg tx_rate_cfg;
1821 struct host_cmd_ds_txpwr_cfg txp_cfg;
Amitkumar Karwarcaa89842012-06-27 19:57:57 -07001822 struct host_cmd_ds_rf_tx_pwr txp;
Amitkumar Karwar8a279d52012-07-02 19:32:33 -07001823 struct host_cmd_ds_rf_ant_mimo ant_mimo;
1824 struct host_cmd_ds_rf_ant_siso ant_siso;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001825 struct host_cmd_ds_802_11_ps_mode_enh psmode_enh;
1826 struct host_cmd_ds_802_11_hs_cfg_enh opt_hs_cfg;
1827 struct host_cmd_ds_802_11_scan scan;
Amitkumar Karwar21f58d202014-02-11 18:39:56 -08001828 struct host_cmd_ds_802_11_scan_ext ext_scan;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001829 struct host_cmd_ds_802_11_scan_rsp scan_resp;
1830 struct host_cmd_ds_802_11_bg_scan_query bg_scan_query;
1831 struct host_cmd_ds_802_11_bg_scan_query_rsp bg_scan_query_resp;
1832 struct host_cmd_ds_802_11_associate associate;
1833 struct host_cmd_ds_802_11_associate_rsp associate_rsp;
1834 struct host_cmd_ds_802_11_deauthenticate deauth;
1835 struct host_cmd_ds_802_11_ad_hoc_start adhoc_start;
1836 struct host_cmd_ds_802_11_ad_hoc_result adhoc_result;
1837 struct host_cmd_ds_802_11_ad_hoc_join adhoc_join;
1838 struct host_cmd_ds_802_11d_domain_info domain_info;
1839 struct host_cmd_ds_802_11d_domain_info_rsp domain_info_resp;
1840 struct host_cmd_ds_11n_addba_req add_ba_req;
1841 struct host_cmd_ds_11n_addba_rsp add_ba_rsp;
1842 struct host_cmd_ds_11n_delba del_ba;
1843 struct host_cmd_ds_txbuf_cfg tx_buf;
1844 struct host_cmd_ds_amsdu_aggr_ctrl amsdu_aggr_ctrl;
1845 struct host_cmd_ds_11n_cfg htcfg;
1846 struct host_cmd_ds_wmm_get_status get_wmm_status;
1847 struct host_cmd_ds_802_11_key_material key_material;
Avinash Patile57f1732014-02-07 16:32:35 -08001848 struct host_cmd_ds_802_11_key_material_v2 key_material_v2;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001849 struct host_cmd_ds_version_ext verext;
Stone Piao3cec6872012-09-25 20:23:34 -07001850 struct host_cmd_ds_mgmt_frame_reg reg_mask;
Stone Piao7feb4c42012-09-25 20:23:36 -07001851 struct host_cmd_ds_remain_on_chan roc_cfg;
Stone Piaoe1a2b7a2012-09-25 20:23:41 -07001852 struct host_cmd_ds_p2p_mode_cfg mode_cfg;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001853 struct host_cmd_ds_802_11_ibss_status ibss_coalescing;
Amitkumar Karwar7da060c2013-03-04 16:27:59 -08001854 struct host_cmd_ds_mef_cfg mef_cfg;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001855 struct host_cmd_ds_mac_reg_access mac_reg;
1856 struct host_cmd_ds_bbp_reg_access bbp_reg;
1857 struct host_cmd_ds_rf_reg_access rf_reg;
1858 struct host_cmd_ds_pmic_reg_access pmic_reg;
1859 struct host_cmd_ds_set_bss_mode bss_mode;
Amitkumar Karward930fae2011-10-11 17:41:21 -07001860 struct host_cmd_ds_pcie_details pcie_host_spec;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001861 struct host_cmd_ds_802_11_eeprom_access eeprom;
Amitkumar Karwarfa444bf2012-03-15 20:51:51 -07001862 struct host_cmd_ds_802_11_subsc_evt subsc_evt;
Avinash Patil4db16a12012-05-08 18:30:20 -07001863 struct host_cmd_ds_sys_config uap_sys_config;
Avinash Patil0f9e9b82013-05-17 17:50:23 -07001864 struct host_cmd_ds_sta_deauth sta_deauth;
Yogesh Ashok Powar83c78da2013-03-18 20:06:03 -07001865 struct host_cmd_11ac_vht_cfg vht_cfg;
Amitkumar Karwar562fc5b2013-08-05 18:52:00 -07001866 struct host_cmd_ds_coalesce_cfg coalesce_cfg;
Avinash Patil429d90d2014-02-07 16:27:34 -08001867 struct host_cmd_ds_tdls_oper tdls_oper;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001868 } params;
1869} __packed;
1870
1871struct mwifiex_opt_sleep_confirm {
1872 __le16 command;
1873 __le16 size;
1874 __le16 seq_num;
1875 __le16 result;
1876 __le16 action;
Marc Yang2b06bdb2011-03-30 18:12:44 -07001877 __le16 resp_ctrl;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001878} __packed;
Bing Zhao5e6e3a92011-03-21 18:00:50 -07001879#endif /* !_MWIFIEX_FW_H_ */