blob: de34a140195d6f7853cd2b0d9820a1cdb81e30ee [file] [log] [blame]
Jeff Johnson295189b2012-06-20 16:38:30 -07001/*
Jeff Johnson32d95a32012-09-10 13:15:23 -07002 * Copyright (c) 2012, The Linux Foundation. All rights reserved.
Jeff Johnson295189b2012-06-20 16:38:30 -07003 *
4 * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
5 *
6 *
7 * Permission to use, copy, modify, and/or distribute this software for
8 * any purpose with or without fee is hereby granted, provided that the
9 * above copyright notice and this permission notice appear in all
10 * copies.
11 *
12 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
13 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
14 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
15 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
16 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
17 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
18 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19 * PERFORMANCE OF THIS SOFTWARE.
20 */
21
22#if !defined( __SME_API_H )
23#define __SME_API_H
24
25
26/**=========================================================================
27
28 \file smeApi.h
29
30 \brief prototype for SME APIs
31
32 Copyright 2008 (c) Qualcomm, Incorporated. All Rights Reserved.
33
34 Qualcomm Confidential and Proprietary.
35
36 ========================================================================*/
37
38/* $Header$ */
39
40/*--------------------------------------------------------------------------
41 Include Files
42 ------------------------------------------------------------------------*/
43#include "ccmApi.h"
44#include "csrApi.h"
45#include "pmcApi.h"
46#include "vos_mq.h"
47#include "vos_lock.h"
48#include "halTypes.h"
49#include "sirApi.h"
50#include "btcApi.h"
51#include "vos_nvitem.h"
52#include "p2p_Api.h"
53#ifdef FEATURE_WLAN_NON_INTEGRATED_SOC
54#include "halFw.h"
55#endif
56
Jeff Johnsone7245742012-09-05 17:12:55 -070057#ifdef FEATURE_OEM_DATA_SUPPORT
58#include "oemDataApi.h"
59#endif
Jeff Johnson295189b2012-06-20 16:38:30 -070060
61#if defined WLAN_FEATURE_VOWIFI
62#include "smeRrmInternal.h"
63#endif
64
65/*--------------------------------------------------------------------------
66 Preprocessor definitions and constants
67 ------------------------------------------------------------------------*/
68
69#define SME_SUMMARY_STATS 1
70#define SME_GLOBAL_CLASSA_STATS 2
71#define SME_GLOBAL_CLASSB_STATS 4
72#define SME_GLOBAL_CLASSC_STATS 8
73#define SME_GLOBAL_CLASSD_STATS 16
74#define SME_PER_STA_STATS 32
75
76#define SME_INVALID_COUNTRY_CODE "XX"
77
78/*--------------------------------------------------------------------------
79 Type declarations
80 ------------------------------------------------------------------------*/
81typedef struct _smeConfigParams
82{
83 tCsrConfigParam csrConfig;
84#if defined WLAN_FEATURE_VOWIFI
85 tRrmConfigParam rrmConfig;
86#endif
Jeff Johnson04dd8a82012-06-29 20:41:40 -070087#if defined FEATURE_WLAN_LFR
88 tANI_U8 isFastRoamIniFeatureEnabled;
89#endif
Jeff Johnson295189b2012-06-20 16:38:30 -070090#if defined FEATURE_WLAN_CCX
91 tANI_U8 isCcxIniFeatureEnabled;
92#endif
93#if defined WLAN_FEATURE_P2P_INTERNAL
94 tP2PConfigParam p2pConfig;
95#endif
Jeff Johnson04dd8a82012-06-29 20:41:40 -070096#if defined (WLAN_FEATURE_VOWIFI_11R) || defined (FEATURE_WLAN_CCX) || defined(FEATURE_WLAN_LFR)
Jeff Johnson295189b2012-06-20 16:38:30 -070097 tANI_U8 isFastTransitionEnabled;
Jeff Johnson43971f52012-07-17 12:26:56 -070098 tANI_U8 RoamRssiDiff;
Jeff Johnson295189b2012-06-20 16:38:30 -070099#endif
100} tSmeConfigParams, *tpSmeConfigParams;
101
102
103/*-------------------------------------------------------------------------
104 Function declarations and documenation
105 ------------------------------------------------------------------------*/
106
107/*--------------------------------------------------------------------------
108
109 \brief sme_Open() - Initialze all SME modules and put them at idle state
110
111 The function initializes each module inside SME, PMC, CCM, CSR, etc. . Upon
112 successfully return, all modules are at idle state ready to start.
113
114 smeOpen must be called before any other SME APIs can be involved.
115 smeOpen must be called after macOpen.
116
117 \param hHal - The handle returned by macOpen.
118
119 \return eHAL_STATUS_SUCCESS - SME is successfully initialized.
120
121 Other status means SME is failed to be initialized
122 \sa
123
124 --------------------------------------------------------------------------*/
125eHalStatus sme_Open(tHalHandle hHal);
126
127/*--------------------------------------------------------------------------
128
129 \brief sme_Close() - Release all SME modules and their resources.
130
131 The function release each module in SME, PMC, CCM, CSR, etc. . Upon
132 return, all modules are at closed state.
133
134 No SME APIs can be involved after sme_Close except sme_Open.
135 sme_Close must be called before macClose.
136
137 \param hHal - The handle returned by macOpen.
138
139 \return eHAL_STATUS_SUCCESS - SME is successfully close.
140
141 Other status means SME is failed to be closed but caller still cannot
142 call any other SME functions except smeOpen.
143 \sa
144
145 --------------------------------------------------------------------------*/
146eHalStatus sme_Close(tHalHandle hHal);
147
148/*--------------------------------------------------------------------------
149
150 \brief sme_Start() - Put all SME modules at ready state.
151
152 The function starts each module in SME, PMC, CCM, CSR, etc. . Upon
153 successfully return, all modules are ready to run.
154
155 \param hHal - The handle returned by macOpen.
156
157 \return eHAL_STATUS_SUCCESS - SME is ready.
158
159 Other status means SME is failed to start.
160 \sa
161
162 --------------------------------------------------------------------------*/
163eHalStatus sme_Start(tHalHandle hHal);
164
165/*--------------------------------------------------------------------------
166
167 \brief sme_Stop() - Stop all SME modules and put them at idle state
168
169 The function stops each module in SME, PMC, CCM, CSR, etc. . Upon
170 return, all modules are at idle state ready to start.
171
172
173 \param hHal - The handle returned by macOpen.
174
175 \param pmcFlag - The flag tells SME if we want to stop PMC or not
176
177 \return eHAL_STATUS_SUCCESS - SME is stopped.
178
179 Other status means SME is failed to stop but caller should still consider
180 SME is stopped.
181 \sa
182
183 --------------------------------------------------------------------------*/
184eHalStatus sme_Stop(tHalHandle hHal, tANI_BOOLEAN pmcFlag);
185
186
187/*--------------------------------------------------------------------------
188
189 \brief sme_OpenSession() - Open a session for scan/roam operation.
190
191 This is a synchronous API.
192
193
194 \param hHal - The handle returned by macOpen.
195 \param callback - A pointer to the function caller specifies for roam/connect status indication
196 \param pContext - The context passed with callback
197 \param pSelfMacAddr - Caller allocated memory filled with self MAC address (6 bytes)
198 \param pbSessionId - pointer to a caller allocated buffer for returned session ID
199
200 \return eHAL_STATUS_SUCCESS - session is opened. sessionId returned.
201
202 Other status means SME is failed to open the session.
203 eHAL_STATUS_RESOURCES - no more session available.
204 \sa
205
206 --------------------------------------------------------------------------*/
207eHalStatus sme_OpenSession(tHalHandle hHal, csrRoamCompleteCallback callback, void *pContext,
208 tANI_U8 *pSelfMacAddr, tANI_U8 *pbSessionId);
209
210
211/*--------------------------------------------------------------------------
212
213 \brief sme_CloseSession() - Open a session for scan/roam operation.
214
215 This is a synchronous API.
216
217
218 \param hHal - The handle returned by macOpen.
219
220 \param sessionId - A previous opened session's ID.
221
222 \return eHAL_STATUS_SUCCESS - session is closed.
223
224 Other status means SME is failed to open the session.
225 eHAL_STATUS_INVALID_PARAMETER - session is not opened.
226 \sa
227
228 --------------------------------------------------------------------------*/
229eHalStatus sme_CloseSession(tHalHandle hHal, tANI_U8 sessionId,
230 csrRoamSessionCloseCallback callback, void *pContext);
231
232
233
234/*--------------------------------------------------------------------------
235
236 \brief sme_UpdateConfig() - Change configurations for all SME moduels
237
238 The function updates some configuration for modules in SME, CCM, CSR, etc
239 during SMEs close -> open sequence.
240
241 Modules inside SME apply the new configuration at the next transaction.
242
243
244 \param hHal - The handle returned by macOpen.
245 \Param pSmeConfigParams - a pointer to a caller allocated object of
246 typedef struct _smeConfigParams.
247
248 \return eHAL_STATUS_SUCCESS - SME update the config parameters successfully.
249
250 Other status means SME is failed to update the config parameters.
251 \sa
252
253 --------------------------------------------------------------------------*/
254eHalStatus sme_UpdateConfig(tHalHandle hHal, tpSmeConfigParams pSmeConfigParams);
255
256#ifdef FEATURE_WLAN_SCAN_PNO
257/*--------------------------------------------------------------------------
258
259 \brief sme_UpdateChannelConfig() - Update channel configuration in RIVA.
260
261 It is used at driver start up to inform RIVA of the default channel
262 configuration.
263
264 This is a synchronuous call
265
266 \param hHal - The handle returned by macOpen.
267
268 \return eHAL_STATUS_SUCCESS - SME update the channel config successfully.
269
270 Other status means SME is failed to update the channel config.
271 \sa
272
273 --------------------------------------------------------------------------*/
274eHalStatus sme_UpdateChannelConfig(tHalHandle hHal);
275
276#endif // FEATURE_WLAN_SCAN_PNLO
277#ifdef WLAN_SOFTAP_FEATURE
278/*--------------------------------------------------------------------------
279
280 \brief sme_set11dinfo() - Set the 11d information about valid channels
281 and there power using information from nvRAM
282 This function is called only for AP.
283
284 This is a synchronuous call
285
286 \param hHal - The handle returned by macOpen.
287 \Param pSmeConfigParams - a pointer to a caller allocated object of
288 typedef struct _smeConfigParams.
289
290 \return eHAL_STATUS_SUCCESS - SME update the config parameters successfully.
291
292 Other status means SME is failed to update the config parameters.
293 \sa
294--------------------------------------------------------------------------*/
295
296eHalStatus sme_set11dinfo(tHalHandle hHal, tpSmeConfigParams pSmeConfigParams);
297
298/*--------------------------------------------------------------------------
299
300 \brief sme_getSoftApDomain() - Get the current regulatory domain of softAp.
301
302 This is a synchronuous call
303
304 \param hHal - The handle returned by HostapdAdapter.
305 \Param v_REGDOMAIN_t - The current Regulatory Domain requested for SoftAp.
306
307 \return eHAL_STATUS_SUCCESS - SME successfully completed the request.
308
309 Other status means, failed to get the current regulatory domain.
310 \sa
311--------------------------------------------------------------------------*/
312
313eHalStatus sme_getSoftApDomain(tHalHandle hHal, v_REGDOMAIN_t *domainIdSoftAp);
314
315eHalStatus sme_setRegInfo(tHalHandle hHal, tANI_U8 *apCntryCode);
316
317#endif
318
319/* ---------------------------------------------------------------------------
320 \fn sme_ChangeConfigParams
321 \brief The SME API exposed for HDD to provide config params to SME during
322 SMEs stop -> start sequence.
323
324 If HDD changed the domain that will cause a reset. This function will
325 provide the new set of 11d information for the new domain. Currrently this
326 API provides info regarding 11d only at reset but we can extend this for
327 other params (PMC, QoS) which needs to be initialized again at reset.
328
329 This is a synchronuous call
330
331 \param hHal - The handle returned by macOpen.
332
333 \Param
334 pUpdateConfigParam - a pointer to a structure (tCsrUpdateConfigParam) that
335 currently provides 11d related information like Country code,
336 Regulatory domain, valid channel list, Tx power per channel, a
337 list with active/passive scan allowed per valid channel.
338
339 \return eHalStatus
340 ---------------------------------------------------------------------------*/
341eHalStatus sme_ChangeConfigParams(tHalHandle hHal,
342 tCsrUpdateConfigParam *pUpdateConfigParam);
343
344/*--------------------------------------------------------------------------
345
346 \brief sme_HDDReadyInd() - SME sends eWNI_SME_SYS_READY_IND to PE to inform that the NIC
347 is ready tio run.
348
349 The function is called by HDD at the end of initialization stage so PE/HAL can enable the NIC
350 to running state.
351
352
353 \param hHal - The handle returned by macOpen.
354
355 \return eHAL_STATUS_SUCCESS - eWNI_SME_SYS_READY_IND is sent to PE successfully.
356
357 Other status means SME failed to send the message to PE.
358 \sa
359
360 --------------------------------------------------------------------------*/
361eHalStatus sme_HDDReadyInd(tHalHandle hHal);
362
363
364/*--------------------------------------------------------------------------
365
366 \brief sme_ProcessMsg() - The main message processor for SME.
367
368 The function is called by a message dispatcher when to process a message
369 targeted for SME.
370
371
372 \param hHal - The handle returned by macOpen.
373 \param pMsg - A pointer to a caller allocated object of tSirMsgQ.
374
375 \return eHAL_STATUS_SUCCESS - SME successfully process the message.
376
377 Other status means SME failed to process the message.
378 \sa
379
380 --------------------------------------------------------------------------*/
381eHalStatus sme_ProcessMsg(tHalHandle hHal, vos_msg_t* pMsg);
382
383v_VOID_t sme_FreeMsg( tHalHandle hHal, vos_msg_t* pMsg );
384
385/* ---------------------------------------------------------------------------
386 \fn sme_ScanRequest
387 \brief a wrapper function to Request a 11d or full scan from CSR.
388 \param pScanRequestID - pointer to an object to get back the request ID
389 \param callback - a callback function that scan calls upon finish, will not
390 be called if csrScanRequest returns error
391 \param pContext - a pointer passed in for the callback
392 \return eHalStatus
393 ---------------------------------------------------------------------------*/
394eHalStatus sme_ScanRequest(tHalHandle hHal, tANI_U8 sessionId, tCsrScanRequest *,
395 tANI_U32 *pScanRequestID,
396 csrScanCompleteCallback callback, void *pContext);
397
398
399/* ---------------------------------------------------------------------------
400 \fn sme_ScanSetBGScanparams
401 \brief a wrapper function to request CSR to set BG scan params in PE
402 \param pScanReq - BG scan request structure
403 \return eHalStatus
404 ---------------------------------------------------------------------------*/
405eHalStatus sme_ScanSetBGScanparams(tHalHandle hHal, tANI_U8 sessionId, tCsrBGScanRequest *pScanReq);
406
407
408/* ---------------------------------------------------------------------------
409 \fn sme_ScanGetResult
410 \brief a wrapper function to request scan results from CSR.
411 \param pFilter - If pFilter is NULL, all cached results are returned
412 \param phResult - an object for the result.
413 \return eHalStatus
414 ---------------------------------------------------------------------------*/
415eHalStatus sme_ScanGetResult(tHalHandle hHal, tANI_U8 sessionId, tCsrScanResultFilter *pFilter,
416 tScanResultHandle *phResult);
417
418
419/* ---------------------------------------------------------------------------
420 \fn sme_ScanFlushResult
421 \brief a wrapper function to request CSR to clear scan results.
422 \return eHalStatus
423 ---------------------------------------------------------------------------*/
424eHalStatus sme_ScanFlushResult(tHalHandle hHal, tANI_U8 sessionId);
425
426
427/* ---------------------------------------------------------------------------
428 \fn sme_ScanResultGetFirst
429 \brief a wrapper function to request CSR to returns the first element of
430 scan result.
431 \param hScanResult - returned from csrScanGetResult
432 \return tCsrScanResultInfo * - NULL if no result
433 ---------------------------------------------------------------------------*/
434tCsrScanResultInfo *sme_ScanResultGetFirst(tHalHandle,
435 tScanResultHandle hScanResult);
436
437/* ---------------------------------------------------------------------------
438 \fn sme_ScanResultGetNext
439 \brief a wrapper function to request CSR to returns the next element of
440 scan result. It can be called without calling csrScanResultGetFirst
441 first
442 \param hScanResult - returned from csrScanGetResult
443 \return Null if no result or reach the end
444 ---------------------------------------------------------------------------*/
445tCsrScanResultInfo *sme_ScanResultGetNext(tHalHandle,
446 tScanResultHandle hScanResult);
447
448/* ---------------------------------------------------------------------------
449 \fn sme_ScanResultPurge
450 \brief a wrapper function to request CSR to remove all items(tCsrScanResult)
451 in the list and free memory for each item
452 \param hScanResult - returned from csrScanGetResult. hScanResult is
453 considered gone by
454 calling this function and even before this function reutrns.
455 \return eHalStatus
456 ---------------------------------------------------------------------------*/
457eHalStatus sme_ScanResultPurge(tHalHandle hHal, tScanResultHandle hScanResult);
458
459/* ---------------------------------------------------------------------------
460 \fn sme_ScanGetPMKIDCandidateList
461 \brief a wrapper function to return the PMKID candidate list
462 \param pPmkidList - caller allocated buffer point to an array of
463 tPmkidCandidateInfo
464 \param pNumItems - pointer to a variable that has the number of
465 tPmkidCandidateInfo allocated when retruning, this is
466 either the number needed or number of items put into
467 pPmkidList
468 \return eHalStatus - when fail, it usually means the buffer allocated is not
469 big enough and pNumItems
470 has the number of tPmkidCandidateInfo.
471 \Note: pNumItems is a number of tPmkidCandidateInfo,
472 not sizeof(tPmkidCandidateInfo) * something
473 ---------------------------------------------------------------------------*/
474eHalStatus sme_ScanGetPMKIDCandidateList(tHalHandle hHal, tANI_U8 sessionId,
475 tPmkidCandidateInfo *pPmkidList,
476 tANI_U32 *pNumItems );
477
478
479/*----------------------------------------------------------------------------
480 \fn sme_RoamRegisterLinkQualityIndCallback
481
482 \brief
483 a wrapper function to allow HDD to register a callback handler with CSR for
484 link quality indications.
485
486 Only one callback may be registered at any time.
487 In order to deregister the callback, a NULL cback may be provided.
488
489 Registration happens in the task context of the caller.
490
491 \param callback - Call back being registered
492 \param pContext - user data
493
494 DEPENDENCIES: After CSR open
495
496 \return eHalStatus
497-----------------------------------------------------------------------------*/
498eHalStatus sme_RoamRegisterLinkQualityIndCallback(tHalHandle hHal, tANI_U8 sessionId,
499 csrRoamLinkQualityIndCallback callback,
500 void *pContext);
501
502
503/* ---------------------------------------------------------------------------
504 \fn sme_RoamConnect
505 \brief a wrapper function to request CSR to inititiate an association
506 \param sessionId - the sessionId returned by sme_OpenSession.
507 \param pProfile - can be NULL to join to any open ones
508 \param pRoamId - to get back the request ID
509 \return eHalStatus
510 ---------------------------------------------------------------------------*/
511eHalStatus sme_RoamConnect(tHalHandle hHal, tANI_U8 sessionId, tCsrRoamProfile *pProfile,
512 tANI_U32 *pRoamId);
513
514/* ---------------------------------------------------------------------------
515 \fn sme_RoamReassoc
516 \brief a wrapper function to request CSR to inititiate a re-association
517 \param pProfile - can be NULL to join the currently connected AP. In that
518 case modProfileFields should carry the modified field(s) which could trigger
519 reassoc
520 \param modProfileFields - fields which are part of tCsrRoamConnectedProfile
521 that might need modification dynamically once STA is up & running and this
522 could trigger a reassoc
523 \param pRoamId - to get back the request ID
524 \return eHalStatus
525 -------------------------------------------------------------------------------*/
526eHalStatus sme_RoamReassoc(tHalHandle hHal, tANI_U8 sessionId, tCsrRoamProfile *pProfile,
527 tCsrRoamModifyProfileFields modProfileFields,
528 tANI_U32 *pRoamId);
529
530/* ---------------------------------------------------------------------------
531 \fn sme_RoamConnectToLastProfile
532 \brief a wrapper function to request CSR to disconnect and reconnect with
533 the same profile
534 \return eHalStatus. It returns fail if currently connected
535 ---------------------------------------------------------------------------*/
536eHalStatus sme_RoamConnectToLastProfile(tHalHandle hHal, tANI_U8 sessionId);
537
538/* ---------------------------------------------------------------------------
539 \fn sme_RoamDisconnect
540 \brief a wrapper function to request CSR to disconnect from a network
541 \param reason -- To indicate the reason for disconnecting. Currently, only
542 eCSR_DISCONNECT_REASON_MIC_ERROR is meanful.
543 \return eHalStatus
544 ---------------------------------------------------------------------------*/
545eHalStatus sme_RoamDisconnect(tHalHandle hHal, tANI_U8 sessionId, eCsrRoamDisconnectReason reason);
546
547#ifdef WLAN_SOFTAP_FEATURE
548/* ---------------------------------------------------------------------------
549 \fn sme_RoamStopBss
550 \brief a wrapper function to request CSR to stop bss
551 \param sessionId - sessionId of SoftAP
552 \return eHalStatus
553 ---------------------------------------------------------------------------*/
554eHalStatus sme_RoamStopBss(tHalHandle hHal, tANI_U8 sessionId);
555
556/* ---------------------------------------------------------------------------
557 \fn sme_RoamGetAssociatedStas
558 \brief To probe the list of associated stations from various modules of CORE stack.
559 \This is an asynchronous API.
560 \param sessionId - sessionId of SoftAP
561 \param modId - Module from whom list of associtated stations is to be probed.
562 If an invalid module is passed then by default VOS_MODULE_ID_PE will be probed
563 \param pUsrContext - Opaque HDD context
564 \param pfnSapEventCallback - Sap event callback in HDD
565 \param pAssocBuf - Caller allocated memory to be filled with associatd stations info
566 \return eHalStatus
567 -------------------------------------------------------------------------------*/
568eHalStatus sme_RoamGetAssociatedStas(tHalHandle hHal, tANI_U8 sessionId,
569 VOS_MODULE_ID modId, void *pUsrContext,
570 void *pfnSapEventCallback, tANI_U8 *pAssocStasBuf);
571
572/* ---------------------------------------------------------------------------
573 \fn sme_RoamDisconnectSta
574 \brief To disassociate a station. This is an asynchronous API.
575 \param pPeerMacAddr - Caller allocated memory filled with peer MAC address (6 bytes)
576 \return eHalStatus SUCCESS Roam callback will be called to indicate actual results
577 -------------------------------------------------------------------------------*/
578eHalStatus sme_RoamDisconnectSta(tHalHandle hHal, tANI_U8 sessionId, tANI_U8 *pPeerMacAddr);
579
580/* ---------------------------------------------------------------------------
581 \fn sme_RoamDeauthSta
582 \brief To disassociate a station. This is an asynchronous API.
583 \param hHal - Global structure
584 \param sessionId - sessionId of SoftAP
585 \param pPeerMacAddr - Caller allocated memory filled with peer MAC address (6 bytes)
586 \return eHalStatus SUCCESS Roam callback will be called to indicate actual results
587 -------------------------------------------------------------------------------*/
588eHalStatus sme_RoamDeauthSta(tHalHandle hHal, tANI_U8 sessionId,
589 tANI_U8 *pPeerMacAddr);
590
591/* ---------------------------------------------------------------------------
592 \fn sme_RoamTKIPCounterMeasures
593 \brief To start or stop TKIP counter measures. This is an asynchronous API.
594 \param sessionId - sessionId of SoftAP
595 \param bEnable - Flag to start/stop TKIP countermeasures
596 \return eHalStatus SUCCESS Roam callback will be called to indicate actual results
597 -------------------------------------------------------------------------------*/
598eHalStatus sme_RoamTKIPCounterMeasures(tHalHandle hHal, tANI_U8 sessionId, tANI_BOOLEAN bEnable);
599
600/* ---------------------------------------------------------------------------
601 \fn sme_RoamGetWpsSessionOverlap
602 \brief To get the WPS PBC session overlap information.
603 \This is an asynchronous API.
604 \param sessionId - sessionId of SoftAP
605 \param pUsrContext - Opaque HDD context
606 \param pfnSapEventCallback - Sap event callback in HDD
607 \return eHalStatus
608 -------------------------------------------------------------------------------*/
609eHalStatus sme_RoamGetWpsSessionOverlap(tHalHandle hHal, tANI_U8 sessionId,
610 void *pUsrContext, void *pfnSapEventCallback,
611 v_MACADDR_t pRemoveMac);
612#endif
613
614/* ---------------------------------------------------------------------------
615 \fn sme_RoamGetConnectState
616 \brief a wrapper function to request CSR to return the current connect state
617 of Roaming
618 \return eHalStatus
619 ---------------------------------------------------------------------------*/
620eHalStatus sme_RoamGetConnectState(tHalHandle hHal, tANI_U8 sessionId, eCsrConnectState *pState);
621
622/* ---------------------------------------------------------------------------
623 \fn sme_RoamGetConnectProfile
624 \brief a wrapper function to request CSR to return the current connect
625 profile. Caller must call csrRoamFreeConnectProfile after it is done
626 and before reuse for another csrRoamGetConnectProfile call.
627 \param pProfile - pointer to a caller allocated structure
628 tCsrRoamConnectedProfile
629 \return eHalStatus. Failure if not connected
630 ---------------------------------------------------------------------------*/
631eHalStatus sme_RoamGetConnectProfile(tHalHandle hHal, tANI_U8 sessionId,
632 tCsrRoamConnectedProfile *pProfile);
633
634/* ---------------------------------------------------------------------------
635 \fn sme_RoamFreeConnectProfile
636 \brief a wrapper function to request CSR to free and reinitialize the
637 profile returned previously by csrRoamGetConnectProfile.
638 \param pProfile - pointer to a caller allocated structure
639 tCsrRoamConnectedProfile
640 \return eHalStatus.
641 ---------------------------------------------------------------------------*/
642eHalStatus sme_RoamFreeConnectProfile(tHalHandle hHal,
643 tCsrRoamConnectedProfile *pProfile);
644
645/* ---------------------------------------------------------------------------
646 \fn sme_RoamSetPMKIDCache
647 \brief a wrapper function to request CSR to return the PMKID candidate list
648 \param pPMKIDCache - caller allocated buffer point to an array of
649 tPmkidCacheInfo
650 \param numItems - a variable that has the number of tPmkidCacheInfo
651 allocated when retruning, this is either the number needed
652 or number of items put into pPMKIDCache
653 \return eHalStatus - when fail, it usually means the buffer allocated is not
654 big enough and pNumItems has the number of
655 tPmkidCacheInfo.
656 \Note: pNumItems is a number of tPmkidCacheInfo,
657 not sizeof(tPmkidCacheInfo) * something
658 ---------------------------------------------------------------------------*/
659eHalStatus sme_RoamSetPMKIDCache( tHalHandle hHal, tANI_U8 sessionId, tPmkidCacheInfo *pPMKIDCache,
660 tANI_U32 numItems );
661
662/* ---------------------------------------------------------------------------
663 \fn sme_RoamGetSecurityReqIE
664 \brief a wrapper function to request CSR to return the WPA or RSN or WAPI IE CSR
665 passes to PE to JOIN request or START_BSS request
666 This is a synchronuous call.
667 \param sessionId - returned by sme_OpenSession.
668 \param pLen - caller allocated memory that has the length of pBuf as input.
669 Upon returned, *pLen has the needed or IE length in pBuf.
670 \param pBuf - Caller allocated memory that contain the IE field, if any,
671 upon return
672 \param secType - Specifies whether looking for WPA/WPA2/WAPI IE
673 \return eHalStatus - when fail, it usually means the buffer allocated is not
674 big enough
675 ---------------------------------------------------------------------------*/
676eHalStatus sme_RoamGetSecurityReqIE(tHalHandle hHal, tANI_U8 sessionId, tANI_U32 *pLen,
677 tANI_U8 *pBuf, eCsrSecurityType secType);
678
679/* ---------------------------------------------------------------------------
680 \fn sme_RoamGetSecurityRspIE
681 \brief a wrapper function to request CSR to return the WPA or RSN or WAPI IE from
682 the beacon or probe rsp if connected
683 \param sessionId - returned by sme_OpenSession.
684 \param pLen - caller allocated memory that has the length of pBuf as input.
685 Upon returned, *pLen has the needed or IE length in pBuf.
686 \param pBuf - Caller allocated memory that contain the IE field, if any,
687 upon return
688 \param secType - Specifies whether looking for WPA/WPA2/WAPI IE
689 \return eHalStatus - when fail, it usually means the buffer allocated is not
690 big enough
691 ---------------------------------------------------------------------------*/
692eHalStatus sme_RoamGetSecurityRspIE(tHalHandle hHal, tANI_U8 sessionId, tANI_U32 *pLen,
693 tANI_U8 *pBuf, eCsrSecurityType secType);
694
695
696/* ---------------------------------------------------------------------------
697 \fn sme_RoamGetNumPMKIDCache
698 \brief a wrapper function to request CSR to return number of PMKID cache
699 entries
700 \return tANI_U32 - the number of PMKID cache entries
701 ---------------------------------------------------------------------------*/
702tANI_U32 sme_RoamGetNumPMKIDCache(tHalHandle hHal, tANI_U8 sessionId);
703
704/* ---------------------------------------------------------------------------
705 \fn sme_RoamGetPMKIDCache
706 \brief a wrapper function to request CSR to return PMKID cache from CSR
707 \param pNum - caller allocated memory that has the space of the number of
708 pBuf tPmkidCacheInfo as input. Upon returned, *pNum has the
709 needed or actually number in tPmkidCacheInfo.
710 \param pPmkidCache - Caller allocated memory that contains PMKID cache, if
711 any, upon return
712 \return eHalStatus - when fail, it usually means the buffer allocated is not
713 big enough
714 ---------------------------------------------------------------------------*/
715eHalStatus sme_RoamGetPMKIDCache(tHalHandle hHal, tANI_U8 sessionId, tANI_U32 *pNum,
716 tPmkidCacheInfo *pPmkidCache);
717
718/* ---------------------------------------------------------------------------
719 \fn sme_GetConfigParam
720 \brief a wrapper function that HDD calls to get the global settings
721 currently maintained by CSR.
722 \param pParam - caller allocated memory
723 \return eHalStatus
724 ---------------------------------------------------------------------------*/
725eHalStatus sme_GetConfigParam(tHalHandle hHal, tSmeConfigParams *pParam);
726
727/* ---------------------------------------------------------------------------
728 \fn sme_GetStatistics
729 \brief a wrapper function that client calls to register a callback to get
730 different PHY level statistics from CSR.
731
732 \param requesterId - different client requesting for statistics, HDD, UMA/GAN etc
733 \param statsMask - The different category/categories of stats requester is looking for
734 The order in which you set the bits in the statsMask for requesting
735 different type of stats is:
736
737 eCsrSummaryStats = bit 0
738 eCsrGlobalClassAStats = bit 1
739 eCsrGlobalClassBStats = bit 2
740 eCsrGlobalClassCStats = bit 3
741 eCsrGlobalClassDStats = bit 4
742 eCsrPerStaStats = bit 5
743
744 \param callback - SME sends back the requested stats using the callback
745 \param periodicity - If requester needs periodic update, 0 means it's an one
746 time request
747 \param cache - If requester is happy with cached stats
748 \param staId - The station ID for which the stats is requested for
749 \param pContext - user context to be passed back along with the callback
750 \return eHalStatus
751 ---------------------------------------------------------------------------*/
752eHalStatus sme_GetStatistics(tHalHandle hHal, eCsrStatsRequesterType requesterId,
753 tANI_U32 statsMask,
754 tCsrStatsCallback callback,
755 tANI_U32 periodicity, tANI_BOOLEAN cache,
756 tANI_U8 staId, void *pContext);
757
758eHalStatus sme_GetRssi(tHalHandle hHal,
759 tCsrRssiCallback callback,
760 tANI_U8 staId, tCsrBssid bssId, void *pContext, void* pVosContext);
761
762/* ---------------------------------------------------------------------------
763 \fn sme_CfgSetInt
764 \brief a wrapper function that HDD calls to set parameters in CFG.
765 \param cfgId - Configuration Parameter ID (type) for STA.
766 \param ccmValue - The information related to Configuration Parameter ID
767 which needs to be saved in CFG
768 \param callback - To be registered by CSR with CCM. Once the CFG done with
769 saving the information in the database, it notifies CCM &
770 then the callback will be invoked to notify.
771 \param toBeSaved - To save the request for future reference
772 \return eHalStatus
773 ---------------------------------------------------------------------------*/
774eHalStatus sme_CfgSetInt(tHalHandle hHal, tANI_U32 cfgId, tANI_U32 ccmValue,
775 tCcmCfgSetCallback callback, eAniBoolean toBeSaved) ;
776
777/* ---------------------------------------------------------------------------
778 \fn sme_CfgSetStr
779 \brief a wrapper function that HDD calls to set parameters in CFG.
780 \param cfgId - Configuration Parameter ID (type) for STA.
781 \param pStr - Pointer to the byte array which carries the information needs
782 to be saved in CFG
783 \param length - Length of the data to be saved
784 \param callback - To be registered by CSR with CCM. Once the CFG done with
785 saving the information in the database, it notifies CCM &
786 then the callback will be invoked to notify.
787 \param toBeSaved - To save the request for future reference
788 \return eHalStatus
789 ---------------------------------------------------------------------------*/
790eHalStatus sme_CfgSetStr(tHalHandle hHal, tANI_U32 cfgId, tANI_U8 *pStr,
791 tANI_U32 length, tCcmCfgSetCallback callback,
792 eAniBoolean toBeSaved) ;
793
794
795/* ---------------------------------------------------------------------------
796 \fn sme_GetModifyProfileFields
797 \brief HDD or SME - QOS calls this function to get the current values of
798 connected profile fields, changing which can cause reassoc.
799 This function must be called after CFG is downloaded and STA is in connected
800 state. Also, make sure to call this function to get the current profile
801 fields before calling the reassoc. So that pModifyProfileFields will have
802 all the latest values plus the one(s) has been updated as part of reassoc
803 request.
804 \param pModifyProfileFields - pointer to the connected profile fields
805 changing which can cause reassoc
806
807 \return eHalStatus
808 -------------------------------------------------------------------------------*/
809eHalStatus sme_GetModifyProfileFields(tHalHandle hHal, tANI_U8 sessionId,
810 tCsrRoamModifyProfileFields * pModifyProfileFields);
811
812
813/*--------------------------------------------------------------------------
814 \fn sme_SetConfigPowerSave
815 \brief Wrapper fn to change power save configuration in SME (PMC) module.
816 For BMPS related configuration, this function also updates the CFG
817 and sends a message to FW to pick up the new values. Note: Calling
818 this function only updates the configuration and does not enable
819 the specified power save mode.
820 \param hHal - The handle returned by macOpen.
821 \param psMode - Power Saving mode being modified
822 \param pConfigParams - a pointer to a caller allocated object of type
823 tPmcSmpsConfigParams or tPmcBmpsConfigParams or tPmcImpsConfigParams
824 \return eHalStatus
825 --------------------------------------------------------------------------*/
826eHalStatus sme_SetConfigPowerSave(tHalHandle hHal, tPmcPowerSavingMode psMode,
827 void *pConfigParams);
828
829/*--------------------------------------------------------------------------
830 \fn sme_GetConfigPowerSave
831 \brief Wrapper fn to retireve power save configuration in SME (PMC) module
832 \param hHal - The handle returned by macOpen.
833 \param psMode - Power Saving mode
834 \param pConfigParams - a pointer to a caller allocated object of type
835 tPmcSmpsConfigParams or tPmcBmpsConfigParams or tPmcImpsConfigParams
836 \return eHalStatus
837 --------------------------------------------------------------------------*/
838eHalStatus sme_GetConfigPowerSave(tHalHandle hHal, tPmcPowerSavingMode psMode,
839 void *pConfigParams);
840
841/* ---------------------------------------------------------------------------
842 \fn sme_SignalPowerEvent
843 \brief Signals to PMC that a power event has occurred. Used for putting
844 the chip into deep sleep mode.
845 \param hHal - The handle returned by macOpen.
846 \param event - the event that has occurred
847 \return eHalStatus
848 ---------------------------------------------------------------------------*/
849extern eHalStatus sme_SignalPowerEvent (
850 tHalHandle hHal,
851 tPmcPowerEvent event);
852
853/* ---------------------------------------------------------------------------
854 \fn sme_EnablePowerSave
855 \brief Enables one of the power saving modes. This API does not cause a
856 device state change. This is purely a configuration API.
857 \param hHal - The handle returned by macOpen.
858 \param psMode - The power saving mode to enable.
859 \return eHalStatus
860 ---------------------------------------------------------------------------*/
861extern eHalStatus sme_EnablePowerSave (
862 tHalHandle hHal,
863 tPmcPowerSavingMode psMode);
864
865/* ---------------------------------------------------------------------------
866 \fn sme_DisablePowerSave
867 \brief Disables one of the power saving modes.Disabling does not imply
868 that device will be brought out of the current PS mode. This is
869 purely a configuration API.
870 \param hHal - The handle returned by macOpen.
871 \param psMode - The power saving mode to disable.
872 \return eHalStatus
873 ---------------------------------------------------------------------------*/
874extern eHalStatus sme_DisablePowerSave (
875 tHalHandle hHal,
876 tPmcPowerSavingMode psMode);
877
878/* ---------------------------------------------------------------------------
879 \fn sme_StartAutoBmpsTimer
880 \brief Starts a timer that periodically polls all the registered
881 module for entry into Bmps mode. This timer is started only if BMPS is
882 enabled and whenever the device is in full power.
883 \param hHal - The handle returned by macOpen.
884 \return eHalStatus
885 ---------------------------------------------------------------------------*/
886extern eHalStatus sme_StartAutoBmpsTimer ( tHalHandle hHal);
887
888/* ---------------------------------------------------------------------------
889 \fn sme_StopAutoBmpsTimer
890 \brief Stops the Auto BMPS Timer that was started using sme_startAutoBmpsTimer
891 Stopping the timer does not cause a device state change. Only the timer
892 is stopped. If "Full Power" is desired, use the sme_RequestFullPower API
893 \param hHal - The handle returned by macOpen.
894 \return eHalStatus
895 ---------------------------------------------------------------------------*/
896extern eHalStatus sme_StopAutoBmpsTimer ( tHalHandle hHal);
897
898/* ---------------------------------------------------------------------------
899 \fn sme_QueryPowerState
900 \brief Returns the current power state of the device.
901 \param hHal - The handle returned by macOpen.
902 \param pPowerState - pointer to location to return power state
903 \param pSwWlanSwitchState - ptr to location to return SW WLAN Switch state
904 \return eHalStatus
905 ---------------------------------------------------------------------------*/
906extern eHalStatus sme_QueryPowerState (
907 tHalHandle hHal,
908 tPmcPowerState *pPowerState,
909 tPmcSwitchState *pSwWlanSwitchState);
910
911/* ---------------------------------------------------------------------------
912 \fn sme_IsPowerSaveEnabled
913 \brief Checks if the device is able to enter a particular power save mode
914 This does not imply that the device is in a particular PS mode
915 \param hHal - The handle returned by macOpen.
916 \param psMode - the power saving mode
917 \return eHalStatus
918 ---------------------------------------------------------------------------*/
919extern tANI_BOOLEAN sme_IsPowerSaveEnabled(
920 tHalHandle hHal,
921 tPmcPowerSavingMode psMode);
922
923/* ---------------------------------------------------------------------------
924 \fn sme_RequestFullPower
925 \brief Request that the device be brought to full power state.
926 Note 1: If "fullPowerReason" specificied in this API is set to
927 eSME_FULL_PWR_NEEDED_BY_HDD, PMC will clear any "buffered wowl" requests
928 and also clear any "buffered BMPS requests by HDD". Assumption is that since
929 HDD is requesting full power, we need to undo any previous HDD requests for
930 BMPS (using sme_RequestBmps) or WoWL (using sme_EnterWoWL). If the reason is
931 specified anything other than above, the buffered requests for BMPS and WoWL
932 will not be cleared.
933 Note 2: Requesting full power (no matter what the fullPowerReason is) doesn't
934 disable the "auto bmps timer" (if it is enabled) or clear any "buffered uapsd
935 request".
936 Note 3: When the device finally enters Full Power PMC will start a timer
937 if any of the following holds true:
938 - Auto BMPS mode is enabled
939 - Uapsd request is pending
940 - HDD's request for BMPS is pending
941 - HDD's request for WoWL is pending
942 On timer expiry PMC will attempt to put the device in BMPS mode if following
943 (in addition to those listed above) holds true:
944 - Polling of all modules through the Power Save Check routine passes
945 - STA is associated to an access point
946 \param hHal - The handle returned by macOpen.
947 \param - callbackRoutine Callback routine invoked in case of success/failure
948 \param - callbackContext - Cookie to be passed back during callback
949 \param - fullPowerReason - Reason why this API is being invoked. SME needs to
950 distinguish between BAP and HDD requests
951 \return eHalStatus - status
952 eHAL_STATUS_SUCCESS - device brought to full power state
953 eHAL_STATUS_FAILURE - device cannot be brought to full power state
954 eHAL_STATUS_PMC_PENDING - device is being brought to full power state,
955 ---------------------------------------------------------------------------*/
956extern eHalStatus sme_RequestFullPower (
957 tHalHandle hHal,
958 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
959 void *callbackContext,
960 tRequestFullPowerReason fullPowerReason);
961
962/* ---------------------------------------------------------------------------
963 \fn sme_RequestBmps
964 \brief Request that the device be put in BMPS state. Request will be
965 accepted only if BMPS mode is enabled and power save check routine
966 passes. Only HDD should invoke this API.
967 \param hHal - The handle returned by macOpen.
968 \param - callbackRoutine Callback routine invoked in case of success/failure
969 \param - callbackContext - Cookie to be passed back during callback
970 \return eHalStatus
971 eHAL_STATUS_SUCCESS - device is in BMPS state
972 eHAL_STATUS_FAILURE - device cannot be brought to BMPS state
973 eHAL_STATUS_PMC_PENDING - device is being brought to BMPS state
974 ---------------------------------------------------------------------------*/
975extern eHalStatus sme_RequestBmps (
976 tHalHandle hHal,
977 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
978 void *callbackContext);
979
980/* ---------------------------------------------------------------------------
981 \fn sme_SetDHCPTillPowerActiveFlag
982 \brief Sets/Clears DHCP related flag in PMC to disable/enable auto BMPS
983 entry by PMC
984 \param hHal - The handle returned by macOpen.
985 ---------------------------------------------------------------------------*/
986void sme_SetDHCPTillPowerActiveFlag(tHalHandle hHal, tANI_U8 flag);
987
988
989/* ---------------------------------------------------------------------------
990 \fn sme_StartUapsd
991 \brief Request that the device be put in UAPSD state. If the device is in
992 Full Power it will be put in BMPS mode first and then into UAPSD
993 mode.
994 \param hHal - The handle returned by macOpen.
995 \param - callbackRoutine Callback routine invoked in case of success/failure
996 \param - callbackContext - Cookie to be passed back during callback
997 eHAL_STATUS_SUCCESS - device is in UAPSD state
998 eHAL_STATUS_FAILURE - device cannot be brought to UAPSD state
999 eHAL_STATUS_PMC_PENDING - device is being brought to UAPSD state
1000 eHAL_STATUS_PMC_DISABLED - UAPSD is disabled or BMPS mode is disabled
1001 \return eHalStatus
1002 ---------------------------------------------------------------------------*/
1003extern eHalStatus sme_StartUapsd (
1004 tHalHandle hHal,
1005 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
1006 void *callbackContext);
1007
1008/* ---------------------------------------------------------------------------
1009 \fn sme_StopUapsd
1010 \brief Request that the device be put out of UAPSD state. Device will be
1011 put in in BMPS state after stop UAPSD completes. Buffered requests for
1012 UAPSD will be cleared after this.
1013 \param hHal - The handle returned by macOpen.
1014 \return eHalStatus
1015 eHAL_STATUS_SUCCESS - device is put out of UAPSD and back in BMPS state
1016 eHAL_STATUS_FAILURE - device cannot be brought out of UAPSD state
1017 ---------------------------------------------------------------------------*/
1018extern eHalStatus sme_StopUapsd (tHalHandle hHal);
1019
1020/* ---------------------------------------------------------------------------
1021 \fn sme_RequestStandby
1022 \brief Request that the device be put in standby. It is HDD's responsibility
1023 to bring the chip to full power and do a discconnect before calling
1024 this API. Request for standby will be rejected if STA is associated
1025 to an AP.
1026 \param hHal - The handle returned by macOpen.
1027 \param - callbackRoutine Callback routine invoked in case of success/failure
1028 \param - callbackContext - Cookie to be passed back during callback
1029 \return eHalStatus
1030 eHAL_STATUS_SUCCESS - device is in Standby mode
1031 eHAL_STATUS_FAILURE - device cannot be put in standby mode
1032 eHAL_STATUS_PMC_PENDING - device is being put in standby mode
1033 ---------------------------------------------------------------------------*/
1034extern eHalStatus sme_RequestStandby (
1035 tHalHandle hHal,
1036 void (*callbackRoutine) (void *callbackContext, eHalStatus status),
1037 void *callbackContext);
1038
1039/* ---------------------------------------------------------------------------
1040 \fn sme_RegisterPowerSaveCheck
1041 \brief Register a power save check routine that is called whenever
1042 the device is about to enter one of the power save modes.
1043 \param hHal - The handle returned by macOpen.
1044 \param checkRoutine - Power save check routine to be registered
1045 \param callbackContext - Cookie to be passed back during callback
1046 \return eHalStatus
1047 eHAL_STATUS_SUCCESS - successfully registered
1048 eHAL_STATUS_FAILURE - not successfully registered
1049 ---------------------------------------------------------------------------*/
1050extern eHalStatus sme_RegisterPowerSaveCheck (
1051 tHalHandle hHal,
1052 tANI_BOOLEAN (*checkRoutine) (void *checkContext), void *checkContext);
1053
1054/* ---------------------------------------------------------------------------
1055 \fn sme_DeregisterPowerSaveCheck
1056 \brief Deregister a power save check routine
1057 \param hHal - The handle returned by macOpen.
1058 \param checkRoutine - Power save check routine to be deregistered
1059 \return eHalStatus
1060 eHAL_STATUS_SUCCESS - successfully deregistered
1061 eHAL_STATUS_FAILURE - not successfully deregistered
1062 ---------------------------------------------------------------------------*/
1063extern eHalStatus sme_DeregisterPowerSaveCheck (
1064 tHalHandle hHal,
1065 tANI_BOOLEAN (*checkRoutine) (void *checkContext));
1066
1067/* ---------------------------------------------------------------------------
1068 \fn sme_RegisterDeviceStateUpdateInd
1069 \brief Register a callback routine that is called whenever
1070 the device enters a new device state (Full Power, BMPS, UAPSD)
1071 \param hHal - The handle returned by macOpen.
1072 \param callbackRoutine - Callback routine to be registered
1073 \param callbackContext - Cookie to be passed back during callback
1074 \return eHalStatus
1075 eHAL_STATUS_SUCCESS - successfully registered
1076 eHAL_STATUS_FAILURE - not successfully registered
1077 ---------------------------------------------------------------------------*/
1078extern eHalStatus sme_RegisterDeviceStateUpdateInd (
1079 tHalHandle hHal,
1080 void (*callbackRoutine) (void *callbackContext, tPmcState pmcState),
1081 void *callbackContext);
1082
1083/* ---------------------------------------------------------------------------
1084 \fn sme_DeregisterDeviceStateUpdateInd
1085 \brief Deregister a routine that was registered for device state changes
1086 \param hHal - The handle returned by macOpen.
1087 \param callbackRoutine - Callback routine to be deregistered
1088 \return eHalStatus
1089 eHAL_STATUS_SUCCESS - successfully deregistered
1090 eHAL_STATUS_FAILURE - not successfully deregistered
1091 ---------------------------------------------------------------------------*/
1092extern eHalStatus sme_DeregisterDeviceStateUpdateInd (
1093 tHalHandle hHal,
1094 void (*callbackRoutine) (void *callbackContext, tPmcState pmcState));
1095
1096/* ---------------------------------------------------------------------------
1097 \fn sme_WowlAddBcastPattern
1098 \brief Add a pattern for Pattern Byte Matching in Wowl mode. Firmware will
1099 do a pattern match on these patterns when Wowl is enabled during BMPS
1100 mode.
1101 \param hHal - The handle returned by macOpen.
1102 \param pattern - Pattern to be added
1103 \return eHalStatus
1104 eHAL_STATUS_FAILURE Cannot add pattern
1105 eHAL_STATUS_SUCCESS Request accepted.
1106 ---------------------------------------------------------------------------*/
1107extern eHalStatus sme_WowlAddBcastPattern (
1108 tHalHandle hHal,
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07001109 tpSirWowlAddBcastPtrn pattern,
1110 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001111
1112/* ---------------------------------------------------------------------------
1113 \fn sme_WowlDelBcastPattern
1114 \brief Delete a pattern that was added for Pattern Byte Matching.
1115 \param hHal - The handle returned by macOpen.
1116 \param pattern - Pattern to be deleted
1117 \return eHalStatus
1118 eHAL_STATUS_FAILURE Cannot delete pattern
1119 eHAL_STATUS_SUCCESS Request accepted.
1120 ---------------------------------------------------------------------------*/
1121extern eHalStatus sme_WowlDelBcastPattern (
1122 tHalHandle hHal,
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07001123 tpSirWowlDelBcastPtrn pattern,
1124 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001125
1126/* ---------------------------------------------------------------------------
1127 \fn sme_EnterWowl
1128 \brief This is the API to request entry into WOWL mode.
1129 WoWLAN works on top of BMPS mode. If the device is not in BMPS mode,
1130 SME will will cache the information that WOWL has been requested and
1131 attempt to put the device in BMPS first. On entry into BMPS, SME will
1132 enter the WOWL mode.
1133 Note 1: After WoWL request is accepted, If module other than HDD requests
1134 full power BEFORE WoWL request is completed, PMC will buffer the WoWL request
1135 and attempt to put the chip into BMPS+WOWL based on a timer.
1136 Note 2: Buffered request for WoWL will be cleared immedisately AFTER "enter Wowl"
1137 completes or if HDD requests full power or if sme_ExitWoWL API is invoked.
1138 Note 3: Both UAPSD and WOWL work on top of BMPS. On entry into BMPS, SME
1139 will give priority to UAPSD and enable only UAPSD if both UAPSD and WOWL
1140 are required. Currently there is no requirement or use case to support UAPSD
1141 and WOWL at the same time.
1142 Note 4. Request for WoWL is rejected if there is a pending UAPSD request.
1143 Note 5. Request for WoWL is rejected if BMPS is disabled.
1144
1145 \param hHal - The handle returned by macOpen.
1146 \param enterWowlCallbackRoutine - Callback routine provided by HDD.
1147 Used for success/failure notification by SME
1148 \param enterWowlCallbackContext - A cookie passed by HDD, that is passed back to HDD
1149 at the time of callback.
1150 \param wakeReasonIndCB - Callback routine provided by HDD.
1151 Used for Wake Reason Indication by SME
1152 \param wakeReasonIndCBContext - A cookie passed by HDD, that is passed back to HDD
1153 at the time of callback.
1154 \return eHalStatus
1155 eHAL_STATUS_SUCCESS Device is already in WoWLAN mode
1156 eHAL_STATUS_FAILURE Device cannot enter WoWLAN mode.
1157 eHAL_STATUS_PMC_PENDING Request accepted. SME will enable WOWL when BMPS
1158 mode is entered.
1159 ---------------------------------------------------------------------------*/
1160extern eHalStatus sme_EnterWowl (
1161 tHalHandle hHal,
1162 void (*enterWowlCallbackRoutine) (void *callbackContext, eHalStatus status),
1163 void *enterWowlCallbackContext,
1164#ifdef WLAN_WAKEUP_EVENTS
1165 void (*wakeReasonIndCB) (void *callbackContext, tpSirWakeReasonInd pWakeReasonInd),
1166 void *wakeReasonIndCBContext,
1167#endif // WLAN_WAKEUP_EVENTS
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07001168 tpSirSmeWowlEnterParams wowlEnterParams, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001169
1170/* ---------------------------------------------------------------------------
1171 \fn sme_ExitWowl
1172 \brief This is the SME API exposed to HDD to request exit from WoWLAN mode.
1173 SME will initiate exit from WoWLAN mode and device will be put in BMPS
1174 mode. Any Buffered request for WoWL will be cleared after this API.
1175 \param hHal - The handle returned by macOpen.
1176 \return eHalStatus
1177 eHAL_STATUS_FAILURE Device cannot exit WoWLAN mode. This can happen
1178 only if the previous "Enter WOWL" transaction has
1179 not even completed.
1180 eHAL_STATUS_SUCCESS Request accepted to exit WoWLAN mode.
1181 ---------------------------------------------------------------------------*/
1182extern eHalStatus sme_ExitWowl (tHalHandle hHal);
1183
1184/* ---------------------------------------------------------------------------
1185
1186 \fn sme_RoamSetKey
1187
1188 \brief To set encryption key. This function should be called only when connected
1189 This is an asynchronous API.
1190
1191 \param pSetKeyInfo - pointer to a caller allocated object of tCsrSetContextInfo
1192
1193 \param pRoamId Upon success return, this is the id caller can use to identify the request in roamcallback
1194
1195 \return eHalStatus SUCCESS Roam callback will be called indicate actually results
1196
1197 FAILURE or RESOURCES The API finished and failed.
1198
1199 -------------------------------------------------------------------------------*/
1200eHalStatus sme_RoamSetKey(tHalHandle, tANI_U8 sessionId, tCsrRoamSetKey *pSetKey, tANI_U32 *pRoamId);
1201
1202/* ---------------------------------------------------------------------------
1203
1204 \fn sme_RoamRemoveKey
1205
1206 \brief To set encryption key. This is an asynchronous API.
1207
1208 \param pRemoveKey - pointer to a caller allocated object of tCsrRoamRemoveKey
1209
1210 \param pRoamId Upon success return, this is the id caller can use to identify the request in roamcallback
1211
1212 \return eHalStatus SUCCESS Roam callback will be called indicate actually results
1213
1214 FAILURE or RESOURCES The API finished and failed.
1215
1216 -------------------------------------------------------------------------------*/
1217eHalStatus sme_RoamRemoveKey(tHalHandle, tANI_U8 sessionId, tCsrRoamRemoveKey *pRemoveKey, tANI_U32 *pRoamId);
1218
1219
1220/* ---------------------------------------------------------------------------
1221
1222 \fn sme_GetCountryCode
1223
1224 \brief To return the current country code. If no country code is applied, default country code is
1225 used to fill the buffer.
1226 If 11d supported is turned off, an error is return and the last applied/default country code is used.
1227 This is a synchronous API.
1228
1229 \param pBuf - pointer to a caller allocated buffer for returned country code.
1230
1231 \param pbLen For input, this parameter indicates how big is the buffer.
1232 Upon return, this parameter has the number of bytes for country. If pBuf
1233 doesn't have enough space, this function returns
1234 fail status and this parameter contains the number that is needed.
1235
1236 \return eHalStatus SUCCESS.
1237
1238 FAILURE or RESOURCES The API finished and failed.
1239
1240 -------------------------------------------------------------------------------*/
1241eHalStatus sme_GetCountryCode(tHalHandle hHal, tANI_U8 *pBuf, tANI_U8 *pbLen);
1242
1243/* ---------------------------------------------------------------------------
1244
1245 \fn sme_SetCountryCode
1246
1247 \brief To change the current/default country code.
1248 If 11d supported is turned off, an error is return.
1249 This is a synchronous API.
1250
1251 \param pCountry - pointer to a caller allocated buffer for the country code.
1252
1253 \param pfRestartNeeded A pointer to caller allocated memory, upon successful return, it indicates
1254 whether a reset is required.
1255
1256 \return eHalStatus SUCCESS.
1257
1258 FAILURE or RESOURCES The API finished and failed.
1259
1260 -------------------------------------------------------------------------------*/
1261eHalStatus sme_SetCountryCode(tHalHandle hHal, tANI_U8 *pCountry, tANI_BOOLEAN *pfRestartNeeded);
1262
1263/* ---------------------------------------------------------------------------
1264 \fn sme_ResetCountryCodeInformation
1265 \brief this function is to reset the country code current being used back to EEPROM default
1266 this includes channel list and power setting. This is a synchronous API.
1267 \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether
1268 a restart is needed to apply the change
1269 \return eHalStatus
1270 -------------------------------------------------------------------------------*/
1271eHalStatus sme_ResetCountryCodeInformation(tHalHandle hHal, tANI_BOOLEAN *pfRestartNeeded);
1272
1273/* ---------------------------------------------------------------------------
1274 \fn sme_GetSupportedCountryCode
1275 \brief this function is to get a list of the country code current being supported
1276 \param pBuf - Caller allocated buffer with at least 3 bytes, upon success return,
1277 this has the country code list. 3 bytes for each country code. This may be NULL if
1278 caller wants to know the needed byte count.
1279 \param pbLen - Caller allocated, as input, it indicates the length of pBuf. Upon success return,
1280 this contains the length of the data in pBuf. If pbuf is NULL, as input, *pbLen should be 0.
1281 \return eHalStatus
1282 -------------------------------------------------------------------------------*/
1283eHalStatus sme_GetSupportedCountryCode(tHalHandle hHal, tANI_U8 *pBuf, tANI_U32 *pbLen);
1284
1285/* ---------------------------------------------------------------------------
1286 \fn sme_GetCurrentRegulatoryDomain
1287 \brief this function is to get the current regulatory domain. This is a synchronous API.
1288 This function must be called after CFG is downloaded and all the band/mode setting already passed into
1289 SME. The function fails if 11d support is turned off.
1290 \param pDomain - Caller allocated buffer to return the current domain.
1291 \return eHalStatus SUCCESS.
1292
1293 FAILURE or RESOURCES The API finished and failed.
1294 -------------------------------------------------------------------------------*/
1295eHalStatus sme_GetCurrentRegulatoryDomain(tHalHandle hHal, v_REGDOMAIN_t *pDomain);
1296
1297/* ---------------------------------------------------------------------------
1298 \fn sme_SetRegulatoryDomain
1299 \brief this function is to set the current regulatory domain.
1300 This function must be called after CFG is downloaded and all the band/mode setting already passed into
1301 SME. This is a synchronous API.
1302 \param domainId - indicate the domain (defined in the driver) needs to set to.
1303 See v_REGDOMAIN_t for definition
1304 \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether
1305 a restart is needed to apply the change
1306 \return eHalStatus
1307 -------------------------------------------------------------------------------*/
1308eHalStatus sme_SetRegulatoryDomain(tHalHandle hHal, v_REGDOMAIN_t domainId, tANI_BOOLEAN *pfRestartNeeded);
1309
1310/* ---------------------------------------------------------------------------
1311
1312 \fn sme_GetRegulatoryDomainForCountry
1313
1314 \brief To return a regulatory domain base on a country code. This is a synchronous API.
1315
1316 \param pCountry - pointer to a caller allocated buffer for input country code.
1317
1318 \param pDomainId Upon successful return, it is the domain that country belongs to.
1319 If it is NULL, returning success means that the country code is known.
1320
1321 \return eHalStatus SUCCESS.
1322
1323 FAILURE or RESOURCES The API finished and failed.
1324
1325 -------------------------------------------------------------------------------*/
1326eHalStatus sme_GetRegulatoryDomainForCountry(tHalHandle hHal, tANI_U8 *pCountry, v_REGDOMAIN_t *pDomainId);
1327
1328
1329
1330/* ---------------------------------------------------------------------------
1331
1332 \fn sme_GetSupportedRegulatoryDomains
1333
1334 \brief To return a list of supported regulatory domains. This is a synchronous API.
1335
1336 \param pDomains - pointer to a caller allocated buffer for returned regulatory domains.
1337
1338 \param pNumDomains For input, this parameter indicates howm many domains pDomains can hold.
1339 Upon return, this parameter has the number for supported domains. If pDomains
1340 doesn't have enough space for all the supported domains, this function returns
1341 fail status and this parameter contains the number that is needed.
1342
1343 \return eHalStatus SUCCESS.
1344
1345 FAILURE or RESOURCES The API finished and failed.
1346
1347 -------------------------------------------------------------------------------*/
1348eHalStatus sme_GetSupportedRegulatoryDomains(tHalHandle hHal, v_REGDOMAIN_t *pDomains, tANI_U32 *pNumDomains);
1349
1350//some support functions
1351tANI_BOOLEAN sme_Is11dSupported(tHalHandle hHal);
1352tANI_BOOLEAN sme_Is11hSupported(tHalHandle hHal);
1353tANI_BOOLEAN sme_IsWmmSupported(tHalHandle hHal);
1354//Upper layer to get the list of the base channels to scan for passively 11d info from csr
1355eHalStatus sme_ScanGetBaseChannels( tHalHandle hHal, tCsrChannelInfo * pChannelInfo );
1356
1357typedef void ( *tSmeChangeCountryCallback)(void *pContext);
1358/* ---------------------------------------------------------------------------
1359
1360 \fn sme_ChangeCountryCode
1361
1362 \brief Change Country code from upperlayer during WLAN driver operation.
1363 This is a synchronous API.
1364
1365 \param hHal - The handle returned by macOpen.
1366
1367 \param pCountry New Country Code String
1368
1369 \return eHalStatus SUCCESS.
1370
1371 FAILURE or RESOURCES The API finished and failed.
1372
1373 -------------------------------------------------------------------------------*/
1374eHalStatus sme_ChangeCountryCode( tHalHandle hHal,
1375 tSmeChangeCountryCallback callback,
1376 tANI_U8 *pCountry,
1377 void *pContext,
1378 void* pVosContext );
1379
1380
1381/* ---------------------------------------------------------------------------
1382 \fn sme_BtcSignalBtEvent
1383 \brief API to signal Bluetooth (BT) event to the WLAN driver. Based on the
1384 BT event type and the current operating mode of Libra (full power,
1385 BMPS, UAPSD etc), appropriate Bluetooth Coexistence (BTC) strategy
1386 would be employed.
1387 \param hHal - The handle returned by macOpen.
1388 \param pBtcBtEvent - Pointer to a caller allocated object of type tSmeBtEvent
1389 Caller owns the memory and is responsible for freeing it.
1390 \return VOS_STATUS
1391 VOS_STATUS_E_FAILURE BT Event not passed to HAL. This can happen
1392 if driver has not yet been initialized or if BTC
1393 Events Layer has been disabled.
1394 VOS_STATUS_SUCCESS BT Event passed to HAL
1395 ---------------------------------------------------------------------------*/
1396VOS_STATUS sme_BtcSignalBtEvent (tHalHandle hHal, tpSmeBtEvent pBtcBtEvent);
1397
1398/* ---------------------------------------------------------------------------
1399 \fn sme_BtcSetConfig
1400 \brief API to change the current Bluetooth Coexistence (BTC) configuration
1401 This function should be invoked only after CFG download has completed.
1402 Calling it after sme_HDDReadyInd is recommended.
1403 \param hHal - The handle returned by macOpen.
1404 \param pSmeBtcConfig - Pointer to a caller allocated object of type
1405 tSmeBtcConfig. Caller owns the memory and is responsible
1406 for freeing it.
1407 \return VOS_STATUS
1408 VOS_STATUS_E_FAILURE Config not passed to HAL.
1409 VOS_STATUS_SUCCESS Config passed to HAL
1410 ---------------------------------------------------------------------------*/
1411VOS_STATUS sme_BtcSetConfig (tHalHandle hHal, tpSmeBtcConfig pSmeBtcConfig);
1412
1413/* ---------------------------------------------------------------------------
1414 \fn sme_BtcGetConfig
1415 \brief API to retrieve the current Bluetooth Coexistence (BTC) configuration
1416 \param hHal - The handle returned by macOpen.
1417 \param pSmeBtcConfig - Pointer to a caller allocated object of type tSmeBtcConfig.
1418 Caller owns the memory and is responsible for freeing it.
1419 \return VOS_STATUS
1420 VOS_STATUS_E_FAILURE - failure
1421 VOS_STATUS_SUCCESS success
1422 ---------------------------------------------------------------------------*/
1423VOS_STATUS sme_BtcGetConfig (tHalHandle hHal, tpSmeBtcConfig pSmeBtcConfig);
1424
1425/* ---------------------------------------------------------------------------
1426 \fn sme_SetCfgPrivacy
1427 \brief API to set configure privacy parameters
1428 \param hHal - The handle returned by macOpen.
1429 \param pProfile - Pointer CSR Roam profile.
1430 \param fPrivacy - This parameter indicates status of privacy
1431
1432 \return void
1433 ---------------------------------------------------------------------------*/
1434void sme_SetCfgPrivacy(tHalHandle hHal, tCsrRoamProfile *pProfile, tANI_BOOLEAN fPrivacy);
1435
1436#if defined WLAN_FEATURE_VOWIFI
1437/* ---------------------------------------------------------------------------
1438 \fn sme_NeighborReportRequest
1439 \brief API to request neighbor report.
1440 \param hHal - The handle returned by macOpen.
1441 \param pRrmNeighborReq - Pointer to a caller allocated object of type
1442 tRrmNeighborReq. Caller owns the memory and is responsible
1443 for freeing it.
1444 \return VOS_STATUS
1445 VOS_STATUS_E_FAILURE - failure
1446 VOS_STATUS_SUCCESS success
1447 ---------------------------------------------------------------------------*/
1448VOS_STATUS sme_NeighborReportRequest (tHalHandle hHal, tANI_U8 sessionId,
1449 tpRrmNeighborReq pRrmNeighborReq, tpRrmNeighborRspCallbackInfo callbackInfo);
1450#endif
1451
1452//The following are debug APIs to support direct read/write register/memory
1453//They are placed in SME because HW cannot be access when in LOW_POWER state
1454//AND not connected. The knowledge and synchronization is done in SME
1455
1456//sme_DbgReadRegister
1457//Caller needs to validate the input values
1458VOS_STATUS sme_DbgReadRegister(tHalHandle hHal, v_U32_t regAddr, v_U32_t *pRegValue);
1459
1460//sme_DbgWriteRegister
1461//Caller needs to validate the input values
1462VOS_STATUS sme_DbgWriteRegister(tHalHandle hHal, v_U32_t regAddr, v_U32_t regValue);
1463
1464//sme_DbgReadMemory
1465//Caller needs to validate the input values
1466//pBuf caller allocated buffer has the length of nLen
1467VOS_STATUS sme_DbgReadMemory(tHalHandle hHal, v_U32_t memAddr, v_U8_t *pBuf, v_U32_t nLen);
1468
1469//sme_DbgWriteMemory
1470//Caller needs to validate the input values
1471VOS_STATUS sme_DbgWriteMemory(tHalHandle hHal, v_U32_t memAddr, v_U8_t *pBuf, v_U32_t nLen);
1472
1473#ifdef FEATURE_WLAN_NON_INTEGRATED_SOC
1474//sme_GetFwVersion
1475VOS_STATUS sme_GetFwVersion (tHalHandle hHal,FwVersionInfo *pVersion);
1476#endif
1477#ifdef FEATURE_WLAN_INTEGRATED_SOC
1478VOS_STATUS sme_GetWcnssWlanCompiledVersion(tHalHandle hHal,
1479 tSirVersionType *pVersion);
1480VOS_STATUS sme_GetWcnssWlanReportedVersion(tHalHandle hHal,
1481 tSirVersionType *pVersion);
1482VOS_STATUS sme_GetWcnssSoftwareVersion(tHalHandle hHal,
1483 tANI_U8 *pVersion,
1484 tANI_U32 versionBufferSize);
1485VOS_STATUS sme_GetWcnssHardwareVersion(tHalHandle hHal,
1486 tANI_U8 *pVersion,
1487 tANI_U32 versionBufferSize);
1488#endif
1489eHalStatus sme_RoamRegisterCallback(tHalHandle hHal,
1490 csrRoamCompleteCallback callback,
1491 void *pContext);
1492
1493#ifdef FEATURE_WLAN_WAPI
1494/* ---------------------------------------------------------------------------
1495 \fn sme_RoamSetBKIDCache
1496 \brief The SME API exposed to HDD to allow HDD to provde SME the BKID
1497 candidate list.
1498 \param hHal - Handle to the HAL. The HAL handle is returned by the HAL after
1499 it is opened (by calling halOpen).
1500 \param pBKIDCache - caller allocated buffer point to an array of tBkidCacheInfo
1501 \param numItems - a variable that has the number of tBkidCacheInfo allocated
1502 when retruning, this is the number of items put into pBKIDCache
1503 \return eHalStatus - when fail, it usually means the buffer allocated is not
1504 big enough and pNumItems has the number of tBkidCacheInfo.
1505 ---------------------------------------------------------------------------*/
1506eHalStatus sme_RoamSetBKIDCache( tHalHandle hHal, tANI_U32 sessionId, tBkidCacheInfo *pBKIDCache,
1507 tANI_U32 numItems );
1508
1509/* ---------------------------------------------------------------------------
1510 \fn sme_RoamGetBKIDCache
1511 \brief The SME API exposed to HDD to allow HDD to request SME to return its
1512 BKID cache.
1513 \param hHal - Handle to the HAL. The HAL handle is returned by the HAL after
1514 it is opened (by calling halOpen).
1515 \param pNum - caller allocated memory that has the space of the number of
1516 tBkidCacheInfo as input. Upon returned, *pNum has the needed number of entries
1517 in SME cache.
1518 \param pBkidCache - Caller allocated memory that contains BKID cache, if any,
1519 upon return
1520 \return eHalStatus - when fail, it usually means the buffer allocated is not
1521 big enough.
1522 ---------------------------------------------------------------------------*/
1523eHalStatus sme_RoamGetBKIDCache(tHalHandle hHal, tANI_U32 *pNum,
1524 tBkidCacheInfo *pBkidCache);
1525
1526/* ---------------------------------------------------------------------------
1527 \fn sme_RoamGetNumBKIDCache
1528 \brief The SME API exposed to HDD to allow HDD to request SME to return the
1529 number of BKID cache entries.
1530 \param hHal - Handle to the HAL. The HAL handle is returned by the HAL after
1531 it is opened (by calling halOpen).
1532 \return tANI_U32 - the number of BKID cache entries.
1533 ---------------------------------------------------------------------------*/
1534tANI_U32 sme_RoamGetNumBKIDCache(tHalHandle hHal, tANI_U32 sessionId);
1535
1536/* ---------------------------------------------------------------------------
1537 \fn sme_ScanGetBKIDCandidateList
1538 \brief a wrapper function to return the BKID candidate list
1539 \param pBkidList - caller allocated buffer point to an array of
1540 tBkidCandidateInfo
1541 \param pNumItems - pointer to a variable that has the number of
1542 tBkidCandidateInfo allocated when retruning, this is
1543 either the number needed or number of items put into
1544 pPmkidList
1545 \return eHalStatus - when fail, it usually means the buffer allocated is not
1546 big enough and pNumItems
1547 has the number of tBkidCandidateInfo.
1548 \Note: pNumItems is a number of tBkidCandidateInfo,
1549 not sizeof(tBkidCandidateInfo) * something
1550 ---------------------------------------------------------------------------*/
1551eHalStatus sme_ScanGetBKIDCandidateList(tHalHandle hHal, tANI_U32 sessionId,
1552 tBkidCandidateInfo *pBkidList,
1553 tANI_U32 *pNumItems );
1554#endif /* FEATURE_WLAN_WAPI */
1555
Jeff Johnsone7245742012-09-05 17:12:55 -07001556#ifdef FEATURE_OEM_DATA_SUPPORT
1557/********************************************************************************************
1558 Oem data related modifications
1559*********************************************************************************************/
1560/* ---------------------------------------------------------------------------
1561 \fn sme_OemDataReq
1562 \param sessionId - session id of session to be used for oem data req.
1563 \param pOemDataReqID - pointer to an object to get back the request ID
1564 \param callback - a callback function that is called upon finish
1565 \param pContext - a pointer passed in for the callback
1566 \return eHalStatus
1567 ---------------------------------------------------------------------------*/
1568eHalStatus sme_OemDataReq(tHalHandle hHal,
1569 tANI_U8 sessionId,
1570 tOemDataReqConfig *,
1571 tANI_U32 *pOemDataReqID,
1572 oemData_OemDataReqCompleteCallback callback,
1573 void *pContext);
1574
1575/* ---------------------------------------------------------------------------
1576 \fn sme_getOemDataRsp
1577 \param pOemDataRsp - A pointer to the response object
1578 \param pOemDataReqID - pointer to an object to get back the request ID
1579 \return eHalStatus
1580 ---------------------------------------------------------------------------*/
1581eHalStatus sme_getOemDataRsp(tHalHandle hHal,
1582 tOemDataRsp **pOemDataRsp);
1583
1584#endif /*FEATURE_OEM_DATA_SUPPORT*/
Jeff Johnson295189b2012-06-20 16:38:30 -07001585
1586
1587#ifdef WLAN_SOFTAP_FEATURE
1588
1589/* ---------------------------------------------------------------------------
1590
1591 \fn sme_RoamUpdateAPWPSIE
1592
1593 \brief To update AP's WPS IE. This function should be called after SME AP session is created
1594 This is an asynchronous API.
1595
1596 \param pAPWPSIES - pointer to a caller allocated object of tCsrRoamAPWPSIES
1597
1598 \return eHalStatus – SUCCESS – Roam callback will be called indicate actually results
1599
1600 FAILURE or RESOURCES – The API finished and failed.
1601
1602 -------------------------------------------------------------------------------*/
1603
1604eHalStatus sme_RoamUpdateAPWPSIE(tHalHandle, tANI_U8 sessionId, tSirAPWPSIEs *pAPWPSIES);
1605/* ---------------------------------------------------------------------------
1606
1607 \fn sme_RoamUpdateAPWPARSNIEs
1608
1609 \brief To update AP's WPA/RSN IEs. This function should be called after SME AP session is created
1610 This is an asynchronous API.
1611
1612 \param pAPSirRSNie - pointer to a caller allocated object of tSirRSNie with WPS/RSN IEs
1613
1614 \return eHalStatus – SUCCESS –
1615
1616 FAILURE or RESOURCES – The API finished and failed.
1617
1618 -------------------------------------------------------------------------------*/
1619eHalStatus sme_RoamUpdateAPWPARSNIEs(tHalHandle hHal, tANI_U8 sessionId, tSirRSNie * pAPSirRSNie);
1620
1621#endif
1622
1623/* ---------------------------------------------------------------------------
1624 \fn sme_sendBTAmpEvent
1625 \brief API to send the btAMPstate to FW
1626 \param hHal - The handle returned by macOpen.
1627 \param btAmpEvent -- btAMP event
1628 \return eHalStatus – SUCCESS –
1629
1630 FAILURE or RESOURCES – The API finished and failed.
1631
1632--------------------------------------------------------------------------- */
1633
1634eHalStatus sme_sendBTAmpEvent(tHalHandle hHal, tSmeBtAmpEvent btAmpEvent);
1635
1636
1637
1638/* ---------------------------------------------------------------------------
1639 \fn sme_SetHostOffload
1640 \brief API to set the host offload feature.
1641 \param hHal - The handle returned by macOpen.
1642 \param pRequest - Pointer to the offload request.
1643 \return eHalStatus
1644 ---------------------------------------------------------------------------*/
Jeff Johnsone7245742012-09-05 17:12:55 -07001645eHalStatus sme_SetHostOffload (tHalHandle hHal, tANI_U8 sessionId,
1646 tpSirHostOffloadReq pRequest);
Jeff Johnson295189b2012-06-20 16:38:30 -07001647
1648/* ---------------------------------------------------------------------------
1649 \fn sme_SetKeepAlive
1650 \brief API to set the Keep Alive feature.
1651 \param hHal - The handle returned by macOpen.
1652 \param pRequest - Pointer to the Keep Alive request.
1653 \return eHalStatus
1654 ---------------------------------------------------------------------------*/
Jeff Johnsone7245742012-09-05 17:12:55 -07001655eHalStatus sme_SetKeepAlive (tHalHandle hHal, tANI_U8 sessionId,
1656 tpSirKeepAliveReq pRequest);
Jeff Johnson295189b2012-06-20 16:38:30 -07001657
1658
1659/* ---------------------------------------------------------------------------
1660 \fn sme_AbortMacScan
1661 \brief API to cancel MAC scan.
1662 \param hHal - The handle returned by macOpen.
1663 \return VOS_STATUS
1664 VOS_STATUS_E_FAILURE - failure
1665 VOS_STATUS_SUCCESS success
1666 ---------------------------------------------------------------------------*/
1667eHalStatus sme_AbortMacScan(tHalHandle hHal);
1668
1669/* ----------------------------------------------------------------------------
1670 \fn sme_GetOperationChannel
1671 \brief API to get current channel on which STA is parked
1672 this function gives channel information only of infra station or IBSS station.
Jeff Johnson04dd8a82012-06-29 20:41:40 -07001673 \param hHal, pointer to memory location and sessionId
Jeff Johnson295189b2012-06-20 16:38:30 -07001674 \returns eHAL_STATUS_SUCCESS
1675 eHAL_STATUS_FAILURE
1676-------------------------------------------------------------------------------*/
Jeff Johnson04dd8a82012-06-29 20:41:40 -07001677eHalStatus sme_GetOperationChannel(tHalHandle hHal, tANI_U32 *pChannel, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001678
1679#ifdef WLAN_FEATURE_P2P
1680/* ---------------------------------------------------------------------------
1681
1682 \fn sme_RegisterMgtFrame
1683
1684 \brief To register managment frame of specified type and subtype.
1685 \param frameType - type of the frame that needs to be passed to HDD.
1686 \param matchData - data which needs to be matched before passing frame
1687 to HDD.
1688 \param matchDataLen - Length of matched data.
1689 \return eHalStatus
1690 -------------------------------------------------------------------------------*/
1691eHalStatus sme_RegisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
1692 tANI_U16 frameType, tANI_U8* matchData, tANI_U16 matchLen);
1693
1694/* ---------------------------------------------------------------------------
1695
1696 \fn sme_DeregisterMgtFrame
1697
1698 \brief To De-register managment frame of specified type and subtype.
1699 \param frameType - type of the frame that needs to be passed to HDD.
1700 \param matchData - data which needs to be matched before passing frame
1701 to HDD.
1702 \param matchDataLen - Length of matched data.
1703 \return eHalStatus
1704 -------------------------------------------------------------------------------*/
1705eHalStatus sme_DeregisterMgmtFrame(tHalHandle hHal, tANI_U8 sessionId,
1706 tANI_U16 frameType, tANI_U8* matchData, tANI_U16 matchLen);
1707#endif
1708
1709/* ---------------------------------------------------------------------------
1710
1711 \fn sme_ConfigureRxpFilter
1712
1713 \brief
1714 SME will pass this request to lower mac to set/reset the filter on RXP for
1715 multicast & broadcast traffic.
1716
1717 \param
1718
1719 hHal - The handle returned by macOpen.
1720
1721 filterMask- Currently the API takes a 1 or 0 (set or reset) as filter.
1722 Basically to enable/disable the filter (to filter "all" mcbc traffic) based
1723 on this param. In future we can use this as a mask to set various types of
1724 filters as suggested below:
1725 FILTER_ALL_MULTICAST:
1726 FILTER_ALL_BROADCAST:
1727 FILTER_ALL_MULTICAST_BROADCAST:
1728
1729
1730 \return eHalStatus
1731
1732
1733--------------------------------------------------------------------------- */
1734eHalStatus sme_ConfigureRxpFilter( tHalHandle hHal,
1735 tpSirWlanSetRxpFilters wlanRxpFilterParam);
1736
1737/* ---------------------------------------------------------------------------
1738
1739 \fn sme_ConfigureAppsCpuWakeupState
1740
1741 \brief
1742 SME will pass this request to lower mac to dynamically adjusts the listen
1743 interval based on the WLAN/MSM activity. This feature is named as
1744 Telescopic Beacon wakeup feature.
1745
1746 \param
1747
1748 hHal - The handle returned by macOpen.
1749
1750 isAppsAwake- Depicts the state of the Apps CPU
1751
1752
1753 \return eHalStatus
1754
1755
1756--------------------------------------------------------------------------- */
1757eHalStatus sme_ConfigureAppsCpuWakeupState( tHalHandle hHal, tANI_BOOLEAN isAppsAwake);
1758
1759#ifdef FEATURE_WLAN_INTEGRATED_SOC
1760/* ---------------------------------------------------------------------------
1761
1762 \fn sme_ConfigureSuspendInd
1763
1764 \brief
1765 SME will pass this request to lower mac to Indicate that the wlan needs to
1766 be suspended
1767
1768 \param
1769
1770 hHal - The handle returned by macOpen.
1771
1772 wlanSuspendParam- Depicts the wlan suspend params
1773
1774
1775 \return eHalStatus
1776
1777
1778--------------------------------------------------------------------------- */
1779eHalStatus sme_ConfigureSuspendInd( tHalHandle hHal,
1780 tpSirWlanSuspendParam wlanSuspendParam);
1781
1782/* ---------------------------------------------------------------------------
1783
1784 \fn sme_ConfigureResumeReq
1785
1786 \brief
1787 SME will pass this request to lower mac to Indicate that the wlan needs to
1788 be Resumed
1789
1790 \param
1791
1792 hHal - The handle returned by macOpen.
1793
1794 wlanResumeParam- Depicts the wlan resume params
1795
1796
1797 \return eHalStatus
1798
1799
1800--------------------------------------------------------------------------- */
1801eHalStatus sme_ConfigureResumeReq( tHalHandle hHal,
1802 tpSirWlanResumeParam wlanResumeParam);
1803
1804#endif
1805
1806/* ---------------------------------------------------------------------------
1807
1808 \fn sme_GetInfraSessionId
1809
1810 \brief To get the session ID for infra session, if connected
1811 This is a synchronous API.
1812
1813 \param hHal - The handle returned by macOpen.
1814
1815 \return sessionid, -1 if infra session is not connected
1816
1817 -------------------------------------------------------------------------------*/
1818tANI_S8 sme_GetInfraSessionId(tHalHandle hHal);
1819
1820/* ---------------------------------------------------------------------------
1821
1822 \fn sme_GetInfraOperationChannel
1823
1824 \brief To get the operating channel for infra session, if connected
1825 This is a synchronous API.
1826
1827 \param hHal - The handle returned by macOpen.
1828 \param sessionId - the sessionId returned by sme_OpenSession.
1829
1830 \return operating channel, 0 if infra session is not connected
1831
1832 -------------------------------------------------------------------------------*/
1833tANI_U8 sme_GetInfraOperationChannel( tHalHandle hHal, tANI_U8 sessionId);
1834/* ---------------------------------------------------------------------------
1835
1836 \fn sme_GetConcurrentOperationChannel
1837
1838 \brief To get the operating channel for other concurrent sessions, if connected
1839 This is a synchronous API.
1840
1841 \param hHal - The handle returned by macOpen.
1842 \param currentPersona - persona that is trying to come up.
1843
1844 \return operating channel, 0 if infra session is not connected
1845
1846 -------------------------------------------------------------------------------*/
1847tANI_U8 sme_GetConcurrentOperationChannel( tHalHandle hHal );
1848
1849/* ---------------------------------------------------------------------------
1850 \fn sme_AbortMacScan
1851 \brief API to cancel MAC scan.
1852 \param hHal - The handle returned by macOpen.
1853 \return VOS_STATUS
1854 VOS_STATUS_E_FAILURE - failure
1855 VOS_STATUS_SUCCESS success
1856 ---------------------------------------------------------------------------*/
1857eHalStatus sme_AbortMacScan(tHalHandle hHal);
1858
1859/* ---------------------------------------------------------------------------
1860 \fn sme_GetCfgValidChannels
1861 \brief API to get valid channel list
1862 \param hHal - The handle returned by macOpen.
1863 \param aValidChannels - Pointer to the valid channel list
1864 \param len - valid channel list length
1865 \return eHalStatus
1866 ---------------------------------------------------------------------------*/
1867eHalStatus sme_GetCfgValidChannels(tHalHandle hHal, tANI_U8 *aValidChannels, tANI_U32 *len);
1868
1869#ifdef FEATURE_WLAN_SCAN_PNO
1870
1871/* ---------------------------------------------------------------------------
1872 \fn sme_SetPreferredNetworkList
1873 \brief API to set the Preferred Network List Offload feature.
1874 \param hHal - The handle returned by macOpen.
1875 \param pRequest - Pointer to the offload request.
1876 \return eHalStatus
1877 ---------------------------------------------------------------------------*/
1878eHalStatus sme_SetPreferredNetworkList (tHalHandle hHal, tpSirPNOScanReq pRequest, tANI_U8 sessionId, preferredNetworkFoundIndCallback callbackRoutine, void *callbackContext );
1879
1880/* ---------------------------------------------------------------------------
1881 \fn sme_SetRSSIFilter
1882 \brief API to set RSSI Filter feature.
1883 \param hHal - The handle returned by macOpen.
1884 \param pRequest - Pointer to the offload request.
1885 \return eHalStatus
1886 ---------------------------------------------------------------------------*/
1887eHalStatus sme_SetRSSIFilter(tHalHandle hHal, v_U8_t rssiThreshold);
1888
1889/******************************************************************************
1890*
1891* Name: sme_PreferredNetworkFoundInd
1892*
1893* Description:
1894* Invoke Preferred Network Found Indication
1895*
1896* Parameters:
1897* hHal - HAL handle for device
1898* pMsg - found network description
1899*
1900* Returns: eHalStatus
1901*
1902******************************************************************************/
1903eHalStatus sme_PreferredNetworkFoundInd (tHalHandle hHal, void* pMsg);
1904#endif // FEATURE_WLAN_SCAN_PNO
1905
1906/* ---------------------------------------------------------------------------
1907 \fn sme_SetPowerParams
1908 \brief API to set Power Parameters
1909 \param hHal - The handle returned by macOpen.
1910 \param pwParams - Pointer to the power parameters requested.
1911 \return eHalStatus
1912 ---------------------------------------------------------------------------*/
1913eHalStatus sme_SetPowerParams(tHalHandle hHal, tSirSetPowerParamsReq* pwParams);
1914
1915/* ---------------------------------------------------------------------------
1916 \fn sme_SetTxPerTracking
1917 \brief Set Tx PER tracking configuration parameters
1918 \param hHal - The handle returned by macOpen.
1919 \param pTxPerTrackingParam - Tx PER configuration parameters
1920 \return eHalStatus
1921 ---------------------------------------------------------------------------*/
1922eHalStatus sme_SetTxPerTracking (
1923 tHalHandle hHal,
1924 void (*pCallbackfn) (void *pCallbackContext),
1925 void *pCallbackContext,
1926 tpSirTxPerTrackingParam pTxPerTrackingParam);
1927
1928#ifdef WLAN_FEATURE_PACKET_FILTERING
1929/* ---------------------------------------------------------------------------
1930 \fn sme_ReceiveFilterSetFilter
1931 \brief API to set 8023 Multicast Address List
1932 \param hHal - The handle returned by macOpen.
1933 \param pMulticastAddrs - Pointer to the Multicast Address List
1934 \return eHalStatus
1935 ---------------------------------------------------------------------------*/
1936eHalStatus sme_8023MulticastList(tHalHandle hHal, tpSirRcvFltMcAddrList pMulticastAddrs);
1937
1938/* ---------------------------------------------------------------------------
1939 \fn sme_ReceiveFilterSetFilter
1940 \brief API to set Receive Packet Filter
1941 \param hHal - The handle returned by macOpen.
1942 \param pRcvPktFilterCfg - Receive Packet Filter parameter
1943 \return eHalStatus
1944 ---------------------------------------------------------------------------*/
Jeff Johnsone7245742012-09-05 17:12:55 -07001945eHalStatus sme_ReceiveFilterSetFilter(tHalHandle hHal, tpSirRcvPktFilterCfgType pRcvPktFilterCfg,
1946 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001947
1948/* ---------------------------------------------------------------------------
1949 \fn sme_GetFilterMatchCount
1950 \brief API to get D0 PC Filter Match Count
1951 \param hHal - The handle returned by macOpen
1952 \param callbackRoutine - Callback routine invoked to receive Packet Coalescing Filter Match Count
1953 \param callbackContext - Cookie to be passed back during callback
1954 \return eHalStatus
1955 ---------------------------------------------------------------------------*/
1956eHalStatus sme_GetFilterMatchCount(tHalHandle hHal,
1957 FilterMatchCountCallback callbackRoutine,
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07001958 void *callbackContext,
1959 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001960
1961/* ---------------------------------------------------------------------------
1962 \fn sme_ReceiveFilterClearFilter
1963 \brief API to clear Receive Packet Filter
1964 \param hHal - The handle returned by macOpen.
1965 \param pRcvFltPktClearParam - Receive Packet Filter Clear parameter
1966 \return eHalStatus
1967 ---------------------------------------------------------------------------*/
1968eHalStatus sme_ReceiveFilterClearFilter(tHalHandle hHal,
Jeff Johnsone7245742012-09-05 17:12:55 -07001969 tpSirRcvFltPktClearParam pRcvFltPktClearParam,
1970 tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07001971#endif // WLAN_FEATURE_PACKET_FILTERING
1972/* ---------------------------------------------------------------------------
1973
1974 \fn sme_IsChannelValid
1975 \brief To check if the channel is valid for currently established domain
1976 This is a synchronous API.
1977
1978 \param hHal - The handle returned by macOpen.
1979 \param channel - channel to verify
1980
1981 \return TRUE/FALSE, TRUE if channel is valid
1982
1983 -------------------------------------------------------------------------------*/
1984tANI_BOOLEAN sme_IsChannelValid(tHalHandle hHal, tANI_U8 channel);
1985
1986/* ---------------------------------------------------------------------------
1987 \fn sme_SetFreqBand
1988 \brief Used to set frequency band.
1989 \param hHal
1990 \eBand band value to be configured
1991 \- return eHalStatus
1992 -------------------------------------------------------------------------*/
1993eHalStatus sme_SetFreqBand(tHalHandle hHal, eCsrBand eBand);
1994
1995/* ---------------------------------------------------------------------------
1996 \fn sme_GetFreqBand
1997 \brief Used to get the current band settings.
1998 \param hHal
1999 \pBand pointer to hold the current band value
2000 \- return eHalStatus
2001 -------------------------------------------------------------------------*/
2002eHalStatus sme_GetFreqBand(tHalHandle hHal, eCsrBand *pBand);
2003
2004/* ---------------------------------------------------------------------------
2005
2006 \fn sme_SetTxPerTracking
2007 \brief Set Tx PER tracking configuration parameters
2008 \param hHal - The handle returned by macOpen.
2009 \param pTxPerTrackingParam - Tx PER configuration parameters
2010 \return eHalStatus
2011 ---------------------------------------------------------------------------*/
2012eHalStatus sme_SetTxPerTracking (
2013 tHalHandle hHal,
2014 void (*pCallbackfn) (void *pCallbackContext),
2015 void *pCallbackContext,
2016 tpSirTxPerTrackingParam pTxPerTrackingParam);
2017
2018#ifdef WLAN_FEATURE_GTK_OFFLOAD
2019/* ---------------------------------------------------------------------------
2020 \fn sme_SetGTKOffload
2021 \brief API to set GTK offload feature.
2022 \param hHal - The handle returned by macOpen.
2023 \param pRequest - Pointer to the GTK offload request.
2024 \return eHalStatus
2025 ---------------------------------------------------------------------------*/
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07002026eHalStatus sme_SetGTKOffload (tHalHandle hHal, tpSirGtkOffloadParams pRequest, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002027
2028/* ---------------------------------------------------------------------------
2029 \fn sme_GetGTKOffload
2030 \brief API to get GTK offload information.
2031 \param hHal - The handle returned by macOpen.
2032 \param pRequest - Pointer to the GTK offload response.
2033 \return eHalStatus
2034 ---------------------------------------------------------------------------*/
Madan Mohan Koyyalamudi96dd30d2012-10-05 17:24:51 -07002035eHalStatus sme_GetGTKOffload (tHalHandle hHal, GTKOffloadGetInfoCallback callbackRoutine,
2036 void *callbackContext, tANI_U8 sessionId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002037#endif // WLAN_FEATURE_GTK_OFFLOAD
2038
2039#ifdef WLAN_WAKEUP_EVENTS
2040eHalStatus sme_WakeReasonIndCallback (tHalHandle hHal, void* pMsg);
2041#endif // WLAN_WAKEUP_EVENTS
2042
2043/* ---------------------------------------------------------------------------
2044 \fn sme_SetTxPerTracking
2045 \brief Set Tx PER tracking configuration parameters
2046 \param hHal - The handle returned by macOpen.
2047 \param pTxPerTrackingParam - Tx PER configuration parameters
2048 \return eHalStatus
2049 ---------------------------------------------------------------------------*/
2050eHalStatus sme_SetTxPerTracking (
2051 tHalHandle hHal,
2052 void (*pCallbackfn) (void *pCallbackContext),
2053 void *pCallbackContext,
2054 tpSirTxPerTrackingParam pTxPerTrackingParam);
2055
2056
2057//return frequency for a particular channel
2058tANI_U16 sme_ChnToFreq(tANI_U8 chanNum);
2059
2060tANI_BOOLEAN sme_IsChannelValid(tHalHandle hHal, tANI_U8 channel);
2061
2062#if defined WLAN_FEATURE_P2P_INTERNAL
2063
2064eHalStatus sme_p2pResetSession(tHalHandle hHal, tANI_U8 HDDSessionId);
2065
2066/* ---------------------------------------------------------------------------
2067 \fn sme_p2pFlushDeviceList
2068 \brief Remove cached P2P result from scan results
2069 \param hHal - The handle returned by macOpen.
2070 \param HDDSessionId - HDD's sessionId. Currently unused.
2071 \return eHalStatus
2072 ---------------------------------------------------------------------------*/
2073eHalStatus sme_p2pFlushDeviceList(tHalHandle hHal, tANI_U8 HDDSessionId);
2074
2075eHalStatus sme_p2pGetResultFilter(tHalHandle hHal, tANI_U8 HDDSessionId,
2076 tCsrScanResultFilter *pFilter);
2077
2078#endif //#if defined WLAN_FEATURE_P2P_INTERNAL
2079
2080/* ---------------------------------------------------------------------------
2081 \fn sme_SetMaxTxPower
2082 \brief Used to set the Maximum Transmit Power dynamically. Note: this
2083 setting will not persist over reboots
2084 \param hHal
2085 \param pBssid BSSID to set the power cap for
2086 \param pBssid pSelfMacAddress self MAC Address
2087 \param pBssid power to set in dB
2088 \- return eHalStatus
2089 -------------------------------------------------------------------------*/
2090eHalStatus sme_SetMaxTxPower(tHalHandle hHal, tSirMacAddr pBssid,
2091 tSirMacAddr pSelfMacAddress, v_S7_t dB);
2092
2093#ifdef WLAN_SOFTAP_FEATURE
2094/* ---------------------------------------------------------------------------
2095
2096 \fn sme_HideSSID
2097
2098 \brief Enable/Disables hidden SSID dynamically. Note: this setting will
2099 not persist over reboots.
2100
2101 \param hHal
2102 \param sessionId
2103 \param ssidHidden 0 - Broadcast SSID, 1 - Disable broadcast SSID
2104 \- return eHalStatus
2105
2106 -------------------------------------------------------------------------------*/
2107eHalStatus sme_HideSSID(tHalHandle hHal, v_U8_t sessionId, v_U8_t ssidHidden);
2108#endif
2109
2110/* ---------------------------------------------------------------------------
2111
2112 \fn sme_SetTmLevel
2113 \brief Set Thermal Mitigation Level to RIVA
2114 \param hHal - The handle returned by macOpen.
2115 \param newTMLevel - new Thermal Mitigation Level
2116 \param tmMode - Thermal Mitigation handle mode, default 0
2117 \return eHalStatus
2118 ---------------------------------------------------------------------------*/
2119eHalStatus sme_SetTmLevel(tHalHandle hHal, v_U16_t newTMLevel, v_U16_t tmMode);
2120
2121/*---------------------------------------------------------------------------
2122
2123 \brief sme_featureCapsExchange() - SME interface to exchange capabilities between
2124 Host and FW.
2125
2126 \param hHal - HAL handle for device
2127
2128 \return NONE
2129
2130---------------------------------------------------------------------------*/
2131void sme_featureCapsExchange(tHalHandle hHal);
2132
Jeff Johnsond13512a2012-07-17 11:42:19 -07002133/*---------------------------------------------------------------------------
2134
2135 \brief sme_GetDefaultCountryCodeFrmNv() - SME interface to get the default
2136 country code
2137 Host and FW.
2138
2139 \param hHal - HAL handle for device
2140 \param pCountry - pointer to country code
2141
2142 \return Sucess or failure
2143
2144 ---------------------------------------------------------------------------*/
2145eHalStatus sme_GetDefaultCountryCodeFrmNv(tHalHandle hHal, tANI_U8 *pCountry);
2146
2147/*---------------------------------------------------------------------------
2148
2149 \brief sme_GetCurrentCountryCode() - SME interface to get the current operating
2150 country code.
2151
2152 \param hHal - HAL handle for device
2153 \param pCountry - pointer to country code
2154
2155 \return Success or failure
2156
2157 ---------------------------------------------------------------------------*/
2158eHalStatus sme_GetCurrentCountryCode(tHalHandle hHal, tANI_U8 *pCountry);
2159
Madan Mohan Koyyalamudi8cb53982012-09-28 14:34:47 -07002160/* ---------------------------------------------------------------------------
2161 \fn sme_transportDebug
2162 \brief Dynamically monitoring Transport channels
2163 Private IOCTL will querry transport channel status if driver loaded
2164 \param displaySnapshot Dispaly transport cahnnel snapshot option
2165 \param toggleStallDetect Enable stall detect feature
2166 This feature will take effect to data performance
2167 Not integrate till fully verification
2168 \- return NONE
2169 -------------------------------------------------------------------------*/
2170void sme_transportDebug
2171(
2172 v_BOOL_t displaySnapshot,
2173 v_BOOL_t toggleStallDetect
2174);
Jeff Johnson295189b2012-06-20 16:38:30 -07002175#endif //#if !defined( __SME_API_H )