blob: b297d3d45e5855acd9a933967c6fffd7346a94af [file] [log] [blame]
Jeff Johnson295189b2012-06-20 16:38:30 -07001/*
Abhishek Singh5f693202016-01-06 13:47:33 +05302 * Copyright (c) 2012-2016 The Linux Foundation. All rights reserved.
Kiet Lam0fb93dd2014-02-19 00:32:59 -08003 *
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.
Gopichand Nakkala92f07d82013-01-08 21:16:34 -080020 */
Kiet Lam0fb93dd2014-02-19 00:32:59 -080021
22/*
23 * This file was originally distributed by Qualcomm Atheros, Inc.
24 * under proprietary terms before Copyright ownership was assigned
25 * to the Linux Foundation.
26 */
27
Jeff Johnson295189b2012-06-20 16:38:30 -070028/** ------------------------------------------------------------------------- *
29 ------------------------------------------------------------------------- *
30
31
32 \file csrInsideApi.h
33
34 Define interface only used by CSR.
Jeff Johnson295189b2012-06-20 16:38:30 -070035 ========================================================================== */
36#ifndef CSR_INSIDE_API_H__
37#define CSR_INSIDE_API_H__
38
39
Anand N Sunkadb3ab97d2015-07-29 09:58:13 +053040#include <linux/version.h>
Jeff Johnson295189b2012-06-20 16:38:30 -070041#include "csrSupport.h"
42#include "smeInside.h"
43#include "vos_nvitem.h"
44
45#define CSR_PASSIVE_MAX_CHANNEL_TIME 110
46#define CSR_PASSIVE_MIN_CHANNEL_TIME 60
47
48#define CSR_ACTIVE_MAX_CHANNEL_TIME 40
49#define CSR_ACTIVE_MIN_CHANNEL_TIME 20
50
Abhishek Singhadd13582016-09-29 17:00:03 +053051#define CSR_ACTIVE_MAX_CHANNEL_TIME_ESCO_BTC 120
52#define CSR_ACTIVE_MIN_CHANNEL_TIME_ESCO_BTC 60
53
54#define CSR_ACTIVE_MIN_CHANNEL_TIME_SCO_BTC 20
55#define CSR_ACTIVE_MAX_CHANNEL_TIME_SCO_BTC 40
Kiran Kumar Lokere3527f0c2013-02-24 22:21:28 -080056
Jeff Johnson295189b2012-06-20 16:38:30 -070057#ifdef WLAN_AP_STA_CONCURRENCY
Madan Mohan Koyyalamudi4ff9cd62012-10-30 17:48:57 -070058#define CSR_PASSIVE_MAX_CHANNEL_TIME_CONC 110
59#define CSR_PASSIVE_MIN_CHANNEL_TIME_CONC 60
60
Jeff Johnson295189b2012-06-20 16:38:30 -070061#define CSR_ACTIVE_MAX_CHANNEL_TIME_CONC 27
62#define CSR_ACTIVE_MIN_CHANNEL_TIME_CONC 20
Madan Mohan Koyyalamudi4ff9cd62012-10-30 17:48:57 -070063
Madan Mohan Koyyalamudi4805fa82012-11-09 17:53:39 -080064#define CSR_REST_TIME_CONC 100
Vinay Malekal05fdc812012-12-17 13:04:30 -080065
Sudhir Sattayappa Kohallieb97d502013-05-22 23:16:42 -070066#define CSR_NUM_STA_CHAN_COMBINED_CONC 3
67#define CSR_NUM_P2P_CHAN_COMBINED_CONC 1
Jeff Johnson295189b2012-06-20 16:38:30 -070068#endif
69
70#define CSR_MAX_NUM_SUPPORTED_CHANNELS 55
71
Jeff Johnsone7245742012-09-05 17:12:55 -070072#define CSR_MAX_2_4_GHZ_SUPPORTED_CHANNELS 14
73
Deepthi Gowri50e2fa52016-03-17 15:30:53 +053074#define CSR_MAX_BSS_SUPPORT 512
Srinivas Girigowda5cecb202013-10-08 09:13:25 -070075#define SYSTEM_TIME_MSEC_TO_USEC 1000
Deepthi Gowri4480a3f2016-05-18 19:30:17 +053076#define SYSTEM_TIME_SEC_TO_MSEC 1000
Jeff Johnson295189b2012-06-20 16:38:30 -070077
78//This number minus 1 means the number of times a channel is scanned before a BSS is remvoed from
79//cache scan result
80#define CSR_AGING_COUNT 3
81//The following defines are used by palTimer
82//This is used for palTimer when request to imps fails
83#define CSR_IDLE_SCAN_WAIT_TIME (1 * PAL_TIMER_TO_SEC_UNIT) //1 second
84//This is used for palTimer when imps ps is disabled
85//This number shall not be smaller than 5-6 seconds in general because a full scan may take 3-4 seconds
86#define CSR_IDLE_SCAN_NO_PS_INTERVAL (10 * PAL_TIMER_TO_SEC_UNIT) //10 second
87#define CSR_IDLE_SCAN_NO_PS_INTERVAL_MIN (5 * PAL_TIMER_TO_SEC_UNIT)
88#define CSR_SCAN_GET_RESULT_INTERVAL (5 * PAL_TIMER_TO_SEC_UNIT) //5 seconds
Jeff Johnson295189b2012-06-20 16:38:30 -070089#define CSR_MIC_ERROR_TIMEOUT (60 * PAL_TIMER_TO_SEC_UNIT) //60 seconds
90#define CSR_TKIP_COUNTER_MEASURE_TIMEOUT (60 * PAL_TIMER_TO_SEC_UNIT) //60 seconds
91#define CSR_SCAN_RESULT_AGING_INTERVAL (5 * PAL_TIMER_TO_SEC_UNIT) //5 seconds
92//the following defines are NOT used by palTimer
93#define CSR_SCAN_AGING_TIME_NOT_CONNECT_NO_PS 50 //50 seconds
94#define CSR_SCAN_AGING_TIME_NOT_CONNECT_W_PS 300 //300 seconds
95#define CSR_SCAN_AGING_TIME_CONNECT_NO_PS 150 //150 seconds
96#define CSR_SCAN_AGING_TIME_CONNECT_W_PS 600 //600 seconds
97#define CSR_JOIN_FAILURE_TIMEOUT_DEFAULT ( 3000 )
Jeff Johnsone7245742012-09-05 17:12:55 -070098#define CSR_JOIN_FAILURE_TIMEOUT_MIN (1000) //minimal value
Jeff Johnson295189b2012-06-20 16:38:30 -070099//These are going against the signed RSSI (tANI_S8) so it is between -+127
100#define CSR_BEST_RSSI_VALUE (-30) //RSSI >= this is in CAT4
101#define CSR_DEFAULT_RSSI_DB_GAP 30 //every 30 dbm for one category
102#define CSR_BSS_CAP_VALUE_NONE 0 //not much value
103#define CSR_BSS_CAP_VALUE_HT 2
104#define CSR_BSS_CAP_VALUE_WMM 1
105#define CSR_BSS_CAP_VALUE_UAPSD 1
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -0800106#if defined (WLAN_FEATURE_VOWIFI_11R) || defined (FEATURE_WLAN_ESE) || defined(FEATURE_WLAN_LFR)
Madan Mohan Koyyalamudid5026072012-11-30 14:56:21 -0800107#define CSR_BSS_CAP_VALUE_5GHZ 1
108#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700109#define CSR_DEFAULT_ROAMING_TIME 10 //10 seconds
110#define CSR_ROAM_MIN(X, Y) ((X) < (Y) ? (X) : (Y))
111#define CSR_ROAM_MAX(X, Y) ((X) > (Y) ? (X) : (Y))
112
113#ifdef FEATURE_WLAN_BTAMP_UT_RF
114#define CSR_JOIN_MAX_RETRY_COUNT 10
115#define CSR_JOIN_RETRY_TIMEOUT_PERIOD ( 1 * PAL_TIMER_TO_SEC_UNIT ) // 1 second
116#endif
117
Kapil Guptab3a981b2016-06-26 13:36:51 +0530118#ifdef WLAN_FEATURE_ROAM_SCAN_OFFLOAD
119#define ROAMING_RSSI_WEIGHT 50
120#define MIN_RSSI (-100)
121#define MAX_RSSI 0
122#define ROAM_AP_COUNT_WEIGHT 50
123#define ROAM_MAX_COUNT 30
124#define ROAM_MIN_COUNT 0
125#define ROAM_MAX_WEIGHT 100
126
127#define RSSI_WEIGHTAGE 25
128#define HT_CAPABILITY_WEIGHTAGE 10
129#define VHT_CAP_WEIGHTAGE 6
130#define BEAMFORMING_CAP_WEIGHTAGE 2
131#define CHAN_WIDTH_WEIGHTAGE 10
132#define CHAN_BAND_WEIGHTAGE 5
133#define WMM_WEIGHTAGE 2
134#define CCA_WEIGHTAGE 10
135#define OTHER_AP_WEIGHT 30
136
137#define MAX_AP_LOAD 255
138#define PENALTY_TIMEOUT (30 * 60 * 1000)
139#define PENALTY_REMAINING_SCORE (7)
140#define PENALTY_TOTAL_SCORE (10)
141#define PER_EXCELENT_RSSI -40
142#define PER_GOOD_RSSI -55
143#define PER_POOR_RSSI -65
Kapil Guptaa040e772016-09-15 19:03:45 +0530144#define PER_BAD_RSSI -80
Kapil Guptab3a981b2016-06-26 13:36:51 +0530145#define PER_ROAM_EXCELLENT_RSSI_WEIGHT 100
146#define PER_ROAM_GOOD_RSSI_WEIGHT 80
147#define PER_ROAM_BAD_RSSI_WEIGHT 60
148#define PER_ROAM_MAX_WEIGHT 100
149#define PER_ROAM_80MHZ 100
150#define PER_ROAM_40MHZ 70
151#define PER_ROAM_20MHZ 30
152#define PER_ROAM_PENALTY (3/10)
153#define PER_ROAM_MAX_BSS_SCORE 10000
154#endif
155
Jeff Johnson295189b2012-06-20 16:38:30 -0700156typedef enum
157{
158 eCsrNextScanNothing,
159 eCsrNextLostLinkScan1Success,
160 eCsrNextLostLinkScan1Failed,
161 eCsrNextLostLinkScan2Success,
162 eCsrNextLostLinkScan2Failed,
163 eCsrNextLostLinkScan3Success,
164 eCsrNexteScanForSsidSuccess,
165 eCsrNextLostLinkScan3Failed,
166 eCsrNext11dScan1Failure,
167 eCsrNext11dScan1Success,
168 eCsrNext11dScan2Failure,
169 eCsrNext11dScan2Success,
170 eCsrNext11dScanComplete,
171 eCsrNexteScanForSsidFailure,
172 eCsrNextIdleScanComplete,
173 eCsrNextCapChangeScanComplete,
174
175}eCsrScanCompleteNextCommand;
176
177typedef enum
178{
179 eCsrJoinSuccess,
180 eCsrJoinFailure,
181 eCsrReassocSuccess,
182 eCsrReassocFailure,
183 eCsrNothingToJoin,
184 eCsrStartBssSuccess,
185 eCsrStartBssFailure,
186 eCsrSilentlyStopRoaming,
187 eCsrSilentlyStopRoamingSaveState,
188 eCsrJoinWdsFailure,
Jeff Johnsone7245742012-09-05 17:12:55 -0700189 eCsrJoinFailureDueToConcurrency,
Jeff Johnson295189b2012-06-20 16:38:30 -0700190
191}eCsrRoamCompleteResult;
192
193typedef struct tagScanReqParam
194{
195 tANI_U8 bReturnAfter1stMatch;
196 tANI_U8 fUniqueResult;
197 tANI_U8 freshScan;
198 tANI_U8 hiddenSsid;
199 tANI_U8 reserved;
200}tScanReqParam;
201
202typedef struct tagCsrScanResult
203{
204 tListElem Link;
205 tANI_S32 AgingCount; //This BSS is removed when it reaches 0 or less
206 tANI_U32 preferValue; //The bigger the number, the better the BSS. This value override capValue
207 tANI_U32 capValue; //The biggger the better. This value is in use only if we have equal preferValue
208 //This member must be the last in the structure because the end of tSirBssDescription (inside) is an
209 // array with nonknown size at this time
210
211 eCsrEncryptionType ucEncryptionType; //Preferred Encryption type that matched with profile.
212 eCsrEncryptionType mcEncryptionType;
213 eCsrAuthType authType; //Preferred auth type that matched with the profile.
Kapil Guptab3a981b2016-06-26 13:36:51 +0530214#ifdef WLAN_FEATURE_ROAM_SCAN_OFFLOAD
215 int congestionScore;
216#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700217 tCsrScanResultInfo Result;
218}tCsrScanResult;
219
220typedef struct
221{
222 tDblLinkList List;
223 tListElem *pCurEntry;
224}tScanResultList;
225
226
227
228
229#define CSR_IS_ROAM_REASON( pCmd, reason ) ( (reason) == (pCmd)->roamCmd.roamReason )
230#define CSR_IS_BETTER_PREFER_VALUE(v1, v2) ((v1) > (v2))
231#define CSR_IS_EQUAL_PREFER_VALUE(v1, v2) ((v1) == (v2))
232#define CSR_IS_BETTER_CAP_VALUE(v1, v2) ((v1) > (v2))
233#define CSR_IS_ENC_TYPE_STATIC( encType ) ( ( eCSR_ENCRYPT_TYPE_NONE == (encType) ) || \
234 ( eCSR_ENCRYPT_TYPE_WEP40_STATICKEY == (encType) ) || \
235 ( eCSR_ENCRYPT_TYPE_WEP104_STATICKEY == (encType) ) )
236#define CSR_IS_WAIT_FOR_KEY( pMac, sessionId ) ( CSR_IS_ROAM_JOINED( pMac, sessionId ) && CSR_IS_ROAM_SUBSTATE_WAITFORKEY( pMac, sessionId ) )
237//WIFI has a test case for not using HT rates with TKIP as encryption
238//We may need to add WEP but for now, TKIP only.
239
240#define CSR_IS_11n_ALLOWED( encType ) (( eCSR_ENCRYPT_TYPE_TKIP != (encType) ) && \
241 ( eCSR_ENCRYPT_TYPE_WEP40_STATICKEY != (encType) ) && \
242 ( eCSR_ENCRYPT_TYPE_WEP104_STATICKEY != (encType) ) && \
243 ( eCSR_ENCRYPT_TYPE_WEP40 != (encType) ) && \
244 ( eCSR_ENCRYPT_TYPE_WEP104 != (encType) ) )
245
Abhishek Singhf4669da2014-05-26 15:07:49 +0530246#define CSR_IS_DISCONNECT_COMMAND(pCommand) ( ( eSmeCommandRoam == (pCommand)->command ) &&\
247 ( ( eCsrForcedDisassoc == (pCommand)->u.roamCmd.roamReason ) ||\
248 ( eCsrForcedDeauth == (pCommand)->u.roamCmd.roamReason ) ||\
249 ( eCsrSmeIssuedDisassocForHandoff ==\
250 (pCommand)->u.roamCmd.roamReason ) ||\
251 ( eCsrForcedDisassocMICFailure ==\
252 (pCommand)->u.roamCmd.roamReason ) ) )
253
Jeff Johnson295189b2012-06-20 16:38:30 -0700254eCsrRoamState csrRoamStateChange( tpAniSirGlobal pMac, eCsrRoamState NewRoamState, tANI_U8 sessionId);
255eHalStatus csrScanningStateMsgProcessor( tpAniSirGlobal pMac, void *pMsgBuf );
256void csrRoamingStateMsgProcessor( tpAniSirGlobal pMac, void *pMsgBuf );
257void csrRoamJoinedStateMsgProcessor( tpAniSirGlobal pMac, void *pMsgBuf );
258tANI_BOOLEAN csrScanComplete( tpAniSirGlobal pMac, tSirSmeScanRsp *pScanRsp );
259void csrReleaseCommandRoam(tpAniSirGlobal pMac, tSmeCmd *pCommand);
260void csrReleaseCommandScan(tpAniSirGlobal pMac, tSmeCmd *pCommand);
261void csrReleaseCommandWmStatusChange(tpAniSirGlobal pMac, tSmeCmd *pCommand);
262//pIes2 can be NULL
263tANI_BOOLEAN csrIsDuplicateBssDescription( tpAniSirGlobal pMac, tSirBssDescription *pSirBssDesc1,
Tushnim Bhattacharyya5128d752013-06-26 23:23:18 -0700264 tSirBssDescription *pSirBssDesc2, tDot11fBeaconIEs *pIes2, tANI_BOOLEAN fForced );
Jeff Johnson295189b2012-06-20 16:38:30 -0700265eHalStatus csrRoamSaveConnectedBssDesc( tpAniSirGlobal pMac, tANI_U32 sessionId, tSirBssDescription *pBssDesc );
266tANI_BOOLEAN csrIsNetworkTypeEqual( tSirBssDescription *pSirBssDesc1, tSirBssDescription *pSirBssDesc2 );
267eHalStatus csrScanSmeScanResponse( tpAniSirGlobal pMac, void *pMsgBuf );
268/*
269 Prepare a filter base on a profile for parsing the scan results.
270 Upon successful return, caller MUST call csrFreeScanFilter on
271 pScanFilter when it is done with the filter.
272*/
273eHalStatus csrRoamPrepareFilterFromProfile(tpAniSirGlobal pMac, tCsrRoamProfile *pProfile, tCsrScanResultFilter *pScanFilter);
274eHalStatus csrRoamCopyProfile(tpAniSirGlobal pMac, tCsrRoamProfile *pDstProfile, tCsrRoamProfile *pSrcProfile);
275eHalStatus csrRoamStart(tpAniSirGlobal pMac);
276void csrRoamStop(tpAniSirGlobal pMac, tANI_U32 sessionId);
277void csrRoamStartMICFailureTimer(tpAniSirGlobal pMac);
278void csrRoamStopMICFailureTimer(tpAniSirGlobal pMac);
279void csrRoamStartTKIPCounterMeasureTimer(tpAniSirGlobal pMac);
280void csrRoamStopTKIPCounterMeasureTimer(tpAniSirGlobal pMac);
281
282eHalStatus csrScanOpen(tpAniSirGlobal pMac);
283eHalStatus csrScanClose(tpAniSirGlobal pMac);
284eHalStatus csrScanRequestLostLink1( tpAniSirGlobal pMac, tANI_U32 sessionId );
285eHalStatus csrScanRequestLostLink2( tpAniSirGlobal pMac, tANI_U32 sessionId );
286eHalStatus csrScanRequestLostLink3( tpAniSirGlobal pMac, tANI_U32 sessionId );
287eHalStatus csrScanHandleFailedLostlink1(tpAniSirGlobal pMac, tANI_U32 sessionId);
288eHalStatus csrScanHandleFailedLostlink2(tpAniSirGlobal pMac, tANI_U32 sessionId);
289eHalStatus csrScanHandleFailedLostlink3(tpAniSirGlobal pMac, tANI_U32 sessionId);
Madan Mohan Koyyalamudica43cdf2012-09-24 13:15:49 -0700290tCsrScanResult *csrScanAppendBssDescription( tpAniSirGlobal pMac,
Jeff Johnson295189b2012-06-20 16:38:30 -0700291 tSirBssDescription *pSirBssDescription,
Tushnim Bhattacharyya5128d752013-06-26 23:23:18 -0700292 tDot11fBeaconIEs *pIes, tANI_BOOLEAN fForced);
Jeff Johnson295189b2012-06-20 16:38:30 -0700293void csrScanCallCallback(tpAniSirGlobal pMac, tSmeCmd *pCommand, eCsrScanStatus scanStatus);
294eHalStatus csrScanCopyRequest(tpAniSirGlobal pMac, tCsrScanRequest *pDstReq, tCsrScanRequest *pSrcReq);
295eHalStatus csrScanFreeRequest(tpAniSirGlobal pMac, tCsrScanRequest *pReq);
Madan Mohan Koyyalamudica43cdf2012-09-24 13:15:49 -0700296eHalStatus csrScanCopyResultList(tpAniSirGlobal pMac, tScanResultHandle hIn, tScanResultHandle *phResult);
Jeff Johnson295189b2012-06-20 16:38:30 -0700297void csrInitBGScanChannelList(tpAniSirGlobal pMac);
Varun Reddy Yeturucc661d22013-05-20 11:47:10 -0700298eHalStatus csrScanForSSID(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamProfile *pProfile, tANI_U32 roamId, tANI_BOOLEAN notify);
Jeff Johnson295189b2012-06-20 16:38:30 -0700299eHalStatus csrScanForCapabilityChange(tpAniSirGlobal pMac, tSirSmeApNewCaps *pNewCaps);
300eHalStatus csrScanStartGetResultTimer(tpAniSirGlobal pMac);
301eHalStatus csrScanStopGetResultTimer(tpAniSirGlobal pMac);
Jeff Johnson295189b2012-06-20 16:38:30 -0700302eHalStatus csrScanBGScanEnable(tpAniSirGlobal pMac);
303eHalStatus csrScanStartIdleScanTimer(tpAniSirGlobal pMac, tANI_U32 interval);
304eHalStatus csrScanStopIdleScanTimer(tpAniSirGlobal pMac);
305eHalStatus csrScanStartIdleScan(tpAniSirGlobal pMac);
306//Param: pTimeInterval -- Caller allocated memory in return, if failed, to specify the nxt time interval for
307//idle scan timer interval
308//Return: Not success -- meaning it cannot start IMPS, caller needs to start a timer for idle scan
309eHalStatus csrScanTriggerIdleScan(tpAniSirGlobal pMac, tANI_U32 *pTimeInterval);
310void csrScanCancelIdleScan(tpAniSirGlobal pMac);
311void csrScanStopTimers(tpAniSirGlobal pMac);
312//This function will remove scan commands that are not related to association or IBSS
313tANI_BOOLEAN csrScanRemoveNotRoamingScanCommand(tpAniSirGlobal pMac);
314//To remove fresh scan commands from the pending queue
315tANI_BOOLEAN csrScanRemoveFreshScanCommand(tpAniSirGlobal pMac, tANI_U8 sessionId);
c_hpothua3d45d52015-01-05 14:11:17 +0530316tSirAbortScanStatus csrScanAbortMacScan(tpAniSirGlobal pMac,
317 tANI_U8 sessionId,
318 eCsrAbortReason reason);
Jeff Johnson295189b2012-06-20 16:38:30 -0700319void csrRemoveCmdFromPendingList(tpAniSirGlobal pMac, tDblLinkList *pList,
320 eSmeCommandType commandType );
Madan Mohan Koyyalamudiff3a7152013-06-13 14:47:55 +0530321void csrRemoveCmdWithSessionIdFromPendingList(tpAniSirGlobal pMac,
322 tANI_U8 sessionId,
323 tDblLinkList *pList,
324 eSmeCommandType commandType);
325eHalStatus csrScanAbortMacScanNotForConnect(tpAniSirGlobal pMac,
326 tANI_U8 sessionId);
Madan Mohan Koyyalamudide1b5bc2013-07-12 00:56:04 +0530327eHalStatus csrScanGetScanChannelInfo(tpAniSirGlobal pMac, tANI_U8 sessionId);
Abhishek Singhdc2bfd42014-06-19 17:59:05 +0530328eHalStatus csrScanAbortScanForSSID(tpAniSirGlobal pMac, tANI_U32 sessionId);
329void csrRemoveScanForSSIDFromPendingList(tpAniSirGlobal pMac, tDblLinkList *pList, tANI_U32 sessionId);
330
Jeff Johnson295189b2012-06-20 16:38:30 -0700331//To age out scan results base. tSmeGetScanChnRsp is a pointer returned by LIM that
332//has the information regarding scanned channels.
333//The logic is that whenever CSR add a BSS to scan result, it set the age count to
334//a value. This function deduct the age count if channelId matches the BSS' channelId
335//The BSS is remove if the count reaches 0.
Madan Mohan Koyyalamudica43cdf2012-09-24 13:15:49 -0700336eHalStatus csrScanAgeResults(tpAniSirGlobal pMac, tSmeGetScanChnRsp *pScanChnInfo);
Jeff Johnson295189b2012-06-20 16:38:30 -0700337
Abhishek Singhc640dbb2015-06-08 10:54:17 +0530338eHalStatus csrIbssAgeBss(tpAniSirGlobal pMac);
339
Jeff Johnson295189b2012-06-20 16:38:30 -0700340//If fForce is TRUE we will save the new String that is learn't.
341//Typically it will be true in case of Join or user initiated ioctl
Chandrasekaran, Manishekar90c49322014-06-24 13:26:14 +0530342tANI_BOOLEAN csrLearnCountryInformation( tpAniSirGlobal pMac, tSirBssDescription *pSirBssDesc,
343 tDot11fBeaconIEs *pIes, tANI_BOOLEAN fForce );
Madan Mohan Koyyalamudica43cdf2012-09-24 13:15:49 -0700344void csrApplyCountryInformation( tpAniSirGlobal pMac, tANI_BOOLEAN fForce );
Jeff Johnson295189b2012-06-20 16:38:30 -0700345void csrSetCfgScanControlList( tpAniSirGlobal pMac, tANI_U8 *countryCode, tCsrChannel *pChannelList );
346void csrReinitScanCmd(tpAniSirGlobal pMac, tSmeCmd *pCommand);
347void csrFreeScanResultEntry( tpAniSirGlobal pMac, tCsrScanResult *pResult );
348
349eHalStatus csrRoamCallCallback(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamInfo *pRoamInfo,
350 tANI_U32 roamId, eRoamCmdStatus u1, eCsrRoamResult u2);
351eHalStatus csrRoamIssueConnect(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamProfile *pProfile,
352 tScanResultHandle hBSSList,
353 eCsrRoamReason reason, tANI_U32 roamId,
354 tANI_BOOLEAN fImediate, tANI_BOOLEAN fClearScan);
355eHalStatus csrRoamIssueReassoc(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamProfile *pProfile,
356 tCsrRoamModifyProfileFields *pModProfileFields,
357 eCsrRoamReason reason, tANI_U32 roamId, tANI_BOOLEAN fImediate);
358void csrRoamComplete( tpAniSirGlobal pMac, eCsrRoamCompleteResult Result, void *Context );
359eHalStatus csrRoamIssueSetContextReq( tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrEncryptionType EncryptType,
360 tSirBssDescription *pBssDescription,
361 tSirMacAddr *bssId, tANI_BOOLEAN addKey,
362 tANI_BOOLEAN fUnicast, tAniKeyDirection aniKeyDirection,
363 tANI_U8 keyId, tANI_U16 keyLength,
364 tANI_U8 *pKey, tANI_U8 paeRole );
365eHalStatus csrRoamProcessDisassocDeauth( tpAniSirGlobal pMac, tSmeCmd *pCommand,
366 tANI_BOOLEAN fDisassoc, tANI_BOOLEAN fMICFailure );
367eHalStatus csrRoamSaveConnectedInfomation(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamProfile *pProfile,
368 tSirBssDescription *pSirBssDesc, tDot11fBeaconIEs *pIes);
369void csrRoamCheckForLinkStatusChange( tpAniSirGlobal pMac, tSirSmeRsp *pSirMsg );
370void csrRoamStatsRspProcessor(tpAniSirGlobal pMac, tSirSmeRsp *pSirMsg);
371eHalStatus csrRoamIssueStartBss( tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamStartBssParams *pParam,
372 tCsrRoamProfile *pProfile, tSirBssDescription *pBssDesc, tANI_U32 roamId );
373eHalStatus csrRoamIssueStopBss( tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrRoamSubState NewSubstate );
374tANI_BOOLEAN csrIsSameProfile(tpAniSirGlobal pMac, tCsrRoamConnectedProfile *pProfile1, tCsrRoamProfile *pProfile2);
375tANI_BOOLEAN csrIsRoamCommandWaiting(tpAniSirGlobal pMac);
376tANI_BOOLEAN csrIsRoamCommandWaitingForSession(tpAniSirGlobal pMac, tANI_U32 sessionId);
377tANI_BOOLEAN csrIsScanForRoamCommandActive( tpAniSirGlobal pMac );
378eRoamCmdStatus csrGetRoamCompleteStatus(tpAniSirGlobal pMac, tANI_U32 sessionId);
379//pBand can be NULL if caller doesn't need to get it
380//eCsrCfgDot11Mode csrRoamGetPhyModeBandForBss( tpAniSirGlobal pMac, eCsrPhyMode phyModeIn, tANI_U8 operationChn, eCsrBand *pBand );
381eHalStatus csrRoamIssueDisassociateCmd( tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrRoamDisconnectReason reason );
382eHalStatus csrRoamDisconnectInternal(tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrRoamDisconnectReason reason);
383//pCommand may be NULL
384void csrRoamRemoveDuplicateCommand(tpAniSirGlobal pMac, tANI_U32 sessionId, tSmeCmd *pCommand, eCsrRoamReason eRoamReason);
385
386eHalStatus csrSendJoinReqMsg( tpAniSirGlobal pMac, tANI_U32 sessionId, tSirBssDescription *pBssDescription,
Srinivas Girigowdac16730e2013-01-16 13:39:39 -0800387 tCsrRoamProfile *pProfile, tDot11fBeaconIEs *pIes, tANI_U16 messageType );
Jeff Johnson295189b2012-06-20 16:38:30 -0700388eHalStatus csrSendMBDisassocReqMsg( tpAniSirGlobal pMac, tANI_U32 sessionId, tSirMacAddr bssId, tANI_U16 reasonCode );
389eHalStatus csrSendMBDeauthReqMsg( tpAniSirGlobal pMac, tANI_U32 sessionId, tSirMacAddr bssId, tANI_U16 reasonCode );
390eHalStatus csrSendMBDisassocCnfMsg( tpAniSirGlobal pMac, tpSirSmeDisassocInd pDisassocInd );
391eHalStatus csrSendMBDeauthCnfMsg( tpAniSirGlobal pMac, tpSirSmeDeauthInd pDeauthInd );
392eHalStatus csrSendAssocCnfMsg( tpAniSirGlobal pMac, tpSirSmeAssocInd pAssocInd, eHalStatus status );
Jeff Johnson295189b2012-06-20 16:38:30 -0700393eHalStatus csrSendAssocIndToUpperLayerCnfMsg( tpAniSirGlobal pMac, tpSirSmeAssocInd pAssocInd, eHalStatus Halstatus, tANI_U8 sessionId );
Jeff Johnson295189b2012-06-20 16:38:30 -0700394eHalStatus csrSendMBStartBssReqMsg( tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrRoamBssType bssType,
395 tCsrRoamStartBssParams *pParam, tSirBssDescription *pBssDesc );
396eHalStatus csrSendMBStopBssReqMsg( tpAniSirGlobal pMac, tANI_U32 sessionId );
Jeff Johnson295189b2012-06-20 16:38:30 -0700397
398tANI_BOOLEAN csrIsMacAddressEqual( tpAniSirGlobal pMac, tCsrBssid *pMacAddr1, tCsrBssid *pMacAddr2 );
399//Caller should put the BSS' ssid to fiedl bssSsid when comparing SSID for a BSS.
400tANI_BOOLEAN csrIsSsidMatch( tpAniSirGlobal pMac, tANI_U8 *ssid1, tANI_U8 ssid1Len, tANI_U8 *bssSsid,
401 tANI_U8 bssSsidLen, tANI_BOOLEAN fSsidRequired );
402tANI_BOOLEAN csrIsPhyModeMatch( tpAniSirGlobal pMac, tANI_U32 phyMode,
403 tSirBssDescription *pSirBssDesc, tCsrRoamProfile *pProfile,
404 eCsrCfgDot11Mode *pReturnCfgDot11Mode,
405 tDot11fBeaconIEs *pIes);
406tANI_BOOLEAN csrRoamIsChannelValid( tpAniSirGlobal pMac, tANI_U8 channel );
407
408//pNumChan is a caller allocated space with the sizeof pChannels
409eHalStatus csrGetCfgValidChannels(tpAniSirGlobal pMac, tANI_U8 *pChannels, tANI_U32 *pNumChan);
410void csrRoamCcmCfgSetCallback(tHalHandle hHal, tANI_S32 result);
411void csrScanCcmCfgSetCallback(tHalHandle hHal, tANI_S32 result);
412
Kiran4a17ebe2013-01-31 10:43:43 -0800413tPowerdBm csrGetCfgMaxTxPower (tpAniSirGlobal pMac, tANI_U8 channel);
414
Jeff Johnson295189b2012-06-20 16:38:30 -0700415//To free the last roaming profile
416void csrFreeRoamProfile(tpAniSirGlobal pMac, tANI_U32 sessionId);
417void csrFreeConnectBssDesc(tpAniSirGlobal pMac, tANI_U32 sessionId);
418eHalStatus csrMoveBssToHeadFromBSSID(tpAniSirGlobal pMac, tCsrBssid *bssid, tScanResultHandle hScanResult);
419tANI_BOOLEAN csrCheckPSReady(void *pv);
420void csrFullPowerCallback(void *pv, eHalStatus status);
421//to free memory allocated inside the profile structure
422void csrReleaseProfile(tpAniSirGlobal pMac, tCsrRoamProfile *pProfile);
423//To free memory allocated inside scanFilter
424void csrFreeScanFilter(tpAniSirGlobal pMac, tCsrScanResultFilter *pScanFilter);
Jeff Johnson295189b2012-06-20 16:38:30 -0700425eCsrCfgDot11Mode csrGetCfgDot11ModeFromCsrPhyMode(tCsrRoamProfile *pProfile, eCsrPhyMode phyMode, tANI_BOOLEAN fProprietary);
Jeff Johnson295189b2012-06-20 16:38:30 -0700426tANI_U32 csrTranslateToWNICfgDot11Mode(tpAniSirGlobal pMac, eCsrCfgDot11Mode csrDot11Mode);
427void csrSaveChannelPowerForBand( tpAniSirGlobal pMac, tANI_BOOLEAN fPopulate5GBand );
Gopichand Nakkalab9185f22012-12-21 08:03:42 -0800428void csrApplyChannelPowerCountryInfo( tpAniSirGlobal pMac, tCsrChannel *pChannelList, tANI_U8 *countryCode, tANI_BOOLEAN updateRiva);
Jeff Johnsone7245742012-09-05 17:12:55 -0700429void csrApplyPower2Current( tpAniSirGlobal pMac );
Srinivas Girigowda41c7c5f2013-10-21 19:01:38 -0700430void csrAssignRssiForCategory(tpAniSirGlobal pMac, tANI_S8 bestApRssi, tANI_U8 catOffset);
Jeff Johnson295189b2012-06-20 16:38:30 -0700431tANI_BOOLEAN csrIsMacAddressZero( tpAniSirGlobal pMac, tCsrBssid *pMacAddr );
432tANI_BOOLEAN csrIsMacAddressBroadcast( tpAniSirGlobal pMac, tCsrBssid *pMacAddr );
Madan Mohan Koyyalamudica43cdf2012-09-24 13:15:49 -0700433eHalStatus csrRoamRemoveConnectedBssFromScanCache(tpAniSirGlobal pMac, tCsrRoamConnectedProfile *pConnProfile);
Jeff Johnson295189b2012-06-20 16:38:30 -0700434eHalStatus csrRoamStartRoaming(tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrRoamingReason roamingReason);
435//return a boolean to indicate whether roaming completed or continue.
436tANI_BOOLEAN csrRoamCompleteRoaming(tpAniSirGlobal pMac, tANI_U32 sessionId,
437 tANI_BOOLEAN fForce, eCsrRoamResult roamResult);
438void csrRoamCompletion(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamInfo *pRoamInfo, tSmeCmd *pCommand, eCsrRoamResult roamResult, tANI_BOOLEAN fSuccess);
439void csrRoamCancelRoaming(tpAniSirGlobal pMac, tANI_U32 sessionId);
Gopichand Nakkalab9185f22012-12-21 08:03:42 -0800440void csrResetCountryInformation( tpAniSirGlobal pMac, tANI_BOOLEAN fForce, tANI_BOOLEAN updateRiva );
Jeff Johnson295189b2012-06-20 16:38:30 -0700441void csrResetPMKIDCandidateList( tpAniSirGlobal pMac, tANI_U32 sessionId );
442#ifdef FEATURE_WLAN_WAPI
443void csrResetBKIDCandidateList( tpAniSirGlobal pMac, tANI_U32 sessionId );
444#endif /* FEATURE_WLAN_WAPI */
Jeff Johnsone7245742012-09-05 17:12:55 -0700445eHalStatus csrSaveToChannelPower2G_5G( tpAniSirGlobal pMac, tANI_U32 tableSize, tSirMacChanInfo *channelTable );
Jeff Johnson295189b2012-06-20 16:38:30 -0700446//Get the list of the base channels to scan for passively 11d info
447eHalStatus csrScanGetSupportedChannels( tpAniSirGlobal pMac );
448//To check whether a country code matches the one in the IE
449//Only check the first two characters, ignoring in/outdoor
450//pCountry -- caller allocated buffer contain the country code that is checking against
451//the one in pIes. It can be NULL.
452//caller must provide pIes, it cannot be NULL
453//This function always return TRUE if 11d support is not turned on.
454//pIes cannot be NULL
455tANI_BOOLEAN csrMatchCountryCode( tpAniSirGlobal pMac, tANI_U8 *pCountry, tDot11fBeaconIEs *pIes );
456eHalStatus csrRoamSetKey( tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamSetKey *pSetKey, tANI_U32 roamId );
Kiran Kumar Lokere0ad5cd32013-06-25 11:26:22 -0700457eHalStatus csrRoamOpenSession(tpAniSirGlobal pMac,
458 csrRoamCompleteCallback callback,
459 void *pContext, tANI_U8 *pSelfMacAddr,
460 tANI_U8 *pbSessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -0700461//fSync: TRUE means cleanupneeds to handle synchronously.
462eHalStatus csrRoamCloseSession( tpAniSirGlobal pMac, tANI_U32 sessionId,
mukul sharmabab477d2015-06-11 17:14:55 +0530463 tANI_BOOLEAN fSync, tANI_U8 bPurgeList,
Jeff Johnson295189b2012-06-20 16:38:30 -0700464 csrRoamSessionCloseCallback callback,
465 void *pContext );
Abhishek Singhdeb782f2016-04-28 11:44:29 +0530466void csrPurgeSmeCmdList(tpAniSirGlobal pMac, tANI_U32 sessionId,
467 bool flush_all);
Jeff Johnson295189b2012-06-20 16:38:30 -0700468void csrCleanupSession(tpAniSirGlobal pMac, tANI_U32 sessionId);
469eHalStatus csrRoamGetSessionIdFromBSSID( tpAniSirGlobal pMac, tCsrBssid *bssid, tANI_U32 *pSessionId );
470eCsrCfgDot11Mode csrFindBestPhyMode( tpAniSirGlobal pMac, tANI_U32 phyMode );
471
472/* ---------------------------------------------------------------------------
473 \fn csrScanEnable
474 \brief Enable the scanning feature of CSR. It must be called before any scan request can be performed.
475 \param tHalHandle - HAL context handle
476 \return eHalStatus
477 -------------------------------------------------------------------------------*/
478eHalStatus csrScanEnable(tpAniSirGlobal);
479
480/* ---------------------------------------------------------------------------
481 \fn csrScanDisable
482 \brief Disableing the scanning feature of CSR. After this function return success, no scan is performed until
483a successfull to csrScanEnable
484 \param tHalHandle - HAL context handle
485 \return eHalStatus
486 -------------------------------------------------------------------------------*/
487eHalStatus csrScanDisable(tpAniSirGlobal);
488/* ---------------------------------------------------------------------------
489 \fn csrScanRequest
490 \brief Request a 11d or full scan.
491 \param pScanRequestID - pointer to an object to get back the request ID
492 \param callback - a callback function that scan calls upon finish, will not be called if csrScanRequest returns error
493 \param pContext - a pointer passed in for the callback
494 \return eHalStatus
495 -------------------------------------------------------------------------------*/
496eHalStatus csrScanRequest(tpAniSirGlobal, tANI_U16, tCsrScanRequest *,
497 tANI_U32 *pScanRequestID, csrScanCompleteCallback callback,
498 void *pContext);
499
500/* ---------------------------------------------------------------------------
501 \fn csrScanAbort
502 \brief If a scan request is abort, the scan complete callback will be called first before csrScanAbort returns.
503 \param pScanRequestID - The request ID returned from csrScanRequest
504 \return eHalStatus
505 -------------------------------------------------------------------------------*/
506eHalStatus csrScanAbort(tpAniSirGlobal, tANI_U32 scanRequestID);
507
508eHalStatus csrScanSetBGScanparams(tpAniSirGlobal, tCsrBGScanRequest *);
509eHalStatus csrScanBGScanAbort(tpAniSirGlobal);
510
511/* ---------------------------------------------------------------------------
512 \fn csrScanGetResult
513 \brief Return scan results.
514 \param pFilter - If pFilter is NULL, all cached results are returned
515 \param phResult - an object for the result.
516 \return eHalStatus
517 -------------------------------------------------------------------------------*/
Madan Mohan Koyyalamudica43cdf2012-09-24 13:15:49 -0700518eHalStatus csrScanGetResult(tpAniSirGlobal, tCsrScanResultFilter *pFilter, tScanResultHandle *phResult);
Jeff Johnson295189b2012-06-20 16:38:30 -0700519
Mukul Sharma9e4e0f92015-02-13 18:45:20 +0530520#ifdef FEATURE_WLAN_LFR
521/* ---------------------------------------------------------------------------
522 \fn csrAddChannelToOccupiedChannelList
523 \brief Add channel no given by fast reassoc cmd into occ chn list
524 \param channel - channel no passed by fast reassoc cmd
525 \return void
526 -------------------------------------------------------------------------------*/
527void csrAddChannelToOccupiedChannelList(tpAniSirGlobal pMac, tANI_U8 channel);
528#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700529/* ---------------------------------------------------------------------------
530 \fn csrScanFlushResult
531 \brief Clear scan results.
532 \return eHalStatus
533 -------------------------------------------------------------------------------*/
Madan Mohan Koyyalamudica43cdf2012-09-24 13:15:49 -0700534eHalStatus csrScanFlushResult(tpAniSirGlobal);
Srinivas, Dasari42bf7702014-02-07 11:29:53 +0530535/* ---------------------------------------------------------------------------
536 * \fn csrScanFilterResults
537 * \brief Filter scan results based on valid channel list.
538 * \return eHalStatus
539 *-------------------------------------------------------------------------------
540 */
541eHalStatus csrScanFilterResults(tpAniSirGlobal pMac);
542
Padma, Santhosh Kumar778d8382015-03-04 17:41:22 +0530543/* ---------------------------------------------------------------------------
544 * \fn csrScanFilterDFSResults
545 * \brief Filter BSSIDs on DFS channels from the scan results.
546 * \return eHalStatus
547 *-------------------------------------------------------------------------------
548 */
549eHalStatus csrScanFilterDFSResults(tpAniSirGlobal pMac);
550
Madan Mohan Koyyalamudi5850f312012-11-27 19:00:25 +0530551eHalStatus csrScanFlushSelectiveResult(tpAniSirGlobal, v_BOOL_t flushP2P);
Mukul Sharma20aa6582014-08-07 21:36:12 +0530552
553eHalStatus csrScanFlushSelectiveResultForBand(tpAniSirGlobal, v_BOOL_t flushP2P, tSirRFBand band);
554
Jeff Johnson295189b2012-06-20 16:38:30 -0700555/* ---------------------------------------------------------------------------
556 \fn csrScanBGScanGetParam
557 \brief Returns the current background scan settings.
558 \return eHalStatus
559 -------------------------------------------------------------------------------*/
560eHalStatus csrScanBGScanGetParam(tpAniSirGlobal, tCsrBGScanRequest *);
561
562/* ---------------------------------------------------------------------------
563 \fn csrScanResultGetFirst
564 \brief Returns the first element of scan result.
565 \param hScanResult - returned from csrScanGetResult
566 \return tCsrScanResultInfo * - NULL if no result
567 -------------------------------------------------------------------------------*/
568tCsrScanResultInfo *csrScanResultGetFirst(tpAniSirGlobal, tScanResultHandle hScanResult);
569/* ---------------------------------------------------------------------------
570 \fn csrScanResultGetNext
571 \brief Returns the next element of scan result. It can be called without calling csrScanResultGetFirst first
572 \param hScanResult - returned from csrScanGetResult
573 \return Null if no result or reach the end
574 -------------------------------------------------------------------------------*/
575tCsrScanResultInfo *csrScanResultGetNext(tpAniSirGlobal, tScanResultHandle hScanResult);
576
577/* ---------------------------------------------------------------------------
578 \fn csrGetCountryCode
579 \brief this function is to get the country code current being used
580 \param pBuf - Caller allocated buffer with at least 3 bytes, upon success return, this has the country code
581 \param pbLen - Caller allocated, as input, it indicates the length of pBuf. Upon success return,
582 this contains the length of the data in pBuf
583 \return eHalStatus
584 -------------------------------------------------------------------------------*/
585eHalStatus csrGetCountryCode(tpAniSirGlobal pMac, tANI_U8 *pBuf, tANI_U8 *pbLen);
586
587/* ---------------------------------------------------------------------------
588 \fn csrSetCountryCode
589 \brief this function is to set the country code so channel/power setting matches the countrycode and
590 the domain it belongs to.
591 \param pCountry - Caller allocated buffer with at least 3 bytes specifying the country code
592 \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether
593 a restart is needed to apply the change
594 \return eHalStatus
595 -------------------------------------------------------------------------------*/
596eHalStatus csrSetCountryCode(tpAniSirGlobal pMac, tANI_U8 *pCountry, tANI_BOOLEAN *pfRestartNeeded);
597
598/* ---------------------------------------------------------------------------
599 \fn csrResetCountryCodeInformation
600 \brief this function is to reset the country code current being used back to EEPROM default
601 this includes channel list and power setting.
602 \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether
603 a restart is needed to apply the change
604 \return eHalStatus
605 -------------------------------------------------------------------------------*/
606eHalStatus csrResetCountryCodeInformation(tpAniSirGlobal pMac, tANI_BOOLEAN *pfRestartNeeded);
607
608/* ---------------------------------------------------------------------------
609 \fn csrGetSupportedCountryCode
610 \brief this function is to get a list of the country code current being supported
611 \param pBuf - Caller allocated buffer with at least 3 bytes, upon success return,
612 this has the country code list. 3 bytes for each country code. This may be NULL if
613 caller wants to know the needed bytes.
614 \param pbLen - Caller allocated, as input, it indicates the length of pBuf. Upon success return,
615 this contains the length of the data in pBuf
616 \return eHalStatus
617 -------------------------------------------------------------------------------*/
618eHalStatus csrGetSupportedCountryCode(tpAniSirGlobal pMac, tANI_U8 *pBuf, tANI_U32 *pbLen);
619
620/* ---------------------------------------------------------------------------
621 \fn csrSetRegulatoryDomain
622 \brief this function is to set the current regulatory domain.
623 This function must be called after CFG is downloaded and all the band/mode setting already passed into
624 CSR.
625 \param domainId - indicate the domain (defined in the driver) needs to set to.
626 See eRegDomainId for definition
627 \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether
628 a restart is needed to apply the change
629 \return eHalStatus
630 -------------------------------------------------------------------------------*/
631eHalStatus csrSetRegulatoryDomain(tpAniSirGlobal pMac, v_REGDOMAIN_t domainId, tANI_BOOLEAN *pfRestartNeeded);
632
633/* ---------------------------------------------------------------------------
634 \fn csrGetCurrentRegulatoryDomain
635 \brief this function is to get the current regulatory domain.
636 This function must be called after CFG is downloaded and all the band/mode setting already passed into
637 CSR.
638 \return eRegDomainId
639 -------------------------------------------------------------------------------*/
640v_REGDOMAIN_t csrGetCurrentRegulatoryDomain(tpAniSirGlobal pMac);
641
642/* ---------------------------------------------------------------------------
643 \fn csrGetRegulatoryDomainForCountry
644 \brief this function is to get the regulatory domain for a country.
645 This function must be called after CFG is downloaded and all the band/mode setting already passed into
646 CSR.
647 \param pCountry - Caller allocated buffer with at least 3 bytes specifying the country code
648 \param pDomainId - Caller allocated buffer to get the return domain ID upon success return. Can be NULL.
Kiet Lam6c583332013-10-14 05:37:09 +0530649 \param source - the source of country information.
Jeff Johnson295189b2012-06-20 16:38:30 -0700650 \return eHalStatus
651 -------------------------------------------------------------------------------*/
Kiet Lam6c583332013-10-14 05:37:09 +0530652eHalStatus csrGetRegulatoryDomainForCountry(tpAniSirGlobal pMac,
653 tANI_U8 *pCountry,
654 v_REGDOMAIN_t *pDomainId,
655 v_CountryInfoSource_t source);
Jeff Johnson295189b2012-06-20 16:38:30 -0700656
657
658tANI_BOOLEAN csrSave11dCountryString( tpAniSirGlobal pMac, tANI_U8 *pCountryCode, tANI_BOOLEAN fForce );
659
660//some support functions
661tANI_BOOLEAN csrIs11dSupported(tpAniSirGlobal pMac);
662tANI_BOOLEAN csrIs11hSupported(tpAniSirGlobal pMac);
663tANI_BOOLEAN csrIs11eSupported(tpAniSirGlobal pMac);
664tANI_BOOLEAN csrIsWmmSupported(tpAniSirGlobal pMac);
665tANI_BOOLEAN csrIsMCCSupported(tpAniSirGlobal pMac);
666
667//Upper layer to get the list of the base channels to scan for passively 11d info from csr
668eHalStatus csrScanGetBaseChannels( tpAniSirGlobal pMac, tCsrChannelInfo * pChannelInfo );
669//Return SUCCESS is the command is queued, failed
670eHalStatus csrQueueSmeCommand( tpAniSirGlobal pMac, tSmeCmd *pCommand, tANI_BOOLEAN fHighPriority );
671tSmeCmd *csrGetCommandBuffer( tpAniSirGlobal pMac );
672void csrReleaseCommand(tpAniSirGlobal pMac, tSmeCmd *pCommand);
673#ifdef FEATURE_WLAN_WAPI
674tANI_BOOLEAN csrIsProfileWapi( tCsrRoamProfile *pProfile );
675#endif /* FEATURE_WLAN_WAPI */
676
677#ifdef FEATURE_WLAN_DIAG_SUPPORT_CSR
678
679//Security
680#define WLAN_SECURITY_EVENT_SET_PTK_REQ 1
681#define WLAN_SECURITY_EVENT_SET_PTK_RSP 2
682#define WLAN_SECURITY_EVENT_SET_GTK_REQ 3
683#define WLAN_SECURITY_EVENT_SET_GTK_RSP 4
684#define WLAN_SECURITY_EVENT_REMOVE_KEY_REQ 5
685#define WLAN_SECURITY_EVENT_REMOVE_KEY_RSP 6
686#define WLAN_SECURITY_EVENT_PMKID_CANDIDATE_FOUND 7
687#define WLAN_SECURITY_EVENT_PMKID_UPDATE 8
688#define WLAN_SECURITY_EVENT_MIC_ERROR 9
Abhishek Singh5f693202016-01-06 13:47:33 +0530689#define WLAN_SECURITY_EVENT_SET_UNICAST_REQ 10
690#define WLAN_SECURITY_EVENT_SET_UNICAST_RSP 11
691#define WLAN_SECURITY_EVENT_SET_BCAST_REQ 12
692#define WLAN_SECURITY_EVENT_SET_BCAST_RSP 13
693
Jeff Johnson295189b2012-06-20 16:38:30 -0700694
695#define AUTH_OPEN 0
696#define AUTH_SHARED 1
697#define AUTH_WPA_EAP 2
698#define AUTH_WPA_PSK 3
699#define AUTH_WPA2_EAP 4
700#define AUTH_WPA2_PSK 5
701#ifdef FEATURE_WLAN_WAPI
702#define AUTH_WAPI_CERT 6
703#define AUTH_WAPI_PSK 7
704#endif /* FEATURE_WLAN_WAPI */
705
706#define ENC_MODE_OPEN 0
707#define ENC_MODE_WEP40 1
708#define ENC_MODE_WEP104 2
709#define ENC_MODE_TKIP 3
710#define ENC_MODE_AES 4
711#ifdef FEATURE_WLAN_WAPI
712#define ENC_MODE_SMS4 5 //WAPI
713#endif /* FEATURE_WLAN_WAPI */
714
715#define NO_MATCH 0
716#define MATCH 1
717
718#define WLAN_SECURITY_STATUS_SUCCESS 0
719#define WLAN_SECURITY_STATUS_FAILURE 1
720
721//Scan
722#define WLAN_SCAN_EVENT_ACTIVE_SCAN_REQ 1
723#define WLAN_SCAN_EVENT_ACTIVE_SCAN_RSP 2
724#define WLAN_SCAN_EVENT_PASSIVE_SCAN_REQ 3
725#define WLAN_SCAN_EVENT_PASSIVE_SCAN_RSP 4
726#define WLAN_SCAN_EVENT_HO_SCAN_REQ 5
727#define WLAN_SCAN_EVENT_HO_SCAN_RSP 6
728
729#define WLAN_SCAN_STATUS_SUCCESS 0
730#define WLAN_SCAN_STATUS_FAILURE 1
731#define WLAN_SCAN_STATUS_ABORT 2
732
733//Ibss
734#define WLAN_IBSS_EVENT_START_IBSS_REQ 0
735#define WLAN_IBSS_EVENT_START_IBSS_RSP 1
736#define WLAN_IBSS_EVENT_JOIN_IBSS_REQ 2
737#define WLAN_IBSS_EVENT_JOIN_IBSS_RSP 3
738#define WLAN_IBSS_EVENT_COALESCING 4
739#define WLAN_IBSS_EVENT_PEER_JOIN 5
740#define WLAN_IBSS_EVENT_PEER_LEAVE 6
741#define WLAN_IBSS_EVENT_STOP_REQ 7
742#define WLAN_IBSS_EVENT_STOP_RSP 8
743
744#define AUTO_PICK 0
745#define SPECIFIED 1
746
747#define WLAN_IBSS_STATUS_SUCCESS 0
748#define WLAN_IBSS_STATUS_FAILURE 1
749
750//11d
751#define WLAN_80211D_EVENT_COUNTRY_SET 0
752#define WLAN_80211D_EVENT_RESET 1
753
754#define WLAN_80211D_DISABLED 0
755#define WLAN_80211D_SUPPORT_MULTI_DOMAIN 1
756#define WLAN_80211D_NOT_SUPPORT_MULTI_DOMAIN 2
757
758int diagAuthTypeFromCSRType(eCsrAuthType authType);
759int diagEncTypeFromCSRType(eCsrEncryptionType encType);
760#endif //#ifdef FEATURE_WLAN_DIAG_SUPPORT_CSR
761/* ---------------------------------------------------------------------------
762 \fn csrScanResultPurge
763 \brief remove all items(tCsrScanResult) in the list and free memory for each item
764 \param hScanResult - returned from csrScanGetResult. hScanResult is considered gone by
765 calling this function and even before this function reutrns.
766 \return eHalStatus
767 -------------------------------------------------------------------------------*/
768eHalStatus csrScanResultPurge(tpAniSirGlobal pMac, tScanResultHandle hScanResult);
769
770
771///////////////////////////////////////////Common Scan ends
772
773/* ---------------------------------------------------------------------------
774 \fn csrRoamConnect
775 \brief To inititiate an association
776 \param pProfile - can be NULL to join to any open ones
777 \param hBssListIn - a list of BSS descriptor to roam to. It is returned from csrScanGetResult
778 \param pRoamId - to get back the request ID
779 \return eHalStatus
780 -------------------------------------------------------------------------------*/
781eHalStatus csrRoamConnect(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamProfile *pProfile,
782 tScanResultHandle hBssListIn, tANI_U32 *pRoamId);
783
784/* ---------------------------------------------------------------------------
785 \fn csrRoamReassoc
786 \brief To inititiate a re-association
787 \param pProfile - can be NULL to join the currently connected AP. In that
788 case modProfileFields should carry the modified field(s) which could trigger
789 reassoc
790 \param modProfileFields - fields which are part of tCsrRoamConnectedProfile
791 that might need modification dynamically once STA is up & running and this
792 could trigger a reassoc
793 \param pRoamId - to get back the request ID
794 \return eHalStatus
795 -------------------------------------------------------------------------------*/
796eHalStatus csrRoamReassoc(tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamProfile *pProfile,
797 tCsrRoamModifyProfileFields modProfileFields,
798 tANI_U32 *pRoamId);
799
800
801/* ---------------------------------------------------------------------------
802 \fn csrRoamReconnect
803 \brief To disconnect and reconnect with the same profile
804 \return eHalStatus. It returns fail if currently not connected
805 -------------------------------------------------------------------------------*/
806eHalStatus csrRoamReconnect(tpAniSirGlobal pMac, tANI_U32 sessionId);
807
808/* ---------------------------------------------------------------------------
809 \fn csrRoamSetPMKIDCache
810 \brief return the PMKID candidate list
811 \param pPMKIDCache - caller allocated buffer point to an array of tPmkidCacheInfo
812 \param numItems - a variable that has the number of tPmkidCacheInfo allocated
813 when retruning, this is either the number needed or number of items put into pPMKIDCache
814 \return eHalStatus - when fail, it usually means the buffer allocated is not big enough and pNumItems
815 has the number of tPmkidCacheInfo.
816 \Note: pNumItems is a number of tPmkidCacheInfo, not sizeof(tPmkidCacheInfo) * something
817 -------------------------------------------------------------------------------*/
Kanchanapally, Vidyullatha2633ace2014-09-25 15:16:50 +0530818eHalStatus csrRoamSetPMKIDCache( tpAniSirGlobal pMac, tANI_U32 sessionId,
819 tPmkidCacheInfo *pPMKIDCache,
820 tANI_U32 numItems,
821 tANI_BOOLEAN update_entire_cache );
Jeff Johnson295189b2012-06-20 16:38:30 -0700822
823/* ---------------------------------------------------------------------------
824 \fn csrRoamGetWpaRsnReqIE
825 \brief return the WPA or RSN IE CSR passes to PE to JOIN request or START_BSS request
826 \param pLen - caller allocated memory that has the length of pBuf as input. Upon returned, *pLen has the
827 needed or IE length in pBuf.
828 \param pBuf - Caller allocated memory that contain the IE field, if any, upon return
829 \return eHalStatus - when fail, it usually means the buffer allocated is not big enough
830 -------------------------------------------------------------------------------*/
831eHalStatus csrRoamGetWpaRsnReqIE(tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_U32 *pLen, tANI_U8 *pBuf);
832
833/* ---------------------------------------------------------------------------
834 \fn csrRoamGetWpaRsnRspIE
835 \brief return the WPA or RSN IE from the beacon or probe rsp if connected
836 \param pLen - caller allocated memory that has the length of pBuf as input. Upon returned, *pLen has the
837 needed or IE length in pBuf.
838 \param pBuf - Caller allocated memory that contain the IE field, if any, upon return
839 \return eHalStatus - when fail, it usually means the buffer allocated is not big enough
840 -------------------------------------------------------------------------------*/
841eHalStatus csrRoamGetWpaRsnRspIE(tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_U32 *pLen, tANI_U8 *pBuf);
842
843
844/* ---------------------------------------------------------------------------
845 \fn csrRoamGetNumPMKIDCache
846 \brief return number of PMKID cache entries
847 \return tANI_U32 - the number of PMKID cache entries
848 -------------------------------------------------------------------------------*/
849tANI_U32 csrRoamGetNumPMKIDCache(tpAniSirGlobal pMac, tANI_U32 sessionId);
850
851/* ---------------------------------------------------------------------------
852 \fn csrRoamGetPMKIDCache
853 \brief return PMKID cache from CSR
854 \param pNum - caller allocated memory that has the space of the number of pBuf tPmkidCacheInfo as input. Upon returned, *pNum has the
855 needed or actually number in tPmkidCacheInfo.
856 \param pPmkidCache - Caller allocated memory that contains PMKID cache, if any, upon return
857 \return eHalStatus - when fail, it usually means the buffer allocated is not big enough
858 -------------------------------------------------------------------------------*/
859eHalStatus csrRoamGetPMKIDCache(tpAniSirGlobal pMac, tANI_U32 sessionId,
860 tANI_U32 *pNum, tPmkidCacheInfo *pPmkidCache);
861
862/* ---------------------------------------------------------------------------
863 \fn csrRoamGetConnectProfile
864 \brief To return the current connect profile. Caller must call csrRoamFreeConnectProfile
865 after it is done and before reuse for another csrRoamGetConnectProfile call.
866 \param pProfile - pointer to a caller allocated structure tCsrRoamConnectedProfile
867 \return eHalStatus. Failure if not connected
868 -------------------------------------------------------------------------------*/
869eHalStatus csrRoamGetConnectProfile(tpAniSirGlobal pMac, tANI_U32 sessionId,
870 tCsrRoamConnectedProfile *pProfile);
871
872/* ---------------------------------------------------------------------------
873 \fn csrRoamGetConnectState
874 \brief To return the current connect state of Roaming
875 \return eHalStatus
876 -------------------------------------------------------------------------------*/
877eHalStatus csrRoamGetConnectState(tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrConnectState *pState);
878
879/* ---------------------------------------------------------------------------
880 \fn csrRoamFreeConnectProfile
881 \brief To free and reinitialize the profile return previous by csrRoamGetConnectProfile.
882 \param pProfile - pointer to a caller allocated structure tCsrRoamConnectedProfile
883 \return eHalStatus.
884 -------------------------------------------------------------------------------*/
885eHalStatus csrRoamFreeConnectProfile(tpAniSirGlobal pMac, tCsrRoamConnectedProfile *pProfile);
886
887/* ---------------------------------------------------------------------------
888 \fn csrInitChannelList
889 \brief HDD calls this function to set the WNI_CFG_VALID_CHANNEL_LIST base on the band/mode settings.
890 This function must be called after CFG is downloaded and all the band/mode setting already passed into
891 CSR.
892 \return eHalStatus
893 -------------------------------------------------------------------------------*/
894eHalStatus csrInitChannelList( tHalHandle hHal );
895
896/* ---------------------------------------------------------------------------
897 \fn csrChangeConfigParams
898 \brief The CSR API exposed for HDD to provide config params to CSR during
899 SMEs stop -> start sequence.
900 If HDD changed the domain that will cause a reset. This function will
901 provide the new set of 11d information for the new domain. Currrently this
902 API provides info regarding 11d only at reset but we can extend this for
903 other params (PMC, QoS) which needs to be initialized again at reset.
904 \param
905 hHal - Handle to the HAL. The HAL handle is returned by the HAL after it is
906 opened (by calling halOpen).
907 pUpdateConfigParam - a pointer to a structure (tCsrUpdateConfigParam) that
908 currently provides 11d related information like Country code,
909 Regulatory domain, valid channel list, Tx power per channel, a
910 list with active/passive scan allowed per valid channel.
911
912 \return eHalStatus
913 ---------------------------------------------------------------------------*/
914eHalStatus csrChangeConfigParams(tpAniSirGlobal pMac,
915 tCsrUpdateConfigParam *pUpdateConfigParam);
916
917/* ---------------------------------------------------------------------------
918 \fn csrRoamConnectToLastProfile
919 \brief To disconnect and reconnect with the same profile
920 \return eHalStatus. It returns fail if currently connected
921 -------------------------------------------------------------------------------*/
922eHalStatus csrRoamConnectToLastProfile(tpAniSirGlobal pMac, tANI_U32 sessionId);
923
924/* ---------------------------------------------------------------------------
925 \fn csrRoamDisconnect
926 \brief To disconnect from a network
927 \param reason -- To indicate the reason for disconnecting. Currently, only eCSR_DISCONNECT_REASON_MIC_ERROR is meanful.
928 \return eHalStatus
929 -------------------------------------------------------------------------------*/
930eHalStatus csrRoamDisconnect(tpAniSirGlobal pMac, tANI_U32 sessionId, eCsrRoamDisconnectReason reason);
931
932/* ---------------------------------------------------------------------------
Sushant Kaushikb4834d22015-07-15 15:29:05 +0530933 \fn csr_abortConnection
934 \brief To disconnect from a connecting network
935 \retutn void.
936----------------------------------------------------------------------------*/
937
938void csr_abortConnection(tpAniSirGlobal pMac, tANI_U32 sessionId);
939
940/* ---------------------------------------------------------------------------
Jeff Johnson295189b2012-06-20 16:38:30 -0700941 \fn csrScanGetPMKIDCandidateList
942 \brief return the PMKID candidate list
943 \param pPmkidList - caller allocated buffer point to an array of tPmkidCandidateInfo
944 \param pNumItems - pointer to a variable that has the number of tPmkidCandidateInfo allocated
945 when retruning, this is either the number needed or number of items put into pPmkidList
946 \return eHalStatus - when fail, it usually means the buffer allocated is not big enough and pNumItems
947 has the number of tPmkidCandidateInfo.
948 \Note: pNumItems is a number of tPmkidCandidateInfo, not sizeof(tPmkidCandidateInfo) * something
949 -------------------------------------------------------------------------------*/
950eHalStatus csrScanGetPMKIDCandidateList(tpAniSirGlobal pMac, tANI_U32 sessionId,
951 tPmkidCandidateInfo *pPmkidList, tANI_U32 *pNumItems );
952
953//This function is used to stop a BSS. It is similar of csrRoamIssueDisconnect but this function
954//doesn't have any logic other than blindly trying to stop BSS
955eHalStatus csrRoamIssueStopBssCmd( tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_BOOLEAN fHighPriority );
956
957void csrCallRoamingCompletionCallback(tpAniSirGlobal pMac, tCsrRoamSession *pSession,
958 tCsrRoamInfo *pRoamInfo, tANI_U32 roamId, eCsrRoamResult roamResult);
959
Jeff Johnson295189b2012-06-20 16:38:30 -0700960/* ---------------------------------------------------------------------------
961 \fn csrRoamIssueDisassociateStaCmd
962 \brief csr function that HDD calls to disassociate a associated station
963 \param sessionId - session Id for Soft AP
964 \param pPeerMacAddr - MAC of associated station to delete
965 \param reason - reason code, be one of the tSirMacReasonCodes
966 \return eHalStatus
967 ---------------------------------------------------------------------------*/
968eHalStatus csrRoamIssueDisassociateStaCmd( tpAniSirGlobal pMac,
Anand N Sunkadc205d952015-07-30 15:36:03 +0530969 tANI_U32 sessionId,
970#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,18,0))
971 const tANI_U8 *pPeerMacAddr,
972#else
Jeff Johnson295189b2012-06-20 16:38:30 -0700973 tANI_U8 *pPeerMacAddr,
Anand N Sunkadc205d952015-07-30 15:36:03 +0530974#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700975 tANI_U32 reason);
976
977/* ---------------------------------------------------------------------------
978 \fn csrRoamIssueDeauthSta
979 \brief csr function that HDD calls to delete a associated station
980 \param sessionId - session Id for Soft AP
Hanumantha Reddy Pothulaf57da152014-10-31 13:02:08 +0530981 \param pDelStaParams- Pointer to parameters of the station to deauthenticate
Jeff Johnson295189b2012-06-20 16:38:30 -0700982 \return eHalStatus
983 ---------------------------------------------------------------------------*/
984eHalStatus csrRoamIssueDeauthStaCmd( tpAniSirGlobal pMac,
Hanumantha Reddy Pothulaf57da152014-10-31 13:02:08 +0530985 tANI_U32 sessionId,
986 struct tagCsrDelStaParams *pDelStaParams);
Jeff Johnson295189b2012-06-20 16:38:30 -0700987
988/* ---------------------------------------------------------------------------
989 \fn csrRoamIssueTkipCounterMeasures
990 \brief csr function that HDD calls to start and stop tkip countermeasures
991 \param sessionId - session Id for Soft AP
992 \param bEnable - Flag to start/stop countermeasures
993 \return eHalStatus
994 ---------------------------------------------------------------------------*/
995eHalStatus csrRoamIssueTkipCounterMeasures( tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_BOOLEAN bEnable);
996
997eHalStatus csrSendMBTkipCounterMeasuresReqMsg( tpAniSirGlobal pMac, tANI_U32 sessinId, tANI_BOOLEAN bEnable, tSirMacAddr bssId );
998
999/* ---------------------------------------------------------------------------
1000 \fn csrRoamGetAssociatedStas
1001 \brief csr function that HDD calls to get list of associated stations based on module ID
1002 \param sessionId - session Id for Soft AP
1003 \param modId - module ID - PE/HAL/TL
1004 \param pUsrContext - Opaque HDD context
1005 \param pfnSapEventCallback - Sap event callback in HDD
1006 \param pAssocStasBuf - Caller allocated memory to be filled with associatd stations info
1007 \return eHalStatus
1008 ---------------------------------------------------------------------------*/
1009eHalStatus csrRoamGetAssociatedStas( tpAniSirGlobal pMac, tANI_U32 sessionId, VOS_MODULE_ID modId,
1010 void *pUsrContext, void *pfnSapEventCallback, tANI_U8 *pAssocStasBuf );
1011
1012eHalStatus csrSendMBGetAssociatedStasReqMsg( tpAniSirGlobal pMac, tANI_U32 sessionId, VOS_MODULE_ID modId, tSirMacAddr bssId,
1013 void *pUsrContext, void *pfnSapEventCallback, tANI_U8 *pAssocStasBuf );
1014
1015/* ---------------------------------------------------------------------------
1016 \fn csrRoamGetWpsSessionOverlap
1017 \brief csr function that HDD calls to get WPS PBC session overlap information
1018 \param sessionId - session Id for Soft AP
1019 \param pUsrContext - Opaque HDD context
1020 \param pfnSapEventCallback - Sap event callback in HDD
1021 \param pRemoveMac - pointer to MAC address of session to be removed
1022 \return eHalStatus
1023 ---------------------------------------------------------------------------*/
1024eHalStatus csrRoamGetWpsSessionOverlap( tpAniSirGlobal pMac, tANI_U32 sessionId,
1025 void *pUsrContext, void *pfnSapEventCallback,v_MACADDR_t pRemoveMac );
1026
1027eHalStatus csrSendMBGetWPSPBCSessions( tpAniSirGlobal pMac, tANI_U32 sessionId,
1028 tSirMacAddr bssId, void *pUsrContext, void *pfnSapEventCallback,v_MACADDR_t pRemoveMac);
Madan Mohan Koyyalamudi167b95e2012-11-27 15:53:38 -08001029
1030/* ---------------------------------------------------------------------------
1031 \fn csrSendChngMCCBeaconInterval
1032 \brief csr function that HDD calls to send Update beacon interval
1033 \param sessionId - session Id for Soft AP
1034 \return eHalStatus
1035 ---------------------------------------------------------------------------*/
1036eHalStatus
1037csrSendChngMCCBeaconInterval(tpAniSirGlobal pMac, tANI_U32 sessionId);
1038
Jeff Johnson295189b2012-06-20 16:38:30 -07001039#ifdef FEATURE_WLAN_BTAMP_UT_RF
1040eHalStatus csrRoamStartJoinRetryTimer(tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_U32 interval);
1041eHalStatus csrRoamStopJoinRetryTimer(tpAniSirGlobal pMac, tANI_U32 sessionId);
1042#endif
1043#ifdef WLAN_FEATURE_VOWIFI_11R
1044/* ---------------------------------------------------------------------------
1045 \fn csrRoamFTPreAuthRspProcessor
1046 \brief csr function that handles pre auth response from LIM
1047 ---------------------------------------------------------------------------*/
1048void csrRoamFTPreAuthRspProcessor( tHalHandle hHal, tpSirFTPreAuthRsp pFTPreAuthRsp );
1049#endif
1050
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001051#if defined(FEATURE_WLAN_ESE) && !defined(FEATURE_WLAN_ESE_UPLOAD)
1052void csrEseSendAdjacentApRepMsg(tpAniSirGlobal pMac, tCsrRoamSession *pSession);
Jeff Johnson295189b2012-06-20 16:38:30 -07001053#endif
Jeff Johnsond13512a2012-07-17 11:42:19 -07001054
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001055#if defined(FEATURE_WLAN_ESE)
Srinivas Girigowda5cecb202013-10-08 09:13:25 -07001056void UpdateCCKMTSF(tANI_U32 *timeStamp0, tANI_U32 *timeStamp1, tANI_U32 *incr);
1057#endif
1058
Jeff Johnsond13512a2012-07-17 11:42:19 -07001059eHalStatus csrGetDefaultCountryCodeFrmNv(tpAniSirGlobal pMac, tANI_U8 *pCountry);
1060eHalStatus csrGetCurrentCountryCode(tpAniSirGlobal pMac, tANI_U8 *pCountry);
1061
Madan Mohan Koyyalamudi286b60e2012-10-11 12:59:07 -07001062
1063eHalStatus csrRoamEnqueuePreauth(tpAniSirGlobal pMac, tANI_U32 sessionId, tpSirBssDescription pBssDescription,
1064 eCsrRoamReason reason, tANI_BOOLEAN fImmediate);
1065eHalStatus csrRoamDequeuePreauth(tpAniSirGlobal pMac);
Madan Mohan Koyyalamudidd3c9662012-11-09 17:39:30 -08001066#ifdef FEATURE_WLAN_LFR
1067void csrInitOccupiedChannelsList(tpAniSirGlobal pMac);
1068tANI_BOOLEAN csrNeighborRoamIsNewConnectedProfile(tpAniSirGlobal pMac);
1069tANI_BOOLEAN csrNeighborRoamConnectedProfileMatch(tpAniSirGlobal pMac, tCsrScanResult *pResult,
1070 tDot11fBeaconIEs *pIes);
1071#endif
schang86c22c42013-03-13 18:41:24 -07001072eHalStatus csrSetTxPower(tpAniSirGlobal pMac, v_U8_t sessionId, v_U8_t mW);
Sandeep Puligilla332ea912014-02-04 00:16:24 +05301073eHalStatus csrHT40StopOBSSScan(tpAniSirGlobal pMac, v_U8_t sessionId);
Varun Reddy Yeturucc661d22013-05-20 11:47:10 -07001074
1075eHalStatus csrScanCreateEntryInScanCache(tpAniSirGlobal pMac, tANI_U32 sessionId,
1076 tCsrBssid bssid, tANI_U8 channel);
Gopichand Nakkalaf72a3872013-06-11 17:51:13 +05301077
Leela Venkata Kiran Kumar Reddy Chiralac6663f72014-02-03 21:04:58 -08001078eHalStatus csrUpdateChannelList(tpAniSirGlobal pMac);
Leela Venkata Kiran Kumar Reddy Chiralaede10652013-09-11 18:48:46 -07001079eHalStatus csrRoamDelPMKIDfromCache( tpAniSirGlobal pMac, tANI_U32 sessionId,
Anand N Sunkadb3ab97d2015-07-29 09:58:13 +05301080#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,18,0))
1081 const tANI_U8 *pBSSId,
1082#else
1083 tANI_U8 *pBSSId,
1084#endif
1085 tANI_BOOLEAN flush_cache );
Agrawal Ashish0b6984f2014-04-05 18:35:45 +05301086tANI_BOOLEAN csrElectedCountryInfo(tpAniSirGlobal pMac);
1087void csrAddVoteForCountryInfo(tpAniSirGlobal pMac, tANI_U8 *pCountryCode);
1088void csrClearVotesForCountryInfo(tpAniSirGlobal pMac);
Abhishek Singh72c2f4e2016-07-22 11:25:43 +05301089void csr_remove_bssid_from_scan_list(tpAniSirGlobal pMac,
1090 tSirMacAddr bssid);
1091
Hardik Kantilal Patel62a3a762014-11-21 12:55:57 +05301092#ifdef WLAN_FEATURE_AP_HT40_24G
1093eHalStatus csrSetHT2040Mode(tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_U8 cbMode);
1094#endif
Jeff Johnson295189b2012-06-20 16:38:30 -07001095#endif
1096