blob: 55bffd91d8592dafd6d9c24cf8201d31996a611b [file] [log] [blame]
Jeff Johnson295189b2012-06-20 16:38:30 -07001/*
Kiet Lam0fb93dd2014-02-19 00:32:59 -08002 * Copyright (c) 2012-2014 The Linux Foundation. All rights reserved.
3 *
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/*
Kiet Lama7f454d2014-07-24 12:04:06 -070023 * This file was originally distributed by Qualcomm Atheros, Inc.
24 * under proprietary terms before Copyright ownership was assigned
25 * to the Linux Foundation.
Kiet Lam0fb93dd2014-02-19 00:32:59 -080026 */
27
Jeff Johnson295189b2012-06-20 16:38:30 -070028
Kiet Lama7f454d2014-07-24 12:04:06 -070029
30
Jeff Johnson295189b2012-06-20 16:38:30 -070031#if !defined( __SME_API_H )
32#define __SME_API_H
33
34
35/**=========================================================================
36
37 \file smeApi.h
38
39 \brief prototype for SME APIs
40
41 Copyright 2008 (c) Qualcomm, Incorporated. All Rights Reserved.
42
43 Qualcomm Confidential and Proprietary.
44
45 ========================================================================*/
46
47/* $Header$ */
48
49/*--------------------------------------------------------------------------
50 Include Files
51 ------------------------------------------------------------------------*/
52#include "ccmApi.h"
53#include "csrApi.h"
54#include "pmcApi.h"
55#include "vos_mq.h"
56#include "vos_lock.h"
57#include "halTypes.h"
58#include "sirApi.h"
59#include "btcApi.h"
60#include "vos_nvitem.h"
61#include "p2p_Api.h"
Jeff Johnson295189b2012-06-20 16:38:30 -070062
Jeff Johnsone7245742012-09-05 17:12:55 -070063#ifdef FEATURE_OEM_DATA_SUPPORT
64#include "oemDataApi.h"
65#endif
Jeff Johnson295189b2012-06-20 16:38:30 -070066
67#if defined WLAN_FEATURE_VOWIFI
68#include "smeRrmInternal.h"
69#endif
70
71/*--------------------------------------------------------------------------
72 Preprocessor definitions and constants
73 ------------------------------------------------------------------------*/
74
75#define SME_SUMMARY_STATS 1
76#define SME_GLOBAL_CLASSA_STATS 2
77#define SME_GLOBAL_CLASSB_STATS 4
78#define SME_GLOBAL_CLASSC_STATS 8
79#define SME_GLOBAL_CLASSD_STATS 16
80#define SME_PER_STA_STATS 32
81
82#define SME_INVALID_COUNTRY_CODE "XX"
83
Sudhir Sattayappa Kohalli37620692013-08-05 14:02:26 -070084//Macro to disable split scan
85#define SME_DISABLE_SPLIT_SCAN 255
Jeff Johnson295189b2012-06-20 16:38:30 -070086/*--------------------------------------------------------------------------
87 Type declarations
88 ------------------------------------------------------------------------*/
89typedef struct _smeConfigParams
90{
91 tCsrConfigParam csrConfig;
92#if defined WLAN_FEATURE_VOWIFI
93 tRrmConfigParam rrmConfig;
94#endif
Jeff Johnson04dd8a82012-06-29 20:41:40 -070095#if defined FEATURE_WLAN_LFR
96 tANI_U8 isFastRoamIniFeatureEnabled;
Sameer Thalappil4ae66ec2013-11-05 14:17:35 -080097 tANI_U8 MAWCEnabled;
Jeff Johnson04dd8a82012-06-29 20:41:40 -070098#endif
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -080099#if defined FEATURE_WLAN_ESE
100 tANI_U8 isEseIniFeatureEnabled;
Jeff Johnson295189b2012-06-20 16:38:30 -0700101#endif
102#if defined WLAN_FEATURE_P2P_INTERNAL
103 tP2PConfigParam p2pConfig;
104#endif
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -0800105#if defined (WLAN_FEATURE_VOWIFI_11R) || defined (FEATURE_WLAN_ESE) || defined(FEATURE_WLAN_LFR)
Srinivas Girigowda100eb322013-03-15 16:48:20 -0700106 tANI_U8 isFastTransitionEnabled;
107 tANI_U8 RoamRssiDiff;
Srinivas Girigowdaad34ca92013-10-22 10:54:29 -0700108 tANI_BOOLEAN isWESModeEnabled;
Jeff Johnson295189b2012-06-20 16:38:30 -0700109#endif
Gopichand Nakkala86e42662013-06-11 17:44:11 +0530110 tANI_BOOLEAN fScanOffload;
krunal soni5afa96c2013-09-06 22:19:02 -0700111 tANI_U8 isAmsduSupportInAMPDU;
Tushnim Bhattacharyyaed4d0c22014-01-30 11:56:44 -0800112 tANI_U32 fEnableDebugLog;
Rashmi Ramanna68b309c2014-05-20 11:52:22 +0530113 tANI_U32 fDeferIMPSTime;
Jeff Johnson295189b2012-06-20 16:38:30 -0700114} tSmeConfigParams, *tpSmeConfigParams;
115
Sunil Duttc69bccb2014-05-26 21:30:20 +0530116#ifdef WLAN_FEATURE_LINK_LAYER_STATS
117
118/* ---------------------------------------------------------------------------
119 \fn sme_LLStatsSetReq
120 \brief API to set link layer stats request to FW
121 \param hHal - The handle returned by macOpen.
122
123 \Param pStatsReq - a pointer to a caller allocated object of
124 typedef struct tSirLLStatsSetReq, signifying the parameters to link layer
125 stats set.
126
127 \return eHalStatus
128 ---------------------------------------------------------------------------*/
129eHalStatus sme_LLStatsSetReq(tHalHandle hHal, tSirLLStatsSetReq *pStatsReq);
130
131/* ---------------------------------------------------------------------------
132 \fn sme_LLStatsGetReq
133 \brief API to get link layer stats request to FW
134 \param hHal - The handle returned by macOpen.
135
136 \Param pStatsReq - a pointer to a caller allocated object of
137 typedef struct tSirLLStatsGetReq, signifying the parameters to link layer
138 stats get.
139
140 \return eHalStatus
141 ---------------------------------------------------------------------------*/
142eHalStatus sme_LLStatsGetReq(tHalHandle hHal, tSirLLStatsGetReq *pStatsReq);
143
144/* ---------------------------------------------------------------------------
145 \fn sme_LLStatsClearReq
146 \brief API to clear link layer stats request to FW
147 \param hHal - The handle returned by macOpen.
148
149 \Param pStatsReq - a pointer to a caller allocated object of
150 typedef struct tSirLLStatsClearReq, signifying the parameters to link layer
151 stats clear.
152
153 \return eHalStatus
154 ---------------------------------------------------------------------------*/
155eHalStatus sme_LLStatsClearReq(tHalHandle hHal, tSirLLStatsClearReq *pStatsReq);
156
157/* ---------------------------------------------------------------------------
158 \fn sme_SetLinkLayerStatsIndCB
159 \brief API to trigger Link Layer stats result indications from from FW
160 \param hHal - The handle returned by macOpen.
Sunil Duttc69bccb2014-05-26 21:30:20 +0530161 \param callbackRoutine - HDD callback which needs to be invoked after
162 getting get Link Layer Statistics results from FW
Sunil Duttc69bccb2014-05-26 21:30:20 +0530163 \return eHalStatus
164 ---------------------------------------------------------------------------*/
165eHalStatus
166sme_SetLinkLayerStatsIndCB
167(
Dino Mycled3d50022014-07-07 12:58:25 +0530168 tHalHandle hHal,
169 void (*callbackRoutine) (void *callbackCtx, int indType, void *pRsp,
170 tANI_U8 *macAddr)
Sunil Duttc69bccb2014-05-26 21:30:20 +0530171);
172
173
174#endif /* WLAN_FEATURE_LINK_LAYER_STATS */
175
Dino Mycle2c198072014-06-10 10:15:52 +0530176#ifdef WLAN_FEATURE_EXTSCAN
177/* ---------------------------------------------------------------------------
178 \fn sme_GetValidChannelsByBand
179 \brief SME API to fetch all valid channel filtered by band
180 \param hHal
181 \param wifiBand: RF band information
182 \param aValidChannels: Array to store channel info
183 \param len: number of channels
184 \- return eHalStatus
185 -------------------------------------------------------------------------*/
186eHalStatus sme_GetValidChannelsByBand (tHalHandle hHal, tANI_U8 wifiBand,
187 tANI_U32 *aValidChannels, tANI_U8 *pNumChannels);
188
189/* ---------------------------------------------------------------------------
190 \fn sme_EXTScanGetCapabilities
191 \brief SME API to fetch Extented Scan capabilities
192 \param hHal
193 \param pReq: Extented Scan capabilities structure
194 \- return eHalStatus
195 -------------------------------------------------------------------------*/
196eHalStatus sme_EXTScanGetCapabilities (tHalHandle hHal,
197 tSirGetEXTScanCapabilitiesReqParams *pReq);
198
199/* ---------------------------------------------------------------------------
200 \fn sme_EXTScanStart
201 \brief SME API to issue Extented Scan start
202 \param hHal
203 \param pStartCmd: Extented Scan start structure
204 \- return eHalStatus
205 -------------------------------------------------------------------------*/
206eHalStatus sme_EXTScanStart (tHalHandle hHal,
207 tSirEXTScanStartReqParams *pStartCmd);
208
209/* ---------------------------------------------------------------------------
210 \fn sme_EXTScanStop
211 \brief SME API to issue Extented Scan stop
212 \param hHal
213 \param pStopReq: Extented Scan stop structure
214 \- return eHalStatus
215 -------------------------------------------------------------------------*/
216eHalStatus sme_EXTScanStop(tHalHandle hHal, tSirEXTScanStopReqParams *pStopReq);
217
218/* ---------------------------------------------------------------------------
219 \fn sme_SetBssHotlist
220 \brief SME API to set BSSID hotlist
221 \param hHal
222 \param pSetHotListReq: Extented Scan set hotlist structure
223 \- return eHalStatus
224 -------------------------------------------------------------------------*/
225eHalStatus sme_SetBssHotlist (tHalHandle hHal,
226 tSirEXTScanSetBssidHotListReqParams *pSetHotListReq);
227
228/* ---------------------------------------------------------------------------
229 \fn sme_ResetBssHotlist
230 \brief SME API to reset BSSID hotlist
231 \param hHal
232 \param pSetHotListReq: Extented Scan set hotlist structure
233 \- return eHalStatus
234 -------------------------------------------------------------------------*/
235eHalStatus sme_ResetBssHotlist (tHalHandle hHal,
236 tSirEXTScanResetBssidHotlistReqParams *pResetReq);
237
238/* ---------------------------------------------------------------------------
239 \fn sme_SetSignificantChange
240 \brief SME API to set significant change
241 \param hHal
242 \param pSetSignificantChangeReq: Extented Scan set significant
243 change structure
244 \- return eHalStatus
245 -------------------------------------------------------------------------*/
246eHalStatus sme_SetSignificantChange (tHalHandle hHal,
247 tSirEXTScanSetSignificantChangeReqParams* pSetSignificantChangeReq);
248
249/* ---------------------------------------------------------------------------
250 \fn sme_ResetSignificantChange
251 \brief SME API to reset significant change
252 \param hHal
253 \param pResetReq: Extented Scan reset significant change structure
254 \- return eHalStatus
255 -------------------------------------------------------------------------*/
256eHalStatus sme_ResetSignificantChange (tHalHandle hHal,
257 tSirEXTScanResetSignificantChangeReqParams *pResetReq);
258
259/* ---------------------------------------------------------------------------
260 \fn sme_getCachedResults
261 \brief SME API to get cached results
262 \param hHal
263 \param pCachedResultsReq: Extented Scan get cached results structure
264 \- return eHalStatus
265 -------------------------------------------------------------------------*/
266eHalStatus sme_getCachedResults (tHalHandle hHal,
267 tSirEXTScanGetCachedResultsReqParams *pCachedResultsReq);
268
269/* ---------------------------------------------------------------------------
270 \fn sme_EXTScanRegisterCallback
271 \brief SME API to register Extented Scan notification callback
272 \param pEXTScanIndCb
273 \- return void
274 -------------------------------------------------------------------------*/
275eHalStatus sme_EXTScanRegisterCallback (tHalHandle hHal,
276 void (*pEXTScanIndCb)(void *, const tANI_U16, void *),
277 void *);
278
279#endif /* WLAN_FEATURE_EXTSCAN */
Siddharth Bhal6af5d4e2014-09-29 21:11:16 +0530280tANI_BOOLEAN sme_SpoofMacAddrReq(tHalHandle hHal, v_MACADDR_t *macaddr);
Dino Mycle2c198072014-06-10 10:15:52 +0530281
Madan Mohan Koyyalamudi48101412013-09-11 23:09:37 +0530282typedef enum
283{
284 eSME_ROAM_TRIGGER_NONE = 0,
285 eSME_ROAM_TRIGGER_SCAN = 1,
286 eSME_ROAM_TRIGGER_FAST_ROAM = 2,
287 eSME_ROAM_TRIGGER_MAX
288} tSmeFastRoamTrigger;
Jeff Johnson295189b2012-06-20 16:38:30 -0700289
290/*-------------------------------------------------------------------------
Sushant Kaushike0d2cce2014-04-10 14:36:07 +0530291 Function declarations and documentation.
Jeff Johnson295189b2012-06-20 16:38:30 -0700292 ------------------------------------------------------------------------*/
Jeff Johnson295189b2012-06-20 16:38:30 -0700293/*--------------------------------------------------------------------------
294
295 \brief sme_Open() - Initialze all SME modules and put them at idle state
296
297 The function initializes each module inside SME, PMC, CCM, CSR, etc. . Upon
298 successfully return, all modules are at idle state ready to start.
299
300 smeOpen must be called before any other SME APIs can be involved.
301 smeOpen must be called after macOpen.
302
303 \param hHal - The handle returned by macOpen.
304
305 \return eHAL_STATUS_SUCCESS - SME is successfully initialized.
306
307 Other status means SME is failed to be initialized
308 \sa
309
310 --------------------------------------------------------------------------*/
311eHalStatus sme_Open(tHalHandle hHal);
312
313/*--------------------------------------------------------------------------
314
315 \brief sme_Close() - Release all SME modules and their resources.
316
317 The function release each module in SME, PMC, CCM, CSR, etc. . Upon
318 return, all modules are at closed state.
319
320 No SME APIs can be involved after sme_Close except sme_Open.
321 sme_Close must be called before macClose.
322
323 \param hHal - The handle returned by macOpen.
324
325 \return eHAL_STATUS_SUCCESS - SME is successfully close.
326
327 Other status means SME is failed to be closed but caller still cannot
328 call any other SME functions except smeOpen.
329 \sa
330
331 --------------------------------------------------------------------------*/
332eHalStatus sme_Close(tHalHandle hHal);
333
334/*--------------------------------------------------------------------------
335
336 \brief sme_Start() - Put all SME modules at ready state.
337
338 The function starts each module in SME, PMC, CCM, CSR, etc. . Upon
339 successfully return, all modules are ready to run.
340
341 \param hHal - The handle returned by macOpen.
342
343 \return eHAL_STATUS_SUCCESS - SME is ready.
344
345 Other status means SME is failed to start.
346 \sa
347
348 --------------------------------------------------------------------------*/
349eHalStatus sme_Start(tHalHandle hHal);
350
351/*--------------------------------------------------------------------------
352
353 \brief sme_Stop() - Stop all SME modules and put them at idle state
354
355 The function stops each module in SME, PMC, CCM, CSR, etc. . Upon
356 return, all modules are at idle state ready to start.
357
358
359 \param hHal - The handle returned by macOpen.
360
Kiet Lama72a2322013-11-15 11:18:11 +0530361 \param tHalStopType - reason for stopping
Jeff Johnson295189b2012-06-20 16:38:30 -0700362
363 \return eHAL_STATUS_SUCCESS - SME is stopped.
364
365 Other status means SME is failed to stop but caller should still consider
366 SME is stopped.
367 \sa
368
369 --------------------------------------------------------------------------*/
Kiet Lama72a2322013-11-15 11:18:11 +0530370eHalStatus sme_Stop(tHalHandle hHal, tHalStopType stopType);
Jeff Johnson295189b2012-06-20 16:38:30 -0700371
372
373/*--------------------------------------------------------------------------
374
375 \brief sme_OpenSession() - Open a session for scan/roam operation.
376
377 This is a synchronous API.
378
379
380 \param hHal - The handle returned by macOpen.
381 \param callback - A pointer to the function caller specifies for roam/connect status indication
382 \param pContext - The context passed with callback
383 \param pSelfMacAddr - Caller allocated memory filled with self MAC address (6 bytes)
384 \param pbSessionId - pointer to a caller allocated buffer for returned session ID
385
386 \return eHAL_STATUS_SUCCESS - session is opened. sessionId returned.
387
388 Other status means SME is failed to open the session.
389 eHAL_STATUS_RESOURCES - no more session available.
390 \sa
391
392 --------------------------------------------------------------------------*/
Kiran Kumar Lokere0ad5cd32013-06-25 11:26:22 -0700393eHalStatus sme_OpenSession(tHalHandle hHal, csrRoamCompleteCallback callback,
394 void *pContext, tANI_U8 *pSelfMacAddr,
395 tANI_U8 *pbSessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -0700396
Kiran Kumar Lokere0ad5cd32013-06-25 11:26:22 -0700397/*--------------------------------------------------------------------------
398
399 \brief sme_SetCurrDeviceMode() - Sets the current operating device mode.
400 \param hHal - The handle returned by macOpen.
401 \param currDeviceMode - Current operating device mode.
402 --------------------------------------------------------------------------*/
403
404void sme_SetCurrDeviceMode (tHalHandle hHal, tVOS_CON_MODE currDeviceMode);
Jeff Johnson295189b2012-06-20 16:38:30 -0700405
406/*--------------------------------------------------------------------------
407
408 \brief sme_CloseSession() - Open a session for scan/roam operation.
409
410 This is a synchronous API.
411
412
413 \param hHal - The handle returned by macOpen.
414
415 \param sessionId - A previous opened session's ID.
416
417 \return eHAL_STATUS_SUCCESS - session is closed.
418
419 Other status means SME is failed to open the session.
420 eHAL_STATUS_INVALID_PARAMETER - session is not opened.
421 \sa
422
423 --------------------------------------------------------------------------*/
424eHalStatus sme_CloseSession(tHalHandle hHal, tANI_U8 sessionId,
425 csrRoamSessionCloseCallback callback, void *pContext);
426
427
428
429/*--------------------------------------------------------------------------
430
431 \brief sme_UpdateConfig() - Change configurations for all SME moduels
432
433 The function updates some configuration for modules in SME, CCM, CSR, etc
434 during SMEs close -> open sequence.
435
436 Modules inside SME apply the new configuration at the next transaction.
437
438
439 \param hHal - The handle returned by macOpen.
440 \Param pSmeConfigParams - a pointer to a caller allocated object of
441 typedef struct _smeConfigParams.
442
443 \return eHAL_STATUS_SUCCESS - SME update the config parameters successfully.
444
445 Other status means SME is failed to update the config parameters.
446 \sa
447
448 --------------------------------------------------------------------------*/
449eHalStatus sme_UpdateConfig(tHalHandle hHal, tpSmeConfigParams pSmeConfigParams);
450
451#ifdef FEATURE_WLAN_SCAN_PNO
452/*--------------------------------------------------------------------------
453
454 \brief sme_UpdateChannelConfig() - Update channel configuration in RIVA.
455
456 It is used at driver start up to inform RIVA of the default channel
457 configuration.
458
459 This is a synchronuous call
460
461 \param hHal - The handle returned by macOpen.
462
463 \return eHAL_STATUS_SUCCESS - SME update the channel config successfully.
464
465 Other status means SME is failed to update the channel config.
466 \sa
467
468 --------------------------------------------------------------------------*/
469eHalStatus sme_UpdateChannelConfig(tHalHandle hHal);
470
471#endif // FEATURE_WLAN_SCAN_PNLO
Jeff Johnson295189b2012-06-20 16:38:30 -0700472/*--------------------------------------------------------------------------
Abhishek Singhf644b272014-08-21 02:59:39 +0530473
474 \brief sme_UpdateChannelList() - Update channel List in FW.
475
476
477 \param hHal - The handle returned by macOpen.
478
479 \return eHAL_STATUS_SUCCESS - SME update the channel config successfully.
480
481 Other status means SME is failed to update the channel config.
482 \sa
483
484 --------------------------------------------------------------------------*/
485eHalStatus sme_UpdateChannelList(tHalHandle hHal);
486
487/*--------------------------------------------------------------------------
Jeff Johnson295189b2012-06-20 16:38:30 -0700488
489 \brief sme_set11dinfo() - Set the 11d information about valid channels
490 and there power using information from nvRAM
491 This function is called only for AP.
492
493 This is a synchronuous call
494
495 \param hHal - The handle returned by macOpen.
496 \Param pSmeConfigParams - a pointer to a caller allocated object of
497 typedef struct _smeConfigParams.
498
499 \return eHAL_STATUS_SUCCESS - SME update the config parameters successfully.
500
501 Other status means SME is failed to update the config parameters.
502 \sa
503--------------------------------------------------------------------------*/
504
505eHalStatus sme_set11dinfo(tHalHandle hHal, tpSmeConfigParams pSmeConfigParams);
506
507/*--------------------------------------------------------------------------
508
509 \brief sme_getSoftApDomain() - Get the current regulatory domain of softAp.
510
511 This is a synchronuous call
512
513 \param hHal - The handle returned by HostapdAdapter.
514 \Param v_REGDOMAIN_t - The current Regulatory Domain requested for SoftAp.
515
516 \return eHAL_STATUS_SUCCESS - SME successfully completed the request.
517
518 Other status means, failed to get the current regulatory domain.
519 \sa
520--------------------------------------------------------------------------*/
521
522eHalStatus sme_getSoftApDomain(tHalHandle hHal, v_REGDOMAIN_t *domainIdSoftAp);
523
524eHalStatus sme_setRegInfo(tHalHandle hHal, tANI_U8 *apCntryCode);
525
Jeff Johnson295189b2012-06-20 16:38:30 -0700526
527/* ---------------------------------------------------------------------------
528 \fn sme_ChangeConfigParams
529 \brief The SME API exposed for HDD to provide config params to SME during
530 SMEs stop -> start sequence.
531
532 If HDD changed the domain that will cause a reset. This function will
533 provide the new set of 11d information for the new domain. Currrently this
534 API provides info regarding 11d only at reset but we can extend this for
535 other params (PMC, QoS) which needs to be initialized again at reset.
536
537 This is a synchronuous call
538
539 \param hHal - The handle returned by macOpen.
540
541 \Param
542 pUpdateConfigParam - a pointer to a structure (tCsrUpdateConfigParam) that
543 currently provides 11d related information like Country code,
544 Regulatory domain, valid channel list, Tx power per channel, a
545 list with active/passive scan allowed per valid channel.
546
547 \return eHalStatus
548 ---------------------------------------------------------------------------*/
549eHalStatus sme_ChangeConfigParams(tHalHandle hHal,
550 tCsrUpdateConfigParam *pUpdateConfigParam);
551
552/*--------------------------------------------------------------------------
553
554 \brief sme_HDDReadyInd() - SME sends eWNI_SME_SYS_READY_IND to PE to inform that the NIC
555 is ready tio run.
556
557 The function is called by HDD at the end of initialization stage so PE/HAL can enable the NIC
558 to running state.
559
560
561 \param hHal - The handle returned by macOpen.
562
563 \return eHAL_STATUS_SUCCESS - eWNI_SME_SYS_READY_IND is sent to PE successfully.
564
565 Other status means SME failed to send the message to PE.
566 \sa
567
568 --------------------------------------------------------------------------*/
569eHalStatus sme_HDDReadyInd(tHalHandle hHal);
570
571
572/*--------------------------------------------------------------------------
573
574 \brief sme_ProcessMsg() - The main message processor for SME.
575
576 The function is called by a message dispatcher when to process a message
577 targeted for SME.
578
579
580 \param hHal - The handle returned by macOpen.
581 \param pMsg - A pointer to a caller allocated object of tSirMsgQ.
582
583 \return eHAL_STATUS_SUCCESS - SME successfully process the message.
584
585 Other status means SME failed to process the message.
586 \sa
587
588 --------------------------------------------------------------------------*/
589eHalStatus sme_ProcessMsg(tHalHandle hHal, vos_msg_t* pMsg);
590
591v_VOID_t sme_FreeMsg( tHalHandle hHal, vos_msg_t* pMsg );
592
593/* ---------------------------------------------------------------------------
594 \fn sme_ScanRequest
595 \brief a wrapper function to Request a 11d or full scan from CSR.
596 \param pScanRequestID - pointer to an object to get back the request ID
597 \param callback - a callback function that scan calls upon finish, will not
598 be called if csrScanRequest returns error
599 \param pContext - a pointer passed in for the callback
600 \return eHalStatus
601 ---------------------------------------------------------------------------*/
602eHalStatus sme_ScanRequest(tHalHandle hHal, tANI_U8 sessionId, tCsrScanRequest *,
603 tANI_U32 *pScanRequestID,
604 csrScanCompleteCallback callback, void *pContext);
605
606
607/* ---------------------------------------------------------------------------
608 \fn sme_ScanSetBGScanparams
609 \brief a wrapper function to request CSR to set BG scan params in PE
610 \param pScanReq - BG scan request structure
611 \return eHalStatus
612 ---------------------------------------------------------------------------*/
613eHalStatus sme_ScanSetBGScanparams(tHalHandle hHal, tANI_U8 sessionId, tCsrBGScanRequest *pScanReq);
614
615
616/* ---------------------------------------------------------------------------
617 \fn sme_ScanGetResult
618 \brief a wrapper function to request scan results from CSR.
619 \param pFilter - If pFilter is NULL, all cached results are returned
620 \param phResult - an object for the result.
621 \return eHalStatus
622 ---------------------------------------------------------------------------*/
623eHalStatus sme_ScanGetResult(tHalHandle hHal, tANI_U8 sessionId, tCsrScanResultFilter *pFilter,
624 tScanResultHandle *phResult);
625
626
627/* ---------------------------------------------------------------------------
628 \fn sme_ScanFlushResult
629 \brief a wrapper function to request CSR to clear scan results.
630 \return eHalStatus
631 ---------------------------------------------------------------------------*/
632eHalStatus sme_ScanFlushResult(tHalHandle hHal, tANI_U8 sessionId);
Srinivas, Dasari42bf7702014-02-07 11:29:53 +0530633
634/*
635 * ---------------------------------------------------------------------------
636 * \fn sme_FilterScanResults
637 * \brief a wrapper function to request CSR to filter the scan results based
638 * on valid chennel list.
639 * \return eHalStatus
640 *---------------------------------------------------------------------------
641 */
642eHalStatus sme_FilterScanResults(tHalHandle hHal, tANI_U8 sessionId);
643
Madan Mohan Koyyalamudia3fcf142012-10-18 15:01:20 -0700644eHalStatus sme_ScanFlushP2PResult(tHalHandle hHal, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -0700645
646/* ---------------------------------------------------------------------------
647 \fn sme_ScanResultGetFirst
648 \brief a wrapper function to request CSR to returns the first element of
649 scan result.
650 \param hScanResult - returned from csrScanGetResult
651 \return tCsrScanResultInfo * - NULL if no result
652 ---------------------------------------------------------------------------*/
653tCsrScanResultInfo *sme_ScanResultGetFirst(tHalHandle,
654 tScanResultHandle hScanResult);
655
656/* ---------------------------------------------------------------------------
657 \fn sme_ScanResultGetNext
658 \brief a wrapper function to request CSR to returns the next element of
659 scan result. It can be called without calling csrScanResultGetFirst
660 first
661 \param hScanResult - returned from csrScanGetResult
662 \return Null if no result or reach the end
663 ---------------------------------------------------------------------------*/
664tCsrScanResultInfo *sme_ScanResultGetNext(tHalHandle,
665 tScanResultHandle hScanResult);
666
667/* ---------------------------------------------------------------------------
668 \fn sme_ScanResultPurge
669 \brief a wrapper function to request CSR to remove all items(tCsrScanResult)
670 in the list and free memory for each item
671 \param hScanResult - returned from csrScanGetResult. hScanResult is
672 considered gone by
673 calling this function and even before this function reutrns.
674 \return eHalStatus
675 ---------------------------------------------------------------------------*/
676eHalStatus sme_ScanResultPurge(tHalHandle hHal, tScanResultHandle hScanResult);
677
678/* ---------------------------------------------------------------------------
679 \fn sme_ScanGetPMKIDCandidateList
680 \brief a wrapper function to return the PMKID candidate list
681 \param pPmkidList - caller allocated buffer point to an array of
682 tPmkidCandidateInfo
683 \param pNumItems - pointer to a variable that has the number of
684 tPmkidCandidateInfo allocated when retruning, this is
685 either the number needed or number of items put into
686 pPmkidList
687 \return eHalStatus - when fail, it usually means the buffer allocated is not
688 big enough and pNumItems
689 has the number of tPmkidCandidateInfo.
690 \Note: pNumItems is a number of tPmkidCandidateInfo,
691 not sizeof(tPmkidCandidateInfo) * something
692 ---------------------------------------------------------------------------*/
693eHalStatus sme_ScanGetPMKIDCandidateList(tHalHandle hHal, tANI_U8 sessionId,
694 tPmkidCandidateInfo *pPmkidList,
695 tANI_U32 *pNumItems );
696
697
698/*----------------------------------------------------------------------------
699 \fn sme_RoamRegisterLinkQualityIndCallback
700
701 \brief
702 a wrapper function to allow HDD to register a callback handler with CSR for
703 link quality indications.
704
705 Only one callback may be registered at any time.
706 In order to deregister the callback, a NULL cback may be provided.
707
708 Registration happens in the task context of the caller.
709
710 \param callback - Call back being registered
711 \param pContext - user data
712
713 DEPENDENCIES: After CSR open
714
715 \return eHalStatus
716-----------------------------------------------------------------------------*/
717eHalStatus sme_RoamRegisterLinkQualityIndCallback(tHalHandle hHal, tANI_U8 sessionId,
718 csrRoamLinkQualityIndCallback callback,
719 void *pContext);
720
721
722/* ---------------------------------------------------------------------------
723 \fn sme_RoamConnect
724 \brief a wrapper function to request CSR to inititiate an association
725 \param sessionId - the sessionId returned by sme_OpenSession.
726 \param pProfile - can be NULL to join to any open ones
727 \param pRoamId - to get back the request ID
728 \return eHalStatus
729 ---------------------------------------------------------------------------*/
730eHalStatus sme_RoamConnect(tHalHandle hHal, tANI_U8 sessionId, tCsrRoamProfile *pProfile,
731 tANI_U32 *pRoamId);
732
733/* ---------------------------------------------------------------------------
734 \fn sme_RoamReassoc
735 \brief a wrapper function to request CSR to inititiate a re-association
736 \param pProfile - can be NULL to join the currently connected AP. In that
737 case modProfileFields should carry the modified field(s) which could trigger
738 reassoc
739 \param modProfileFields - fields which are part of tCsrRoamConnectedProfile
740 that might need modification dynamically once STA is up & running and this
741 could trigger a reassoc
742 \param pRoamId - to get back the request ID
743 \return eHalStatus
744 -------------------------------------------------------------------------------*/
745eHalStatus sme_RoamReassoc(tHalHandle hHal, tANI_U8 sessionId, tCsrRoamProfile *pProfile,
746 tCsrRoamModifyProfileFields modProfileFields,
Madan Mohan Koyyalamudiea22cdc2012-10-18 21:02:23 -0700747 tANI_U32 *pRoamId, v_BOOL_t fForce);
Jeff Johnson295189b2012-06-20 16:38:30 -0700748
749/* ---------------------------------------------------------------------------
750 \fn sme_RoamConnectToLastProfile
751 \brief a wrapper function to request CSR to disconnect and reconnect with
752 the same profile
753 \return eHalStatus. It returns fail if currently connected
754 ---------------------------------------------------------------------------*/
755eHalStatus sme_RoamConnectToLastProfile(tHalHandle hHal, tANI_U8 sessionId);
756
757/* ---------------------------------------------------------------------------
758 \fn sme_RoamDisconnect
759 \brief a wrapper function to request CSR to disconnect from a network
760 \param reason -- To indicate the reason for disconnecting. Currently, only
761 eCSR_DISCONNECT_REASON_MIC_ERROR is meanful.
762 \return eHalStatus
763 ---------------------------------------------------------------------------*/
764eHalStatus sme_RoamDisconnect(tHalHandle hHal, tANI_U8 sessionId, eCsrRoamDisconnectReason reason);
765
Jeff Johnson295189b2012-06-20 16:38:30 -0700766/* ---------------------------------------------------------------------------
767 \fn sme_RoamStopBss
768 \brief a wrapper function to request CSR to stop bss
769 \param sessionId - sessionId of SoftAP
770 \return eHalStatus
771 ---------------------------------------------------------------------------*/
772eHalStatus sme_RoamStopBss(tHalHandle hHal, tANI_U8 sessionId);
773
774/* ---------------------------------------------------------------------------
775 \fn sme_RoamGetAssociatedStas
776 \brief To probe the list of associated stations from various modules of CORE stack.
777 \This is an asynchronous API.
778 \param sessionId - sessionId of SoftAP
779 \param modId - Module from whom list of associtated stations is to be probed.
780 If an invalid module is passed then by default VOS_MODULE_ID_PE will be probed
781 \param pUsrContext - Opaque HDD context
782 \param pfnSapEventCallback - Sap event callback in HDD
783 \param pAssocBuf - Caller allocated memory to be filled with associatd stations info
784 \return eHalStatus
785 -------------------------------------------------------------------------------*/
786eHalStatus sme_RoamGetAssociatedStas(tHalHandle hHal, tANI_U8 sessionId,
787 VOS_MODULE_ID modId, void *pUsrContext,
788 void *pfnSapEventCallback, tANI_U8 *pAssocStasBuf);
789
790/* ---------------------------------------------------------------------------
791 \fn sme_RoamDisconnectSta
792 \brief To disassociate a station. This is an asynchronous API.
793 \param pPeerMacAddr - Caller allocated memory filled with peer MAC address (6 bytes)
794 \return eHalStatus SUCCESS Roam callback will be called to indicate actual results
795 -------------------------------------------------------------------------------*/
796eHalStatus sme_RoamDisconnectSta(tHalHandle hHal, tANI_U8 sessionId, tANI_U8 *pPeerMacAddr);
797
798/* ---------------------------------------------------------------------------
799 \fn sme_RoamDeauthSta
800 \brief To disassociate a station. This is an asynchronous API.
801 \param hHal - Global structure
802 \param sessionId - sessionId of SoftAP
803 \param pPeerMacAddr - Caller allocated memory filled with peer MAC address (6 bytes)
804 \return eHalStatus SUCCESS Roam callback will be called to indicate actual results
805 -------------------------------------------------------------------------------*/
806eHalStatus sme_RoamDeauthSta(tHalHandle hHal, tANI_U8 sessionId,
807 tANI_U8 *pPeerMacAddr);
808
809/* ---------------------------------------------------------------------------
810 \fn sme_RoamTKIPCounterMeasures
811 \brief To start or stop TKIP counter measures. This is an asynchronous API.
812 \param sessionId - sessionId of SoftAP
813 \param bEnable - Flag to start/stop TKIP countermeasures
814 \return eHalStatus SUCCESS Roam callback will be called to indicate actual results
815 -------------------------------------------------------------------------------*/
816eHalStatus sme_RoamTKIPCounterMeasures(tHalHandle hHal, tANI_U8 sessionId, tANI_BOOLEAN bEnable);
817
818/* ---------------------------------------------------------------------------
819 \fn sme_RoamGetWpsSessionOverlap
820 \brief To get the WPS PBC session overlap information.
821 \This is an asynchronous API.
822 \param sessionId - sessionId of SoftAP
823 \param pUsrContext - Opaque HDD context
824 \param pfnSapEventCallback - Sap event callback in HDD
825 \return eHalStatus
826 -------------------------------------------------------------------------------*/
827eHalStatus sme_RoamGetWpsSessionOverlap(tHalHandle hHal, tANI_U8 sessionId,
828 void *pUsrContext, void *pfnSapEventCallback,
829 v_MACADDR_t pRemoveMac);
Jeff Johnson295189b2012-06-20 16:38:30 -0700830
831/* ---------------------------------------------------------------------------
832 \fn sme_RoamGetConnectState
833 \brief a wrapper function to request CSR to return the current connect state
834 of Roaming
835 \return eHalStatus
836 ---------------------------------------------------------------------------*/
837eHalStatus sme_RoamGetConnectState(tHalHandle hHal, tANI_U8 sessionId, eCsrConnectState *pState);
838
839/* ---------------------------------------------------------------------------
840 \fn sme_RoamGetConnectProfile
841 \brief a wrapper function to request CSR to return the current connect
842 profile. Caller must call csrRoamFreeConnectProfile after it is done
843 and before reuse for another csrRoamGetConnectProfile call.
844 \param pProfile - pointer to a caller allocated structure
845 tCsrRoamConnectedProfile
846 \return eHalStatus. Failure if not connected
847 ---------------------------------------------------------------------------*/
848eHalStatus sme_RoamGetConnectProfile(tHalHandle hHal, tANI_U8 sessionId,
849 tCsrRoamConnectedProfile *pProfile);
850
851/* ---------------------------------------------------------------------------
852 \fn sme_RoamFreeConnectProfile
853 \brief a wrapper function to request CSR to free and reinitialize the
854 profile returned previously by csrRoamGetConnectProfile.
855 \param pProfile - pointer to a caller allocated structure
856 tCsrRoamConnectedProfile
857 \return eHalStatus.
858 ---------------------------------------------------------------------------*/
859eHalStatus sme_RoamFreeConnectProfile(tHalHandle hHal,
860 tCsrRoamConnectedProfile *pProfile);
861
862/* ---------------------------------------------------------------------------
863 \fn sme_RoamSetPMKIDCache
864 \brief a wrapper function to request CSR to return the PMKID candidate list
865 \param pPMKIDCache - caller allocated buffer point to an array of
866 tPmkidCacheInfo
867 \param numItems - a variable that has the number of tPmkidCacheInfo
868 allocated when retruning, this is either the number needed
869 or number of items put into pPMKIDCache
Kanchanapally, Vidyullatha2633ace2014-09-25 15:16:50 +0530870 \param update_entire_cache - if TRUE, then it overwrites the entire cache
871 with pPMKIDCache, else it updates entry by
872 entry without deleting the old entries.
Jeff Johnson295189b2012-06-20 16:38:30 -0700873 \return eHalStatus - when fail, it usually means the buffer allocated is not
874 big enough and pNumItems has the number of
875 tPmkidCacheInfo.
876 \Note: pNumItems is a number of tPmkidCacheInfo,
877 not sizeof(tPmkidCacheInfo) * something
878 ---------------------------------------------------------------------------*/
Kanchanapally, Vidyullatha2633ace2014-09-25 15:16:50 +0530879eHalStatus sme_RoamSetPMKIDCache( tHalHandle hHal, tANI_U8 sessionId,
880 tPmkidCacheInfo *pPMKIDCache,
881 tANI_U32 numItems,
882 tANI_BOOLEAN update_entire_cache );
Jeff Johnson295189b2012-06-20 16:38:30 -0700883
884/* ---------------------------------------------------------------------------
885 \fn sme_RoamGetSecurityReqIE
886 \brief a wrapper function to request CSR to return the WPA or RSN or WAPI IE CSR
887 passes to PE to JOIN request or START_BSS request
888 This is a synchronuous call.
889 \param sessionId - returned by sme_OpenSession.
890 \param pLen - caller allocated memory that has the length of pBuf as input.
891 Upon returned, *pLen has the needed or IE length in pBuf.
892 \param pBuf - Caller allocated memory that contain the IE field, if any,
893 upon return
894 \param secType - Specifies whether looking for WPA/WPA2/WAPI IE
895 \return eHalStatus - when fail, it usually means the buffer allocated is not
896 big enough
897 ---------------------------------------------------------------------------*/
898eHalStatus sme_RoamGetSecurityReqIE(tHalHandle hHal, tANI_U8 sessionId, tANI_U32 *pLen,
899 tANI_U8 *pBuf, eCsrSecurityType secType);
900
901/* ---------------------------------------------------------------------------
902 \fn sme_RoamGetSecurityRspIE
903 \brief a wrapper function to request CSR to return the WPA or RSN or WAPI IE from
904 the beacon or probe rsp if connected
905 \param sessionId - returned by sme_OpenSession.
906 \param pLen - caller allocated memory that has the length of pBuf as input.
907 Upon returned, *pLen has the needed or IE length in pBuf.
908 \param pBuf - Caller allocated memory that contain the IE field, if any,
909 upon return
910 \param secType - Specifies whether looking for WPA/WPA2/WAPI IE
911 \return eHalStatus - when fail, it usually means the buffer allocated is not
912 big enough
913 ---------------------------------------------------------------------------*/
914eHalStatus sme_RoamGetSecurityRspIE(tHalHandle hHal, tANI_U8 sessionId, tANI_U32 *pLen,
915 tANI_U8 *pBuf, eCsrSecurityType secType);
916
917
918/* ---------------------------------------------------------------------------
919 \fn sme_RoamGetNumPMKIDCache
920 \brief a wrapper function to request CSR to return number of PMKID cache
921 entries
922 \return tANI_U32 - the number of PMKID cache entries
923 ---------------------------------------------------------------------------*/
924tANI_U32 sme_RoamGetNumPMKIDCache(tHalHandle hHal, tANI_U8 sessionId);
925
926/* ---------------------------------------------------------------------------
927 \fn sme_RoamGetPMKIDCache
928 \brief a wrapper function to request CSR to return PMKID cache from CSR
929 \param pNum - caller allocated memory that has the space of the number of
930 pBuf tPmkidCacheInfo as input. Upon returned, *pNum has the
931 needed or actually number in tPmkidCacheInfo.
932 \param pPmkidCache - Caller allocated memory that contains PMKID cache, if
933 any, upon return
934 \return eHalStatus - when fail, it usually means the buffer allocated is not
935 big enough
936 ---------------------------------------------------------------------------*/
937eHalStatus sme_RoamGetPMKIDCache(tHalHandle hHal, tANI_U8 sessionId, tANI_U32 *pNum,
938 tPmkidCacheInfo *pPmkidCache);
939
940/* ---------------------------------------------------------------------------
941 \fn sme_GetConfigParam
942 \brief a wrapper function that HDD calls to get the global settings
943 currently maintained by CSR.
944 \param pParam - caller allocated memory
945 \return eHalStatus
946 ---------------------------------------------------------------------------*/
947eHalStatus sme_GetConfigParam(tHalHandle hHal, tSmeConfigParams *pParam);
948
949/* ---------------------------------------------------------------------------
950 \fn sme_GetStatistics
951 \brief a wrapper function that client calls to register a callback to get
952 different PHY level statistics from CSR.
953
954 \param requesterId - different client requesting for statistics, HDD, UMA/GAN etc
955 \param statsMask - The different category/categories of stats requester is looking for
956 The order in which you set the bits in the statsMask for requesting
957 different type of stats is:
958
959 eCsrSummaryStats = bit 0
960 eCsrGlobalClassAStats = bit 1
961 eCsrGlobalClassBStats = bit 2
962 eCsrGlobalClassCStats = bit 3
963 eCsrGlobalClassDStats = bit 4
964 eCsrPerStaStats = bit 5
965
966 \param callback - SME sends back the requested stats using the callback
967 \param periodicity - If requester needs periodic update, 0 means it's an one
968 time request
969 \param cache - If requester is happy with cached stats
970 \param staId - The station ID for which the stats is requested for
971 \param pContext - user context to be passed back along with the callback
972 \return eHalStatus
973 ---------------------------------------------------------------------------*/
974eHalStatus sme_GetStatistics(tHalHandle hHal, eCsrStatsRequesterType requesterId,
975 tANI_U32 statsMask,
976 tCsrStatsCallback callback,
977 tANI_U32 periodicity, tANI_BOOLEAN cache,
978 tANI_U8 staId, void *pContext);
979
Madan Mohan Koyyalamudi8af9b402013-07-11 14:59:10 +0530980/* ---------------------------------------------------------------------------
981 \fn smeGetTLSTAState
982 \helper function to get teh TL STA State whenever the function is called.
983
984 \param staId - The staID to be passed to the TL
985 to get the relevant TL STA State
986 \return the state as tANI_U16
987 ---------------------------------------------------------------------------*/
988tANI_U16 smeGetTLSTAState(tHalHandle hHal, tANI_U8 staId);
989
Jeff Johnson295189b2012-06-20 16:38:30 -0700990eHalStatus sme_GetRssi(tHalHandle hHal,
991 tCsrRssiCallback callback,
992 tANI_U8 staId, tCsrBssid bssId, void *pContext, void* pVosContext);
Madan Mohan Koyyalamudid9383fd2013-08-13 09:27:30 +0530993
994/* ---------------------------------------------------------------------------
995 \fn sme_GetSnr
996 \brief a wrapper function that client calls to register a callback to get
997 SNR from FW
998
999 \param callback - SME sends back the requested stats using the callback
1000 \param staId - The station ID for which the stats is requested for
1001 \param bssid - The bssid of the connected session
1002 \param pContext - user context to be passed back along with the callback
1003 ---------------------------------------------------------------------------*/
1004eHalStatus sme_GetSnr(tHalHandle hHal,
1005 tCsrSnrCallback callback,
1006 tANI_U8 staId, tCsrBssid bssId,
1007 void *pContext);
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001008#if defined WLAN_FEATURE_VOWIFI_11R || defined FEATURE_WLAN_ESE || defined(FEATURE_WLAN_LFR)
Srinivas Girigowdad34cedb2013-01-25 13:33:11 -08001009eHalStatus sme_GetRoamRssi(tHalHandle hHal,
1010 tCsrRssiCallback callback,
1011 tANI_U8 staId,
1012 tCsrBssid bssId,
1013 void *pContext,
1014 void* pVosContext);
1015#endif
Srinivas Girigowda5cecb202013-10-08 09:13:25 -07001016
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001017#if defined(FEATURE_WLAN_ESE) && defined(FEATURE_WLAN_ESE_UPLOAD)
Srinivas Girigowda5cecb202013-10-08 09:13:25 -07001018/* ---------------------------------------------------------------------------
1019 \fn sme_GetTsmStats
1020 \brief a wrapper function that client calls to register a callback to get TSM Stats
1021
1022 \param callback - SME sends back the requested stats using the callback
1023 \param staId - The station ID for which the stats is requested for
1024 \param pContext - user context to be passed back along with the callback
1025 \param pVosContext - vos context
1026 \return eHalStatus
1027 ---------------------------------------------------------------------------*/
1028eHalStatus sme_GetTsmStats(tHalHandle hHal,
1029 tCsrTsmStatsCallback callback,
1030 tANI_U8 staId, tCsrBssid bssId,
1031 void *pContext, void* pVosContext, tANI_U8 tid);
1032
1033/* ---------------------------------------------------------------------------
1034 \fn sme_SetCCKMIe
1035 \brief function to store the CCKM IE passed from supplicant and use it while packing
1036 reassociation request
1037 \param hHal - HAL handle for device
1038 \param pCckmIe - pointer to CCKM IE data
1039 \param pCckmIeLen - length of the CCKM IE
1040 \- return Success or failure
1041 -------------------------------------------------------------------------*/
1042eHalStatus sme_SetCCKMIe(tHalHandle hHal, tANI_U8 sessionId, tANI_U8 *pCckmIe, tANI_U8 cckmIeLen);
1043
1044
Srinivas Girigowda91ccbe82013-11-10 16:37:38 -08001045/* ---------------------------------------------------------------------------
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001046 \fn sme_SetEseBeaconRequest
1047 \brief function to set ESE beacon request parameters
Srinivas Girigowda91ccbe82013-11-10 16:37:38 -08001048 \param hHal - HAL handle for device
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001049 \param pESEBcnReq - pointer to ESE beacon request
Srinivas Girigowda91ccbe82013-11-10 16:37:38 -08001050 \- return Success or failure
1051 -------------------------------------------------------------------------*/
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001052eHalStatus sme_SetEseBeaconRequest(tHalHandle hHal, const tANI_U8 sessionId,
1053 const tCsrEseBeaconReq* pEseBcnReq);
Srinivas Girigowda91ccbe82013-11-10 16:37:38 -08001054
1055
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08001056#endif /*FEATURE_WLAN_ESE && FEATURE_WLAN_ESE_UPLOAD */
Jeff Johnson295189b2012-06-20 16:38:30 -07001057/* ---------------------------------------------------------------------------
1058 \fn sme_CfgSetInt
1059 \brief a wrapper function that HDD calls to set parameters in CFG.
1060 \param cfgId - Configuration Parameter ID (type) for STA.
1061 \param ccmValue - The information related to Configuration Parameter ID
1062 which needs to be saved in CFG
1063 \param callback - To be registered by CSR with CCM. Once the CFG done with
1064 saving the information in the database, it notifies CCM &
1065 then the callback will be invoked to notify.
1066 \param toBeSaved - To save the request for future reference
1067 \return eHalStatus
1068 ---------------------------------------------------------------------------*/
1069eHalStatus sme_CfgSetInt(tHalHandle hHal, tANI_U32 cfgId, tANI_U32 ccmValue,
1070 tCcmCfgSetCallback callback, eAniBoolean toBeSaved) ;
1071
1072/* ---------------------------------------------------------------------------
1073 \fn sme_CfgSetStr
1074 \brief a wrapper function that HDD calls to set parameters in CFG.
1075 \param cfgId - Configuration Parameter ID (type) for STA.
1076 \param pStr - Pointer to the byte array which carries the information needs
1077 to be saved in CFG
1078 \param length - Length of the data to be saved
1079 \param callback - To be registered by CSR with CCM. Once the CFG done with
1080 saving the information in the database, it notifies CCM &
1081 then the callback will be invoked to notify.
1082 \param toBeSaved - To save the request for future reference
1083 \return eHalStatus
1084 ---------------------------------------------------------------------------*/
1085eHalStatus sme_CfgSetStr(tHalHandle hHal, tANI_U32 cfgId, tANI_U8 *pStr,
1086 tANI_U32 length, tCcmCfgSetCallback callback,
1087 eAniBoolean toBeSaved) ;
Sandeep Puligillaa3e76952014-06-23 15:53:11 +05301088/* ---------------------------------------------------------------------------
1089 \fn sme_GetModifyProfileFields
1090 \brief HDD or SME - QOS calls this function to get the current values of
1091 connected profile fields, changing which can cause reassoc.
1092 This function must be called after CFG is downloaded and STA is in connected
1093 state. Also, make sure to call this function to get the current profile
1094 fields before calling the reassoc. So that pModifyProfileFields will have
1095 all the latest values plus the one(s) has been updated as part of reassoc
1096 request.
1097 \param pModifyProfileFields - pointer to the connected profile fields
1098 changing which can cause reassoc
Jeff Johnson295189b2012-06-20 16:38:30 -07001099
Sandeep Puligillaa3e76952014-06-23 15:53:11 +05301100 \return eHalStatus
1101 -------------------------------------------------------------------------------*/
1102eHalStatus sme_GetModifyProfileFields(tHalHandle hHal, tANI_U8 sessionId,
1103 tCsrRoamModifyProfileFields * pModifyProfileFields);
Sandeep Puligilla332ea912014-02-04 00:16:24 +05301104/* ---------------------------------------------------------------------------
1105 \fn sme_HT40StopOBSSScan
1106 \brief HDD or SME - Command to stop the OBSS scan
1107 THis is implemented only for debugging purpose.
1108 As per spec while operating in 2.4GHz OBSS scan shouldnt be stopped.
1109 \param sessionId - sessionId
1110 changing which can cause reassoc
1111
1112 \return eHalStatus
1113 -------------------------------------------------------------------------------*/
1114eHalStatus sme_HT40StopOBSSScan(tHalHandle hHal, tANI_U8 sessionId );
Jeff Johnson295189b2012-06-20 16:38:30 -07001115
1116/*--------------------------------------------------------------------------
1117 \fn sme_SetConfigPowerSave
1118 \brief Wrapper fn to change power save configuration in SME (PMC) module.
1119 For BMPS related configuration, this function also updates the CFG
1120 and sends a message to FW to pick up the new values. Note: Calling
1121 this function only updates the configuration and does not enable
1122 the specified power save mode.
1123 \param hHal - The handle returned by macOpen.
1124 \param psMode - Power Saving mode being modified
1125 \param pConfigParams - a pointer to a caller allocated object of type
1126 tPmcSmpsConfigParams or tPmcBmpsConfigParams or tPmcImpsConfigParams
1127 \return eHalStatus
1128 --------------------------------------------------------------------------*/
1129eHalStatus sme_SetConfigPowerSave(tHalHandle hHal, tPmcPowerSavingMode psMode,
1130 void *pConfigParams);
1131
1132/*--------------------------------------------------------------------------
1133 \fn sme_GetConfigPowerSave
1134 \brief Wrapper fn to retireve power save configuration in SME (PMC) module
1135 \param hHal - The handle returned by macOpen.
1136 \param psMode - Power Saving mode
1137 \param pConfigParams - a pointer to a caller allocated object of type
1138 tPmcSmpsConfigParams or tPmcBmpsConfigParams or tPmcImpsConfigParams
1139 \return eHalStatus
1140 --------------------------------------------------------------------------*/
1141eHalStatus sme_GetConfigPowerSave(tHalHandle hHal, tPmcPowerSavingMode psMode,
1142 void *pConfigParams);
1143
1144/* ---------------------------------------------------------------------------
1145 \fn sme_SignalPowerEvent
1146 \brief Signals to PMC that a power event has occurred. Used for putting
1147 the chip into deep sleep mode.
1148 \param hHal - The handle returned by macOpen.
1149 \param event - the event that has occurred
1150 \return eHalStatus
1151 ---------------------------------------------------------------------------*/
1152extern eHalStatus sme_SignalPowerEvent (
1153 tHalHandle hHal,
1154 tPmcPowerEvent event);
1155
1156/* ---------------------------------------------------------------------------
1157 \fn sme_EnablePowerSave
1158 \brief Enables one of the power saving modes. This API does not cause a
1159 device state change. This is purely a configuration API.
1160 \param hHal - The handle returned by macOpen.
1161 \param psMode - The power saving mode to enable.
1162 \return eHalStatus
1163 ---------------------------------------------------------------------------*/
1164extern eHalStatus sme_EnablePowerSave (
1165 tHalHandle hHal,
1166 tPmcPowerSavingMode psMode);
1167
1168/* ---------------------------------------------------------------------------
1169 \fn sme_DisablePowerSave
1170 \brief Disables one of the power saving modes.Disabling does not imply
1171 that device will be brought out of the current PS mode. This is
1172 purely a configuration API.
1173 \param hHal - The handle returned by macOpen.
1174 \param psMode - The power saving mode to disable.
1175 \return eHalStatus
1176 ---------------------------------------------------------------------------*/
1177extern eHalStatus sme_DisablePowerSave (
1178 tHalHandle hHal,
1179 tPmcPowerSavingMode psMode);
1180
Madan Mohan Koyyalamudi69b34182013-01-16 08:51:40 +05301181 /* ---------------------------------------------------------------------------
1182 \fn sme_SetHostPowerSave
1183 \brief The BMPS logic is controlled by the User level Apps
1184 \param hHal - The handle returned by macOpen.
1185 \param psMode - The power saving mode to enable.
1186 \return eHalStatus
1187 ---------------------------------------------------------------------------*/
1188extern eHalStatus sme_SetHostPowerSave (
1189 tHalHandle hHal,
1190 v_BOOL_t psMode);
1191
Jeff Johnson295189b2012-06-20 16:38:30 -07001192/* ---------------------------------------------------------------------------
1193 \fn sme_StartAutoBmpsTimer
1194 \brief Starts a timer that periodically polls all the registered
1195 module for entry into Bmps mode. This timer is started only if BMPS is
1196 enabled and whenever the device is in full power.
1197 \param hHal - The handle returned by macOpen.
1198 \return eHalStatus
1199 ---------------------------------------------------------------------------*/
1200extern eHalStatus sme_StartAutoBmpsTimer ( tHalHandle hHal);
1201
1202/* ---------------------------------------------------------------------------
1203 \fn sme_StopAutoBmpsTimer
1204 \brief Stops the Auto BMPS Timer that was started using sme_startAutoBmpsTimer
1205 Stopping the timer does not cause a device state change. Only the timer
1206 is stopped. If "Full Power" is desired, use the sme_RequestFullPower API
1207 \param hHal - The handle returned by macOpen.
1208 \return eHalStatus
1209 ---------------------------------------------------------------------------*/
1210extern eHalStatus sme_StopAutoBmpsTimer ( tHalHandle hHal);
1211
1212/* ---------------------------------------------------------------------------
1213 \fn sme_QueryPowerState
1214 \brief Returns the current power state of the device.
1215 \param hHal - The handle returned by macOpen.
1216 \param pPowerState - pointer to location to return power state
1217 \param pSwWlanSwitchState - ptr to location to return SW WLAN Switch state
1218 \return eHalStatus
1219 ---------------------------------------------------------------------------*/
1220extern eHalStatus sme_QueryPowerState (
1221 tHalHandle hHal,
1222 tPmcPowerState *pPowerState,
1223 tPmcSwitchState *pSwWlanSwitchState);
1224
1225/* ---------------------------------------------------------------------------
1226 \fn sme_IsPowerSaveEnabled
1227 \brief Checks if the device is able to enter a particular power save mode
1228 This does not imply that the device is in a particular PS mode
1229 \param hHal - The handle returned by macOpen.
1230 \param psMode - the power saving mode
1231 \return eHalStatus
1232 ---------------------------------------------------------------------------*/
1233extern tANI_BOOLEAN sme_IsPowerSaveEnabled(
1234 tHalHandle hHal,
1235 tPmcPowerSavingMode psMode);
1236
1237/* ---------------------------------------------------------------------------
1238 \fn sme_RequestFullPower
1239 \brief Request that the device be brought to full power state.
1240 Note 1: If "fullPowerReason" specificied in this API is set to
1241 eSME_FULL_PWR_NEEDED_BY_HDD, PMC will clear any "buffered wowl" requests
1242 and also clear any "buffered BMPS requests by HDD". Assumption is that since
1243 HDD is requesting full power, we need to undo any previous HDD requests for
1244 BMPS (using sme_RequestBmps) or WoWL (using sme_EnterWoWL). If the reason is
1245 specified anything other than above, the buffered requests for BMPS and WoWL
1246 will not be cleared.
1247 Note 2: Requesting full power (no matter what the fullPowerReason is) doesn't
1248 disable the "auto bmps timer" (if it is enabled) or clear any "buffered uapsd
1249 request".
1250 Note 3: When the device finally enters Full Power PMC will start a timer
1251 if any of the following holds true:
1252 - Auto BMPS mode is enabled
1253 - Uapsd request is pending
1254 - HDD's request for BMPS is pending
1255 - HDD's request for WoWL is pending
1256 On timer expiry PMC will attempt to put the device in BMPS mode if following
1257 (in addition to those listed above) holds true:
1258 - Polling of all modules through the Power Save Check routine passes
1259 - STA is associated to an access point
1260 \param hHal - The handle returned by macOpen.
1261 \param - callbackRoutine Callback routine invoked in case of success/failure
1262 \param - callbackContext - Cookie to be passed back during callback
1263 \param - fullPowerReason - Reason why this API is being invoked. SME needs to
1264 distinguish between BAP and HDD requests
1265 \return eHalStatus - status
1266 eHAL_STATUS_SUCCESS - device brought to full power state
1267 eHAL_STATUS_FAILURE - device cannot be brought to full power state
1268 eHAL_STATUS_PMC_PENDING - device is being brought to full power state,
1269 ---------------------------------------------------------------------------*/
1270extern eHalStatus sme_RequestFullPower (
1271 tHalHandle hHal,
1272 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
1273 void *callbackContext,
1274 tRequestFullPowerReason fullPowerReason);
1275
1276/* ---------------------------------------------------------------------------
1277 \fn sme_RequestBmps
1278 \brief Request that the device be put in BMPS state. Request will be
1279 accepted only if BMPS mode is enabled and power save check routine
1280 passes. Only HDD should invoke this API.
1281 \param hHal - The handle returned by macOpen.
1282 \param - callbackRoutine Callback routine invoked in case of success/failure
1283 \param - callbackContext - Cookie to be passed back during callback
1284 \return eHalStatus
1285 eHAL_STATUS_SUCCESS - device is in BMPS state
1286 eHAL_STATUS_FAILURE - device cannot be brought to BMPS state
1287 eHAL_STATUS_PMC_PENDING - device is being brought to BMPS state
1288 ---------------------------------------------------------------------------*/
1289extern eHalStatus sme_RequestBmps (
1290 tHalHandle hHal,
1291 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
1292 void *callbackContext);
1293
1294/* ---------------------------------------------------------------------------
1295 \fn sme_SetDHCPTillPowerActiveFlag
1296 \brief Sets/Clears DHCP related flag in PMC to disable/enable auto BMPS
1297 entry by PMC
1298 \param hHal - The handle returned by macOpen.
1299 ---------------------------------------------------------------------------*/
1300void sme_SetDHCPTillPowerActiveFlag(tHalHandle hHal, tANI_U8 flag);
1301
1302
1303/* ---------------------------------------------------------------------------
1304 \fn sme_StartUapsd
1305 \brief Request that the device be put in UAPSD state. If the device is in
1306 Full Power it will be put in BMPS mode first and then into UAPSD
1307 mode.
1308 \param hHal - The handle returned by macOpen.
1309 \param - callbackRoutine Callback routine invoked in case of success/failure
1310 \param - callbackContext - Cookie to be passed back during callback
1311 eHAL_STATUS_SUCCESS - device is in UAPSD state
1312 eHAL_STATUS_FAILURE - device cannot be brought to UAPSD state
1313 eHAL_STATUS_PMC_PENDING - device is being brought to UAPSD state
1314 eHAL_STATUS_PMC_DISABLED - UAPSD is disabled or BMPS mode is disabled
1315 \return eHalStatus
1316 ---------------------------------------------------------------------------*/
1317extern eHalStatus sme_StartUapsd (
1318 tHalHandle hHal,
1319 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
1320 void *callbackContext);
1321
1322/* ---------------------------------------------------------------------------
1323 \fn sme_StopUapsd
1324 \brief Request that the device be put out of UAPSD state. Device will be
1325 put in in BMPS state after stop UAPSD completes. Buffered requests for
1326 UAPSD will be cleared after this.
1327 \param hHal - The handle returned by macOpen.
1328 \return eHalStatus
1329 eHAL_STATUS_SUCCESS - device is put out of UAPSD and back in BMPS state
1330 eHAL_STATUS_FAILURE - device cannot be brought out of UAPSD state
1331 ---------------------------------------------------------------------------*/
1332extern eHalStatus sme_StopUapsd (tHalHandle hHal);
1333
1334/* ---------------------------------------------------------------------------
1335 \fn sme_RequestStandby
1336 \brief Request that the device be put in standby. It is HDD's responsibility
1337 to bring the chip to full power and do a discconnect before calling
1338 this API. Request for standby will be rejected if STA is associated
1339 to an AP.
1340 \param hHal - The handle returned by macOpen.
1341 \param - callbackRoutine Callback routine invoked in case of success/failure
1342 \param - callbackContext - Cookie to be passed back during callback
1343 \return eHalStatus
1344 eHAL_STATUS_SUCCESS - device is in Standby mode
1345 eHAL_STATUS_FAILURE - device cannot be put in standby mode
1346 eHAL_STATUS_PMC_PENDING - device is being put in standby mode
1347 ---------------------------------------------------------------------------*/
1348extern eHalStatus sme_RequestStandby (
1349 tHalHandle hHal,
1350 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
1351 void *callbackContext);
1352
1353/* ---------------------------------------------------------------------------
1354 \fn sme_RegisterPowerSaveCheck
1355 \brief Register a power save check routine that is called whenever
1356 the device is about to enter one of the power save modes.
1357 \param hHal - The handle returned by macOpen.
1358 \param checkRoutine - Power save check routine to be registered
1359 \param callbackContext - Cookie to be passed back during callback
1360 \return eHalStatus
1361 eHAL_STATUS_SUCCESS - successfully registered
1362 eHAL_STATUS_FAILURE - not successfully registered
1363 ---------------------------------------------------------------------------*/
1364extern eHalStatus sme_RegisterPowerSaveCheck (
1365 tHalHandle hHal,
1366 tANI_BOOLEAN (*checkRoutine) (void *checkContext), void *checkContext);
1367
1368/* ---------------------------------------------------------------------------
Mihir Shetefc7ff5b2014-01-27 11:30:05 +05301369 \fn sme_Register11dScanDoneCallback
1370 \brief Register a routine of type csrScanCompleteCallback which is
1371 called whenever an 11d scan is done
1372 \param hHal - The handle returned by macOpen.
1373 \param callback - 11d scan complete routine to be registered
1374 \return eHalStatus
1375 ---------------------------------------------------------------------------*/
1376extern eHalStatus sme_Register11dScanDoneCallback (
1377 tHalHandle hHal,
1378 csrScanCompleteCallback);
1379
1380/* ---------------------------------------------------------------------------
Jeff Johnson295189b2012-06-20 16:38:30 -07001381 \fn sme_DeregisterPowerSaveCheck
1382 \brief Deregister a power save check routine
1383 \param hHal - The handle returned by macOpen.
1384 \param checkRoutine - Power save check routine to be deregistered
1385 \return eHalStatus
1386 eHAL_STATUS_SUCCESS - successfully deregistered
1387 eHAL_STATUS_FAILURE - not successfully deregistered
1388 ---------------------------------------------------------------------------*/
1389extern eHalStatus sme_DeregisterPowerSaveCheck (
1390 tHalHandle hHal,
1391 tANI_BOOLEAN (*checkRoutine) (void *checkContext));
1392
1393/* ---------------------------------------------------------------------------
1394 \fn sme_RegisterDeviceStateUpdateInd
1395 \brief Register a callback routine that is called whenever
1396 the device enters a new device state (Full Power, BMPS, UAPSD)
1397 \param hHal - The handle returned by macOpen.
1398 \param callbackRoutine - Callback routine to be registered
1399 \param callbackContext - Cookie to be passed back during callback
1400 \return eHalStatus
1401 eHAL_STATUS_SUCCESS - successfully registered
1402 eHAL_STATUS_FAILURE - not successfully registered
1403 ---------------------------------------------------------------------------*/
1404extern eHalStatus sme_RegisterDeviceStateUpdateInd (
1405 tHalHandle hHal,
1406 void (*callbackRoutine) (void *callbackContext, tPmcState pmcState),
1407 void *callbackContext);
1408
1409/* ---------------------------------------------------------------------------
1410 \fn sme_DeregisterDeviceStateUpdateInd
1411 \brief Deregister a routine that was registered for device state changes
1412 \param hHal - The handle returned by macOpen.
1413 \param callbackRoutine - Callback routine to be deregistered
1414 \return eHalStatus
1415 eHAL_STATUS_SUCCESS - successfully deregistered
1416 eHAL_STATUS_FAILURE - not successfully deregistered
1417 ---------------------------------------------------------------------------*/
1418extern eHalStatus sme_DeregisterDeviceStateUpdateInd (
1419 tHalHandle hHal,
1420 void (*callbackRoutine) (void *callbackContext, tPmcState pmcState));
1421
1422/* ---------------------------------------------------------------------------
1423 \fn sme_WowlAddBcastPattern
1424 \brief Add a pattern for Pattern Byte Matching in Wowl mode. Firmware will
1425 do a pattern match on these patterns when Wowl is enabled during BMPS
1426 mode.
1427 \param hHal - The handle returned by macOpen.
1428 \param pattern - Pattern to be added
1429 \return eHalStatus
1430 eHAL_STATUS_FAILURE Cannot add pattern
1431 eHAL_STATUS_SUCCESS Request accepted.
1432 ---------------------------------------------------------------------------*/
1433extern eHalStatus sme_WowlAddBcastPattern (
1434 tHalHandle hHal,
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07001435 tpSirWowlAddBcastPtrn pattern,
1436 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001437
1438/* ---------------------------------------------------------------------------
1439 \fn sme_WowlDelBcastPattern
1440 \brief Delete a pattern that was added for Pattern Byte Matching.
1441 \param hHal - The handle returned by macOpen.
1442 \param pattern - Pattern to be deleted
1443 \return eHalStatus
1444 eHAL_STATUS_FAILURE Cannot delete pattern
1445 eHAL_STATUS_SUCCESS Request accepted.
1446 ---------------------------------------------------------------------------*/
1447extern eHalStatus sme_WowlDelBcastPattern (
1448 tHalHandle hHal,
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07001449 tpSirWowlDelBcastPtrn pattern,
1450 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001451
1452/* ---------------------------------------------------------------------------
1453 \fn sme_EnterWowl
1454 \brief This is the API to request entry into WOWL mode.
1455 WoWLAN works on top of BMPS mode. If the device is not in BMPS mode,
1456 SME will will cache the information that WOWL has been requested and
1457 attempt to put the device in BMPS first. On entry into BMPS, SME will
1458 enter the WOWL mode.
1459 Note 1: After WoWL request is accepted, If module other than HDD requests
1460 full power BEFORE WoWL request is completed, PMC will buffer the WoWL request
1461 and attempt to put the chip into BMPS+WOWL based on a timer.
1462 Note 2: Buffered request for WoWL will be cleared immedisately AFTER "enter Wowl"
1463 completes or if HDD requests full power or if sme_ExitWoWL API is invoked.
1464 Note 3: Both UAPSD and WOWL work on top of BMPS. On entry into BMPS, SME
1465 will give priority to UAPSD and enable only UAPSD if both UAPSD and WOWL
1466 are required. Currently there is no requirement or use case to support UAPSD
1467 and WOWL at the same time.
1468 Note 4. Request for WoWL is rejected if there is a pending UAPSD request.
1469 Note 5. Request for WoWL is rejected if BMPS is disabled.
1470
1471 \param hHal - The handle returned by macOpen.
1472 \param enterWowlCallbackRoutine - Callback routine provided by HDD.
1473 Used for success/failure notification by SME
1474 \param enterWowlCallbackContext - A cookie passed by HDD, that is passed back to HDD
1475 at the time of callback.
1476 \param wakeReasonIndCB - Callback routine provided by HDD.
1477 Used for Wake Reason Indication by SME
1478 \param wakeReasonIndCBContext - A cookie passed by HDD, that is passed back to HDD
1479 at the time of callback.
1480 \return eHalStatus
1481 eHAL_STATUS_SUCCESS Device is already in WoWLAN mode
1482 eHAL_STATUS_FAILURE Device cannot enter WoWLAN mode.
1483 eHAL_STATUS_PMC_PENDING Request accepted. SME will enable WOWL when BMPS
1484 mode is entered.
1485 ---------------------------------------------------------------------------*/
1486extern eHalStatus sme_EnterWowl (
1487 tHalHandle hHal,
1488 void (*enterWowlCallbackRoutine) (void *callbackContext, eHalStatus status),
1489 void *enterWowlCallbackContext,
1490#ifdef WLAN_WAKEUP_EVENTS
1491 void (*wakeReasonIndCB) (void *callbackContext, tpSirWakeReasonInd pWakeReasonInd),
1492 void *wakeReasonIndCBContext,
1493#endif // WLAN_WAKEUP_EVENTS
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07001494 tpSirSmeWowlEnterParams wowlEnterParams, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001495
1496/* ---------------------------------------------------------------------------
1497 \fn sme_ExitWowl
1498 \brief This is the SME API exposed to HDD to request exit from WoWLAN mode.
1499 SME will initiate exit from WoWLAN mode and device will be put in BMPS
1500 mode. Any Buffered request for WoWL will be cleared after this API.
1501 \param hHal - The handle returned by macOpen.
1502 \return eHalStatus
1503 eHAL_STATUS_FAILURE Device cannot exit WoWLAN mode. This can happen
1504 only if the previous "Enter WOWL" transaction has
1505 not even completed.
1506 eHAL_STATUS_SUCCESS Request accepted to exit WoWLAN mode.
1507 ---------------------------------------------------------------------------*/
c_hpothu01484c02014-05-16 14:05:15 +05301508extern eHalStatus sme_ExitWowl (tHalHandle hHal, tWowlExitSource wowlExitSrc);
Jeff Johnson295189b2012-06-20 16:38:30 -07001509
1510/* ---------------------------------------------------------------------------
1511
1512 \fn sme_RoamSetKey
1513
1514 \brief To set encryption key. This function should be called only when connected
1515 This is an asynchronous API.
1516
1517 \param pSetKeyInfo - pointer to a caller allocated object of tCsrSetContextInfo
1518
1519 \param pRoamId Upon success return, this is the id caller can use to identify the request in roamcallback
1520
1521 \return eHalStatus SUCCESS Roam callback will be called indicate actually results
1522
1523 FAILURE or RESOURCES The API finished and failed.
1524
1525 -------------------------------------------------------------------------------*/
1526eHalStatus sme_RoamSetKey(tHalHandle, tANI_U8 sessionId, tCsrRoamSetKey *pSetKey, tANI_U32 *pRoamId);
1527
1528/* ---------------------------------------------------------------------------
1529
1530 \fn sme_RoamRemoveKey
1531
1532 \brief To set encryption key. This is an asynchronous API.
1533
1534 \param pRemoveKey - pointer to a caller allocated object of tCsrRoamRemoveKey
1535
1536 \param pRoamId Upon success return, this is the id caller can use to identify the request in roamcallback
1537
1538 \return eHalStatus SUCCESS Roam callback will be called indicate actually results
1539
1540 FAILURE or RESOURCES The API finished and failed.
1541
1542 -------------------------------------------------------------------------------*/
1543eHalStatus sme_RoamRemoveKey(tHalHandle, tANI_U8 sessionId, tCsrRoamRemoveKey *pRemoveKey, tANI_U32 *pRoamId);
1544
1545
1546/* ---------------------------------------------------------------------------
1547
1548 \fn sme_GetCountryCode
1549
1550 \brief To return the current country code. If no country code is applied, default country code is
1551 used to fill the buffer.
1552 If 11d supported is turned off, an error is return and the last applied/default country code is used.
1553 This is a synchronous API.
1554
1555 \param pBuf - pointer to a caller allocated buffer for returned country code.
1556
1557 \param pbLen For input, this parameter indicates how big is the buffer.
1558 Upon return, this parameter has the number of bytes for country. If pBuf
1559 doesn't have enough space, this function returns
1560 fail status and this parameter contains the number that is needed.
1561
1562 \return eHalStatus SUCCESS.
1563
1564 FAILURE or RESOURCES The API finished and failed.
1565
1566 -------------------------------------------------------------------------------*/
1567eHalStatus sme_GetCountryCode(tHalHandle hHal, tANI_U8 *pBuf, tANI_U8 *pbLen);
1568
1569/* ---------------------------------------------------------------------------
1570
1571 \fn sme_SetCountryCode
1572
1573 \brief To change the current/default country code.
1574 If 11d supported is turned off, an error is return.
1575 This is a synchronous API.
1576
1577 \param pCountry - pointer to a caller allocated buffer for the country code.
1578
1579 \param pfRestartNeeded A pointer to caller allocated memory, upon successful return, it indicates
1580 whether a reset is required.
1581
1582 \return eHalStatus SUCCESS.
1583
1584 FAILURE or RESOURCES The API finished and failed.
1585
1586 -------------------------------------------------------------------------------*/
1587eHalStatus sme_SetCountryCode(tHalHandle hHal, tANI_U8 *pCountry, tANI_BOOLEAN *pfRestartNeeded);
1588
1589/* ---------------------------------------------------------------------------
Mihir Shetee1093ba2014-01-21 20:13:32 +05301590
1591 \fn sme_InitChannels
1592
1593 \brief Used to initialize CSR channel lists while driver loading
1594
1595 \param hHal - global pMac structure
1596
1597 \return eHalStatus SUCCESS.
1598
1599 FAILURE or RESOURCES The API finished and failed.
1600
1601 -------------------------------------------------------------------------------*/
1602eHalStatus sme_InitChannels(tHalHandle hHal);
1603
Mahesh A Saptasagar74289d22014-05-14 12:43:37 +05301604
1605/* ---------------------------------------------------------------------------
1606 \fn sme_InitChannelsForCC
1607
1608 \brief Used to issue regulatory hint to user
1609
1610 \param hHal - global pMac structure
1611
1612 \return eHalStatus SUCCESS.
1613
1614 FAILURE or RESOURCES The API finished and failed.
1615
1616 -------------------------------------------------------------------------------*/
1617eHalStatus sme_InitChannelsForCC(tHalHandle hHal);
1618
Mihir Shetee1093ba2014-01-21 20:13:32 +05301619/* ---------------------------------------------------------------------------
Jeff Johnson295189b2012-06-20 16:38:30 -07001620 \fn sme_ResetCountryCodeInformation
1621 \brief this function is to reset the country code current being used back to EEPROM default
1622 this includes channel list and power setting. This is a synchronous API.
1623 \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether
1624 a restart is needed to apply the change
1625 \return eHalStatus
1626 -------------------------------------------------------------------------------*/
1627eHalStatus sme_ResetCountryCodeInformation(tHalHandle hHal, tANI_BOOLEAN *pfRestartNeeded);
1628
1629/* ---------------------------------------------------------------------------
1630 \fn sme_GetSupportedCountryCode
1631 \brief this function is to get a list of the country code current being supported
1632 \param pBuf - Caller allocated buffer with at least 3 bytes, upon success return,
1633 this has the country code list. 3 bytes for each country code. This may be NULL if
1634 caller wants to know the needed byte count.
1635 \param pbLen - Caller allocated, as input, it indicates the length of pBuf. Upon success return,
1636 this contains the length of the data in pBuf. If pbuf is NULL, as input, *pbLen should be 0.
1637 \return eHalStatus
1638 -------------------------------------------------------------------------------*/
1639eHalStatus sme_GetSupportedCountryCode(tHalHandle hHal, tANI_U8 *pBuf, tANI_U32 *pbLen);
1640
1641/* ---------------------------------------------------------------------------
1642 \fn sme_GetCurrentRegulatoryDomain
1643 \brief this function is to get the current regulatory domain. This is a synchronous API.
1644 This function must be called after CFG is downloaded and all the band/mode setting already passed into
1645 SME. The function fails if 11d support is turned off.
1646 \param pDomain - Caller allocated buffer to return the current domain.
1647 \return eHalStatus SUCCESS.
1648
1649 FAILURE or RESOURCES The API finished and failed.
1650 -------------------------------------------------------------------------------*/
1651eHalStatus sme_GetCurrentRegulatoryDomain(tHalHandle hHal, v_REGDOMAIN_t *pDomain);
1652
1653/* ---------------------------------------------------------------------------
1654 \fn sme_SetRegulatoryDomain
1655 \brief this function is to set the current regulatory domain.
1656 This function must be called after CFG is downloaded and all the band/mode setting already passed into
1657 SME. This is a synchronous API.
1658 \param domainId - indicate the domain (defined in the driver) needs to set to.
1659 See v_REGDOMAIN_t for definition
1660 \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether
1661 a restart is needed to apply the change
1662 \return eHalStatus
1663 -------------------------------------------------------------------------------*/
1664eHalStatus sme_SetRegulatoryDomain(tHalHandle hHal, v_REGDOMAIN_t domainId, tANI_BOOLEAN *pfRestartNeeded);
1665
1666/* ---------------------------------------------------------------------------
1667
1668 \fn sme_GetRegulatoryDomainForCountry
1669
1670 \brief To return a regulatory domain base on a country code. This is a synchronous API.
1671
1672 \param pCountry - pointer to a caller allocated buffer for input country code.
1673
1674 \param pDomainId Upon successful return, it is the domain that country belongs to.
1675 If it is NULL, returning success means that the country code is known.
1676
1677 \return eHalStatus SUCCESS.
1678
1679 FAILURE or RESOURCES The API finished and failed.
1680
1681 -------------------------------------------------------------------------------*/
1682eHalStatus sme_GetRegulatoryDomainForCountry(tHalHandle hHal, tANI_U8 *pCountry, v_REGDOMAIN_t *pDomainId);
1683
1684
1685
1686/* ---------------------------------------------------------------------------
1687
1688 \fn sme_GetSupportedRegulatoryDomains
1689
1690 \brief To return a list of supported regulatory domains. This is a synchronous API.
1691
1692 \param pDomains - pointer to a caller allocated buffer for returned regulatory domains.
1693
1694 \param pNumDomains For input, this parameter indicates howm many domains pDomains can hold.
1695 Upon return, this parameter has the number for supported domains. If pDomains
1696 doesn't have enough space for all the supported domains, this function returns
1697 fail status and this parameter contains the number that is needed.
1698
1699 \return eHalStatus SUCCESS.
1700
1701 FAILURE or RESOURCES The API finished and failed.
1702
1703 -------------------------------------------------------------------------------*/
1704eHalStatus sme_GetSupportedRegulatoryDomains(tHalHandle hHal, v_REGDOMAIN_t *pDomains, tANI_U32 *pNumDomains);
1705
1706//some support functions
1707tANI_BOOLEAN sme_Is11dSupported(tHalHandle hHal);
1708tANI_BOOLEAN sme_Is11hSupported(tHalHandle hHal);
1709tANI_BOOLEAN sme_IsWmmSupported(tHalHandle hHal);
1710//Upper layer to get the list of the base channels to scan for passively 11d info from csr
1711eHalStatus sme_ScanGetBaseChannels( tHalHandle hHal, tCsrChannelInfo * pChannelInfo );
1712
1713typedef void ( *tSmeChangeCountryCallback)(void *pContext);
1714/* ---------------------------------------------------------------------------
1715
1716 \fn sme_ChangeCountryCode
1717
1718 \brief Change Country code from upperlayer during WLAN driver operation.
1719 This is a synchronous API.
1720
1721 \param hHal - The handle returned by macOpen.
1722
1723 \param pCountry New Country Code String
1724
Abhishek Singha306a442013-11-07 18:39:01 +05301725 \param sendRegHint If we want to send reg hint to nl80211
1726
Jeff Johnson295189b2012-06-20 16:38:30 -07001727 \return eHalStatus SUCCESS.
1728
1729 FAILURE or RESOURCES The API finished and failed.
1730
1731 -------------------------------------------------------------------------------*/
1732eHalStatus sme_ChangeCountryCode( tHalHandle hHal,
1733 tSmeChangeCountryCallback callback,
1734 tANI_U8 *pCountry,
1735 void *pContext,
Gopichand Nakkalaacd94112013-05-29 21:37:47 +05301736 void* pVosContext,
Abhishek Singha306a442013-11-07 18:39:01 +05301737 tAniBool countryFromUserSpace,
1738 tAniBool sendRegHint);
Jeff Johnson295189b2012-06-20 16:38:30 -07001739
Sundaresan Ramachandran76e48e82013-07-15 13:07:17 +05301740/* ---------------------------------------------------------------------------
1741
Amar Singhal0d15bd52013-10-12 23:13:13 -07001742 \fn sme_GenericChangeCountryCode
1743
1744 \brief Generic API to change country code
1745
1746 \param hHal - The handle returned by macOpen.
1747
1748 \param pCountry New Country Code String
1749
1750 \param reg_domain Regulatory domain for the new country code
1751
1752 \return eHalStatus SUCCESS.
1753
1754 FAILURE or RESOURCES The API finished and failed.
1755
1756 -------------------------------------------------------------------------------*/
1757eHalStatus sme_GenericChangeCountryCode( tHalHandle hHal,
1758 tANI_U8 *pCountry,
1759 v_REGDOMAIN_t reg_domain);
1760
1761/* ---------------------------------------------------------------------------
1762
Sundaresan Ramachandran76e48e82013-07-15 13:07:17 +05301763 \fn sme_DHCPStartInd
1764
1765 \brief Indicate FW about DHCP start event.
1766
1767 \param hHal - The handle returned by macOpen.
1768
1769 \param device_mode the mode of the device
1770
c_hpothu0b0cab72014-02-13 21:52:40 +05301771 \param sessionId session ID
Sundaresan Ramachandran76e48e82013-07-15 13:07:17 +05301772
1773 \return eHalStatus SUCCESS.
1774
1775 FAILURE or RESOURCES The API finished and failed.
1776
1777 -------------------------------------------------------------------------------*/
1778
1779eHalStatus sme_DHCPStartInd( tHalHandle hHal,
1780 tANI_U8 device_mode,
c_hpothu0b0cab72014-02-13 21:52:40 +05301781 tANI_U8 sessionId );
Sundaresan Ramachandran76e48e82013-07-15 13:07:17 +05301782
1783/* ---------------------------------------------------------------------------
1784
1785 \fn sme_DHCPStopInd
1786
1787 \brief Indicate FW about DHCP stop event.
1788
1789 \param hHal - The handle returned by macOpen.
1790
1791 \param device_mode the mode of the device
1792
c_hpothu0b0cab72014-02-13 21:52:40 +05301793 \param sessionId session ID
Sundaresan Ramachandran76e48e82013-07-15 13:07:17 +05301794
1795 \return eHalStatus SUCCESS.
1796
1797 FAILURE or RESOURCES The API finished and failed.
1798
1799 -------------------------------------------------------------------------------*/
1800eHalStatus sme_DHCPStopInd( tHalHandle hHal,
1801 tANI_U8 device_mode,
c_hpothu0b0cab72014-02-13 21:52:40 +05301802 tANI_U8 sessionId );
Sundaresan Ramachandran76e48e82013-07-15 13:07:17 +05301803
Jeff Johnson295189b2012-06-20 16:38:30 -07001804
1805/* ---------------------------------------------------------------------------
1806 \fn sme_BtcSignalBtEvent
1807 \brief API to signal Bluetooth (BT) event to the WLAN driver. Based on the
1808 BT event type and the current operating mode of Libra (full power,
1809 BMPS, UAPSD etc), appropriate Bluetooth Coexistence (BTC) strategy
1810 would be employed.
1811 \param hHal - The handle returned by macOpen.
1812 \param pBtcBtEvent - Pointer to a caller allocated object of type tSmeBtEvent
1813 Caller owns the memory and is responsible for freeing it.
1814 \return VOS_STATUS
1815 VOS_STATUS_E_FAILURE BT Event not passed to HAL. This can happen
1816 if driver has not yet been initialized or if BTC
1817 Events Layer has been disabled.
1818 VOS_STATUS_SUCCESS BT Event passed to HAL
1819 ---------------------------------------------------------------------------*/
1820VOS_STATUS sme_BtcSignalBtEvent (tHalHandle hHal, tpSmeBtEvent pBtcBtEvent);
1821
1822/* ---------------------------------------------------------------------------
1823 \fn sme_BtcSetConfig
1824 \brief API to change the current Bluetooth Coexistence (BTC) configuration
1825 This function should be invoked only after CFG download has completed.
1826 Calling it after sme_HDDReadyInd is recommended.
1827 \param hHal - The handle returned by macOpen.
1828 \param pSmeBtcConfig - Pointer to a caller allocated object of type
1829 tSmeBtcConfig. Caller owns the memory and is responsible
1830 for freeing it.
1831 \return VOS_STATUS
1832 VOS_STATUS_E_FAILURE Config not passed to HAL.
1833 VOS_STATUS_SUCCESS Config passed to HAL
1834 ---------------------------------------------------------------------------*/
1835VOS_STATUS sme_BtcSetConfig (tHalHandle hHal, tpSmeBtcConfig pSmeBtcConfig);
1836
1837/* ---------------------------------------------------------------------------
1838 \fn sme_BtcGetConfig
1839 \brief API to retrieve the current Bluetooth Coexistence (BTC) configuration
1840 \param hHal - The handle returned by macOpen.
1841 \param pSmeBtcConfig - Pointer to a caller allocated object of type tSmeBtcConfig.
1842 Caller owns the memory and is responsible for freeing it.
1843 \return VOS_STATUS
1844 VOS_STATUS_E_FAILURE - failure
1845 VOS_STATUS_SUCCESS success
1846 ---------------------------------------------------------------------------*/
1847VOS_STATUS sme_BtcGetConfig (tHalHandle hHal, tpSmeBtcConfig pSmeBtcConfig);
1848
1849/* ---------------------------------------------------------------------------
1850 \fn sme_SetCfgPrivacy
1851 \brief API to set configure privacy parameters
1852 \param hHal - The handle returned by macOpen.
1853 \param pProfile - Pointer CSR Roam profile.
1854 \param fPrivacy - This parameter indicates status of privacy
1855
1856 \return void
1857 ---------------------------------------------------------------------------*/
1858void sme_SetCfgPrivacy(tHalHandle hHal, tCsrRoamProfile *pProfile, tANI_BOOLEAN fPrivacy);
1859
1860#if defined WLAN_FEATURE_VOWIFI
1861/* ---------------------------------------------------------------------------
1862 \fn sme_NeighborReportRequest
1863 \brief API to request neighbor report.
1864 \param hHal - The handle returned by macOpen.
1865 \param pRrmNeighborReq - Pointer to a caller allocated object of type
1866 tRrmNeighborReq. Caller owns the memory and is responsible
1867 for freeing it.
1868 \return VOS_STATUS
1869 VOS_STATUS_E_FAILURE - failure
1870 VOS_STATUS_SUCCESS success
1871 ---------------------------------------------------------------------------*/
1872VOS_STATUS sme_NeighborReportRequest (tHalHandle hHal, tANI_U8 sessionId,
1873 tpRrmNeighborReq pRrmNeighborReq, tpRrmNeighborRspCallbackInfo callbackInfo);
1874#endif
1875
1876//The following are debug APIs to support direct read/write register/memory
1877//They are placed in SME because HW cannot be access when in LOW_POWER state
1878//AND not connected. The knowledge and synchronization is done in SME
1879
1880//sme_DbgReadRegister
1881//Caller needs to validate the input values
1882VOS_STATUS sme_DbgReadRegister(tHalHandle hHal, v_U32_t regAddr, v_U32_t *pRegValue);
1883
1884//sme_DbgWriteRegister
1885//Caller needs to validate the input values
1886VOS_STATUS sme_DbgWriteRegister(tHalHandle hHal, v_U32_t regAddr, v_U32_t regValue);
1887
1888//sme_DbgReadMemory
1889//Caller needs to validate the input values
1890//pBuf caller allocated buffer has the length of nLen
1891VOS_STATUS sme_DbgReadMemory(tHalHandle hHal, v_U32_t memAddr, v_U8_t *pBuf, v_U32_t nLen);
1892
1893//sme_DbgWriteMemory
1894//Caller needs to validate the input values
1895VOS_STATUS sme_DbgWriteMemory(tHalHandle hHal, v_U32_t memAddr, v_U8_t *pBuf, v_U32_t nLen);
1896
Jeff Johnson295189b2012-06-20 16:38:30 -07001897VOS_STATUS sme_GetWcnssWlanCompiledVersion(tHalHandle hHal,
1898 tSirVersionType *pVersion);
1899VOS_STATUS sme_GetWcnssWlanReportedVersion(tHalHandle hHal,
1900 tSirVersionType *pVersion);
1901VOS_STATUS sme_GetWcnssSoftwareVersion(tHalHandle hHal,
1902 tANI_U8 *pVersion,
1903 tANI_U32 versionBufferSize);
1904VOS_STATUS sme_GetWcnssHardwareVersion(tHalHandle hHal,
1905 tANI_U8 *pVersion,
1906 tANI_U32 versionBufferSize);
Jeff Johnson295189b2012-06-20 16:38:30 -07001907eHalStatus sme_RoamRegisterCallback(tHalHandle hHal,
1908 csrRoamCompleteCallback callback,
1909 void *pContext);
1910
1911#ifdef FEATURE_WLAN_WAPI
1912/* ---------------------------------------------------------------------------
1913 \fn sme_RoamSetBKIDCache
1914 \brief The SME API exposed to HDD to allow HDD to provde SME the BKID
1915 candidate list.
1916 \param hHal - Handle to the HAL. The HAL handle is returned by the HAL after
1917 it is opened (by calling halOpen).
1918 \param pBKIDCache - caller allocated buffer point to an array of tBkidCacheInfo
1919 \param numItems - a variable that has the number of tBkidCacheInfo allocated
1920 when retruning, this is the number of items put into pBKIDCache
1921 \return eHalStatus - when fail, it usually means the buffer allocated is not
1922 big enough and pNumItems has the number of tBkidCacheInfo.
1923 ---------------------------------------------------------------------------*/
1924eHalStatus sme_RoamSetBKIDCache( tHalHandle hHal, tANI_U32 sessionId, tBkidCacheInfo *pBKIDCache,
1925 tANI_U32 numItems );
1926
1927/* ---------------------------------------------------------------------------
1928 \fn sme_RoamGetBKIDCache
1929 \brief The SME API exposed to HDD to allow HDD to request SME to return its
1930 BKID cache.
1931 \param hHal - Handle to the HAL. The HAL handle is returned by the HAL after
1932 it is opened (by calling halOpen).
1933 \param pNum - caller allocated memory that has the space of the number of
1934 tBkidCacheInfo as input. Upon returned, *pNum has the needed number of entries
1935 in SME cache.
1936 \param pBkidCache - Caller allocated memory that contains BKID cache, if any,
1937 upon return
1938 \return eHalStatus - when fail, it usually means the buffer allocated is not
1939 big enough.
1940 ---------------------------------------------------------------------------*/
1941eHalStatus sme_RoamGetBKIDCache(tHalHandle hHal, tANI_U32 *pNum,
1942 tBkidCacheInfo *pBkidCache);
1943
1944/* ---------------------------------------------------------------------------
1945 \fn sme_RoamGetNumBKIDCache
1946 \brief The SME API exposed to HDD to allow HDD to request SME to return the
1947 number of BKID cache entries.
1948 \param hHal - Handle to the HAL. The HAL handle is returned by the HAL after
1949 it is opened (by calling halOpen).
1950 \return tANI_U32 - the number of BKID cache entries.
1951 ---------------------------------------------------------------------------*/
1952tANI_U32 sme_RoamGetNumBKIDCache(tHalHandle hHal, tANI_U32 sessionId);
1953
1954/* ---------------------------------------------------------------------------
1955 \fn sme_ScanGetBKIDCandidateList
1956 \brief a wrapper function to return the BKID candidate list
1957 \param pBkidList - caller allocated buffer point to an array of
1958 tBkidCandidateInfo
1959 \param pNumItems - pointer to a variable that has the number of
1960 tBkidCandidateInfo allocated when retruning, this is
1961 either the number needed or number of items put into
1962 pPmkidList
1963 \return eHalStatus - when fail, it usually means the buffer allocated is not
1964 big enough and pNumItems
1965 has the number of tBkidCandidateInfo.
1966 \Note: pNumItems is a number of tBkidCandidateInfo,
1967 not sizeof(tBkidCandidateInfo) * something
1968 ---------------------------------------------------------------------------*/
1969eHalStatus sme_ScanGetBKIDCandidateList(tHalHandle hHal, tANI_U32 sessionId,
1970 tBkidCandidateInfo *pBkidList,
1971 tANI_U32 *pNumItems );
1972#endif /* FEATURE_WLAN_WAPI */
1973
Jeff Johnsone7245742012-09-05 17:12:55 -07001974#ifdef FEATURE_OEM_DATA_SUPPORT
1975/********************************************************************************************
1976 Oem data related modifications
1977*********************************************************************************************/
1978/* ---------------------------------------------------------------------------
1979 \fn sme_OemDataReq
1980 \param sessionId - session id of session to be used for oem data req.
1981 \param pOemDataReqID - pointer to an object to get back the request ID
1982 \param callback - a callback function that is called upon finish
1983 \param pContext - a pointer passed in for the callback
1984 \return eHalStatus
1985 ---------------------------------------------------------------------------*/
1986eHalStatus sme_OemDataReq(tHalHandle hHal,
1987 tANI_U8 sessionId,
1988 tOemDataReqConfig *,
1989 tANI_U32 *pOemDataReqID,
1990 oemData_OemDataReqCompleteCallback callback,
1991 void *pContext);
1992
1993/* ---------------------------------------------------------------------------
1994 \fn sme_getOemDataRsp
1995 \param pOemDataRsp - A pointer to the response object
1996 \param pOemDataReqID - pointer to an object to get back the request ID
1997 \return eHalStatus
1998 ---------------------------------------------------------------------------*/
1999eHalStatus sme_getOemDataRsp(tHalHandle hHal,
2000 tOemDataRsp **pOemDataRsp);
2001
2002#endif /*FEATURE_OEM_DATA_SUPPORT*/
Jeff Johnson295189b2012-06-20 16:38:30 -07002003
2004
Jeff Johnson295189b2012-06-20 16:38:30 -07002005
2006/* ---------------------------------------------------------------------------
2007
2008 \fn sme_RoamUpdateAPWPSIE
2009
2010 \brief To update AP's WPS IE. This function should be called after SME AP session is created
2011 This is an asynchronous API.
2012
2013 \param pAPWPSIES - pointer to a caller allocated object of tCsrRoamAPWPSIES
2014
Mohit Khanna698ba2a2012-12-04 15:08:18 -08002015 \return eHalStatus SUCCESS Roam callback will be called indicate actually results
Jeff Johnson295189b2012-06-20 16:38:30 -07002016
Mohit Khanna698ba2a2012-12-04 15:08:18 -08002017 FAILURE or RESOURCES The API finished and failed.
Jeff Johnson295189b2012-06-20 16:38:30 -07002018
2019 -------------------------------------------------------------------------------*/
2020
2021eHalStatus sme_RoamUpdateAPWPSIE(tHalHandle, tANI_U8 sessionId, tSirAPWPSIEs *pAPWPSIES);
2022/* ---------------------------------------------------------------------------
2023
2024 \fn sme_RoamUpdateAPWPARSNIEs
2025
2026 \brief To update AP's WPA/RSN IEs. This function should be called after SME AP session is created
2027 This is an asynchronous API.
2028
2029 \param pAPSirRSNie - pointer to a caller allocated object of tSirRSNie with WPS/RSN IEs
2030
Mohit Khanna698ba2a2012-12-04 15:08:18 -08002031 \return eHalStatus SUCCESS
Jeff Johnson295189b2012-06-20 16:38:30 -07002032
Mohit Khanna698ba2a2012-12-04 15:08:18 -08002033 FAILURE or RESOURCES The API finished and failed.
Jeff Johnson295189b2012-06-20 16:38:30 -07002034
2035 -------------------------------------------------------------------------------*/
2036eHalStatus sme_RoamUpdateAPWPARSNIEs(tHalHandle hHal, tANI_U8 sessionId, tSirRSNie * pAPSirRSNie);
2037
Madan Mohan Koyyalamudi167b95e2012-11-27 15:53:38 -08002038/* ---------------------------------------------------------------------------
2039
2040 sme_ChangeMCCBeaconInterval
2041
2042 \brief To update P2P-GO's beacon Interval.
2043
Mohit Khanna698ba2a2012-12-04 15:08:18 -08002044 \return eHalStatus SUCCESS
2045 FAILURE or RESOURCES
2046 The API finished and failed.
Madan Mohan Koyyalamudi167b95e2012-11-27 15:53:38 -08002047 -------------------------------------------------------------------------------*/
2048eHalStatus sme_ChangeMCCBeaconInterval(tHalHandle hHal, tANI_U8 sessionId);
2049
2050
Jeff Johnson295189b2012-06-20 16:38:30 -07002051
2052/* ---------------------------------------------------------------------------
2053 \fn sme_sendBTAmpEvent
2054 \brief API to send the btAMPstate to FW
2055 \param hHal - The handle returned by macOpen.
2056 \param btAmpEvent -- btAMP event
Mohit Khanna698ba2a2012-12-04 15:08:18 -08002057 \return eHalStatus SUCCESS
2058 FAILURE or RESOURCES The API finished and failed.
Jeff Johnson295189b2012-06-20 16:38:30 -07002059
2060--------------------------------------------------------------------------- */
2061
2062eHalStatus sme_sendBTAmpEvent(tHalHandle hHal, tSmeBtAmpEvent btAmpEvent);
2063
2064
2065
2066/* ---------------------------------------------------------------------------
2067 \fn sme_SetHostOffload
2068 \brief API to set the host offload feature.
2069 \param hHal - The handle returned by macOpen.
2070 \param pRequest - Pointer to the offload request.
2071 \return eHalStatus
2072 ---------------------------------------------------------------------------*/
Jeff Johnsone7245742012-09-05 17:12:55 -07002073eHalStatus sme_SetHostOffload (tHalHandle hHal, tANI_U8 sessionId,
2074 tpSirHostOffloadReq pRequest);
Jeff Johnson295189b2012-06-20 16:38:30 -07002075
2076/* ---------------------------------------------------------------------------
2077 \fn sme_SetKeepAlive
2078 \brief API to set the Keep Alive feature.
2079 \param hHal - The handle returned by macOpen.
2080 \param pRequest - Pointer to the Keep Alive request.
2081 \return eHalStatus
2082 ---------------------------------------------------------------------------*/
Jeff Johnsone7245742012-09-05 17:12:55 -07002083eHalStatus sme_SetKeepAlive (tHalHandle hHal, tANI_U8 sessionId,
2084 tpSirKeepAliveReq pRequest);
Jeff Johnson295189b2012-06-20 16:38:30 -07002085
Jeff Johnson295189b2012-06-20 16:38:30 -07002086/* ----------------------------------------------------------------------------
2087 \fn sme_GetOperationChannel
2088 \brief API to get current channel on which STA is parked
2089 this function gives channel information only of infra station or IBSS station.
Jeff Johnson04dd8a82012-06-29 20:41:40 -07002090 \param hHal, pointer to memory location and sessionId
Jeff Johnson295189b2012-06-20 16:38:30 -07002091 \returns eHAL_STATUS_SUCCESS
2092 eHAL_STATUS_FAILURE
2093-------------------------------------------------------------------------------*/
Jeff Johnson04dd8a82012-06-29 20:41:40 -07002094eHalStatus sme_GetOperationChannel(tHalHandle hHal, tANI_U32 *pChannel, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002095
Jeff Johnson295189b2012-06-20 16:38:30 -07002096/* ---------------------------------------------------------------------------
2097
2098 \fn sme_RegisterMgtFrame
2099
2100 \brief To register managment frame of specified type and subtype.
2101 \param frameType - type of the frame that needs to be passed to HDD.
2102 \param matchData - data which needs to be matched before passing frame
2103 to HDD.
2104 \param matchDataLen - Length of matched data.
2105 \return eHalStatus
2106 -------------------------------------------------------------------------------*/
2107eHalStatus sme_RegisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
2108 tANI_U16 frameType, tANI_U8* matchData, tANI_U16 matchLen);
2109
2110/* ---------------------------------------------------------------------------
2111
2112 \fn sme_DeregisterMgtFrame
2113
2114 \brief To De-register managment frame of specified type and subtype.
2115 \param frameType - type of the frame that needs to be passed to HDD.
2116 \param matchData - data which needs to be matched before passing frame
2117 to HDD.
2118 \param matchDataLen - Length of matched data.
2119 \return eHalStatus
2120 -------------------------------------------------------------------------------*/
2121eHalStatus sme_DeregisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
2122 tANI_U16 frameType, tANI_U8* matchData, tANI_U16 matchLen);
Jeff Johnson295189b2012-06-20 16:38:30 -07002123
2124/* ---------------------------------------------------------------------------
2125
2126 \fn sme_ConfigureRxpFilter
2127
2128 \brief
2129 SME will pass this request to lower mac to set/reset the filter on RXP for
2130 multicast & broadcast traffic.
2131
2132 \param
2133
2134 hHal - The handle returned by macOpen.
2135
2136 filterMask- Currently the API takes a 1 or 0 (set or reset) as filter.
2137 Basically to enable/disable the filter (to filter "all" mcbc traffic) based
2138 on this param. In future we can use this as a mask to set various types of
2139 filters as suggested below:
2140 FILTER_ALL_MULTICAST:
2141 FILTER_ALL_BROADCAST:
2142 FILTER_ALL_MULTICAST_BROADCAST:
2143
2144
2145 \return eHalStatus
2146
2147
2148--------------------------------------------------------------------------- */
2149eHalStatus sme_ConfigureRxpFilter( tHalHandle hHal,
2150 tpSirWlanSetRxpFilters wlanRxpFilterParam);
2151
2152/* ---------------------------------------------------------------------------
2153
2154 \fn sme_ConfigureAppsCpuWakeupState
2155
2156 \brief
2157 SME will pass this request to lower mac to dynamically adjusts the listen
2158 interval based on the WLAN/MSM activity. This feature is named as
2159 Telescopic Beacon wakeup feature.
2160
2161 \param
2162
2163 hHal - The handle returned by macOpen.
2164
2165 isAppsAwake- Depicts the state of the Apps CPU
2166
2167
2168 \return eHalStatus
2169
2170
2171--------------------------------------------------------------------------- */
2172eHalStatus sme_ConfigureAppsCpuWakeupState( tHalHandle hHal, tANI_BOOLEAN isAppsAwake);
2173
Jeff Johnson295189b2012-06-20 16:38:30 -07002174/* ---------------------------------------------------------------------------
2175
2176 \fn sme_ConfigureSuspendInd
2177
2178 \brief
2179 SME will pass this request to lower mac to Indicate that the wlan needs to
2180 be suspended
2181
2182 \param
2183
2184 hHal - The handle returned by macOpen.
2185
2186 wlanSuspendParam- Depicts the wlan suspend params
2187
2188
2189 \return eHalStatus
2190
2191
2192--------------------------------------------------------------------------- */
2193eHalStatus sme_ConfigureSuspendInd( tHalHandle hHal,
2194 tpSirWlanSuspendParam wlanSuspendParam);
2195
2196/* ---------------------------------------------------------------------------
2197
2198 \fn sme_ConfigureResumeReq
2199
2200 \brief
2201 SME will pass this request to lower mac to Indicate that the wlan needs to
2202 be Resumed
2203
2204 \param
2205
2206 hHal - The handle returned by macOpen.
2207
2208 wlanResumeParam- Depicts the wlan resume params
2209
2210
2211 \return eHalStatus
2212
2213
2214--------------------------------------------------------------------------- */
2215eHalStatus sme_ConfigureResumeReq( tHalHandle hHal,
2216 tpSirWlanResumeParam wlanResumeParam);
2217
Jeff Johnson295189b2012-06-20 16:38:30 -07002218
2219/* ---------------------------------------------------------------------------
2220
2221 \fn sme_GetInfraSessionId
2222
2223 \brief To get the session ID for infra session, if connected
2224 This is a synchronous API.
2225
2226 \param hHal - The handle returned by macOpen.
2227
2228 \return sessionid, -1 if infra session is not connected
2229
2230 -------------------------------------------------------------------------------*/
2231tANI_S8 sme_GetInfraSessionId(tHalHandle hHal);
2232
2233/* ---------------------------------------------------------------------------
2234
2235 \fn sme_GetInfraOperationChannel
2236
2237 \brief To get the operating channel for infra session, if connected
2238 This is a synchronous API.
2239
2240 \param hHal - The handle returned by macOpen.
2241 \param sessionId - the sessionId returned by sme_OpenSession.
2242
2243 \return operating channel, 0 if infra session is not connected
2244
2245 -------------------------------------------------------------------------------*/
2246tANI_U8 sme_GetInfraOperationChannel( tHalHandle hHal, tANI_U8 sessionId);
2247/* ---------------------------------------------------------------------------
2248
2249 \fn sme_GetConcurrentOperationChannel
2250
2251 \brief To get the operating channel for other concurrent sessions, if connected
2252 This is a synchronous API.
2253
2254 \param hHal - The handle returned by macOpen.
2255 \param currentPersona - persona that is trying to come up.
2256
2257 \return operating channel, 0 if infra session is not connected
2258
2259 -------------------------------------------------------------------------------*/
2260tANI_U8 sme_GetConcurrentOperationChannel( tHalHandle hHal );
2261
2262/* ---------------------------------------------------------------------------
2263 \fn sme_AbortMacScan
2264 \brief API to cancel MAC scan.
2265 \param hHal - The handle returned by macOpen.
Madan Mohan Koyyalamudiff3a7152013-06-13 14:47:55 +05302266 \param sessionId - sessionId for interface
Jeff Johnson295189b2012-06-20 16:38:30 -07002267 \return VOS_STATUS
2268 VOS_STATUS_E_FAILURE - failure
2269 VOS_STATUS_SUCCESS success
2270 ---------------------------------------------------------------------------*/
Srinivas, Dasari138af4f2014-02-07 11:13:45 +05302271eHalStatus sme_AbortMacScan(tHalHandle hHal, tANI_U8 sessionId,
2272 eCsrAbortReason reason);
Jeff Johnson295189b2012-06-20 16:38:30 -07002273
2274/* ---------------------------------------------------------------------------
2275 \fn sme_GetCfgValidChannels
2276 \brief API to get valid channel list
2277 \param hHal - The handle returned by macOpen.
2278 \param aValidChannels - Pointer to the valid channel list
2279 \param len - valid channel list length
2280 \return eHalStatus
2281 ---------------------------------------------------------------------------*/
2282eHalStatus sme_GetCfgValidChannels(tHalHandle hHal, tANI_U8 *aValidChannels, tANI_U32 *len);
2283
2284#ifdef FEATURE_WLAN_SCAN_PNO
2285
2286/* ---------------------------------------------------------------------------
2287 \fn sme_SetPreferredNetworkList
2288 \brief API to set the Preferred Network List Offload feature.
2289 \param hHal - The handle returned by macOpen.
2290 \param pRequest - Pointer to the offload request.
2291 \return eHalStatus
2292 ---------------------------------------------------------------------------*/
2293eHalStatus sme_SetPreferredNetworkList (tHalHandle hHal, tpSirPNOScanReq pRequest, tANI_U8 sessionId, preferredNetworkFoundIndCallback callbackRoutine, void *callbackContext );
2294
2295/* ---------------------------------------------------------------------------
2296 \fn sme_SetRSSIFilter
2297 \brief API to set RSSI Filter feature.
2298 \param hHal - The handle returned by macOpen.
2299 \param pRequest - Pointer to the offload request.
2300 \return eHalStatus
2301 ---------------------------------------------------------------------------*/
2302eHalStatus sme_SetRSSIFilter(tHalHandle hHal, v_U8_t rssiThreshold);
2303
2304/******************************************************************************
2305*
2306* Name: sme_PreferredNetworkFoundInd
2307*
2308* Description:
2309* Invoke Preferred Network Found Indication
2310*
2311* Parameters:
2312* hHal - HAL handle for device
2313* pMsg - found network description
2314*
2315* Returns: eHalStatus
2316*
2317******************************************************************************/
2318eHalStatus sme_PreferredNetworkFoundInd (tHalHandle hHal, void* pMsg);
2319#endif // FEATURE_WLAN_SCAN_PNO
2320
2321/* ---------------------------------------------------------------------------
2322 \fn sme_SetPowerParams
2323 \brief API to set Power Parameters
2324 \param hHal - The handle returned by macOpen.
2325 \param pwParams - Pointer to the power parameters requested.
Tushnim Bhattacharyya3a37def2013-02-24 11:11:15 -08002326 \param forced - if true, not to be dropped silently in host, it must reach
2327 FW; It is added to avoid a race condition scenario where LIM hasn't deleted
2328 the session yet before power params gets sent to PMC
Jeff Johnson295189b2012-06-20 16:38:30 -07002329 \return eHalStatus
2330 ---------------------------------------------------------------------------*/
Tushnim Bhattacharyya3a37def2013-02-24 11:11:15 -08002331eHalStatus sme_SetPowerParams(tHalHandle hHal, tSirSetPowerParamsReq* pwParams, tANI_BOOLEAN forced);
Jeff Johnson295189b2012-06-20 16:38:30 -07002332
2333/* ---------------------------------------------------------------------------
2334 \fn sme_SetTxPerTracking
2335 \brief Set Tx PER tracking configuration parameters
2336 \param hHal - The handle returned by macOpen.
2337 \param pTxPerTrackingParam - Tx PER configuration parameters
2338 \return eHalStatus
2339 ---------------------------------------------------------------------------*/
2340eHalStatus sme_SetTxPerTracking (
2341 tHalHandle hHal,
2342 void (*pCallbackfn) (void *pCallbackContext),
2343 void *pCallbackContext,
2344 tpSirTxPerTrackingParam pTxPerTrackingParam);
2345
2346#ifdef WLAN_FEATURE_PACKET_FILTERING
2347/* ---------------------------------------------------------------------------
2348 \fn sme_ReceiveFilterSetFilter
2349 \brief API to set 8023 Multicast Address List
2350 \param hHal - The handle returned by macOpen.
2351 \param pMulticastAddrs - Pointer to the Multicast Address List
2352 \return eHalStatus
2353 ---------------------------------------------------------------------------*/
Amar Singhalf3a6e762013-02-19 15:06:50 -08002354eHalStatus sme_8023MulticastList(tHalHandle hHal, tANI_U8 sessionId, tpSirRcvFltMcAddrList pMulticastAddrs);
Jeff Johnson295189b2012-06-20 16:38:30 -07002355
2356/* ---------------------------------------------------------------------------
2357 \fn sme_ReceiveFilterSetFilter
2358 \brief API to set Receive Packet Filter
2359 \param hHal - The handle returned by macOpen.
2360 \param pRcvPktFilterCfg - Receive Packet Filter parameter
2361 \return eHalStatus
2362 ---------------------------------------------------------------------------*/
Jeff Johnsone7245742012-09-05 17:12:55 -07002363eHalStatus sme_ReceiveFilterSetFilter(tHalHandle hHal, tpSirRcvPktFilterCfgType pRcvPktFilterCfg,
2364 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002365
2366/* ---------------------------------------------------------------------------
2367 \fn sme_GetFilterMatchCount
2368 \brief API to get D0 PC Filter Match Count
2369 \param hHal - The handle returned by macOpen
2370 \param callbackRoutine - Callback routine invoked to receive Packet Coalescing Filter Match Count
2371 \param callbackContext - Cookie to be passed back during callback
2372 \return eHalStatus
2373 ---------------------------------------------------------------------------*/
2374eHalStatus sme_GetFilterMatchCount(tHalHandle hHal,
2375 FilterMatchCountCallback callbackRoutine,
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07002376 void *callbackContext,
2377 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002378
2379/* ---------------------------------------------------------------------------
2380 \fn sme_ReceiveFilterClearFilter
2381 \brief API to clear Receive Packet Filter
2382 \param hHal - The handle returned by macOpen.
2383 \param pRcvFltPktClearParam - Receive Packet Filter Clear parameter
2384 \return eHalStatus
2385 ---------------------------------------------------------------------------*/
2386eHalStatus sme_ReceiveFilterClearFilter(tHalHandle hHal,
Jeff Johnsone7245742012-09-05 17:12:55 -07002387 tpSirRcvFltPktClearParam pRcvFltPktClearParam,
2388 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002389#endif // WLAN_FEATURE_PACKET_FILTERING
2390/* ---------------------------------------------------------------------------
2391
2392 \fn sme_IsChannelValid
2393 \brief To check if the channel is valid for currently established domain
2394 This is a synchronous API.
2395
2396 \param hHal - The handle returned by macOpen.
2397 \param channel - channel to verify
2398
2399 \return TRUE/FALSE, TRUE if channel is valid
2400
2401 -------------------------------------------------------------------------------*/
2402tANI_BOOLEAN sme_IsChannelValid(tHalHandle hHal, tANI_U8 channel);
2403
2404/* ---------------------------------------------------------------------------
2405 \fn sme_SetFreqBand
2406 \brief Used to set frequency band.
2407 \param hHal
2408 \eBand band value to be configured
2409 \- return eHalStatus
2410 -------------------------------------------------------------------------*/
2411eHalStatus sme_SetFreqBand(tHalHandle hHal, eCsrBand eBand);
2412
2413/* ---------------------------------------------------------------------------
2414 \fn sme_GetFreqBand
2415 \brief Used to get the current band settings.
2416 \param hHal
2417 \pBand pointer to hold the current band value
2418 \- return eHalStatus
2419 -------------------------------------------------------------------------*/
2420eHalStatus sme_GetFreqBand(tHalHandle hHal, eCsrBand *pBand);
2421
2422/* ---------------------------------------------------------------------------
2423
2424 \fn sme_SetTxPerTracking
2425 \brief Set Tx PER tracking configuration parameters
2426 \param hHal - The handle returned by macOpen.
2427 \param pTxPerTrackingParam - Tx PER configuration parameters
2428 \return eHalStatus
2429 ---------------------------------------------------------------------------*/
2430eHalStatus sme_SetTxPerTracking (
2431 tHalHandle hHal,
2432 void (*pCallbackfn) (void *pCallbackContext),
2433 void *pCallbackContext,
2434 tpSirTxPerTrackingParam pTxPerTrackingParam);
2435
2436#ifdef WLAN_FEATURE_GTK_OFFLOAD
2437/* ---------------------------------------------------------------------------
2438 \fn sme_SetGTKOffload
2439 \brief API to set GTK offload feature.
2440 \param hHal - The handle returned by macOpen.
2441 \param pRequest - Pointer to the GTK offload request.
2442 \return eHalStatus
2443 ---------------------------------------------------------------------------*/
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07002444eHalStatus sme_SetGTKOffload (tHalHandle hHal, tpSirGtkOffloadParams pRequest, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002445
2446/* ---------------------------------------------------------------------------
2447 \fn sme_GetGTKOffload
2448 \brief API to get GTK offload information.
2449 \param hHal - The handle returned by macOpen.
2450 \param pRequest - Pointer to the GTK offload response.
2451 \return eHalStatus
2452 ---------------------------------------------------------------------------*/
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07002453eHalStatus sme_GetGTKOffload (tHalHandle hHal, GTKOffloadGetInfoCallback callbackRoutine,
2454 void *callbackContext, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002455#endif // WLAN_FEATURE_GTK_OFFLOAD
2456
2457#ifdef WLAN_WAKEUP_EVENTS
2458eHalStatus sme_WakeReasonIndCallback (tHalHandle hHal, void* pMsg);
2459#endif // WLAN_WAKEUP_EVENTS
2460
2461/* ---------------------------------------------------------------------------
2462 \fn sme_SetTxPerTracking
2463 \brief Set Tx PER tracking configuration parameters
2464 \param hHal - The handle returned by macOpen.
2465 \param pTxPerTrackingParam - Tx PER configuration parameters
2466 \return eHalStatus
2467 ---------------------------------------------------------------------------*/
2468eHalStatus sme_SetTxPerTracking (
2469 tHalHandle hHal,
2470 void (*pCallbackfn) (void *pCallbackContext),
2471 void *pCallbackContext,
2472 tpSirTxPerTrackingParam pTxPerTrackingParam);
2473
2474
2475//return frequency for a particular channel
2476tANI_U16 sme_ChnToFreq(tANI_U8 chanNum);
2477
2478tANI_BOOLEAN sme_IsChannelValid(tHalHandle hHal, tANI_U8 channel);
2479
2480#if defined WLAN_FEATURE_P2P_INTERNAL
2481
2482eHalStatus sme_p2pResetSession(tHalHandle hHal, tANI_U8 HDDSessionId);
2483
2484/* ---------------------------------------------------------------------------
2485 \fn sme_p2pFlushDeviceList
2486 \brief Remove cached P2P result from scan results
2487 \param hHal - The handle returned by macOpen.
2488 \param HDDSessionId - HDD's sessionId. Currently unused.
2489 \return eHalStatus
2490 ---------------------------------------------------------------------------*/
2491eHalStatus sme_p2pFlushDeviceList(tHalHandle hHal, tANI_U8 HDDSessionId);
2492
2493eHalStatus sme_p2pGetResultFilter(tHalHandle hHal, tANI_U8 HDDSessionId,
2494 tCsrScanResultFilter *pFilter);
2495
2496#endif //#if defined WLAN_FEATURE_P2P_INTERNAL
2497
2498/* ---------------------------------------------------------------------------
2499 \fn sme_SetMaxTxPower
2500 \brief Used to set the Maximum Transmit Power dynamically. Note: this
2501 setting will not persist over reboots
2502 \param hHal
2503 \param pBssid BSSID to set the power cap for
2504 \param pBssid pSelfMacAddress self MAC Address
2505 \param pBssid power to set in dB
2506 \- return eHalStatus
2507 -------------------------------------------------------------------------*/
2508eHalStatus sme_SetMaxTxPower(tHalHandle hHal, tSirMacAddr pBssid,
2509 tSirMacAddr pSelfMacAddress, v_S7_t dB);
2510
Jeff Johnson295189b2012-06-20 16:38:30 -07002511/* ---------------------------------------------------------------------------
Arif Hussaina5ebce02013-08-09 15:09:58 -07002512 \fn sme_SetMaxTxPowerPerBand
2513 \brief Used to set the Maximum Transmit Power for
2514 specific band dynamically. Note: this setting will not persist over reboots
2515 \param band
2516 \param power to set in dB
2517 \- return eHalStatus
2518 -------------------------------------------------------------------------*/
2519eHalStatus sme_SetMaxTxPowerPerBand(eCsrBand band, v_S7_t db);
2520
2521/* ---------------------------------------------------------------------------
Jeff Johnson295189b2012-06-20 16:38:30 -07002522
schang86c22c42013-03-13 18:41:24 -07002523 \fn sme_SetTxPower
2524
2525 \brief Set Transmit Power dynamically. Note: this setting will
2526 not persist over reboots.
2527
2528 \param hHal
2529 \param sessionId Target Session ID
2530 \param mW power to set in mW
2531 \- return eHalStatus
2532
2533 -------------------------------------------------------------------------------*/
2534eHalStatus sme_SetTxPower(tHalHandle hHal, v_U8_t sessionId, v_U8_t mW);
2535
2536/* ---------------------------------------------------------------------------
2537
Jeff Johnson295189b2012-06-20 16:38:30 -07002538 \fn sme_HideSSID
2539
2540 \brief Enable/Disables hidden SSID dynamically. Note: this setting will
2541 not persist over reboots.
2542
2543 \param hHal
2544 \param sessionId
2545 \param ssidHidden 0 - Broadcast SSID, 1 - Disable broadcast SSID
2546 \- return eHalStatus
2547
2548 -------------------------------------------------------------------------------*/
2549eHalStatus sme_HideSSID(tHalHandle hHal, v_U8_t sessionId, v_U8_t ssidHidden);
Jeff Johnson295189b2012-06-20 16:38:30 -07002550
2551/* ---------------------------------------------------------------------------
2552
2553 \fn sme_SetTmLevel
2554 \brief Set Thermal Mitigation Level to RIVA
2555 \param hHal - The handle returned by macOpen.
2556 \param newTMLevel - new Thermal Mitigation Level
2557 \param tmMode - Thermal Mitigation handle mode, default 0
Varun Reddy Yeturucc661d22013-05-20 11:47:10 -07002558 \return eHalStatus
Jeff Johnson295189b2012-06-20 16:38:30 -07002559 ---------------------------------------------------------------------------*/
2560eHalStatus sme_SetTmLevel(tHalHandle hHal, v_U16_t newTMLevel, v_U16_t tmMode);
2561
2562/*---------------------------------------------------------------------------
2563
2564 \brief sme_featureCapsExchange() - SME interface to exchange capabilities between
2565 Host and FW.
2566
2567 \param hHal - HAL handle for device
2568
2569 \return NONE
2570
2571---------------------------------------------------------------------------*/
2572void sme_featureCapsExchange(tHalHandle hHal);
2573
Jeff Johnsond13512a2012-07-17 11:42:19 -07002574/*---------------------------------------------------------------------------
2575
Yathish9f22e662012-12-10 14:21:35 -08002576 \brief sme_disableActiveModeOffload() - SME interface to disable Active mode Offload capabilitu
2577 between in Host.
2578
2579 \param hHal - HAL handle for device
2580
2581 \return NONE
2582
2583---------------------------------------------------------------------------*/
2584void sme_disableFeatureCapablity(tANI_U8 feature_index);
2585
2586/*---------------------------------------------------------------------------
2587
Jeff Johnsond13512a2012-07-17 11:42:19 -07002588 \brief sme_GetDefaultCountryCodeFrmNv() - SME interface to get the default
2589 country code
2590 Host and FW.
2591
2592 \param hHal - HAL handle for device
2593 \param pCountry - pointer to country code
2594
Jeff Johnsonfeddb2d2012-12-10 14:41:22 -08002595 \return Success or failure
Jeff Johnsond13512a2012-07-17 11:42:19 -07002596
2597 ---------------------------------------------------------------------------*/
2598eHalStatus sme_GetDefaultCountryCodeFrmNv(tHalHandle hHal, tANI_U8 *pCountry);
2599
2600/*---------------------------------------------------------------------------
2601
2602 \brief sme_GetCurrentCountryCode() - SME interface to get the current operating
2603 country code.
2604
2605 \param hHal - HAL handle for device
2606 \param pCountry - pointer to country code
2607
2608 \return Success or failure
2609
2610 ---------------------------------------------------------------------------*/
2611eHalStatus sme_GetCurrentCountryCode(tHalHandle hHal, tANI_U8 *pCountry);
2612
Madan Mohan Koyyalamudi8cb53982012-09-28 14:34:47 -07002613/* ---------------------------------------------------------------------------
2614 \fn sme_transportDebug
2615 \brief Dynamically monitoring Transport channels
2616 Private IOCTL will querry transport channel status if driver loaded
schang6295e542013-03-12 15:31:23 -07002617 \param hHal Upper MAC context
Jeff Johnsonb88db982012-12-10 13:34:59 -08002618 \param displaySnapshot Display transport channel snapshot option
Madan Mohan Koyyalamudi8cb53982012-09-28 14:34:47 -07002619 \param toggleStallDetect Enable stall detect feature
2620 This feature will take effect to data performance
2621 Not integrate till fully verification
2622 \- return NONE
2623 -------------------------------------------------------------------------*/
schang6295e542013-03-12 15:31:23 -07002624void sme_transportDebug(tHalHandle hHal, v_BOOL_t displaySnapshot, v_BOOL_t toggleStallDetect);
Madan Mohan Koyyalamudid5026072012-11-30 14:56:21 -08002625
Kiran4a17ebe2013-01-31 10:43:43 -08002626/* ---------------------------------------------------------------------------
2627 \fn sme_ResetPowerValuesFor5G
2628 \brief Reset the power values for 5G band with NV power values.
2629 \param hHal - HAL handle for device
2630 \- return NONE
2631 -------------------------------------------------------------------------*/
2632void sme_ResetPowerValuesFor5G (tHalHandle hHal);
2633
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002634#if defined (WLAN_FEATURE_VOWIFI_11R) || defined (FEATURE_WLAN_ESE) || defined(FEATURE_WLAN_LFR)
Madan Mohan Koyyalamudid5026072012-11-30 14:56:21 -08002635/* ---------------------------------------------------------------------------
2636 \fn sme_UpdateRoamPrefer5GHz
2637 \brief enable/disable Roam prefer 5G runtime option
2638 This function is called through dynamic setConfig callback function
2639 to configure the Roam prefer 5G runtime option
2640 \param hHal - HAL handle for device
2641 \param nRoamPrefer5GHz Enable/Disable Roam prefer 5G runtime option
2642 \- return Success or failure
2643 -------------------------------------------------------------------------*/
Madan Mohan Koyyalamudid5026072012-11-30 14:56:21 -08002644eHalStatus sme_UpdateRoamPrefer5GHz(tHalHandle hHal, v_BOOL_t nRoamPrefer5GHz);
Madan Mohan Koyyalamudi62b55b02012-12-03 16:45:39 -08002645
2646/* ---------------------------------------------------------------------------
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07002647 \fn sme_setRoamIntraBand
2648 \brief enable/disable Intra band roaming
2649 This function is called through dynamic setConfig callback function
2650 to configure the intra band roaming
2651 \param hHal - HAL handle for device
2652 \param nRoamIntraBand Enable/Disable Intra band roaming
2653 \- return Success or failure
2654 -------------------------------------------------------------------------*/
2655eHalStatus sme_setRoamIntraBand(tHalHandle hHal, const v_BOOL_t nRoamIntraBand);
2656
2657/* ---------------------------------------------------------------------------
Varun Reddy Yeturu920df212013-05-22 08:07:23 -07002658 \fn sme_UpdateRoamScanNProbes
2659 \brief function to update roam scan N probes
2660 This function is called through dynamic setConfig callback function
2661 to update roam scan N probes
2662 \param hHal - HAL handle for device
2663 \param nProbes number of probe requests to be sent out
2664 \- return Success or failure
2665 -------------------------------------------------------------------------*/
2666eHalStatus sme_UpdateRoamScanNProbes(tHalHandle hHal, const v_U8_t nProbes);
2667
2668/* ---------------------------------------------------------------------------
2669 \fn sme_UpdateRoamScanHomeAwayTime
2670 \brief function to update roam scan Home away time
2671 This function is called through dynamic setConfig callback function
2672 to update roam scan home away time
2673 \param hHal - HAL handle for device
2674 \param nRoamScanAwayTime Scan home away time
2675 \- return Success or failure
2676 -------------------------------------------------------------------------*/
Srinivas Girigowda6cf0b822013-06-27 14:00:20 -07002677eHalStatus sme_UpdateRoamScanHomeAwayTime(tHalHandle hHal,
2678 const v_U16_t nRoamScanHomeAwayTime,
2679 const eAniBoolean bSendOffloadCmd);
Varun Reddy Yeturu920df212013-05-22 08:07:23 -07002680
2681/* ---------------------------------------------------------------------------
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07002682 \fn sme_getRoamIntraBand
2683 \brief get Intra band roaming
2684 \param hHal - HAL handle for device
2685 \- return Success or failure
2686 -------------------------------------------------------------------------*/
2687v_BOOL_t sme_getRoamIntraBand(tHalHandle hHal);
2688
2689/* ---------------------------------------------------------------------------
Varun Reddy Yeturu920df212013-05-22 08:07:23 -07002690 \fn sme_getRoamScanNProbes
2691 \brief get N Probes
2692 \param hHal - HAL handle for device
2693 \- return Success or failure
2694 -------------------------------------------------------------------------*/
2695v_U8_t sme_getRoamScanNProbes(tHalHandle hHal);
2696
2697/* ---------------------------------------------------------------------------
2698 \fn sme_getRoamScanHomeAwayTime
2699 \brief get Roam scan home away time
2700 \param hHal - HAL handle for device
2701 \- return Success or failure
2702 -------------------------------------------------------------------------*/
2703v_U16_t sme_getRoamScanHomeAwayTime(tHalHandle hHal);
2704
2705/* ---------------------------------------------------------------------------
Madan Mohan Koyyalamudi62b55b02012-12-03 16:45:39 -08002706 \fn sme_UpdateImmediateRoamRssiDiff
2707 \brief Update nImmediateRoamRssiDiff
2708 This function is called through dynamic setConfig callback function
2709 to configure nImmediateRoamRssiDiff
2710 Usage: adb shell iwpriv wlan0 setConfig gImmediateRoamRssiDiff=[0 .. 125]
2711 \param hHal - HAL handle for device
2712 \param nImmediateRoamRssiDiff - minimum rssi difference between potential
2713 candidate and current AP.
2714 \- return Success or failure
2715 -------------------------------------------------------------------------*/
2716
2717eHalStatus sme_UpdateImmediateRoamRssiDiff(tHalHandle hHal, v_U8_t nImmediateRoamRssiDiff);
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002718
Srinivas Girigowdade697412013-02-14 16:31:48 -08002719/* ---------------------------------------------------------------------------
2720 \fn sme_UpdateRoamRssiDiff
2721 \brief Update RoamRssiDiff
2722 This function is called through dynamic setConfig callback function
2723 to configure RoamRssiDiff
2724 Usage: adb shell iwpriv wlan0 setConfig RoamRssiDiff=[0 .. 125]
2725 \param hHal - HAL handle for device
2726 \param RoamRssiDiff - minimum rssi difference between potential
2727 candidate and current AP.
2728 \- return Success or failure
2729 -------------------------------------------------------------------------*/
2730
2731eHalStatus sme_UpdateRoamRssiDiff(tHalHandle hHal, v_U8_t RoamRssiDiff);
2732
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002733/*--------------------------------------------------------------------------
2734 \brief sme_UpdateFastTransitionEnabled() - enable/disable Fast Transition support at runtime
2735 It is used at in the REG_DYNAMIC_VARIABLE macro definition of
2736 isFastTransitionEnabled.
2737 This is a synchronuous call
2738 \param hHal - The handle returned by macOpen.
2739 \return eHAL_STATUS_SUCCESS - SME update isFastTransitionEnabled config successfully.
2740 Other status means SME is failed to update isFastTransitionEnabled.
2741 \sa
2742 --------------------------------------------------------------------------*/
2743
2744eHalStatus sme_UpdateFastTransitionEnabled(tHalHandle hHal,
2745 v_BOOL_t isFastTransitionEnabled);
Srinivas Girigowda100eb322013-03-15 16:48:20 -07002746
2747/* ---------------------------------------------------------------------------
Srinivas Girigowdaad34ca92013-10-22 10:54:29 -07002748 \fn sme_UpdateWESMode
2749 \brief Update WESMode
2750 This function is called through dynamic setConfig callback function
2751 to configure isWESModeEnabled
2752 \param hHal - HAL handle for device
2753 \param isWESModeEnabled - Enable/Disable WES Mode
2754 \- return Success or failure
2755 -------------------------------------------------------------------------*/
2756eHalStatus sme_UpdateWESMode(tHalHandle hHal, v_BOOL_t isWESModeEnabled);
2757
2758/* ---------------------------------------------------------------------------
Srinivas Girigowda100eb322013-03-15 16:48:20 -07002759 \fn sme_SetRoamScanControl
2760 \brief Set roam scan control
2761 This function is called to set roam scan control
2762 if roam scan control is set to 0, roaming scan cache is cleared
2763 any value other than 0 is treated as invalid value
2764 \param hHal - HAL handle for device
2765 \return eHAL_STATUS_SUCCESS - SME update config successfully.
2766 Other status means SME failure to update
2767 -------------------------------------------------------------------------*/
2768eHalStatus sme_SetRoamScanControl(tHalHandle hHal, v_BOOL_t roamScanControl);
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002769#endif /* (WLAN_FEATURE_VOWIFI_11R) || (FEATURE_WLAN_ESE) || (FEATURE_WLAN_LFR) */
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002770
2771#ifdef FEATURE_WLAN_LFR
2772/*--------------------------------------------------------------------------
2773 \brief sme_UpdateIsFastRoamIniFeatureEnabled() - enable/disable LFR support at runtime
Srinivas Girigowdade697412013-02-14 16:31:48 -08002774 It is used at in the REG_DYNAMIC_VARIABLE macro definition of
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002775 isFastRoamIniFeatureEnabled.
2776 This is a synchronuous call
2777 \param hHal - The handle returned by macOpen.
2778 \return eHAL_STATUS_SUCCESS - SME update isFastRoamIniFeatureEnabled config successfully.
2779 Other status means SME is failed to update isFastRoamIniFeatureEnabled.
2780 \sa
2781 --------------------------------------------------------------------------*/
2782
Srinivas Girigowdade697412013-02-14 16:31:48 -08002783eHalStatus sme_UpdateIsFastRoamIniFeatureEnabled(tHalHandle hHal,
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07002784 const v_BOOL_t isFastRoamIniFeatureEnabled);
Srinivas Girigowda830bbd02013-06-13 19:44:16 -07002785
Sameer Thalappil4ae66ec2013-11-05 14:17:35 -08002786/*--------------------------------------------------------------------------
2787 \brief sme_UpdateIsMAWCIniFeatureEnabled() -
2788 Enable/disable LFR MAWC support at runtime
2789 It is used at in the REG_DYNAMIC_VARIABLE macro definition of
2790 isMAWCIniFeatureEnabled.
2791 This is a synchronous call
2792 \param hHal - The handle returned by macOpen.
2793 \return eHAL_STATUS_SUCCESS - SME update MAWCEnabled config successfully.
2794 Other status means SME is failed to update MAWCEnabled.
2795 \sa
2796 --------------------------------------------------------------------------*/
2797eHalStatus sme_UpdateIsMAWCIniFeatureEnabled(tHalHandle hHal,
2798 const v_BOOL_t MAWCEnabled);
2799
Srinivas Girigowda830bbd02013-06-13 19:44:16 -07002800
2801#ifdef WLAN_FEATURE_ROAM_SCAN_OFFLOAD
2802/*--------------------------------------------------------------------------
2803 \brief sme_UpdateEnableFastRoamInConcurrency() - enable/disable LFR if Concurrent session exists
2804 This is a synchronuous call
2805 \param hHal - The handle returned by macOpen.
2806 \return eHAL_STATUS_SUCCESS
2807 Other status means SME is failed
2808 \sa
2809 --------------------------------------------------------------------------*/
2810
2811eHalStatus sme_UpdateEnableFastRoamInConcurrency(tHalHandle hHal,
2812 v_BOOL_t bFastRoamInConIniFeatureEnabled);
2813#endif
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002814#endif /* FEATURE_WLAN_LFR */
2815
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002816#ifdef FEATURE_WLAN_ESE
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002817/*--------------------------------------------------------------------------
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002818 \brief sme_UpdateIsEseFeatureEnabled() - enable/disable ESE support at runtime
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002819 It is used at in the REG_DYNAMIC_VARIABLE macro definition of
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002820 isEseIniFeatureEnabled.
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002821 This is a synchronuous call
2822 \param hHal - The handle returned by macOpen.
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002823 \return eHAL_STATUS_SUCCESS - SME update isEseIniFeatureEnabled config successfully.
2824 Other status means SME is failed to update isEseIniFeatureEnabled.
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002825 \sa
2826 --------------------------------------------------------------------------*/
2827
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002828eHalStatus sme_UpdateIsEseFeatureEnabled(tHalHandle hHal,
2829 const v_BOOL_t isEseIniFeatureEnabled);
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002830
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002831#endif /* FEATURE_WLAN_ESE */
Gopichand Nakkala98a98af2012-12-31 14:38:47 -08002832
2833/*--------------------------------------------------------------------------
2834 \brief sme_UpdateConfigFwRssiMonitoring() - enable/disable firmware RSSI Monitornig at runtime
2835 It is used at in the REG_DYNAMIC_VARIABLE macro definition of
2836 fEnableFwRssiMonitoring.
2837 This is a synchronuous call
2838 \param hHal - The handle returned by macOpen.
2839 \return eHAL_STATUS_SUCCESS - SME update fEnableFwRssiMonitoring config successfully.
2840 Other status means SME is failed to update
2841 \sa
2842 --------------------------------------------------------------------------*/
2843
2844eHalStatus sme_UpdateConfigFwRssiMonitoring(tHalHandle hHal,
2845 v_BOOL_t fEnableFwRssiMonitoring);
Madan Mohan Koyyalamudid5026072012-11-30 14:56:21 -08002846
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07002847#ifdef WLAN_FEATURE_NEIGHBOR_ROAMING
Srinivas Girigowdade697412013-02-14 16:31:48 -08002848/*--------------------------------------------------------------------------
2849 \brief sme_setNeighborLookupRssiThreshold() - update neighbor lookup rssi threshold
2850 This is a synchronuous call
2851 \param hHal - The handle returned by macOpen.
2852 \return eHAL_STATUS_SUCCESS - SME update config successful.
2853 Other status means SME is failed to update
2854 \sa
2855 --------------------------------------------------------------------------*/
2856eHalStatus sme_setNeighborLookupRssiThreshold(tHalHandle hHal,
2857 v_U8_t neighborLookupRssiThreshold);
2858
2859/*--------------------------------------------------------------------------
2860 \brief sme_setNeighborReassocRssiThreshold() - update neighbor reassoc rssi threshold
2861 This is a synchronuous call
2862 \param hHal - The handle returned by macOpen.
2863 \return eHAL_STATUS_SUCCESS - SME update config successful.
2864 Other status means SME is failed to update
2865 \sa
2866 --------------------------------------------------------------------------*/
2867eHalStatus sme_setNeighborReassocRssiThreshold(tHalHandle hHal,
2868 v_U8_t neighborReassocRssiThreshold);
2869
2870/*--------------------------------------------------------------------------
2871 \brief sme_getNeighborLookupRssiThreshold() - get neighbor lookup rssi threshold
2872 This is a synchronuous call
2873 \param hHal - The handle returned by macOpen.
2874 \return eHAL_STATUS_SUCCESS - SME update config successful.
2875 Other status means SME is failed to update
2876 \sa
2877 --------------------------------------------------------------------------*/
2878v_U8_t sme_getNeighborLookupRssiThreshold(tHalHandle hHal);
2879
2880/*--------------------------------------------------------------------------
2881 \brief sme_setNeighborScanRefreshPeriod() - set neighbor scan results refresh period
2882 This is a synchronuous call
2883 \param hHal - The handle returned by macOpen.
2884 \return eHAL_STATUS_SUCCESS - SME update config successful.
2885 Other status means SME is failed to update
2886 \sa
2887 --------------------------------------------------------------------------*/
2888eHalStatus sme_setNeighborScanRefreshPeriod(tHalHandle hHal,
2889 v_U16_t neighborScanResultsRefreshPeriod);
2890
2891/*--------------------------------------------------------------------------
2892 \brief sme_getNeighborScanRefreshPeriod() - get neighbor scan results refresh period
2893 This is a synchronuous call
2894 \param hHal - The handle returned by macOpen.
2895 \return eHAL_STATUS_SUCCESS - SME update config successful.
2896 Other status means SME is failed to update
2897 \sa
2898 --------------------------------------------------------------------------*/
2899v_U16_t sme_getNeighborScanRefreshPeriod(tHalHandle hHal);
2900
2901/*--------------------------------------------------------------------------
2902 \brief sme_getEmptyScanRefreshPeriod() - get empty scan refresh period
2903 This is a synchronuous call
2904 \param hHal - The handle returned by macOpen.
2905 \return eHAL_STATUS_SUCCESS - SME update config successful.
2906 Other status means SME is failed to update
2907 \sa
2908 --------------------------------------------------------------------------*/
2909v_U16_t sme_getEmptyScanRefreshPeriod(tHalHandle hHal);
2910
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07002911/* ---------------------------------------------------------------------------
2912 \fn sme_UpdateEmptyScanRefreshPeriod
2913 \brief Update nEmptyScanRefreshPeriod
2914 This function is called through dynamic setConfig callback function
2915 to configure nEmptyScanRefreshPeriod
2916 Usage: adb shell iwpriv wlan0 setConfig nEmptyScanRefreshPeriod=[0 .. 60]
2917 \param hHal - HAL handle for device
2918 \param nEmptyScanRefreshPeriod - scan period following empty scan results.
2919 \- return Success or failure
2920 -------------------------------------------------------------------------*/
2921eHalStatus sme_UpdateEmptyScanRefreshPeriod(tHalHandle hHal, v_U16_t nEmptyScanRefreshPeriod);
2922
2923/* ---------------------------------------------------------------------------
2924 \fn sme_setNeighborScanMinChanTime
2925 \brief Update nNeighborScanMinChanTime
2926 This function is called through dynamic setConfig callback function
2927 to configure gNeighborScanChannelMinTime
2928 Usage: adb shell iwpriv wlan0 setConfig gNeighborScanChannelMinTime=[0 .. 60]
2929 \param hHal - HAL handle for device
2930 \param nNeighborScanMinChanTime - Channel minimum dwell time
2931 \- return Success or failure
2932 -------------------------------------------------------------------------*/
2933eHalStatus sme_setNeighborScanMinChanTime(tHalHandle hHal, const v_U16_t nNeighborScanMinChanTime);
2934
2935/* ---------------------------------------------------------------------------
2936 \fn sme_setNeighborScanMaxChanTime
2937 \brief Update nNeighborScanMaxChanTime
2938 This function is called through dynamic setConfig callback function
2939 to configure gNeighborScanChannelMaxTime
2940 Usage: adb shell iwpriv wlan0 setConfig gNeighborScanChannelMaxTime=[0 .. 60]
2941 \param hHal - HAL handle for device
2942 \param nNeighborScanMinChanTime - Channel maximum dwell time
2943 \- return Success or failure
2944 -------------------------------------------------------------------------*/
2945eHalStatus sme_setNeighborScanMaxChanTime(tHalHandle hHal, const v_U16_t nNeighborScanMaxChanTime);
2946
2947/* ---------------------------------------------------------------------------
2948 \fn sme_getNeighborScanMinChanTime
2949 \brief get neighbor scan min channel time
2950 \param hHal - The handle returned by macOpen.
2951 \return v_U16_t - channel min time value
2952 -------------------------------------------------------------------------*/
2953v_U16_t sme_getNeighborScanMinChanTime(tHalHandle hHal);
2954
2955/* ---------------------------------------------------------------------------
2956 \fn sme_getNeighborScanMaxChanTime
2957 \brief get neighbor scan max channel time
2958 \param hHal - The handle returned by macOpen.
2959 \return v_U16_t - channel max time value
2960 -------------------------------------------------------------------------*/
2961v_U16_t sme_getNeighborScanMaxChanTime(tHalHandle hHal);
2962
2963/* ---------------------------------------------------------------------------
2964 \fn sme_setNeighborScanPeriod
2965 \brief Update nNeighborScanPeriod
2966 This function is called through dynamic setConfig callback function
2967 to configure nNeighborScanPeriod
2968 Usage: adb shell iwpriv wlan0 setConfig nNeighborScanPeriod=[0 .. 60]
2969 \param hHal - HAL handle for device
2970 \param nNeighborScanPeriod - neighbor scan period
2971 \- return Success or failure
2972 -------------------------------------------------------------------------*/
2973eHalStatus sme_setNeighborScanPeriod(tHalHandle hHal, const v_U16_t nNeighborScanPeriod);
2974
2975/* ---------------------------------------------------------------------------
2976 \fn sme_getNeighborScanPeriod
2977 \brief get neighbor scan period
2978 \param hHal - The handle returned by macOpen.
2979 \return v_U16_t - neighbor scan period
2980 -------------------------------------------------------------------------*/
2981v_U16_t sme_getNeighborScanPeriod(tHalHandle hHal);
2982
2983#endif
Srinivas Girigowdade697412013-02-14 16:31:48 -08002984
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08002985#if defined (WLAN_FEATURE_VOWIFI_11R) || defined (FEATURE_WLAN_ESE) || defined(FEATURE_WLAN_LFR)
Srinivas Girigowdade697412013-02-14 16:31:48 -08002986/*--------------------------------------------------------------------------
2987 \brief sme_getRoamRssiDiff() - get Roam rssi diff
2988 This is a synchronuous call
2989 \param hHal - The handle returned by macOpen.
2990 \return eHAL_STATUS_SUCCESS - SME update config successful.
2991 Other status means SME is failed to update
2992 \sa
2993 --------------------------------------------------------------------------*/
2994v_U8_t sme_getRoamRssiDiff(tHalHandle hHal);
2995
2996/*--------------------------------------------------------------------------
2997 \brief sme_ChangeRoamScanChannelList() - Change roam scan channel list
2998 This is a synchronuous call
2999 \param hHal - The handle returned by macOpen.
3000 \return eHAL_STATUS_SUCCESS - SME update config successful.
3001 Other status means SME is failed to update
3002 \sa
3003 --------------------------------------------------------------------------*/
3004eHalStatus sme_ChangeRoamScanChannelList(tHalHandle hHal, tANI_U8 *pChannelList,
3005 tANI_U8 numChannels);
3006
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08003007#ifdef FEATURE_WLAN_ESE_UPLOAD
Srinivas Girigowda5cecb202013-10-08 09:13:25 -07003008/*--------------------------------------------------------------------------
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08003009 \brief sme_SetEseRoamScanChannelList() - set ese roam scan channel list
Srinivas Girigowda5cecb202013-10-08 09:13:25 -07003010 This is a synchronuous call
3011 \param hHal - The handle returned by macOpen.
3012 \return eHAL_STATUS_SUCCESS - SME update config successful.
3013 Other status means SME is failed to update
3014 \sa
3015 --------------------------------------------------------------------------*/
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08003016eHalStatus sme_SetEseRoamScanChannelList(tHalHandle hHal,
Srinivas Girigowda5cecb202013-10-08 09:13:25 -07003017 tANI_U8 *pChannelList,
3018 tANI_U8 numChannels);
3019#endif
3020
Srinivas Girigowdade697412013-02-14 16:31:48 -08003021/*--------------------------------------------------------------------------
Srinivas Girigowdade697412013-02-14 16:31:48 -08003022 \brief sme_getRoamScanChannelList() - get roam scan channel list
3023 This is a synchronuous call
3024 \param hHal - The handle returned by macOpen.
3025 \return eHAL_STATUS_SUCCESS - SME update config successful.
3026 Other status means SME is failed to update
3027 \sa
3028 --------------------------------------------------------------------------*/
3029eHalStatus sme_getRoamScanChannelList(tHalHandle hHal, tANI_U8 *pChannelList,
3030 tANI_U8 *pNumChannels);
3031
3032/*--------------------------------------------------------------------------
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08003033 \brief sme_getIsEseFeatureEnabled() - get ESE feature enabled or not
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07003034 This is a synchronuous call
3035 \param hHal - The handle returned by macOpen.
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08003036 \return TRUE (1) - if the ESE feature is enabled
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07003037 FALSE (0) - if feature is disabled (compile or runtime)
3038 \sa
3039 --------------------------------------------------------------------------*/
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -08003040tANI_BOOLEAN sme_getIsEseFeatureEnabled(tHalHandle hHal);
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07003041
3042/*--------------------------------------------------------------------------
Srinivas Girigowdaad34ca92013-10-22 10:54:29 -07003043 \brief sme_getWESMode() - getWES Mode
3044 This is a synchronous call
3045 \param hHal - The handle returned by macOpen.
3046 \return v_U8_t - WES Mode Enabled(1)/Disabled(0)
3047 \sa
3048 --------------------------------------------------------------------------*/
3049v_BOOL_t sme_GetWESMode(tHalHandle hHal);
3050
3051/*--------------------------------------------------------------------------
Srinivas Girigowda100eb322013-03-15 16:48:20 -07003052 \brief sme_GetRoamScanControl() - get scan control
3053 This is a synchronous call
3054 \param hHal - The handle returned by macOpen.
3055 \return v_BOOL_t - Enabled(1)/Disabled(0)
3056 \sa
3057 --------------------------------------------------------------------------*/
3058v_BOOL_t sme_GetRoamScanControl(tHalHandle hHal);
3059
3060/* ---------------------------------------------------------------------------
3061 \fn sme_UpdateEmptyScanRefreshPeriod
3062 \brief Update nnEmptyScanRefreshPeriod
3063 This function is called through dynamic setConfig callback function
3064 to configure nnEmptyScanRefreshPeriod
3065 Usage: adb shell iwpriv wlan0 setConfig nEmptyScanRefreshPeriod=[0 .. 60]
3066 \param hHal - HAL handle for device
3067 \param nEmptyScanRefreshPeriod - scan period following empty scan results.
3068 \- return Success or failure
3069 -------------------------------------------------------------------------*/
3070
3071/*--------------------------------------------------------------------------
Srinivas Girigowdabbd16eb2013-03-21 12:34:46 -07003072 \brief sme_getIsLfrFeatureEnabled() - get LFR feature enabled or not
3073 This is a synchronuous call
3074 \param hHal - The handle returned by macOpen.
3075 \return TRUE (1) - if the feature is enabled
3076 FALSE (0) - if feature is disabled (compile or runtime)
3077 \sa
3078 --------------------------------------------------------------------------*/
3079tANI_BOOLEAN sme_getIsLfrFeatureEnabled(tHalHandle hHal);
3080
3081/*--------------------------------------------------------------------------
3082 \brief sme_getIsFtFeatureEnabled() - get FT feature enabled or not
3083 This is a synchronuous call
3084 \param hHal - The handle returned by macOpen.
3085 \return TRUE (1) - if the feature is enabled
3086 FALSE (0) - if feature is disabled (compile or runtime)
3087 \sa
3088 --------------------------------------------------------------------------*/
3089tANI_BOOLEAN sme_getIsFtFeatureEnabled(tHalHandle hHal);
3090
Srinivas Girigowdade697412013-02-14 16:31:48 -08003091#endif
3092
Varun Reddy Yeturud0a3f252013-04-15 21:58:13 -07003093#ifdef WLAN_FEATURE_ROAM_SCAN_OFFLOAD
3094/*--------------------------------------------------------------------------
3095 \brief sme_UpdateRoamScanOffloadEnabled() - enable/disable roam scan offload feaure
3096 It is used at in the REG_DYNAMIC_VARIABLE macro definition of
3097 gRoamScanOffloadEnabled.
3098 This is a synchronous call
3099 \param hHal - The handle returned by macOpen.
3100 \return eHAL_STATUS_SUCCESS - SME update config successfully.
3101 Other status means SME is failed to update.
3102 \sa
3103 --------------------------------------------------------------------------*/
3104
3105eHalStatus sme_UpdateRoamScanOffloadEnabled(tHalHandle hHal, v_BOOL_t nRoamScanOffloadEnabled);
3106#endif
3107
3108
Srinivas Girigowdade697412013-02-14 16:31:48 -08003109/* ---------------------------------------------------------------------------
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003110 \fn sme_IsFeatureSupportedByFW
Kiet Lam0f320422013-11-21 19:29:17 +05303111 \brief Check if a feature is enabled by FW
3112
3113 \param featEnumValue - Enumeration value of the feature to be checked.
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003114 A value from enum placeHolderInCapBitmap
3115
3116 \- return 1/0 (TRUE/FALSE)
3117 -------------------------------------------------------------------------*/
3118tANI_U8 sme_IsFeatureSupportedByFW(tANI_U8 featEnumValue);
Kiet Lam0f320422013-11-21 19:29:17 +05303119
3120/* ---------------------------------------------------------------------------
3121 \fn sme_IsFeatureSupportedByDriver
3122 \brief Check if a feature is enabled by driver
3123
3124 \param featEnumValue - Enumeration value of the feature to be checked.
3125 A value from enum placeHolderInCapBitmap
3126
3127 \- return 1/0 (TRUE/FALSE)
3128 -------------------------------------------------------------------------*/
3129tANI_U8 sme_IsFeatureSupportedByDriver(tANI_U8 featEnumValue);
3130
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003131#ifdef FEATURE_WLAN_TDLS
Gopichand Nakkala79ff85d2013-05-27 17:05:29 +05303132
3133/* ---------------------------------------------------------------------------
3134 \fn sme_SendTdlsLinkEstablishParams
3135 \brief API to send TDLS Link Establishment Parameters.
3136
3137 \param peerMac - peer's Mac Adress.
3138 \param tdlsLinkEstablishParams - TDLS Peer Link Establishment Parameters
3139 \- return VOS_STATUS_SUCCES
3140 -------------------------------------------------------------------------*/
3141
3142VOS_STATUS sme_SendTdlsLinkEstablishParams(tHalHandle hHal,
3143 tANI_U8 sessionId,
3144 tSirMacAddr peerMac,
3145 tCsrTdlsLinkEstablishParams *tdlsLinkEstablishParams);
3146
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003147/* ---------------------------------------------------------------------------
3148 \fn sme_SendTdlsMgmtFrame
3149 \brief API to send TDLS management frames.
3150
3151 \param peerMac - peer's Mac Adress.
3152 \param frame_type - Type of TDLS mgmt frame to be sent.
3153 \param dialog - dialog token used in the frame.
3154 \param status - status to be incuded in the frame.
Pradeep Reddy POTTETIca171f82014-03-21 14:17:35 +05303155 \param peerCapability - peerCapability to be incuded in the frame.
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003156 \param buf - additional IEs to be included
3157 \param len - lenght of additional Ies
Hoonki Leea34dd892013-02-05 22:56:02 -08003158 \param responder - Tdls request type
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003159 \- return VOS_STATUS_SUCCES
3160 -------------------------------------------------------------------------*/
3161VOS_STATUS sme_SendTdlsMgmtFrame(tHalHandle hHal, tANI_U8 sessionId, tSirMacAddr peerMac,
Pradeep Reddy POTTETIca171f82014-03-21 14:17:35 +05303162 tANI_U8 frame_type, tANI_U8 dialog, tANI_U16 status, tANI_U32 peerCapability, tANI_U8 *buf, tANI_U8 len, tANI_U8 responder);
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003163/* ---------------------------------------------------------------------------
Gopichand Nakkala681989c2013-03-06 22:27:48 -08003164 \fn sme_ChangeTdlsPeerSta
3165 \brief API to Update TDLS peer sta parameters.
3166
3167 \param peerMac - peer's Mac Adress.
3168 \param staParams - Peer Station Parameters.
3169 \- return VOS_STATUS_SUCCES
3170 -------------------------------------------------------------------------*/
3171VOS_STATUS sme_ChangeTdlsPeerSta(tHalHandle hHal, tANI_U8 sessionId, tSirMacAddr peerMac,
3172 tCsrStaParams *pstaParams);
3173/* ---------------------------------------------------------------------------
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003174 \fn sme_AddTdlsPeerSta
3175 \brief API to Add TDLS peer sta entry.
3176
3177 \param peerMac - peer's Mac Adress.
3178 \- return VOS_STATUS_SUCCES
3179 -------------------------------------------------------------------------*/
3180VOS_STATUS sme_AddTdlsPeerSta(tHalHandle hHal, tANI_U8 sessionId, tSirMacAddr peerMac);
3181/* ---------------------------------------------------------------------------
3182 \fn sme_DeleteTdlsPeerSta
3183 \brief API to Delete TDLS peer sta entry.
3184
3185 \param peerMac - peer's Mac Adress.
3186 \- return VOS_STATUS_SUCCES
3187 -------------------------------------------------------------------------*/
3188VOS_STATUS sme_DeleteTdlsPeerSta(tHalHandle hHal, tANI_U8 sessionId, tSirMacAddr peerMac);
Gopichand Nakkala75e7b282013-03-15 18:37:13 -07003189/* ---------------------------------------------------------------------------
Gopichand Nakkalaccd3a382013-03-19 13:56:10 -07003190 \fn sme_SetTdlsPowerSaveProhibited
3191 \API to set/reset the isTdlsPowerSaveProhibited.
3192
3193 \- return void
3194 -------------------------------------------------------------------------*/
3195void sme_SetTdlsPowerSaveProhibited(tHalHandle hHal, v_BOOL_t val);
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003196#endif
Gopichand Nakkalafe7246d2013-06-10 17:43:37 +05303197/* ---------------------------------------------------------------------------
3198 \fn sme_IsPmcBmps
3199 \brief API to Check if PMC state is BMPS.
3200
3201 \- return v_BOOL_t
3202 -------------------------------------------------------------------------*/
3203v_BOOL_t sme_IsPmcBmps(tHalHandle hHal);
3204
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003205#ifdef FEATURE_WLAN_TDLS_INTERNAL
3206typedef struct smeTdlsDisResult
3207{
3208 tSirMacAddr tdlsPeerMac;
3209 v_S7_t tdlsPeerRssi;
3210} tSmeTdlsDisResult;
3211
3212VOS_STATUS sme_StartTdlsDiscoveryReq(tHalHandle hHal, tANI_U8 sessionId, tSirMacAddr peerMac);
3213v_U8_t sme_GetTdlsDiscoveryResult(tHalHandle hHal,
3214 tSmeTdlsDisResult *disResult, v_U8_t listType);
3215VOS_STATUS sme_StartTdlsLinkSetupReq(tHalHandle hHal, tANI_U8 sessionId, tSirMacAddr peerMac);
3216VOS_STATUS sme_StartTdlsLinkTeardownReq(tHalHandle hHal, tANI_U8 sessionId, tSirMacAddr peerMac);
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003217#endif /* FEATURE_WLAN_TDLS */
Tushnim Bhattacharyya9cdf6082013-04-21 16:33:30 -07003218eHalStatus sme_UpdateDfsSetting(tHalHandle hHal, tANI_U8 fUpdateEnableDFSChnlScan);
Mohit Khanna698ba2a2012-12-04 15:08:18 -08003219
Gopichand Nakkalae620d5a2013-04-26 05:45:57 -07003220/*
3221 * SME API to enable/disable WLAN driver initiated SSR
3222 */
3223void sme_UpdateEnableSSR(tHalHandle hHal, tANI_BOOLEAN enableSSR);
3224
Gopichand Nakkaladacbcb52013-04-18 16:41:54 +05303225/* ---------------------------------------------------------------------------
3226
3227 \fn sme_SetPhyMode
3228
3229 \brief Changes the PhyMode.
3230
3231 \param hHal - The handle returned by macOpen.
3232
3233 \param phyMode new phyMode which is to set
3234
3235 \return eHalStatus SUCCESS.
3236
3237 -------------------------------------------------------------------------------*/
3238eHalStatus sme_SetPhyMode(tHalHandle hHal, eCsrPhyMode phyMode);
3239
3240/* ---------------------------------------------------------------------------
3241
3242 \fn sme_GetPhyMode
3243
3244 \brief gets current PhyMode.
3245
3246 \param hHal - The handle returned by macOpen.
3247
3248 \return eHalStatus PhyMode
3249
3250 -------------------------------------------------------------------------------*/
3251eCsrPhyMode sme_GetPhyMode(tHalHandle hHal);
3252
Ravi Joshiaeb7d9e2013-05-02 12:28:14 -07003253/*
3254 * SME API to determine the channel bonding mode
3255 */
3256VOS_STATUS sme_SelectCBMode(tHalHandle hHal, eCsrPhyMode eCsrPhyMode, tANI_U8 channel);
3257
Varun Reddy Yeturucc661d22013-05-20 11:47:10 -07003258#ifdef WLAN_FEATURE_ROAM_SCAN_OFFLOAD
3259/*--------------------------------------------------------------------------
3260 \brief sme_HandoffRequest() - a wrapper function to Request a handoff
3261 from CSR.
3262 This is a synchronous call
3263 \param hHal - The handle returned by macOpen
3264 \param pHandoffInfo - info provided by HDD with the handoff request (namely:
3265 BSSID, channel etc.)
3266 \return eHAL_STATUS_SUCCESS - SME passed the request to CSR successfully.
3267 Other status means SME is failed to send the request.
3268 \sa
3269 --------------------------------------------------------------------------*/
3270
3271eHalStatus sme_HandoffRequest(tHalHandle hHal, tCsrHandoffRequest *pHandoffInfo);
3272#endif
Sudhir Sattayappa Kohalli37620692013-08-05 14:02:26 -07003273/*--------------------------------------------------------------------------
3274 \brief sme_isSta_p2p_clientConnected() - a wrapper function to check if there
3275 is any connected session .
3276 This is a synchronous call
3277 \param hHal - The handle returned by macOpen
3278 \return VOS_STATUS - SME passed the request to CSR successfully.
3279 Other status means SME is failed to send the request.
3280 \sa
3281 --------------------------------------------------------------------------*/
Sudhir Sattayappa Kohallib1d8c3a2013-06-18 14:47:20 -07003282VOS_STATUS sme_isSta_p2p_clientConnected(tHalHandle hHal);
Leo Chang9056f462013-08-01 19:21:11 -07003283
3284#ifdef FEATURE_WLAN_LPHB
3285/* ---------------------------------------------------------------------------
3286 \fn sme_LPHBConfigReq
3287 \API to make configuration LPHB within FW.
3288 \param hHal - The handle returned by macOpen
3289 \param lphdReq - LPHB request argument by client
3290 \param pCallbackfn - LPHB timeout notification callback function pointer
3291 \- return Configuration message posting status, SUCCESS or Fail
3292 -------------------------------------------------------------------------*/
3293eHalStatus sme_LPHBConfigReq(
3294 tHalHandle hHal,
3295 tSirLPHBReq *lphdReq,
3296 void (*pCallbackfn)(void *pAdapter, void *indParam));
3297#endif /* FEATURE_WLAN_LPHB */
Yue Mab9c86f42013-08-14 15:59:08 -07003298
3299/* ---------------------------------------------------------------------------
3300 \fn sme_AddPeriodicTxPtrn
3301 \brief API to Periodic TX Pattern Offload feature
3302 \param hHal - The handle returned by macOpen
3303 \param addPeriodicTxPtrnParams - Pointer to the add pattern structure
3304 \return eHalStatus
3305 ---------------------------------------------------------------------------*/
3306eHalStatus sme_AddPeriodicTxPtrn(tHalHandle hHal, tSirAddPeriodicTxPtrn
3307 *addPeriodicTxPtrnParams);
3308
3309/* ---------------------------------------------------------------------------
3310 \fn sme_DelPeriodicTxPtrn
3311 \brief API to Periodic TX Pattern Offload feature
3312 \param hHal - The handle returned by macOpen
3313 \param delPeriodicTxPtrnParams - Pointer to the deleting pattern structure
3314 \return eHalStatus
3315 ---------------------------------------------------------------------------*/
3316eHalStatus sme_DelPeriodicTxPtrn(tHalHandle hHal, tSirDelPeriodicTxPtrn
3317 *delPeriodicTxPtrnParams);
Sudhir Sattayappa Kohalli37620692013-08-05 14:02:26 -07003318/*--------------------------------------------------------------------------
3319 \brief sme_enable_disable_split_scan() - a wrapper function to set the split
3320 scan parameter.
3321 This is a synchronous call
3322 \param hHal - The handle returned by macOpen
3323 \return None.
3324 \sa
3325 --------------------------------------------------------------------------*/
3326void sme_enable_disable_split_scan (tHalHandle hHal, tANI_U8 nNumStaChan,
3327 tANI_U8 nNumP2PChan);
Madan Mohan Koyyalamudi48101412013-09-11 23:09:37 +05303328
Chittajit Mitraf5413a42013-10-18 14:20:08 -07003329/* ---------------------------------------------------------------------------
3330 \fn sme_SendRateUpdateInd
3331 \brief API to Update rate
3332 \param hHal - The handle returned by macOpen
3333 \param rateUpdateParams - Pointer to rate update params
3334 \return eHalStatus
3335 ---------------------------------------------------------------------------*/
3336eHalStatus sme_SendRateUpdateInd(tHalHandle hHal, tSirRateUpdateInd *rateUpdateParams);
3337
Madan Mohan Koyyalamudi48101412013-09-11 23:09:37 +05303338/*
3339 * sme API to trigger fast BSS roam to a given BSSID independent of RSSI
3340 * triggers
3341 * return status
3342*/
3343eHalStatus smeIssueFastRoamNeighborAPEvent (tHalHandle hHal,
3344 tANI_U8 *bssid,
3345 tSmeFastRoamTrigger fastRoamTrig);
Kanchanapally, Vidyullatha2633ace2014-09-25 15:16:50 +05303346
3347eHalStatus sme_RoamDelPMKIDfromCache( tHalHandle hHal, tANI_U8 sessionId,
3348 tANI_U8 *pBSSId,
3349 tANI_BOOLEAN flush_cache );
Tushnim Bhattacharyyaad37df12013-10-02 12:01:33 -07003350
3351void smeGetCommandQStatus( tHalHandle hHal );
Rajeev79dbe4c2013-10-05 11:03:42 +05303352
3353#ifdef FEATURE_WLAN_BATCH_SCAN
3354/* ---------------------------------------------------------------------------
3355 \fn sme_SetBatchScanReq
3356 \brief API to set batch scan request in FW
3357 \param hHal - The handle returned by macOpen.
3358 \param pRequest - Pointer to the batch request.
3359 \param sessionId - session ID
3360 \param callbackRoutine - HDD callback which needs to be invoked after
3361 getting set batch scan response from FW
3362 \param callbackContext - pAdapter context
3363 \return eHalStatus
3364 ---------------------------------------------------------------------------*/
3365eHalStatus
3366sme_SetBatchScanReq
3367(
3368 tHalHandle hHal, tSirSetBatchScanReq *pRequest, tANI_U8 sessionId,
3369 void (*callbackRoutine) (void *callbackCtx, tSirSetBatchScanRsp *pRsp),
3370 void *callbackContext
3371);
3372
3373/* ---------------------------------------------------------------------------
3374 \fn sme_TriggerBatchScanResultInd
3375 \brief API to trigger batch scan result indications from from FW
3376 \param hHal - The handle returned by macOpen.
3377 \param pRequest - Pointer to get batch request.
3378 \param sessionId - session ID
3379 \param callbackRoutine - HDD callback which needs to be invoked after
3380 getting get batch scan response from FW
3381 \param callbackContext - pAdapter context
3382 \return eHalStatus
3383 ---------------------------------------------------------------------------*/
3384eHalStatus
3385sme_TriggerBatchScanResultInd
3386(
3387 tHalHandle hHal, tSirTriggerBatchScanResultInd *pRequest, tANI_U8 sessionId,
3388 void (*callbackRoutine) (void *callbackCtx, void *pRsp),
3389 void *callbackContext
3390);
3391
3392/* ---------------------------------------------------------------------------
3393 \fn sme_StopBatchScanInd
3394 \brief API to stop batch scan request in FW
3395 \param hHal - The handle returned by macOpen.
3396 \param pRequest - Pointer to stop batch indication
3397 \return eHalStatus
3398 ---------------------------------------------------------------------------*/
3399eHalStatus
3400sme_StopBatchScanInd
3401(
3402 tHalHandle hHal, tSirStopBatchScanInd *pInd, tANI_U8 sessionId
3403);
3404
3405#endif
Leo Chang0b0e45a2013-12-15 15:18:55 -08003406
3407#ifdef FEATURE_WLAN_CH_AVOID
3408/* ---------------------------------------------------------------------------
3409 \fn sme_AddChAvoidCallback
3410 \brief Used to plug in callback function
3411 Which notify channel may not be used with SAP or P2PGO mode.
3412 Notification come from FW.
3413 \param hHal
3414 \param pCallbackfn : callback function pointer should be plugged in
3415 \- return eHalStatus
3416 -------------------------------------------------------------------------*/
3417eHalStatus sme_AddChAvoidCallback
3418(
3419 tHalHandle hHal,
3420 void (*pCallbackfn)(void *pAdapter, void *indParam)
3421);
3422#endif /* FEATURE_WLAN_CH_AVOID */
Tushnim Bhattacharyyaed4d0c22014-01-30 11:56:44 -08003423eHalStatus sme_UpdateConnectDebug(tHalHandle hHal, tANI_U32 set_value);
Sushant Kaushike0d2cce2014-04-10 14:36:07 +05303424/* ---------------------------------------------------------------------------
3425 \fn sme_requestTypetoString
3426 \brief API to convert requestType enum values
3427 to string.
3428 ---------------------------------------------------------------------------*/
3429const char * sme_requestTypetoString(const v_U8_t requestType);
3430/* ---------------------------------------------------------------------------
3431 \fn sme_PmcStatetoString
3432 \brief API to convert PmcState enum values
3433 to string.
3434 ---------------------------------------------------------------------------*/
3435const char * sme_PmcStatetoString(const v_U8_t pmcState);
c_hpothu92367912014-05-01 15:18:17 +05303436
3437eHalStatus sme_getBcnMissRate(tHalHandle, tANI_U8, void *, void *);
3438
Agarwal Ashish5e414792014-06-08 15:25:23 +05303439tANI_BOOLEAN sme_Is11dCountrycode(tHalHandle hHal);
Atul Mittalc0f739f2014-07-31 13:47:47 +05303440
3441// tdlsoffchan
3442VOS_STATUS sme_SendTdlsChanSwitchReq(tHalHandle hHal,
3443 tANI_U8 sessionId,
3444 tSirMacAddr peerMac,
3445 tANI_S32 tdlsOffCh,
3446 tANI_S32 tdlsOffChBwOffset,
3447 tANI_U8 tdlsSwMode);
3448
Ganesh Kondabattini8f6e3b32014-08-25 16:07:54 +05303449void sme_SetMiracastMode (tHalHandle hHal,tANI_U8 mode);
c_hpothuef45bc32014-09-11 10:10:18 +05303450
3451void sme_resetCoexEevent(tHalHandle hHal);
3452
Peng Xu117eab42014-09-25 13:33:27 +05303453tANI_U32 sme_GetChannelBondingMode5G(tHalHandle hHal);
3454tANI_U32 sme_GetChannelBondingMode24G(tHalHandle hHal);
3455
Jeff Johnson295189b2012-06-20 16:38:30 -07003456#endif //#if !defined( __SME_API_H )