blob: 7070ed2d31ba59e22392cb3e395c08c6b9d3a125 [file] [log] [blame]
Jeff Johnson295189b2012-06-20 16:38:30 -07001/*
Kiet Lam1ed83fc2014-02-19 01:15:45 -08002 * Copyright (c) 2012-2014 The Linux Foundation. All rights reserved.
3 *
4 * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
5 *
6 *
7 * Permission to use, copy, modify, and/or distribute this software for
8 * any purpose with or without fee is hereby granted, provided that the
9 * above copyright notice and this permission notice appear in all
10 * copies.
11 *
12 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
13 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
14 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
15 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
16 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
17 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
18 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19 * PERFORMANCE OF THIS SOFTWARE.
20 */
21
22/*
Kiet Lama7f454d2014-07-24 12:04:06 -070023 * This file was originally distributed by Qualcomm Atheros, Inc.
24 * under proprietary terms before Copyright ownership was assigned
25 * to the Linux Foundation.
Gopichand Nakkala92f07d82013-01-08 21:16:34 -080026 */
Kiet Lam1ed83fc2014-02-19 01:15:45 -080027
28
Kiet Lama7f454d2014-07-24 12:04:06 -070029
30
Jeff Johnson295189b2012-06-20 16:38:30 -070031#ifndef WLAN_QCT_WLANTL_H
32#define WLAN_QCT_WLANTL_H
33
34/*===========================================================================
35
Jeff Johnson40b59aa2013-03-19 14:43:18 -070036 W L A N T R A N S P O R T L A Y E R
Jeff Johnson295189b2012-06-20 16:38:30 -070037 E X T E R N A L A P I
Jeff Johnson40b59aa2013-03-19 14:43:18 -070038
39
Jeff Johnson295189b2012-06-20 16:38:30 -070040DESCRIPTION
Jeff Johnson40b59aa2013-03-19 14:43:18 -070041 This file contains the external API exposed by the wlan transport layer
Jeff Johnson295189b2012-06-20 16:38:30 -070042 module.
Jeff Johnson295189b2012-06-20 16:38:30 -070043===========================================================================*/
44
45
46/*===========================================================================
47
48 EDIT HISTORY FOR FILE
49
50
51 This section contains comments describing changes made to the module.
52 Notice that changes are listed in reverse chronological order.
53
54
55 $Header:$ $DateTime: $ $Author: $
56
57
58when who what, where, why
59-------- --- ----------------------------------------------------------
6001/08/10 lti Added TL Data Caching
6110/15/09 rnair Modifying STADescType struct
6210/06/09 rnair Adding support for WAPI
6309/22/09 lti Add deregistration API for management client
6402/02/09 sch Add Handoff support
6512/09/08 lti Fixes for AMSS compilation
6609/05/08 lti Fixes after QOS unit testing
6708/06/08 lti Added QOS support
6805/01/08 lti Created module.
69
70===========================================================================*/
71
72
73
74/*===========================================================================
75
76 INCLUDE FILES FOR MODULE
77
78===========================================================================*/
79
80/*----------------------------------------------------------------------------
81 * Include Files
82 * -------------------------------------------------------------------------*/
83#include "vos_api.h"
84#include "vos_packet.h"
85#include "sirApi.h"
Jeff Johnson295189b2012-06-20 16:38:30 -070086#include "csrApi.h"
87#include "sapApi.h"
Jeff Johnson295189b2012-06-20 16:38:30 -070088/*----------------------------------------------------------------------------
89 * Preprocessor Definitions and Constants
90 * -------------------------------------------------------------------------*/
91 #ifdef __cplusplus
92 extern "C" {
93 #endif
94
95/*Offset of the OUI field inside the LLC/SNAP header*/
96#define WLANTL_LLC_OUI_OFFSET 3
97
98/*Size of the OUI type field inside the LLC/SNAP header*/
99#define WLANTL_LLC_OUI_SIZE 3
100
101/*Offset of the LLC/SNAP header*/
102#define WLANTL_LLC_SNAP_OFFSET 0
103
104/*Size of the LLC/SNAP header*/
105#define WLANTL_LLC_SNAP_SIZE 8
106
107/*============================================================================
108 * GENERIC STRUCTURES - not belonging to TL
109 * TO BE MOVED TO A GLOBAL HEADER
110 ============================================================================*/
111/*Maximum number of ACs */
112#define WLANTL_MAX_AC 4
113
Jeff Johnson295189b2012-06-20 16:38:30 -0700114/* Maximum number of station supported by TL, including BC. */
115#define WLAN_MAX_STA_COUNT (HAL_NUM_STA)
Madan Mohan Koyylamudi3b8400c2013-01-24 17:47:01 +0530116#define WLAN_NON32_STA_COUNT 14
Jeff Johnson295189b2012-06-20 16:38:30 -0700117/* The symbolic station ID return to HDD to specify the packet is bc/mc */
118#define WLAN_RX_BCMC_STA_ID (WLAN_MAX_STA_COUNT + 1)
119
120/* The symbolic station ID return to HDD to specify the packet is to soft-AP itself */
121#define WLAN_RX_SAP_SELF_STA_ID (WLAN_MAX_STA_COUNT + 2)
122
123/* Used by HDS systme. This station ID is used by TL to tell upper layer that
124 this packet is for WDS and not for a loopback for an associated station. */
125#define WLANTL_RX_WDS_STAID WLAN_MAX_STA_COUNT
126
127/* Station ID used for BC traffic. This value will be used when upper layer registers
128 the broadcast client or allocate station strcuture to keep per-station info.*/
129//#define WLANTL_BC_STA_ID 0x00
130
Jeff Johnson295189b2012-06-20 16:38:30 -0700131
Jeff Johnson295189b2012-06-20 16:38:30 -0700132#define WLANTL_MAX_TID 15
Shailender Karmuchi13c0d082013-03-26 14:41:39 -0700133/* Default RSSI average Alpha */
134#define WLANTL_HO_DEFAULT_ALPHA 5
135#define WLANTL_HO_TDLS_ALPHA 7
136
Madan Mohan Koyyalamudid9383fd2013-08-13 09:27:30 +0530137// Choose the largest possible value that can be accomodates in 8 bit signed
138// variable.
139#define SNR_HACK_BMPS (127)
Mahesh A Saptasagarbbdcf122014-10-28 20:57:11 +0530140#define IS_BROADCAST_ADD(_a) \
141 ((_a)[0] == 0xff && \
142 (_a)[1] == 0xff && \
143 (_a)[2] == 0xff && \
144 (_a)[3] == 0xff && \
145 (_a)[4] == 0xff && \
146 (_a)[5] == 0xff)
147
148#define IS_MULTICAST_ADD(_a) (*(_a) & 0x01)
149
Jeff Johnson295189b2012-06-20 16:38:30 -0700150/*--------------------------------------------------------------------------
151 Access category enum used by TL
152 - order must be kept as these values are used to setup the AC mask
153 --------------------------------------------------------------------------*/
154typedef enum
155{
156 WLANTL_AC_BK = 0,
157 WLANTL_AC_BE = 1,
158 WLANTL_AC_VI = 2,
159 WLANTL_AC_VO = 3
160}WLANTL_ACEnumType;
161
Siddharth Bhal4551b102014-10-09 21:36:36 +0530162typedef struct
163{
164 v_MACADDR_t selfMac;
165 v_MACADDR_t spoofMac;
166}WLANTL_SpoofMacAddr;
167
Jeff Johnson295189b2012-06-20 16:38:30 -0700168/*---------------------------------------------------------------------------
169 STA Type
170---------------------------------------------------------------------------*/
171typedef enum
172{
173 /* Indicates a link to an AP*/
174 WLAN_STA_INFRA = 0,
175
176 /* AD-hoc link*/
177 WLAN_STA_IBSS,
178
179 /* BT-AMP link*/
180 WLAN_STA_BT_AMP,
181
Jeff Johnson295189b2012-06-20 16:38:30 -0700182 /* SoftAP station */
183 WLAN_STA_SOFTAP,
Mohit Khanna698ba2a2012-12-04 15:08:18 -0800184
185#ifdef FEATURE_WLAN_TDLS
186 /* TDLS direct link */
187 WLAN_STA_TDLS, /* 4 */
Jeff Johnson295189b2012-06-20 16:38:30 -0700188#endif
189
Mohit Khanna698ba2a2012-12-04 15:08:18 -0800190
Jeff Johnson295189b2012-06-20 16:38:30 -0700191 /* Invalid link*/
192 WLAN_STA_MAX
193
194}WLAN_STAType;
195
196/*---------------------------------------------------------------------------
197 BAP Management frame type
198---------------------------------------------------------------------------*/
199typedef enum
200{
201 /* BT-AMP packet of type data */
202 WLANTL_BT_AMP_TYPE_DATA = 0x0001,
203
204 /* BT-AMP packet of type activity report */
205 WLANTL_BT_AMP_TYPE_AR = 0x0002,
206
207 /* BT-AMP packet of type security frame */
208 WLANTL_BT_AMP_TYPE_SEC = 0x0003,
209
210 /* BT-AMP packet of type Link Supervision request frame */
211 WLANTL_BT_AMP_TYPE_LS_REQ = 0x0004,
212
213 /* BT-AMP packet of type Link Supervision reply frame */
214 WLANTL_BT_AMP_TYPE_LS_REP = 0x0005,
215
216 /* Invalid Frame */
217 WLANTL_BAP_INVALID_FRAME
218
219} WLANTL_BAPFrameEnumType;
220
Jeff Johnson295189b2012-06-20 16:38:30 -0700221/* Type used to specify LWM threshold unit */
222typedef enum {
223 WLAN_LWM_THRESHOLD_BYTE = 0,
224
225 WLAN_LWM_THRESHOLD_PACKET
226} WLAN_LWM_Threshold_Type;
Jeff Johnson295189b2012-06-20 16:38:30 -0700227
228/*---------------------------------------------------------------------------
229 TL States
230---------------------------------------------------------------------------*/
231typedef enum
232{
233 /* Transition in this state made upon creation*/
234 WLANTL_STA_INIT = 0,
235
236 /* Transition happens after Assoc success if second level authentication
237 is needed*/
238 WLANTL_STA_CONNECTED,
239
240 /* Transition happens when second level auth is successful and keys are
241 properly installed */
242 WLANTL_STA_AUTHENTICATED,
243
244 /* Transition happens when connectivity is lost*/
245 WLANTL_STA_DISCONNECTED,
246
247 WLANTL_STA_MAX_STATE
248}WLANTL_STAStateType;
249
250
251/*---------------------------------------------------------------------------
252 STA Descriptor Type
253---------------------------------------------------------------------------*/
254typedef struct
255{
256 /*STA unique identifier, originating from HAL*/
257 v_U8_t ucSTAId;
258
259 /*STA MAC Address*/
260 v_MACADDR_t vSTAMACAddress;
261
262 /*BSSID for IBSS*/
263 v_MACADDR_t vBSSIDforIBSS;
264
265 /*Self MAC Address*/
266 v_MACADDR_t vSelfMACAddress;
267
268 /*Type of the STA*/
269 WLAN_STAType wSTAType;
270
271 /*flag for setting the state of the QOS for the link*/
272 v_U8_t ucQosEnabled;
273
274 /*enable FT in TL */
275 v_U8_t ucSwFrameTXXlation;
276 v_U8_t ucSwFrameRXXlation;
277
278 /*Flag for signaling TL if LLC header needs to be added for outgoing
279 packets*/
280 v_U8_t ucAddRmvLLC;
281
282 /*Flag for signaling if the privacy bit needs to be set*/
283 v_U8_t ucProtectedFrame;
284
285 /*DPU Signature used for unicast data - used for data caching*/
286 v_U8_t ucUcastSig;
287 /*Flag to indicate if STA is a WAPI STA*/
288 v_U8_t ucIsWapiSta;
289
Varun Reddy Yeturu5d5e2c62014-02-27 13:31:29 -0800290#ifdef FEATURE_WLAN_ESE
291 /*Flag to indicate if STA is a ESE STA*/
292 v_U8_t ucIsEseSta;
Jeff Johnson295189b2012-06-20 16:38:30 -0700293#endif
294
295 /*DPU Signature used for broadcast data - used for data caching*/
296 v_U8_t ucBcastSig;
297
298 /*Initial state at which the STA should be brought up to*/
299 WLANTL_STAStateType ucInitState;
Jeff Johnson295189b2012-06-20 16:38:30 -0700300 /* 1 means replay check is needed for the station,
301 0 means replay check is not needed for the station*/
302 v_BOOL_t ucIsReplayCheckValid;
Jeff Johnson295189b2012-06-20 16:38:30 -0700303}WLAN_STADescType;
304
305/*---------------------------------------------------------------------------
306 TL Configuration
307---------------------------------------------------------------------------*/
308typedef struct
309{
310 /*AC weight for WFQ*/
311 v_U8_t ucAcWeights[WLANTL_MAX_AC];
312
313 /*Delayed trigger frame timmer: - used by TL to send trigger frames less
314 often when it has established that the App is suspended*/
315 v_U32_t uDelayedTriggerFrmInt;
316
Jeff Johnson295189b2012-06-20 16:38:30 -0700317 /* Min Threshold for Processing Frames in TL */
318 v_U8_t uMinFramesProcThres;
Dhanashri Atred8c20a32014-01-03 17:20:55 -0800319
320 /* Re-order Aging Time */
321 v_U16_t ucReorderAgingTime[WLANTL_MAX_AC];
Jeff Johnson295189b2012-06-20 16:38:30 -0700322}WLANTL_ConfigInfoType;
323
324/*---------------------------------------------------------------------------
325 TSPEC Direction Enum Type
326---------------------------------------------------------------------------*/
327typedef enum
328{
329 /* uplink */
330 WLANTL_TX_DIR = 0,
331
332 /* downlink */
333 WLANTL_RX_DIR = 1,
334
335 /*bidirectional*/
336 WLANTL_BI_DIR = 2,
337}WLANTL_TSDirType;
338
339/*============================================================================
340 * GENERIC STRUCTURES - END
341 ============================================================================*/
342
343
344
345/*----------------------------------------------------------------------------
346 * Type Declarations
347 * -------------------------------------------------------------------------*/
348
349/*---------------------------------------------------------------------------
350 TL Error Type
351---------------------------------------------------------------------------*/
352typedef enum
353{
354 /* Generic error */
355 WLANTL_ERROR = 0,
356
357 /* No rx callback registered for data path */
358 WLANTL_NO_RX_DATA_CB,
359
360 /* No rx callback registered for management path*/
361 WLANTL_NO_RX_MGMT_CB,
362
363 /* Generic memory error*/
364 WLANTL_MEM_ERROR,
365
366 /* Bus error notified by BAL */
367 WLANTL_BUS_ERROR
368
369}WLANTL_ErrorType;
370
371/*---------------------------------------------------------------------------
372 STA priority type
373---------------------------------------------------------------------------*/
374typedef enum
375{
376 /* STA gets to tx every second round*/
377 WLANTL_STA_PRI_VERY_LOW = -2,
378
379 /* STA gets to tx every other round*/
380 WLANTL_STA_PRI_LOW = -1,
381
382 /* STA gets to tx each time */
383 WLANTL_STA_PRI_NORMAL = 0,
384
385 /* STA gets to tx twice each time*/
386 WLANTL_STA_PRI_HIGH = 1,
387
388 /* STA gets to tx three times each time*/
389 WLANTL_STA_PRI_VERY_HIGH = 2
390
391}WLANTL_STAPriorityType;
392
393/*---------------------------------------------------------------------------
394 Meta information requested from HDD by TL
395---------------------------------------------------------------------------*/
396typedef struct
397{
398 /* TID of the packet being sent */
399 v_U8_t ucTID;
400
401 /* UP of the packet being sent */
402 v_U8_t ucUP;
403
404 /* notifying TL if this is an EAPOL frame or not */
405 v_U8_t ucIsEapol;
406#ifdef FEATURE_WLAN_WAPI
407 /* notifying TL if this is a WAI frame or not */
408 v_U8_t ucIsWai;
409#endif
410 /* frame is 802.11 and it does not need translation */
411 v_U8_t ucDisableFrmXtl;
412
413 /* frame is broadcast */
414 v_U8_t ucBcast;
415
416 /* frame is multicast */
417 v_U8_t ucMcast;
418
419 /* frame type */
420 v_U8_t ucType;
421
422 /* timestamp */
423 v_U16_t usTimeStamp;
424
425 /* STA has more packets to send */
426 v_BOOL_t bMorePackets;
Abhishek Singhfa011222014-04-14 10:57:08 +0530427 /* notifying TL if this is an ARP frame or not */
428 v_U8_t ucIsArp;
Jeff Johnson295189b2012-06-20 16:38:30 -0700429}WLANTL_MetaInfoType;
430
431/*---------------------------------------------------------------------------
432 Meta information provided by TL to HDD on rx path
433---------------------------------------------------------------------------*/
434typedef struct
435{
436 /* UP of the packet being sent */
437 v_U8_t ucUP;
438 /* Address 3 Index of the received packet */
439 v_U16_t ucDesSTAId;
Shailender Karmuchi13c0d082013-03-26 14:41:39 -0700440 /*Rssi based on the received packet */
441 v_S7_t rssiAvg;
Gopichand Nakkala4a2fc1a2013-05-17 16:59:39 +0530442 #ifdef FEATURE_WLAN_TDLS
443 /* Packet received on direct link/AP link */
444 v_U8_t isStaTdls;
445 #endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700446}WLANTL_RxMetaInfoType;
447
Dino Mycle3b9536d2014-07-09 22:05:24 +0530448#ifdef WLAN_FEATURE_LINK_LAYER_STATS
449/* per interface per access category statistics */
450typedef PACKED_PRE struct PACKED_POST
451{
452 /* access category (VI, VO, BE, BK) */
453 v_U8_t ac;
454
455 /*Number of successfully transmitted unicast data pkts (ACK rcvd) */
456 v_U32_t txMpdu;
457
458 /* number of received unicast mpdu */
459 v_U32_t rxMpdu;
460
461 /* umber of succesfully transmitted multicast data packets
462 * STA case: implies ACK received from AP for the unicast packet in which mcast
463 * pkt was sent
464 */
465 v_U32_t txMcast;
466
467 /* number of received multicast data packets */
468 v_U32_t rxMcast;
469
470 /* number of received unicast a-mpdu */
471 v_U32_t rxAmpdu;
472
473 /* number of transmitted unicast a-mpdus */
474 v_U32_t txAmpdu;
475
476 /* number of data pkt losses (no ACK) */
477 v_U32_t mpduLost;
478
479 /* total number of data pkt retries */
480 v_U32_t retries;
481
482 /* number of short data pkt retries */
483 v_U32_t retriesShort;
484
485 /* number of long data pkt retries */
486 v_U32_t retriesLong;
487
488 /* data pkt min contention time (usecs) */
489 v_U32_t contentionTimeMin;
490
491 /* data pkt max contention time (usecs) */
492 v_U32_t contentionTimeMax;
493
494 /* data pkt avg contention time (usecs) */
495 v_U32_t contentionTimeAvg;
496
497 /* num of data pkts used for contention statistics */
498 v_U32_t contentionNumSamples;
499}WLANTL_AccessCategoryStatsType;
500
501/* per interface statistics */
502typedef PACKED_PRE struct PACKED_POST
503{
504 /* access point beacon received count from connected AP */
505 v_U32_t beaconRx;
506
507 /* access point mgmt frames received count from connected AP (including
508 * Beacon)
509 */
510 v_U32_t mgmtRx;
511
512 /* action frames received count */
513 v_U32_t mgmtActionRx;
514
515 /* action frames transmit count */
516 v_U32_t mgmtActionTx;
517
518 /* access Point Beacon and Management frames RSSI (averaged) */
519 v_U32_t rssiMgmt;
520
521 /* access Point Data Frames RSSI (averaged) from connected AP */
522 v_U32_t rssiData;
523
524 /* access Point ACK RSSI (averaged) from connected AP */
525 v_U32_t rssiAck;
526
527 WLANTL_AccessCategoryStatsType accessCategoryStats[WLANTL_MAX_AC];
528
529}WLANTL_InterfaceStatsType;
530
531
532#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700533
534/*---------------------------------------------------------------------------
535 Handoff support and statistics defines and enum types
536---------------------------------------------------------------------------*/
537/* Threshold crossed event type definitions */
538#define WLANTL_HO_THRESHOLD_NA 0x00
539#define WLANTL_HO_THRESHOLD_DOWN 0x01
540#define WLANTL_HO_THRESHOLD_UP 0x02
541#define WLANTL_HO_THRESHOLD_CROSS 0x04
542
543/* Realtime traffic status */
544typedef enum
545{
546 WLANTL_HO_RT_TRAFFIC_STATUS_OFF,
547 WLANTL_HO_RT_TRAFFIC_STATUS_ON
548} WLANTL_HO_RT_TRAFFIC_STATUS_TYPE;
549
550/* Non-Realtime traffic status */
551typedef enum
552{
553 WLANTL_HO_NRT_TRAFFIC_STATUS_OFF,
554 WLANTL_HO_NRT_TRAFFIC_STATUS_ON
555} WLANTL_HO_NRT_TRAFFIC_STATUS_TYPE;
556
557/* Statistics type TL supported */
558typedef enum
559{
560 WLANTL_STATIC_TX_UC_FCNT,
561 WLANTL_STATIC_TX_MC_FCNT,
562 WLANTL_STATIC_TX_BC_FCNT,
563 WLANTL_STATIC_TX_UC_BCNT,
564 WLANTL_STATIC_TX_MC_BCNT,
565 WLANTL_STATIC_TX_BC_BCNT,
566 WLANTL_STATIC_RX_UC_FCNT,
567 WLANTL_STATIC_RX_MC_FCNT,
568 WLANTL_STATIC_RX_BC_FCNT,
569 WLANTL_STATIC_RX_UC_BCNT,
570 WLANTL_STATIC_RX_MC_BCNT,
571 WLANTL_STATIC_RX_BC_BCNT,
572 WLANTL_STATIC_RX_BCNT,
573 WLANTL_STATIC_RX_BCNT_CRC_OK,
574 WLANTL_STATIC_RX_RATE
575} WLANTL_TRANSFER_STATIC_TYPE;
576
577/*---------------------------------------------------------------------------
578 Handoff support and statistics structures
579---------------------------------------------------------------------------*/
580typedef struct
581{
582 WLANTL_HO_RT_TRAFFIC_STATUS_TYPE rtTrafficStatus;
583 WLANTL_HO_NRT_TRAFFIC_STATUS_TYPE nrtTrafficStatus;
584} WLANTL_HO_TRAFFIC_STATUS_TYPE;
585
Jeff Johnson295189b2012-06-20 16:38:30 -0700586typedef tSap_SoftapStats WLANTL_TRANSFER_STA_TYPE;
Jeff Johnson295189b2012-06-20 16:38:30 -0700587
588/* Under here not public items, just use for internal */
589/* 3 SME 1 HDD */
590#define WLANTL_MAX_AVAIL_THRESHOLD 5
591#define WLANTL_HS_NUM_CLIENT 2
592#define WLANTL_SINGLE_CLNT_THRESHOLD 4
593
Mihir Shete327c2ab2014-11-13 15:17:02 +0530594typedef enum
595{
596 WLANTL_DEBUG_TX_SNAPSHOT = 1<<0,
597
598 WLANTL_DEBUG_FW_CLEANUP = 1<<1,
599}WLANTL_DebugFlags;
600
Jeff Johnson295189b2012-06-20 16:38:30 -0700601/*----------------------------------------------------------------------------
602 * TL callback types
603 *--------------------------------------------------------------------------*/
604
605/*----------------------------------------------------------------------------
606
607 DESCRIPTION
608 Type of the tx complete callback registered with TL.
609
610 TL will call this to notify the client when a transmission for a
611 packet has ended.
612
613 PARAMETERS
614
615 IN
616 pvosGCtx: pointer to the global vos context; a handle to
617 TL/HAL/PE/BAP/HDD control block can be extracted from
618 its context
619 vosDataBuff: pointer to the VOSS data buffer that was transmitted
620 wTxSTAtus: status of the transmission
621
622
623 RETURN VALUE
624 The result code associated with performing the operation
625
626----------------------------------------------------------------------------*/
627typedef VOS_STATUS (*WLANTL_TxCompCBType)( v_PVOID_t pvosGCtx,
628 vos_pkt_t* pFrameDataBuff,
629 VOS_STATUS wTxSTAtus );
630
631
632/*----------------------------------------------------------------------------
633 INTERACTION WITH HDD
634 ---------------------------------------------------------------------------*/
635/*----------------------------------------------------------------------------
636
637 DESCRIPTION
638 Type of the fetch packet callback registered with TL.
639
640 It is called by the TL when the scheduling algorithms allows for
641 transmission of another packet to the module.
642 It will be called in the context of the BAL fetch transmit packet
643 function, initiated by the bus lower layer.
644
645
646 PARAMETERS
647
648 IN
649 pvosGCtx: pointer to the global vos context; a handle
650 to TL's or HDD's control block can be extracted
651 from its context
652
653 IN/OUT
654 pucSTAId: the Id of the station for which TL is requesting a
655 packet, in case HDD does not maintain per station
656 queues it can give the next packet in its queue
657 and put in the right value for the
658 pucAC: access category requested by TL, if HDD does not have
659 packets on this AC it can choose to service another AC
660 queue in the order of priority
661
662 OUT
663 vosDataBuff: pointer to the VOSS data buffer that was transmitted
664 tlMetaInfo: meta info related to the data frame
665
666
667
668 RETURN VALUE
669 The result code associated with performing the operation
670
671----------------------------------------------------------------------------*/
672typedef VOS_STATUS (*WLANTL_STAFetchPktCBType)(
673 v_PVOID_t pvosGCtx,
674 v_U8_t* pucSTAId,
675 WLANTL_ACEnumType ucAC,
676 vos_pkt_t** vosDataBuff,
677 WLANTL_MetaInfoType* tlMetaInfo);
678
679/*----------------------------------------------------------------------------
680
681 DESCRIPTION
682 Type of the receive callback registered with TL.
683
684 TL will call this to notify the client when a packet was received
685 for a registered STA.
686
687 PARAMETERS
688
689 IN
690 pvosGCtx: pointer to the global vos context; a handle to
691 TL's or HDD's control block can be extracted from
692 its context
693 vosDataBuff: pointer to the VOSS data buffer that was received
694 (it may be a linked list)
695 ucSTAId: station id
696 pRxMetaInfo: meta info for the received packet(s)
697
698 RETURN VALUE
699 The result code associated with performing the operation
700
701----------------------------------------------------------------------------*/
702typedef VOS_STATUS (*WLANTL_STARxCBType)( v_PVOID_t pvosGCtx,
703 vos_pkt_t* vosDataBuff,
704 v_U8_t ucSTAId,
705 WLANTL_RxMetaInfoType* pRxMetaInfo);
706
707
708/*----------------------------------------------------------------------------
709 INTERACTION WITH BAP
710 ---------------------------------------------------------------------------*/
711
712/*----------------------------------------------------------------------------
713
714 DESCRIPTION
715 Type of the receive callback registered with TL for BAP.
716
717 The registered reception callback is being triggered by TL whenever a
718 frame was received and it was filtered as a non-data BT AMP packet.
719
720 PARAMETERS
721
722 IN
723 pvosGCtx: pointer to the global vos context; a handle to TL's
724 or SME's control block can be extracted from its context
725 vosDataBuff: pointer to the vOSS buffer containing the received packet;
726 no chaining will be done on this path
727 frameType: type of the frame to be indicated to BAP.
728
729 RETURN VALUE
730 The result code associated with performing the operation
731
732----------------------------------------------------------------------------*/
733typedef VOS_STATUS (*WLANTL_BAPRxCBType)( v_PVOID_t pvosGCtx,
734 vos_pkt_t* vosDataBuff,
735 WLANTL_BAPFrameEnumType frameType);
736
737/*----------------------------------------------------------------------------
738
739 DESCRIPTION
740 Callback registered with TL for BAP, this is required inorder for
741 TL to inform BAP, that the flush operation requested has been completed.
742
743 The registered reception callback is being triggered by TL whenever a
744 frame SIR_TL_HAL_FLUSH_AC_RSP is received by TL from HAL.
745
746 PARAMETERS
747
748 IN
749 pvosGCtx: pointer to the global vos context; a handle to TL's
750 or SME's control block can be extracted from its context
751 vosDataBuff: pointer to the vOSS buffer containing the received packet;
752 no chaining will be done on this path
753
754 RETURN VALUE
755 The result code associated with performing the operation
756
757----------------------------------------------------------------------------*/
758typedef VOS_STATUS (*WLANTL_FlushOpCompCBType)( v_PVOID_t pvosGCtx,
759 v_U8_t ucStaId,
760 v_U8_t ucTID,
761 v_U8_t status);
762/*----------------------------------------------------------------------------
763 INTERACTION WITH PE
764 ---------------------------------------------------------------------------*/
765
766/*----------------------------------------------------------------------------
767
768 DESCRIPTION
769 Type of the receive callback registered with TL for PE.
770
771 Upon receipt of a management frame TL will call the registered receive
772 callback and forward this frame to the interested module, in our case PE.
773
774 PARAMETERS
775
776 IN
777 pvosGCtx: pointer to the global vos context; a handle to TL's
778 control block can be extracted from its context
779 vosFrmBuf: pointer to a vOSS buffer containing the management frame
780 received
781
782 RETURN VALUE
783 The result code associated with performing the operation
784
785----------------------------------------------------------------------------*/
786typedef VOS_STATUS (*WLANTL_MgmtFrmRxCBType)( v_PVOID_t pvosGCtx,
787 v_PVOID_t vosBuff);
788
789
790/*----------------------------------------------------------------------------
791 INTERACTION WITH HAL
792 ---------------------------------------------------------------------------*/
793
794/*----------------------------------------------------------------------------
795
796 DESCRIPTION
797 Type of the fetch packet callback registered with TL.
798
799 HAL calls this API when it wishes to suspend transmission for a
800 particular STA.
801
802 PARAMETERS
803
804 IN
805 pvosGCtx: pointer to the global vos context; a handle to TL's
806 control block can be extracted from its context
807 ucSTAId: identifier of the station for which the request is made;
808 a value of 0 assumes suspend on all active station
809 pfnSuspendTxCB: pointer to the suspend result notification in case the
810 call is asynchronous
811
812 RETURN VALUE
813 The result code associated with performing the operation
814
815----------------------------------------------------------------------------*/
816typedef VOS_STATUS (*WLANTL_SuspendCBType)( v_PVOID_t pvosGCtx,
817 v_U8_t* ucSTAId,
818 VOS_STATUS vosStatus);
819
820
821/*==========================================================================
822
823 DESCRIPTION
824 Traffic status changed callback function
825 Should be registered to let client know that traffic status is changed
826 REF WLANTL_RegGetTrafficStatus
827
828 PARAMETERS
829 pAdapter Global handle pointer
830 trafficStatus RT and NRT current traffic status
831 pUserCtxt pre registered client context
832
833 RETURN VALUE
834 VOS_STATUS
835
836 SIDE EFFECTS
837 NONE
838
839============================================================================*/
840/* IF traffic status is changed, send notification to SME */
841typedef VOS_STATUS (*WLANTL_TrafficStatusChangedCBType)
842(
843 v_PVOID_t pAdapter,
844 WLANTL_HO_TRAFFIC_STATUS_TYPE trafficStatus,
845 v_PVOID_t pUserCtxt
846);
847
848/*==========================================================================
849
850 DESCRIPTION
851 RSSI threshold crossed notification callback function
852 REF WLANTL_RegRSSIIndicationCB
853
854 PARAMETERS
855 pAdapter Global handle pointer
856 rssiNotification Notification event type
857 pUserCtxt pre registered client context
858
859 RETURN VALUE
860
861 SIDE EFFECTS
862
863============================================================================*/
864/* If RSSI realm is changed, send notification to Clients, SME, HDD */
865typedef VOS_STATUS (*WLANTL_RSSICrossThresholdCBType)
866(
867 v_PVOID_t pAdapter,
868 v_U8_t rssiNotification,
Srinivasdaaec712012-12-12 15:59:44 -0800869 v_PVOID_t pUserCtxt,
870 v_S7_t avgRssi
Jeff Johnson295189b2012-06-20 16:38:30 -0700871);
872
Jeff Johnsone7245742012-09-05 17:12:55 -0700873typedef struct
874{
875 // Common for all types are requests
876 v_U16_t msgType; // message type is same as the request type
877 v_U16_t msgLen; // length of the entire request
878 v_U8_t sessionId; //sme Session Id
879 v_U8_t rssiNotification;
Srinivasdaaec712012-12-12 15:59:44 -0800880 v_U8_t avgRssi;
Jeff Johnsone7245742012-09-05 17:12:55 -0700881 v_PVOID_t tlCallback;
882 v_PVOID_t pAdapter;
883 v_PVOID_t pUserCtxt;
884} WLANTL_TlIndicationReq;
885
Jeff Johnson295189b2012-06-20 16:38:30 -0700886/*----------------------------------------------------------------------------
887 * Function Declarations and Documentation
888 * -------------------------------------------------------------------------*/
889
890/*==========================================================================
891
892 FUNCTION WLANTL_Open
893
894 DESCRIPTION
895 Called by HDD at driver initialization. TL will initialize all its
896 internal resources and will wait for the call to start to register
897 with the other modules.
898
899 DEPENDENCIES
900
901 PARAMETERS
902
903 IN
904 pvosGCtx: pointer to the global vos context; a handle to TL's
905 control block can be extracted from its context
906 pTLConfig: TL Configuration
907
908 RETURN VALUE
909 The result code associated with performing the operation
910
911 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
912 fault
913 VOS_STATUS_SUCCESS: Everything is good :)
914
915 SIDE EFFECTS
916
917============================================================================*/
918VOS_STATUS
919WLANTL_Open
920(
921 v_PVOID_t pvosGCtx,
922 WLANTL_ConfigInfoType* pTLConfig
923);
924
925/*==========================================================================
926
927 FUNCTION WLANTL_Start
928
929 DESCRIPTION
930 Called by HDD as part of the overall start procedure. TL will use this
931 call to register with BAL as a transport layer entity.
932
933 DEPENDENCIES
934
935 PARAMETERS
936
937 IN
938 pvosGCtx: pointer to the global vos context; a handle to TL's
939 control block can be extracted from its context
940
941 RETURN VALUE
942 The result code associated with performing the operation
943
944 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
945 fault
946 VOS_STATUS_SUCCESS: Everything is good :)
947
948 Other codes can be returned as a result of a BAL failure; see BAL API
949 for more info
950
951 SIDE EFFECTS
952
953============================================================================*/
954VOS_STATUS
955WLANTL_Start
956(
957 v_PVOID_t pvosGCtx
958);
959
960/*==========================================================================
961
962 FUNCTION WLANTL_Stop
963
964 DESCRIPTION
965 Called by HDD to stop operation in TL, before close. TL will suspend all
966 frame transfer operation and will wait for the close request to clean up
967 its resources.
968
969 DEPENDENCIES
970
971 PARAMETERS
972
973 IN
974 pvosGCtx: pointer to the global vos context; a handle to TL's
975 control block can be extracted from its context
976
977 RETURN VALUE
978 The result code associated with performing the operation
979
980 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
981 fault
982 VOS_STATUS_SUCCESS: Everything is good :)
983
984 SIDE EFFECTS
985
986============================================================================*/
987VOS_STATUS
988WLANTL_Stop
989(
990 v_PVOID_t pvosGCtx
991);
992
993/*==========================================================================
994
995 FUNCTION WLANTL_Close
996
997 DESCRIPTION
998 Called by HDD during general driver close procedure. TL will clean up
999 all the internal resources.
1000
1001 DEPENDENCIES
1002
1003 PARAMETERS
1004
1005 IN
1006 pvosGCtx: pointer to the global vos context; a handle to TL's
1007 control block can be extracted from its context
1008
1009 RETURN VALUE
1010 The result code associated with performing the operation
1011
1012 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a page
1013 fault
1014 VOS_STATUS_SUCCESS: Everything is good :)
1015
1016 SIDE EFFECTS
1017
1018============================================================================*/
1019VOS_STATUS
1020WLANTL_Close
1021(
1022 v_PVOID_t pvosGCtx
1023);
1024
Mihir Shete2ab1d492014-06-04 14:21:05 +05301025/*===========================================================================
1026
1027 FUNCTION WLANTL_StartForwarding
1028
1029 DESCRIPTION
1030
1031 This function is used to ask serialization through TX thread of the
1032 cached frame forwarding (if statation has been registered in the mean while)
1033 or flushing (if station has not been registered by the time)
1034
1035 In case of forwarding, upper layer is only required to call WLANTL_RegisterSTAClient()
1036 and doesn't need to call this function explicitly. TL will handle this inside
1037 WLANTL_RegisterSTAClient().
1038
1039 In case of flushing, upper layer is required to call this function explicitly
1040
1041 DEPENDENCIES
1042
1043 TL must have been initialized before this gets called.
1044
1045
1046 PARAMETERS
1047
1048 ucSTAId: station id
1049
1050 RETURN VALUE
1051
1052 The result code associated with performing the operation
1053 Please check return values of vos_tx_mq_serialize.
1054
1055 SIDE EFFECTS
1056 If TL was asked to perform WLANTL_CacheSTAFrame() in WLANTL_RxFrames(),
1057 either WLANTL_RegisterSTAClient() or this function must be called
1058 within reasonable time. Otherwise, TL will keep cached vos buffer until
1059 one of this function is called, and may end up with system buffer exhasution.
1060
1061 It's an upper layer's responsibility to call this function in case of
1062 flushing
1063
1064============================================================================*/
1065VOS_STATUS
1066WLANTL_StartForwarding
1067(
1068 v_U8_t ucSTAId,
1069 v_U8_t ucUcastSig,
1070 v_U8_t ucBcastSig
1071);
Jeff Johnson295189b2012-06-20 16:38:30 -07001072
1073/*----------------------------------------------------------------------------
1074 INTERACTION WITH HDD
1075 ---------------------------------------------------------------------------*/
1076/*==========================================================================
1077
1078 FUNCTION WLANTL_ConfigureSwFrameTXXlationForAll
1079
1080 DESCRIPTION
1081 Function to disable/enable frame translation for all association stations.
1082
1083 DEPENDENCIES
1084
1085 PARAMETERS
1086 IN
1087 pvosGCtx: VOS context
1088 EnableFrameXlation TRUE means enable SW translation for all stations.
1089 .
1090
1091 RETURN VALUE
1092
1093 void.
1094
1095============================================================================*/
1096void
1097WLANTL_ConfigureSwFrameTXXlationForAll
1098(
1099 v_PVOID_t pvosGCtx,
1100 v_BOOL_t enableFrameXlation
1101);
1102
1103/*===========================================================================
1104
1105 FUNCTION WLANTL_RegisterSTAClient
1106
1107 DESCRIPTION
1108
1109 This function is used by HDD to register as a client for data services
1110 with TL. HDD will call this API for each new station that it adds,
1111 thus having the flexibility of registering different callback for each
1112 STA it services.
1113
1114 DEPENDENCIES
1115
1116 TL must have been initialized before this gets called.
1117
1118 Restriction:
1119 Main thread will have higher priority that Tx and Rx threads thus
1120 guaranteeing that a station will be added before any data can be
1121 received for it. (This enables TL to be lock free)
1122
1123 PARAMETERS
1124
1125 pvosGCtx: pointer to the global vos context; a handle to TL's
1126 control block can be extracted from its context
1127 pfnStARx: function pointer to the receive packet handler from HDD
1128 pfnSTATxComp: function pointer to the transmit complete confirmation
1129 handler from HDD
1130 pfnSTAFetchPkt: function pointer to the packet retrieval routine in HDD
1131 wSTADescType: STA Descriptor, contains information related to the
1132 new added STA
1133
1134 RETURN VALUE
1135
1136 The result code associated with performing the operation
1137
1138 VOS_STATUS_E_INVAL: Input parameters are invalid
1139 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1140 TL cb is NULL ; access would cause a page fault
1141 VOS_STATUS_E_EXISTS: Station was already registered
1142 VOS_STATUS_SUCCESS: Everything is good :)
1143
1144 SIDE EFFECTS
1145
1146============================================================================*/
1147VOS_STATUS
1148WLANTL_RegisterSTAClient
1149(
1150 v_PVOID_t pvosGCtx,
1151 WLANTL_STARxCBType pfnSTARx,
1152 WLANTL_TxCompCBType pfnSTATxComp,
1153 WLANTL_STAFetchPktCBType pfnSTAFetchPkt,
1154 WLAN_STADescType* wSTADescType ,
1155 v_S7_t rssi
1156);
1157
1158/*===========================================================================
1159
Agarwal Ashish16020c42014-12-29 22:01:11 +05301160 FUNCTION WLANTL_UpdateTdlsSTAClient
1161
1162 DESCRIPTION
1163
1164 HDD will call this API when ENABLE_LINK happens and HDD want to
1165 register QoS or other params for TDLS peers.
1166
1167 DEPENDENCIES
1168
1169 A station must have been registered before the WMM/QOS registration is
1170 called.
1171
1172 PARAMETERS
1173
1174 pvosGCtx: pointer to the global vos context; a handle to TL's
1175 control block can be extracted from its context
1176 wSTADescType: STA Descriptor, contains information related to the
1177 new added STA
1178
1179 RETURN VALUE
1180
1181 The result code associated with performing the operation
1182
1183 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1184 TL cb is NULL ; access would cause a page fault
1185 VOS_STATUS_E_EXISTS: Station was not registered
1186 VOS_STATUS_SUCCESS: Everything is good :)
1187
1188 SIDE EFFECTS
1189
1190============================================================================*/
1191
1192VOS_STATUS
1193WLANTL_UpdateTdlsSTAClient
1194(
1195 v_PVOID_t pvosGCtx,
1196 WLAN_STADescType* wSTADescType
1197);
1198
1199
1200/*===========================================================================
1201
Jeff Johnson295189b2012-06-20 16:38:30 -07001202 FUNCTION WLANTL_ClearSTAClient
1203
1204 DESCRIPTION
1205
1206 HDD will call this API when it no longer needs data services for the
1207 particular station.
1208
1209 DEPENDENCIES
1210
1211 A station must have been registered before the clear registration is
1212 called.
1213
1214 PARAMETERS
1215
1216 pvosGCtx: pointer to the global vos context; a handle to TL's
1217 control block can be extracted from its context
1218 ucSTAId: identifier for the STA to be cleared
1219
1220 RETURN VALUE
1221
1222 The result code associated with performing the operation
1223
1224 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1225 TL cb is NULL ; access would cause a page fault
1226 VOS_STATUS_E_EXISTS: Station was not registered
1227 VOS_STATUS_SUCCESS: Everything is good :)
1228
1229 SIDE EFFECTS
1230
1231============================================================================*/
1232VOS_STATUS
1233WLANTL_ClearSTAClient
1234(
1235 v_PVOID_t pvosGCtx,
1236 v_U8_t ucSTAId
1237);
1238
Dino Mycle3b9536d2014-07-09 22:05:24 +05301239#ifdef WLAN_FEATURE_LINK_LAYER_STATS
1240/*==========================================================================
1241
1242 FUNCTION WLANTL_CollectStats
1243
1244 DESCRIPTION
1245 Utility function used by TL to send the statitics
1246
1247 DEPENDENCIES
1248
1249
1250 PARAMETERS
1251
1252 IN
1253
1254 ucSTAId: station for which the statistics need to collected
1255
1256 vosDataBuff: it will contain the pointer to the corresponding
1257 structure
1258
1259 RETURN VALUE
1260 The result code associated with performing the operation
1261
1262 VOS_STATUS_E_INVAL: Input parameters are invalid
1263 VOS_STATUS_SUCCESS: Everything is good :)
1264
1265 SIDE EFFECTS
1266
1267============================================================================*/
1268VOS_STATUS
1269WLANTL_CollectInterfaceStats
1270(
1271 v_PVOID_t pvosGCtx,
1272 v_U8_t ucSTAId,
1273 WLANTL_InterfaceStatsType *vosDataBuff
1274);
Srinivas Dasari98947432014-11-07 19:41:24 +05301275
1276/*==========================================================================
1277
1278 FUNCTION WLANTL_ClearInterfaceStats
1279
1280 DESCRIPTION
1281 Utility function used by TL to clear the statitics
1282
1283 DEPENDENCIES
1284
1285
1286 PARAMETERS
1287
1288 IN
1289
1290 ucSTAId: station for which the statistics need to collected
1291
1292 RETURN VALUE
1293 The result code associated with performing the operation
1294
1295 VOS_STATUS_E_INVAL: Input parameters are invalid
1296 VOS_STATUS_SUCCESS: Everything is good :)
1297
1298 SIDE EFFECTS
1299
1300============================================================================*/
1301VOS_STATUS
1302WLANTL_ClearInterfaceStats
1303(
1304 v_PVOID_t pvosGCtx,
1305 v_U8_t ucSTAId,
1306 v_U8_t statsClearReqMask
1307);
Dino Mycle3b9536d2014-07-09 22:05:24 +05301308#endif
1309
Jeff Johnson295189b2012-06-20 16:38:30 -07001310/*===========================================================================
1311
1312 FUNCTION WLANTL_ChangeSTAState
1313
1314 DESCRIPTION
1315
1316 HDD will make this notification whenever a change occurs in the
1317 connectivity state of a particular STA.
1318
1319 DEPENDENCIES
1320
1321 A station must have been registered before the change state can be
1322 called.
1323
1324 RESTRICTION: A station is being notified as authenticated before the
1325 keys are installed in HW. This way if a frame is received
1326 before the keys are installed DPU will drop that frame.
1327
1328 Main thread has higher priority that Tx and Rx threads thus guaranteeing
1329 the following:
1330 - a station will be in assoc state in TL before TL receives any data
1331 for it
1332
1333 PARAMETERS
1334
1335 pvosGCtx: pointer to the global vos context; a handle to TL's
1336 control block can be extracted from its context
1337 ucSTAId: identifier for the STA that is pending transmission
1338 tlSTAState: the new state of the connection to the given station
1339
1340
1341 RETURN VALUE
1342
1343 The result code associated with performing the operation
1344
1345 VOS_STATUS_E_INVAL: Input parameters are invalid
1346 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1347 TL cb is NULL ; access would cause a page fault
1348 VOS_STATUS_E_EXISTS: Station was not registered
1349 VOS_STATUS_SUCCESS: Everything is good :)
1350
1351 SIDE EFFECTS
1352
1353============================================================================*/
1354VOS_STATUS
1355WLANTL_ChangeSTAState
1356(
1357 v_PVOID_t pvosGCtx,
1358 v_U8_t ucSTAId,
1359 WLANTL_STAStateType tlSTAState
1360);
1361
1362/*===========================================================================
1363
Gopichand Nakkala8b54e912013-03-11 10:44:21 +05301364 FUNCTION WLANTL_STAPtkInstalled
1365
1366 DESCRIPTION
1367
1368 HDD will make this notification whenever PTK is installed for the STA
1369
1370 DEPENDENCIES
1371
1372 A station must have been registered before the change state can be
1373 called.
1374
1375 PARAMETERS
1376
1377 pvosGCtx: pointer to the global vos context; a handle to TL's
1378 control block can be extracted from its context
1379 ucSTAId: identifier for the STA for which Pairwise key is
1380 installed
1381
1382 RETURN VALUE
1383
1384 The result code associated with performing the operation
1385
1386 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1387 TL cb is NULL ; access would cause a page fault
1388 VOS_STATUS_E_EXISTS: Station was not registered
1389 VOS_STATUS_SUCCESS: Everything is good :)
1390
1391 SIDE EFFECTS
1392
1393============================================================================*/
1394VOS_STATUS
1395WLANTL_STAPtkInstalled
1396(
1397 v_PVOID_t pvosGCtx,
1398 v_U8_t ucSTAId
1399);
1400/*===========================================================================
1401
Madan Mohan Koyyalamudifc1d1fe2012-10-18 15:07:12 -07001402 FUNCTION WLANTL_GetSTAState
1403
1404 DESCRIPTION
1405
1406 Returns connectivity state of a particular STA.
1407
1408 DEPENDENCIES
1409
1410 A station must have been registered before its state can be retrieved.
1411
1412
1413 PARAMETERS
1414
1415 IN
1416 pvosGCtx: pointer to the global vos context; a handle to TL's
1417 control block can be extracted from its context
1418 ucSTAId: identifier of the station
1419
1420 OUT
1421 ptlSTAState: the current state of the connection to the given station
1422
1423
1424 RETURN VALUE
1425
1426 The result code associated with performing the operation
1427
1428 VOS_STATUS_E_INVAL: Input parameters are invalid
1429 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
1430 TL cb is NULL ; access would cause a page fault
1431 VOS_STATUS_E_EXISTS: Station was not registered
1432 VOS_STATUS_SUCCESS: Everything is good :)
1433
1434 SIDE EFFECTS
1435
1436============================================================================*/
1437VOS_STATUS
1438WLANTL_GetSTAState
1439(
1440 v_PVOID_t pvosGCtx,
1441 v_U8_t ucSTAId,
1442 WLANTL_STAStateType *ptlSTAState
1443);
1444
1445/*===========================================================================
1446
Jeff Johnson295189b2012-06-20 16:38:30 -07001447 FUNCTION WLANTL_STAPktPending
1448
1449 DESCRIPTION
1450
1451 HDD will call this API when a packet is pending transmission in its
1452 queues.
1453
1454 DEPENDENCIES
1455
1456 A station must have been registered before the packet pending
1457 notification can be sent.
1458
1459 RESTRICTION: TL will not count packets for pending notification.
1460 HDD is expected to send the notification only when
1461 non-empty event gets triggered. Worst case scenario
1462 is that TL might end up making a call when Hdds
1463 queues are actually empty.
1464
1465 PARAMETERS
1466
1467 pvosGCtx: pointer to the global vos context; a handle to TL's
1468 control block can be extracted from its context
1469 ucSTAId: identifier for the STA that is pending transmission
1470 ucAC: access category of the non-empty queue
1471
1472 RETURN VALUE
1473
1474 The result code associated with performing the operation
1475
1476 VOS_STATUS_E_INVAL: Input parameters are invalid
1477 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1478 to TL cb is NULL ; access would cause a page fault
1479 VOS_STATUS_E_EXISTS: Station was not registered
1480 VOS_STATUS_SUCCESS: Everything is good :)
1481
1482 SIDE EFFECTS
1483
1484============================================================================*/
1485VOS_STATUS
1486WLANTL_STAPktPending
1487(
1488 v_PVOID_t pvosGCtx,
1489 v_U8_t ucSTAId,
1490 WLANTL_ACEnumType ucAc
1491);
1492
1493/*==========================================================================
1494
1495 FUNCTION WLANTL_SetSTAPriority
1496
1497 DESCRIPTION
1498
1499 TL exposes this API to allow upper layers a rough control over the
1500 priority of transmission for a given station when supporting multiple
1501 connections.
1502
1503 DEPENDENCIES
1504
1505 A station must have been registered before the change in priority can be
1506 called.
1507
1508 PARAMETERS
1509
1510 pvosGCtx: pointer to the global vos context; a handle to TL's
1511 control block can be extracted from its context
1512 ucSTAId: identifier for the STA that has to change priority
1513
1514 RETURN VALUE
1515
1516 The result code associated with performing the operation
1517
1518 VOS_STATUS_E_INVAL: Input parameters are invalid
1519 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1520 to TL cb is NULL ; access would cause a page fault
1521 VOS_STATUS_E_EXISTS: Station was not registered
1522 VOS_STATUS_SUCCESS: Everything is good :)
1523
1524 SIDE EFFECTS
1525
1526============================================================================*/
1527VOS_STATUS
1528WLANTL_SetSTAPriority
1529(
1530 v_PVOID_t pvosGCtx,
1531 v_U8_t ucSTAId,
1532 WLANTL_STAPriorityType tlSTAPri
1533);
1534
1535/*----------------------------------------------------------------------------
1536 INTERACTION WITH BAP
1537 ---------------------------------------------------------------------------*/
1538
1539/*==========================================================================
1540
1541 FUNCTION WLANTL_RegisterBAPClient
1542
1543 DESCRIPTION
1544 Called by SME to register itself as client for non-data BT-AMP packets.
1545
1546 DEPENDENCIES
1547 TL must be initialized before this function can be called.
1548
1549 PARAMETERS
1550
1551 IN
1552 pvosGCtx: pointer to the global vos context; a handle to TL's
1553 or SME's control block can be extracted from its context
1554 pfnTlBAPRxFrm: pointer to the receive processing routine for non-data
1555 BT-AMP packets
1556 pfnFlushOpCompleteCb:
1557 pointer to the function that will inform BAP that the
1558 flush operation is complete.
1559
1560 RETURN VALUE
1561
1562 The result code associated with performing the operation
1563
1564 VOS_STATUS_E_INVAL: Input parameters are invalid
1565 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1566 to TL cb is NULL ; access would cause a page fault
1567 VOS_STATUS_E_EXISTS: BAL client was already registered
1568 VOS_STATUS_SUCCESS: Everything is good :)
1569
1570 SIDE EFFECTS
1571
1572============================================================================*/
1573VOS_STATUS
1574WLANTL_RegisterBAPClient
1575(
1576 v_PVOID_t pvosGCtx,
1577 WLANTL_BAPRxCBType pfnTlBAPRx,
1578 WLANTL_FlushOpCompCBType pfnFlushOpCompleteCb
1579);
1580
1581
1582/*==========================================================================
1583
1584 FUNCTION WLANTL_TxBAPFrm
1585
1586 DESCRIPTION
1587 BAP calls this when it wants to send a frame to the module
1588
1589 DEPENDENCIES
1590 BAP must be registered with TL before this function can be called.
1591
1592 RESTRICTION: BAP CANNOT push any packets to TL until it did not receive
1593 a tx complete from the previous packet, that means BAP
1594 sends one packet, wait for tx complete and then
1595 sends another one
1596
1597 If BAP sends another packet before TL manages to process the
1598 previously sent packet call will end in failure
1599
1600 PARAMETERS
1601
1602 IN
1603 pvosGCtx: pointer to the global vos context; a handle to TL's
1604 or BAP's control block can be extracted from its context
1605 vosDataBuff: pointer to the vOSS buffer containing the packet to be
1606 transmitted
1607 pMetaInfo: meta information about the packet
1608 pfnTlBAPTxComp: pointer to a transmit complete routine for notifying
1609 the result of the operation over the bus
1610
1611 RETURN VALUE
1612 The result code associated with performing the operation
1613
1614 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1615 page fault
1616 VOS_STATUS_E_EXISTS: BAL client was not yet registered
1617 VOS_STATUS_E_BUSY: The previous BT-AMP packet was not yet transmitted
1618 VOS_STATUS_SUCCESS: Everything is good :)
1619
1620 Other failure messages may be returned from the BD header handling
1621 routines, please check apropriate API for more info.
1622
1623 SIDE EFFECTS
1624
1625============================================================================*/
1626VOS_STATUS
1627WLANTL_TxBAPFrm
1628(
1629 v_PVOID_t pvosGCtx,
1630 vos_pkt_t* vosDataBuff,
1631 WLANTL_MetaInfoType* pMetaInfo,
1632 WLANTL_TxCompCBType pfnTlBAPTxComp
1633);
1634
1635
1636/*----------------------------------------------------------------------------
1637 INTERACTION WITH SME
1638 ---------------------------------------------------------------------------*/
1639
1640/*==========================================================================
1641
1642 FUNCTION WLANTL_GetRssi
1643
1644 DESCRIPTION
1645 TL will extract the RSSI information from every data packet from the
1646 ongoing traffic and will store it. It will provide the result to SME
1647 upon request.
1648
1649 DEPENDENCIES
1650
1651 WARNING: the read and write of this value will not be protected
1652 by locks, therefore the information obtained after a read
1653 might not always be consistent.
1654
1655 PARAMETERS
1656
1657 IN
1658 pvosGCtx: pointer to the global vos context; a handle to TL's
1659 or SME's control block can be extracted from its context
1660 ucSTAId: station identifier for the requested value
1661
1662 OUT
1663 puRssi: the average value of the RSSI
1664
1665
1666 RETURN VALUE
1667 The result code associated with performing the operation
1668
1669 VOS_STATUS_E_INVAL: Input parameters are invalid
1670 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1671 to TL cb is NULL ; access would cause a page fault
1672 VOS_STATUS_E_EXISTS: STA was not yet registered
1673 VOS_STATUS_SUCCESS: Everything is good :)
1674
1675 SIDE EFFECTS
1676
1677============================================================================*/
1678VOS_STATUS
1679WLANTL_GetRssi
1680(
1681 v_PVOID_t pvosGCtx,
1682 v_U8_t ucSTAId,
1683 v_S7_t* puRssi
1684);
1685
1686/*==========================================================================
1687
Madan Mohan Koyyalamudid9383fd2013-08-13 09:27:30 +05301688 FUNCTION WLANTL_GetSnr
1689
1690 DESCRIPTION
1691 TL will extract the SNR information from every data packet from the
1692 ongoing traffic and will store it. It will provide the result to SME
1693 upon request.
1694
1695 DEPENDENCIES
1696
1697 WARNING: the read and write of this value will not be protected
1698 by locks, therefore the information obtained after a read
1699 might not always be consistent.
1700
1701 PARAMETERS
1702
1703 IN
1704 pvosGCtx: pointer to the global vos context; a handle to TL's
1705 or SME's control block can be extracted from its context
1706 ucSTAId: station identifier for the requested value
1707
1708 OUT
1709 puSnr: the average value of the SNR
1710
1711
1712 RETURN VALUE
1713 The result code associated with performing the operation
1714
1715 VOS_STATUS_E_INVAL: Input parameters are invalid
1716 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1717 to TL cb is NULL ; access would cause a page fault
1718 VOS_STATUS_E_EXISTS: STA was not yet registered
1719 VOS_STATUS_SUCCESS: Everything is good :)
1720
1721 SIDE EFFECTS
1722
1723============================================================================*/
1724VOS_STATUS
1725WLANTL_GetSnr
1726(
1727 tANI_U8 ucSTAId,
1728 tANI_S8* pSnr
1729);
1730
1731/*==========================================================================
1732
Jeff Johnson295189b2012-06-20 16:38:30 -07001733 FUNCTION WLANTL_GetLinkQuality
1734
1735 DESCRIPTION
1736 TL will extract the LinkQuality information from every data packet from the
1737 ongoing traffic and will store it. It will provide the result to SME
1738 upon request.
1739
1740 DEPENDENCIES
1741
1742 WARNING: the read and write of this value will not be protected
1743 by locks, therefore the information obtained after a read
1744 might not always be consistent.
1745
1746 PARAMETERS
1747
1748 IN
1749 pvosGCtx: pointer to the global vos context; a handle to TL's
1750 or SME's control block can be extracted from its context
1751 ucSTAId: station identifier for the requested value
1752
1753 OUT
1754 puLinkQuality: the average value of the LinkQuality
1755
1756
1757 RETURN VALUE
1758 The result code associated with performing the operation
1759
1760 VOS_STATUS_E_INVAL: Input parameters are invalid
1761 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
1762 to TL cb is NULL ; access would cause a page fault
1763 VOS_STATUS_E_EXISTS: STA was not yet registered
1764 VOS_STATUS_SUCCESS: Everything is good :)
1765
1766 SIDE EFFECTS
1767
1768============================================================================*/
1769VOS_STATUS
1770WLANTL_GetLinkQuality
1771(
1772 v_PVOID_t pvosGCtx,
1773 v_U8_t ucSTAId,
1774 v_U32_t* puLinkQuality
1775);
1776
1777/*==========================================================================
1778
1779 FUNCTION WLANTL_FlushStaTID
1780
1781 DESCRIPTION
1782 TL provides this API as an interface to SME (BAP) layer. TL inturn posts a
1783 message to HAL. This API is called by the SME inorder to perform a flush
1784 operation.
1785
1786 DEPENDENCIES
1787
1788 PARAMETERS
1789
1790 IN
1791 pvosGCtx: pointer to the global vos context; a handle to TL's
1792 or SME's control block can be extracted from its context
1793 ucSTAId: station identifier for the requested value
1794 ucTid: Tspec ID for the new BA session
1795
1796 OUT
1797 The response for this post is received in the main thread, via a response
1798 message from HAL to TL.
1799
1800 RETURN VALUE
1801 VOS_STATUS_SUCCESS: Everything is good :)
1802
1803 SIDE EFFECTS
1804============================================================================*/
1805VOS_STATUS
1806WLANTL_FlushStaTID
1807(
1808 v_PVOID_t pvosGCtx,
1809 v_U8_t ucSTAId,
1810 v_U8_t ucTid
1811);
1812
1813/*----------------------------------------------------------------------------
1814 INTERACTION WITH PE
1815 ---------------------------------------------------------------------------*/
1816
1817/*==========================================================================
1818
Siddharth Bhal4551b102014-10-09 21:36:36 +05301819 FUNCTION WLANTL_updateSpoofMacAddr
1820
1821 DESCRIPTION
1822 Called by HDD to update macaddr
1823
1824 DEPENDENCIES
1825 TL must be initialized before this API can be called.
1826
1827 PARAMETERS
1828
1829 IN
1830 pvosGCtx: pointer to the global vos context; a handle to
1831 TL's control block can be extracted from its context
1832 spoofMacAddr: spoofed mac adderess
1833 selfMacAddr: self Mac Address
1834
1835 RETURN VALUE
1836 The result code associated with performing the operation
1837
1838 VOS_STATUS_E_INVAL: Input parameters are invalid
1839 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1840 page fault
1841 VOS_STATUS_SUCCESS: Everything is good :)
1842
1843 SIDE EFFECTS
1844
1845============================================================================*/
1846VOS_STATUS
1847WLANTL_updateSpoofMacAddr
1848(
1849 v_PVOID_t pvosGCtx,
1850 v_MACADDR_t* spoofMacAddr,
1851 v_MACADDR_t* selfMacAddr
1852);
1853/*==========================================================================
1854
Jeff Johnson295189b2012-06-20 16:38:30 -07001855 FUNCTION WLANTL_RegisterMgmtFrmClient
1856
1857 DESCRIPTION
1858 Called by PE to register as a client for management frames delivery.
1859
1860 DEPENDENCIES
1861 TL must be initialized before this API can be called.
1862
1863 PARAMETERS
1864
1865 IN
1866 pvosGCtx: pointer to the global vos context; a handle to
1867 TL's control block can be extracted from its context
1868 pfnTlMgmtFrmRx: pointer to the receive processing routine for
1869 management frames
1870
1871 RETURN VALUE
1872 The result code associated with performing the operation
1873
1874 VOS_STATUS_E_INVAL: Input parameters are invalid
1875 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1876 page fault
1877 VOS_STATUS_E_EXISTS: Mgmt Frame client was already registered
1878 VOS_STATUS_SUCCESS: Everything is good :)
1879
1880 SIDE EFFECTS
1881
1882============================================================================*/
1883VOS_STATUS
1884WLANTL_RegisterMgmtFrmClient
1885(
1886 v_PVOID_t pvosGCtx,
1887 WLANTL_MgmtFrmRxCBType pfnTlMgmtFrmRx
1888);
1889
1890/*==========================================================================
1891
1892 FUNCTION WLANTL_DeRegisterMgmtFrmClient
1893
1894 DESCRIPTION
1895 Called by PE to deregister as a client for management frames delivery.
1896
1897 DEPENDENCIES
1898 TL must be initialized before this API can be called.
1899
1900 PARAMETERS
1901
1902 IN
1903 pvosGCtx: pointer to the global vos context; a handle to
1904 TL's control block can be extracted from its context
1905 RETURN VALUE
1906 The result code associated with performing the operation
1907
1908 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1909 page fault
1910 VOS_STATUS_E_EXISTS: Mgmt Frame client was never registered
1911 VOS_STATUS_SUCCESS: Everything is good :)
1912
1913 SIDE EFFECTS
1914
1915============================================================================*/
1916VOS_STATUS
1917WLANTL_DeRegisterMgmtFrmClient
1918(
1919 v_PVOID_t pvosGCtx
1920);
1921
1922/*==========================================================================
1923
1924 FUNCTION WLANTL_TxMgmtFrm
1925
1926 DESCRIPTION
1927 Called by PE when it want to send out a management frame.
1928 HAL will also use this API for the few frames it sends out, they are not
1929 management frames howevere it is accepted that an exception will be
1930 allowed ONLY for the usage of HAL.
1931 Generic data frames SHOULD NOT travel through this function.
1932
1933 DEPENDENCIES
1934 TL must be initialized before this API can be called.
1935
1936 RESTRICTION: If PE sends another packet before TL manages to process the
1937 previously sent packet call will end in failure
1938
1939 Frames comming through here must be 802.11 frames, frame
1940 translation in UMA will be automatically disabled.
1941
1942 PARAMETERS
1943
1944 IN
1945 pvosGCtx: pointer to the global vos context;a handle to TL's
1946 control block can be extracted from its context
1947 vosFrmBuf: pointer to a vOSS buffer containing the management
1948 frame to be transmitted
1949 usFrmLen: the length of the frame to be transmitted; information
1950 is already included in the vOSS buffer
1951 wFrmType: the type of the frame being transmitted
1952 tid: tid used to transmit this frame
1953 pfnCompTxFunc: function pointer to the transmit complete routine
1954 pvBDHeader: pointer to the BD header, if NULL it means it was not
1955 yet constructed and it lies within TL's responsibility
1956 to do so; if not NULL it is expected that it was
1957 already packed inside the vos packet
1958 ucAckResponse: flag notifying it an interrupt is needed for the
1959 acknowledgement received when the frame is sent out
1960 the air and ; the interrupt will be processed by HAL,
1961 only one such frame can be pending in the system at
1962 one time.
1963
1964
1965 RETURN VALUE
1966 The result code associated with performing the operation
1967
1968 VOS_STATUS_E_INVAL: Input parameters are invalid
1969 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
1970 page fault
1971 VOS_STATUS_E_EXISTS: Mgmt Frame client was not yet registered
1972 VOS_STATUS_E_BUSY: The previous Mgmt packet was not yet transmitted
1973 VOS_STATUS_SUCCESS: Everything is good :)
1974
1975 Other failure messages may be returned from the BD header handling
1976 routines, please check apropriate API for more info.
1977
1978 SIDE EFFECTS
1979
1980============================================================================*/
1981VOS_STATUS
1982WLANTL_TxMgmtFrm
1983(
1984 v_PVOID_t pvosGCtx,
1985 vos_pkt_t* vosFrmBuf,
1986 v_U16_t usFrmLen,
1987 v_U8_t ucFrmType,
1988 v_U8_t tid,
1989 WLANTL_TxCompCBType pfnCompTxFunc,
1990 v_PVOID_t voosBDHeader,
Kanchanapally, Vidyullathaf9426e52013-12-24 17:28:54 +05301991 v_U32_t ucAckResponse
Jeff Johnson295189b2012-06-20 16:38:30 -07001992);
1993
1994
1995/*----------------------------------------------------------------------------
1996 INTERACTION WITH HAL
1997 ---------------------------------------------------------------------------*/
1998
1999/*==========================================================================
2000
2001 FUNCTION WLANTL_ResetNotification
2002
2003 DESCRIPTION
2004 HAL notifies TL when the module is being reset.
2005 Currently not used.
2006
2007 DEPENDENCIES
2008
2009 PARAMETERS
2010
2011 IN
2012 pvosGCtx: pointer to the global vos context; a handle to TL's
2013 control block can be extracted from its context
2014
2015
2016 RETURN VALUE
2017 The result code associated with performing the operation
2018
2019 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
2020 page fault
2021 VOS_STATUS_SUCCESS: Everything is good :)
2022
2023 SIDE EFFECTS
2024
2025============================================================================*/
2026VOS_STATUS
2027WLANTL_ResetNotification
2028(
2029 v_PVOID_t pvosGCtx
2030);
2031
2032/*==========================================================================
2033
2034 FUNCTION WLANTL_SuspendDataTx
2035
2036 DESCRIPTION
2037 HAL calls this API when it wishes to suspend transmission for a
2038 particular STA.
2039
2040 DEPENDENCIES
2041 The STA for which the request is made must be first registered with
2042 TL by HDD.
2043
2044 RESTRICTION: In case of a suspend, the flag write and read will not be
2045 locked: worst case scenario one more packet can get
2046 through before the flag gets updated (we can make this
2047 write atomic as well to guarantee consistency)
2048
2049 PARAMETERS
2050
2051 IN
2052 pvosGCtx: pointer to the global vos context; a handle to TL's
2053 control block can be extracted from its context
2054 pucSTAId: identifier of the station for which the request is made;
2055 a value of NULL assumes suspend on all active station
2056 pfnSuspendTxCB: pointer to the suspend result notification in case the
2057 call is asynchronous
2058
2059
2060 RETURN VALUE
2061 The result code associated with performing the operation
2062
2063 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
2064 to TL cb is NULL ; access would cause a page fault
2065 VOS_STATUS_E_EXISTS: Station was not registered
2066 VOS_STATUS_SUCCESS: Everything is good :)
2067
2068 SIDE EFFECTS
2069
2070============================================================================*/
2071VOS_STATUS
2072WLANTL_SuspendDataTx
2073(
2074 v_PVOID_t pvosGCtx,
2075 v_U8_t* ucSTAId,
2076 WLANTL_SuspendCBType pfnSuspendTx
2077);
2078
2079/*==========================================================================
2080
2081 FUNCTION WLANTL_ResumeDataTx
2082
2083 DESCRIPTION
2084 Called by HAL to resume data transmission for a given STA.
2085
2086 WARNING: If a station was individually suspended a global resume will
2087 not resume that station
2088
2089 DEPENDENCIES
2090
2091 PARAMETERS
2092
2093 IN
2094 pvosGCtx: pointer to the global vos context; a handle to TL's
2095 control block can be extracted from its context
2096 pucSTAId: identifier of the station which is being resumed; NULL
2097 translates into global resume
2098
2099 RETURN VALUE
2100 The result code associated with performing the operation
2101
2102 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
2103 to TL cb is NULL ; access would cause a page fault
2104 VOS_STATUS_E_EXISTS: Station was not registered
2105 VOS_STATUS_SUCCESS: Everything is good :)
2106
2107 SIDE EFFECTS
2108
2109============================================================================*/
2110VOS_STATUS
2111WLANTL_ResumeDataTx
2112(
2113 v_PVOID_t pvosGCtx,
2114 v_U8_t* pucSTAId
2115);
2116
2117
2118/*----------------------------------------------------------------------------
2119 CLIENT INDEPENDENT INTERFACE
2120 ---------------------------------------------------------------------------*/
2121
2122/*==========================================================================
2123
2124 FUNCTION WLANTL_GetTxPktCount
2125
2126 DESCRIPTION
2127 TL will provide the number of transmitted packets counted per
2128 STA per TID.
2129
2130 DEPENDENCIES
2131
2132 PARAMETERS
2133
2134 IN
2135 pvosGCtx: pointer to the global vos context; a handle to TL's
2136 control block can be extracted from its context
2137 ucSTAId: identifier of the station
2138 ucTid: identifier of the tspec
2139
2140 OUT
2141 puTxPktCount: the number of packets tx packet for this STA and TID
2142
2143 RETURN VALUE
2144 The result code associated with performing the operation
2145
2146 VOS_STATUS_E_INVAL: Input parameters are invalid
2147 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
2148 to TL cb is NULL ; access would cause a page fault
2149 VOS_STATUS_E_EXISTS: Station was not registered
2150 VOS_STATUS_SUCCESS: Everything is good :)
2151
2152 SIDE EFFECTS
2153
2154============================================================================*/
2155VOS_STATUS
2156WLANTL_GetTxPktCount
2157(
2158 v_PVOID_t pvosGCtx,
2159 v_U8_t ucSTAId,
2160 v_U8_t ucTid,
2161 v_U32_t* puTxPktCount
2162);
2163
2164/*==========================================================================
2165
2166 FUNCTION WLANTL_GetRxPktCount
2167
2168 DESCRIPTION
2169 TL will provide the number of received packets counted per
2170 STA per TID.
2171
2172 DEPENDENCIES
2173
2174 PARAMETERS
2175
2176 IN
2177 pvosGCtx: pointer to the global vos context; a handle to TL's
2178 control block can be extracted from its context
2179 ucSTAId: identifier of the station
2180 ucTid: identifier of the tspec
2181
2182 OUT
2183 puTxPktCount: the number of packets rx packet for this STA and TID
2184
2185 RETURN VALUE
2186 The result code associated with performing the operation
2187
2188 VOS_STATUS_E_INVAL: Input parameters are invalid
2189 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer
2190 to TL cb is NULL ; access would cause a page fault
2191 VOS_STATUS_E_EXISTS: Station was not registered
2192 VOS_STATUS_SUCCESS: Everything is good :)
2193
2194 SIDE EFFECTS
2195
2196============================================================================*/
2197VOS_STATUS
2198WLANTL_GetRxPktCount
2199(
2200 v_PVOID_t pvosGCtx,
2201 v_U8_t ucSTAId,
2202 v_U8_t ucTid,
2203 v_U32_t* puRxPktCount
2204);
2205
2206/*==========================================================================
2207 VOSS SCHEDULER INTERACTION
2208 ==========================================================================*/
2209
2210/*==========================================================================
2211 FUNCTION WLANTL_McProcessMsg
2212
2213 DESCRIPTION
2214 Called by VOSS when a message was serialized for TL through the
2215 main thread/task.
2216
2217 DEPENDENCIES
2218 The TL must be initialized before this function can be called.
2219
2220 PARAMETERS
2221
2222 IN
2223 pvosGCtx: pointer to the global vos context; a handle to TL's
2224 control block can be extracted from its context
2225 message: type and content of the message
2226
2227
2228 RETURN VALUE
2229 The result code associated with performing the operation
2230
2231 VOS_STATUS_E_INVAL: invalid input parameters
2232 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
2233 page fault
2234 VOS_STATUS_SUCCESS: Everything is good :)
2235
2236 SIDE EFFECTS
2237
2238============================================================================*/
2239VOS_STATUS
2240WLANTL_McProcessMsg
2241(
2242 v_PVOID_t pvosGCtx,
2243 vos_msg_t* message
2244);
2245
2246/*==========================================================================
Katya Nigam664f5032014-05-05 12:24:32 +05302247 FUNCTION WLANTL_RxProcessMsg
2248
2249 DESCRIPTION
2250 Called by VOSS when a message was serialized for TL through the
2251 rx thread/task.
2252
2253 DEPENDENCIES
2254 The TL must be initialized before this function can be called.
2255
2256 PARAMETERS
2257
2258 IN
2259 pvosGCtx: pointer to the global vos context; a handle to TL's
2260 control block can be extracted from its context
2261 message: type and content of the message
2262
2263
2264 RETURN VALUE
2265 The result code associated with performing the operation
2266
2267 VOS_STATUS_E_INVAL: invalid input parameters
2268 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
2269 page fault
2270 VOS_STATUS_SUCCESS: Everything is good :)
2271
2272 Other values can be returned as a result of a function call, please check
2273 corresponding API for more info.
2274 SIDE EFFECTS
2275
2276============================================================================*/
2277VOS_STATUS
2278WLANTL_RxProcessMsg
2279(
2280 v_PVOID_t pvosGCtx,
2281 vos_msg_t* message
2282);
2283
2284/*==========================================================================
Jeff Johnson295189b2012-06-20 16:38:30 -07002285 FUNCTION WLANTL_McFreeMsg
2286
2287 DESCRIPTION
2288 Called by VOSS to free a given TL message on the Main thread when there
2289 are messages pending in the queue when the whole system is been reset.
2290 For now, TL does not allocate any body so this function shout translate
2291 into a NOOP
2292
2293 DEPENDENCIES
2294 The TL must be initialized before this function can be called.
2295
2296 PARAMETERS
2297
2298 IN
2299 pvosGCtx: pointer to the global vos context; a handle to TL's
2300 control block can be extracted from its context
2301 message: type and content of the message
2302
2303
2304 RETURN VALUE
2305 The result code associated with performing the operation
2306
2307 VOS_STATUS_SUCCESS: Everything is good :)
2308
2309 SIDE EFFECTS
2310
2311============================================================================*/
2312VOS_STATUS
2313WLANTL_McFreeMsg
2314(
2315 v_PVOID_t pvosGCtx,
2316 vos_msg_t* message
2317);
2318
2319/*==========================================================================
2320 FUNCTION WLANTL_TxProcessMsg
2321
2322 DESCRIPTION
2323 Called by VOSS when a message was serialized for TL through the
2324 tx thread/task.
2325
2326 DEPENDENCIES
2327 The TL must be initialized before this function can be called.
2328
2329 PARAMETERS
2330
2331 IN
2332 pvosGCtx: pointer to the global vos context; a handle to TL's
2333 control block can be extracted from its context
2334 message: type and content of the message
2335
2336
2337 RETURN VALUE
2338 The result code associated with performing the operation
2339
2340 VOS_STATUS_E_INVAL: invalid input parameters
2341 VOS_STATUS_E_FAULT: pointer to TL cb is NULL ; access would cause a
2342 page fault
2343 VOS_STATUS_SUCCESS: Everything is good :)
2344
2345 Other values can be returned as a result of a function call, please check
2346 corresponding API for more info.
2347 SIDE EFFECTS
2348
2349============================================================================*/
2350VOS_STATUS
2351WLANTL_TxProcessMsg
2352(
2353 v_PVOID_t pvosGCtx,
2354 vos_msg_t* message
2355);
2356
2357/*==========================================================================
2358 FUNCTION WLANTL_McFreeMsg
2359
2360 DESCRIPTION
2361 Called by VOSS to free a given TL message on the Main thread when there
2362 are messages pending in the queue when the whole system is been reset.
2363 For now, TL does not allocate any body so this function shout translate
2364 into a NOOP
2365
2366 DEPENDENCIES
2367 The TL must be initialized before this function can be called.
2368
2369 PARAMETERS
2370
2371 IN
2372 pvosGCtx: pointer to the global vos context; a handle to TL's
2373 control block can be extracted from its context
2374 message: type and content of the message
2375
2376
2377 RETURN VALUE
2378 The result code associated with performing the operation
2379
2380 VOS_STATUS_SUCCESS: Everything is good :)
2381
2382 SIDE EFFECTS
2383
2384============================================================================*/
2385VOS_STATUS
2386WLANTL_TxFreeMsg
2387(
2388 v_PVOID_t pvosGCtx,
2389 vos_msg_t* message
2390);
2391
2392
2393/*==========================================================================
2394 FUNCTION WLANTL_EnableUAPSDForAC
2395
2396 DESCRIPTION
2397 Called by HDD to enable UAPSD in TL. TL is in charge for sending trigger
2398 frames.
2399
2400 DEPENDENCIES
2401 The TL must be initialized before this function can be called.
2402
2403 PARAMETERS
2404
2405 IN
2406 pvosGCtx: pointer to the global vos context; a handle to TL's
2407 control block can be extracted from its context
2408 ucSTAId: station Id
2409 ucACId: AC for which U-APSD is being enabled
2410 ucTid TSpec Id
2411 uServiceInt: service interval used by TL to send trigger frames
2412 uSuspendInt: suspend interval used by TL to determine that an
2413 app is idle and should start sending trigg frms less often
2414 wTSDir: direction of TSpec
2415
2416 RETURN VALUE
2417 The result code associated with performing the operation
2418
2419 VOS_STATUS_SUCCESS: Everything is good :)
2420
2421 SIDE EFFECTS
2422
2423============================================================================*/
2424VOS_STATUS
2425WLANTL_EnableUAPSDForAC
2426(
2427 v_PVOID_t pvosGCtx,
2428 v_U8_t ucSTAId,
2429 WLANTL_ACEnumType ucACId,
2430 v_U8_t ucTid,
2431 v_U8_t ucUP,
2432 v_U32_t uServiceInt,
2433 v_U32_t uSuspendInt,
2434 WLANTL_TSDirType wTSDir
2435);
2436
2437
2438/*==========================================================================
2439 FUNCTION WLANTL_DisableUAPSDForAC
2440
2441 DESCRIPTION
2442 Called by HDD to disable UAPSD in TL. TL will stop sending trigger
2443 frames.
2444
2445 DEPENDENCIES
2446 The TL must be initialized before this function can be called.
2447
2448 PARAMETERS
2449
2450 IN
2451 pvosGCtx: pointer to the global vos context; a handle to TL's
2452 control block can be extracted from its context
2453 ucSTAId: station Id
2454 ucACId: AC for which U-APSD is being enabled
2455
2456
2457 RETURN VALUE
2458 The result code associated with performing the operation
2459
2460 VOS_STATUS_SUCCESS: Everything is good :)
2461
2462 SIDE EFFECTS
2463
2464============================================================================*/
2465VOS_STATUS
2466WLANTL_DisableUAPSDForAC
2467(
2468 v_PVOID_t pvosGCtx,
2469 v_U8_t ucSTAId,
2470 WLANTL_ACEnumType ucACId
2471);
2472
2473#if defined WLAN_FEATURE_NEIGHBOR_ROAMING
2474/*==========================================================================
2475 FUNCTION WLANTL_RegRSSIIndicationCB
2476
2477 DESCRIPTION Registration function to get notification if RSSI cross
2478 threshold.
2479 Client should register threshold, direction, and notification
2480 callback function pointer
2481
2482 DEPENDENCIES NONE
2483
2484 PARAMETERS in pAdapter - Global handle
2485 in rssiValue - RSSI threshold value
2486 in triggerEvent - Cross direction should be notified
2487 UP, DOWN, and CROSS
2488 in crossCBFunction - Notification CB Function
2489 in usrCtxt - user context
2490
2491 RETURN VALUE VOS_STATUS
2492
2493 SIDE EFFECTS NONE
2494
2495============================================================================*/
2496VOS_STATUS WLANTL_RegRSSIIndicationCB
2497(
2498 v_PVOID_t pAdapter,
2499 v_S7_t rssiValue,
2500 v_U8_t triggerEvent,
2501 WLANTL_RSSICrossThresholdCBType crossCBFunction,
2502 VOS_MODULE_ID moduleID,
2503 v_PVOID_t usrCtxt
2504);
2505
2506/*==========================================================================
2507 FUNCTION WLANTL_DeregRSSIIndicationCB
2508
2509 DESCRIPTION Remove specific threshold from list
2510
2511 DEPENDENCIES NONE
2512
2513 PARAMETERS in pAdapter - Global handle
2514 in rssiValue - RSSI threshold value
2515 in triggerEvent - Cross direction should be notified
2516 UP, DOWN, and CROSS
2517
2518 RETURN VALUE VOS_STATUS
2519
2520 SIDE EFFECTS NONE
2521
2522============================================================================*/
2523VOS_STATUS WLANTL_DeregRSSIIndicationCB
2524(
2525 v_PVOID_t pAdapter,
2526 v_S7_t rssiValue,
2527 v_U8_t triggerEvent,
2528 WLANTL_RSSICrossThresholdCBType crossCBFunction,
2529 VOS_MODULE_ID moduleID
2530);
2531
2532/*==========================================================================
2533
2534 FUNCTION
2535
2536 DESCRIPTION
2537
2538 PARAMETERS
2539
2540 RETURN VALUE
2541
2542============================================================================*/
2543VOS_STATUS WLANTL_BMPSRSSIRegionChangedNotification
2544(
2545 v_PVOID_t pAdapter,
2546 tpSirRSSINotification pRSSINotification
2547);
2548
2549/*==========================================================================
2550 FUNCTION WLANTL_SetAlpha
2551
2552 DESCRIPTION ALPLA is weight value to calculate AVG RSSI
2553 avgRSSI = (ALPHA * historyRSSI) + ((10 - ALPHA) * newRSSI)
2554 avgRSSI has (ALPHA * 10)% of history RSSI weight and
2555 (10 - ALPHA)% of newRSSI weight
2556 This portion is dynamically configurable.
2557 Default is ?
2558
2559 DEPENDENCIES NONE
2560
2561 PARAMETERS in pAdapter - Global handle
2562 in valueAlpah - ALPHA
2563
2564 RETURN VALUE VOS_STATUS
2565
2566 SIDE EFFECTS NONE
2567
2568============================================================================*/
2569VOS_STATUS WLANTL_SetAlpha
2570(
2571 v_PVOID_t pAdapter,
2572 v_U8_t valueAlpha
2573);
2574
2575/*==========================================================================
2576 FUNCTION WLANTL_RegGetTrafficStatus
2577
2578 DESCRIPTION Registration function for traffic status monitoring
2579 During measure period count data frames.
2580 If frame count is larger then IDLE threshold set as traffic ON
2581 or OFF.
2582 And traffic status is changed send report to client with
2583 registered callback function
2584
2585 DEPENDENCIES NONE
2586
2587 PARAMETERS in pAdapter - Global handle
2588 in idleThreshold - Traffic on or off threshold
2589 in measurePeriod - Traffic state check period
2590 in trfficStatusCB - traffic status changed notification
2591 CB function
2592 in usrCtxt - user context
2593
2594 RETURN VALUE VOS_STATUS
2595
2596 SIDE EFFECTS NONE
2597
2598============================================================================*/
2599VOS_STATUS WLANTL_RegGetTrafficStatus
2600(
2601 v_PVOID_t pAdapter,
2602 v_U32_t idleThreshold,
2603 v_U32_t measurePeriod,
2604 WLANTL_TrafficStatusChangedCBType trfficStatusCB,
2605 v_PVOID_t usrCtxt
2606);
2607#endif
2608/*==========================================================================
2609 FUNCTION WLANTL_GetStatistics
2610
2611 DESCRIPTION Get traffic statistics for identified station
2612
2613 DEPENDENCIES NONE
2614
2615 PARAMETERS in pAdapter - Global handle
2616 in statType - specific statistics field to reset
2617 out statBuffer - traffic statistics buffer
2618
2619 RETURN VALUE VOS_STATUS
2620
2621 SIDE EFFECTS NONE
2622
2623============================================================================*/
2624VOS_STATUS WLANTL_GetStatistics
2625(
2626 v_PVOID_t pAdapter,
2627 WLANTL_TRANSFER_STA_TYPE *statBuffer,
2628 v_U8_t STAid
2629);
2630
2631/*==========================================================================
2632 FUNCTION WLANTL_ResetStatistics
2633
2634 DESCRIPTION Reset statistics structure for identified station ID
2635 Reset means set values as 0
2636
2637 DEPENDENCIES NONE
2638
2639 PARAMETERS in pAdapter - Global handle
2640 in statType - specific statistics field to reset
2641
2642 RETURN VALUE VOS_STATUS
2643
2644 SIDE EFFECTS NONE
2645
2646============================================================================*/
2647VOS_STATUS WLANTL_ResetStatistics
2648(
2649 v_PVOID_t pAdapter,
2650 v_U8_t STAid
2651);
2652
2653/*==========================================================================
2654 FUNCTION WLANTL_GetSpecStatistic
2655
2656 DESCRIPTION Get specific field within statistics structure for
2657 identified station ID
2658
2659 DEPENDENCIES NONE
2660
2661 PARAMETERS in pAdapter - Global handle
2662 in statType - specific statistics field to reset
2663 in STAid - Station ID
2664 out buffer - Statistic value
2665
2666 RETURN VALUE VOS_STATUS
2667
2668 SIDE EFFECTS NONE
2669
2670============================================================================*/
2671VOS_STATUS WLANTL_GetSpecStatistic
2672(
2673 v_PVOID_t pAdapter,
2674 WLANTL_TRANSFER_STATIC_TYPE statType,
2675 v_U32_t *buffer,
2676 v_U8_t STAid
2677);
2678
2679/*==========================================================================
2680 FUNCTION WLANTL_ResetSpecStatistic
2681
2682 DESCRIPTION Reset specific field within statistics structure for
2683 identified station ID
2684 Reset means set as 0
2685
2686 DEPENDENCIES NONE
2687
2688 PARAMETERS in pAdapter - Global handle
2689 in statType - specific statistics field to reset
2690 in STAid - Station ID
2691
2692 RETURN VALUE VOS_STATUS
2693
2694 SIDE EFFECTS NONE
2695
2696============================================================================*/
2697VOS_STATUS WLANTL_ResetSpecStatistic
2698(
2699 v_PVOID_t pAdapter,
2700 WLANTL_TRANSFER_STATIC_TYPE statType,
2701 v_U8_t STAid
2702);
Jeff Johnson295189b2012-06-20 16:38:30 -07002703/*===============================================================================
2704 FUNCTION WLANTL_IsReplayPacket
2705
2706 DESCRIPTION This function does replay check for valid stations
2707
2708 DEPENDENCIES Validity of replay check must be done before the function
2709 is called
2710
2711 PARAMETERS currentReplayCounter current replay counter taken from RX BD
2712 previousReplayCounter previous replay counter taken from TL CB
2713
2714 RETRUN VOS_TRUE packet is a replay packet
2715 VOS_FALSE packet is not a replay packet
2716
2717 SIDE EFFECTS none
2718 ===============================================================================*/
2719v_BOOL_t WLANTL_IsReplayPacket
2720(
2721 v_U64_t currentReplayCounter,
2722 v_U64_t previousReplayCounter
2723);
2724
2725/*===============================================================================
2726 FUNCTION WLANTL_GetReplayCounterFromRxBD
2727
2728 DESCRIPTION This function extracts 48-bit replay packet number from RX BD
2729
2730 DEPENDENCIES Validity of replay check must be done before the function
2731 is called
2732
2733 PARAMETERS pucRxHeader pointer to RX BD header
2734
2735 RETRUN v_U64_t Packet number extarcted from RX BD
2736
2737 SIDE EFFECTS none
2738 ===============================================================================*/
2739v_U64_t
2740WLANTL_GetReplayCounterFromRxBD
2741(
2742 v_U8_t *pucRxBDHeader
2743);
Jeff Johnson295189b2012-06-20 16:38:30 -07002744
2745
2746
2747/*
2748 DESCRIPTION
2749 TL returns the weight currently maintained in TL.
2750 IN
2751 pvosGCtx: pointer to the global vos context; a handle to TL's
2752 or SME's control block can be extracted from its context
2753
2754 OUT
2755 pACWeights: Caller allocated memory for filling in weights
2756
2757 RETURN VALUE VOS_STATUS
2758*/
2759VOS_STATUS
2760WLANTL_GetACWeights
2761(
2762 v_PVOID_t pvosGCtx,
2763 v_U8_t* pACWeights
2764);
2765
2766
2767/*
2768 DESCRIPTION
2769 Change the weight currently maintained by TL.
2770 IN
2771 pvosGCtx: pointer to the global vos context; a handle to TL's
2772 or SME's control block can be extracted from its context
2773 pACWeights: Caller allocated memory contain the weights to use
2774
2775
2776 RETURN VALUE VOS_STATUS
2777*/
2778VOS_STATUS
2779WLANTL_SetACWeights
2780(
2781 v_PVOID_t pvosGCtx,
2782 v_U8_t* pACWeights
2783);
2784
Jeff Johnson295189b2012-06-20 16:38:30 -07002785/*==========================================================================
2786 FUNCTION WLANTL_GetSoftAPStatistics
2787
2788 DESCRIPTION Collect the cumulative statistics for all Softap stations
2789
2790 DEPENDENCIES NONE
2791
2792 PARAMETERS in pvosGCtx - Pointer to the global vos context
2793 bReset - If set TL statistics will be cleared after reading
2794 out statsSum - pointer to collected statistics
2795
2796 RETURN VALUE VOS_STATUS_SUCCESS : if the Statistics are successfully extracted
2797
2798 SIDE EFFECTS NONE
2799
2800============================================================================*/
2801VOS_STATUS WLANTL_GetSoftAPStatistics(v_PVOID_t pAdapter, WLANTL_TRANSFER_STA_TYPE *statsSum, v_BOOL_t bReset);
Jeff Johnson295189b2012-06-20 16:38:30 -07002802
2803#ifdef __cplusplus
2804 }
2805#endif
2806
Katya Nigam63902932014-06-26 19:04:23 +05302807/*===========================================================================
2808
2809 FUNCTION WLANTL_EnableCaching
2810
2811 DESCRIPTION
2812
2813 This function is used to enable caching only when assoc/reassoc req is send.
2814 that is cache packets only for such STA ID.
2815
2816
2817 DEPENDENCIES
2818
2819 TL must have been initialized before this gets called.
2820
2821
2822 PARAMETERS
2823
2824 staId: station id.
2825
2826 RETURN VALUE
2827
2828 none
2829
2830============================================================================*/
2831void WLANTL_EnableCaching(v_U8_t staId);
Jeff Johnson295189b2012-06-20 16:38:30 -07002832
2833 /*===========================================================================
2834
2835 FUNCTION WLANTL_AssocFailed
2836
2837 DESCRIPTION
2838
2839 This function is used by PE to notify TL that cache needs to flushed
2840 when association is not successfully completed
2841
2842 Internally, TL post a message to TX_Thread to serialize the request to
2843 keep lock-free mechanism.
2844
2845
2846 DEPENDENCIES
2847
2848 TL must have been initialized before this gets called.
2849
2850
2851 PARAMETERS
2852
2853 ucSTAId: station id
2854
2855 RETURN VALUE
2856
2857 none
2858
2859 SIDE EFFECTS
2860 There may be race condition that PE call this API and send another association
2861 request immediately with same staId before TX_thread can process the message.
2862
2863 To avoid this, we might need PE to wait for TX_thread process the message,
2864 but this is not currently implemented.
2865
2866============================================================================*/
2867void WLANTL_AssocFailed(v_U8_t staId);
2868
2869
2870/*===============================================================================
2871 FUNCTION WLANTL_PostResNeeded
2872
2873 DESCRIPTION This function posts message to TL to reserve BD/PDU memory
2874
2875 DEPENDENCIES None
2876
2877 PARAMETERS pvosGCtx
2878
2879 RETURN None
2880
2881 SIDE EFFECTS none
2882 ===============================================================================*/
2883
2884void WLANTL_PostResNeeded(v_PVOID_t pvosGCtx);
2885
2886/*===========================================================================
2887
2888 FUNCTION WLANTL_Finish_ULA
2889
2890 DESCRIPTION
2891 This function is used by HDD to notify TL to finish Upper layer authentication
2892 incase the last EAPOL packet is pending in the TL queue.
2893 To avoid the race condition between sme set key and the last EAPOL packet
2894 the HDD module calls this function just before calling the sme_RoamSetKey.
2895
2896 DEPENDENCIES
2897
2898 TL must have been initialized before this gets called.
2899
2900
2901 PARAMETERS
2902
2903 callbackRoutine: HDD Callback function.
2904 callbackContext : HDD userdata context.
2905
2906 RETURN VALUE
2907
2908 VOS_STATUS_SUCCESS/VOS_STATUS_FAILURE
2909
2910 SIDE EFFECTS
2911
2912============================================================================*/
2913
2914VOS_STATUS WLANTL_Finish_ULA( void (*callbackRoutine) (void *callbackContext),
Tushnim Bhattacharyya39a8f182013-02-20 18:10:30 -08002915 void *callbackContext);
Jeff Johnson295189b2012-06-20 16:38:30 -07002916
2917/*===============================================================================
2918 FUNCTION WLANTL_UpdateRssiBmps
2919
2920 DESCRIPTION This function updates the TL's RSSI (in BMPS mode)
2921
2922 DEPENDENCIES None
2923
2924 PARAMETERS
2925
2926 pvosGCtx VOS context VOS Global context
2927 staId Station ID Station ID
2928 rssi RSSI (BMPS mode) RSSI in BMPS mode
2929
2930 RETURN None
2931
2932 SIDE EFFECTS none
2933 ===============================================================================*/
2934
2935void WLANTL_UpdateRssiBmps(v_PVOID_t pvosGCtx, v_U8_t staId, v_S7_t rssi);
2936
Madan Mohan Koyyalamudid9383fd2013-08-13 09:27:30 +05302937/*===============================================================================
2938 FUNCTION WLANTL_UpdateSnrBmps
2939
2940 DESCRIPTION This function updates the TL's SNR (in BMPS mode)
2941
2942 DEPENDENCIES None
2943
2944 PARAMETERS
2945
2946 pvosGCtx VOS context VOS Global context
2947 staId Station ID Station ID
2948 snr SNR (BMPS mode) SNR in BMPS mode
2949
2950 RETURN None
2951
2952 SIDE EFFECTS none
2953 ===============================================================================*/
2954
2955void WLANTL_UpdateSnrBmps(v_PVOID_t pvosGCtx, v_U8_t staId, v_S7_t snr);
2956
Gopichand Nakkala11acd112012-12-31 16:04:04 -08002957/*==========================================================================
2958 FUNCTION WLANTL_SetTxXmitPending
2959
2960 DESCRIPTION
2961 Called by the WDA when it wants to indicate that WDA_DS_TX_START_XMIT msg
2962 is pending in TL msg queue
2963
2964 DEPENDENCIES
2965 The TL must be registered with WDA before this function can be called.
2966
2967 PARAMETERS
2968
2969 IN
2970 pvosGCtx: pointer to the global vos context; a handle to TL's
2971 or WDA's control block can be extracted from its context
2972
2973 RETURN VALUE None
2974
2975 SIDE EFFECTS
2976
2977============================================================================*/
2978
2979v_VOID_t
2980WLANTL_SetTxXmitPending
2981(
2982 v_PVOID_t pvosGCtx
2983);
2984
2985/*==========================================================================
2986 FUNCTION WLANTL_IsTxXmitPending
2987
2988 DESCRIPTION
2989 Called by the WDA when it wants to know whether WDA_DS_TX_START_XMIT msg
2990 is pending in TL msg queue
2991
2992 DEPENDENCIES
2993 The TL must be registered with WDA before this function can be called.
2994
2995 PARAMETERS
2996
2997 IN
2998 pvosGCtx: pointer to the global vos context; a handle to TL's
2999 or WDA's control block can be extracted from its context
3000
3001 RETURN VALUE
3002 The result code associated with performing the operation
3003
3004 0: No WDA_DS_TX_START_XMIT msg pending
3005 1: Msg WDA_DS_TX_START_XMIT already pending in TL msg queue
3006
3007 SIDE EFFECTS
3008
3009============================================================================*/
3010
3011v_BOOL_t
3012WLANTL_IsTxXmitPending
3013(
3014 v_PVOID_t pvosGCtx
3015);
3016
3017/*==========================================================================
3018 FUNCTION WLANTL_ClearTxXmitPending
3019
3020 DESCRIPTION
3021 Called by the WDA when it wants to indicate that no WDA_DS_TX_START_XMIT msg
3022 is pending in TL msg queue
3023
3024 DEPENDENCIES
3025 The TL must be registered with WDA before this function can be called.
3026
3027 PARAMETERS
3028
3029 IN
3030 pvosGCtx: pointer to the global vos context; a handle to TL's
3031 or WDA's control block can be extracted from its context
3032
3033 RETURN VALUE None
3034
3035 SIDE EFFECTS
3036
3037============================================================================*/
3038
3039v_VOID_t
3040WLANTL_ClearTxXmitPending
3041(
3042 v_PVOID_t pvosGCtx
3043);
3044
Shailender Karmuchia734f332013-04-19 14:02:48 -07003045/*==========================================================================
3046 FUNCTION WLANTL_UpdateSTABssIdforIBSS
3047
3048 DESCRIPTION
3049 HDD will call this API to update the BSSID for this Station.
3050
3051 DEPENDENCIES
3052 The HDD Should registered the staID with TL before calling this function.
3053
3054 PARAMETERS
3055
3056 IN
3057 pvosGCtx: Pointer to the global vos context; a handle to TL's
3058 or WDA's control block can be extracted from its context
3059 IN
3060 ucSTAId The Station ID for Bssid to be updated
3061 IN
3062 pBssid BSSID to be updated
3063
3064 RETURN VALUE
3065 The result code associated with performing the operation
3066
3067 VOS_STATUS_E_INVAL: Input parameters are invalid
3068 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
3069 TL cb is NULL ; access would cause a page fault
3070 VOS_STATUS_E_EXISTS: Station was not registered
3071 VOS_STATUS_SUCCESS: Everything is good :)
3072
Madan Mohan Koyyalamudia96f5442013-05-10 11:32:06 +05303073 SIDE EFFECTS
Shailender Karmuchia734f332013-04-19 14:02:48 -07003074============================================================================*/
3075
3076VOS_STATUS
3077WLANTL_UpdateSTABssIdforIBSS
3078(
3079 v_PVOID_t pvosGCtx,
3080 v_U8_t ucSTAId,
3081 v_U8_t *pBssid
3082);
3083
3084
3085
Gopichand Nakkala8a2b1442013-05-29 15:33:14 +05303086/*===============================================================================
3087 FUNCTION WLANTL_UpdateLinkCapacity
3088
3089 DESCRIPTION This function updates the STA's Link Capacity in TL
3090
3091 DEPENDENCIES None
3092
3093 PARAMETERS
3094
3095 pvosGCtx VOS context VOS Global context
3096 staId Station ID Station ID
3097 linkCapacity linkCapacity Link Capacity
3098
3099 RETURN None
3100
3101 SIDE EFFECTS none
3102 ===============================================================================*/
3103
3104void
3105WLANTL_UpdateLinkCapacity
3106(
3107 v_PVOID_t pvosGCtx,
3108 v_U8_t staId,
3109 v_U32_t linkCapacity);
3110
3111/*===========================================================================
3112
3113 FUNCTION WLANTL_GetSTALinkCapacity
3114
3115 DESCRIPTION
3116
3117 Returns Link Capacity of a particular STA.
3118
3119 DEPENDENCIES
3120
3121 A station must have been registered before its state can be retrieved.
3122
Gopichand Nakkala8a2b1442013-05-29 15:33:14 +05303123 PARAMETERS
3124
3125 IN
3126 pvosGCtx: pointer to the global vos context; a handle to TL's
3127 control block can be extracted from its context
3128 ucSTAId: identifier of the station
3129
3130 OUT
3131 plinkCapacity: the current link capacity the connection to
3132 the given station
3133
3134
3135 RETURN VALUE
3136
3137 The result code associated with performing the operation
3138
3139 VOS_STATUS_E_INVAL: Input parameters are invalid
3140 VOS_STATUS_E_FAULT: Station ID is outside array boundaries or pointer to
3141 TL cb is NULL ; access would cause a page fault
3142 VOS_STATUS_E_EXISTS: Station was not registered
3143 VOS_STATUS_SUCCESS: Everything is good :)
3144
3145 SIDE EFFECTS
3146
3147============================================================================*/
Madan Mohan Koyyalamudia96f5442013-05-10 11:32:06 +05303148
Gopichand Nakkala8a2b1442013-05-29 15:33:14 +05303149VOS_STATUS
3150WLANTL_GetSTALinkCapacity
3151(
3152 v_PVOID_t pvosGCtx,
3153 v_U8_t ucSTAId,
3154 v_U32_t *plinkCapacity
3155);
Madan Mohan Koyyalamudia96f5442013-05-10 11:32:06 +05303156
3157/*===========================================================================
3158 FUNCTION WLANTL_TxThreadDebugHandler
3159
3160 DESCRIPTION
3161 Printing TL Snapshot dump, processed under TxThread context, currently
3162 information regarding the global TlCb struture. Dumps information related
3163 to per active STA connection currently in use by TL.
3164
3165 DEPENDENCIES
3166 The TL must be initialized before this gets called.
3167
3168 PARAMETERS
3169
3170 IN
3171 pvosGCtx: Pointer to the global vos context; a handle to TL's
3172 or WDA's control block can be extracted from its context
3173
3174 RETURN VALUE None
3175
3176 SIDE EFFECTS
3177============================================================================*/
3178
3179v_VOID_t
3180WLANTL_TxThreadDebugHandler
3181(
3182 v_PVOID_t *pvosGCtx
3183);
3184
3185/*==========================================================================
3186 FUNCTION WLANTL_TLDebugMessage
3187
3188 DESCRIPTION
3189 Post a TL Snapshot request, posts message in TxThread.
3190
3191 DEPENDENCIES
3192 The TL must be initialized before this gets called.
3193
3194 PARAMETERS
3195
3196 IN
3197 displaySnapshot Boolean showing whether to dump the snapshot or not.
3198
3199 RETURN VALUE None
3200
3201 SIDE EFFECTS
3202
3203============================================================================*/
3204
3205v_VOID_t
3206WLANTL_TLDebugMessage
3207(
Mihir Shete327c2ab2014-11-13 15:17:02 +05303208 v_U32_t debugFlags
Madan Mohan Koyyalamudia96f5442013-05-10 11:32:06 +05303209);
3210
Mihir Shetefd62d9d2014-08-06 15:08:21 +05303211/*==========================================================================
3212 FUNCTION WLANTL_FatalError
3213
3214 DESCRIPTION
3215 Fatal error reported in TX path, post an event to TX Thread for further
3216 handling
3217
3218 DEPENDENCIES
3219 The TL must be initialized before this gets called.
3220
3221 PARAMETERS
3222
3223 VOID
3224
3225 RETURN VALUE None
3226
3227 SIDE EFFECTS
3228
3229============================================================================*/
3230v_VOID_t
3231WLANTL_FatalError
3232(
3233 v_VOID_t
3234);
3235
Jeff Johnson295189b2012-06-20 16:38:30 -07003236#endif /* #ifndef WLAN_QCT_WLANTL_H */