blob: a85cbc57e46eba701d19c9e841fb30372882782a [file] [log] [blame]
Jeff Johnson295189b2012-06-20 16:38:30 -07001/*
2 * Copyright (c) 2012, Code Aurora Forum. All rights reserved.
3 *
4 * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
5 *
6 *
7 * Permission to use, copy, modify, and/or distribute this software for
8 * any purpose with or without fee is hereby granted, provided that the
9 * above copyright notice and this permission notice appear in all
10 * copies.
11 *
12 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
13 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
14 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
15 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
16 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
17 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
18 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19 * PERFORMANCE OF THIS SOFTWARE.
20 */
21
22/*
23 * */
24
25#ifndef WLAN_QCT_WLANTL_H
26#define WLAN_QCT_WLANTL_H
27
28/*===========================================================================
29
30 W L A N T R A N S P O R T L A Y E R
31 E X T E R N A L A P I
32
33
34DESCRIPTION
35 This file contains the external API exposed by the wlan transport layer
36 module.
37
38
39 Copyright (c) 2008 QUALCOMM Incorporated. All Rights Reserved.
40 Qualcomm Confidential and Proprietary
41===========================================================================*/
42
43
44/*===========================================================================
45
46 EDIT HISTORY FOR FILE
47
48
49 This section contains comments describing changes made to the module.
50 Notice that changes are listed in reverse chronological order.
51
52
53 $Header:$ $DateTime: $ $Author: $
54
55
56when who what, where, why
57-------- --- ----------------------------------------------------------
5801/08/10 lti Added TL Data Caching
5910/15/09 rnair Modifying STADescType struct
6010/06/09 rnair Adding support for WAPI
6109/22/09 lti Add deregistration API for management client
6202/02/09 sch Add Handoff support
6312/09/08 lti Fixes for AMSS compilation
6409/05/08 lti Fixes after QOS unit testing
6508/06/08 lti Added QOS support
6605/01/08 lti Created module.
67
68===========================================================================*/
69
70
71
72/*===========================================================================
73
74 INCLUDE FILES FOR MODULE
75
76===========================================================================*/
77
78/*----------------------------------------------------------------------------
79 * Include Files
80 * -------------------------------------------------------------------------*/
81#include "vos_api.h"
82#include "vos_packet.h"
83#include "sirApi.h"
84#ifdef WLAN_SOFTAP_FEATURE
85#include "csrApi.h"
86#include "sapApi.h"
87#endif
88
89/*----------------------------------------------------------------------------
90 * Preprocessor Definitions and Constants
91 * -------------------------------------------------------------------------*/
92 #ifdef __cplusplus
93 extern "C" {
94 #endif
95
96/*Offset of the OUI field inside the LLC/SNAP header*/
97#define WLANTL_LLC_OUI_OFFSET 3
98
99/*Size of the OUI type field inside the LLC/SNAP header*/
100#define WLANTL_LLC_OUI_SIZE 3
101
102/*Offset of the LLC/SNAP header*/
103#define WLANTL_LLC_SNAP_OFFSET 0
104
105/*Size of the LLC/SNAP header*/
106#define WLANTL_LLC_SNAP_SIZE 8
107
108/*============================================================================
109 * GENERIC STRUCTURES - not belonging to TL
110 * TO BE MOVED TO A GLOBAL HEADER
111 ============================================================================*/
112/*Maximum number of ACs */
113#define WLANTL_MAX_AC 4
114
115#ifdef WLAN_SOFTAP_FEATURE
116
117/* Bit Mask to represent All Stations */
118#define WLAN_ALL_STA 0xFF
119
120/* Maximum number of station supported by TL, including BC. */
121#define WLAN_MAX_STA_COUNT (HAL_NUM_STA)
122
123/* The symbolic station ID return to HDD to specify the packet is bc/mc */
124#define WLAN_RX_BCMC_STA_ID (WLAN_MAX_STA_COUNT + 1)
125
126/* The symbolic station ID return to HDD to specify the packet is to soft-AP itself */
127#define WLAN_RX_SAP_SELF_STA_ID (WLAN_MAX_STA_COUNT + 2)
128
129/* Used by HDS systme. This station ID is used by TL to tell upper layer that
130 this packet is for WDS and not for a loopback for an associated station. */
131#define WLANTL_RX_WDS_STAID WLAN_MAX_STA_COUNT
132
133/* Station ID used for BC traffic. This value will be used when upper layer registers
134 the broadcast client or allocate station strcuture to keep per-station info.*/
135//#define WLANTL_BC_STA_ID 0x00
136
137#endif
138
139#ifdef ANI_CHIPSET_VOLANS
140#define WLANTL_MAX_TID 15
141#endif
142/*--------------------------------------------------------------------------
143 Access category enum used by TL
144 - order must be kept as these values are used to setup the AC mask
145 --------------------------------------------------------------------------*/
146typedef enum
147{
148 WLANTL_AC_BK = 0,
149 WLANTL_AC_BE = 1,
150 WLANTL_AC_VI = 2,
151 WLANTL_AC_VO = 3
152}WLANTL_ACEnumType;
153
154/*---------------------------------------------------------------------------
155 STA Type
156---------------------------------------------------------------------------*/
157typedef enum
158{
159 /* Indicates a link to an AP*/
160 WLAN_STA_INFRA = 0,
161
162 /* AD-hoc link*/
163 WLAN_STA_IBSS,
164
165 /* BT-AMP link*/
166 WLAN_STA_BT_AMP,
167
168#ifdef WLAN_SOFTAP_FEATURE
169 /* SoftAP station */
170 WLAN_STA_SOFTAP,
171#endif
172
173 /* Invalid link*/
174 WLAN_STA_MAX
175
176}WLAN_STAType;
177
178/*---------------------------------------------------------------------------
179 BAP Management frame type
180---------------------------------------------------------------------------*/
181typedef enum
182{
183 /* BT-AMP packet of type data */
184 WLANTL_BT_AMP_TYPE_DATA = 0x0001,
185
186 /* BT-AMP packet of type activity report */
187 WLANTL_BT_AMP_TYPE_AR = 0x0002,
188
189 /* BT-AMP packet of type security frame */
190 WLANTL_BT_AMP_TYPE_SEC = 0x0003,
191
192 /* BT-AMP packet of type Link Supervision request frame */
193 WLANTL_BT_AMP_TYPE_LS_REQ = 0x0004,
194
195 /* BT-AMP packet of type Link Supervision reply frame */
196 WLANTL_BT_AMP_TYPE_LS_REP = 0x0005,
197
198 /* Invalid Frame */
199 WLANTL_BAP_INVALID_FRAME
200
201} WLANTL_BAPFrameEnumType;
202
203#ifdef WLAN_SOFTAP_FEATURE
204/* Type used to specify LWM threshold unit */
205typedef enum {
206 WLAN_LWM_THRESHOLD_BYTE = 0,
207
208 WLAN_LWM_THRESHOLD_PACKET
209} WLAN_LWM_Threshold_Type;
210#endif
211
212/*---------------------------------------------------------------------------
213 TL States
214---------------------------------------------------------------------------*/
215typedef enum
216{
217 /* Transition in this state made upon creation*/
218 WLANTL_STA_INIT = 0,
219
220 /* Transition happens after Assoc success if second level authentication
221 is needed*/
222 WLANTL_STA_CONNECTED,
223
224 /* Transition happens when second level auth is successful and keys are
225 properly installed */
226 WLANTL_STA_AUTHENTICATED,
227
228 /* Transition happens when connectivity is lost*/
229 WLANTL_STA_DISCONNECTED,
230
231 WLANTL_STA_MAX_STATE
232}WLANTL_STAStateType;
233
234
235/*---------------------------------------------------------------------------
236 STA Descriptor Type
237---------------------------------------------------------------------------*/
238typedef struct
239{
240 /*STA unique identifier, originating from HAL*/
241 v_U8_t ucSTAId;
242
243 /*STA MAC Address*/
244 v_MACADDR_t vSTAMACAddress;
245
246 /*BSSID for IBSS*/
247 v_MACADDR_t vBSSIDforIBSS;
248
249 /*Self MAC Address*/
250 v_MACADDR_t vSelfMACAddress;
251
252 /*Type of the STA*/
253 WLAN_STAType wSTAType;
254
255 /*flag for setting the state of the QOS for the link*/
256 v_U8_t ucQosEnabled;
257
258 /*enable FT in TL */
259 v_U8_t ucSwFrameTXXlation;
260 v_U8_t ucSwFrameRXXlation;
261
262 /*Flag for signaling TL if LLC header needs to be added for outgoing
263 packets*/
264 v_U8_t ucAddRmvLLC;
265
266 /*Flag for signaling if the privacy bit needs to be set*/
267 v_U8_t ucProtectedFrame;
268
269 /*DPU Signature used for unicast data - used for data caching*/
270 v_U8_t ucUcastSig;
271 /*Flag to indicate if STA is a WAPI STA*/
272 v_U8_t ucIsWapiSta;
273
274#ifdef FEATURE_WLAN_CCX
275 /*Flag to indicate if STA is a CCX STA*/
276 v_U8_t ucIsCcxSta;
277#endif
278
279 /*DPU Signature used for broadcast data - used for data caching*/
280 v_U8_t ucBcastSig;
281
282 /*Initial state at which the STA should be brought up to*/
283 WLANTL_STAStateType ucInitState;
284#ifdef ANI_CHIPSET_VOLANS
285 /* 1 means replay check is needed for the station,
286 0 means replay check is not needed for the station*/
287 v_BOOL_t ucIsReplayCheckValid;
288#endif
289}WLAN_STADescType;
290
291/*---------------------------------------------------------------------------
292 TL Configuration
293---------------------------------------------------------------------------*/
294typedef struct
295{
296 /*AC weight for WFQ*/
297 v_U8_t ucAcWeights[WLANTL_MAX_AC];
298
299 /*Delayed trigger frame timmer: - used by TL to send trigger frames less
300 often when it has established that the App is suspended*/
301 v_U32_t uDelayedTriggerFrmInt;
302
303#ifdef WLAN_SOFTAP_FEATURE
304 /* Min Threshold for Processing Frames in TL */
305 v_U8_t uMinFramesProcThres;
306#endif
307}WLANTL_ConfigInfoType;
308
309/*---------------------------------------------------------------------------
310 TSPEC Direction Enum Type
311---------------------------------------------------------------------------*/
312typedef enum
313{
314 /* uplink */
315 WLANTL_TX_DIR = 0,
316
317 /* downlink */
318 WLANTL_RX_DIR = 1,
319
320 /*bidirectional*/
321 WLANTL_BI_DIR = 2,
322}WLANTL_TSDirType;
323
324/*============================================================================
325 * GENERIC STRUCTURES - END
326 ============================================================================*/
327
328
329
330/*----------------------------------------------------------------------------
331 * Type Declarations
332 * -------------------------------------------------------------------------*/
333
334/*---------------------------------------------------------------------------
335 TL Error Type
336---------------------------------------------------------------------------*/
337typedef enum
338{
339 /* Generic error */
340 WLANTL_ERROR = 0,
341
342 /* No rx callback registered for data path */
343 WLANTL_NO_RX_DATA_CB,
344
345 /* No rx callback registered for management path*/
346 WLANTL_NO_RX_MGMT_CB,
347
348 /* Generic memory error*/
349 WLANTL_MEM_ERROR,
350
351 /* Bus error notified by BAL */
352 WLANTL_BUS_ERROR
353
354}WLANTL_ErrorType;
355
356/*---------------------------------------------------------------------------
357 STA priority type
358---------------------------------------------------------------------------*/
359typedef enum
360{
361 /* STA gets to tx every second round*/
362 WLANTL_STA_PRI_VERY_LOW = -2,
363
364 /* STA gets to tx every other round*/
365 WLANTL_STA_PRI_LOW = -1,
366
367 /* STA gets to tx each time */
368 WLANTL_STA_PRI_NORMAL = 0,
369
370 /* STA gets to tx twice each time*/
371 WLANTL_STA_PRI_HIGH = 1,
372
373 /* STA gets to tx three times each time*/
374 WLANTL_STA_PRI_VERY_HIGH = 2
375
376}WLANTL_STAPriorityType;
377
378/*---------------------------------------------------------------------------
379 Meta information requested from HDD by TL
380---------------------------------------------------------------------------*/
381typedef struct
382{
383 /* TID of the packet being sent */
384 v_U8_t ucTID;
385
386 /* UP of the packet being sent */
387 v_U8_t ucUP;
388
389 /* notifying TL if this is an EAPOL frame or not */
390 v_U8_t ucIsEapol;
391#ifdef FEATURE_WLAN_WAPI
392 /* notifying TL if this is a WAI frame or not */
393 v_U8_t ucIsWai;
394#endif
395 /* frame is 802.11 and it does not need translation */
396 v_U8_t ucDisableFrmXtl;
397
398 /* frame is broadcast */
399 v_U8_t ucBcast;
400
401 /* frame is multicast */
402 v_U8_t ucMcast;
403
404 /* frame type */
405 v_U8_t ucType;
406
407 /* timestamp */
408 v_U16_t usTimeStamp;
409
410 /* STA has more packets to send */
411 v_BOOL_t bMorePackets;
412}WLANTL_MetaInfoType;
413
414/*---------------------------------------------------------------------------
415 Meta information provided by TL to HDD on rx path
416---------------------------------------------------------------------------*/
417typedef struct
418{
419 /* UP of the packet being sent */
420 v_U8_t ucUP;
421 /* Address 3 Index of the received packet */
422 v_U16_t ucDesSTAId;
423}WLANTL_RxMetaInfoType;
424
425
426/*---------------------------------------------------------------------------
427 Handoff support and statistics defines and enum types
428---------------------------------------------------------------------------*/
429/* Threshold crossed event type definitions */
430#define WLANTL_HO_THRESHOLD_NA 0x00
431#define WLANTL_HO_THRESHOLD_DOWN 0x01
432#define WLANTL_HO_THRESHOLD_UP 0x02
433#define WLANTL_HO_THRESHOLD_CROSS 0x04
434
435/* Realtime traffic status */
436typedef enum
437{
438 WLANTL_HO_RT_TRAFFIC_STATUS_OFF,
439 WLANTL_HO_RT_TRAFFIC_STATUS_ON
440} WLANTL_HO_RT_TRAFFIC_STATUS_TYPE;
441
442/* Non-Realtime traffic status */
443typedef enum
444{
445 WLANTL_HO_NRT_TRAFFIC_STATUS_OFF,
446 WLANTL_HO_NRT_TRAFFIC_STATUS_ON
447} WLANTL_HO_NRT_TRAFFIC_STATUS_TYPE;
448
449/* Statistics type TL supported */
450typedef enum
451{
452 WLANTL_STATIC_TX_UC_FCNT,
453 WLANTL_STATIC_TX_MC_FCNT,
454 WLANTL_STATIC_TX_BC_FCNT,
455 WLANTL_STATIC_TX_UC_BCNT,
456 WLANTL_STATIC_TX_MC_BCNT,
457 WLANTL_STATIC_TX_BC_BCNT,
458 WLANTL_STATIC_RX_UC_FCNT,
459 WLANTL_STATIC_RX_MC_FCNT,
460 WLANTL_STATIC_RX_BC_FCNT,
461 WLANTL_STATIC_RX_UC_BCNT,
462 WLANTL_STATIC_RX_MC_BCNT,
463 WLANTL_STATIC_RX_BC_BCNT,
464 WLANTL_STATIC_RX_BCNT,
465 WLANTL_STATIC_RX_BCNT_CRC_OK,
466 WLANTL_STATIC_RX_RATE
467} WLANTL_TRANSFER_STATIC_TYPE;
468
469/*---------------------------------------------------------------------------
470 Handoff support and statistics structures
471---------------------------------------------------------------------------*/
472typedef struct
473{
474 WLANTL_HO_RT_TRAFFIC_STATUS_TYPE rtTrafficStatus;
475 WLANTL_HO_NRT_TRAFFIC_STATUS_TYPE nrtTrafficStatus;
476} WLANTL_HO_TRAFFIC_STATUS_TYPE;
477
478#ifdef WLAN_SOFTAP_FEATURE
479typedef tSap_SoftapStats WLANTL_TRANSFER_STA_TYPE;
480#else
481typedef struct
482{
483 v_U32_t txUCFcnt;
484 v_U32_t txMCFcnt;
485 v_U32_t txBCFcnt;
486 v_U32_t txUCBcnt;
487 v_U32_t txMCBcnt;
488 v_U32_t txBCBcnt;
489 v_U32_t rxUCFcnt;
490 v_U32_t rxMCFcnt;
491 v_U32_t rxBCFcnt;
492 v_U32_t rxUCBcnt;
493 v_U32_t rxMCBcnt;
494 v_U32_t rxBCBcnt;
495 v_U32_t rxBcnt;
496 v_U32_t rxBcntCRCok;
497 v_U32_t rxRate;
498}WLANTL_TRANSFER_STA_TYPE;
499#endif
500
501/* Under here not public items, just use for internal */
502/* 3 SME 1 HDD */
503#define WLANTL_MAX_AVAIL_THRESHOLD 5
504#define WLANTL_HS_NUM_CLIENT 2
505#define WLANTL_SINGLE_CLNT_THRESHOLD 4
506
507/*----------------------------------------------------------------------------
508 * TL callback types
509 *--------------------------------------------------------------------------*/
510
511/*----------------------------------------------------------------------------
512
513 DESCRIPTION
514 Type of the tx complete callback registered with TL.
515
516 TL will call this to notify the client when a transmission for a
517 packet has ended.
518
519 PARAMETERS
520
521 IN
522 pvosGCtx: pointer to the global vos context; a handle to
523 TL/HAL/PE/BAP/HDD control block can be extracted from
524 its context
525 vosDataBuff: pointer to the VOSS data buffer that was transmitted
526 wTxSTAtus: status of the transmission
527
528
529 RETURN VALUE
530 The result code associated with performing the operation
531
532----------------------------------------------------------------------------*/
533typedef VOS_STATUS (*WLANTL_TxCompCBType)( v_PVOID_t pvosGCtx,
534 vos_pkt_t* pFrameDataBuff,
535 VOS_STATUS wTxSTAtus );
536
537
538/*----------------------------------------------------------------------------
539 INTERACTION WITH HDD
540 ---------------------------------------------------------------------------*/
541/*----------------------------------------------------------------------------
542
543 DESCRIPTION
544 Type of the fetch packet callback registered with TL.
545
546 It is called by the TL when the scheduling algorithms allows for
547 transmission of another packet to the module.
548 It will be called in the context of the BAL fetch transmit packet
549 function, initiated by the bus lower layer.
550
551
552 PARAMETERS
553
554 IN
555 pvosGCtx: pointer to the global vos context; a handle
556 to TL's or HDD's control block can be extracted
557 from its context
558
559 IN/OUT
560 pucSTAId: the Id of the station for which TL is requesting a
561 packet, in case HDD does not maintain per station
562 queues it can give the next packet in its queue
563 and put in the right value for the
564 pucAC: access category requested by TL, if HDD does not have
565 packets on this AC it can choose to service another AC
566 queue in the order of priority
567
568 OUT
569 vosDataBuff: pointer to the VOSS data buffer that was transmitted
570 tlMetaInfo: meta info related to the data frame
571
572
573
574 RETURN VALUE
575 The result code associated with performing the operation
576
577----------------------------------------------------------------------------*/
578typedef VOS_STATUS (*WLANTL_STAFetchPktCBType)(
579 v_PVOID_t pvosGCtx,
580 v_U8_t* pucSTAId,
581 WLANTL_ACEnumType ucAC,
582 vos_pkt_t** vosDataBuff,
583 WLANTL_MetaInfoType* tlMetaInfo);
584
585/*----------------------------------------------------------------------------
586
587 DESCRIPTION
588 Type of the receive callback registered with TL.
589
590 TL will call this to notify the client when a packet was received
591 for a registered STA.
592
593 PARAMETERS
594
595 IN
596 pvosGCtx: pointer to the global vos context; a handle to
597 TL's or HDD's control block can be extracted from
598 its context
599 vosDataBuff: pointer to the VOSS data buffer that was received
600 (it may be a linked list)
601 ucSTAId: station id
602 pRxMetaInfo: meta info for the received packet(s)
603
604 RETURN VALUE
605 The result code associated with performing the operation
606
607----------------------------------------------------------------------------*/
608typedef VOS_STATUS (*WLANTL_STARxCBType)( v_PVOID_t pvosGCtx,
609 vos_pkt_t* vosDataBuff,
610 v_U8_t ucSTAId,
611 WLANTL_RxMetaInfoType* pRxMetaInfo);
612
613
614/*----------------------------------------------------------------------------
615 INTERACTION WITH BAP
616 ---------------------------------------------------------------------------*/
617
618/*----------------------------------------------------------------------------
619
620 DESCRIPTION
621 Type of the receive callback registered with TL for BAP.
622
623 The registered reception callback is being triggered by TL whenever a
624 frame was received and it was filtered as a non-data BT AMP packet.
625
626 PARAMETERS
627
628 IN
629 pvosGCtx: pointer to the global vos context; a handle to TL's
630 or SME's control block can be extracted from its context
631 vosDataBuff: pointer to the vOSS buffer containing the received packet;
632 no chaining will be done on this path
633 frameType: type of the frame to be indicated to BAP.
634
635 RETURN VALUE
636 The result code associated with performing the operation
637
638----------------------------------------------------------------------------*/
639typedef VOS_STATUS (*WLANTL_BAPRxCBType)( v_PVOID_t pvosGCtx,
640 vos_pkt_t* vosDataBuff,
641 WLANTL_BAPFrameEnumType frameType);
642
643/*----------------------------------------------------------------------------
644
645 DESCRIPTION
646 Callback registered with TL for BAP, this is required inorder for
647 TL to inform BAP, that the flush operation requested has been completed.
648
649 The registered reception callback is being triggered by TL whenever a
650 frame SIR_TL_HAL_FLUSH_AC_RSP is received by TL from HAL.
651
652 PARAMETERS
653
654 IN
655 pvosGCtx: pointer to the global vos context; a handle to TL's
656 or SME's control block can be extracted from its context
657 vosDataBuff: pointer to the vOSS buffer containing the received packet;
658 no chaining will be done on this path
659
660 RETURN VALUE
661 The result code associated with performing the operation
662
663----------------------------------------------------------------------------*/
664typedef VOS_STATUS (*WLANTL_FlushOpCompCBType)( v_PVOID_t pvosGCtx,
665 v_U8_t ucStaId,
666 v_U8_t ucTID,
667 v_U8_t status);
668/*----------------------------------------------------------------------------
669 INTERACTION WITH PE
670 ---------------------------------------------------------------------------*/
671
672/*----------------------------------------------------------------------------
673
674 DESCRIPTION
675 Type of the receive callback registered with TL for PE.
676
677 Upon receipt of a management frame TL will call the registered receive
678 callback and forward this frame to the interested module, in our case PE.
679
680 PARAMETERS
681
682 IN
683 pvosGCtx: pointer to the global vos context; a handle to TL's
684 control block can be extracted from its context
685 vosFrmBuf: pointer to a vOSS buffer containing the management frame
686 received
687
688 RETURN VALUE
689 The result code associated with performing the operation
690
691----------------------------------------------------------------------------*/
692typedef VOS_STATUS (*WLANTL_MgmtFrmRxCBType)( v_PVOID_t pvosGCtx,
693 v_PVOID_t vosBuff);
694
695
696/*----------------------------------------------------------------------------
697 INTERACTION WITH HAL
698 ---------------------------------------------------------------------------*/
699
700/*----------------------------------------------------------------------------
701
702 DESCRIPTION
703 Type of the fetch packet callback registered with TL.
704
705 HAL calls this API when it wishes to suspend transmission for a
706 particular STA.
707
708 PARAMETERS
709
710 IN
711 pvosGCtx: pointer to the global vos context; a handle to TL's
712 control block can be extracted from its context
713 ucSTAId: identifier of the station for which the request is made;
714 a value of 0 assumes suspend on all active station
715 pfnSuspendTxCB: pointer to the suspend result notification in case the
716 call is asynchronous
717
718 RETURN VALUE
719 The result code associated with performing the operation
720
721----------------------------------------------------------------------------*/
722typedef VOS_STATUS (*WLANTL_SuspendCBType)( v_PVOID_t pvosGCtx,
723 v_U8_t* ucSTAId,
724 VOS_STATUS vosStatus);
725
726
727/*==========================================================================
728
729 DESCRIPTION
730 Traffic status changed callback function
731 Should be registered to let client know that traffic status is changed
732 REF WLANTL_RegGetTrafficStatus
733
734 PARAMETERS
735 pAdapter Global handle pointer
736 trafficStatus RT and NRT current traffic status
737 pUserCtxt pre registered client context
738
739 RETURN VALUE
740 VOS_STATUS
741
742 SIDE EFFECTS
743 NONE
744
745============================================================================*/
746/* IF traffic status is changed, send notification to SME */
747typedef VOS_STATUS (*WLANTL_TrafficStatusChangedCBType)
748(
749 v_PVOID_t pAdapter,
750 WLANTL_HO_TRAFFIC_STATUS_TYPE trafficStatus,
751 v_PVOID_t pUserCtxt
752);
753
754/*==========================================================================
755
756 DESCRIPTION
757 RSSI threshold crossed notification callback function
758 REF WLANTL_RegRSSIIndicationCB
759
760 PARAMETERS
761 pAdapter Global handle pointer
762 rssiNotification Notification event type
763 pUserCtxt pre registered client context
764
765 RETURN VALUE
766
767 SIDE EFFECTS
768
769============================================================================*/
770/* If RSSI realm is changed, send notification to Clients, SME, HDD */
771typedef VOS_STATUS (*WLANTL_RSSICrossThresholdCBType)
772(
773 v_PVOID_t pAdapter,
774 v_U8_t rssiNotification,
775 v_PVOID_t pUserCtxt
776);
777
Jeff Johnsone7245742012-09-05 17:12:55 -0700778typedef struct
779{
780 // Common for all types are requests
781 v_U16_t msgType; // message type is same as the request type
782 v_U16_t msgLen; // length of the entire request
783 v_U8_t sessionId; //sme Session Id
784 v_U8_t rssiNotification;
785 v_PVOID_t tlCallback;
786 v_PVOID_t pAdapter;
787 v_PVOID_t pUserCtxt;
788} WLANTL_TlIndicationReq;
789
Jeff Johnson295189b2012-06-20 16:38:30 -0700790/*----------------------------------------------------------------------------
791 * Function Declarations and Documentation
792 * -------------------------------------------------------------------------*/
793
794/*==========================================================================
795
796 FUNCTION WLANTL_Open
797
798 DESCRIPTION
799 Called by HDD at driver initialization. TL will initialize all its
800 internal resources and will wait for the call to start to register
801 with the other modules.
802
803 DEPENDENCIES
804
805 PARAMETERS
806
807 IN
808 pvosGCtx: pointer to the global vos context; a handle to TL's
809 control block can be extracted from its context
810 pTLConfig: TL Configuration
811
812 RETURN VALUE
813 The result code associated with performing the operation
814
815 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
816 fault
817 VOS_STATUS_SUCCESS: Everything is good :)
818
819 SIDE EFFECTS
820
821============================================================================*/
822VOS_STATUS
823WLANTL_Open
824(
825 v_PVOID_t pvosGCtx,
826 WLANTL_ConfigInfoType* pTLConfig
827);
828
829/*==========================================================================
830
831 FUNCTION WLANTL_Start
832
833 DESCRIPTION
834 Called by HDD as part of the overall start procedure. TL will use this
835 call to register with BAL as a transport layer entity.
836
837 DEPENDENCIES
838
839 PARAMETERS
840
841 IN
842 pvosGCtx: pointer to the global vos context; a handle to TL's
843 control block can be extracted from its context
844
845 RETURN VALUE
846 The result code associated with performing the operation
847
848 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
849 fault
850 VOS_STATUS_SUCCESS: Everything is good :)
851
852 Other codes can be returned as a result of a BAL failure; see BAL API
853 for more info
854
855 SIDE EFFECTS
856
857============================================================================*/
858VOS_STATUS
859WLANTL_Start
860(
861 v_PVOID_t pvosGCtx
862);
863
864/*==========================================================================
865
866 FUNCTION WLANTL_Stop
867
868 DESCRIPTION
869 Called by HDD to stop operation in TL, before close. TL will suspend all
870 frame transfer operation and will wait for the close request to clean up
871 its resources.
872
873 DEPENDENCIES
874
875 PARAMETERS
876
877 IN
878 pvosGCtx: pointer to the global vos context; a handle to TL's
879 control block can be extracted from its context
880
881 RETURN VALUE
882 The result code associated with performing the operation
883
884 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
885 fault
886 VOS_STATUS_SUCCESS: Everything is good :)
887
888 SIDE EFFECTS
889
890============================================================================*/
891VOS_STATUS
892WLANTL_Stop
893(
894 v_PVOID_t pvosGCtx
895);
896
897/*==========================================================================
898
899 FUNCTION WLANTL_Close
900
901 DESCRIPTION
902 Called by HDD during general driver close procedure. TL will clean up
903 all the internal resources.
904
905 DEPENDENCIES
906
907 PARAMETERS
908
909 IN
910 pvosGCtx: pointer to the global vos context; a handle to TL's
911 control block can be extracted from its context
912
913 RETURN VALUE
914 The result code associated with performing the operation
915
916 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
917 fault
918 VOS_STATUS_SUCCESS: Everything is good :)
919
920 SIDE EFFECTS
921
922============================================================================*/
923VOS_STATUS
924WLANTL_Close
925(
926 v_PVOID_t pvosGCtx
927);
928
929
930/*----------------------------------------------------------------------------
931 INTERACTION WITH HDD
932 ---------------------------------------------------------------------------*/
933/*==========================================================================
934
935 FUNCTION WLANTL_ConfigureSwFrameTXXlationForAll
936
937 DESCRIPTION
938 Function to disable/enable frame translation for all association stations.
939
940 DEPENDENCIES
941
942 PARAMETERS
943 IN
944 pvosGCtx: VOS context
945 EnableFrameXlation TRUE means enable SW translation for all stations.
946 .
947
948 RETURN VALUE
949
950 void.
951
952============================================================================*/
953void
954WLANTL_ConfigureSwFrameTXXlationForAll
955(
956 v_PVOID_t pvosGCtx,
957 v_BOOL_t enableFrameXlation
958);
959
960/*===========================================================================
961
962 FUNCTION WLANTL_RegisterSTAClient
963
964 DESCRIPTION
965
966 This function is used by HDD to register as a client for data services
967 with TL. HDD will call this API for each new station that it adds,
968 thus having the flexibility of registering different callback for each
969 STA it services.
970
971 DEPENDENCIES
972
973 TL must have been initialized before this gets called.
974
975 Restriction:
976 Main thread will have higher priority that Tx and Rx threads thus
977 guaranteeing that a station will be added before any data can be
978 received for it. (This enables TL to be lock free)
979
980 PARAMETERS
981
982 pvosGCtx: pointer to the global vos context; a handle to TL's
983 control block can be extracted from its context
984 pfnStARx: function pointer to the receive packet handler from HDD
985 pfnSTATxComp: function pointer to the transmit complete confirmation
986 handler from HDD
987 pfnSTAFetchPkt: function pointer to the packet retrieval routine in HDD
988 wSTADescType: STA Descriptor, contains information related to the
989 new added STA
990
991 RETURN VALUE
992
993 The result code associated with performing the operation
994
995 VOS_STATUS_E_INVAL: Input parameters are invalid
996 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
997 TL cb is NULL ; access would cause a page fault
998 VOS_STATUS_E_EXISTS: Station was already registered
999 VOS_STATUS_SUCCESS: Everything is good :)
1000
1001 SIDE EFFECTS
1002
1003============================================================================*/
1004VOS_STATUS
1005WLANTL_RegisterSTAClient
1006(
1007 v_PVOID_t pvosGCtx,
1008 WLANTL_STARxCBType pfnSTARx,
1009 WLANTL_TxCompCBType pfnSTATxComp,
1010 WLANTL_STAFetchPktCBType pfnSTAFetchPkt,
1011 WLAN_STADescType* wSTADescType ,
1012 v_S7_t rssi
1013);
1014
1015/*===========================================================================
1016
1017 FUNCTION WLANTL_ClearSTAClient
1018
1019 DESCRIPTION
1020
1021 HDD will call this API when it no longer needs data services for the
1022 particular station.
1023
1024 DEPENDENCIES
1025
1026 A station must have been registered before the clear registration is
1027 called.
1028
1029 PARAMETERS
1030
1031 pvosGCtx: pointer to the global vos context; a handle to TL's
1032 control block can be extracted from its context
1033 ucSTAId: identifier for the STA to be cleared
1034
1035 RETURN VALUE
1036
1037 The result code associated with performing the operation
1038
1039 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1040 TL cb is NULL ; access would cause a page fault
1041 VOS_STATUS_E_EXISTS: Station was not registered
1042 VOS_STATUS_SUCCESS: Everything is good :)
1043
1044 SIDE EFFECTS
1045
1046============================================================================*/
1047VOS_STATUS
1048WLANTL_ClearSTAClient
1049(
1050 v_PVOID_t pvosGCtx,
1051 v_U8_t ucSTAId
1052);
1053
1054/*===========================================================================
1055
1056 FUNCTION WLANTL_ChangeSTAState
1057
1058 DESCRIPTION
1059
1060 HDD will make this notification whenever a change occurs in the
1061 connectivity state of a particular STA.
1062
1063 DEPENDENCIES
1064
1065 A station must have been registered before the change state can be
1066 called.
1067
1068 RESTRICTION: A station is being notified as authenticated before the
1069 keys are installed in HW. This way if a frame is received
1070 before the keys are installed DPU will drop that frame.
1071
1072 Main thread has higher priority that Tx and Rx threads thus guaranteeing
1073 the following:
1074 - a station will be in assoc state in TL before TL receives any data
1075 for it
1076
1077 PARAMETERS
1078
1079 pvosGCtx: pointer to the global vos context; a handle to TL's
1080 control block can be extracted from its context
1081 ucSTAId: identifier for the STA that is pending transmission
1082 tlSTAState: the new state of the connection to the given station
1083
1084
1085 RETURN VALUE
1086
1087 The result code associated with performing the operation
1088
1089 VOS_STATUS_E_INVAL: Input parameters are invalid
1090 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1091 TL cb is NULL ; access would cause a page fault
1092 VOS_STATUS_E_EXISTS: Station was not registered
1093 VOS_STATUS_SUCCESS: Everything is good :)
1094
1095 SIDE EFFECTS
1096
1097============================================================================*/
1098VOS_STATUS
1099WLANTL_ChangeSTAState
1100(
1101 v_PVOID_t pvosGCtx,
1102 v_U8_t ucSTAId,
1103 WLANTL_STAStateType tlSTAState
1104);
1105
1106/*===========================================================================
1107
1108 FUNCTION WLANTL_STAPktPending
1109
1110 DESCRIPTION
1111
1112 HDD will call this API when a packet is pending transmission in its
1113 queues.
1114
1115 DEPENDENCIES
1116
1117 A station must have been registered before the packet pending
1118 notification can be sent.
1119
1120 RESTRICTION: TL will not count packets for pending notification.
1121 HDD is expected to send the notification only when
1122 non-empty event gets triggered. Worst case scenario
1123 is that TL might end up making a call when Hdds
1124 queues are actually empty.
1125
1126 PARAMETERS
1127
1128 pvosGCtx: pointer to the global vos context; a handle to TL's
1129 control block can be extracted from its context
1130 ucSTAId: identifier for the STA that is pending transmission
1131 ucAC: access category of the non-empty queue
1132
1133 RETURN VALUE
1134
1135 The result code associated with performing the operation
1136
1137 VOS_STATUS_E_INVAL: Input parameters are invalid
1138 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1139 to TL cb is NULL ; access would cause a page fault
1140 VOS_STATUS_E_EXISTS: Station was not registered
1141 VOS_STATUS_SUCCESS: Everything is good :)
1142
1143 SIDE EFFECTS
1144
1145============================================================================*/
1146VOS_STATUS
1147WLANTL_STAPktPending
1148(
1149 v_PVOID_t pvosGCtx,
1150 v_U8_t ucSTAId,
1151 WLANTL_ACEnumType ucAc
1152);
1153
1154/*==========================================================================
1155
1156 FUNCTION WLANTL_SetSTAPriority
1157
1158 DESCRIPTION
1159
1160 TL exposes this API to allow upper layers a rough control over the
1161 priority of transmission for a given station when supporting multiple
1162 connections.
1163
1164 DEPENDENCIES
1165
1166 A station must have been registered before the change in priority can be
1167 called.
1168
1169 PARAMETERS
1170
1171 pvosGCtx: pointer to the global vos context; a handle to TL's
1172 control block can be extracted from its context
1173 ucSTAId: identifier for the STA that has to change priority
1174
1175 RETURN VALUE
1176
1177 The result code associated with performing the operation
1178
1179 VOS_STATUS_E_INVAL: Input parameters are invalid
1180 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1181 to TL cb is NULL ; access would cause a page fault
1182 VOS_STATUS_E_EXISTS: Station was not registered
1183 VOS_STATUS_SUCCESS: Everything is good :)
1184
1185 SIDE EFFECTS
1186
1187============================================================================*/
1188VOS_STATUS
1189WLANTL_SetSTAPriority
1190(
1191 v_PVOID_t pvosGCtx,
1192 v_U8_t ucSTAId,
1193 WLANTL_STAPriorityType tlSTAPri
1194);
1195
1196/*----------------------------------------------------------------------------
1197 INTERACTION WITH BAP
1198 ---------------------------------------------------------------------------*/
1199
1200/*==========================================================================
1201
1202 FUNCTION WLANTL_RegisterBAPClient
1203
1204 DESCRIPTION
1205 Called by SME to register itself as client for non-data BT-AMP packets.
1206
1207 DEPENDENCIES
1208 TL must be initialized before this function can be called.
1209
1210 PARAMETERS
1211
1212 IN
1213 pvosGCtx: pointer to the global vos context; a handle to TL's
1214 or SME's control block can be extracted from its context
1215 pfnTlBAPRxFrm: pointer to the receive processing routine for non-data
1216 BT-AMP packets
1217 pfnFlushOpCompleteCb:
1218 pointer to the function that will inform BAP that the
1219 flush operation is complete.
1220
1221 RETURN VALUE
1222
1223 The result code associated with performing the operation
1224
1225 VOS_STATUS_E_INVAL: Input parameters are invalid
1226 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1227 to TL cb is NULL ; access would cause a page fault
1228 VOS_STATUS_E_EXISTS: BAL client was already registered
1229 VOS_STATUS_SUCCESS: Everything is good :)
1230
1231 SIDE EFFECTS
1232
1233============================================================================*/
1234VOS_STATUS
1235WLANTL_RegisterBAPClient
1236(
1237 v_PVOID_t pvosGCtx,
1238 WLANTL_BAPRxCBType pfnTlBAPRx,
1239 WLANTL_FlushOpCompCBType pfnFlushOpCompleteCb
1240);
1241
1242
1243/*==========================================================================
1244
1245 FUNCTION WLANTL_TxBAPFrm
1246
1247 DESCRIPTION
1248 BAP calls this when it wants to send a frame to the module
1249
1250 DEPENDENCIES
1251 BAP must be registered with TL before this function can be called.
1252
1253 RESTRICTION: BAP CANNOT push any packets to TL until it did not receive
1254 a tx complete from the previous packet, that means BAP
1255 sends one packet, wait for tx complete and then
1256 sends another one
1257
1258 If BAP sends another packet before TL manages to process the
1259 previously sent packet call will end in failure
1260
1261 PARAMETERS
1262
1263 IN
1264 pvosGCtx: pointer to the global vos context; a handle to TL's
1265 or BAP's control block can be extracted from its context
1266 vosDataBuff: pointer to the vOSS buffer containing the packet to be
1267 transmitted
1268 pMetaInfo: meta information about the packet
1269 pfnTlBAPTxComp: pointer to a transmit complete routine for notifying
1270 the result of the operation over the bus
1271
1272 RETURN VALUE
1273 The result code associated with performing the operation
1274
1275 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1276 page fault
1277 VOS_STATUS_E_EXISTS: BAL client was not yet registered
1278 VOS_STATUS_E_BUSY: The previous BT-AMP packet was not yet transmitted
1279 VOS_STATUS_SUCCESS: Everything is good :)
1280
1281 Other failure messages may be returned from the BD header handling
1282 routines, please check apropriate API for more info.
1283
1284 SIDE EFFECTS
1285
1286============================================================================*/
1287VOS_STATUS
1288WLANTL_TxBAPFrm
1289(
1290 v_PVOID_t pvosGCtx,
1291 vos_pkt_t* vosDataBuff,
1292 WLANTL_MetaInfoType* pMetaInfo,
1293 WLANTL_TxCompCBType pfnTlBAPTxComp
1294);
1295
1296
1297/*----------------------------------------------------------------------------
1298 INTERACTION WITH SME
1299 ---------------------------------------------------------------------------*/
1300
1301/*==========================================================================
1302
1303 FUNCTION WLANTL_GetRssi
1304
1305 DESCRIPTION
1306 TL will extract the RSSI information from every data packet from the
1307 ongoing traffic and will store it. It will provide the result to SME
1308 upon request.
1309
1310 DEPENDENCIES
1311
1312 WARNING: the read and write of this value will not be protected
1313 by locks, therefore the information obtained after a read
1314 might not always be consistent.
1315
1316 PARAMETERS
1317
1318 IN
1319 pvosGCtx: pointer to the global vos context; a handle to TL's
1320 or SME's control block can be extracted from its context
1321 ucSTAId: station identifier for the requested value
1322
1323 OUT
1324 puRssi: the average value of the RSSI
1325
1326
1327 RETURN VALUE
1328 The result code associated with performing the operation
1329
1330 VOS_STATUS_E_INVAL: Input parameters are invalid
1331 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1332 to TL cb is NULL ; access would cause a page fault
1333 VOS_STATUS_E_EXISTS: STA was not yet registered
1334 VOS_STATUS_SUCCESS: Everything is good :)
1335
1336 SIDE EFFECTS
1337
1338============================================================================*/
1339VOS_STATUS
1340WLANTL_GetRssi
1341(
1342 v_PVOID_t pvosGCtx,
1343 v_U8_t ucSTAId,
1344 v_S7_t* puRssi
1345);
1346
1347/*==========================================================================
1348
1349 FUNCTION WLANTL_GetLinkQuality
1350
1351 DESCRIPTION
1352 TL will extract the LinkQuality information from every data packet from the
1353 ongoing traffic and will store it. It will provide the result to SME
1354 upon request.
1355
1356 DEPENDENCIES
1357
1358 WARNING: the read and write of this value will not be protected
1359 by locks, therefore the information obtained after a read
1360 might not always be consistent.
1361
1362 PARAMETERS
1363
1364 IN
1365 pvosGCtx: pointer to the global vos context; a handle to TL's
1366 or SME's control block can be extracted from its context
1367 ucSTAId: station identifier for the requested value
1368
1369 OUT
1370 puLinkQuality: the average value of the LinkQuality
1371
1372
1373 RETURN VALUE
1374 The result code associated with performing the operation
1375
1376 VOS_STATUS_E_INVAL: Input parameters are invalid
1377 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1378 to TL cb is NULL ; access would cause a page fault
1379 VOS_STATUS_E_EXISTS: STA was not yet registered
1380 VOS_STATUS_SUCCESS: Everything is good :)
1381
1382 SIDE EFFECTS
1383
1384============================================================================*/
1385VOS_STATUS
1386WLANTL_GetLinkQuality
1387(
1388 v_PVOID_t pvosGCtx,
1389 v_U8_t ucSTAId,
1390 v_U32_t* puLinkQuality
1391);
1392
1393/*==========================================================================
1394
1395 FUNCTION WLANTL_FlushStaTID
1396
1397 DESCRIPTION
1398 TL provides this API as an interface to SME (BAP) layer. TL inturn posts a
1399 message to HAL. This API is called by the SME inorder to perform a flush
1400 operation.
1401
1402 DEPENDENCIES
1403
1404 PARAMETERS
1405
1406 IN
1407 pvosGCtx: pointer to the global vos context; a handle to TL's
1408 or SME's control block can be extracted from its context
1409 ucSTAId: station identifier for the requested value
1410 ucTid: Tspec ID for the new BA session
1411
1412 OUT
1413 The response for this post is received in the main thread, via a response
1414 message from HAL to TL.
1415
1416 RETURN VALUE
1417 VOS_STATUS_SUCCESS: Everything is good :)
1418
1419 SIDE EFFECTS
1420============================================================================*/
1421VOS_STATUS
1422WLANTL_FlushStaTID
1423(
1424 v_PVOID_t pvosGCtx,
1425 v_U8_t ucSTAId,
1426 v_U8_t ucTid
1427);
1428
1429/*----------------------------------------------------------------------------
1430 INTERACTION WITH PE
1431 ---------------------------------------------------------------------------*/
1432
1433/*==========================================================================
1434
1435 FUNCTION WLANTL_RegisterMgmtFrmClient
1436
1437 DESCRIPTION
1438 Called by PE to register as a client for management frames delivery.
1439
1440 DEPENDENCIES
1441 TL must be initialized before this API can be called.
1442
1443 PARAMETERS
1444
1445 IN
1446 pvosGCtx: pointer to the global vos context; a handle to
1447 TL's control block can be extracted from its context
1448 pfnTlMgmtFrmRx: pointer to the receive processing routine for
1449 management frames
1450
1451 RETURN VALUE
1452 The result code associated with performing the operation
1453
1454 VOS_STATUS_E_INVAL: Input parameters are invalid
1455 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1456 page fault
1457 VOS_STATUS_E_EXISTS: Mgmt Frame client was already registered
1458 VOS_STATUS_SUCCESS: Everything is good :)
1459
1460 SIDE EFFECTS
1461
1462============================================================================*/
1463VOS_STATUS
1464WLANTL_RegisterMgmtFrmClient
1465(
1466 v_PVOID_t pvosGCtx,
1467 WLANTL_MgmtFrmRxCBType pfnTlMgmtFrmRx
1468);
1469
1470/*==========================================================================
1471
1472 FUNCTION WLANTL_DeRegisterMgmtFrmClient
1473
1474 DESCRIPTION
1475 Called by PE to deregister as a client for management frames delivery.
1476
1477 DEPENDENCIES
1478 TL must be initialized before this API can be called.
1479
1480 PARAMETERS
1481
1482 IN
1483 pvosGCtx: pointer to the global vos context; a handle to
1484 TL's control block can be extracted from its context
1485 RETURN VALUE
1486 The result code associated with performing the operation
1487
1488 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1489 page fault
1490 VOS_STATUS_E_EXISTS: Mgmt Frame client was never registered
1491 VOS_STATUS_SUCCESS: Everything is good :)
1492
1493 SIDE EFFECTS
1494
1495============================================================================*/
1496VOS_STATUS
1497WLANTL_DeRegisterMgmtFrmClient
1498(
1499 v_PVOID_t pvosGCtx
1500);
1501
1502/*==========================================================================
1503
1504 FUNCTION WLANTL_TxMgmtFrm
1505
1506 DESCRIPTION
1507 Called by PE when it want to send out a management frame.
1508 HAL will also use this API for the few frames it sends out, they are not
1509 management frames howevere it is accepted that an exception will be
1510 allowed ONLY for the usage of HAL.
1511 Generic data frames SHOULD NOT travel through this function.
1512
1513 DEPENDENCIES
1514 TL must be initialized before this API can be called.
1515
1516 RESTRICTION: If PE sends another packet before TL manages to process the
1517 previously sent packet call will end in failure
1518
1519 Frames comming through here must be 802.11 frames, frame
1520 translation in UMA will be automatically disabled.
1521
1522 PARAMETERS
1523
1524 IN
1525 pvosGCtx: pointer to the global vos context;a handle to TL's
1526 control block can be extracted from its context
1527 vosFrmBuf: pointer to a vOSS buffer containing the management
1528 frame to be transmitted
1529 usFrmLen: the length of the frame to be transmitted; information
1530 is already included in the vOSS buffer
1531 wFrmType: the type of the frame being transmitted
1532 tid: tid used to transmit this frame
1533 pfnCompTxFunc: function pointer to the transmit complete routine
1534 pvBDHeader: pointer to the BD header, if NULL it means it was not
1535 yet constructed and it lies within TL's responsibility
1536 to do so; if not NULL it is expected that it was
1537 already packed inside the vos packet
1538 ucAckResponse: flag notifying it an interrupt is needed for the
1539 acknowledgement received when the frame is sent out
1540 the air and ; the interrupt will be processed by HAL,
1541 only one such frame can be pending in the system at
1542 one time.
1543
1544
1545 RETURN VALUE
1546 The result code associated with performing the operation
1547
1548 VOS_STATUS_E_INVAL: Input parameters are invalid
1549 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1550 page fault
1551 VOS_STATUS_E_EXISTS: Mgmt Frame client was not yet registered
1552 VOS_STATUS_E_BUSY: The previous Mgmt packet was not yet transmitted
1553 VOS_STATUS_SUCCESS: Everything is good :)
1554
1555 Other failure messages may be returned from the BD header handling
1556 routines, please check apropriate API for more info.
1557
1558 SIDE EFFECTS
1559
1560============================================================================*/
1561VOS_STATUS
1562WLANTL_TxMgmtFrm
1563(
1564 v_PVOID_t pvosGCtx,
1565 vos_pkt_t* vosFrmBuf,
1566 v_U16_t usFrmLen,
1567 v_U8_t ucFrmType,
1568 v_U8_t tid,
1569 WLANTL_TxCompCBType pfnCompTxFunc,
1570 v_PVOID_t voosBDHeader,
1571 v_U8_t ucAckResponse
1572);
1573
1574
1575/*----------------------------------------------------------------------------
1576 INTERACTION WITH HAL
1577 ---------------------------------------------------------------------------*/
1578
1579/*==========================================================================
1580
1581 FUNCTION WLANTL_ResetNotification
1582
1583 DESCRIPTION
1584 HAL notifies TL when the module is being reset.
1585 Currently not used.
1586
1587 DEPENDENCIES
1588
1589 PARAMETERS
1590
1591 IN
1592 pvosGCtx: pointer to the global vos context; a handle to TL's
1593 control block can be extracted from its context
1594
1595
1596 RETURN VALUE
1597 The result code associated with performing the operation
1598
1599 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1600 page fault
1601 VOS_STATUS_SUCCESS: Everything is good :)
1602
1603 SIDE EFFECTS
1604
1605============================================================================*/
1606VOS_STATUS
1607WLANTL_ResetNotification
1608(
1609 v_PVOID_t pvosGCtx
1610);
1611
1612/*==========================================================================
1613
1614 FUNCTION WLANTL_SuspendDataTx
1615
1616 DESCRIPTION
1617 HAL calls this API when it wishes to suspend transmission for a
1618 particular STA.
1619
1620 DEPENDENCIES
1621 The STA for which the request is made must be first registered with
1622 TL by HDD.
1623
1624 RESTRICTION: In case of a suspend, the flag write and read will not be
1625 locked: worst case scenario one more packet can get
1626 through before the flag gets updated (we can make this
1627 write atomic as well to guarantee consistency)
1628
1629 PARAMETERS
1630
1631 IN
1632 pvosGCtx: pointer to the global vos context; a handle to TL's
1633 control block can be extracted from its context
1634 pucSTAId: identifier of the station for which the request is made;
1635 a value of NULL assumes suspend on all active station
1636 pfnSuspendTxCB: pointer to the suspend result notification in case the
1637 call is asynchronous
1638
1639
1640 RETURN VALUE
1641 The result code associated with performing the operation
1642
1643 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1644 to TL cb is NULL ; access would cause a page fault
1645 VOS_STATUS_E_EXISTS: Station was not registered
1646 VOS_STATUS_SUCCESS: Everything is good :)
1647
1648 SIDE EFFECTS
1649
1650============================================================================*/
1651VOS_STATUS
1652WLANTL_SuspendDataTx
1653(
1654 v_PVOID_t pvosGCtx,
1655 v_U8_t* ucSTAId,
1656 WLANTL_SuspendCBType pfnSuspendTx
1657);
1658
1659/*==========================================================================
1660
1661 FUNCTION WLANTL_ResumeDataTx
1662
1663 DESCRIPTION
1664 Called by HAL to resume data transmission for a given STA.
1665
1666 WARNING: If a station was individually suspended a global resume will
1667 not resume that station
1668
1669 DEPENDENCIES
1670
1671 PARAMETERS
1672
1673 IN
1674 pvosGCtx: pointer to the global vos context; a handle to TL's
1675 control block can be extracted from its context
1676 pucSTAId: identifier of the station which is being resumed; NULL
1677 translates into global resume
1678
1679 RETURN VALUE
1680 The result code associated with performing the operation
1681
1682 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1683 to TL cb is NULL ; access would cause a page fault
1684 VOS_STATUS_E_EXISTS: Station was not registered
1685 VOS_STATUS_SUCCESS: Everything is good :)
1686
1687 SIDE EFFECTS
1688
1689============================================================================*/
1690VOS_STATUS
1691WLANTL_ResumeDataTx
1692(
1693 v_PVOID_t pvosGCtx,
1694 v_U8_t* pucSTAId
1695);
1696
1697
1698/*----------------------------------------------------------------------------
1699 CLIENT INDEPENDENT INTERFACE
1700 ---------------------------------------------------------------------------*/
1701
1702/*==========================================================================
1703
1704 FUNCTION WLANTL_GetTxPktCount
1705
1706 DESCRIPTION
1707 TL will provide the number of transmitted packets counted per
1708 STA per TID.
1709
1710 DEPENDENCIES
1711
1712 PARAMETERS
1713
1714 IN
1715 pvosGCtx: pointer to the global vos context; a handle to TL's
1716 control block can be extracted from its context
1717 ucSTAId: identifier of the station
1718 ucTid: identifier of the tspec
1719
1720 OUT
1721 puTxPktCount: the number of packets tx packet for this STA and TID
1722
1723 RETURN VALUE
1724 The result code associated with performing the operation
1725
1726 VOS_STATUS_E_INVAL: Input parameters are invalid
1727 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1728 to TL cb is NULL ; access would cause a page fault
1729 VOS_STATUS_E_EXISTS: Station was not registered
1730 VOS_STATUS_SUCCESS: Everything is good :)
1731
1732 SIDE EFFECTS
1733
1734============================================================================*/
1735VOS_STATUS
1736WLANTL_GetTxPktCount
1737(
1738 v_PVOID_t pvosGCtx,
1739 v_U8_t ucSTAId,
1740 v_U8_t ucTid,
1741 v_U32_t* puTxPktCount
1742);
1743
1744/*==========================================================================
1745
1746 FUNCTION WLANTL_GetRxPktCount
1747
1748 DESCRIPTION
1749 TL will provide the number of received packets counted per
1750 STA per TID.
1751
1752 DEPENDENCIES
1753
1754 PARAMETERS
1755
1756 IN
1757 pvosGCtx: pointer to the global vos context; a handle to TL's
1758 control block can be extracted from its context
1759 ucSTAId: identifier of the station
1760 ucTid: identifier of the tspec
1761
1762 OUT
1763 puTxPktCount: the number of packets rx packet for this STA and TID
1764
1765 RETURN VALUE
1766 The result code associated with performing the operation
1767
1768 VOS_STATUS_E_INVAL: Input parameters are invalid
1769 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1770 to TL cb is NULL ; access would cause a page fault
1771 VOS_STATUS_E_EXISTS: Station was not registered
1772 VOS_STATUS_SUCCESS: Everything is good :)
1773
1774 SIDE EFFECTS
1775
1776============================================================================*/
1777VOS_STATUS
1778WLANTL_GetRxPktCount
1779(
1780 v_PVOID_t pvosGCtx,
1781 v_U8_t ucSTAId,
1782 v_U8_t ucTid,
1783 v_U32_t* puRxPktCount
1784);
1785
1786/*==========================================================================
1787 VOSS SCHEDULER INTERACTION
1788 ==========================================================================*/
1789
1790/*==========================================================================
1791 FUNCTION WLANTL_McProcessMsg
1792
1793 DESCRIPTION
1794 Called by VOSS when a message was serialized for TL through the
1795 main thread/task.
1796
1797 DEPENDENCIES
1798 The TL must be initialized before this function can be called.
1799
1800 PARAMETERS
1801
1802 IN
1803 pvosGCtx: pointer to the global vos context; a handle to TL's
1804 control block can be extracted from its context
1805 message: type and content of the message
1806
1807
1808 RETURN VALUE
1809 The result code associated with performing the operation
1810
1811 VOS_STATUS_E_INVAL: invalid input parameters
1812 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1813 page fault
1814 VOS_STATUS_SUCCESS: Everything is good :)
1815
1816 SIDE EFFECTS
1817
1818============================================================================*/
1819VOS_STATUS
1820WLANTL_McProcessMsg
1821(
1822 v_PVOID_t pvosGCtx,
1823 vos_msg_t* message
1824);
1825
1826/*==========================================================================
1827 FUNCTION WLANTL_McFreeMsg
1828
1829 DESCRIPTION
1830 Called by VOSS to free a given TL message on the Main thread when there
1831 are messages pending in the queue when the whole system is been reset.
1832 For now, TL does not allocate any body so this function shout translate
1833 into a NOOP
1834
1835 DEPENDENCIES
1836 The TL must be initialized before this function can be called.
1837
1838 PARAMETERS
1839
1840 IN
1841 pvosGCtx: pointer to the global vos context; a handle to TL's
1842 control block can be extracted from its context
1843 message: type and content of the message
1844
1845
1846 RETURN VALUE
1847 The result code associated with performing the operation
1848
1849 VOS_STATUS_SUCCESS: Everything is good :)
1850
1851 SIDE EFFECTS
1852
1853============================================================================*/
1854VOS_STATUS
1855WLANTL_McFreeMsg
1856(
1857 v_PVOID_t pvosGCtx,
1858 vos_msg_t* message
1859);
1860
1861/*==========================================================================
1862 FUNCTION WLANTL_TxProcessMsg
1863
1864 DESCRIPTION
1865 Called by VOSS when a message was serialized for TL through the
1866 tx thread/task.
1867
1868 DEPENDENCIES
1869 The TL must be initialized before this function can be called.
1870
1871 PARAMETERS
1872
1873 IN
1874 pvosGCtx: pointer to the global vos context; a handle to TL's
1875 control block can be extracted from its context
1876 message: type and content of the message
1877
1878
1879 RETURN VALUE
1880 The result code associated with performing the operation
1881
1882 VOS_STATUS_E_INVAL: invalid input parameters
1883 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1884 page fault
1885 VOS_STATUS_SUCCESS: Everything is good :)
1886
1887 Other values can be returned as a result of a function call, please check
1888 corresponding API for more info.
1889 SIDE EFFECTS
1890
1891============================================================================*/
1892VOS_STATUS
1893WLANTL_TxProcessMsg
1894(
1895 v_PVOID_t pvosGCtx,
1896 vos_msg_t* message
1897);
1898
1899/*==========================================================================
1900 FUNCTION WLANTL_McFreeMsg
1901
1902 DESCRIPTION
1903 Called by VOSS to free a given TL message on the Main thread when there
1904 are messages pending in the queue when the whole system is been reset.
1905 For now, TL does not allocate any body so this function shout translate
1906 into a NOOP
1907
1908 DEPENDENCIES
1909 The TL must be initialized before this function can be called.
1910
1911 PARAMETERS
1912
1913 IN
1914 pvosGCtx: pointer to the global vos context; a handle to TL's
1915 control block can be extracted from its context
1916 message: type and content of the message
1917
1918
1919 RETURN VALUE
1920 The result code associated with performing the operation
1921
1922 VOS_STATUS_SUCCESS: Everything is good :)
1923
1924 SIDE EFFECTS
1925
1926============================================================================*/
1927VOS_STATUS
1928WLANTL_TxFreeMsg
1929(
1930 v_PVOID_t pvosGCtx,
1931 vos_msg_t* message
1932);
1933
1934
1935/*==========================================================================
1936 FUNCTION WLANTL_EnableUAPSDForAC
1937
1938 DESCRIPTION
1939 Called by HDD to enable UAPSD in TL. TL is in charge for sending trigger
1940 frames.
1941
1942 DEPENDENCIES
1943 The TL must be initialized before this function can be called.
1944
1945 PARAMETERS
1946
1947 IN
1948 pvosGCtx: pointer to the global vos context; a handle to TL's
1949 control block can be extracted from its context
1950 ucSTAId: station Id
1951 ucACId: AC for which U-APSD is being enabled
1952 ucTid TSpec Id
1953 uServiceInt: service interval used by TL to send trigger frames
1954 uSuspendInt: suspend interval used by TL to determine that an
1955 app is idle and should start sending trigg frms less often
1956 wTSDir: direction of TSpec
1957
1958 RETURN VALUE
1959 The result code associated with performing the operation
1960
1961 VOS_STATUS_SUCCESS: Everything is good :)
1962
1963 SIDE EFFECTS
1964
1965============================================================================*/
1966VOS_STATUS
1967WLANTL_EnableUAPSDForAC
1968(
1969 v_PVOID_t pvosGCtx,
1970 v_U8_t ucSTAId,
1971 WLANTL_ACEnumType ucACId,
1972 v_U8_t ucTid,
1973 v_U8_t ucUP,
1974 v_U32_t uServiceInt,
1975 v_U32_t uSuspendInt,
1976 WLANTL_TSDirType wTSDir
1977);
1978
1979
1980/*==========================================================================
1981 FUNCTION WLANTL_DisableUAPSDForAC
1982
1983 DESCRIPTION
1984 Called by HDD to disable UAPSD in TL. TL will stop sending trigger
1985 frames.
1986
1987 DEPENDENCIES
1988 The TL must be initialized before this function can be called.
1989
1990 PARAMETERS
1991
1992 IN
1993 pvosGCtx: pointer to the global vos context; a handle to TL's
1994 control block can be extracted from its context
1995 ucSTAId: station Id
1996 ucACId: AC for which U-APSD is being enabled
1997
1998
1999 RETURN VALUE
2000 The result code associated with performing the operation
2001
2002 VOS_STATUS_SUCCESS: Everything is good :)
2003
2004 SIDE EFFECTS
2005
2006============================================================================*/
2007VOS_STATUS
2008WLANTL_DisableUAPSDForAC
2009(
2010 v_PVOID_t pvosGCtx,
2011 v_U8_t ucSTAId,
2012 WLANTL_ACEnumType ucACId
2013);
2014
2015#if defined WLAN_FEATURE_NEIGHBOR_ROAMING
2016/*==========================================================================
2017 FUNCTION WLANTL_RegRSSIIndicationCB
2018
2019 DESCRIPTION Registration function to get notification if RSSI cross
2020 threshold.
2021 Client should register threshold, direction, and notification
2022 callback function pointer
2023
2024 DEPENDENCIES NONE
2025
2026 PARAMETERS in pAdapter - Global handle
2027 in rssiValue - RSSI threshold value
2028 in triggerEvent - Cross direction should be notified
2029 UP, DOWN, and CROSS
2030 in crossCBFunction - Notification CB Function
2031 in usrCtxt - user context
2032
2033 RETURN VALUE VOS_STATUS
2034
2035 SIDE EFFECTS NONE
2036
2037============================================================================*/
2038VOS_STATUS WLANTL_RegRSSIIndicationCB
2039(
2040 v_PVOID_t pAdapter,
2041 v_S7_t rssiValue,
2042 v_U8_t triggerEvent,
2043 WLANTL_RSSICrossThresholdCBType crossCBFunction,
2044 VOS_MODULE_ID moduleID,
2045 v_PVOID_t usrCtxt
2046);
2047
2048/*==========================================================================
2049 FUNCTION WLANTL_DeregRSSIIndicationCB
2050
2051 DESCRIPTION Remove specific threshold from list
2052
2053 DEPENDENCIES NONE
2054
2055 PARAMETERS in pAdapter - Global handle
2056 in rssiValue - RSSI threshold value
2057 in triggerEvent - Cross direction should be notified
2058 UP, DOWN, and CROSS
2059
2060 RETURN VALUE VOS_STATUS
2061
2062 SIDE EFFECTS NONE
2063
2064============================================================================*/
2065VOS_STATUS WLANTL_DeregRSSIIndicationCB
2066(
2067 v_PVOID_t pAdapter,
2068 v_S7_t rssiValue,
2069 v_U8_t triggerEvent,
2070 WLANTL_RSSICrossThresholdCBType crossCBFunction,
2071 VOS_MODULE_ID moduleID
2072);
2073
2074/*==========================================================================
2075
2076 FUNCTION
2077
2078 DESCRIPTION
2079
2080 PARAMETERS
2081
2082 RETURN VALUE
2083
2084============================================================================*/
2085VOS_STATUS WLANTL_BMPSRSSIRegionChangedNotification
2086(
2087 v_PVOID_t pAdapter,
2088 tpSirRSSINotification pRSSINotification
2089);
2090
2091/*==========================================================================
2092 FUNCTION WLANTL_SetAlpha
2093
2094 DESCRIPTION ALPLA is weight value to calculate AVG RSSI
2095 avgRSSI = (ALPHA * historyRSSI) + ((10 - ALPHA) * newRSSI)
2096 avgRSSI has (ALPHA * 10)% of history RSSI weight and
2097 (10 - ALPHA)% of newRSSI weight
2098 This portion is dynamically configurable.
2099 Default is ?
2100
2101 DEPENDENCIES NONE
2102
2103 PARAMETERS in pAdapter - Global handle
2104 in valueAlpah - ALPHA
2105
2106 RETURN VALUE VOS_STATUS
2107
2108 SIDE EFFECTS NONE
2109
2110============================================================================*/
2111VOS_STATUS WLANTL_SetAlpha
2112(
2113 v_PVOID_t pAdapter,
2114 v_U8_t valueAlpha
2115);
2116
2117/*==========================================================================
2118 FUNCTION WLANTL_RegGetTrafficStatus
2119
2120 DESCRIPTION Registration function for traffic status monitoring
2121 During measure period count data frames.
2122 If frame count is larger then IDLE threshold set as traffic ON
2123 or OFF.
2124 And traffic status is changed send report to client with
2125 registered callback function
2126
2127 DEPENDENCIES NONE
2128
2129 PARAMETERS in pAdapter - Global handle
2130 in idleThreshold - Traffic on or off threshold
2131 in measurePeriod - Traffic state check period
2132 in trfficStatusCB - traffic status changed notification
2133 CB function
2134 in usrCtxt - user context
2135
2136 RETURN VALUE VOS_STATUS
2137
2138 SIDE EFFECTS NONE
2139
2140============================================================================*/
2141VOS_STATUS WLANTL_RegGetTrafficStatus
2142(
2143 v_PVOID_t pAdapter,
2144 v_U32_t idleThreshold,
2145 v_U32_t measurePeriod,
2146 WLANTL_TrafficStatusChangedCBType trfficStatusCB,
2147 v_PVOID_t usrCtxt
2148);
2149#endif
2150/*==========================================================================
2151 FUNCTION WLANTL_GetStatistics
2152
2153 DESCRIPTION Get traffic statistics for identified station
2154
2155 DEPENDENCIES NONE
2156
2157 PARAMETERS in pAdapter - Global handle
2158 in statType - specific statistics field to reset
2159 out statBuffer - traffic statistics buffer
2160
2161 RETURN VALUE VOS_STATUS
2162
2163 SIDE EFFECTS NONE
2164
2165============================================================================*/
2166VOS_STATUS WLANTL_GetStatistics
2167(
2168 v_PVOID_t pAdapter,
2169 WLANTL_TRANSFER_STA_TYPE *statBuffer,
2170 v_U8_t STAid
2171);
2172
2173/*==========================================================================
2174 FUNCTION WLANTL_ResetStatistics
2175
2176 DESCRIPTION Reset statistics structure for identified station ID
2177 Reset means set values as 0
2178
2179 DEPENDENCIES NONE
2180
2181 PARAMETERS in pAdapter - Global handle
2182 in statType - specific statistics field to reset
2183
2184 RETURN VALUE VOS_STATUS
2185
2186 SIDE EFFECTS NONE
2187
2188============================================================================*/
2189VOS_STATUS WLANTL_ResetStatistics
2190(
2191 v_PVOID_t pAdapter,
2192 v_U8_t STAid
2193);
2194
2195/*==========================================================================
2196 FUNCTION WLANTL_GetSpecStatistic
2197
2198 DESCRIPTION Get specific field within statistics structure for
2199 identified station ID
2200
2201 DEPENDENCIES NONE
2202
2203 PARAMETERS in pAdapter - Global handle
2204 in statType - specific statistics field to reset
2205 in STAid - Station ID
2206 out buffer - Statistic value
2207
2208 RETURN VALUE VOS_STATUS
2209
2210 SIDE EFFECTS NONE
2211
2212============================================================================*/
2213VOS_STATUS WLANTL_GetSpecStatistic
2214(
2215 v_PVOID_t pAdapter,
2216 WLANTL_TRANSFER_STATIC_TYPE statType,
2217 v_U32_t *buffer,
2218 v_U8_t STAid
2219);
2220
2221/*==========================================================================
2222 FUNCTION WLANTL_ResetSpecStatistic
2223
2224 DESCRIPTION Reset specific field within statistics structure for
2225 identified station ID
2226 Reset means set as 0
2227
2228 DEPENDENCIES NONE
2229
2230 PARAMETERS in pAdapter - Global handle
2231 in statType - specific statistics field to reset
2232 in STAid - Station ID
2233
2234 RETURN VALUE VOS_STATUS
2235
2236 SIDE EFFECTS NONE
2237
2238============================================================================*/
2239VOS_STATUS WLANTL_ResetSpecStatistic
2240(
2241 v_PVOID_t pAdapter,
2242 WLANTL_TRANSFER_STATIC_TYPE statType,
2243 v_U8_t STAid
2244);
2245#ifdef ANI_CHIPSET_VOLANS
2246/*===============================================================================
2247 FUNCTION WLANTL_IsReplayPacket
2248
2249 DESCRIPTION This function does replay check for valid stations
2250
2251 DEPENDENCIES Validity of replay check must be done before the function
2252 is called
2253
2254 PARAMETERS currentReplayCounter current replay counter taken from RX BD
2255 previousReplayCounter previous replay counter taken from TL CB
2256
2257 RETRUN VOS_TRUE packet is a replay packet
2258 VOS_FALSE packet is not a replay packet
2259
2260 SIDE EFFECTS none
2261 ===============================================================================*/
2262v_BOOL_t WLANTL_IsReplayPacket
2263(
2264 v_U64_t currentReplayCounter,
2265 v_U64_t previousReplayCounter
2266);
2267
2268/*===============================================================================
2269 FUNCTION WLANTL_GetReplayCounterFromRxBD
2270
2271 DESCRIPTION This function extracts 48-bit replay packet number from RX BD
2272
2273 DEPENDENCIES Validity of replay check must be done before the function
2274 is called
2275
2276 PARAMETERS pucRxHeader pointer to RX BD header
2277
2278 RETRUN v_U64_t Packet number extarcted from RX BD
2279
2280 SIDE EFFECTS none
2281 ===============================================================================*/
2282v_U64_t
2283WLANTL_GetReplayCounterFromRxBD
2284(
2285 v_U8_t *pucRxBDHeader
2286);
2287#endif /*End of #ifdef ANI_CHIPSET_VOLANS*/
2288
2289
2290
2291/*
2292 DESCRIPTION
2293 TL returns the weight currently maintained in TL.
2294 IN
2295 pvosGCtx: pointer to the global vos context; a handle to TL's
2296 or SME's control block can be extracted from its context
2297
2298 OUT
2299 pACWeights: Caller allocated memory for filling in weights
2300
2301 RETURN VALUE VOS_STATUS
2302*/
2303VOS_STATUS
2304WLANTL_GetACWeights
2305(
2306 v_PVOID_t pvosGCtx,
2307 v_U8_t* pACWeights
2308);
2309
2310
2311/*
2312 DESCRIPTION
2313 Change the weight currently maintained by TL.
2314 IN
2315 pvosGCtx: pointer to the global vos context; a handle to TL's
2316 or SME's control block can be extracted from its context
2317 pACWeights: Caller allocated memory contain the weights to use
2318
2319
2320 RETURN VALUE VOS_STATUS
2321*/
2322VOS_STATUS
2323WLANTL_SetACWeights
2324(
2325 v_PVOID_t pvosGCtx,
2326 v_U8_t* pACWeights
2327);
2328
2329#ifdef WLAN_SOFTAP_FEATURE
2330/*==========================================================================
2331 FUNCTION WLANTL_GetSoftAPStatistics
2332
2333 DESCRIPTION Collect the cumulative statistics for all Softap stations
2334
2335 DEPENDENCIES NONE
2336
2337 PARAMETERS in pvosGCtx - Pointer to the global vos context
2338 bReset - If set TL statistics will be cleared after reading
2339 out statsSum - pointer to collected statistics
2340
2341 RETURN VALUE VOS_STATUS_SUCCESS : if the Statistics are successfully extracted
2342
2343 SIDE EFFECTS NONE
2344
2345============================================================================*/
2346VOS_STATUS WLANTL_GetSoftAPStatistics(v_PVOID_t pAdapter, WLANTL_TRANSFER_STA_TYPE *statsSum, v_BOOL_t bReset);
2347#endif
2348
2349#ifdef __cplusplus
2350 }
2351#endif
2352
2353
2354 /*===========================================================================
2355
2356 FUNCTION WLANTL_AssocFailed
2357
2358 DESCRIPTION
2359
2360 This function is used by PE to notify TL that cache needs to flushed
2361 when association is not successfully completed
2362
2363 Internally, TL post a message to TX_Thread to serialize the request to
2364 keep lock-free mechanism.
2365
2366
2367 DEPENDENCIES
2368
2369 TL must have been initialized before this gets called.
2370
2371
2372 PARAMETERS
2373
2374 ucSTAId: station id
2375
2376 RETURN VALUE
2377
2378 none
2379
2380 SIDE EFFECTS
2381 There may be race condition that PE call this API and send another association
2382 request immediately with same staId before TX_thread can process the message.
2383
2384 To avoid this, we might need PE to wait for TX_thread process the message,
2385 but this is not currently implemented.
2386
2387============================================================================*/
2388void WLANTL_AssocFailed(v_U8_t staId);
2389
2390
2391/*===============================================================================
2392 FUNCTION WLANTL_PostResNeeded
2393
2394 DESCRIPTION This function posts message to TL to reserve BD/PDU memory
2395
2396 DEPENDENCIES None
2397
2398 PARAMETERS pvosGCtx
2399
2400 RETURN None
2401
2402 SIDE EFFECTS none
2403 ===============================================================================*/
2404
2405void WLANTL_PostResNeeded(v_PVOID_t pvosGCtx);
2406
2407/*===========================================================================
2408
2409 FUNCTION WLANTL_Finish_ULA
2410
2411 DESCRIPTION
2412 This function is used by HDD to notify TL to finish Upper layer authentication
2413 incase the last EAPOL packet is pending in the TL queue.
2414 To avoid the race condition between sme set key and the last EAPOL packet
2415 the HDD module calls this function just before calling the sme_RoamSetKey.
2416
2417 DEPENDENCIES
2418
2419 TL must have been initialized before this gets called.
2420
2421
2422 PARAMETERS
2423
2424 callbackRoutine: HDD Callback function.
2425 callbackContext : HDD userdata context.
2426
2427 RETURN VALUE
2428
2429 VOS_STATUS_SUCCESS/VOS_STATUS_FAILURE
2430
2431 SIDE EFFECTS
2432
2433============================================================================*/
2434
2435VOS_STATUS WLANTL_Finish_ULA( void (*callbackRoutine) (void *callbackContext),
2436 void *callbackContext);
2437
2438/*===============================================================================
2439 FUNCTION WLANTL_UpdateRssiBmps
2440
2441 DESCRIPTION This function updates the TL's RSSI (in BMPS mode)
2442
2443 DEPENDENCIES None
2444
2445 PARAMETERS
2446
2447 pvosGCtx VOS context VOS Global context
2448 staId Station ID Station ID
2449 rssi RSSI (BMPS mode) RSSI in BMPS mode
2450
2451 RETURN None
2452
2453 SIDE EFFECTS none
2454 ===============================================================================*/
2455
2456void WLANTL_UpdateRssiBmps(v_PVOID_t pvosGCtx, v_U8_t staId, v_S7_t rssi);
2457
2458#endif /* #ifndef WLAN_QCT_WLANTL_H */