blob: 49b14bd8550049b88425726655b378e2b548c35d [file] [log] [blame]
Jeff Johnson295189b2012-06-20 16:38:30 -07001/*
Jeff Johnson32d95a32012-09-10 13:15:23 -07002 * Copyright (c) 2012, The Linux Foundation. All rights reserved.
Jeff Johnson295189b2012-06-20 16:38:30 -07003 *
4 * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
5 *
6 *
7 * Permission to use, copy, modify, and/or distribute this software for
8 * any purpose with or without fee is hereby granted, provided that the
9 * above copyright notice and this permission notice appear in all
10 * copies.
11 *
12 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
13 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
14 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
15 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
16 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
17 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
18 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19 * PERFORMANCE OF THIS SOFTWARE.
20 */
21
22/*
23 * Airgo Networks, Inc proprietary. All rights reserved.
24 * This file sirApi.h contains definitions exported by
25 * Sirius software.
26 * Author: Chandra Modumudi
27 * Date: 04/16/2002
28 * History:-
29 * Date Modified by Modification Information
30 * --------------------------------------------------------------------
31 */
32
33#ifndef __SIR_API_H
34#define __SIR_API_H
35
36#include "sirTypes.h"
37#include "sirMacProtDef.h"
38#include "aniSystemDefs.h"
Jeff Johnsone7245742012-09-05 17:12:55 -070039#include "sirParams.h"
Jeff Johnson295189b2012-06-20 16:38:30 -070040
41#ifdef FEATURE_WLAN_CCX
42#include "ccxGlobal.h"
43#endif
44
45/// Maximum number of STAs allowed in the BSS
46#define SIR_MAX_NUM_STA 256
47
48/// Maximum number of Neighbors reported by STA for LB feature
49#define SIR_MAX_NUM_NEIGHBOR_BSS 3
50
51/// Maximum number of Neighbors reported by STA for LB feature
52#define SIR_MAX_NUM_ALTERNATE_RADIOS 5
53
54/// Maximum size of SCAN_RSP message
55#define SIR_MAX_SCAN_RSP_MSG_LENGTH 2600
56
57/// Start of Sirius software/Host driver message types
58#define SIR_HAL_HOST_MSG_START 0x1000
59
60/// Power save level definitions
61#define SIR_MAX_POWER_SAVE 3
62#define SIR_INTERMEDIATE_POWER_SAVE 4
63#define SIR_NO_POWER_SAVE 5
64
65/// Max supported channel list
66#define SIR_MAX_SUPPORTED_CHANNEL_LIST 96
67
68/// Maximum DTIM Factor
69#define SIR_MAX_DTIM_FACTOR 32
70
71#define SIR_MDIE_SIZE 3
72
73
74
75#define SIR_NUM_11B_RATES 4 //1,2,5.5,11
76#define SIR_NUM_11A_RATES 8 //6,9,12,18,24,36,48,54
77#define SIR_NUM_POLARIS_RATES 3 //72,96,108
78#define SIR_NUM_TITAN_RATES 26
79#define SIR_NUM_TAURUS_RATES 4 //136.5, 151.7,283.5,315
80#define SIR_NUM_PROP_RATES (SIR_NUM_TITAN_RATES + SIR_NUM_TAURUS_RATES)
81
82#define SIR_11N_PROP_RATE_136_5 (1<<28)
83#define SIR_11N_PROP_RATE_151_7 (1<<29)
84#define SIR_11N_PROP_RATE_283_5 (1<<30)
85#define SIR_11N_PROP_RATE_315 (1<<31)
86#define SIR_11N_PROP_RATE_BITMAP 0x80000000 //only 315MBPS rate is supported today
87//Taurus is going to support 26 Titan Rates(no ESF/concat Rates will be supported)
88//First 26 bits are reserved for Titan and last 4 bits for Taurus, 2(27 and 28) bits are reserved.
89//#define SIR_TITAN_PROP_RATE_BITMAP 0x03FFFFFF
90//Disable all Titan rates
91#define SIR_TITAN_PROP_RATE_BITMAP 0
92#define SIR_CONVERT_2_U32_BITMAP(nRates) ((nRates + 31)/32)
93
94/* #tANI_U32's needed for a bitmap representation for all prop rates */
95#define SIR_NUM_U32_MAP_RATES SIR_CONVERT_2_U32_BITMAP(SIR_NUM_PROP_RATES)
96
97
98#define SIR_PM_SLEEP_MODE 0
99#define SIR_PM_ACTIVE_MODE 1
100
101// Used by various modules to load ALL CFG's
102#define ANI_IGNORE_CFG_ID 0xFFFF
103
104//hidden SSID options
105#define SIR_SCAN_NO_HIDDEN_SSID 0
106#define SIR_SCAN_HIDDEN_SSID_PE_DECISION 1
107#define SIR_SCAN_HIDDEN_SSID 2
108
109#define SIR_MAC_ADDR_LEN 6
110#define SIR_IPV4_ADDR_LEN 4
111
112typedef tANI_U8 tSirIpv4Addr[SIR_IPV4_ADDR_LEN];
113
114#define SIR_VERSION_STRING_LEN 64
115typedef tANI_U8 tSirVersionString[SIR_VERSION_STRING_LEN];
116
117enum eSirHostMsgTypes
118{
119 SIR_HAL_APP_SETUP_NTF = SIR_HAL_HOST_MSG_START,
120 SIR_HAL_INITIAL_CAL_FAILED_NTF,
121 SIR_HAL_NIC_OPER_NTF,
122 SIR_HAL_INIT_START_REQ,
123 SIR_HAL_SHUTDOWN_REQ,
124 SIR_HAL_SHUTDOWN_CNF,
125 SIR_HAL_RESET_REQ,
126 SIR_HAL_RADIO_ON_OFF_IND,
127 SIR_HAL_RESET_CNF,
128 SIR_WRITE_TO_TD,
129 SIR_HAL_HDD_ADDBA_REQ, // MAC -> HDD
130 SIR_HAL_HDD_ADDBA_RSP, // HDD -> HAL
131 SIR_HAL_DELETEBA_IND, // MAC -> HDD
132 SIR_HAL_BA_FAIL_IND, // HDD -> MAC
133 SIR_TL_HAL_FLUSH_AC_REQ,
134 SIR_HAL_TL_FLUSH_AC_RSP
135};
136
137
138
139/**
140 * Module ID definitions.
141 */
142enum {
143 SIR_BOOT_MODULE_ID = 1,
144 SIR_HAL_MODULE_ID = 0x10,
145 SIR_CFG_MODULE_ID,
146 SIR_LIM_MODULE_ID,
147 SIR_ARQ_MODULE_ID,
148 SIR_SCH_MODULE_ID,
149 SIR_PMM_MODULE_ID,
150 SIR_MNT_MODULE_ID,
151 SIR_DBG_MODULE_ID,
152 SIR_DPH_MODULE_ID,
153 SIR_SYS_MODULE_ID,
154 SIR_SMS_MODULE_ID,
155
156 SIR_PHY_MODULE_ID = 0x20,
157
158
159 // Add any modules above this line
160 SIR_DVT_MODULE_ID
161};
162
163#define SIR_WDA_MODULE_ID SIR_HAL_MODULE_ID
164
165/**
166 * First and last module definition for logging utility
167 *
168 * NOTE: The following definitions need to be updated if
169 * the above list is changed.
170 */
171#define SIR_FIRST_MODULE_ID SIR_HAL_MODULE_ID
172#define SIR_LAST_MODULE_ID SIR_DVT_MODULE_ID
173
174
175// Type declarations used by Firmware and Host software
176
177// Scan type enum used in scan request
178typedef enum eSirScanType
179{
180 eSIR_PASSIVE_SCAN,
181 eSIR_ACTIVE_SCAN,
182} tSirScanType;
183
184/// Result codes Firmware return to Host SW
185typedef enum eSirResultCodes
186{
187 eSIR_SME_SUCCESS,
188
189 eSIR_EOF_SOF_EXCEPTION,
190 eSIR_BMU_EXCEPTION,
191 eSIR_LOW_PDU_EXCEPTION,
192 eSIR_USER_TRIG_RESET,
193 eSIR_LOGP_EXCEPTION,
194 eSIR_CP_EXCEPTION,
195 eSIR_STOP_BSS,
196 eSIR_AHB_HANG_EXCEPTION,
197 eSIR_DPU_EXCEPTION,
198 eSIR_RPE_EXCEPTION,
199 eSIR_TPE_EXCEPTION,
200 eSIR_DXE_EXCEPTION,
201 eSIR_RXP_EXCEPTION,
202 eSIR_MCPU_EXCEPTION,
203 eSIR_MCU_EXCEPTION,
204 eSIR_MTU_EXCEPTION,
205 eSIR_MIF_EXCEPTION,
206 eSIR_FW_EXCEPTION,
207 eSIR_PS_MUTEX_READ_EXCEPTION,
208 eSIR_PHY_HANG_EXCEPTION,
209 eSIR_MAILBOX_SANITY_CHK_FAILED,
210 eSIR_RADIO_HW_SWITCH_STATUS_IS_OFF, // Only where this switch is present
211 eSIR_CFB_FLAG_STUCK_EXCEPTION,
212
213 eSIR_SME_BASIC_RATES_NOT_SUPPORTED_STATUS=30,
214
215 eSIR_SME_INVALID_PARAMETERS=500,
216 eSIR_SME_UNEXPECTED_REQ_RESULT_CODE,
217 eSIR_SME_RESOURCES_UNAVAILABLE,
218 eSIR_SME_SCAN_FAILED, // Unable to find a BssDescription
219 // matching requested scan criteria
220 eSIR_SME_BSS_ALREADY_STARTED_OR_JOINED,
221 eSIR_SME_LOST_LINK_WITH_PEER_RESULT_CODE,
222 eSIR_SME_REFUSED,
223 eSIR_SME_JOIN_TIMEOUT_RESULT_CODE,
224 eSIR_SME_AUTH_TIMEOUT_RESULT_CODE,
225 eSIR_SME_ASSOC_TIMEOUT_RESULT_CODE,
226 eSIR_SME_REASSOC_TIMEOUT_RESULT_CODE,
227 eSIR_SME_MAX_NUM_OF_PRE_AUTH_REACHED,
228 eSIR_SME_AUTH_REFUSED,
229 eSIR_SME_INVALID_WEP_DEFAULT_KEY,
230 eSIR_SME_NO_KEY_MAPPING_KEY_FOR_PEER,
231 eSIR_SME_ASSOC_REFUSED,
232 eSIR_SME_REASSOC_REFUSED,
233 eSIR_SME_DEAUTH_WHILE_JOIN, //Received Deauth while joining or pre-auhtentication.
234 eSIR_SME_DISASSOC_WHILE_JOIN, //Received Disassociation while joining.
235 eSIR_SME_DEAUTH_WHILE_REASSOC, //Received Deauth while ReAssociate.
236 eSIR_SME_DISASSOC_WHILE_REASSOC, //Received Disassociation while ReAssociate
237 eSIR_SME_STA_NOT_AUTHENTICATED,
238 eSIR_SME_STA_NOT_ASSOCIATED,
239 eSIR_SME_STA_DISASSOCIATED,
240 eSIR_SME_ALREADY_JOINED_A_BSS,
241 eSIR_ULA_COMPLETED,
242 eSIR_ULA_FAILURE,
243 eSIR_SME_LINK_ESTABLISHED,
244 eSIR_SME_UNABLE_TO_PERFORM_MEASUREMENTS,
245 eSIR_SME_UNABLE_TO_PERFORM_DFS,
246 eSIR_SME_DFS_FAILED,
247 eSIR_SME_TRANSFER_STA, // To be used when STA need to be LB'ed
248 eSIR_SME_INVALID_LINK_TEST_PARAMETERS,// Given in LINK_TEST_START_RSP
249 eSIR_SME_LINK_TEST_MAX_EXCEEDED, // Given in LINK_TEST_START_RSP
250 eSIR_SME_UNSUPPORTED_RATE, // Given in LINK_TEST_RSP if peer does
251 // support requested rate in
252 // LINK_TEST_REQ
253 eSIR_SME_LINK_TEST_TIMEOUT, // Given in LINK_TEST_IND if peer does
254 // not respond before next test packet
255 // is sent
256 eSIR_SME_LINK_TEST_COMPLETE, // Given in LINK_TEST_IND at the end
257 // of link test
258 eSIR_SME_LINK_TEST_INVALID_STATE, // Given in LINK_TEST_START_RSP
259 eSIR_SME_LINK_TEST_TERMINATE, // Given in LINK_TEST_START_RSP
260 eSIR_SME_LINK_TEST_INVALID_ADDRESS, // Given in LINK_TEST_STOP_RSP
261 eSIR_SME_POLARIS_RESET, // Given in SME_STOP_BSS_REQ
262 eSIR_SME_SETCONTEXT_FAILED, // Given in SME_SETCONTEXT_REQ when
263 // unable to plumb down keys
264 eSIR_SME_BSS_RESTART, // Given in SME_STOP_BSS_REQ
265
266 eSIR_SME_MORE_SCAN_RESULTS_FOLLOW, // Given in SME_SCAN_RSP message
267 // that more SME_SCAN_RSP
268 // messages are following.
269 // SME_SCAN_RSP message with
270 // eSIR_SME_SUCCESS status
271 // code is the last one.
272 eSIR_SME_INVALID_ASSOC_RSP_RXED, // Sent in SME_JOIN/REASSOC_RSP
273 // messages upon receiving
274 // invalid Re/Assoc Rsp frame.
275 eSIR_SME_MIC_COUNTER_MEASURES, // STOP BSS triggered by MIC failures: MAC software to disassoc all stations
276 // with MIC_FAILURE reason code and perform the stop bss operation
277 eSIR_SME_ADDTS_RSP_TIMEOUT, // didn't get response from peer within
278 // timeout interval
279 eSIR_SME_ADDTS_RSP_FAILED, // didn't get success response from HAL
280 eSIR_SME_RECEIVED,
281 // TBA - TSPEC related Result Codes
282
283 eSIR_SME_CHANNEL_SWITCH_FAIL, // failed to send out Channel Switch Action Frame
284 eSIR_SME_INVALID_STA_ROLE,
285 eSIR_SME_INVALID_STATE,
286#ifdef GEN4_SCAN
287 eSIR_SME_CHANNEL_SWITCH_DISABLED, // either 11h is disabled or channelSwitch is currently active
288 eSIR_SME_HAL_SCAN_INIT_FAILED, // SIR_HAL_SIR_HAL_INIT_SCAN_RSP returned failed status
289 eSIR_SME_HAL_SCAN_START_FAILED, // SIR_HAL_START_SCAN_RSP returned failed status
290 eSIR_SME_HAL_SCAN_END_FAILED, // SIR_HAL_END_SCAN_RSP returned failed status
291 eSIR_SME_HAL_SCAN_FINISH_FAILED, // SIR_HAL_FINISH_SCAN_RSP returned failed status
292 eSIR_SME_HAL_SEND_MESSAGE_FAIL, // Failed to send a message to HAL
293#else // GEN4_SCAN
294 eSIR_SME_CHANNEL_SWITCH_DISABLED, // either 11h is disabled or channelSwitch is currently active
295 eSIR_SME_HAL_SEND_MESSAGE_FAIL, // Failed to send a message to HAL
296#endif // GEN4_SCAN
Jeff Johnsone7245742012-09-05 17:12:55 -0700297#ifdef FEATURE_OEM_DATA_SUPPORT
298 eSIR_SME_HAL_OEM_DATA_REQ_START_FAILED,
299#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700300 eSIR_SME_STOP_BSS_FAILURE, // Failed to stop the bss
301 eSIR_SME_STA_ASSOCIATED,
302 eSIR_SME_INVALID_PMM_STATE,
303 eSIR_SME_CANNOT_ENTER_IMPS,
304 eSIR_SME_IMPS_REQ_FAILED,
305 eSIR_SME_BMPS_REQ_FAILED,
Jeff Johnson04dd8a82012-06-29 20:41:40 -0700306 eSIR_SME_BMPS_REQ_REJECT,
Jeff Johnson295189b2012-06-20 16:38:30 -0700307 eSIR_SME_UAPSD_REQ_FAILED,
308 eSIR_SME_WOWL_ENTER_REQ_FAILED,
309 eSIR_SME_WOWL_EXIT_REQ_FAILED,
310#if defined WLAN_FEATURE_VOWIFI_11R
311 eSIR_SME_FT_REASSOC_TIMEOUT_FAILURE,
312 eSIR_SME_FT_REASSOC_FAILURE,
313#endif
314#ifdef WLAN_FEATURE_P2P
315 eSIR_SME_SEND_ACTION_FAIL,
316#endif
317#ifdef WLAN_FEATURE_PACKET_FILTERING
318 eSIR_SME_PC_FILTER_MATCH_COUNT_REQ_FAILED,
319#endif // WLAN_FEATURE_PACKET_FILTERING
320
321#ifdef WLAN_FEATURE_GTK_OFFLOAD
322 eSIR_SME_GTK_OFFLOAD_GETINFO_REQ_FAILED,
323#endif // WLAN_FEATURE_GTK_OFFLOAD
324 eSIR_DONOT_USE_RESULT_CODE = SIR_MAX_ENUM_SIZE
325} tSirResultCodes;
326
Jeff Johnson295189b2012-06-20 16:38:30 -0700327/* each station added has a rate mode which specifies the sta attributes */
328typedef enum eStaRateMode {
329 eSTA_TAURUS = 0,
330 eSTA_TITAN,
331 eSTA_POLARIS,
332 eSTA_11b,
333 eSTA_11bg,
334 eSTA_11a,
335 eSTA_11n,
Jeff Johnsone7245742012-09-05 17:12:55 -0700336#ifdef WLAN_FEATURE_11AC
337 eSTA_11ac,
338#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700339 eSTA_INVALID_RATE_MODE
340} tStaRateMode, *tpStaRateMode;
341
342//although in tSirSupportedRates each IE is 16bit but PE only passes IEs in 8 bits with MSB=1 for basic rates.
343//change the mask for bit0-7 only so HAL gets correct basic rates for setting response rates.
344#define IERATE_BASICRATE_MASK 0x80
345#define IERATE_RATE_MASK 0x7f
346#define IERATE_IS_BASICRATE(x) ((x) & IERATE_BASICRATE_MASK)
347#define ANIENHANCED_TAURUS_RATEMAP_BITOFFSET_START 28
348
349typedef struct sSirSupportedRates {
350 /*
351 * For Self STA Entry: this represents Self Mode.
352 * For Peer Stations, this represents the mode of the peer.
353 * On Station:
354 * --this mode is updated when PE adds the Self Entry.
355 * -- OR when PE sends 'ADD_BSS' message and station context in BSS is used to indicate the mode of the AP.
356 * ON AP:
357 * -- this mode is updated when PE sends 'ADD_BSS' and Sta entry for that BSS is used
358 * to indicate the self mode of the AP.
359 * -- OR when a station is associated, PE sends 'ADD_STA' message with this mode updated.
360 */
361
362 tStaRateMode opRateMode;
363 // 11b, 11a and aniLegacyRates are IE rates which gives rate in unit of 500Kbps
364 tANI_U16 llbRates[SIR_NUM_11B_RATES];
365 tANI_U16 llaRates[SIR_NUM_11A_RATES];
366 tANI_U16 aniLegacyRates[SIR_NUM_POLARIS_RATES];
367
368 //Taurus only supports 26 Titan Rates(no ESF/concat Rates will be supported)
369 //First 26 bits are reserved for those Titan rates and
370 //the last 4 bits(bit28-31) for Taurus, 2(bit26-27) bits are reserved.
371 tANI_U32 aniEnhancedRateBitmap; //Titan and Taurus Rates
372
373 /*
374 * 0-76 bits used, remaining reserved
375 * bits 0-15 and 32 should be set.
376 */
377 tANI_U8 supportedMCSSet[SIR_MAC_MAX_SUPPORTED_MCS_SET];
378
379 /*
380 * RX Highest Supported Data Rate defines the highest data
381 * rate that the STA is able to receive, in unites of 1Mbps.
382 * This value is derived from "Supported MCS Set field" inside
383 * the HT capability element.
384 */
385 tANI_U16 rxHighestDataRate;
386
Jeff Johnsone7245742012-09-05 17:12:55 -0700387#ifdef WLAN_FEATURE_11AC
388 /*Indicates the Maximum MCS that can be received for each number
389 of spacial streams */
390 tANI_U16 vhtRxMCSMap;
391 /*Indicate the highest VHT data rate that the STA is able to receive*/
392 tANI_U16 vhtRxHighestDataRate;
Madan Mohan Koyyalamudi1bed5982012-10-22 14:38:06 -0700393 /*Indicates the Maximum MCS that can be transmitted for each number
Jeff Johnsone7245742012-09-05 17:12:55 -0700394 of spacial streams */
395 tANI_U16 vhtTxMCSMap;
396 /*Indicate the highest VHT data rate that the STA is able to transmit*/
397 tANI_U16 vhtTxHighestDataRate;
398#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700399} tSirSupportedRates, *tpSirSupportedRates;
400
401
402typedef enum eSirRFBand
403{
404 SIR_BAND_UNKNOWN,
405 SIR_BAND_2_4_GHZ,
406 SIR_BAND_5_GHZ,
407} tSirRFBand;
408
409
410/*
411* Specifies which beacons are to be indicated upto the host driver when
412* Station is in power save mode.
413*/
414typedef enum eBeaconForwarding
415{
416 ePM_BEACON_FWD_NTH,
417 ePM_BEACON_FWD_TIM,
418 ePM_BEACON_FWD_DTIM,
419 ePM_BEACON_FWD_NONE
420} tBeaconForwarding;
421
422
423#ifdef WLAN_FEATURE_P2P
424typedef struct sSirRemainOnChnReq
425{
426 tANI_U16 messageType;
427 tANI_U16 length;
428 tANI_U8 sessionId;
429 tSirMacAddr selfMacAddr;
430 tANI_U8 chnNum;
431 tANI_U8 phyMode;
432 tANI_U32 duration;
433 tANI_U8 probeRspIe[1];
434}tSirRemainOnChnReq, *tpSirRemainOnChnReq;
435
436typedef struct sSirRegisterMgmtFrame
437{
438 tANI_U16 messageType;
439 tANI_U16 length;
440 tANI_U8 sessionId;
441 tANI_BOOLEAN registerFrame;
442 tANI_U16 frameType;
443 tANI_U16 matchLen;
444 tANI_U8 matchData[1];
445}tSirRegisterMgmtFrame, *tpSirRegisterMgmtFrame;
446#endif
447
448//
Jeff Johnson295189b2012-06-20 16:38:30 -0700449// Identifies the neighbor BSS' that was(were) detected
450// by an STA and reported to the AP
451//
452typedef struct sAniTitanCBNeighborInfo
453{
454 // A BSS was found on the Primary
455 tANI_U8 cbBssFoundPri;
456
457 // A BSS was found on the adjacent Upper Secondary
458 tANI_U8 cbBssFoundSecUp;
459
460 // A BSS was found on the adjacent Lower Secondary
461 tANI_U8 cbBssFoundSecDown;
462
463} tAniTitanCBNeighborInfo, *tpAniTitanCBNeighborInfo;
464
Jeff Johnson295189b2012-06-20 16:38:30 -0700465/// Generic type for sending a response message
466/// with result code to host software
467typedef struct sSirSmeRsp
468{
469 tANI_U16 messageType; // eWNI_SME_*_RSP
470 tANI_U16 length;
471 tANI_U8 sessionId; // To support BT-AMP
472 tANI_U16 transactionId; // To support BT-AMP
473 tSirResultCodes statusCode;
474} tSirSmeRsp, *tpSirSmeRsp;
475
476/// Definition for kick starting Firmware on STA
477typedef struct sSirSmeStartReq
478{
479 tANI_U16 messageType; // eWNI_SME_START_REQ
480 tANI_U16 length;
481 tANI_U8 sessionId; //Added for BT-AMP Support
482 tANI_U16 transcationId; //Added for BT-AMP Support
483 tSirMacAddr bssId; //Added For BT-AMP Support
484 tANI_U32 roamingAtPolaris;
485#if (WNI_POLARIS_FW_PRODUCT == WLAN_STA) || defined(ANI_AP_CLIENT_SDK)
486 tANI_U32 sendNewBssInd;
487#endif
488} tSirSmeStartReq, *tpSirSmeStartReq;
489
490/// Definition for indicating all modules ready on STA
491typedef struct sSirSmeReadyReq
492{
493 tANI_U16 messageType; // eWNI_SME_SYS_READY_IND
494 tANI_U16 length;
495 tANI_U16 transactionId;
496} tSirSmeReadyReq, *tpSirSmeReadyReq;
497
498/// Definition for response message to previously issued start request
499typedef struct sSirSmeStartRsp
500{
501 tANI_U16 messageType; // eWNI_SME_START_RSP
502 tANI_U16 length;
503 tSirResultCodes statusCode;
504 tANI_U16 transactionId;
505} tSirSmeStartRsp, *tpSirSmeStartRsp;
506
507#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
508/**
509 * Trigger Type
510 */
511typedef enum {
512 // During Initialization and NM triggers only
513 eSIR_TRIGGER_INIT_NM,
514
515 // During Initialization, NM triggers and Periodic evaluation
516 eSIR_TRIGGER_INIT_NM_PERIODIC
517}tSirDfsTrigType;
518#endif
519
520/// Definition for Load structure
521typedef struct sSirLoad
522{
523 tANI_U16 numStas;
524 tANI_U16 channelUtilization;
525} tSirLoad, *tpSirLoad;
526
527/// BSS type enum used in while scanning/joining etc
528typedef enum eSirBssType
529{
530 eSIR_INFRASTRUCTURE_MODE,
531#ifdef WLAN_SOFTAP_FEATURE
532 eSIR_INFRA_AP_MODE, //Added for softAP support
533#endif
534 eSIR_IBSS_MODE,
535 eSIR_BTAMP_STA_MODE, //Added for BT-AMP support
536 eSIR_BTAMP_AP_MODE, //Added for BT-AMP support
537 eSIR_AUTO_MODE,
538 eSIR_DONOT_USE_BSS_TYPE = SIR_MAX_ENUM_SIZE
539} tSirBssType;
540
541/// Definition for WDS Information
542typedef struct sSirWdsInfo
543{
544 tANI_U16 wdsLength;
545 tANI_U8 wdsBytes[ANI_WDS_INFO_MAX_LENGTH];
546} tSirWdsInfo, *tpSirWdsInfo;
547
548/// Power Capability info used in 11H
549typedef struct sSirMacPowerCapInfo
550{
551 tANI_U8 minTxPower;
552 tANI_U8 maxTxPower;
553} tSirMacPowerCapInfo, *tpSirMacPowerCapInfo;
554
555/// Supported Channel info used in 11H
556typedef struct sSirSupChnl
557{
558 tANI_U8 numChnl;
559 tANI_U8 channelList[SIR_MAX_SUPPORTED_CHANNEL_LIST];
560} tSirSupChnl, *tpSirSupChnl;
561
562typedef enum eSirNwType
563{
564 eSIR_11A_NW_TYPE,
565 eSIR_11B_NW_TYPE,
566 eSIR_11G_NW_TYPE,
567 eSIR_11N_NW_TYPE,
Jeff Johnsone7245742012-09-05 17:12:55 -0700568#ifdef WLAN_FEATURE_11AC
569 eSIR_11AC_NW_TYPE,
570#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700571 eSIR_DONOT_USE_NW_TYPE = SIR_MAX_ENUM_SIZE
572} tSirNwType;
573
574/// Definition for new iBss peer info
575typedef struct sSirNewIbssPeerInfo
576{
577 tSirMacAddr peerAddr;
578 tANI_U16 aid;
579} tSirNewIbssPeerInfo, *tpSirNewIbssPeerInfo;
580
581/// Definition for Alternate BSS info
582typedef struct sSirAlternateRadioInfo
583{
584 tSirMacAddr bssId;
585 tANI_U8 channelId;
586} tSirAlternateRadioInfo, *tpSirAlternateRadioInfo;
587
588/// Definition for Alternate BSS list
589typedef struct sSirAlternateRadioList
590{
591 tANI_U8 numBss;
592 tSirAlternateRadioInfo alternateRadio[1];
593} tSirAlternateRadioList, *tpSirAlternateRadioList;
594
595/// Definition for kick starting BSS
596/// ---> MAC
597/**
598 * Usage of ssId, numSSID & ssIdList:
599 * ---------------------------------
600 * 1. ssId.length of zero indicates that Broadcast/Suppress SSID
601 * feature is enabled.
602 * 2. If ssId.length is zero, MAC SW will advertise NULL SSID
603 * and interpret the SSID list from numSSID & ssIdList.
604 * 3. If ssId.length is non-zero, MAC SW will advertise the SSID
605 * specified in the ssId field and it is expected that
606 * application will set numSSID to one (only one SSID present
607 * in the list) and SSID in the list is same as ssId field.
608 * 4. Application will always set numSSID >= 1.
609 */
610//*****NOTE: Please make sure all codes are updated if inserting field into this structure..**********
611typedef struct sSirSmeStartBssReq
612{
613 tANI_U16 messageType; // eWNI_SME_START_BSS_REQ
614 tANI_U16 length;
615 tANI_U8 sessionId; //Added for BT-AMP Support
616 tANI_U16 transactionId; //Added for BT-AMP Support
617 tSirMacAddr bssId; //Added for BT-AMP Support
618 tSirMacAddr selfMacAddr; //Added for BT-AMP Support
619 tANI_U16 beaconInterval; //Added for BT-AMP Support
620 tANI_U8 dot11mode;
621 tSirBssType bssType;
622 tSirMacSSid ssId;
623 tANI_U8 channelId;
Jeff Johnsone7245742012-09-05 17:12:55 -0700624 ePhyChanBondState cbMode;
Jeff Johnson295189b2012-06-20 16:38:30 -0700625#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
626 tSirAlternateRadioList alternateRadioList;
627 tANI_S8 powerLevel;
628 tSirWdsInfo wdsInfo;
629#endif
630
631#ifdef WLAN_SOFTAP_FEATURE
632 tANI_U8 privacy;
633 tANI_U8 apUapsdEnable;
634 tANI_U8 ssidHidden;
635 tANI_BOOLEAN fwdWPSPBCProbeReq;
636 tANI_BOOLEAN protEnabled;
637 tANI_BOOLEAN obssProtEnabled;
638 tANI_U16 ht_capab;
639 tAniAuthType authType;
640 tANI_U32 dtimPeriod;
641 tANI_U8 wps_state;
642#endif
643 tVOS_CON_MODE bssPersona;
644
645 tSirRSNie rsnIE; // RSN IE to be sent in
646 // Beacon and Probe
647 // Response frames
648 tSirNwType nwType; // Indicates 11a/b/g
649 tSirMacRateSet operationalRateSet;// Has 11a or 11b rates
650 tSirMacRateSet extendedRateSet; // Has 11g rates
651
652#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
653 tANI_U8 numSSID;
654 tSirMacSSid ssIdList[ANI_MAX_NUM_OF_SSIDS];
655#endif
656} tSirSmeStartBssReq, *tpSirSmeStartBssReq;
657
658#define GET_IE_LEN_IN_BSS(lenInBss) ( lenInBss + sizeof(lenInBss) - \
659 ((int) OFFSET_OF( tSirBssDescription, ieFields)))
660
661#define WSCIE_PROBE_RSP_LEN (317 + 2)
662
663typedef struct sSirBssDescription
664{
665 //offset of the ieFields from bssId.
666 tANI_U16 length;
667 tSirMacAddr bssId;
668 v_TIME_t scanSysTimeMsec;
669 tANI_U32 timeStamp[2];
670 tANI_U16 beaconInterval;
671 tANI_U16 capabilityInfo;
672 tSirNwType nwType; // Indicates 11a/b/g
673 tANI_U8 aniIndicator;
674 tANI_S8 rssi;
675 tANI_S8 sinr;
676 //channelId what peer sent in beacon/probersp.
677 tANI_U8 channelId;
678 //channelId on which we are parked at.
679 //used only in scan case.
680 tANI_U8 channelIdSelf;
681 tANI_U8 sSirBssDescriptionRsvd[3];
Jeff Johnson295189b2012-06-20 16:38:30 -0700682 tANI_TIMESTAMP nReceivedTime; //base on a tick count. It is a time stamp, not a relative time.
683#if defined WLAN_FEATURE_VOWIFI
684 tANI_U32 parentTSF;
685 tANI_U32 startTSF[2];
686#endif
687#ifdef WLAN_FEATURE_VOWIFI_11R
688 tANI_U8 mdiePresent;
689 tANI_U8 mdie[SIR_MDIE_SIZE]; // MDIE for 11r, picked from the beacons
690#endif
691#ifdef FEATURE_WLAN_CCX
692 tANI_U16 QBSSLoad_present;
693 tANI_U16 QBSSLoad_avail;
694#endif
695 // Please keep the structure 4 bytes aligned above the ieFields
696
697 tANI_U8 fProbeRsp; //whether it is from a probe rsp
Madan Mohan Koyyalamudi2a6ba242012-10-31 17:06:19 -0700698 tANI_U8 reservedPadding1;
699 tANI_U8 reservedPadding2;
700 tANI_U8 reservedPadding3;
Jeff Johnson295189b2012-06-20 16:38:30 -0700701 tANI_U32 WscIeLen;
702 tANI_U8 WscIeProbeRsp[WSCIE_PROBE_RSP_LEN];
Madan Mohan Koyyalamudi2a6ba242012-10-31 17:06:19 -0700703 tANI_U8 reservedPadding4;
Jeff Johnson295189b2012-06-20 16:38:30 -0700704
Madan Mohan Koyyalamudi527935a2012-12-04 16:41:16 -0800705 /* ChannelWidth, secondaryChanneloffset, VHT capability and center freqency in case of VHT Information what peer sent in beacon/probersp */
706
707 tANI_U16 channelWidth;
708 tANI_U16 secondaryChannelOffset;
709 tANI_U16 vhtSupport;
710 tANI_U16 centerFreq;
711
Jeff Johnson295189b2012-06-20 16:38:30 -0700712 tANI_U32 ieFields[1];
713} tSirBssDescription, *tpSirBssDescription;
714
715/// Definition for response message to previously
716/// issued start BSS request
717/// MAC --->
718typedef struct sSirSmeStartBssRsp
719{
720 tANI_U16 messageType; // eWNI_SME_START_BSS_RSP
721 tANI_U16 length;
722 tANI_U8 sessionId;
723 tANI_U16 transactionId;//transaction ID for cmd
724 tSirResultCodes statusCode;
725 tSirBssType bssType;//Add new type for WDS mode
726 tANI_U16 beaconInterval;//Beacon Interval for both type
727 tANI_U32 staId;//Staion ID for Self
728 tSirBssDescription bssDescription;//Peer BSS description
729} tSirSmeStartBssRsp, *tpSirSmeStartBssRsp;
730
731#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
732typedef struct sSirMeasControl
733{
734 // Periodic Measurements enabled flag
735 tAniBool periodicMeasEnabled;
736 // Indicates whether to involve STAs in measurements or not
737 tAniBool involveSTAs;
738 // Basic or enhanced measurement metrics
739 // 0 - for basic, 1 - for enhanced
740 tANI_U8 metricsType;
741 // Indicates active or passive scanning
742 tSirScanType scanType;
743 // Following indicates how often measurements
744 // on each channel are made for long-scan-duration
745 tANI_U8 longChannelScanPeriodicity;
746 //
747 // Channel Bonding plus 11H related scan control
748 // 0 - CB and/or 11H is disabled
749 // 1 - CB and 11H is enabled
750 //
751 tANI_BOOLEAN cb11hEnabled;
752} tSirMeasControl, *tpSirMeasControl;
753
754typedef struct sSirMeasDuration
755{
756 // Following indicates time duration over which
757 // all channels in the channelList to be measured once
758 tANI_U32 shortTermPeriod;
759 // Following indicates time duration over which
760 // cached DFS measurements are averaged
761 tANI_U32 averagingPeriod;
762 // Following indicates time duration for making
763 // DFS measurements on each channel
764 tANI_U32 shortChannelScanDuration;
765 // Following indicates time duration for making
766 // DFS measurements on each channel for long term measurements
767 tANI_U32 longChannelScanDuration;
768} tSirMeasDuration, *tpSirMeasDuration;
769#endif
770
771typedef struct sSirChannelList
772{
773 tANI_U8 numChannels;
774 tANI_U8 channelNumber[1];
775} tSirChannelList, *tpSirChannelList;
776
777#ifdef FEATURE_WLAN_CCX
778typedef struct sTspecInfo {
779 tANI_U8 valid;
780 tSirMacTspecIE tspec;
781} tTspecInfo;
782
783#define SIR_CCX_MAX_TSPEC_IES 4
784typedef struct sCCXTspecTspecInfo {
785 tANI_U8 numTspecs;
786 tTspecInfo tspec[SIR_CCX_MAX_TSPEC_IES];
787} tCCXTspecInfo;
788#endif
789
790#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
791/// Definition for Neighbor BSS info
792typedef struct sSirNeighborBssInfo
793{
794 tSirMacAddr bssId;
795 tANI_U8 channelId;
Jeff Johnson295189b2012-06-20 16:38:30 -0700796 tAniBool wniIndicator;
797 tSirBssType bssType;
798 tANI_U8 sinr;
799 tANI_S8 rssi;
800 tSirLoad load;
801 tAniSSID ssId;
802 tAniApName apName;
803 tSirRSNie rsnIE;
804#if 0
805 tDot11fIEHTCaps HTCaps;
806 tDot11fIEHTInfo HTInfo;
807#endif
808 tSirNwType nwType; // Indicates 11a/b/g
809 tANI_U16 capabilityInfo;
810 tSirMacRateSet operationalRateSet; // Has 11a or 11b rates
811 tSirMacRateSet extendedRateSet; // Has 11g rates
812 tANI_U16 beaconInterval;
813 tANI_U8 dtimPeriod;
814 tANI_U8 HTCapsPresent;
815 tANI_U8 HTInfoPresent;
816 tANI_U8 wmeInfoPresent;
817 tANI_U8 wmeEdcaPresent;
818 tANI_U8 wsmCapablePresent;
819 tANI_U8 hcfEnabled;
820 tANI_U16 propIECapability;
821 tANI_U32 localPowerConstraints;
822 tANI_S32 aggrRssi;
823 tANI_U32 dataCount;
824 tANI_U32 totalPackets;
825} tSirNeighborBssInfo, *tpSirNeighborBssInfo;
826
827
828/// Definition for Neighbor BSS with WDS info
829typedef struct sSirNeighborBssWdsInfo
830{
831 tSirNeighborBssInfo neighborBssInfo;
832 tSirWdsInfo wdsInfo;
833} tSirNeighborBssWdsInfo, *tpSirNeighborBssWdsInfo;
834
835/// Definition for Neighbor BSS list
836typedef struct sSirNeighborBssList
837{
838 tANI_U32 numBss;
839 tSirNeighborBssInfo bssList[1];
840} tSirNeighborBssList, *tpSirNeighborBssList;
841
842/// Definition for Neighbor BSS list with WDS info
843typedef struct sSirNeighborBssWdsList
844{
845 tANI_U32 numBssWds;
846 tSirNeighborBssWdsInfo bssWdsList[1];
847} tSirNeighborBssWdsList, *tpSirNeighborBssWdsList;
848
849#if (WNI_POLARIS_FW_PRODUCT == AP)
850/// Definition for kick starting measurements
851/// ---> MAC
852typedef struct sSirSmeMeasurementReq
853{
854 tANI_U16 messageType; // eWNI_SME_MEASUREMENT_REQ
855 tANI_U16 length;
856 tSirMeasControl measControl;
857 tSirMeasDuration measDuration;
858 // This indicates how often SME_MEASUREMENT_IND message
859 // is sent to host
860 tANI_U32 measIndPeriod;
861 // This channel list will have current channel also
862 tSirChannelList channelList;
863} tSirSmeMeasurementReq, *tpSirSmeMeasurementReq;
864
865/// Definition for response message to previously
866/// issued Measurement request
867/// MAC --->
868typedef struct sSirSmeMeasurementRsp
869{
870 tANI_U16 messageType; // eWNI_SME_MEASUREMENT_RSP
871 tANI_U16 length;
872 tSirResultCodes statusCode;
873 tANI_U16 transactionId; // Transaction ID for cmd
874} tSirSmeMeasurementRsp, *tpSirSmeMeasurementRsp;
875
876/// Definition for Measurement Matrix info
877// NOTE: This should include current channel measurements
878typedef struct sSirMeasMatrixInfo
879{
880 tANI_U8 channelNumber;
881 tANI_S8 compositeRssi;
882 tANI_S32 aggrRssi; // Due to all packets in this channel
883 tANI_U32 totalPackets;
884} tSirMeasMatrixInfo, *tpSirMeasMatrixInfo;
885
886/// Definition for Measurement Matrix List
887typedef struct sSirMeasMatrixList
888{
889 tANI_U8 numChannels;
890 tSirMeasMatrixInfo measMatrixList[1];
891} tSirMeasMatrixList, *tpSirMeasMatrixList;
892/// Definition for Measurement indication
893/// MAC --->
894/// Note : This is only sent when there was prior
895/// SME_MEASUREMENT_REQ received by MAC
896typedef struct sSirSmeMeasurementInd
897{
898 tANI_U16 messageType; // eWNI_SME_MEASUREMENT_IND
899 tANI_U16 length;
900 tANI_U32 duration;
901 tSirLoad currentLoad; // on this AP radio
902 tSirMeasMatrixList measMatrixList;
903 tSirNeighborBssWdsList neighborBssWdsList;
904} tSirSmeMeasurementInd, *tpSirSmeMeasurementInd;
905
906/// Definition for Backhaul Link status change Indication
907/// MAC --->
908typedef struct sSirSmeWdsInfoInd
909{
910 tANI_U16 messageType; // eWNI_SME_WDS_INFO_IND
911 tANI_U16 length;
912 tSirWdsInfo wdsInfo;
913} tSirSmeWdsInfoInd, *tpSirSmeWdsInfoInd;
914
915/// Definition for Backhaul Link Info Set Request
916/// ---> MAC
917typedef struct sSirSmeSetWdsInfoReq
918{
919 tANI_U16 messageType; // eWNI_SME_SET_WDS_INFO_REQ
920 tANI_U16 length;
921 tANI_U16 transactionId;
922 tSirWdsInfo wdsInfo;
923} tSirSmeSetWdsInfoReq, *tpSirSmeSetWdsInfoReq;
924
925/// Definition for Backhaul Link Lnfo Set Response
926/// MAC --->
927typedef struct sSirSmeSetWdsInfoRsp
928{
929 tANI_U16 messageType; // eWNI_SME_SET_WDS_INFO_RSP
930 tANI_U16 length;
931 tSirResultCodes statusCode;
932 tANI_U16 transactionId;
933} tSirSmeSetWdsInfoRsp, *tpSirSmeSetWdsInfoRsp;
934#endif
935#endif
936
937/// Definition for Radar Info
938typedef struct sSirRadarInfo
939{
940 tANI_U8 channelNumber;
941 tANI_U16 radarPulseWidth; // in usecond
942 tANI_U16 numRadarPulse;
943} tSirRadarInfo, *tpSirRadarInfo;
944
945#define SIR_RADAR_INFO_SIZE (sizeof(tANI_U8) + 2 *sizeof(tANI_U16))
946
947/// Two Background Scan mode
948typedef enum eSirBackgroundScanMode
949{
950 eSIR_AGGRESSIVE_BACKGROUND_SCAN = 0,
Madan Mohan Koyyalamudi9b876782012-10-11 16:22:51 -0700951 eSIR_NORMAL_BACKGROUND_SCAN = 1,
952 eSIR_ROAMING_SCAN = 2,
Jeff Johnson295189b2012-06-20 16:38:30 -0700953} tSirBackgroundScanMode;
954
955/// Two types of traffic check
956typedef enum eSirLinkTrafficCheck
957{
958 eSIR_DONT_CHECK_LINK_TRAFFIC_BEFORE_SCAN = 0,
Madan Mohan Koyyalamudi9b876782012-10-11 16:22:51 -0700959 eSIR_CHECK_LINK_TRAFFIC_BEFORE_SCAN = 1,
960 eSIR_CHECK_ROAMING_SCAN = 2,
Jeff Johnson295189b2012-06-20 16:38:30 -0700961} tSirLinkTrafficCheck;
962
963#define SIR_BG_SCAN_RETURN_CACHED_RESULTS 0x0
964#define SIR_BG_SCAN_PURGE_RESUTLS 0x80
965#define SIR_BG_SCAN_RETURN_FRESH_RESULTS 0x01
966#define SIR_SCAN_MAX_NUM_SSID 0x09
967
968/// Definition for scan request
969typedef struct sSirSmeScanReq
970{
971 tANI_U16 messageType; // eWNI_SME_SCAN_REQ
972 tANI_U16 length;
973 tANI_U8 sessionId; // Session ID
974 tANI_U16 transactionId; // Transaction ID for cmd
975 tSirMacAddr bssId;
976 tSirMacSSid ssId[SIR_SCAN_MAX_NUM_SSID];
977 tSirMacAddr selfMacAddr; //Added For BT-AMP Support
978 tSirBssType bssType;
979 tANI_U8 dot11mode;
980 tSirScanType scanType;
981 /**
982 * minChannelTime. Not used if scanType is passive.
983 * 0x0 - Dont Use min channel timer. Only max channel timeout will used.
984 * 11k measurements set this to zero to user only single duration for scan.
985 * <valid timeout> - Timeout value used for min channel timeout.
986 */
987 tANI_U32 minChannelTime;
988 /**
989 * maxChannelTime.
990 * 0x0 - Invalid. In case of active scan.
991 * In case of passive scan, MAX( maxChannelTime, WNI_CFG_PASSIVE_MAXIMUM_CHANNEL_TIME) is used.
992 *
993 */
994 tANI_U32 maxChannelTime;
995 /**
996 * returnAfterFirstMatch can take following values:
997 * 0x00 - Return SCAN_RSP message after complete channel scan
998 * 0x01 - Return SCAN_RSP message after collecting BSS description
999 * that matches scan criteria.
1000 * 0xC0 - Return after collecting first 11d IE from 2.4 GHz &
1001 * 5 GHz band channels
1002 * 0x80 - Return after collecting first 11d IE from 5 GHz band
1003 * channels
1004 * 0x40 - Return after collecting first 11d IE from 2.4 GHz
1005 * band channels
1006 *
1007 * Values of 0xC0, 0x80 & 0x40 are to be used by
1008 * Roaming/application when 11d is enabled.
1009 */
1010 tANI_U8 returnAfterFirstMatch;
1011
1012 /**
1013 * returnUniqueResults can take following values:
1014 * 0 - Collect & report all received BSS descriptions from same BSS.
1015 * 1 - Collect & report unique BSS description from same BSS.
1016 */
1017 tANI_U8 returnUniqueResults;
1018
1019 /**
1020 * returnFreshResults can take following values:
1021 * 0x00 - Return background scan results.
1022 * 0x80 - Return & purge background scan results
1023 * 0x01 - Trigger fresh scan instead of returning background scan
1024 * results.
1025 * 0x81 - Trigger fresh scan instead of returning background scan
1026 * results and purge background scan results.
1027 */
1028 tANI_U8 returnFreshResults;
1029
1030 /* backgroundScanMode can take following values:
1031 * 0x0 - agressive scan
1032 * 0x1 - normal scan where HAL will check for link traffic
1033 * prior to proceeding with the scan
1034 */
1035 tSirBackgroundScanMode backgroundScanMode;
1036
1037 tANI_U8 hiddenSsid;
1038
1039 /* Number of SSIDs to scan */
1040 tANI_U8 numSsid;
1041
1042 //channelList has to be the last member of this structure. Check tSirChannelList for the reason.
1043 /* This MUST be the last field of the structure */
1044
1045
1046#ifdef WLAN_FEATURE_P2P
1047 tANI_BOOLEAN p2pSearch;
1048#endif
1049 tANI_U16 uIEFieldLen;
1050 tANI_U16 uIEFieldOffset;
1051
1052 //channelList MUST be the last field of this structure
1053 tSirChannelList channelList;
1054 /*-----------------------------
1055 tSirSmeScanReq....
1056 -----------------------------
1057 uIEFiledLen
1058 -----------------------------
1059 uIEFiledOffset ----+
1060 ----------------------------- |
1061 channelList.numChannels |
1062 ----------------------------- |
1063 ... variable size up to |
1064 channelNumber[numChannels-1] |
1065 This can be zero, if |
1066 numChannel is zero. |
1067 ----------------------------- <--+
1068 ... variable size uIEFiled
1069 up to uIEFieldLen (can be 0)
1070 -----------------------------*/
1071} tSirSmeScanReq, *tpSirSmeScanReq;
1072
Jeff Johnsone7245742012-09-05 17:12:55 -07001073#ifdef FEATURE_OEM_DATA_SUPPORT
1074
1075#ifndef OEM_DATA_REQ_SIZE
Madan Mohan Koyyalamudi7a4d9312012-12-04 17:21:36 -08001076#define OEM_DATA_REQ_SIZE 134
Jeff Johnsone7245742012-09-05 17:12:55 -07001077#endif
1078#ifndef OEM_DATA_RSP_SIZE
Madan Mohan Koyyalamudi7a4d9312012-12-04 17:21:36 -08001079#define OEM_DATA_RSP_SIZE 1968
Jeff Johnsone7245742012-09-05 17:12:55 -07001080#endif
1081
1082typedef struct sSirOemDataReq
1083{
1084 tANI_U16 messageType; //eWNI_SME_OEM_DATA_REQ
1085 tSirMacAddr selfMacAddr;
1086 tANI_U8 oemDataReq[OEM_DATA_REQ_SIZE];
1087} tSirOemDataReq, *tpSirOemDataReq;
1088
1089typedef struct sSirOemDataRsp
1090{
1091 tANI_U16 messageType;
1092 tANI_U16 length;
1093 tANI_U8 oemDataRsp[OEM_DATA_RSP_SIZE];
1094} tSirOemDataRsp, *tpSirOemDataRsp;
1095
1096#endif //FEATURE_OEM_DATA_SUPPORT
Jeff Johnson295189b2012-06-20 16:38:30 -07001097
1098/// Definition for response message to previously issued scan request
1099typedef struct sSirSmeScanRsp
1100{
1101 tANI_U16 messageType; // eWNI_SME_SCAN_RSP
1102 tANI_U16 length;
1103 tANI_U8 sessionId;
1104 tSirResultCodes statusCode;
1105 tANI_U16 transcationId;
1106 tSirBssDescription bssDescription[1];
1107} tSirSmeScanRsp, *tpSirSmeScanRsp;
1108
1109/// Sme Req message to set the Background Scan mode
1110typedef struct sSirSmeBackgroundScanModeReq
1111{
1112 tANI_U16 messageType; // eWNI_SME_BACKGROUND_SCAN_MODE_REQ
1113 tANI_U16 length;
1114 tSirBackgroundScanMode mode;
1115} tSirSmeBackgroundScanModeReq, *tpSirSmeBackgroundScanModeReq;
1116
1117/// Background Scan Statisics
1118typedef struct sSirBackgroundScanInfo {
1119 tANI_U32 numOfScanSuccess;
1120 tANI_U32 numOfScanFailure;
1121 tANI_U32 reserved;
1122} tSirBackgroundScanInfo, *tpSirBackgroundScanInfo;
1123
1124#define SIR_BACKGROUND_SCAN_INFO_SIZE (3 * sizeof(tANI_U32))
1125
1126/// Definition for Authentication request
1127typedef struct sSirSmeAuthReq
1128{
1129 tANI_U16 messageType; // eWNI_SME_AUTH_REQ
1130 tANI_U16 length;
1131 tANI_U8 sessionId; // Session ID
1132 tANI_U16 transactionId; // Transaction ID for cmd
1133 tSirMacAddr bssId; // Self BSSID
1134 tSirMacAddr peerMacAddr;
1135 tAniAuthType authType;
1136 tANI_U8 channelNumber;
1137} tSirSmeAuthReq, *tpSirSmeAuthReq;
1138
1139/// Definition for reponse message to previously issued Auth request
1140typedef struct sSirSmeAuthRsp
1141{
1142 tANI_U16 messageType; // eWNI_SME_AUTH_RSP
1143 tANI_U16 length;
1144 tANI_U8 sessionId; // Session ID
1145 tANI_U16 transactionId; // Transaction ID for cmd
1146 tSirMacAddr peerMacAddr;
1147 tAniAuthType authType;
1148 tSirResultCodes statusCode;
1149 tANI_U16 protStatusCode; //It holds reasonCode when Pre-Auth fails due to deauth frame.
1150 //Otherwise it holds status code.
1151} tSirSmeAuthRsp, *tpSirSmeAuthRsp;
1152
1153#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1154/// Association type
1155typedef enum eSirAssocType
1156{
1157 eSIR_NORMAL,
1158 eSIR_TRANSFERRED,
1159 eSIR_DONOT_USE_ASSOC_TYPE = SIR_MAX_ENUM_SIZE
1160} tSirAssocType;
1161#endif
1162
1163#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1164typedef enum eSirBpIndicatorType
1165{
1166 eSIR_WIRELESS_BP,
1167 eSIR_WIRED_BP
1168} tSirBpIndicatorType;
1169
1170#endif
1171
1172#ifdef FEATURE_WLAN_INTEGRATED_SOC
1173/// Definition for Join/Reassoc info - Reshmi: need to check if this is a def which moved from elsehwere.
1174typedef struct sJoinReassocInfo
1175{
1176 tAniTitanCBNeighborInfo cbNeighbors;
1177 tAniBool spectrumMgtIndicator;
1178 tSirMacPowerCapInfo powerCap;
1179 tSirSupChnl supportedChannels;
1180} tJoinReassocInfo, *tpJoinReassocInfo;
1181#endif
1182
1183/// Definition for join request
1184/// ---> MAC
1185/// WARNING! If you add a field in JOIN REQ.
1186/// Make sure to add it in REASSOC REQ
1187/// The Serdes function is the same and its
1188/// shared with REASSOC. So if we add a field
1189// here and dont add it in REASSOC REQ. It will BREAK!!! REASSOC.
1190typedef struct sSirSmeJoinReq
1191{
1192 tANI_U16 messageType; // eWNI_SME_JOIN_REQ
1193 tANI_U16 length;
Jeff Johnsone7245742012-09-05 17:12:55 -07001194 tANI_U8 sessionId;
Jeff Johnson295189b2012-06-20 16:38:30 -07001195 tANI_U16 transactionId;
1196 tSirMacSSid ssId;
1197 tSirMacAddr selfMacAddr; // self Mac address
1198 tSirBssType bsstype; // add new type for BT -AMP STA and AP Modules
1199 tANI_U8 dot11mode; // to support BT-AMP
Jeff Johnsone7245742012-09-05 17:12:55 -07001200 tVOS_CON_MODE staPersona; //Persona
1201 ePhyChanBondState cbMode; // Pass CB mode value in Join.
Jeff Johnson295189b2012-06-20 16:38:30 -07001202
1203 /*This contains the UAPSD Flag for all 4 AC
1204 * B0: AC_VO UAPSD FLAG
1205 * B1: AC_VI UAPSD FLAG
1206 * B2: AC_BK UAPSD FLAG
1207 * B3: AC_BE UASPD FLAG
1208 */
1209 tANI_U8 uapsdPerAcBitmask;
1210
1211#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1212 tSirAssocType assocType; // Indicates whether STA is
1213 // sending (Re) Association
1214 // due to load balance or not
1215#endif
1216 tSirMacRateSet operationalRateSet;// Has 11a or 11b rates
1217 tSirMacRateSet extendedRateSet; // Has 11g rates
1218 tSirRSNie rsnIE; // RSN IE to be sent in
1219 // (Re) Association Request
1220#ifdef FEATURE_WLAN_CCX
1221 tSirCCKMie cckmIE; // CCMK IE to be included as handler for join and reassoc is
1222 // the same. The join will never carry cckm, but will be set to
1223 // 0.
1224#endif
1225
1226 tSirAddie addIEScan; // Additional IE to be sent in
1227 // (unicast) Probe Request at the time of join
1228
1229 tSirAddie addIEAssoc; // Additional IE to be sent in
1230 // (Re) Association Request
1231
1232 tAniEdType UCEncryptionType;
1233
1234 tAniEdType MCEncryptionType;
1235#ifdef WLAN_FEATURE_VOWIFI_11R
1236 tAniBool is11Rconnection;
1237#endif
1238#ifdef FEATURE_WLAN_CCX
1239 tAniBool isCCXconnection;
1240 tCCXTspecInfo ccxTspecInfo;
1241#endif
1242
Jeff Johnson04dd8a82012-06-29 20:41:40 -07001243#if defined WLAN_FEATURE_VOWIFI_11R || defined FEATURE_WLAN_CCX || defined(FEATURE_WLAN_LFR)
Jeff Johnson295189b2012-06-20 16:38:30 -07001244 tAniBool isFastTransitionEnabled;
1245#endif
Jeff Johnson43971f52012-07-17 12:26:56 -07001246#ifdef FEATURE_WLAN_LFR
1247 tAniBool isFastRoamIniFeatureEnabled;
1248#endif
Jeff Johnson295189b2012-06-20 16:38:30 -07001249
1250#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
1251 tAniBool bpIndicator;
1252 tSirBpIndicatorType bpType;
1253 tSirNeighborBssList neighborBssList; // TBD Move this outside 'AP'
1254 // flag
1255#endif
1256 tAniTitanCBNeighborInfo cbNeighbors;
1257 tAniBool spectrumMgtIndicator;
1258 tSirMacPowerCapInfo powerCap;
1259 tSirSupChnl supportedChannels;
1260//#if (WNI_POLARIS_FW_PRODUCT == WLAN_STA )
1261 tSirBssDescription bssDescription;
1262//#endif
1263
1264} tSirSmeJoinReq, *tpSirSmeJoinReq;
1265
1266/// Definition for reponse message to previously issued join request
1267/// MAC --->
1268typedef struct sSirSmeJoinRsp
1269{
1270 tANI_U16 messageType; // eWNI_SME_JOIN_RSP
1271 tANI_U16 length;
1272 tANI_U8 sessionId; // Session ID
1273 tANI_U16 transactionId; // Transaction ID for cmd
1274 tSirResultCodes statusCode;
1275#if (WNI_POLARIS_FW_PRODUCT == WLAN_STA)
1276 tAniAuthType authType;
1277// tANI_U16 staId; // Station ID for peer
1278#endif
1279#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1280 // Following are needed for Roaming algorithm
1281 // to 'associate' with an alternate BSS.
1282 tSirMacAddr alternateBssId;
1283 tANI_U8 alternateChannelId;
1284#endif
1285 tANI_U16 protStatusCode; //It holds reasonCode when join fails due to deauth/disassoc frame.
1286 //Otherwise it holds status code.
1287 tANI_U16 aid;
1288 tANI_U32 beaconLength;
1289 tANI_U32 assocReqLength;
1290 tANI_U32 assocRspLength;
1291#ifdef WLAN_FEATURE_VOWIFI_11R
1292 tANI_U32 parsedRicRspLen;
1293#endif
1294#ifdef FEATURE_WLAN_CCX
1295 tANI_U32 tspecIeLen;
1296#endif
1297 tANI_U32 staId;//Station ID for peer
1298
1299 /*The DPU signatures will be sent eventually to TL to help it determine the
1300 association to which a packet belongs to*/
1301 /*Unicast DPU signature*/
1302 tANI_U8 ucastSig;
1303
1304 /*Broadcast DPU signature*/
1305 tANI_U8 bcastSig;
1306
1307 tANI_U8 frames[ 1 ];
1308} tSirSmeJoinRsp, *tpSirSmeJoinRsp;
1309
1310/// Definition for Authentication indication from peer
1311typedef struct sSirSmeAuthInd
1312{
1313 tANI_U16 messageType; // eWNI_SME_AUTH_IND
1314 tANI_U16 length;
1315 tANI_U8 sessionId;
1316 tSirMacAddr bssId; // Self BSSID
1317 tSirMacAddr peerMacAddr;
1318 tAniAuthType authType;
1319} tSirSmeAuthInd, *tpSirSmeAuthInd;
1320
1321/// probereq from peer, when wsc is enabled
1322typedef struct sSirSmeProbereq
1323{
1324 tANI_U16 messageType; // eWNI_SME_PROBE_REQ
1325 tANI_U16 length;
1326 tANI_U8 sessionId;
1327 tSirMacAddr peerMacAddr;
1328 tANI_U16 devicePasswdId;
1329} tSirSmeProbeReq, *tpSirSmeProbeReq;
1330
1331/// Definition for Association indication from peer
1332/// MAC --->
1333typedef struct sSirSmeAssocInd
1334{
1335 tANI_U16 messageType; // eWNI_SME_ASSOC_IND
1336 tANI_U16 length;
1337 tANI_U8 sessionId;
1338 tSirMacAddr peerMacAddr;
1339 tANI_U16 aid;
1340 tSirMacAddr bssId; // Self BSSID
1341 tANI_U16 staId; // Station ID for peer
1342 tANI_U8 uniSig; // DPU signature for unicast packets
1343 tANI_U8 bcastSig; // DPU signature for broadcast packets
1344 tAniAuthType authType;
1345 tAniSSID ssId; // SSID used by STA to associate
1346 tSirRSNie rsnIE;// RSN IE received from peer
1347 tSirAddie addIE;// Additional IE received from peer, which possibly include WSC IE and/or P2P IE
1348
1349#if defined (ANI_PRODUCT_TYPE_AP)
1350 tANI_U16 seqNum;
1351 tAniBool wniIndicator;
1352 tAniBool bpIndicator;
1353 tSirBpIndicatorType bpType;
1354 tSirAssocType assocType; // Indicates whether STA is LB'ed or not
1355 tSirLoad load; // Current load on the radio for LB
1356 tSirNeighborBssList neighborList; // List received from STA
1357 tANI_U16 capabilityInfo; // STA capability
1358 tSirNwType nwType; // Indicates 11a/b/g
1359#endif
Jeff Johnson295189b2012-06-20 16:38:30 -07001360 // powerCap & supportedChannels are present only when
1361 // spectrumMgtIndicator flag is set
1362 tAniBool spectrumMgtIndicator;
1363 tSirMacPowerCapInfo powerCap;
1364 tSirSupChnl supportedChannels;
1365#ifdef WLAN_SOFTAP_FEATURE
1366 tAniBool wmmEnabledSta; /* if present - STA is WMM enabled */
1367 tAniBool reassocReq;
1368 // Required for indicating the frames to upper layer
1369 tANI_U32 beaconLength;
1370 tANI_U8* beaconPtr;
1371 tANI_U32 assocReqLength;
1372 tANI_U8* assocReqPtr;
1373#endif
1374} tSirSmeAssocInd, *tpSirSmeAssocInd;
1375
1376
1377/// Definition for Association confirm
1378/// ---> MAC
1379typedef struct sSirSmeAssocCnf
1380{
1381 tANI_U16 messageType; // eWNI_SME_ASSOC_CNF
1382 tANI_U16 length;
1383 tSirResultCodes statusCode;
1384 tSirMacAddr bssId; // Self BSSID
1385 tSirMacAddr peerMacAddr;
1386 tANI_U16 aid;
1387 tSirMacAddr alternateBssId;
1388 tANI_U8 alternateChannelId;
1389} tSirSmeAssocCnf, *tpSirSmeAssocCnf;
1390
1391/// Definition for Reassociation request
1392/// ---> MAC
1393/// WARNING! If you add a field in REASSOC REQ.
1394/// Make sure to add it in JOIN REQ
1395/// The Serdes function is the same and its
1396/// shared with REASSOC. So if we add a field
1397// here and dont add it in JOIN REQ. It will BREAK!!! JOIN.
1398typedef struct sSirSmeReassocReq
1399{
1400 tANI_U16 messageType; // eWNI_SME_REASSOC_REQ
1401 tANI_U16 length;
1402 tANI_U8 sessionId;
1403 tANI_U16 transactionId;
1404 tSirMacSSid ssId;
1405 tSirMacAddr selfMacAddr; // self Mac address
1406 tSirBssType bsstype; // add new type for BT -AMP STA and AP Modules
1407 tANI_U8 dot11mode; // to support BT-AMP
Jeff Johnsone7245742012-09-05 17:12:55 -07001408 tVOS_CON_MODE staPersona; //Persona
1409 ePhyChanBondState cbMode; // CBMode value to be passed with reassoc req
Jeff Johnson295189b2012-06-20 16:38:30 -07001410
1411 /*This contains the UAPSD Flag for all 4 AC
1412 * B0: AC_VO UAPSD FLAG
1413 * B1: AC_VI UAPSD FLAG
1414 * B2: AC_BK UAPSD FLAG
1415 * B3: AC_BE UASPD FLAG
1416 */
1417 tANI_U8 uapsdPerAcBitmask;
1418
1419#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1420 tSirAssocType assocType; // Indicates whether STA is
1421 // sending (Re) Association
1422 // due to load balance or not
1423#endif
1424
1425 tSirMacRateSet operationalRateSet;// Has 11a or 11b rates
1426 tSirMacRateSet extendedRateSet; // Has 11g rates
1427
1428 tSirRSNie rsnIE; // RSN IE to be sent in
1429 // (Re) Association Request
1430
1431#ifdef FEATURE_WLAN_CCX
1432 tSirCCKMie cckmIE; // CCMK IE to be included in ReAssoc if length != 0.
1433#endif
1434 tSirAddie addIEScan; // Addtional IE to be sent in
1435 // (unicast) Probe Request at the time of join
1436
1437 tSirAddie addIEAssoc; // Additional IE to be sent in
1438 // (Re) Association Request
1439
1440 tAniEdType UCEncryptionType;
1441 tAniEdType MCEncryptionType;
1442#ifdef WLAN_FEATURE_VOWIFI_11R
1443 tAniBool is11Rconnection;
1444#endif
1445#ifdef FEATURE_WLAN_CCX
1446 tAniBool isCCXconnection;
1447 tCCXTspecInfo ccxTspecInfo;
1448#endif
Jeff Johnson04dd8a82012-06-29 20:41:40 -07001449#if defined WLAN_FEATURE_VOWIFI_11R || defined FEATURE_WLAN_CCX || defined(FEATURE_WLAN_LFR)
Jeff Johnson295189b2012-06-20 16:38:30 -07001450 tAniBool isFastTransitionEnabled;
1451#endif
Jeff Johnson43971f52012-07-17 12:26:56 -07001452#ifdef FEATURE_WLAN_LFR
1453 tAniBool isFastRoamIniFeatureEnabled;
1454#endif
Jeff Johnson295189b2012-06-20 16:38:30 -07001455
1456#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
1457 tAniBool bpIndicator;
1458 tSirBpIndicatorType bpType;
1459 tSirNeighborBssList neighborBssList;
1460#endif
1461 tAniTitanCBNeighborInfo cbNeighbors;
1462 tAniBool spectrumMgtIndicator;
1463 tSirMacPowerCapInfo powerCap;
1464 tSirSupChnl supportedChannels;
1465//#if (WNI_POLARIS_FW_PRODUCT == WLAN_STA )
1466 tSirBssDescription bssDescription;
1467//#endif
1468} tSirSmeReassocReq, *tpSirSmeReassocReq;
1469
1470/// Definition for reponse message to previously issued
1471/// Reassociation request
1472typedef struct sSirSmeReassocRsp
1473{
1474 tANI_U16 messageType; // eWNI_SME_REASSOC_RSP
1475 tANI_U16 length;
1476 tANI_U8 sessionId; // Session ID
1477 tANI_U16 transactionId; // Transaction ID for cmd
1478 tSirResultCodes statusCode;
1479 tANI_U8 staId; // Station ID for peer
1480#if (WNI_POLARIS_FW_PRODUCT == WLAN_STA)
1481 tAniAuthType authType;
1482#endif
1483#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1484 tSirMacAddr alternateBssId;
1485 tANI_U8 alternateChannelId;
1486#endif
1487} tSirSmeReassocRsp, *tpSirSmeReassocRsp;
1488
1489/// Definition for Reassociation indication from peer
1490typedef struct sSirSmeReassocInd
1491{
1492 tANI_U16 messageType; // eWNI_SME_REASSOC_IND
1493 tANI_U16 length;
1494 tANI_U8 sessionId; // Session ID
1495 tSirMacAddr peerMacAddr;
1496 tSirMacAddr oldMacAddr;
1497 tANI_U16 aid;
1498 tSirMacAddr bssId; // Self BSSID
1499 tANI_U16 staId; // Station ID for peer
1500 tAniAuthType authType;
1501 tAniSSID ssId; // SSID used by STA to reassociate
1502 tSirRSNie rsnIE; // RSN IE received from peer
1503
1504 tSirAddie addIE; // Additional IE received from peer
1505
1506#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1507 tANI_U16 seqNum;
1508 tAniBool wniIndicator;
1509 tAniBool bpIndicator;
1510 tSirBpIndicatorType bpType;
1511 tSirAssocType reassocType; // Indicates whether STA is LB'ed or not
1512 tSirLoad load; // Current load on the radio for LB
1513 tSirNeighborBssList neighborList; // List received from STA
1514 tANI_U16 capabilityInfo; // STA capability
1515 tSirNwType nwType; // Indicates 11a/b/g
1516#endif
Jeff Johnson295189b2012-06-20 16:38:30 -07001517 // powerCap & supportedChannels are present only when
1518 // spectrumMgtIndicator flag is set
1519 tAniBool spectrumMgtIndicator;
1520 tSirMacPowerCapInfo powerCap;
1521 tSirSupChnl supportedChannels;
1522#ifdef WLAN_SOFTAP_FEATURE
1523 // Required for indicating the frames to upper layer
1524 // TODO: use the appropriate names to distinguish between the other similar names used above for station mode of operation
1525 tANI_U32 beaconLength;
1526 tANI_U8* beaconPtr;
1527 tANI_U32 assocReqLength;
1528 tANI_U8* assocReqPtr;
1529#endif
1530} tSirSmeReassocInd, *tpSirSmeReassocInd;
1531
1532/// Definition for Reassociation confirm
1533/// ---> MAC
1534typedef struct sSirSmeReassocCnf
1535{
1536 tANI_U16 messageType; // eWNI_SME_REASSOC_CNF
1537 tANI_U16 length;
1538 tSirResultCodes statusCode;
1539 tSirMacAddr bssId; // Self BSSID
1540 tSirMacAddr peerMacAddr;
1541 tANI_U16 aid;
1542 tSirMacAddr alternateBssId;
1543 tANI_U8 alternateChannelId;
1544} tSirSmeReassocCnf, *tpSirSmeReassocCnf;
1545
1546#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
1547typedef enum {
1548 // Based on Periodic evaluation
1549 eSIR_PERIODIC_EVALATION,
1550
1551 // Dectection of primary users such as RADARs
1552 eSIR_DETECTION_OF_RADAR,
1553
1554 // Degradation in system performance (eg. Triggered by
1555 // increase in PER beyond a certain threshold)
1556 eSIR_PERFORMANCE_DEGRADATION,
1557
1558 // Frequency changed due to previously issued SWITCH_CHANNEL_REQ
1559 eSIR_UPPER_LAYER_TRIGGERED
1560}tSirFreqChangeReason;
1561#endif
1562
1563/// Enum definition for Wireless medium status change codes
1564typedef enum eSirSmeStatusChangeCode
1565{
1566 eSIR_SME_DEAUTH_FROM_PEER,
1567 eSIR_SME_DISASSOC_FROM_PEER,
1568 eSIR_SME_LOST_LINK_WITH_PEER,
1569 eSIR_SME_CHANNEL_SWITCH,
1570 eSIR_SME_JOINED_NEW_BSS,
1571 eSIR_SME_LEAVING_BSS,
1572 eSIR_SME_IBSS_ACTIVE,
1573 eSIR_SME_IBSS_INACTIVE,
1574 eSIR_SME_IBSS_PEER_DEPARTED,
1575 eSIR_SME_RADAR_DETECTED,
1576 eSIR_SME_IBSS_NEW_PEER,
1577 eSIR_SME_AP_CAPS_CHANGED,
1578 eSIR_SME_BACKGROUND_SCAN_FAIL,
1579 eSIR_SME_CB_LEGACY_BSS_FOUND_BY_AP,
1580 eSIR_SME_CB_LEGACY_BSS_FOUND_BY_STA
1581} tSirSmeStatusChangeCode;
1582
1583typedef struct sSirSmeNewBssInfo
1584{
1585 tSirMacAddr bssId;
1586 tANI_U8 channelNumber;
1587 tANI_U8 reserved;
1588 tSirMacSSid ssId;
1589} tSirSmeNewBssInfo, *tpSirSmeNewBssInfo;
1590
1591typedef struct sSirSmeApNewCaps
1592{
1593 tANI_U16 capabilityInfo;
1594 tSirMacAddr bssId;
1595 tANI_U8 channelId;
1596 tANI_U8 reserved[3];
1597 tSirMacSSid ssId;
1598} tSirSmeApNewCaps, *tpSirSmeApNewCaps;
1599
1600/**
1601 * Table below indicates what information is passed for each of
1602 * the Wireless Media status change notifications:
1603 *
1604 * Status Change code Status change info
1605 * ----------------------------------------------------------------------
1606 * eSIR_SME_DEAUTH_FROM_PEER Reason code received in DEAUTH frame
1607 * eSIR_SME_DISASSOC_FROM_PEER Reason code received in DISASSOC frame
1608 * eSIR_SME_LOST_LINK_WITH_PEER None
1609 * eSIR_SME_CHANNEL_SWITCH New channel number
1610 * eSIR_SME_JOINED_NEW_BSS BSSID, SSID and channel number
1611 * eSIR_SME_LEAVING_BSS None
1612 * eSIR_SME_IBSS_ACTIVE Indicates that another STA joined
1613 * IBSS apart from this STA that
1614 * started IBSS
1615 * eSIR_SME_IBSS_INACTIVE Indicates that only this STA is left
1616 * in IBSS
1617 * eSIR_SME_RADAR_DETECTED Indicates that radar is detected
1618 * eSIR_SME_IBSS_NEW_PEER Indicates that a new peer is detected
1619 * eSIR_SME_AP_CAPS_CHANGED Indicates that capabilities of the AP
1620 * that STA is currently associated with
1621 * have changed.
1622 * eSIR_SME_BACKGROUND_SCAN_FAIL Indicates background scan failure
1623 */
1624
1625/// Definition for Wireless medium status change notification
1626typedef struct sSirSmeWmStatusChangeNtf
1627{
1628 tANI_U16 messageType; // eWNI_SME_WM_STATUS_CHANGE_NTF
1629 tANI_U16 length;
1630 tANI_U8 sessionId; // Session ID
1631 tSirSmeStatusChangeCode statusChangeCode;
1632 tSirMacAddr bssId; // Self BSSID
1633 union
1634 {
1635 tANI_U16 deAuthReasonCode; // eSIR_SME_DEAUTH_FROM_PEER
1636 tANI_U16 disassocReasonCode; // eSIR_SME_DISASSOC_FROM_PEER
1637 // none for eSIR_SME_LOST_LINK_WITH_PEER
1638 tANI_U8 newChannelId; // eSIR_SME_CHANNEL_SWITCH
1639 tSirSmeNewBssInfo newBssInfo; // eSIR_SME_JOINED_NEW_BSS
1640 // none for eSIR_SME_LEAVING_BSS
1641 // none for eSIR_SME_IBSS_ACTIVE
1642 // none for eSIR_SME_IBSS_INACTIVE
1643#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
1644 tSirRadarInfo radarInfo; // eSIR_SME_RADAR_DETECTED
1645#endif
1646 tSirNewIbssPeerInfo newIbssPeerInfo; // eSIR_SME_IBSS_NEW_PEER
1647 tSirSmeApNewCaps apNewCaps; // eSIR_SME_AP_CAPS_CHANGED
1648 tSirBackgroundScanInfo bkgndScanInfo; // eSIR_SME_BACKGROUND_SCAN_FAIL
1649 tAniTitanCBNeighborInfo cbNeighbors; // eSIR_SME_CB_LEGACY_BSS_FOUND_BY_STA
1650#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1651 tSirNeighborBssWdsInfo neighborWdsInfo; // eSIR_SME_CB_LEGACY_BSS_FOUND_BY_AP
1652#endif
1653 } statusChangeInfo;
1654} tSirSmeWmStatusChangeNtf, *tpSirSmeWmStatusChangeNtf;
1655
1656/// Definition for Disassociation request
1657typedef
1658#ifdef WLAN_SOFTAP_FEATURE
1659__ani_attr_pre_packed
1660#endif
1661struct sSirSmeDisassocReq
1662{
1663 tANI_U16 messageType; // eWNI_SME_DISASSOC_REQ
1664 tANI_U16 length;
1665 tANI_U8 sessionId; // Session ID
1666 tANI_U16 transactionId; // Transaction ID for cmd
1667 tSirMacAddr bssId; // Peer BSSID
1668 tSirMacAddr peerMacAddr;
1669 tANI_U16 reasonCode;
1670 tANI_U8 doNotSendOverTheAir; //This flag tells LIM whether to send the disassoc OTA or not
1671 //This will be set in while handing off from one AP to other
1672#if (WNI_POLARIS_FW_PRODUCT == AP)
1673 tANI_U16 aid;
1674#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
1675 tANI_U16 seqNum;
1676#endif
1677#endif
1678}
1679#ifdef WLAN_SOFTAP_FEATURE
1680__ani_attr_packed
1681#endif
1682tSirSmeDisassocReq, *tpSirSmeDisassocReq;
1683
1684/// Definition for Tkip countermeasures request
1685#ifdef WLAN_SOFTAP_FEATURE
1686typedef __ani_attr_pre_packed struct sSirSmeTkipCntrMeasReq
1687{
1688 tANI_U16 messageType; // eWNI_SME_DISASSOC_REQ
1689 tANI_U16 length;
1690 tANI_U8 sessionId; // Session ID
1691 tANI_U16 transactionId; // Transaction ID for cmd
1692 tSirMacAddr bssId; // Peer BSSID
1693 tANI_BOOLEAN bEnable; // Start/stop countermeasures
1694} __ani_attr_packed tSirSmeTkipCntrMeasReq, *tpSirSmeTkipCntrMeasReq;
1695#endif
1696
1697typedef struct sAni64BitCounters
1698{
1699 tANI_U32 Hi;
1700 tANI_U32 Lo;
1701}tAni64BitCounters, *tpAni64BitCounters;
1702
1703typedef struct sAniSecurityStat
1704{
1705 tAni64BitCounters txBlks;
1706 tAni64BitCounters rxBlks;
1707 tAni64BitCounters formatErrorCnt;
1708 tAni64BitCounters decryptErr;
1709 tAni64BitCounters protExclCnt;
1710 tAni64BitCounters unDecryptableCnt;
1711 tAni64BitCounters decryptOkCnt;
1712
1713}tAniSecurityStat, *tpAniSecurityStat;
1714
1715typedef struct sAniTxRxCounters
1716{
1717 tANI_U32 txFrames; // Incremented for every packet tx
1718 tANI_U32 rxFrames;
1719 tANI_U32 nRcvBytes;
1720 tANI_U32 nXmitBytes;
1721}tAniTxRxCounters, *tpAniTxRxCounters;
1722
1723typedef struct sAniTxRxStats
1724{
1725 tAni64BitCounters txFrames;
1726 tAni64BitCounters rxFrames;
1727 tAni64BitCounters nRcvBytes;
1728 tAni64BitCounters nXmitBytes;
1729
1730}tAniTxRxStats,*tpAniTxRxStats;
1731
1732typedef struct sAniSecStats
1733{
1734 tAniSecurityStat aes;
1735 tAni64BitCounters aesReplays;
1736 tAniSecurityStat tkip;
1737 tAni64BitCounters tkipReplays;
1738 tAni64BitCounters tkipMicError;
1739
1740 tAniSecurityStat wep;
1741#if defined(FEATURE_WLAN_WAPI) && !defined(LIBRA_WAPI_SUPPORT)
1742 tAniSecurityStat wpi;
1743 tAni64BitCounters wpiReplays;
1744 tAni64BitCounters wpiMicError;
1745#endif
1746}tAniSecStats, *tpAniSecStats;
1747
1748#define SIR_MAX_RX_CHAINS 3
1749
1750typedef struct sAniStaStatStruct
1751{
1752 /* following statistic elements till expandPktRxCntLo are not filled with valid data.
1753 * These are kept as it is, since WSM is using this structure.
1754 * These elements can be removed whenever WSM is updated.
1755 * Phystats is used to hold phystats from BD.
1756 */
1757 tANI_U32 sentAesBlksUcastHi;
1758 tANI_U32 sentAesBlksUcastLo;
1759 tANI_U32 recvAesBlksUcastHi;
1760 tANI_U32 recvAesBlksUcastLo;
1761 tANI_U32 aesFormatErrorUcastCnts;
1762 tANI_U32 aesReplaysUcast;
1763 tANI_U32 aesDecryptErrUcast;
1764 tANI_U32 singleRetryPkts;
1765 tANI_U32 failedTxPkts;
1766 tANI_U32 ackTimeouts;
1767 tANI_U32 multiRetryPkts;
1768 tANI_U32 fragTxCntsHi;
1769 tANI_U32 fragTxCntsLo;
1770 tANI_U32 transmittedPktsHi;
1771 tANI_U32 transmittedPktsLo;
1772 tANI_U32 phyStatHi; //These are used to fill in the phystats.
1773 tANI_U32 phyStatLo; //This is only for private use.
1774
1775 tANI_U32 uplinkRssi;
1776 tANI_U32 uplinkSinr;
1777 tANI_U32 uplinkRate;
1778 tANI_U32 downlinkRssi;
1779 tANI_U32 downlinkSinr;
1780 tANI_U32 downlinkRate;
1781 tANI_U32 nRcvBytes;
1782 tANI_U32 nXmitBytes;
1783
1784 // titan 3c stats
1785 tANI_U32 chunksTxCntHi; // Number of Chunks Transmitted
1786 tANI_U32 chunksTxCntLo;
1787 tANI_U32 compPktRxCntHi; // Number of Packets Received that were actually compressed
1788 tANI_U32 compPktRxCntLo;
1789 tANI_U32 expanPktRxCntHi; // Number of Packets Received that got expanded
1790 tANI_U32 expanPktRxCntLo;
1791
1792
1793 /* Following elements are valid and filled in correctly. They have valid values.
1794 */
1795
1796 //Unicast frames and bytes.
1797 tAniTxRxStats ucStats;
1798
1799 //Broadcast frames and bytes.
1800 tAniTxRxStats bcStats;
1801
1802 //Multicast frames and bytes.
1803 tAniTxRxStats mcStats;
1804
1805 tANI_U32 currentTxRate;
1806 tANI_U32 currentRxRate; //Rate in 100Kbps
1807
1808 tANI_U32 maxTxRate;
1809 tANI_U32 maxRxRate;
1810
1811 tANI_S8 rssi[SIR_MAX_RX_CHAINS];
1812
1813
1814 tAniSecStats securityStats;
1815
1816 tANI_U8 currentRxRateIdx; //This the softmac rate Index.
1817 tANI_U8 currentTxRateIdx;
1818
1819} tAniStaStatStruct, *tpAniStaStatStruct;
1820
1821//Statistics that are not maintained per stations.
1822typedef struct sAniGlobalStatStruct
1823{
1824 tAni64BitCounters txError;
1825 tAni64BitCounters rxError;
1826 tAni64BitCounters rxDropNoBuffer;
1827 tAni64BitCounters rxDropDup;
1828 tAni64BitCounters rxCRCError;
1829
1830 tAni64BitCounters singleRetryPkts;
1831 tAni64BitCounters failedTxPkts;
1832 tAni64BitCounters ackTimeouts;
1833 tAni64BitCounters multiRetryPkts;
1834 tAni64BitCounters fragTxCnts;
1835 tAni64BitCounters fragRxCnts;
1836
1837 tAni64BitCounters txRTSSuccess;
1838 tAni64BitCounters txCTSSuccess;
1839 tAni64BitCounters rxRTSSuccess;
1840 tAni64BitCounters rxCTSSuccess;
1841
1842 tAniSecStats securityStats;
1843
1844 tAniTxRxStats mcStats;
1845 tAniTxRxStats bcStats;
1846
1847}tAniGlobalStatStruct,*tpAniGlobalStatStruct;
1848
1849typedef enum sPacketType
1850{
1851 ePACKET_TYPE_UNKNOWN,
1852 ePACKET_TYPE_11A,
1853 ePACKET_TYPE_11G,
1854 ePACKET_TYPE_11B,
1855 ePACKET_TYPE_11N
1856
1857}tPacketType, *tpPacketType;
1858
1859typedef struct sAniStatSummaryStruct
1860{
1861 tAniTxRxStats uc; //Unicast counters.
1862 tAniTxRxStats bc; //Broadcast counters.
1863 tAniTxRxStats mc; //Multicast counters.
1864 tAni64BitCounters txError;
1865 tAni64BitCounters rxError;
1866 tANI_S8 rssi[SIR_MAX_RX_CHAINS]; //For each chain.
1867 tANI_U32 rxRate; // Rx rate of the last received packet.
1868 tANI_U32 txRate;
1869 tANI_U16 rxMCSId; //MCS index is valid only when packet type is ePACKET_TYPE_11N
1870 tANI_U16 txMCSId;
1871 tPacketType rxPacketType;
1872 tPacketType txPacketType;
1873 tSirMacAddr macAddr; //Mac Address of the station from which above RSSI and rate is from.
1874}tAniStatSummaryStruct,*tpAniStatSummaryStruct;
1875
1876#if (WNI_POLARIS_FW_PRODUCT == WLAN_STA)
1877//structure for stats that may be reset, like the ones in sta descriptor
1878//The stats are saved into here before reset. It should be tANI_U32 aligned.
1879typedef struct _sPermStaStats
1880{
1881 //tANI_U32 sentAesBlksUcastHi;
1882 //tANI_U32 sentAesBlksUcastLo;
1883 //tANI_U32 recvAesBlksUcastHi;
1884 //tANI_U32 recvAesBlksUcastLo;
1885 tANI_U32 aesFormatErrorUcastCnts;
1886 tANI_U32 aesReplaysUcast;
1887 tANI_U32 aesDecryptErrUcast;
1888 tANI_U32 singleRetryPkts;
1889 tANI_U32 failedTxPkts;
1890 tANI_U32 ackTimeouts;
1891 tANI_U32 multiRetryPkts;
1892 tANI_U32 fragTxCntsHi;
1893 tANI_U32 fragTxCntsLo;
1894 tANI_U32 transmittedPktsHi;
1895 tANI_U32 transmittedPktsLo;
1896
1897 // titan 3c stats
1898 tANI_U32 chunksTxCntHi; // Number of Chunks Transmitted
1899 tANI_U32 chunksTxCntLo;
1900 tANI_U32 compPktRxCntHi; // Number of Packets Received that were actually compressed
1901 tANI_U32 compPktRxCntLo;
1902 tANI_U32 expanPktRxCntHi; // Number of Packets Received that got expanded
1903 tANI_U32 expanPktRxCntLo;
1904}tPermanentStaStats;
1905
1906#endif//#if (WNI_POLARIS_FW_PRODUCT == WLAN_STA)
1907
1908
1909
1910/// Definition for Disassociation response
1911typedef struct sSirSmeDisassocRsp
1912{
1913 tANI_U16 messageType; // eWNI_SME_DISASSOC_RSP
1914 tANI_U16 length;
1915 tANI_U8 sessionId; // Session ID
1916 tANI_U16 transactionId; // Transaction ID for cmd
1917 tSirResultCodes statusCode;
1918 tSirMacAddr peerMacAddr;
1919#if (WNI_POLARIS_FW_PRODUCT == AP)
1920 tANI_U16 aid;
1921#endif
1922 tAniStaStatStruct perStaStats; // STA stats
1923#ifdef WLAN_SOFTAP_FEATURE
1924 tANI_U16 staId;
1925#endif
1926}
1927#ifdef WLAN_SOFTAP_FEATURE
1928__ani_attr_packed
1929#endif
1930 tSirSmeDisassocRsp, *tpSirSmeDisassocRsp;
1931
1932/// Definition for Disassociation indication from peer
1933typedef struct sSirSmeDisassocInd
1934{
1935 tANI_U16 messageType; // eWNI_SME_DISASSOC_IND
1936 tANI_U16 length;
1937 tANI_U8 sessionId; // Session Identifier
1938 tANI_U16 transactionId; // Transaction Identifier with PE
1939 tSirResultCodes statusCode;
1940 tSirMacAddr bssId;
1941 tSirMacAddr peerMacAddr;
1942#if (WNI_POLARIS_FW_PRODUCT == AP)
1943 tANI_U16 aid;
1944#endif
1945 tAniStaStatStruct perStaStats; // STA stats
1946#ifdef WLAN_SOFTAP_FEATURE
1947 tANI_U16 staId;
1948#endif
Mohit Khanna99d5fd02012-09-11 14:51:20 -07001949 tANI_U32 reasonCode;
Jeff Johnson295189b2012-06-20 16:38:30 -07001950} tSirSmeDisassocInd, *tpSirSmeDisassocInd;
1951
1952/// Definition for Disassociation confirm
1953/// MAC --->
1954typedef struct sSirSmeDisassocCnf
1955{
1956 tANI_U16 messageType; // eWNI_SME_DISASSOC_CNF
1957 tANI_U16 length;
1958 tSirResultCodes statusCode;
1959 tSirMacAddr bssId;
1960 tSirMacAddr peerMacAddr;
1961#if (WNI_POLARIS_FW_PRODUCT == AP)
1962 tANI_U16 aid;
1963#endif
1964} tSirSmeDisassocCnf, *tpSirSmeDisassocCnf;
1965
1966/// Definition for Deauthetication request
1967typedef struct sSirSmeDeauthReq
1968{
1969 tANI_U16 messageType; // eWNI_SME_DEAUTH_REQ
1970 tANI_U16 length;
1971 tANI_U8 sessionId; // Session ID
1972 tANI_U16 transactionId; // Transaction ID for cmd
1973 tSirMacAddr bssId; // AP BSSID
1974 tSirMacAddr peerMacAddr;
1975 tANI_U16 reasonCode;
1976#if (WNI_POLARIS_FW_PRODUCT == AP)
1977 tANI_U16 aid;
1978#endif
1979} tSirSmeDeauthReq, *tpSirSmeDeauthReq;
1980
1981/// Definition for Deauthetication response
1982typedef struct sSirSmeDeauthRsp
1983{
1984 tANI_U16 messageType; // eWNI_SME_DEAUTH_RSP
1985 tANI_U16 length;
1986 tANI_U8 sessionId; // Session ID
1987 tANI_U16 transactionId; // Transaction ID for cmd
1988 tSirResultCodes statusCode;
1989 tSirMacAddr peerMacAddr;
1990#if (WNI_POLARIS_FW_PRODUCT == AP)
1991 tANI_U16 aid;
1992#endif
1993} tSirSmeDeauthRsp, *tpSirSmeDeauthRsp;
1994
1995/// Definition for Deauthetication indication from peer
1996typedef struct sSirSmeDeauthInd
1997{
1998 tANI_U16 messageType; // eWNI_SME_DEAUTH_IND
1999 tANI_U16 length;
2000 tANI_U8 sessionId; //Added for BT-AMP
2001 tANI_U16 transactionId; //Added for BT-AMP
2002 tSirResultCodes statusCode;
2003 tSirMacAddr bssId;// AP BSSID
2004 tSirMacAddr peerMacAddr;
2005#if (WNI_POLARIS_FW_PRODUCT == AP)
2006 tANI_U16 aid;
2007#endif
2008
2009#ifdef WLAN_SOFTAP_FEATURE
2010 tANI_U16 staId;
2011#endif
Mohit Khanna99d5fd02012-09-11 14:51:20 -07002012 tANI_U32 reasonCode;
Jeff Johnson295189b2012-06-20 16:38:30 -07002013} tSirSmeDeauthInd, *tpSirSmeDeauthInd;
2014
2015/// Definition for Deauthentication confirm
2016/// MAC --->
2017typedef struct sSirSmeDeauthCnf
2018{
2019 tANI_U16 messageType; // eWNI_SME_DEAUTH_CNF
2020 tANI_U16 length;
2021 tSirResultCodes statusCode;
2022 tSirMacAddr bssId; // AP BSSID
2023 tSirMacAddr peerMacAddr;
2024#if (WNI_POLARIS_FW_PRODUCT == AP)
2025 tANI_U16 aid;
2026#endif
2027} tSirSmeDeauthCnf, *tpSirSmeDeauthCnf;
2028
2029/// Definition for stop BSS request message
2030typedef struct sSirSmeStopBssReq
2031{
2032 tANI_U16 messageType; // eWNI_SME_STOP_BSS_REQ
2033 tANI_U16 length;
2034 tANI_U8 sessionId; //Session ID
2035 tANI_U16 transactionId; //tranSaction ID for cmd
2036 tSirResultCodes reasonCode;
2037 tSirMacAddr bssId; //Self BSSID
2038} tSirSmeStopBssReq, *tpSirSmeStopBssReq;
2039
2040/// Definition for stop BSS response message
2041typedef struct sSirSmeStopBssRsp
2042{
2043 tANI_U16 messageType; // eWNI_SME_STOP_BSS_RSP
2044 tANI_U16 length;
2045 tSirResultCodes statusCode;
2046 tANI_U8 sessionId; // Session ID
2047 tANI_U16 transactionId; // Transaction ID for cmd
2048} tSirSmeStopBssRsp, *tpSirSmeStopBssRsp;
2049
2050#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
2051/// Definition for Channel Select request
2052/// ---> MAC
2053typedef struct sSirSmeSelectChannelReq
2054{
2055 tANI_U16 messageType; // eWNI_SME_SELECT_CHL_REQ
2056 tANI_U16 length;
2057 tANI_U16 transactionId; // Transaction ID for cmd
2058 tANI_U8 channelId;
2059} tSirSmeSelectChannelReq, *tpSirSmeSelectChannelReq;
2060
2061/// Definition for Channel Select response
2062/// MAC --->
2063typedef struct sSirSmeSelectChannelRsp
2064{
2065 tANI_U16 messageType; // eWNI_SME_SELECT_CHL_RSP
2066 tANI_U16 length;
2067 tSirResultCodes statusCode;
2068 tANI_U16 transactionId; // Transaction ID for cmd
2069} tSirSmeSelectChannelRsp, *tpSirSmeSelectChannelRsp;
2070
2071/// Definition for Channel Switch request
2072/// ---> MAC
2073typedef struct sSirSmeSwitchChannelReq
2074{
2075 // eWNI_SME_SWITCH_CHL_REQ,
2076 // eWNI_SME_SWITCH_CHL_CB_PRIMARY_REQ,
2077 // eWNI_SME_SWITCH_CHL_CB_SECONDARY_REQ
2078 tANI_U16 messageType;
2079
2080 tANI_U16 length;
2081 tANI_U16 transactionId; // Transaction ID for cmd
2082 tANI_U8 channelId;
2083 //
2084 // The cbMode field is applicable to TITAN only.
2085 // This indicates as to how the CB secondary
2086 // channel will be used (if at all).
2087 //
2088 // In a non-CB environment, with 11H enabled,
2089 // this field will be ignored
2090 //
Jeff Johnsone7245742012-09-05 17:12:55 -07002091 ePhyChanBondState cbMode;
Jeff Johnson295189b2012-06-20 16:38:30 -07002092
2093 // dtimFactor indicates the number of DTIM
2094 // Beacon before LIM switches channel
2095 tANI_U32 dtimFactor;
2096} tSirSmeSwitchChannelReq, *tpSirSmeSwitchChannelReq;
2097
2098/// Definition for Channel Switch response
2099/// MAC --->
2100typedef struct sSirSmeSwitchChannelRsp
2101{
2102 tANI_U16 messageType; // eWNI_SME_SWITCH_CHL_RSP
2103 tANI_U16 length;
2104 tSirResultCodes statusCode;
2105 tANI_U16 transactionId; // Transaction ID for cmd
2106} tSirSmeSwitchChannelRsp, *tpSirSmeSwitchChannelRsp;
2107
2108#endif
2109
2110
2111/// Definition for Channel Switch indication for station
2112/// MAC --->
2113typedef struct sSirSmeSwitchChannelInd
2114{
2115 tANI_U16 messageType; // eWNI_SME_SWITCH_CHL_REQ
2116 tANI_U16 length;
2117 tANI_U8 sessionId;
2118 tANI_U16 newChannelId;
2119 tSirMacAddr bssId; // BSSID
2120} tSirSmeSwitchChannelInd, *tpSirSmeSwitchChannelInd;
2121
2122/// Definition for ULA complete indication message
2123typedef struct sirUlaCompleteInd
2124{
2125 tANI_U16 messageType; // eWNI_ULA_COMPLETE_IND
2126 tANI_U16 length;
2127 tSirResultCodes statusCode;
2128 tSirMacAddr peerMacAddr;
2129#if (WNI_POLARIS_FW_PRODUCT == AP)
2130 tANI_U16 aid;
2131#endif
2132} tSirUlaCompleteInd, *tpSirUlaCompleteInd;
2133
2134/// Definition for ULA complete confirmation message
2135typedef struct sirUlaCompleteCnf
2136{
2137 tANI_U16 messageType; // eWNI_ULA_COMPLETE_CNF
2138 tANI_U16 length;
2139 tSirResultCodes statusCode;
2140 tSirMacAddr peerMacAddr;
2141#if (WNI_POLARIS_FW_PRODUCT == AP)
2142 tANI_U16 aid;
2143#endif
2144} tSirUlaCompleteCnf, *tpSirUlaCompleteCnf;
2145
2146/// Definition for Neighbor BSS indication
2147/// MAC --->
2148/// MAC reports this each time a new I/BSS is detected
2149typedef struct sSirSmeNeighborBssInd
2150{
2151 tANI_U16 messageType; // eWNI_SME_NEIGHBOR_BSS_IND
2152 tANI_U16 length;
2153 tANI_U8 sessionId;
2154#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
2155 tSirNeighborBssInfo neighborInfo;
2156 tSirWdsInfo wdsInfo;
2157#else
2158 tSirBssDescription bssDescription[1];
2159#endif
2160} tSirSmeNeighborBssInd, *tpSirSmeNeighborBssInd;
2161
2162/// Definition for MIC failure indication
2163/// MAC --->
2164/// MAC reports this each time a MIC failure occures on Rx TKIP packet
2165typedef struct sSirSmeMicFailureInd
2166{
2167 tANI_U16 messageType; // eWNI_SME_MIC_FAILURE_IND
2168 tANI_U16 length;
2169 tANI_U8 sessionId;
2170 tSirMacAddr bssId; // BSSID
2171 tSirMicFailureInfo info;
2172} tSirSmeMicFailureInd, *tpSirSmeMicFailureInd;
2173
2174
2175/// Definition for Set Context request
2176/// ---> MAC
2177typedef struct sSirSmeSetContextReq
2178{
2179 tANI_U16 messageType; // eWNI_SME_SET_CONTEXT_REQ
2180 tANI_U16 length;
2181 tANI_U8 sessionId; //Session ID
2182 tANI_U16 transactionId; //Transaction ID for cmd
2183 tSirMacAddr peerMacAddr;
2184 tSirMacAddr bssId; // BSSID
2185#if (WNI_POLARIS_FW_PRODUCT == AP)
2186 tANI_U16 aid;
2187#endif
2188 // TBD Following QOS fields to be uncommented
2189 //tAniBool qosInfoPresent;
2190 //tSirQos qos;
2191 tSirKeyMaterial keyMaterial;
2192} tSirSmeSetContextReq, *tpSirSmeSetContextReq;
2193
2194/// Definition for Set Context response
2195/// MAC --->
2196typedef struct sSirSmeSetContextRsp
2197{
2198 tANI_U16 messageType; // eWNI_SME_SET_CONTEXT_RSP
2199 tANI_U16 length;
2200 tANI_U8 sessionId; // Session ID
2201 tANI_U16 transactionId; // Transaction ID for cmd
2202 tSirResultCodes statusCode;
2203 tSirMacAddr peerMacAddr;
2204#if (WNI_POLARIS_FW_PRODUCT == AP)
2205 tANI_U16 aid;
2206#endif
2207} tSirSmeSetContextRsp, *tpSirSmeSetContextRsp;
2208
2209/// Definition for Remove Key Context request
2210/// ---> MAC
2211typedef struct sSirSmeRemoveKeyReq
2212{
2213 tANI_U16 messageType; // eWNI_SME_REMOVE_KEY_REQ
2214 tANI_U16 length;
2215 tANI_U8 sessionId; // Session ID
2216 tANI_U16 transactionId; // Transaction ID for cmd
2217 tSirMacAddr bssId; // BSSID
2218 tSirMacAddr peerMacAddr;
2219#if (WNI_POLARIS_FW_PRODUCT == AP)
2220 tANI_U16 aid;
2221#endif
2222 tANI_U8 edType;
2223 tANI_U8 wepType;
2224 tANI_U8 keyId;
2225 tANI_BOOLEAN unicast;
2226} tSirSmeRemoveKeyReq, *tpSirSmeRemoveKeyReq;
2227
2228/// Definition for Remove Key Context response
2229/// MAC --->
2230typedef struct sSirSmeRemoveKeyRsp
2231{
2232 tANI_U16 messageType; // eWNI_SME_REMOVE_KEY_RSP
2233 tANI_U16 length;
2234 tANI_U8 sessionId; // Session ID
2235 tANI_U16 transactionId; // Transaction ID for cmd
2236 tSirResultCodes statusCode;
2237 tSirMacAddr peerMacAddr;
2238#if (WNI_POLARIS_FW_PRODUCT == AP)
2239 tANI_U16 aid;
2240#endif
2241} tSirSmeRemoveKeyRsp, *tpSirSmeRemoveKeyRsp;
2242
2243/// Definition for Set Power request
2244/// ---> MAC
2245typedef struct sSirSmeSetPowerReq
2246{
2247 tANI_U16 messageType; // eWNI_SME_SET_POWER_REQ
2248 tANI_U16 length;
2249 tANI_U16 transactionId; // Transaction ID for cmd
2250 tANI_S8 powerLevel;
2251} tSirSmeSetPowerReq, *tpSirSmeSetPowerReq;
2252
2253/// Definition for Set Power response
2254/// MAC --->
2255typedef struct sSirSmeSetPowerRsp
2256{
2257 tANI_U16 messageType; // eWNI_SME_SET_POWER_RSP
2258 tANI_U16 length;
2259 tSirResultCodes statusCode;
2260 tANI_U16 transactionId; // Transaction ID for cmd
2261} tSirSmeSetPowerRsp, *tpSirSmeSetPowerRsp;
2262
2263#if (WNI_POLARIS_FW_PACKAGE == ADVANCED) && (WNI_POLARIS_FW_PRODUCT == AP)
2264/// Definition for Client Side Load Balancing request
2265/// ---> MAC
2266typedef struct sSirSmeSetClientLoadBalanceReq
2267{
2268 tANI_U16 messageType; // eWNI_SME_CLIENT_LOAD_BALANCE_REQ
2269 tANI_U16 length;
2270 tANI_U16 transactionId; // Transaction ID for cmd
2271 tSirMacAddr alternateBssId;
2272 tANI_U8 alternateChannelId;
2273 tANI_U8 numberStas;
2274} tSirSmeClientLoadBalanceReq, *tpSirSmeClientLoadBalanceReq;
2275
2276/// Definition for Client Side Load Balancing response
2277/// MAC --->
2278typedef struct sSirSmeSetClientLoadBalanceRsp
2279{
2280 tANI_U16 messageType; // eWNI_SME_CLIENT_LOAD_BALANCE_RSP
2281 tANI_U16 length;
2282 tANI_U16 transactionId; // Transaction ID for cmd
2283 tSirResultCodes statusCode;
2284} tSirSmeClientLoadBalanceRsp, *tpSirSmeClientLoadBalanceRsp;
2285#endif
2286
2287/// Definition for Link Test Start response
2288/// MAC --->
2289typedef struct sSirSmeLinkTestStartRsp
2290{
2291 tANI_U16 messageType; // eWNI_SME_LINK_TEST_START_RSP
2292 tANI_U16 length;
2293 tSirMacAddr peerMacAddr;
2294 tSirResultCodes statusCode;
2295#if (WNI_POLARIS_FW_PRODUCT == AP)
2296 tANI_U16 aid;
2297#endif
2298} tSirSmeLinkTestStartRsp, *tpSirSmeLinkTestStartRsp;
2299
2300/// Definition for Link Test Stop response
2301/// WSM ---> MAC
2302typedef struct sSirSmeLinkTestStopRsp
2303{
2304 tANI_U16 messageType; // eWNI_SME_LINK_TEST_STOP_RSP
2305 tANI_U16 length;
2306 tSirMacAddr peerMacAddr;
2307 tSirResultCodes statusCode;
2308#if (WNI_POLARIS_FW_PRODUCT == AP)
2309 tANI_U16 aid;
2310#endif
2311} tSirSmeLinkTestStopRsp, *tpSirSmeLinkTestStopRsp;
2312
2313/// Definition for kick starting DFS measurements
2314typedef struct sSirSmeDFSreq
2315{
2316 tANI_U16 messageType; // eWNI_SME_DFS_REQ
2317 tANI_U16 length;
2318 tANI_U16 transactionId; // Transaction ID for cmd
2319} tSirSmeDFSrequest, *tpSirSmeDFSrequest;
2320
2321/// Definition for response message to previously
2322/// issued DFS request
2323typedef struct sSirSmeDFSrsp
2324{
2325 tANI_U16 messageType; // eWNI_SME_DFS_RSP
2326 tANI_U16 length;
2327 tSirResultCodes statusCode;
2328 tANI_U16 transactionId; // Transaction ID for cmd
2329 tANI_U32 dfsReport[1];
2330} tSirSmeDFSrsp, *tpSirSmeDFSrsp;
2331
2332/// Statistic definitions
2333//=============================================================
2334// Per STA statistic structure; This same struct will be used for Aggregate
2335// STA stats as well.
2336
2337// Clear radio stats and clear per sta stats
2338typedef enum
2339{
2340 eANI_CLEAR_ALL_STATS, // Clears all stats
2341 eANI_CLEAR_RX_STATS, // Clears RX statistics of the radio interface
2342 eANI_CLEAR_TX_STATS, // Clears TX statistics of the radio interface
2343 eANI_CLEAR_RADIO_STATS, // Clears all the radio stats
2344 eANI_CLEAR_PER_STA_STATS, // Clears Per STA stats
2345 eANI_CLEAR_AGGR_PER_STA_STATS, // Clears aggregate stats
2346
2347 // Used to distinguish between per sta to security stats.
2348 // Used only by AP, FW just returns the same parameter as it received.
2349 eANI_LINK_STATS, // Get Per STA stats
2350 eANI_SECURITY_STATS, // Get Per STA security stats
2351
2352 eANI_CLEAR_STAT_TYPES_END
2353} tAniStatSubTypes;
2354
2355typedef struct sAniTxCtrs
2356{
2357 // add the rate counters here
2358 tANI_U32 tx1Mbps;
2359 tANI_U32 tx2Mbps;
2360 tANI_U32 tx5_5Mbps;
2361 tANI_U32 tx6Mbps;
2362 tANI_U32 tx9Mbps;
2363 tANI_U32 tx11Mbps;
2364 tANI_U32 tx12Mbps;
2365 tANI_U32 tx18Mbps;
2366 tANI_U32 tx24Mbps;
2367 tANI_U32 tx36Mbps;
2368 tANI_U32 tx48Mbps;
2369 tANI_U32 tx54Mbps;
2370 tANI_U32 tx72Mbps;
2371 tANI_U32 tx96Mbps;
2372 tANI_U32 tx108Mbps;
2373
2374 // tx path radio counts
2375 tANI_U32 txFragHi;
2376 tANI_U32 txFragLo;
2377 tANI_U32 txFrameHi;
2378 tANI_U32 txFrameLo;
2379 tANI_U32 txMulticastFrameHi;
2380 tANI_U32 txMulticastFrameLo;
2381 tANI_U32 txFailedHi;
2382 tANI_U32 txFailedLo;
2383 tANI_U32 multipleRetryHi;
2384 tANI_U32 multipleRetryLo;
2385 tANI_U32 singleRetryHi;
2386 tANI_U32 singleRetryLo;
2387 tANI_U32 ackFailureHi;
2388 tANI_U32 ackFailureLo;
2389 tANI_U32 xmitBeacons;
2390
2391 // titan 3c stats
2392 tANI_U32 txCbEscPktCntHi; // Total Number of Channel Bonded/Escort Packet Transmitted
2393 tANI_U32 txCbEscPktCntLo;
2394 tANI_U32 txChunksCntHi; // Total Number of Chunks Transmitted
2395 tANI_U32 txChunksCntLo;
2396 tANI_U32 txCompPktCntHi; // Total Number of Compresssed Packet Transmitted
2397 tANI_U32 txCompPktCntLo;
2398 tANI_U32 tx50PerCompPktCntHi; // Total Number of Packets with 50% or more compression
2399 tANI_U32 tx50PerCompPktCntLo;
2400 tANI_U32 txExpanPktCntHi; // Total Number of Packets Transmitted that got expanded
2401 tANI_U32 txExpanPktCntLo;
2402} tAniTxCtrs, *tpAniTxCtrs;
2403
2404typedef struct sAniRxCtrs
2405{
2406 // receive frame rate counters
2407 tANI_U32 rx1Mbps;
2408 tANI_U32 rx2Mbps;
2409 tANI_U32 rx5_5Mbps;
2410 tANI_U32 rx6Mbps;
2411 tANI_U32 rx9Mbps;
2412 tANI_U32 rx11Mbps;
2413 tANI_U32 rx12Mbps;
2414 tANI_U32 rx18Mbps;
2415 tANI_U32 rx24Mbps;
2416 tANI_U32 rx36Mbps;
2417 tANI_U32 rx48Mbps;
2418 tANI_U32 rx54Mbps;
2419 tANI_U32 rx72Mbps;
2420 tANI_U32 rx96Mbps;
2421 tANI_U32 rx108Mbps;
2422
2423 // receive size counters; 'Lte' = Less than or equal to
2424 tANI_U32 rxLte64;
2425 tANI_U32 rxLte128Gt64;
2426 tANI_U32 rxLte256Gt128;
2427 tANI_U32 rxLte512Gt256;
2428 tANI_U32 rxLte1kGt512;
2429 tANI_U32 rxLte1518Gt1k;
2430 tANI_U32 rxLte2kGt1518;
2431 tANI_U32 rxLte4kGt2k;
2432
2433 // rx radio stats
2434 tANI_U32 rxFrag;
2435 tANI_U32 rxFrame;
2436 tANI_U32 fcsError;
2437 tANI_U32 rxMulticast;
2438 tANI_U32 duplicate;
2439 tANI_U32 rtsSuccess;
2440 tANI_U32 rtsFailed;
2441 tANI_U32 wepUndecryptables;
2442 tANI_U32 drops;
2443 tANI_U32 aesFormatErrorUcastCnts;
2444 tANI_U32 aesReplaysUcast;
2445 tANI_U32 aesDecryptErrUcast;
2446
2447 // titan 3c stats
2448 tANI_U32 rxDecompPktCntHi; // Total Number of Packets that got decompressed
2449 tANI_U32 rxDecompPktCntLo;
2450 tANI_U32 rxCompPktCntHi; // Total Number of Packets received that were actually compressed
2451 tANI_U32 rxCompPktCntLo;
2452 tANI_U32 rxExpanPktCntHi; // Total Number of Packets received that got expanded
2453 tANI_U32 rxExpanPktCntLo;
2454} tAniRxCtrs, *tpAniRxCtrs;
2455
2456// Radio stats
2457typedef struct sAniRadioStats
2458{
2459 tAniTxCtrs tx;
2460 tAniRxCtrs rx;
2461} tAniRadioStats, *tpAniRadioStats;
2462
2463// Get Radio Stats request structure
2464// This structure shall be used for both Radio stats and Aggregate stats
2465// A valid request must contain entire structure with/without valid fields.
2466// Based on the request type, the valid fields will be checked.
2467typedef struct sAniGetStatsReq
2468{
2469 // Common for all types are requests
2470 tANI_U16 msgType; // message type is same as the request type
2471 tANI_U16 msgLen; // length of the entire request
2472 tANI_U8 sessionId; //Session ID
2473 tANI_U16 transactionId;
2474 tSirMacAddr bssId; //BSSID
2475 // only used for clear stats and per sta stats clear
2476 tAniStatSubTypes stat; // Clears the stats of the described types.
2477 tANI_U32 staId; // Per STA stats request must contain valid
2478 // values
2479 tANI_U8 macAddr[6];
2480} tAniGetStatsReq, *tpAniGetStatsReq;
2481
2482// Get Radio Stats response struct
2483typedef struct sAniGetRadioStatsRsp
2484{
2485 tANI_U16 type; // message type is same as the request type
2486 tANI_U16 msgLen; // length of the entire request
2487 tANI_U32 rc;
2488 tANI_U16 transactionId;
2489 tAniRadioStats radio;
2490} tAniGetRadioStatsRsp, *tpAniGetRadioStatsRsp;
2491
2492// Per Sta stats response struct
2493typedef struct sAniGetPerStaStatsRsp
2494{
2495 tANI_U16 type; // message type is same as the request type
2496 tANI_U16 msgLen; // length of the entire request
2497 tANI_U32 rc;
2498 tANI_U16 transactionId;
2499 tAniStatSubTypes stat; // Sub type needed by AP. Returns the same value
2500 tAniStaStatStruct sta;
2501 tANI_U32 staId;
2502 tANI_U8 macAddr[6];
2503} tAniGetPerStaStatsRsp, *tpAniGetPerStaStatsRsp;
2504
2505// Get Aggregate stats
2506typedef struct sAniGetAggrStaStatsRsp
2507{
2508 tANI_U16 type; // message type is same as the request type
2509 tANI_U16 msgLen; // length of the entire request
2510 tANI_U32 rc;
2511 tANI_U16 transactionId;
2512 tAniStaStatStruct sta;
2513} tAniGetAggrStaStatsRsp, *tpAniGetAggrStaStatsRsp;
2514
2515// Clear stats request and response structure. 'rc' field is unused in
2516// request and this field is used in response field.
2517typedef struct sAniClearStatsRsp
2518{
2519 tANI_U16 type; // message type is same as the request type
2520 tANI_U16 msgLen; // length of the entire request
2521 tANI_U32 rc; // return code - will be filled by FW on
2522 // response.
2523 // Same transaction ID will be returned by the FW
2524 tANI_U16 transactionId;
2525 tAniStatSubTypes stat; // Clears the stats of the described types.
2526 tANI_U32 staId; // Applicable only to PER STA stats clearing
2527 tANI_U8 macAddr[6]; // Applicable only to PER STA stats clearing
2528} tAniClearStatsRsp, *tpAniClearStatsRsp;
2529
2530typedef struct sAniGetGlobalStatsRsp
2531{
2532 tANI_U16 type; // message type is same as the request type
2533 tANI_U16 msgLen; // length of the entire request
2534 tANI_U32 rc;
2535 tANI_U16 transactionId;
2536 tAniGlobalStatStruct global;
2537} tAniGetGlobalStatsRsp, *tpAniGetGlobalStatsRsp;
2538
2539typedef struct sAniGetStatSummaryRsp
2540{
2541 tANI_U16 type; // message type is same as the request type
2542 tANI_U16 msgLen; // length of the entire request --Why?
2543 tANI_U32 rc;
2544 tANI_U16 transactionId;
2545 tAniStatSummaryStruct stat;
2546} tAniGetStatSummaryRsp, *tpAniGetStatSummaryRsp;
2547
2548//***************************************************************
2549
2550
2551/*******************PE Statistics*************************/
2552typedef enum
2553{
2554 PE_SUMMARY_STATS_INFO = 0x00000001,
2555 PE_GLOBAL_CLASS_A_STATS_INFO = 0x00000002,
2556 PE_GLOBAL_CLASS_B_STATS_INFO = 0x00000004,
2557 PE_GLOBAL_CLASS_C_STATS_INFO = 0x00000008,
2558 PE_GLOBAL_CLASS_D_STATS_INFO = 0x00000010,
2559 PE_PER_STA_STATS_INFO = 0x00000020
2560}ePEStatsMask;
2561
2562/*
2563 * tpAniGetPEStatsReq is tied to
2564 * for SME ==> PE eWNI_SME_GET_STATISTICS_REQ msgId and
2565 * for PE ==> HAL SIR_HAL_GET_STATISTICS_REQ msgId
2566 */
2567typedef struct sAniGetPEStatsReq
2568{
2569 // Common for all types are requests
2570 tANI_U16 msgType; // message type is same as the request type
2571 tANI_U16 msgLen; // length of the entire request
2572 tANI_U32 staId; // Per STA stats request must contain valid
2573 tANI_U32 statsMask; // categories of stats requested. look at ePEStatsMask
2574} tAniGetPEStatsReq, *tpAniGetPEStatsReq;
2575
2576/*
2577 * tpAniGetPEStatsRsp is tied to
2578 * for PE ==> SME eWNI_SME_GET_STATISTICS_RSP msgId and
2579 * for HAL ==> PE SIR_HAL_GET_STATISTICS_RSP msgId
2580 */
2581typedef struct sAniGetPEStatsRsp
2582{
2583 // Common for all types are responses
2584 tANI_U16 msgType; // message type is same as the request type
2585 tANI_U16 msgLen; // length of the entire request, includes the pStatsBuf length too
2586 tANI_U8 sessionId;
2587 tANI_U32 rc; //success/failure
2588 tANI_U32 staId; // Per STA stats request must contain valid
2589 tANI_U32 statsMask; // categories of stats requested. look at ePEStatsMask
2590/**********************************************************************************************
2591 //void *pStatsBuf;
2592 The Stats buffer starts here and can be an aggregate of more than one statistics
2593 structure depending on statsMask.The void pointer "pStatsBuf" is commented out
2594 intentionally and the src code that uses this structure should take that into account.
2595**********************************************************************************************/
2596} tAniGetPEStatsRsp, *tpAniGetPEStatsRsp;
2597
2598typedef struct sAniGetRssiReq
2599{
2600 // Common for all types are requests
2601 tANI_U16 msgType; // message type is same as the request type
2602 tANI_U16 msgLen; // length of the entire request
2603 tANI_U8 sessionId;
2604 tANI_U8 staId;
2605 void *rssiCallback;
2606 void *pDevContext; //device context
2607 void *pVosContext; //voss context
2608
2609} tAniGetRssiReq, *tpAniGetRssiReq;
2610
2611/* Change country code request MSG structure */
2612typedef struct sAniChangeCountryCodeReq
2613{
2614 // Common for all types are requests
2615 tANI_U16 msgType; // message type is same as the request type
2616 tANI_U16 msgLen; // length of the entire request
2617 tANI_U8 countryCode[WNI_CFG_COUNTRY_CODE_LEN]; //3 char country code
2618 void *changeCCCallback;
2619 void *pDevContext; //device context
2620 void *pVosContext; //voss context
2621
2622} tAniChangeCountryCodeReq, *tpAniChangeCountryCodeReq;
2623
2624typedef struct sAniSummaryStatsInfo
2625{
2626 tANI_U32 retry_cnt[4]; //Total number of packets(per AC) that were successfully transmitted with retries
2627 tANI_U32 multiple_retry_cnt[4];//The number of MSDU packets and MMPDU frames per AC that the 802.11
2628 // station successfully transmitted after more than one retransmission attempt
2629
2630 tANI_U32 tx_frm_cnt[4]; //Total number of packets(per AC) that were successfully transmitted
2631 //(with and without retries, including multi-cast, broadcast)
2632 //tANI_U32 tx_fail_cnt;
2633 //tANI_U32 num_rx_frm_crc_err; //Total number of received frames with CRC Error
2634 //tANI_U32 num_rx_frm_crc_ok; //Total number of successfully received frames with out CRC Error
2635 tANI_U32 rx_frm_cnt; //Total number of packets that were successfully received
2636 //(after appropriate filter rules including multi-cast, broadcast)
2637 tANI_U32 frm_dup_cnt; //Total number of duplicate frames received successfully
2638 tANI_U32 fail_cnt[4]; //Total number packets(per AC) failed to transmit
2639 tANI_U32 rts_fail_cnt; //Total number of RTS/CTS sequence failures for transmission of a packet
2640 tANI_U32 ack_fail_cnt; //Total number packets failed transmit because of no ACK from the remote entity
2641 tANI_U32 rts_succ_cnt; //Total number of RTS/CTS sequence success for transmission of a packet
2642 tANI_U32 rx_discard_cnt; //The sum of the receive error count and dropped-receive-buffer error count.
2643 //HAL will provide this as a sum of (FCS error) + (Fail get BD/PDU in HW)
2644 tANI_U32 rx_error_cnt; //The receive error count. HAL will provide the RxP FCS error global counter.
2645 tANI_U32 tx_byte_cnt; //The sum of the transmit-directed byte count, transmit-multicast byte count
2646 //and transmit-broadcast byte count. HAL will sum TPE UC/MC/BCAST global counters
2647 //to provide this.
2648#if 0
2649 //providing the following stats, in case of wrap around for tx_byte_cnt
2650 tANI_U32 tx_unicast_lower_byte_cnt;
2651 tANI_U32 tx_unicast_upper_byte_cnt;
2652 tANI_U32 tx_multicast_lower_byte_cnt;
2653 tANI_U32 tx_multicast_upper_byte_cnt;
2654 tANI_U32 tx_broadcast_lower_byte_cnt;
2655 tANI_U32 tx_broadcast_upper_byte_cnt;
2656#endif
2657
2658}tAniSummaryStatsInfo, *tpAniSummaryStatsInfo;
2659
2660typedef enum eTxRateInfo
2661{
2662 eHAL_TX_RATE_LEGACY = 0x1, /* Legacy rates */
2663 eHAL_TX_RATE_HT20 = 0x2, /* HT20 rates */
2664 eHAL_TX_RATE_HT40 = 0x4, /* HT40 rates */
2665 eHAL_TX_RATE_SGI = 0x8, /* Rate with Short guard interval */
2666 eHAL_TX_RATE_LGI = 0x10 /* Rate with Long guard interval */
2667} tTxrateinfoflags;
2668
2669typedef struct sAniGlobalClassAStatsInfo
2670{
2671 tANI_U32 rx_frag_cnt; //The number of MPDU frames received by the 802.11 station for MSDU packets
2672 //or MMPDU frames
2673 tANI_U32 promiscuous_rx_frag_cnt; //The number of MPDU frames received by the 802.11 station for MSDU packets
2674 //or MMPDU frames when a promiscuous packet filter was enabled
2675 //tANI_U32 rx_fcs_err; //The number of MPDU frames that the 802.11 station received with FCS errors
2676 tANI_U32 rx_input_sensitivity; //The receiver input sensitivity referenced to a FER of 8% at an MPDU length
2677 //of 1024 bytes at the antenna connector. Each element of the array shall correspond
2678 //to a supported rate and the order shall be the same as the supporteRates parameter.
2679 tANI_U32 max_pwr; //The maximum transmit power in dBm upto one decimal.
2680 //for eg: if it is 10.5dBm, the value would be 105
2681 //tANI_U32 default_pwr; //The nominal transmit level used after normal power on sequence
2682 tANI_U32 sync_fail_cnt; //Number of times the receiver failed to synchronize with the incoming signal
2683 //after detecting the sync in the preamble of the transmitted PLCP protocol data unit.
2684 tANI_U32 tx_rate; //Legacy transmit rate, in units of
2685 //500 kbit/sec, for the most
2686 //recently transmitted frame
2687 tANI_U32 mcs_index; //mcs index for HT20 and HT40 rates
2688 tANI_U32 tx_rate_flags; //to differentiate between HT20 and
2689 //HT40 rates; short and long guard interval
2690
2691}tAniGlobalClassAStatsInfo, *tpAniGlobalClassAStatsInfo;
2692
2693
2694typedef struct sAniGlobalSecurityStats
2695{
2696 tANI_U32 rx_wep_unencrypted_frm_cnt; //The number of unencrypted received MPDU frames that the MAC layer discarded when
2697 //the IEEE 802.11 dot11ExcludeUnencrypted management information base (MIB) object
2698 //is enabled
2699 tANI_U32 rx_mic_fail_cnt; //The number of received MSDU packets that that the 802.11 station discarded
2700 //because of MIC failures
2701 tANI_U32 tkip_icv_err; //The number of encrypted MPDU frames that the 802.11 station failed to decrypt
2702 //because of a TKIP ICV error
2703 tANI_U32 aes_ccmp_format_err; //The number of received MPDU frames that the 802.11 discarded because of an
2704 //invalid AES-CCMP format
2705 tANI_U32 aes_ccmp_replay_cnt; //The number of received MPDU frames that the 802.11 station discarded because of
2706 //the AES-CCMP replay protection procedure
2707 tANI_U32 aes_ccmp_decrpt_err; //The number of received MPDU frames that the 802.11 station discarded because of
2708 //errors detected by the AES-CCMP decryption algorithm
2709 tANI_U32 wep_undecryptable_cnt; //The number of encrypted MPDU frames received for which a WEP decryption key was
2710 //not available on the 802.11 station
2711 tANI_U32 wep_icv_err; //The number of encrypted MPDU frames that the 802.11 station failed to decrypt
2712 //because of a WEP ICV error
2713 tANI_U32 rx_decrypt_succ_cnt; //The number of received encrypted packets that the 802.11 station successfully
2714 //decrypted
2715 tANI_U32 rx_decrypt_fail_cnt; //The number of encrypted packets that the 802.11 station failed to decrypt
2716
2717}tAniGlobalSecurityStats, *tpAniGlobalSecurityStats;
2718
2719typedef struct sAniGlobalClassBStatsInfo
2720{
2721 tAniGlobalSecurityStats ucStats;
2722 tAniGlobalSecurityStats mcbcStats;
2723}tAniGlobalClassBStatsInfo, *tpAniGlobalClassBStatsInfo;
2724
2725typedef struct sAniGlobalClassCStatsInfo
2726{
2727 tANI_U32 rx_amsdu_cnt; //This counter shall be incremented for a received A-MSDU frame with the stations
2728 //MAC address in the address 1 field or an A-MSDU frame with a group address in the
2729 //address 1 field
2730 tANI_U32 rx_ampdu_cnt; //This counter shall be incremented when the MAC receives an AMPDU from the PHY
2731 tANI_U32 tx_20_frm_cnt; //This counter shall be incremented when a Frame is transmitted only on the
2732 //primary channel
2733 tANI_U32 rx_20_frm_cnt; //This counter shall be incremented when a Frame is received only on the primary channel
2734 tANI_U32 rx_mpdu_in_ampdu_cnt; //This counter shall be incremented by the number of MPDUs received in the A-MPDU
2735 //when an A-MPDU is received
2736 tANI_U32 ampdu_delimiter_crc_err;//This counter shall be incremented when an MPDU delimiter has a CRC error when this
2737 //is the first CRC error in the received AMPDU or when the previous delimiter has been
2738 //decoded correctly
2739
2740}tAniGlobalClassCStatsInfo, *tpAniGlobalClassCStatsInfo;
2741
2742typedef struct sAniPerStaStatsInfo
2743{
2744 tANI_U32 tx_frag_cnt[4]; //The number of MPDU frames that the 802.11 station transmitted and acknowledged
2745 //through a received 802.11 ACK frame
2746 tANI_U32 tx_ampdu_cnt; //This counter shall be incremented when an A-MPDU is transmitted
2747 tANI_U32 tx_mpdu_in_ampdu_cnt; //This counter shall increment by the number of MPDUs in the AMPDU when an A-MPDU
2748 //is transmitted
2749
2750}tAniPerStaStatsInfo, *tpAniPerStaStatsInfo;
2751
2752/**********************PE Statistics end*************************/
2753
2754
2755
2756typedef struct sSirRSSIThresholds
2757{
2758#ifdef ANI_BIG_BYTE_ENDIAN
2759 tANI_S8 ucRssiThreshold1 : 8;
2760 tANI_S8 ucRssiThreshold2 : 8;
2761 tANI_S8 ucRssiThreshold3 : 8;
2762 tANI_U8 bRssiThres1PosNotify : 1;
2763 tANI_U8 bRssiThres1NegNotify : 1;
2764 tANI_U8 bRssiThres2PosNotify : 1;
2765 tANI_U8 bRssiThres2NegNotify : 1;
2766 tANI_U8 bRssiThres3PosNotify : 1;
2767 tANI_U8 bRssiThres3NegNotify : 1;
2768 tANI_U8 bReserved10 : 2;
2769#else
2770 tANI_U8 bReserved10 : 2;
2771 tANI_U8 bRssiThres3NegNotify : 1;
2772 tANI_U8 bRssiThres3PosNotify : 1;
2773 tANI_U8 bRssiThres2NegNotify : 1;
2774 tANI_U8 bRssiThres2PosNotify : 1;
2775 tANI_U8 bRssiThres1NegNotify : 1;
2776 tANI_U8 bRssiThres1PosNotify : 1;
2777 tANI_S8 ucRssiThreshold3 : 8;
2778 tANI_S8 ucRssiThreshold2 : 8;
2779 tANI_S8 ucRssiThreshold1 : 8;
2780#endif
2781
2782}tSirRSSIThresholds, *tpSirRSSIThresholds;
2783
2784typedef struct sSirRSSINotification
2785{
2786#ifdef ANI_BIG_BYTE_ENDIAN
2787 tANI_U32 bRssiThres1PosCross : 1;
2788 tANI_U32 bRssiThres1NegCross : 1;
2789 tANI_U32 bRssiThres2PosCross : 1;
2790 tANI_U32 bRssiThres2NegCross : 1;
2791 tANI_U32 bRssiThres3PosCross : 1;
2792 tANI_U32 bRssiThres3NegCross : 1;
2793 tANI_U32 bReserved : 26;
2794#else
2795 tANI_U32 bReserved : 26;
2796 tANI_U32 bRssiThres3NegCross : 1;
2797 tANI_U32 bRssiThres3PosCross : 1;
2798 tANI_U32 bRssiThres2NegCross : 1;
2799 tANI_U32 bRssiThres2PosCross : 1;
2800 tANI_U32 bRssiThres1NegCross : 1;
2801 tANI_U32 bRssiThres1PosCross : 1;
2802#endif
2803
2804}tSirRSSINotification, *tpSirRSSINotification;
2805
2806#ifdef WLAN_FEATURE_P2P
2807typedef struct sSirP2PNoaAttr
2808{
2809#ifdef ANI_BIG_BYTE_ENDIAN
2810 tANI_U32 index :8;
2811 tANI_U32 oppPsFlag :1;
2812 tANI_U32 ctWin :7;
2813 tANI_U32 rsvd1: 16;
2814#else
2815 tANI_U32 rsvd1: 16;
2816 tANI_U32 ctWin :7;
2817 tANI_U32 oppPsFlag :1;
2818 tANI_U32 index :8;
2819#endif
2820
2821#ifdef ANI_BIG_BYTE_ENDIAN
2822 tANI_U32 uNoa1IntervalCnt:8;
2823 tANI_U32 rsvd2:24;
2824#else
2825 tANI_U32 rsvd2:24;
2826 tANI_U32 uNoa1IntervalCnt:8;
2827#endif
2828 tANI_U32 uNoa1Duration;
2829 tANI_U32 uNoa1Interval;
2830 tANI_U32 uNoa1StartTime;
2831
2832#ifdef ANI_BIG_BYTE_ENDIAN
2833 tANI_U32 uNoa2IntervalCnt:8;
2834 tANI_U32 rsvd3:24;
2835#else
2836 tANI_U32 rsvd3:24;
2837 tANI_U32 uNoa2IntervalCnt:8;
2838#endif
2839 tANI_U32 uNoa2Duration;
2840 tANI_U32 uNoa2Interval;
2841 tANI_U32 uNoa2StartTime;
2842} tSirP2PNoaAttr, *tpSirP2PNoaAttr;
2843#endif
2844
2845typedef __ani_attr_pre_packed struct sSirTclasInfo
2846{
2847 tSirMacTclasIE tclas;
2848 tANI_U8 version; // applies only for classifier type ip
2849 __ani_attr_pre_packed union {
2850 tSirMacTclasParamEthernet eth;
2851 tSirMacTclasParamIPv4 ipv4;
2852 tSirMacTclasParamIPv6 ipv6;
2853 tSirMacTclasParam8021dq t8021dq;
2854 }__ani_attr_packed tclasParams;
2855} __ani_attr_packed tSirTclasInfo;
2856
2857typedef struct sSirAddtsReqInfo
2858{
2859 tANI_U8 dialogToken;
2860 tSirMacTspecIE tspec;
2861
2862 tANI_U8 numTclas; // number of Tclas elements
2863 tSirTclasInfo tclasInfo[SIR_MAC_TCLASIE_MAXNUM];
2864 tANI_U8 tclasProc;
2865#ifdef FEATURE_WLAN_CCX
2866 tSirMacCCXTSRSIE tsrsIE;
2867 tANI_U8 tsrsPresent:1;
2868#endif
2869 tANI_U8 wmeTspecPresent:1;
2870 tANI_U8 wsmTspecPresent:1;
2871 tANI_U8 lleTspecPresent:1;
2872 tANI_U8 tclasProcPresent:1;
2873} tSirAddtsReqInfo, *tpSirAddtsReqInfo;
2874
2875typedef struct sSirAddtsRspInfo
2876{
2877 tANI_U8 dialogToken;
2878 tSirMacStatusCodes status;
2879 tSirMacTsDelayIE delay;
2880
2881 tSirMacTspecIE tspec;
2882 tANI_U8 numTclas; // number of Tclas elements
2883 tSirTclasInfo tclasInfo[SIR_MAC_TCLASIE_MAXNUM];
2884 tANI_U8 tclasProc;
2885 tSirMacScheduleIE schedule;
2886#ifdef FEATURE_WLAN_CCX
2887 tSirMacCCXTSMIE tsmIE;
2888 tANI_U8 tsmPresent:1;
2889#endif
2890 tANI_U8 wmeTspecPresent:1;
2891 tANI_U8 wsmTspecPresent:1;
2892 tANI_U8 lleTspecPresent:1;
2893 tANI_U8 tclasProcPresent:1;
2894 tANI_U8 schedulePresent:1;
2895} tSirAddtsRspInfo, *tpSirAddtsRspInfo;
2896
2897typedef struct sSirDeltsReqInfo
2898{
2899 tSirMacTSInfo tsinfo;
2900 tSirMacTspecIE tspec;
2901 tANI_U8 wmeTspecPresent:1;
2902 tANI_U8 wsmTspecPresent:1;
2903 tANI_U8 lleTspecPresent:1;
2904} tSirDeltsReqInfo, *tpSirDeltsReqInfo;
2905
2906/// Add a tspec as defined
2907typedef struct sSirAddtsReq
2908{
2909 tANI_U16 messageType; // eWNI_SME_ADDTS_REQ
2910 tANI_U16 length;
2911 tANI_U8 sessionId; //Session ID
2912 tANI_U16 transactionId;
2913 tSirMacAddr bssId; //BSSID
2914 tANI_U32 timeout; // in ms
2915 tANI_U8 rspReqd;
2916 tSirAddtsReqInfo req;
2917} tSirAddtsReq, *tpSirAddtsReq;
2918
2919typedef struct sSirAddtsRsp
2920{
2921 tANI_U16 messageType; // eWNI_SME_ADDTS_RSP
2922 tANI_U16 length;
2923 tANI_U8 sessionId; // sme sessionId Added for BT-AMP support
2924 tANI_U16 transactionId; //sme transaction Id Added for BT-AMP Support
2925 tANI_U32 rc; // return code
2926 tSirAddtsRspInfo rsp;
2927} tSirAddtsRsp, *tpSirAddtsRsp;
2928
2929typedef struct sSirDeltsReq
2930{
2931 tANI_U16 messageType; // eWNI_SME_DELTS_REQ
2932 tANI_U16 length;
2933 tANI_U8 sessionId;//Session ID
2934 tANI_U16 transactionId;
2935 tSirMacAddr bssId; //BSSID
2936 tANI_U16 aid; // use 0 if macAddr is being specified
2937 tANI_U8 macAddr[6]; // only on AP to specify the STA
2938 tANI_U8 rspReqd;
2939 tSirDeltsReqInfo req;
2940} tSirDeltsReq, *tpSirDeltsReq;
2941
2942typedef struct sSirDeltsRsp
2943{
2944 tANI_U16 messageType; // eWNI_SME_DELTS_RSP
2945 tANI_U16 length;
2946 tANI_U8 sessionId; // sme sessionId Added for BT-AMP support
2947 tANI_U16 transactionId; //sme transaction Id Added for BT-AMP Support
2948 tANI_U32 rc;
2949 tANI_U16 aid; // use 0 if macAddr is being specified
2950 tANI_U8 macAddr[6]; // only on AP to specify the STA
2951 tSirDeltsReqInfo rsp;
2952} tSirDeltsRsp, *tpSirDeltsRsp;
2953
Jeff Johnson04dd8a82012-06-29 20:41:40 -07002954#if defined WLAN_FEATURE_VOWIFI_11R || defined FEATURE_WLAN_CCX || defined(FEATURE_WLAN_LFR)
Jeff Johnson295189b2012-06-20 16:38:30 -07002955
2956#define SIR_QOS_NUM_TSPEC_MAX 2
2957#define SIR_QOS_NUM_AC_MAX 4
2958
2959typedef struct sSirAggrQosReqInfo
2960{
2961 tANI_U16 tspecIdx;
2962 tSirAddtsReqInfo aggrAddTsInfo[SIR_QOS_NUM_AC_MAX];
2963}tSirAggrQosReqInfo, *tpSirAggrQosReqInfo;
2964
2965typedef struct sSirAggrQosReq
2966{
2967 tANI_U16 messageType; // eWNI_SME_ADDTS_REQ
2968 tANI_U16 length;
2969 tANI_U8 sessionId; //Session ID
2970 tANI_U16 transactionId;
2971 tSirMacAddr bssId; //BSSID
2972 tANI_U32 timeout; // in ms
2973 tANI_U8 rspReqd;
2974 tSirAggrQosReqInfo aggrInfo;
2975}tSirAggrQosReq, *tpSirAggrQosReq;
2976
2977typedef struct sSirAggrQosRspInfo
2978{
2979 tANI_U16 tspecIdx;
2980 tSirAddtsRspInfo aggrRsp[SIR_QOS_NUM_AC_MAX];
2981} tSirAggrQosRspInfo, *tpSirAggrQosRspInfo;
2982
2983typedef struct sSirAggrQosRsp
2984{
2985 tANI_U16 messageType;
2986 tANI_U16 length;
2987 tANI_U8 sessionId;
2988 tSirAggrQosRspInfo aggrInfo;
2989} tSirAggrQosRsp, *tpSirAggrQosRsp;
2990
2991#endif/*WLAN_FEATURE_VOWIFI_11R || FEATURE_WLAN_CCX*/
2992
2993typedef struct sSirSetTxPowerReq
2994{
2995 tANI_U16 messageType;
2996 tANI_U16 length;
2997 tANI_U32 txPower;
2998} tSirSetTxPowerReq, *tpSirSetTxPowerReq;
2999
3000typedef struct sSirSetTxPowerRsp
3001{
3002 tANI_U16 messageType;
3003 tANI_U16 length;
3004 tANI_U32 status;
3005} tSirSetTxPowerRsp, *tpSirSetTxPowerRsp;
3006
3007typedef struct sSirGetTxPowerReq
3008{
3009 tANI_U16 messageType;
3010 tANI_U16 length;
3011 tANI_U16 staid;
3012} tSirGetTxPowerReq, *tpSirGetTxPowerReq;
3013
3014typedef struct sSirGetTxPowerRsp
3015{
3016 tANI_U16 messageType;
3017 tANI_U16 length; // length of the entire request
3018 tANI_U32 power; // units of milliwatts
3019 tANI_U32 status;
3020} tSirGetTxPowerRsp, *tpSirGetTxPowerRsp;
3021
3022
3023typedef tANI_U32 tSirMacNoise[3];
3024
3025typedef struct sSirGetNoiseRsp
3026{
3027 tANI_U16 messageType;
3028 tANI_U16 length;
3029 tSirMacNoise noise;
3030} tSirGetNoiseRsp, *tpSirGetNoiseRsp;
3031
3032
3033//
3034// PMC --> PE --> HAL
3035// Power save configuration parameters
3036//
3037typedef struct sSirPowerSaveCfg
3038{
3039 tANI_U16 listenInterval;
3040
3041 /* Number of consecutive missed beacons before
3042 * hardware generates an interrupt to wake up
3043 * the host. In units of listen interval.
3044 */
3045 tANI_U32 HeartBeatCount;
3046
3047 /* specifies which beacons are to be forwarded
3048 * to host when beacon filtering is enabled.
3049 * In units of listen interval.
3050 */
3051 tANI_U32 nthBeaconFilter;
3052
3053 /* Maximum number of PS-Poll send before
3054 * firmware sends data null with PM set to 0.
3055 */
3056 tANI_U32 maxPsPoll;
3057
3058 /* If the average RSSI value falls below the
3059 * minRssiThreshold, then FW will send an
3060 * interrupt to wake up the host.
3061 */
3062 tANI_U32 minRssiThreshold;
3063
3064 /* Number of beacons for which firmware will
3065 * collect the RSSI values and compute the average.
3066 */
3067 tANI_U8 numBeaconPerRssiAverage;
3068
3069 /* FW collects the RSSI stats for this period
3070 * in BMPS mode.
3071 */
3072 tANI_U8 rssiFilterPeriod;
3073
3074 // Enabling/disabling broadcast frame filter feature
3075 tANI_U8 broadcastFrameFilter;
3076
3077 // Enabling/disabling the ignore DTIM feature
3078 tANI_U8 ignoreDtim;
3079
3080 /* The following configuration parameters are kept
3081 * in order to be backward compatible for Gen5.
3082 * These will NOT be used for Gen6 Libra chip
3083 */
3084 tBeaconForwarding beaconFwd;
3085 tANI_U16 nthBeaconFwd;
3086 tANI_U8 fEnablePwrSaveImmediately;
3087 tANI_U8 fPSPoll;
3088
3089 // Enabling/disabling Beacon Early Termination feature
3090 tANI_U8 fEnableBeaconEarlyTermination;
3091 tANI_U8 bcnEarlyTermWakeInterval;
3092
3093}tSirPowerSaveCfg, *tpSirPowerSaveCfg;
3094
3095/* Reason code for requesting Full Power. This reason code is used by
3096 any module requesting full power from PMC and also by PE when it
3097 sends the eWNI_PMC_EXIT_BMPS_IND to PMC*/
3098typedef enum eRequestFullPowerReason
3099{
3100 eSME_MISSED_BEACON_IND_RCVD, /* PE received a MAX_MISSED_BEACON_IND */
3101 eSME_BMPS_STATUS_IND_RCVD, /* PE received a SIR_HAL_BMPS_STATUS_IND */
3102 eSME_BMPS_MODE_DISABLED, /* BMPS mode was disabled by HDD in SME */
3103 eSME_LINK_DISCONNECTED_BY_HDD, /* Link has been disconnected requested by HDD */
3104 eSME_LINK_DISCONNECTED_BY_OTHER,/* Disconnect due to linklost or requested by peer */
3105 eSME_FULL_PWR_NEEDED_BY_HDD, /* HDD request full power for some reason */
3106 eSME_FULL_PWR_NEEDED_BY_BAP, /* BAP request full power for BT_AMP */
3107 eSME_FULL_PWR_NEEDED_BY_CSR, /* CSR requests full power */
3108 eSME_FULL_PWR_NEEDED_BY_QOS, /* QOS requests full power */
3109 eSME_FULL_PWR_NEEDED_BY_CHANNEL_SWITCH, /* channel switch request full power*/
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003110#ifdef FEATURE_WLAN_TDLS
3111 eSME_FULL_PWR_NEEDED_BY_TDLS_PEER_SETUP, /* TDLS peer setup*/
3112#endif
Jeff Johnson295189b2012-06-20 16:38:30 -07003113 eSME_REASON_OTHER /* No specific reason. General reason code */
3114} tRequestFullPowerReason, tExitBmpsReason;
3115
3116
3117
3118//This is sent alongwith eWNI_PMC_EXIT_BMPS_REQ message
3119typedef struct sExitBmpsInfo
3120{
3121 tExitBmpsReason exitBmpsReason; /*Reason for exiting BMPS */
3122}tExitBmpsInfo, *tpExitBmpsInfo;
3123
3124
3125// MAC SW --> SME
3126// Message indicating to SME to exit BMPS sleep mode
3127typedef struct sSirSmeExitBmpsInd
3128{
3129 tANI_U16 mesgType; /* eWNI_PMC_EXIT_BMPS_IND */
3130 tANI_U16 mesgLen;
3131 tSirResultCodes statusCode;
3132 tExitBmpsReason exitBmpsReason; /*Reason for exiting BMPS */
3133
3134} tSirSmeExitBmpsInd, *tpSirSmeExitBmpsInd;
3135
3136
3137//
3138// HDD -> LIM
3139// tSirMsgQ.type = eWNI_SME_DEL_BA_PEER_IND
3140// tSirMsgQ.reserved = 0
3141// tSirMsgQ.body = instance of tDelBAParams
3142//
3143typedef struct sSmeDelBAPeerInd
3144{
3145 // Message Type
3146 tANI_U16 mesgType;
3147
3148 tSirMacAddr bssId;//BSSID
3149
3150 // Message Length
3151 tANI_U16 mesgLen;
3152
3153 // Station Index
3154 tANI_U16 staIdx;
3155
3156 // TID for which the BA session is being deleted
3157 tANI_U8 baTID;
3158
3159 // DELBA direction
3160 // eBA_INITIATOR - Originator
3161 // eBA_RECEIPIENT - Recipient
3162 tANI_U8 baDirection;
3163} tSmeDelBAPeerInd, *tpSmeDelBAPeerInd;
3164
3165typedef struct sSmeIbssPeerInd
3166{
3167 tANI_U16 mesgType;
3168 tANI_U16 mesgLen;
3169 tANI_U8 sessionId;
3170
3171 tSirMacAddr peerAddr;
3172 tANI_U16 staId;
3173
3174 /*The DPU signatures will be sent eventually to TL to help it determine the
3175 association to which a packet belongs to*/
3176 /*Unicast DPU signature*/
3177 tANI_U8 ucastSig;
3178
3179 /*Broadcast DPU signature*/
3180 tANI_U8 bcastSig;
3181
3182 //Beacon will be appended for new Peer indication.
3183}tSmeIbssPeerInd, *tpSmeIbssPeerInd;
3184
3185typedef struct sLimScanChn
3186{
3187 tANI_U16 numTimeScan; //how many time this channel is scan
3188 tANI_U8 channelId;
3189}tLimScanChn;
3190
3191typedef struct sSmeGetScanChnRsp
3192{
3193 // Message Type
3194 tANI_U16 mesgType;
3195 // Message Length
3196 tANI_U16 mesgLen;
3197 tANI_U8 sessionId;
3198 tANI_U8 numChn;
3199 tLimScanChn scanChn[1];
3200} tSmeGetScanChnRsp, *tpSmeGetScanChnRsp;
3201
3202typedef struct sLimScanChnInfo
3203{
3204 tANI_U8 numChnInfo; //number of channels in scanChn
3205 tLimScanChn scanChn[SIR_MAX_SUPPORTED_CHANNEL_LIST];
3206}tLimScanChnInfo;
3207
3208#ifdef WLAN_SOFTAP_FEATURE
3209typedef struct sSirSmeGetAssocSTAsReq
3210{
3211 tANI_U16 messageType; // eWNI_SME_GET_ASSOC_STAS_REQ
3212 tANI_U16 length;
3213 tSirMacAddr bssId; // BSSID
3214 tANI_U16 modId;
3215 void *pUsrContext;
3216 void *pSapEventCallback;
3217 void *pAssocStasArray;// Pointer to allocated memory passed in WLANSAP_GetAssocStations API
3218} tSirSmeGetAssocSTAsReq, *tpSirSmeGetAssocSTAsReq;
3219#endif
3220
3221typedef struct sSmeMaxAssocInd
3222{
3223 tANI_U16 mesgType; // eWNI_SME_MAX_ASSOC_EXCEEDED
3224 tANI_U16 mesgLen;
3225 tANI_U8 sessionId;
3226 tSirMacAddr peerMac; // the new peer that got rejected due to softap max assoc limit reached
3227} tSmeMaxAssocInd, *tpSmeMaxAssocInd;
3228
3229/*--------------------------------------------------------------------*/
3230/* BootLoader message definition */
3231/*--------------------------------------------------------------------*/
3232
3233/*--------------------------------------------------------------------*/
3234/* FW image size */
3235/*--------------------------------------------------------------------*/
3236#define SIR_FW_IMAGE_SIZE 146332
3237
3238
3239#define SIR_BOOT_MODULE_ID 1
3240
3241#define SIR_BOOT_SETUP_IND ((SIR_BOOT_MODULE_ID << 8) | 0x11)
3242#define SIR_BOOT_POST_RESULT_IND ((SIR_BOOT_MODULE_ID << 8) | 0x12)
3243#define SIR_BOOT_DNLD_RESULT_IND ((SIR_BOOT_MODULE_ID << 8) | 0x13)
3244#define SIR_BOOT_DNLD_DEV_REQ ((SIR_BOOT_MODULE_ID << 8) | 0x41)
3245#define SIR_BOOT_DNLD_DEV_RSP ((SIR_BOOT_MODULE_ID << 8) | 0x81)
3246#define SIR_BOOT_DNLD_REQ ((SIR_BOOT_MODULE_ID << 8) | 0x42)
3247#define SIR_BOOT_DNLD_RSP ((SIR_BOOT_MODULE_ID << 8) | 0x82)
3248
3249/*--------------------------------------------------------------------*/
3250/* Bootloader message syntax */
3251/*--------------------------------------------------------------------*/
3252
3253// Message header
3254#define SIR_BOOT_MB_HEADER 0
3255#define SIR_BOOT_MB_HEADER2 1
3256
3257#define SIR_BOOT_MSG_HDR_MASK 0xffff0000
3258#define SIR_BOOT_MSG_LEN_MASK 0x0000ffff
3259
3260// BOOT_SETUP_IND parameter indices
3261#define SIR_BOOT_SETUP_IND_MBADDR 2
3262#define SIR_BOOT_SETUP_IND_MBSIZE 3
3263#define SIR_BOOT_SETUP_IND_MEMOPT 4
3264#define SIR_BOOT_SETUP_IND_LEN \
3265 ((SIR_BOOT_SETUP_IND_MEMOPT+1)<<2)
3266
3267// BOOT_POST_RESULT_IND parameter indices
3268#define SIR_BOOT_POST_RESULT_IND_RES 2
3269#define SIR_BOOT_POST_RESULT_IND_LEN \
3270 ((SIR_BOOT_POST_RESULT_IND_RES+1)<<2)
3271
3272#define SIR_BOOT_POST_RESULT_IND_SUCCESS 1
3273#define SIR_BOOT_POST_RESULT_IND_MB_FAILED 2
3274#define SIR_BOOT_POST_RESULT_IND_SDRAM_FAILED 3
3275#define SIR_BOOT_POST_RESULT_IND_ESRAM_FAILED 4
3276
3277
3278// BOOT_DNLD_RESULT_IND parameter indices
3279#define SIR_BOOT_DNLD_RESULT_IND_RES 2
3280#define SIR_BOOT_DNLD_RESULT_IND_LEN \
3281 ((SIR_BOOT_DNLD_RESULT_IND_RES+1)<<2)
3282
3283#define SIR_BOOT_DNLD_RESULT_IND_SUCCESS 1
3284#define SIR_BOOT_DNLD_RESULT_IND_HDR_ERR 2
3285#define SIR_BOOT_DNLD_RESULT_IND_ERR 3
3286
3287// BOOT_DNLD_DEV_REQ
3288#define SIR_BOOT_DNLD_DEV_REQ_SDRAMSIZE 2
3289#define SIR_BOOT_DNLD_DEV_REQ_FLASHSIZE 3
3290#define SIR_BOOT_DNLD_DEV_REQ_LEN \
3291 ((SIR_BOOT_DNLD_DEV_REQ_FLASHSIZE+1)<<2)
3292
3293// BOOT_DNLD_DEV_RSP
3294#define SIR_BOOT_DNLD_DEV_RSP_DEVTYPE 2
3295#define SIR_BOOT_DNLD_DEV_RSP_LEN \
3296 ((SIR_BOOT_DNLD_DEV_RSP_DEVTYPE+1)<<2)
3297
3298#define SIR_BOOT_DNLD_DEV_RSP_SRAM 1
3299#define SIR_BOOT_DNLD_DEV_RSP_FLASH 2
3300
3301// BOOT_DNLD_REQ
3302#define SIR_BOOT_DNLD_REQ_OFFSET 2
3303#define SIR_BOOT_DNLD_REQ_WRADDR 3
3304#define SIR_BOOT_DNLD_REQ_SIZE 4
3305#define SIR_BOOT_DNLD_REQ_LEN ((SIR_BOOT_DNLD_REQ_SIZE+1)<<2)
3306
3307// BOOT_DNLD_RSP
3308#define SIR_BOOT_DNLD_RSP_SIZE 2
3309#define SIR_BOOT_DNLD_RSP_LEN ((SIR_BOOT_DNLD_RSP_SIZE+1)<<2)
3310
3311#if defined(ANI_OS_TYPE_RTAI_LINUX)
3312// RTAI WRAPPER definition - Buffer block control entry
3313// the new block Control entry is initialized by HDD
3314// memory buffers (blkPool) are allocated by HDD
3315// The table resides in plmac_rtai.c
3316#define BLOCK_ALLOCATED_BY_HDD 1
3317#define RED_ZONE 16 // 16 bytes between buffers
3318#define NUM_POOL 16 // NUM_POOL defined here for now, not
3319 // so good
3320typedef struct
3321{
3322 tANI_U16 blkSize;
3323 tANI_U16 blkNum;
3324 void *blkPool; // pointer to memory buffer
3325
3326} t_mac_block_table;
3327
3328#endif
3329
3330// board capabilities fields are defined here.
3331typedef __ani_attr_pre_packed struct sSirBoardCapabilities
3332{
3333#ifndef ANI_LITTLE_BIT_ENDIAN
3334 tANI_U32 concat:1; // 0 - Concat is not supported, 1 - Concat is supported
3335 tANI_U32 compression:1; // 0 - Compression is not supported, 1 - Compression is supported
3336 tANI_U32 chnlBonding:1; // 0 - Channel Bonding is not supported, 1 - Channel Bonding is supported
3337 tANI_U32 reverseFCS:1; // 0 - Reverse FCS is not supported, 1 - Reverse FCS is supported
3338 tANI_U32 rsvd1:2;
3339 // (productId derives sub-category in the following three families)
3340 tANI_U32 cbFamily:1; // 0 - Not CB family, 1 - Cardbus
3341 tANI_U32 apFamily:1; // 0 - Not AP family, 1 - AP
3342 tANI_U32 mpciFamily:1; // 0 - Not MPCI family, 1 - MPCI
3343 tANI_U32 bgOnly:1; // 0 - default a/b/g; 1 - b/g only
3344 tANI_U32 bbChipVer:4; // Baseband chip version
3345 tANI_U32 loType:2; // 0 = no LO, 1 = SILABS, 2 = ORION
3346 tANI_U32 radioOn:2; // Not supported is 3 or 2, 0 = Off and 1 = On
3347 tANI_U32 nReceivers:2; // 0 based.
3348 tANI_U32 nTransmitters:1; // 0 = 1 transmitter, 1 = 2 transmitters
3349 tANI_U32 sdram:1; // 0 = no SDRAM, 1 = SDRAM
3350 tANI_U32 rsvd:1;
3351 tANI_U32 extVsIntAnt:1; // 0 = ext antenna, 1 = internal antenna
3352#else
3353
3354 tANI_U32 extVsIntAnt:1; // 0 = ext antenna, 1 = internal antenna
3355 tANI_U32 rsvd:1;
3356 tANI_U32 sdram:1; // 0 = no SDRAM, 1 = SDRAM
3357 tANI_U32 nTransmitters:1; // 0 = 1 transmitter, 1 = 2 transmitters
3358 tANI_U32 nReceivers:2; // 0 based.
3359 tANI_U32 radioOn:2; // Not supported is 3 or 2, 0 = Off and 1 = On
3360 tANI_U32 loType:2; // 0 = no LO, 1 = SILABS, 2 = ORION
3361 tANI_U32 bbChipVer:4; // Baseband chip version
3362 tANI_U32 bgOnly:1; // 0 - default a/b/g; 1 - b/g only
3363 // (productId derives sub-category in the following three families)
3364 tANI_U32 mpciFamily:1; // 0 - Not MPCI family, 1 - MPCI
3365 tANI_U32 apFamily:1; // 0 - Not AP family, 1 - AP
3366 tANI_U32 cbFamily:1; // 0 - Not CB family, 1 - Cardbus
3367 tANI_U32 rsvd1:2;
3368 tANI_U32 reverseFCS:1; // 0 - Reverse FCS is not supported, 1 - Reverse FCS is supported
3369 tANI_U32 chnlBonding:1; // 0 - Channel Bonding is not supported, 1 - Channel Bonding is supported
3370 tANI_U32 compression:1; // 0 - Compression is not supported, 1 - Compression is supported
3371 tANI_U32 concat:1; // 0 - Concat is not supported, 1 - Concat is supported
3372#endif
3373} __ani_attr_packed tSirBoardCapabilities, *tpSirBoardCapabilities;
3374
3375# define ANI_BCAP_EXT_VS_INT_ANT_MASK 0x1
3376# define ANI_BCAP_EXT_VS_INT_ANT_OFFSET 0
3377
3378# define ANI_BCAP_GAL_ON_BOARD_MASK 0x2
3379# define ANI_BCAP_GAL_ON_BOARD_OFFSET 1
3380
3381# define ANI_BCAP_SDRAM_MASK 0x4
3382# define ANI_BCAP_SDRAM_OFFSET 2
3383
3384# define ANI_BCAP_NUM_TRANSMITTERS_MASK 0x8
3385# define ANI_BCAP_NUM_TRANSMITTERS_OFFSET 3
3386
3387# define ANI_BCAP_NUM_RECEIVERS_MASK 0x30
3388# define ANI_BCAP_NUM_RECEIVERS_OFFSET 4
3389
3390# define ANI_BCAP_RADIO_ON_MASK 0xC0
3391# define ANI_BCAP_RADIO_ON_OFFSET 6
3392
3393# define ANI_BCAP_LO_TYPE_MASK 0x300
3394# define ANI_BCAP_LO_TYPE_OFFSET 8
3395
3396# define ANI_BCAP_BB_CHIP_VER_MASK 0xC00
3397# define ANI_BCAP_BB_CHIP_VER_OFFSET 10
3398
3399# define ANI_BCAP_CYG_DATE_CODE_MASK 0xFF000
3400# define ANI_BCAP_CYG_DATE_CODE_OFFSET 12
3401
3402# define ANI_BCAP_RADIO_OFF 0
3403# define ANI_BCAP_RADIO_ON 1
3404# define ANI_BCAP_RADIO_ON_NOT_SUPPORTED 3
3405
3406
3407/// WOW related structures
3408// SME -> PE <-> HAL
3409#define SIR_WOWL_BCAST_PATTERN_MAX_SIZE 128
3410#define SIR_WOWL_BCAST_MAX_NUM_PATTERNS 16
3411
3412// SME -> PE -> HAL - This is to add WOWL BCAST wake-up pattern.
3413// SME/HDD maintains the list of the BCAST wake-up patterns.
3414// This is a pass through message for PE
3415typedef struct sSirWowlAddBcastPtrn
3416{
3417 tANI_U8 ucPatternId; // Pattern ID
3418 // Pattern byte offset from beginning of the 802.11 packet to start of the
3419 // wake-up pattern
3420 tANI_U8 ucPatternByteOffset;
3421 tANI_U8 ucPatternSize; // Non-Zero Pattern size
3422 tANI_U8 ucPattern[SIR_WOWL_BCAST_PATTERN_MAX_SIZE]; // Pattern
3423 tANI_U8 ucPatternMaskSize; // Non-zero pattern mask size
3424 tANI_U8 ucPatternMask[SIR_WOWL_BCAST_PATTERN_MAX_SIZE]; // Pattern mask
3425 // Extra pattern data beyond 128 bytes
3426 tANI_U8 ucPatternExt[SIR_WOWL_BCAST_PATTERN_MAX_SIZE]; // Extra Pattern
3427 tANI_U8 ucPatternMaskExt[SIR_WOWL_BCAST_PATTERN_MAX_SIZE]; // Extra Pattern mask
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07003428 tSirMacAddr bssId; // BSSID
Jeff Johnson295189b2012-06-20 16:38:30 -07003429} tSirWowlAddBcastPtrn, *tpSirWowlAddBcastPtrn;
3430
3431
3432// SME -> PE -> HAL - This is to delete WOWL BCAST wake-up pattern.
3433// SME/HDD maintains the list of the BCAST wake-up patterns.
3434// This is a pass through message for PE
3435typedef struct sSirWowlDelBcastPtrn
3436{
3437 /* Pattern ID of the wakeup pattern to be deleted */
3438 tANI_U8 ucPatternId;
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07003439 tSirMacAddr bssId; // BSSID
Jeff Johnson295189b2012-06-20 16:38:30 -07003440}tSirWowlDelBcastPtrn, *tpSirWowlDelBcastPtrn;
3441
3442
3443// SME->PE: Enter WOWLAN parameters
3444typedef struct sSirSmeWowlEnterParams
3445{
3446 /* Enables/disables magic packet filtering */
3447 tANI_U8 ucMagicPktEnable;
3448
3449 /* Magic pattern */
3450 tSirMacAddr magicPtrn;
3451
3452 /* Enables/disables packet pattern filtering */
3453 tANI_U8 ucPatternFilteringEnable;
3454
3455#ifdef WLAN_WAKEUP_EVENTS
3456 /* This configuration directs the WoW packet filtering to look for EAP-ID
3457 * requests embedded in EAPOL frames and use this as a wake source.
3458 */
3459 tANI_U8 ucWoWEAPIDRequestEnable;
3460
3461 /* This configuration directs the WoW packet filtering to look for EAPOL-4WAY
3462 * requests and use this as a wake source.
3463 */
3464 tANI_U8 ucWoWEAPOL4WayEnable;
3465
3466 /* This configuration allows a host wakeup on an network scan offload match.
3467 */
3468 tANI_U8 ucWowNetScanOffloadMatch;
3469
3470 /* This configuration allows a host wakeup on any GTK rekeying error.
3471 */
3472 tANI_U8 ucWowGTKRekeyError;
3473
3474 /* This configuration allows a host wakeup on BSS connection loss.
3475 */
3476 tANI_U8 ucWoWBSSConnLoss;
3477#endif // WLAN_WAKEUP_EVENTS
3478
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07003479 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07003480} tSirSmeWowlEnterParams, *tpSirSmeWowlEnterParams;
3481
3482
3483// PE<->HAL: Enter WOWLAN parameters
3484typedef struct sSirHalWowlEnterParams
3485{
3486 /* Enables/disables magic packet filtering */
3487 tANI_U8 ucMagicPktEnable;
3488
3489 /* Magic pattern */
3490 tSirMacAddr magicPtrn;
3491
3492 /* Enables/disables packet pattern filtering in firmware.
3493 Enabling this flag enables broadcast pattern matching
3494 in Firmware. If unicast pattern matching is also desired,
3495 ucUcastPatternFilteringEnable flag must be set tot true
3496 as well
3497 */
3498 tANI_U8 ucPatternFilteringEnable;
3499
3500 /* Enables/disables unicast packet pattern filtering.
3501 This flag specifies whether we want to do pattern match
3502 on unicast packets as well and not just broadcast packets.
3503 This flag has no effect if the ucPatternFilteringEnable
3504 (main controlling flag) is set to false
3505 */
3506 tANI_U8 ucUcastPatternFilteringEnable;
3507
3508 /* This configuration is valid only when magicPktEnable=1.
3509 * It requests hardware to wake up when it receives the
3510 * Channel Switch Action Frame.
3511 */
3512 tANI_U8 ucWowChnlSwitchRcv;
3513
3514 /* This configuration is valid only when magicPktEnable=1.
3515 * It requests hardware to wake up when it receives the
3516 * Deauthentication Frame.
3517 */
3518 tANI_U8 ucWowDeauthRcv;
3519
3520 /* This configuration is valid only when magicPktEnable=1.
3521 * It requests hardware to wake up when it receives the
3522 * Disassociation Frame.
3523 */
3524 tANI_U8 ucWowDisassocRcv;
3525
3526 /* This configuration is valid only when magicPktEnable=1.
3527 * It requests hardware to wake up when it has missed
3528 * consecutive beacons. This is a hardware register
3529 * configuration (NOT a firmware configuration).
3530 */
3531 tANI_U8 ucWowMaxMissedBeacons;
3532
3533 /* This configuration is valid only when magicPktEnable=1.
3534 * This is a timeout value in units of microsec. It requests
3535 * hardware to unconditionally wake up after it has stayed
3536 * in WoWLAN mode for some time. Set 0 to disable this feature.
3537 */
3538 tANI_U8 ucWowMaxSleepUsec;
3539
3540#ifdef WLAN_WAKEUP_EVENTS
3541 /* This configuration directs the WoW packet filtering to look for EAP-ID
3542 * requests embedded in EAPOL frames and use this as a wake source.
3543 */
3544 tANI_U8 ucWoWEAPIDRequestEnable;
3545
3546 /* This configuration directs the WoW packet filtering to look for EAPOL-4WAY
3547 * requests and use this as a wake source.
3548 */
3549 tANI_U8 ucWoWEAPOL4WayEnable;
3550
3551 /* This configuration allows a host wakeup on an network scan offload match.
3552 */
3553 tANI_U8 ucWowNetScanOffloadMatch;
3554
3555 /* This configuration allows a host wakeup on any GTK rekeying error.
3556 */
3557 tANI_U8 ucWowGTKRekeyError;
3558
3559 /* This configuration allows a host wakeup on BSS connection loss.
3560 */
3561 tANI_U8 ucWoWBSSConnLoss;
3562#endif // WLAN_WAKEUP_EVENTS
3563
3564 /* Status code to be filled by HAL when it sends
3565 * SIR_HAL_WOWL_ENTER_RSP to PE.
3566 */
3567 eHalStatus status;
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07003568
3569 /*BSSID to find the current session
3570 */
3571 tANI_U8 bssIdx;
Jeff Johnson295189b2012-06-20 16:38:30 -07003572} tSirHalWowlEnterParams, *tpSirHalWowlEnterParams;
3573
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07003574// PE<->HAL: Exit WOWLAN parameters
3575typedef struct sSirHalWowlExitParams
3576{
3577 /* Status code to be filled by HAL when it sends
3578 * SIR_HAL_WOWL_EXIT_RSP to PE.
3579 */
3580 eHalStatus status;
3581
3582 /*BSSIDX to find the current session
3583 */
3584 tANI_U8 bssIdx;
3585} tSirHalWowlExitParams, *tpSirHalWowlExitParams;
3586
Jeff Johnson295189b2012-06-20 16:38:30 -07003587#ifdef WLAN_SOFTAP_FEATURE
3588
3589#define SIR_MAX_NAME_SIZE 64
3590#define SIR_MAX_TEXT_SIZE 32
3591
3592typedef struct sSirName {
3593 v_U8_t num_name;
3594 v_U8_t name[SIR_MAX_NAME_SIZE];
3595} tSirName;
3596
3597typedef struct sSirText {
3598 v_U8_t num_text;
3599 v_U8_t text[SIR_MAX_TEXT_SIZE];
3600} tSirText;
3601
3602
3603#define SIR_WPS_PROBRSP_VER_PRESENT 0x00000001
3604#define SIR_WPS_PROBRSP_STATE_PRESENT 0x00000002
3605#define SIR_WPS_PROBRSP_APSETUPLOCK_PRESENT 0x00000004
3606#define SIR_WPS_PROBRSP_SELECTEDREGISTRA_PRESENT 0x00000008
3607#define SIR_WPS_PROBRSP_DEVICEPASSWORDID_PRESENT 0x00000010
3608#define SIR_WPS_PROBRSP_SELECTEDREGISTRACFGMETHOD_PRESENT 0x00000020
3609#define SIR_WPS_PROBRSP_RESPONSETYPE_PRESENT 0x00000040
3610#define SIR_WPS_PROBRSP_UUIDE_PRESENT 0x00000080
3611#define SIR_WPS_PROBRSP_MANUFACTURE_PRESENT 0x00000100
3612#define SIR_WPS_PROBRSP_MODELNAME_PRESENT 0x00000200
3613#define SIR_WPS_PROBRSP_MODELNUMBER_PRESENT 0x00000400
3614#define SIR_WPS_PROBRSP_SERIALNUMBER_PRESENT 0x00000800
3615#define SIR_WPS_PROBRSP_PRIMARYDEVICETYPE_PRESENT 0x00001000
3616#define SIR_WPS_PROBRSP_DEVICENAME_PRESENT 0x00002000
3617#define SIR_WPS_PROBRSP_CONFIGMETHODS_PRESENT 0x00004000
3618#define SIR_WPS_PROBRSP_RF_BANDS_PRESENT 0x00008000
3619
3620
3621typedef struct sSirWPSProbeRspIE {
3622 v_U32_t FieldPresent;
3623 v_U32_t Version; // Version. 0x10 = version 1.0, 0x11 = etc.
3624 v_U32_t wpsState; // 1 = unconfigured, 2 = configured.
3625 v_BOOL_t APSetupLocked; // Must be included if value is TRUE
3626 v_BOOL_t SelectedRegistra; //BOOL: indicates if the user has recently activated a Registrar to add an Enrollee.
3627 v_U16_t DevicePasswordID; // Device Password ID
3628 v_U16_t SelectedRegistraCfgMethod; // Selected Registrar config method
3629 v_U8_t ResponseType; // Response type
3630 v_U8_t UUID_E[16]; // Unique identifier of the AP.
3631 tSirName Manufacture;
3632 tSirText ModelName;
3633 tSirText ModelNumber;
3634 tSirText SerialNumber;
3635 v_U32_t PrimaryDeviceCategory ; // Device Category ID: 1Computer, 2Input Device, ...
3636 v_U8_t PrimaryDeviceOUI[4] ; // Vendor specific OUI for Device Sub Category
3637 v_U32_t DeviceSubCategory ; // Device Sub Category ID: 1-PC, 2-Server if Device Category ID is computer
3638 tSirText DeviceName;
3639 v_U16_t ConfigMethod; // Configuaration method
3640 v_U8_t RFBand; // RF bands available on the AP
3641} tSirWPSProbeRspIE;
3642
3643#define SIR_WPS_BEACON_VER_PRESENT 0x00000001
3644#define SIR_WPS_BEACON_STATE_PRESENT 0x00000002
3645#define SIR_WPS_BEACON_APSETUPLOCK_PRESENT 0x00000004
3646#define SIR_WPS_BEACON_SELECTEDREGISTRA_PRESENT 0x00000008
3647#define SIR_WPS_BEACON_DEVICEPASSWORDID_PRESENT 0x00000010
3648#define SIR_WPS_BEACON_SELECTEDREGISTRACFGMETHOD_PRESENT 0x00000020
3649#define SIR_WPS_BEACON_UUIDE_PRESENT 0x00000080
3650#define SIR_WPS_BEACON_RF_BANDS_PRESENT 0x00000100
3651
3652typedef struct sSirWPSBeaconIE {
3653 v_U32_t FieldPresent;
3654 v_U32_t Version; // Version. 0x10 = version 1.0, 0x11 = etc.
3655 v_U32_t wpsState; // 1 = unconfigured, 2 = configured.
3656 v_BOOL_t APSetupLocked; // Must be included if value is TRUE
3657 v_BOOL_t SelectedRegistra; //BOOL: indicates if the user has recently activated a Registrar to add an Enrollee.
3658 v_U16_t DevicePasswordID; // Device Password ID
3659 v_U16_t SelectedRegistraCfgMethod; // Selected Registrar config method
3660 v_U8_t UUID_E[16]; // Unique identifier of the AP.
3661 v_U8_t RFBand; // RF bands available on the AP
3662} tSirWPSBeaconIE;
3663
3664#define SIR_WPS_ASSOCRSP_VER_PRESENT 0x00000001
3665#define SIR_WPS_ASSOCRSP_RESPONSETYPE_PRESENT 0x00000002
3666
3667typedef struct sSirWPSAssocRspIE {
3668 v_U32_t FieldPresent;
3669 v_U32_t Version;
3670 v_U8_t ResposeType;
3671} tSirWPSAssocRspIE;
3672
3673typedef struct sSirAPWPSIEs {
3674 tSirWPSProbeRspIE SirWPSProbeRspIE; /*WPS Set Probe Respose IE*/
3675 tSirWPSBeaconIE SirWPSBeaconIE; /*WPS Set Beacon IE*/
3676 tSirWPSAssocRspIE SirWPSAssocRspIE; /*WPS Set Assoc Response IE*/
3677} tSirAPWPSIEs, *tpSiriAPWPSIEs;
3678
3679typedef struct sSirUpdateAPWPSIEsReq
3680{
3681 tANI_U16 messageType; // eWNI_SME_UPDATE_APWPSIE_REQ
3682 tANI_U16 length;
3683 tANI_U16 transactionId; //Transaction ID for cmd
3684 tSirMacAddr bssId; // BSSID
3685 tANI_U8 sessionId; //Session ID
3686 tSirAPWPSIEs APWPSIEs;
3687} tSirUpdateAPWPSIEsReq, *tpSirUpdateAPWPSIEsReq;
3688
3689typedef struct sSirUpdateParams
3690{
3691 tANI_U16 messageType;
3692 tANI_U16 length;
3693 tANI_U8 sessionId; // Session ID
3694 tANI_U8 ssidHidden; // Hide SSID
3695} tSirUpdateParams, *tpSirUpdateParams;
3696
Madan Mohan Koyyalamudi167b95e2012-11-27 15:53:38 -08003697//Beacon Interval
3698typedef struct sSirChangeBIParams
3699{
3700 tANI_U16 messageType;
3701 tANI_U16 length;
3702 tANI_U16 beaconInterval; // Beacon Interval
3703 tSirMacAddr bssId;
3704 tANI_U8 sessionId; // Session ID
3705} tSirChangeBIParams, *tpSirChangeBIParams;
3706
Jeff Johnson295189b2012-06-20 16:38:30 -07003707#define SIR_WPS_UUID_LEN 16
3708#define SIR_WPS_PBC_WALK_TIME 120 // 120 Second
3709
3710typedef struct sSirWPSPBCSession {
3711 struct sSirWPSPBCSession *next;
3712 tSirMacAddr addr;
3713 tANI_U8 uuid_e[SIR_WPS_UUID_LEN];
3714 tANI_TIMESTAMP timestamp;
3715} tSirWPSPBCSession;
3716
3717typedef struct sSirSmeGetWPSPBCSessionsReq
3718{
3719 tANI_U16 messageType; // eWNI_SME_GET_WPSPBC_SESSION_REQ
3720 tANI_U16 length;
3721 void *pUsrContext;
3722 void *pSapEventCallback;
3723 tSirMacAddr bssId; // BSSID
3724 tSirMacAddr pRemoveMac; // MAC Address of STA in WPS Session to be removed
3725} tSirSmeGetWPSPBCSessionsReq, *tpSirSmeGetWPSPBCSessionsReq;
3726
3727typedef struct sSirWPSPBCProbeReq
3728{
3729 tSirMacAddr peerMacAddr;
3730 tANI_U16 probeReqIELen;
3731 tANI_U8 probeReqIE[512];
3732} tSirWPSPBCProbeReq, *tpSirWPSPBCProbeReq;
3733
3734// probereq from peer, when wsc is enabled
3735typedef struct sSirSmeProbeReqInd
3736{
3737 tANI_U16 messageType; // eWNI_SME_WPS_PBC_PROBE_REQ_IND
3738 tANI_U16 length;
3739 tANI_U8 sessionId;
3740 tSirMacAddr bssId;
3741 tSirWPSPBCProbeReq WPSPBCProbeReq;
3742} tSirSmeProbeReqInd, *tpSirSmeProbeReqInd;
3743
3744typedef struct sSirUpdateAPWPARSNIEsReq
3745{
3746 tANI_U16 messageType; // eWNI_SME_SET_APWPARSNIEs_REQ
3747 tANI_U16 length;
3748 tANI_U16 transactionId; //Transaction ID for cmd
3749 tSirMacAddr bssId; // BSSID
3750 tANI_U8 sessionId; //Session ID
3751 tSirRSNie APWPARSNIEs;
3752} tSirUpdateAPWPARSNIEsReq, *tpSirUpdateAPWPARSNIEsReq;
3753
3754#endif
3755
3756// SME -> HAL - This is the host offload request.
3757#define SIR_IPV4_ARP_REPLY_OFFLOAD 0
3758#define SIR_IPV6_NEIGHBOR_DISCOVERY_OFFLOAD 1
3759#define SIR_IPV6_NS_OFFLOAD 2
3760#define SIR_OFFLOAD_DISABLE 0
3761#define SIR_OFFLOAD_ENABLE 1
3762#define SIR_OFFLOAD_BCAST_FILTER_ENABLE 0x2
3763#define SIR_OFFLOAD_ARP_AND_BCAST_FILTER_ENABLE (SIR_OFFLOAD_ENABLE|SIR_OFFLOAD_BCAST_FILTER_ENABLE)
3764
3765#ifdef WLAN_NS_OFFLOAD
3766typedef struct sSirNsOffloadReq
3767{
3768 tANI_U8 srcIPv6Addr[16];
3769 tANI_U8 selfIPv6Addr[16];
3770 //Only support 2 possible Network Advertisement IPv6 address
3771 tANI_U8 targetIPv6Addr[SIR_MAC_NUM_TARGET_IPV6_NS_OFFLOAD_NA][16];
3772 tANI_U8 selfMacAddr[6];
3773 tANI_U8 srcIPv6AddrValid;
3774 tANI_U8 targetIPv6AddrValid[SIR_MAC_NUM_TARGET_IPV6_NS_OFFLOAD_NA];
3775} tSirNsOffloadReq, *tpSirNsOffloadReq;
3776#endif //WLAN_NS_OFFLOAD
3777
3778typedef struct sSirHostOffloadReq
3779{
3780 tANI_U8 offloadType;
3781 tANI_U8 enableOrDisable;
3782 union
3783 {
3784 tANI_U8 hostIpv4Addr [4];
3785 tANI_U8 hostIpv6Addr [16];
3786 } params;
3787#ifdef WLAN_NS_OFFLOAD
3788 tSirNsOffloadReq nsOffloadInfo;
3789#endif //WLAN_NS_OFFLOAD
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07003790 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07003791} tSirHostOffloadReq, *tpSirHostOffloadReq;
3792
3793/* Packet Types. */
3794#define SIR_KEEP_ALIVE_NULL_PKT 1
3795#define SIR_KEEP_ALIVE_UNSOLICIT_ARP_RSP 2
3796
3797/* Enable or disable offload. */
3798#define SIR_KEEP_ALIVE_DISABLE 0
3799#define SIR_KEEP_ALIVE_ENABLE 1
3800
3801/* Keep Alive request. */
3802typedef struct sSirKeepAliveReq
3803{
3804 v_U8_t packetType;
3805 v_U32_t timePeriod;
3806 tSirIpv4Addr hostIpv4Addr;
3807 tSirIpv4Addr destIpv4Addr;
3808 tSirMacAddr destMacAddr;
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07003809 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07003810} tSirKeepAliveReq, *tpSirKeepAliveReq;
3811
3812typedef struct sSirSmeAddStaSelfReq
3813{
3814 tANI_U16 mesgType;
3815 tANI_U16 mesgLen;
3816 tSirMacAddr selfMacAddr;
3817}tSirSmeAddStaSelfReq, *tpSirSmeAddStaSelfReq;
3818
3819typedef struct sSirSmeDelStaSelfReq
3820{
3821 tANI_U16 mesgType;
3822 tANI_U16 mesgLen;
3823 tSirMacAddr selfMacAddr;
3824}tSirSmeDelStaSelfReq, *tpSirSmeDelStaSelfReq;
3825
3826typedef struct sSirSmeAddStaSelfRsp
3827{
3828 tANI_U16 mesgType;
3829 tANI_U16 mesgLen;
3830 tANI_U16 status;
3831 tSirMacAddr selfMacAddr;
3832}tSirSmeAddStaSelfRsp, *tpSirSmeAddStaSelfRsp;
3833
3834typedef struct sSirSmeDelStaSelfRsp
3835{
3836 tANI_U16 mesgType;
3837 tANI_U16 mesgLen;
3838 tANI_U16 status;
3839 tSirMacAddr selfMacAddr;
3840}tSirSmeDelStaSelfRsp, *tpSirSmeDelStaSelfRsp;
3841
3842/* Coex Indication defines -
3843 should match WLAN_COEX_IND_DATA_SIZE
3844 should match WLAN_COEX_IND_TYPE_DISABLE_HB_MONITOR
3845 should match WLAN_COEX_IND_TYPE_ENABLE_HB_MONITOR */
3846#define SIR_COEX_IND_DATA_SIZE (4)
3847#define SIR_COEX_IND_TYPE_DISABLE_HB_MONITOR (0)
3848#define SIR_COEX_IND_TYPE_ENABLE_HB_MONITOR (1)
3849
3850typedef struct sSirSmeCoexInd
3851{
3852 tANI_U16 mesgType;
3853 tANI_U16 mesgLen;
3854 tANI_U32 coexIndType;
3855 tANI_U32 coexIndData[SIR_COEX_IND_DATA_SIZE];
3856}tSirSmeCoexInd, *tpSirSmeCoexInd;
3857
3858#ifdef WLAN_FEATURE_P2P
3859typedef struct sSirSmeMgmtFrameInd
3860{
3861 tANI_U16 mesgType;
3862 tANI_U16 mesgLen;
3863 tANI_U8 sessionId;
3864 tANI_U8 frameType;
3865 tANI_U32 rxChan;
3866 tANI_U8 frameBuf[1]; //variable
3867}tSirSmeMgmtFrameInd, *tpSirSmeMgmtFrameInd;
3868#endif
3869
3870#define SIR_IS_FULL_POWER_REASON_DISCONNECTED(eReason) \
3871 ( ( eSME_LINK_DISCONNECTED_BY_HDD == (eReason) ) || \
3872 ( eSME_LINK_DISCONNECTED_BY_OTHER == (eReason) ) || \
3873 (eSME_FULL_PWR_NEEDED_BY_CHANNEL_SWITCH == (eReason)))
3874#define SIR_IS_FULL_POWER_NEEDED_BY_HDD(eReason) \
3875 ( ( eSME_LINK_DISCONNECTED_BY_HDD == (eReason) ) || ( eSME_FULL_PWR_NEEDED_BY_HDD == (eReason) ) )
3876
3877/* P2P Power Save Related */
3878#ifdef WLAN_FEATURE_P2P
3879typedef struct sSirNoAParam
3880{
3881 tANI_U8 ctWindow:7;
3882 tANI_U8 OppPS:1;
3883 tANI_U8 count;
3884 tANI_U32 duration;
3885 tANI_U32 interval;
3886 tANI_U32 singleNoADuration;
3887 tANI_U8 psSelection;
3888}tSirNoAParam, *tpSirNoAParam;
3889#endif
3890
3891#ifdef FEATURE_WLAN_INTEGRATED_SOC
3892typedef struct sSirWlanSuspendParam
3893{
3894 tANI_U8 configuredMcstBcstFilterSetting;
3895}tSirWlanSuspendParam,*tpSirWlanSuspendParam;
3896
3897typedef struct sSirWlanResumeParam
3898{
3899 tANI_U8 configuredMcstBcstFilterSetting;
3900}tSirWlanResumeParam,*tpSirWlanResumeParam;
3901
3902typedef struct sSirWlanSetRxpFilters
3903{
3904 tANI_U8 configuredMcstBcstFilterSetting;
3905 tANI_U8 setMcstBcstFilter;
3906}tSirWlanSetRxpFilters,*tpSirWlanSetRxpFilters;
3907#endif
3908
3909
3910#ifdef FEATURE_WLAN_SCAN_PNO
3911//
3912// PNO Messages
3913//
3914
3915// Set PNO
3916#define SIR_PNO_MAX_NETW_CHANNELS 26
Pratik Bhalgatd4404592012-11-22 17:49:14 +05303917#define SIR_PNO_MAX_NETW_CHANNELS_EX 60
Jeff Johnson295189b2012-06-20 16:38:30 -07003918#define SIR_PNO_MAX_SUPP_NETWORKS 16
3919#define SIR_PNO_MAX_SCAN_TIMERS 10
3920
3921/*size based of dot11 declaration without extra IEs as we will not carry those for PNO*/
3922#define SIR_PNO_MAX_PB_REQ_SIZE 450
3923
3924#define SIR_PNO_24G_DEFAULT_CH 1
3925#define SIR_PNO_5G_DEFAULT_CH 36
3926
3927typedef enum
3928{
3929 SIR_PNO_MODE_IMMEDIATE,
3930 SIR_PNO_MODE_ON_SUSPEND,
3931 SIR_PNO_MODE_ON_RESUME,
3932 SIR_PNO_MODE_MAX
3933} eSirPNOMode;
3934
3935typedef struct
3936{
3937 tSirMacSSid ssId;
3938 tANI_U32 authentication;
3939 tANI_U32 encryption;
3940 tANI_U32 bcastNetwType;
3941 tANI_U8 ucChannelCount;
3942 tANI_U8 aChannels[SIR_PNO_MAX_NETW_CHANNELS];
3943 tANI_U8 rssiThreshold;
3944} tSirNetworkType;
3945
3946typedef struct
3947{
3948 tANI_U32 uTimerValue;
3949 tANI_U32 uTimerRepeat;
3950}tSirScanTimer;
3951
3952typedef struct
3953{
3954 tANI_U8 ucScanTimersCount;
3955 tSirScanTimer aTimerValues[SIR_PNO_MAX_SCAN_TIMERS];
3956} tSirScanTimersType;
3957
3958typedef struct sSirPNOScanReq
3959{
3960 tANI_U8 enable;
3961 eSirPNOMode modePNO;
3962 tANI_U8 ucNetworksCount;
3963 tSirNetworkType aNetworks[SIR_PNO_MAX_SUPP_NETWORKS];
3964 tSirScanTimersType scanTimers;
3965
3966 /*added by SME*/
3967 tANI_U16 us24GProbeTemplateLen;
3968 tANI_U8 p24GProbeTemplate[SIR_PNO_MAX_PB_REQ_SIZE];
3969 tANI_U16 us5GProbeTemplateLen;
3970 tANI_U8 p5GProbeTemplate[SIR_PNO_MAX_PB_REQ_SIZE];
3971} tSirPNOScanReq, *tpSirPNOScanReq;
3972
3973typedef struct sSirSetRSSIFilterReq
3974{
3975 tANI_U8 rssiThreshold;
3976} tSirSetRSSIFilterReq, *tpSirSetRSSIFilterReq;
3977
3978
3979// Update Scan Params
3980typedef struct {
3981 tANI_U8 b11dEnabled;
3982 tANI_U8 b11dResolved;
3983 tANI_U8 ucChannelCount;
Pratik Bhalgatd4404592012-11-22 17:49:14 +05303984 tANI_U8 aChannels[SIR_PNO_MAX_NETW_CHANNELS_EX];
Jeff Johnson295189b2012-06-20 16:38:30 -07003985 tANI_U16 usPassiveMinChTime;
3986 tANI_U16 usPassiveMaxChTime;
3987 tANI_U16 usActiveMinChTime;
3988 tANI_U16 usActiveMaxChTime;
3989 tANI_U8 ucCBState;
3990} tSirUpdateScanParams, * tpSirUpdateScanParams;
3991
3992// Preferred Network Found Indication
3993typedef struct
3994{
3995 tANI_U16 mesgType;
3996 tANI_U16 mesgLen;
3997 /* Network that was found with the highest RSSI*/
3998 tSirMacSSid ssId;
3999 /* Indicates the RSSI */
4000 tANI_U8 rssi;
4001} tSirPrefNetworkFoundInd, *tpSirPrefNetworkFoundInd;
4002#endif // FEATURE_WLAN_SCAN_PNO
4003
4004#define SIR_NOCHANGE_POWER_VALUE 0xFFFFFFFF
4005
4006//Power Parameters Type
4007typedef enum
4008{
4009 eSIR_IGNORE_DTIM = 1,
4010 eSIR_LISTEN_INTERVAL = 2,
4011 eSIR_MCAST_BCAST_FILTER = 3,
4012 eSIR_ENABLE_BET = 4,
4013 eSIR_BET_INTERVAL = 5
4014}tPowerParamType;
4015
4016//Power Parameters Value s
4017typedef struct
4018{
4019 /* Ignore DTIM */
4020 tANI_U32 uIgnoreDTIM;
4021
4022 /* DTIM Period */
4023 tANI_U32 uDTIMPeriod;
4024
4025 /* Listen Interval */
4026 tANI_U32 uListenInterval;
4027
4028 /* Broadcast Multicas Filter */
4029 tANI_U32 uBcastMcastFilter;
4030
4031 /* Beacon Early Termination */
4032 tANI_U32 uEnableBET;
4033
4034 /* Beacon Early Termination Interval */
4035 tANI_U32 uBETInterval;
4036
4037}tSirSetPowerParamsReq, *tpSirSetPowerParamsReq;
4038
4039typedef struct sSirTxPerTrackingParam
4040{
4041 tANI_U8 ucTxPerTrackingEnable; /* 0: disable, 1:enable */
4042 tANI_U8 ucTxPerTrackingPeriod; /* Check period, unit is sec. Once tx_stat_chk enable, firmware will check PER in this period periodically */
4043 tANI_U8 ucTxPerTrackingRatio; /* (Fail TX packet)/(Total TX packet) ratio, the unit is 10%. for example, 5 means 50% TX failed rate, default is 5. If current TX packet failed rate bigger than this ratio then firmware send WLC_E_TX_STAT_ERROR event to driver */
4044 tANI_U32 uTxPerTrackingWatermark; /* A watermark of check number, once the tx packet exceed this number, we do the check, default is 5 */
4045}tSirTxPerTrackingParam, *tpSirTxPerTrackingParam;
4046
4047#ifdef WLAN_FEATURE_PACKET_FILTERING
4048/*---------------------------------------------------------------------------
4049 Packet Filtering Parameters
4050---------------------------------------------------------------------------*/
4051#define SIR_IPV4_ADDR_LEN 4
4052#define SIR_MAC_ADDR_LEN 6
4053#define SIR_MAX_FILTER_TEST_DATA_LEN 8
4054#define SIR_MAX_NUM_MULTICAST_ADDRESS 240
4055#define SIR_MAX_NUM_FILTERS 20
4056#define SIR_MAX_NUM_TESTS_PER_FILTER 10
4057
4058//
4059// Receive Filter Parameters
4060//
4061typedef enum
4062{
4063 SIR_RCV_FILTER_TYPE_INVALID,
4064 SIR_RCV_FILTER_TYPE_FILTER_PKT,
4065 SIR_RCV_FILTER_TYPE_BUFFER_PKT,
4066 SIR_RCV_FILTER_TYPE_MAX_ENUM_SIZE
4067}eSirReceivePacketFilterType;
4068
4069typedef enum
4070{
4071 SIR_FILTER_HDR_TYPE_INVALID,
4072 SIR_FILTER_HDR_TYPE_MAC,
4073 SIR_FILTER_HDR_TYPE_ARP,
4074 SIR_FILTER_HDR_TYPE_IPV4,
4075 SIR_FILTER_HDR_TYPE_IPV6,
4076 SIR_FILTER_HDR_TYPE_UDP,
4077 SIR_FILTER_HDR_TYPE_MAX
4078}eSirRcvPktFltProtocolType;
4079
4080typedef enum
4081{
4082 SIR_FILTER_CMP_TYPE_INVALID,
4083 SIR_FILTER_CMP_TYPE_EQUAL,
4084 SIR_FILTER_CMP_TYPE_MASK_EQUAL,
4085 SIR_FILTER_CMP_TYPE_NOT_EQUAL,
4086 SIR_FILTER_CMP_TYPE_MASK_NOT_EQUAL,
4087 SIR_FILTER_CMP_TYPE_MAX
4088}eSirRcvPktFltCmpFlagType;
4089
4090typedef struct sSirRcvPktFilterFieldParams
4091{
4092 eSirRcvPktFltProtocolType protocolLayer;
4093 eSirRcvPktFltCmpFlagType cmpFlag;
4094 /* Length of the data to compare */
4095 tANI_U16 dataLength;
4096 /* from start of the respective frame header */
4097 tANI_U8 dataOffset;
4098 /* Reserved field */
4099 tANI_U8 reserved;
4100 /* Data to compare */
4101 tANI_U8 compareData[SIR_MAX_FILTER_TEST_DATA_LEN];
4102 /* Mask to be applied on the received packet data before compare */
4103 tANI_U8 dataMask[SIR_MAX_FILTER_TEST_DATA_LEN];
4104}tSirRcvPktFilterFieldParams, *tpSirRcvPktFilterFieldParams;
4105
4106typedef struct sSirRcvPktFilterCfg
4107{
4108 tANI_U8 filterId;
4109 eSirReceivePacketFilterType filterType;
4110 tANI_U32 numFieldParams;
4111 tANI_U32 coalesceTime;
Jeff Johnsone7245742012-09-05 17:12:55 -07004112 tSirMacAddr selfMacAddr;
4113 tSirMacAddr bssId; //Bssid of the connected AP
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07004114 tSirRcvPktFilterFieldParams paramsData[SIR_MAX_NUM_TESTS_PER_FILTER];
Jeff Johnson295189b2012-06-20 16:38:30 -07004115}tSirRcvPktFilterCfgType, *tpSirRcvPktFilterCfgType;
4116
4117//
4118// Filter Packet Match Count Parameters
4119//
4120typedef struct sSirRcvFltPktMatchCnt
4121{
4122 tANI_U8 filterId;
4123 tANI_U32 matchCnt;
4124} tSirRcvFltPktMatchCnt, tpSirRcvFltPktMatchCnt;
4125
4126typedef struct sSirRcvFltPktMatchRsp
4127{
4128 tANI_U16 mesgType;
4129 tANI_U16 mesgLen;
4130
4131 /* Success or Failure */
4132 tANI_U32 status;
4133 tSirRcvFltPktMatchCnt filterMatchCnt[SIR_MAX_NUM_FILTERS];
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07004134 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07004135} tSirRcvFltPktMatchRsp, *tpSirRcvFltPktMatchRsp;
4136
4137//
4138// Receive Filter Clear Parameters
4139//
4140typedef struct sSirRcvFltPktClearParam
4141{
4142 tANI_U32 status; /* only valid for response message */
4143 tANI_U8 filterId;
Jeff Johnsone7245742012-09-05 17:12:55 -07004144 tSirMacAddr selfMacAddr;
4145 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07004146}tSirRcvFltPktClearParam, *tpSirRcvFltPktClearParam;
4147
4148//
4149// Multicast Address List Parameters
4150//
4151typedef struct sSirRcvFltMcAddrList
4152{
4153 tANI_U32 ulMulticastAddrCnt;
4154 tSirMacAddr multicastAddr[SIR_MAX_NUM_MULTICAST_ADDRESS];
Jeff Johnsone7245742012-09-05 17:12:55 -07004155 tSirMacAddr selfMacAddr;
4156 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07004157} tSirRcvFltMcAddrList, *tpSirRcvFltMcAddrList;
4158#endif // WLAN_FEATURE_PACKET_FILTERING
4159
4160//
4161// Generic version information
4162//
4163typedef struct
4164{
4165 tANI_U8 revision;
4166 tANI_U8 version;
4167 tANI_U8 minor;
4168 tANI_U8 major;
4169} tSirVersionType;
4170
4171typedef struct sAniBtAmpLogLinkReq
4172{
4173 // Common for all types are requests
4174 tANI_U16 msgType; // message type is same as the request type
4175 tANI_U16 msgLen; // length of the entire request
4176 tANI_U8 sessionId; //sme Session Id
4177 void *btampHandle; //AMP context
4178
4179} tAniBtAmpLogLinkReq, *tpAniBtAmpLogLinkReq;
4180
4181#ifdef WLAN_FEATURE_GTK_OFFLOAD
4182/*---------------------------------------------------------------------------
4183* WDA_GTK_OFFLOAD_REQ
4184*--------------------------------------------------------------------------*/
4185typedef struct
4186{
4187 tANI_U32 ulFlags; /* optional flags */
4188 tANI_U8 aKCK[16]; /* Key confirmation key */
4189 tANI_U8 aKEK[16]; /* key encryption key */
4190 tANI_U64 ullKeyReplayCounter; /* replay counter */
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07004191 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07004192} tSirGtkOffloadParams, *tpSirGtkOffloadParams;
4193
4194/*---------------------------------------------------------------------------
4195* WDA_GTK_OFFLOAD_GETINFO_REQ
4196*--------------------------------------------------------------------------*/
4197typedef struct
4198{
4199 tANI_U16 mesgType;
4200 tANI_U16 mesgLen;
4201
4202 tANI_U32 ulStatus; /* success or failure */
4203 tANI_U64 ullKeyReplayCounter; /* current replay counter value */
4204 tANI_U32 ulTotalRekeyCount; /* total rekey attempts */
4205 tANI_U32 ulGTKRekeyCount; /* successful GTK rekeys */
4206 tANI_U32 ulIGTKRekeyCount; /* successful iGTK rekeys */
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07004207 tSirMacAddr bssId;
Jeff Johnson295189b2012-06-20 16:38:30 -07004208} tSirGtkOffloadGetInfoRspParams, *tpSirGtkOffloadGetInfoRspParams;
4209#endif // WLAN_FEATURE_GTK_OFFLOAD
4210
4211#ifdef WLAN_WAKEUP_EVENTS
4212/*---------------------------------------------------------------------------
4213 tSirWakeReasonInd
4214---------------------------------------------------------------------------*/
4215typedef struct
4216{
4217 tANI_U16 mesgType;
4218 tANI_U16 mesgLen;
4219 tANI_U32 ulReason; /* see tWakeReasonType */
4220 tANI_U32 ulReasonArg; /* argument specific to the reason type */
4221 tANI_U32 ulStoredDataLen; /* length of optional data stored in this message, in case
4222 HAL truncates the data (i.e. data packets) this length
4223 will be less than the actual length */
4224 tANI_U32 ulActualDataLen; /* actual length of data */
4225 tANI_U8 aDataStart[1]; /* variable length start of data (length == storedDataLen)
4226 see specific wake type */
4227} tSirWakeReasonInd, *tpSirWakeReasonInd;
4228#endif // WLAN_WAKEUP_EVENTS
4229
4230/*---------------------------------------------------------------------------
4231 sAniSetTmLevelReq
4232---------------------------------------------------------------------------*/
4233typedef struct sAniSetTmLevelReq
4234{
4235 tANI_U16 tmMode;
4236 tANI_U16 newTmLevel;
4237} tAniSetTmLevelReq, *tpAniSetTmLevelReq;
4238
Mohit Khanna698ba2a2012-12-04 15:08:18 -08004239#ifdef FEATURE_WLAN_TDLS
4240/* TDLS Request struct SME-->PE */
4241typedef struct sSirTdlsSendMgmtReq
4242{
4243 tANI_U16 messageType; // eWNI_SME_TDLS_DISCOVERY_START_REQ
4244 tANI_U16 length;
4245 tANI_U8 sessionId; // Session ID
4246 tANI_U16 transactionId; // Transaction ID for cmd
4247 tANI_U8 reqType;
4248 tANI_U8 dialog;
4249 tANI_U16 statusCode;
4250 tSirMacAddr bssid; // For multi-session, for PE to locate peSession ID
4251 tSirMacAddr peerMac;
4252 tANI_U8 addIe[1]; //Variable lenght. Dont add any field after this.
4253} tSirTdlsSendMgmtReq, *tpSirSmeTdlsSendMgmtReq ;
4254/* TDLS Request struct SME-->PE */
4255typedef struct sSirTdlsAddStaReq
4256{
4257 tANI_U16 messageType; // eWNI_SME_TDLS_DISCOVERY_START_REQ
4258 tANI_U16 length;
4259 tANI_U8 sessionId; // Session ID
4260 tANI_U16 transactionId; // Transaction ID for cmd
4261 tSirMacAddr bssid; // For multi-session, for PE to locate peSession ID
4262 tSirMacAddr peerMac;
4263} tSirTdlsAddStaReq, *tpSirSmeTdlsAddStaReq ;
4264/* TDLS Response struct PE-->SME */
4265typedef struct sSirTdlsAddStaRsp
4266{
4267 tANI_U16 messageType;
4268 tANI_U16 length;
4269 tSirResultCodes statusCode;
4270 tSirMacAddr peerMac;
4271 tANI_U8 sessionId; // Session ID
4272 tANI_U16 staId ;
4273 tANI_U16 staType ;
4274 tANI_U8 ucastSig;
4275 tANI_U8 bcastSig;
4276} tSirTdlsAddStaRsp ;
4277/* TDLS Request struct SME-->PE */
4278typedef struct sSirTdlsDelStaReq
4279{
4280 tANI_U16 messageType; // eWNI_SME_TDLS_DISCOVERY_START_REQ
4281 tANI_U16 length;
4282 tANI_U8 sessionId; // Session ID
4283 tANI_U16 transactionId; // Transaction ID for cmd
4284 tSirMacAddr bssid; // For multi-session, for PE to locate peSession ID
4285 tSirMacAddr peerMac;
4286} tSirTdlsDelStaReq, *tpSirSmeTdlsDelStaReq ;
4287/* TDLS Response struct PE-->SME */
4288typedef struct sSirTdlsDelStaRsp
4289{
4290 tANI_U16 messageType;
4291 tANI_U16 length;
4292 tANI_U8 sessionId; // Session ID
4293 tSirResultCodes statusCode;
4294 tSirMacAddr peerMac;
4295 tANI_U16 staId;
4296} tSirTdlsDelStaRsp, *tpSirTdlsDelStaRsp;
4297#endif /* FEATURE_WLAN_TDLS */
4298
4299#ifdef FEATURE_WLAN_TDLS_INTERNAL
4300typedef enum tdlsListType
4301{
4302 TDLS_DIS_LIST,
4303 TDLS_SETUP_LIST
4304}eTdlsListType ;
4305
4306typedef enum tdlsStates
4307{
4308 TDLS_LINK_IDLE_STATE,
4309 TDLS_LINK_DIS_INIT_STATE,
4310 TDLS_LINK_DIS_RSP_WAIT_STATE,
4311 TDLS_DIS_REQ_PROCESS_STATE,
4312 TDLS_DIS_RSP_SENT_WAIT_STATE,
4313 TDLS_DIS_RSP_SENT_DONE_STATE,
4314 TDLS_LINK_DIS_DONE_STATE,
4315 TDLS_LINK_SETUP_START_STATE,
4316 TDLS_LINK_SETUP_WAIT_STATE,
4317 TDLS_LINK_SETUP_RSP_WAIT_STATE,
4318 TDLS_LINK_SETUP_DONE_STATE,
4319 TDLS_LINK_TEARDOWN_START_STATE,
4320 TDLS_LINK_TEARDOWN_DONE_STATE,
4321 TDLS_LINK_SETUP_STATE
4322}eSirTdlsStates ;
4323
4324typedef struct sSirTdlsPeerInfo
4325{
4326 tSirMacAddr peerMac;
4327 tANI_U8 sessionId;
4328 tANI_U8 dialog ;
4329 tSirMacCapabilityInfo capabilityInfo ;
4330 tSirMacRateSet tdlsPeerSuppRates ;
4331 tSirMacRateSet tdlsPeerExtRates ;
4332 //tDot11fIEHTCaps tdlsPeerHtCaps ;
4333 tSirMacHTCapabilityInfo tdlsPeerHtCaps ;
4334 tSirMacHTParametersInfo tdlsPeerHtParams ;
4335 tSirMacExtendedHTCapabilityInfo tdlsPeerHtExtCaps ;
4336 tANI_U8 supportedMCSSet[SIZE_OF_SUPPORTED_MCS_SET];
4337
4338 //tDot11fIEExtCapability tdlsPeerExtenCaps ;
4339 tSirMacRsnInfo tdlsPeerRsn ;
4340 tANI_U16 tdlsPeerFtIe ;
4341 tANI_U16 tdlsPeerTimeoutIntvl ;
4342 tANI_U16 tdlsPeerSuppChan ;
4343 tANI_U16 tdlsPeerSuppReguClass ;
4344 tANI_S8 tdlsPeerRssi ;
4345 tANI_U16 tdlsPeerState ;
4346 /* flags to indicate optional IE's are in */
4347 tANI_U8 ExtRatesPresent ;
4348 tANI_U8 rsnIePresent ;
4349 tANI_U8 htCapPresent ;
4350 tANI_U8 delStaNeeded ;
4351
4352} tSirTdlsPeerInfo, *tpSirSmeTdlsPeerInfo ;
4353
4354/* TDLS Request struct SME-->PE */
4355typedef struct sSirTdlsDiscoveryReq
4356{
4357 tANI_U16 messageType; // eWNI_SME_TDLS_DISCOVERY_START_REQ
4358 tANI_U16 length;
4359 tANI_U8 sessionId; // Session ID
4360 tANI_U16 transactionId; // Transaction ID for cmd
4361 tANI_U8 reqType;
4362 tANI_U8 dialog;
4363 tSirMacAddr bssid; // For multi-session, for PE to locate peSession ID
4364 tSirMacAddr peerMac;
4365} tSirTdlsDisReq, *tpSirSmeTdlsDisReq ;
4366
4367typedef struct sSirTdlsLinkSetupReq
4368{
4369 tANI_U16 messageType; // eWNI_SME_TDLS_LINK_START_REQ
4370 tANI_U16 length;
4371 tANI_U8 sessionId; // Session ID
4372 tANI_U16 transactionId; // Transaction ID for cmd
4373 tANI_U8 dialog;
4374 tSirMacAddr bssid; // For multi-session, for PE to locate peSession ID
4375 tSirMacAddr peerMac;
4376} tSirTdlsSetupReq, *tpSirSmeTdlsSetupReq ;
4377
4378typedef struct sSirTdlsTeardownReq
4379{
4380 tANI_U16 messageType; // eWNI_SME_TDLS_TEARDOWN_REQ
4381 tANI_U16 length;
4382 tANI_U8 sessionId; // Session ID
4383 tANI_U16 transactionId; // Transaction ID for cmd
4384 tSirMacAddr bssid; // For multi-session, for PE to locate peSession ID
4385 tSirMacAddr peerMac;
4386} tSirTdlsTeardownReq, *tpSirSmeTdlsTeardownReq ;
4387
4388
4389/* TDLS response struct PE-->SME */
4390typedef struct sSirTdlsDiscoveryRsp
4391{
4392 tANI_U16 messageType;
4393 tANI_U16 length;
4394 tSirResultCodes statusCode;
4395 tANI_U16 numDisSta ;
4396 tSirTdlsPeerInfo tdlsDisPeerInfo[0];
4397} tSirTdlsDisRsp, *tpSirSmeTdlsDiscoveryRsp;
4398
4399typedef struct sSirTdlsLinkSetupRsp
4400{
4401 tANI_U16 messageType;
4402 tANI_U16 length;
4403 tSirResultCodes statusCode;
4404 tSirMacAddr peerMac;
4405} tSirTdlsLinksetupRsp ;
4406
4407typedef struct sSirTdlsLinkSetupInd
4408{
4409 tANI_U16 messageType;
4410 tANI_U16 length;
4411 tSirResultCodes statusCode;
4412 tSirMacAddr peerMac;
4413} tSirTdlsLinkSetupInd ;
4414
4415
4416typedef struct sSirTdlsTeardownRsp
4417{
4418 tANI_U16 messageType;
4419 tANI_U16 length;
4420 tSirResultCodes statusCode;
4421 tSirMacAddr peerMac;
4422} tSirTdlsTeardownRsp ;
4423
4424typedef struct sSirTdlsPeerInd
4425{
4426 tANI_U16 messageType;
4427 tANI_U16 length;
4428 tSirMacAddr peerMac;
4429 tANI_U8 sessionId; // Session ID
4430 tANI_U16 staId ;
4431 tANI_U16 staType ;
4432 tANI_U8 ucastSig;
4433 tANI_U8 bcastSig;
4434} tSirTdlsPeerInd ;
4435
4436typedef struct sSirTdlsLinkEstablishInd
4437{
4438 tANI_U16 messageType;
4439 tANI_U16 length;
4440 tANI_U8 bIsResponder; /* if this is 1, self is initiator and peer is reponder */
4441 tANI_U8 linkIdenOffset; /* offset of LinkIdentifierIE.bssid[0] from ptiTemplateBuf */
4442 tANI_U8 ptiBufStatusOffset; /* offset of BufferStatus from ptiTemplateBuf */
4443 tANI_U8 ptiTemplateLen;
4444 tANI_U8 ptiTemplateBuf[64];
4445 tANI_U8 extCapability[8];
4446/* This will be part of PTI template when sent by PE
4447 tANI_U8 linkIdentifier[20];
4448*/
4449} tSirTdlsLinkEstablishInd, *tpSirTdlsLinkEstablishInd;
4450
4451typedef struct sSirTdlsLinkTeardownInd
4452{
4453 tANI_U16 messageType;
4454 tANI_U16 length;
4455 tANI_U16 staId;
4456} tSirTdlsLinkTeardownInd, *tpSirTdlsLinkTeardownInd;
4457
4458#endif /* FEATURE_WLAN_TDLS_INTERNAL */
4459
Jeff Johnson295189b2012-06-20 16:38:30 -07004460#endif /* __SIR_API_H */