blob: d37a6d1f0cfd49d69cefe20f64c7a872f09dbf52 [file] [log] [blame]
Jeff Johnson295189b2012-06-20 16:38:30 -07001/*
Jeff Johnson32d95a32012-09-10 13:15:23 -07002 * Copyright (c) 2012, The Linux Foundation. All rights reserved.
Jeff Johnson295189b2012-06-20 16:38:30 -07003 *
4 * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
5 *
6 *
7 * Permission to use, copy, modify, and/or distribute this software for
8 * any purpose with or without fee is hereby granted, provided that the
9 * above copyright notice and this permission notice appear in all
10 * copies.
11 *
12 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
13 * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
14 * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
15 * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
16 * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
17 * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
18 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
19 * PERFORMANCE OF THIS SOFTWARE.
20 */
21
22/*
23 * Airgo Networks, Inc proprietary. All rights reserved.
24 * This file parserApi.h contains the definitions used
25 * for parsing received 802.11 frames
26 * Author: Chandra Modumudi
27 * Date: 02/11/02
28 * History:-
29 * Date Modified by Modification Information
30 * --------------------------------------------------------------------
31 *
32 */
33#ifndef __PARSE_H__
34#define __PARSE_H__
35
36#include <stdarg.h>
37#include "sirMacPropExts.h"
38#include "dot11f.h"
39#include "limSession.h"
40
41#define COUNTRY_STRING_LENGTH ( 3 )
42#define COUNTRY_INFO_MAX_CHANNEL ( 84 )
43#define MAX_SIZE_OF_TRIPLETS_IN_COUNTRY_IE (COUNTRY_STRING_LENGTH * COUNTRY_INFO_MAX_CHANNEL)
44#define HIGHEST_24GHZ_CHANNEL_NUM ( 14 )
45
46typedef struct sSirCountryInformation
47{
48 tANI_U8 countryString[COUNTRY_STRING_LENGTH];
49 tANI_U8 numIntervals; //number of channel intervals
50 struct channelPowerLim
51 {
52 tANI_U8 channelNumber;
53 tANI_U8 numChannel;
54 tANI_U8 maxTransmitPower;
55 } channelTransmitPower[COUNTRY_INFO_MAX_CHANNEL];
56} tSirCountryInformation,*tpSirCountryInformation;
57
58
59/// Structure common to Beaons & Probe Responses
60typedef struct sSirProbeRespBeacon
61{
62 tSirMacTimeStamp timeStamp;
63 tANI_U16 beaconInterval;
64 tSirMacCapabilityInfo capabilityInfo;
65
66 tSirMacSSid ssId;
67 tSirMacRateSet supportedRates;
68 tSirMacRateSet extendedRates;
69 tSirMacChanNum channelNumber;
70 tSirMacCfParamSet cfParamSet;
71 tSirMacTim tim;
72 tSirMacEdcaParamSetIE edcaParams;
73 tSirMacQosCapabilityIE qosCapability;
74
75 tSirCountryInformation countryInfoParam;
76 tSirMacWpaInfo wpa;
77 tSirMacRsnInfo rsn;
78
79 tSirMacErpInfo erpIEInfo;
80
81 tSirPropIEStruct propIEinfo;
82 tDot11fIEPowerConstraints localPowerConstraint;
83 tDot11fIETPCReport tpcReport;
84 tDot11fIEChanSwitchAnn channelSwitchIE;
85 tDot11fIEExtChanSwitchAnn extChannelSwitchIE;
86 tSirMacAddr bssid;
87 tDot11fIEQuiet quietIE;
88 tDot11fIEHTCaps HTCaps;
89 tDot11fIEHTInfo HTInfo;
90#ifdef WLAN_FEATURE_P2P
91 tDot11fIEP2PProbeRes P2PProbeRes;
92#endif
93#ifdef WLAN_FEATURE_VOWIFI_11R
94 tANI_U8 mdie[SIR_MDIE_SIZE];
95#endif
96#ifdef FEATURE_WLAN_CCX
97 tDot11fIECCXTxmitPower ccxTxPwr;
98 tDot11fIEQBSSLoad QBSSLoad;
99#endif
100 tANI_U8 ssidPresent;
101 tANI_U8 suppRatesPresent;
102 tANI_U8 extendedRatesPresent;
103 tANI_U8 cfPresent;
104 tANI_U8 dsParamsPresent;
105 tANI_U8 timPresent;
106
107 tANI_U8 edcaPresent;
108 tANI_U8 qosCapabilityPresent;
109 tANI_U8 wmeEdcaPresent;
110 tANI_U8 wmeInfoPresent;
111 tANI_U8 wsmCapablePresent;
112
113 tANI_U8 countryInfoPresent;
114 tANI_U8 wpaPresent;
115 tANI_U8 rsnPresent;
116 tANI_U8 erpPresent;
117 tANI_U8 channelSwitchPresent;
118 tANI_U8 extChannelSwitchPresent;
119 tANI_U8 quietIEPresent;
120 tANI_U8 tpcReportPresent;
121 tANI_U8 powerConstraintPresent;
122
123#ifdef WLAN_FEATURE_VOWIFI_11R
124 tANI_U8 mdiePresent;
125#endif
126
Jeff Johnsone7245742012-09-05 17:12:55 -0700127#ifdef WLAN_FEATURE_11AC
128 tDot11fIEVHTCaps VHTCaps;
129 tDot11fIEVHTOperation VHTOperation;
130 tDot11fIEVHTExtBssLoad VHTExtBssLoad;
Mohit Khanna4a70d262012-09-11 16:30:12 -0700131 tDot11fIEOperatingMode OperatingMode;
Madan Mohan Koyyalamudic6226de2012-09-18 16:33:31 -0700132 tANI_U8 WiderBWChanSwitchAnnPresent;
133 tDot11fIEWiderBWChanSwitchAnn WiderBWChanSwitchAnn;
Jeff Johnsone7245742012-09-05 17:12:55 -0700134#endif
135
Jeff Johnson295189b2012-06-20 16:38:30 -0700136} tSirProbeRespBeacon, *tpSirProbeRespBeacon;
137
138// probe Request structure
139typedef struct sSirProbeReq
140{
141 tSirMacSSid ssId;
142 tSirMacRateSet supportedRates;
143 tSirMacRateSet extendedRates;
144 tDot11fIEWscProbeReq probeReqWscIeInfo;
145 tDot11fIEHTCaps HTCaps;
146 tANI_U8 ssidPresent;
147 tANI_U8 suppRatesPresent;
148 tANI_U8 extendedRatesPresent;
149 tANI_U8 wscIePresent;
150 tANI_U8 p2pIePresent;
Jeff Johnsone7245742012-09-05 17:12:55 -0700151#ifdef WLAN_FEATURE_11AC
152 tDot11fIEVHTCaps VHTCaps;
153#endif
154
Jeff Johnson295189b2012-06-20 16:38:30 -0700155
156} tSirProbeReq, *tpSirProbeReq;
157
158/// Association Request structure (one day to be replaced by
159/// tDot11fAssocRequest)
160typedef struct sSirAssocReq
161{
162
163 tSirMacCapabilityInfo capabilityInfo;
164 tANI_U16 listenInterval;
165 tSirMacAddr currentApAddr; /* only in reassoc frames */
166 tSirMacSSid ssId;
167 tSirMacRateSet supportedRates;
168 tSirMacRateSet extendedRates;
169
170 tSirAddtsReqInfo addtsReq;
171 tSirMacQosCapabilityStaIE qosCapability;
172
173 tSirMacWpaInfo wpa;
174 tSirMacRsnInfo rsn;
175 tSirAddie addIE;
176
177 tSirPropIEStruct propIEinfo;
178 tSirMacPowerCapabilityIE powerCapability;
179 tSirMacSupportedChannelIE supportedChannels;
180 tDot11fIEHTCaps HTCaps;
181#ifdef WLAN_SOFTAP_FEATURE
182 tDot11fIEWMMInfoStation WMMInfoStation;
183#endif
184 /// This is set if the frame is a reassoc request:
185 tANI_U8 reassocRequest;
186 tANI_U8 ssidPresent;
187 tANI_U8 suppRatesPresent;
188 tANI_U8 extendedRatesPresent;
189
190 tANI_U8 wmeInfoPresent;
191 tANI_U8 qosCapabilityPresent;
192 tANI_U8 addtsPresent;
193 tANI_U8 wsmCapablePresent;
194
195 tANI_U8 wpaPresent;
196 tANI_U8 rsnPresent;
197 tANI_U8 addIEPresent;
198
199 tANI_U8 powerCapabilityPresent;
200 tANI_U8 supportedChannelsPresent;
201#ifdef WLAN_SOFTAP_FEATURE
202 // keeing copy of assoction request received, this is
203 // required for indicating the frame to upper layers
204 tANI_U32 assocReqFrameLength;
205 tANI_U8* assocReqFrame;
206#endif
Jeff Johnsone7245742012-09-05 17:12:55 -0700207#ifdef WLAN_FEATURE_11AC
208 tDot11fIEVHTCaps VHTCaps;
Mohit Khanna7d5aeb22012-09-11 16:21:57 -0700209 tDot11fIEOperatingMode operMode;
Jeff Johnsone7245742012-09-05 17:12:55 -0700210#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700211} tSirAssocReq, *tpSirAssocReq;
212
213
214/// Association Response structure (one day to be replaced by
215/// tDot11fAssocRequest)
216typedef struct sSirAssocRsp
217{
218
219 tSirMacCapabilityInfo capabilityInfo;
220 tANI_U16 aid;
221 tANI_U16 statusCode;
222 tSirMacRateSet supportedRates;
223 tSirMacRateSet extendedRates;
224 tSirPropIEStruct propIEinfo;
225 tSirMacEdcaParamSetIE edca;
226 tSirAddtsRspInfo addtsRsp;
227 tDot11fIEHTCaps HTCaps;
228 tDot11fIEHTInfo HTInfo;
229#if defined WLAN_FEATURE_VOWIFI_11R
230 tDot11fIEFTInfo FTInfo;
231 tANI_U8 mdie[SIR_MDIE_SIZE];
232 tANI_U8 num_RICData;
233 tDot11fIERICDataDesc RICData[2];
234#endif
235
236#ifdef FEATURE_WLAN_CCX
237 tANI_U8 num_tspecs;
238 tDot11fIEWMMTSPEC TSPECInfo[SIR_CCX_MAX_TSPEC_IES];
239 tSirMacCCXTSMIE tsmIE;
240#endif
241
242 tANI_U8 suppRatesPresent;
243 tANI_U8 extendedRatesPresent;
244
245 tANI_U8 edcaPresent;
246 tANI_U8 wmeEdcaPresent;
247 tANI_U8 addtsPresent;
248 tANI_U8 wsmCapablePresent;
249#if defined WLAN_FEATURE_VOWIFI_11R
250 tANI_U8 ftinfoPresent;
251 tANI_U8 mdiePresent;
252 tANI_U8 ricPresent;
253#endif
254#ifdef FEATURE_WLAN_CCX
255 tANI_U8 tspecPresent;
256 tANI_U8 tsmPresent;
257#endif
Jeff Johnsone7245742012-09-05 17:12:55 -0700258#ifdef WLAN_FEATURE_11AC
259 tDot11fIEVHTCaps VHTCaps;
260 tDot11fIEVHTOperation VHTOperation;
261#endif
Jeff Johnson295189b2012-06-20 16:38:30 -0700262} tSirAssocRsp, *tpSirAssocRsp;
263
264tANI_U8
265sirIsPropCapabilityEnabled(struct sAniSirGlobal *pMac, tANI_U32 bitnum);
266
267tSirRetStatus
268sirGetCfgPropCaps(struct sAniSirGlobal *, tANI_U16 *);
269
270void dot11fLog(tpAniSirGlobal pMac, int nSev, const char *lpszFormat, ...);
271
Madan Mohan Koyyalamudic0d1b3f2012-11-13 10:41:07 -0800272#define CFG_GET_INT(nStatus, pMac, nItem, cfg ) do { \
273 (nStatus) = wlan_cfgGetInt( (pMac), (nItem), & (cfg) ); \
274 if ( eSIR_SUCCESS != (nStatus) ) \
275 { \
276 dot11fLog( (pMac), LOGP, FL("Failed to retrieve " \
277 #nItem " from CFG (%d).\n"), \
278 (nStatus) ); \
279 return nStatus; \
280 } \
281 } while (0)
Jeff Johnson295189b2012-06-20 16:38:30 -0700282
Madan Mohan Koyyalamudic0d1b3f2012-11-13 10:41:07 -0800283#define CFG_GET_INT_NO_STATUS(nStatus, pMac, nItem, cfg ) do { \
284 (nStatus) = wlan_cfgGetInt( (pMac), (nItem), & (cfg) ); \
285 if ( eSIR_SUCCESS != (nStatus) ) \
286 { \
287 dot11fLog( (pMac), LOGP, FL("Failed to retrieve " \
288 #nItem " from CFG (%d).\n"), \
289 (nStatus) ); \
290 return; \
291 } \
292 } while (0)
Jeff Johnson295189b2012-06-20 16:38:30 -0700293
Madan Mohan Koyyalamudic0d1b3f2012-11-13 10:41:07 -0800294#define CFG_GET_STR(nStatus, pMac, nItem, cfg, nCfg, nMaxCfg) do { \
295 (nCfg) = (nMaxCfg); \
296 (nStatus) = wlan_cfgGetStr( (pMac), (nItem), (cfg), & (nCfg) ); \
297 if ( eSIR_SUCCESS != (nStatus) ) \
298 { \
299 dot11fLog( (pMac), LOGP, FL("Failed to retrieve " \
300 #nItem " from CFG (%d).\n"), \
301 (nStatus) ); \
302 return nStatus; \
303 } \
304 } while (0)
Jeff Johnson295189b2012-06-20 16:38:30 -0700305
Madan Mohan Koyyalamudic0d1b3f2012-11-13 10:41:07 -0800306#define CFG_GET_STR_NO_STATUS(nStatus, pMac, nItem, cfg, nCfg, \
307 nMaxCfg) do { \
308 (nCfg) = (nMaxCfg); \
309 (nStatus) = wlan_cfgGetStr( (pMac), (nItem), (cfg), & (nCfg) ); \
310 if ( eSIR_SUCCESS != (nStatus) ) \
311 { \
312 dot11fLog( (pMac), LOGP, FL("Failed to retrieve " \
313 #nItem " from CFG (%d).\n"), \
314 (nStatus) ); \
315 return; \
316 } \
317 } while (0)
Jeff Johnson295189b2012-06-20 16:38:30 -0700318
319void swapBitField16(tANI_U16 in, tANI_U16 *out);
320
321// Currently implemented as "shims" between callers & the new framesc-
322// generated code:
323
324tSirRetStatus
325sirConvertProbeReqFrame2Struct(struct sAniSirGlobal *pMac,
326 tANI_U8 *frame,
327 tANI_U32 len,
328 tpSirProbeReq probe);
329
330tSirRetStatus
331sirConvertProbeFrame2Struct(struct sAniSirGlobal *pMac, tANI_U8 *frame,
332 tANI_U32 len,
333 tpSirProbeRespBeacon probe);
334
335tSirRetStatus
336sirConvertAssocReqFrame2Struct(struct sAniSirGlobal *pMac,
337 tANI_U8 * frame,
338 tANI_U32 len,
339 tpSirAssocReq assoc);
340
341tSirRetStatus
342sirConvertAssocRespFrame2Struct(struct sAniSirGlobal *pMac,
343 tANI_U8 * frame,
344 tANI_U32 len,
345 tpSirAssocRsp assoc);
346
347tSirRetStatus
348sirConvertReassocReqFrame2Struct(struct sAniSirGlobal *pMac,
349 tANI_U8 * frame,
350 tANI_U32 len,
351 tpSirAssocReq assoc);
352
353tSirRetStatus
354sirParseBeaconIE(struct sAniSirGlobal *pMac,
355 tpSirProbeRespBeacon pBeaconStruct,
356 tANI_U8 *pPayload,
357 tANI_U32 payloadLength);
358
359tSirRetStatus
360sirConvertBeaconFrame2Struct(struct sAniSirGlobal *pMac,
361 tANI_U8 *pBeaconFrame,
362 tpSirProbeRespBeacon pBeaconStruct);
363
364tSirRetStatus
365sirConvertAuthFrame2Struct(struct sAniSirGlobal *pMac,
366 tANI_U8 * frame,
367 tANI_U32 len,
368 tpSirMacAuthFrameBody auth);
369
370tSirRetStatus
371sirConvertAddtsReq2Struct(struct sAniSirGlobal *pMac,
372 tANI_U8 *frame,
373 tANI_U32 len,
374 tSirAddtsReqInfo *addTs);
375
376tSirRetStatus
377sirConvertAddtsRsp2Struct(struct sAniSirGlobal *pMac,
378 tANI_U8 *frame,
379 tANI_U32 len,
380 tSirAddtsRspInfo *addts);
381
382tSirRetStatus
383sirConvertDeltsReq2Struct(struct sAniSirGlobal *pMac,
384 tANI_U8 *frame,
385 tANI_U32 len,
386 tSirDeltsReqInfo *delTs);
387
388#ifdef ANI_SUPPORT_11H
389tSirRetStatus
390sirConvertTpcReqFrame2Struct(struct sAniSirGlobal *, tANI_U8 *,
391 tpSirMacTpcReqActionFrame, tANI_U32);
392
393tSirRetStatus
394sirConvertMeasReqFrame2Struct(struct sAniSirGlobal *, tANI_U8 *,
395 tpSirMacMeasReqActionFrame, tANI_U32);
396#endif
397
398
399/**
400 * \brief Populated a tDot11fFfCapabilities
401 *
402 * \sa PopulatedDot11fCapabilities2
403 *
404 *
405 * \param pMac Pointer to the global MAC datastructure
406 *
407 * \param pDot11f Address of a tDot11fFfCapabilities to be filled in
408 *
409 *
410 * \note If SIR_MAC_PROP_CAPABILITY_11EQOS is enabled, we'll clear the QOS
411 * bit in pDot11f
412 *
413 *
414 */
415
416tSirRetStatus
417PopulateDot11fCapabilities(tpAniSirGlobal pMac,
418 tDot11fFfCapabilities *pDot11f,
419 tpPESession psessionEntry);
420
421/**
422 * \brief Populated a tDot11fFfCapabilities
423 *
424 * \sa PopulatedDot11fCapabilities2
425 *
426 *
427 * \param pMac Pointer to the global MAC datastructure
428 *
429 * \param pDot11f Address of a tDot11fFfCapabilities to be filled in
430 *
431 * \param pSta Pointer to a tDphHashNode representing a peer
432 *
433 *
434 * \note If SIR_MAC_PROP_CAPABILITY_11EQOS is enabled on our peer, we'll
435 * clear the QOS bit in pDot11f
436 *
437 *
438 */
439
440struct sDphHashNode;
441
442tSirRetStatus
443PopulateDot11fCapabilities2(tpAniSirGlobal pMac,
444 tDot11fFfCapabilities *pDot11f,
445 struct sDphHashNode *pSta,
446 tpPESession psessionEntry);
447
448/// Populate a tDot11fIEChanSwitchAnn
449void
450PopulateDot11fChanSwitchAnn(tpAniSirGlobal pMac,
Jeff Johnsone7245742012-09-05 17:12:55 -0700451 tDot11fIEChanSwitchAnn *pDot11f,
452 tpPESession psessionEntry);
Jeff Johnson295189b2012-06-20 16:38:30 -0700453
454/// Populate a tDot11fIEChanSwitchAnn
455void
456PopulateDot11fExtChanSwitchAnn(tpAniSirGlobal pMac,
Jeff Johnsone7245742012-09-05 17:12:55 -0700457 tDot11fIEExtChanSwitchAnn *pDot11f,
458 tpPESession psessionEntry);
Jeff Johnson295189b2012-06-20 16:38:30 -0700459
460/// Populate a tDot11fIECountry
461tSirRetStatus
462PopulateDot11fCountry(tpAniSirGlobal pMac,
463 tDot11fIECountry *pDot11f, tpPESession psessionEntry);
464
465/// Populated a PopulateDot11fDSParams
466tSirRetStatus
467PopulateDot11fDSParams(tpAniSirGlobal pMac,
468 tDot11fIEDSParams *pDot11f, tANI_U8 channel,
469 tpPESession psessionEntry);
470
471
472/// Populated a tDot11fIEEDCAParamSet
473void
474PopulateDot11fEDCAParamSet(tpAniSirGlobal pMac,
475 tDot11fIEEDCAParamSet *pDot11f,
476 tpPESession psessionEntry);
477
478#ifdef WLAN_SOFTAP_FEATURE
479tSirRetStatus
480PopulateDot11fERPInfo(tpAniSirGlobal pMac,
481 tDot11fIEERPInfo *pDot11f, tpPESession psessionEntry);
482#else
483tSirRetStatus
484PopulateDot11fERPInfo(tpAniSirGlobal pMac,
485 tDot11fIEERPInfo *pDot11f);
486#endif
487
488tSirRetStatus
489PopulateDot11fExtSuppRates(tpAniSirGlobal pMac,
490 tANI_U8 nChannelNum, tDot11fIEExtSuppRates *pDot11f,
491 tpPESession psessionEntry);
492
493#if defined WLAN_FEATURE_VOWIFI
494tSirRetStatus
495PopulateDot11fBeaconReport(tpAniSirGlobal pMac,
496 tDot11fIEMeasurementReport *pDot11f,
497 tSirMacBeaconReport *pBeaconReport );
498#endif
499
500/**
501 * \brief Populate a tDot11fIEExtSuppRates
502 *
503 *
504 * \param pMac Pointer to the global MAC datastructure
505 *
506 * \param nChannelNum Channel on which the enclosing frame will be going out
507 *
508 * \param pDot11f Address of a tDot11fIEExtSuppRates struct to be filled in.
509 *
510 *
511 * This method is a NOP if the channel is greater than 14.
512 *
513 *
514 */
515
516tSirRetStatus
517PopulateDot11fExtSuppRates1(tpAniSirGlobal pMac,
518 tANI_U8 nChannelNum,
519 tDot11fIEExtSuppRates *pDot11f);
520
521tSirRetStatus
522PopulateDot11fHCF(tpAniSirGlobal pMac,
523 tANI_U32 capEnable,
524 tDot11fIEHCF *pDot11f);
525
526tSirRetStatus
527PopulateDot11fHTCaps(tpAniSirGlobal pMac,
Jeff Johnsone7245742012-09-05 17:12:55 -0700528 tpPESession psessionEntry,
529 tDot11fIEHTCaps *pDot11f);
Jeff Johnson295189b2012-06-20 16:38:30 -0700530
531#ifdef WLAN_SOFTAP_FEATURE
532tSirRetStatus
533PopulateDot11fHTInfo(tpAniSirGlobal pMac,
534 tDot11fIEHTInfo *pDot11f,
535 tpPESession psessionEntry);
536#else
537tSirRetStatus
538PopulateDot11fHTInfo(tpAniSirGlobal pMac,
539 tDot11fIEHTInfo *pDot11f);
540#endif
541
542void PopulateDot11fIBSSParams(tpAniSirGlobal pMac,
543 tDot11fIEIBSSParams *pDot11f, tpPESession psessionEntry);
544
545#ifdef ANI_SUPPORT_11H
546tSirRetStatus
547PopulateDot11fMeasurementReport0(tpAniSirGlobal pMac,
548 tpSirMacMeasReqActionFrame pReq,
549 tDot11fIEMeasurementReport *pDot11f);
550
551/// Populate a tDot11fIEMeasurementReport when the report type is CCA
552tSirRetStatus
553PopulateDot11fMeasurementReport1(tpAniSirGlobal pMac,
554 tpSirMacMeasReqActionFrame pReq,
555 tDot11fIEMeasurementReport *pDot11f);
556
557/// Populate a tDot11fIEMeasurementReport when the report type is RPI Hist
558tSirRetStatus
559PopulateDot11fMeasurementReport2(tpAniSirGlobal pMac,
560 tpSirMacMeasReqActionFrame pReq,
561 tDot11fIEMeasurementReport *pDot11f);
562#endif //ANI_SUPPORT_11H
563
564/// Populate a tDot11fIEPowerCaps
565void
566PopulateDot11fPowerCaps(tpAniSirGlobal pMac,
567 tDot11fIEPowerCaps *pCaps,
568 tANI_U8 nAssocType,tpPESession psessionEntry);
569
570/// Populate a tDot11fIEPowerConstraints
571tSirRetStatus
572PopulateDot11fPowerConstraints(tpAniSirGlobal pMac,
573 tDot11fIEPowerConstraints *pDot11f);
574
575tSirRetStatus
576PopulateDot11fPropCapability(tpAniSirGlobal pMac,
577 tANI_U32 capEnable,
578 tDot11fIEPropCapability *pDot11f);
579
580void
581PopulateDot11fPropChannSwitchAnn(tpAniSirGlobal pMac,
582 tANI_U32 capEnable,
583 tDot11fIEPropChannSwitchAnn *pDot11f);
584
585void
586PopulateDot11fPropEDCAParams(tpAniSirGlobal pMac,
587 tANI_U16 caps,
588 tDot11fIEPropEDCAParams *pDot11f);
589
590tSirRetStatus
591PopulateDot11fPropSuppRates(tpAniSirGlobal pMac,
592 tANI_U32 capEnable,
593 tDot11fIEPropSuppRates *pDot11f);
594
595void
596PopulateDot11fQOSCapsAp(tpAniSirGlobal pMac,
597 tDot11fIEQOSCapsAp *pDot11f, tpPESession psessionEntry);
598
599void
600PopulateDot11fQOSCapsStation(tpAniSirGlobal pMac,
601 tDot11fIEQOSCapsStation *pDot11f);
602
603tSirRetStatus
604PopulateDot11fRSN(tpAniSirGlobal pMac,
605 tpSirRSNie pRsnIe,
606 tDot11fIERSN *pDot11f);
607
608tSirRetStatus
609PopulateDot11fRSNOpaque( tpAniSirGlobal pMac,
610 tpSirRSNie pRsnIe,
611 tDot11fIERSNOpaque *pDot11f );
612
613#if defined(FEATURE_WLAN_WAPI)
614
615tSirRetStatus
616PopulateDot11fWAPI(tpAniSirGlobal pMac,
617 tpSirRSNie pRsnIe,
618 tDot11fIEWAPI *pDot11f);
619
620tSirRetStatus PopulateDot11fWAPIOpaque( tpAniSirGlobal pMac,
621 tpSirRSNie pRsnIe,
622 tDot11fIEWAPIOpaque *pDot11f );
623
624#endif //defined(FEATURE_WLAN_WAPI)
625
626/// Populate a tDot11fIESSID given a tSirMacSSid
627void
628PopulateDot11fSSID(tpAniSirGlobal pMac,
629 tSirMacSSid *pInternal,
630 tDot11fIESSID *pDot11f);
631
632/// Populate a tDot11fIESSID from CFG
633tSirRetStatus
634PopulateDot11fSSID2(tpAniSirGlobal pMac,
635 tDot11fIESSID *pDot11f);
636
637
638/**
639 * \brief Populate a tDot11fIESchedule
640 *
641 * \sa PopulateDot11fWMMSchedule
642 *
643 *
644 * \param pSchedule Address of a tSirMacScheduleIE struct
645 *
646 * \param pDot11f Address of a tDot11fIESchedule to be filled in
647 *
648 *
649 */
650
651void
652PopulateDot11fSchedule(tSirMacScheduleIE *pSchedule,
653 tDot11fIESchedule *pDot11f);
654
655void
656PopulateDot11fSuppChannels(tpAniSirGlobal pMac,
657 tDot11fIESuppChannels *pDot11f,
658 tANI_U8 nAssocType,tpPESession psessionEntry);
659
660/**
661 * \brief Populated a tDot11fIESuppRates
662 *
663 *
664 * \param pMac Pointer to the global MAC datastructure
665 *
666 * \param nChannelNum Channel the enclosing frame will be going out on; see
667 * below
668 *
669 * \param pDot11f Address of a tDot11fIESuppRates struct to be filled in.
670 *
671 *
672 * If nChannelNum is greater than 13, the supported rates will be
673 * WNI_CFG_SUPPORTED_RATES_11B. If it is less than or equal to 13, the
674 * supported rates will be WNI_CFG_SUPPORTED_RATES_11A. If nChannelNum is
675 * set to the sentinel value POPULATE_DOT11F_RATES_OPERATIONAL, the struct
676 * will be populated with WNI_CFG_OPERATIONAL_RATE_SET.
677 *
678 *
679 */
680
681#define POPULATE_DOT11F_RATES_OPERATIONAL ( 0xff )
682
683tSirRetStatus
684PopulateDot11fSuppRates(tpAniSirGlobal pMac,
685 tANI_U8 nChannelNum,
686 tDot11fIESuppRates *pDot11f,tpPESession);
687
688
689tSirRetStatus PopulateDot11fTPCReport(tpAniSirGlobal pMac,
690 tDot11fIETPCReport *pDot11f,
691 tpPESession psessionEntry);
692
693/// Populate a tDot11FfTSInfo
694void PopulateDot11fTSInfo(tSirMacTSInfo *pInfo,
695 tDot11fFfTSInfo *pDot11f);
696
697
698void PopulateDot11fWMM(tpAniSirGlobal pMac,
699 tDot11fIEWMMInfoAp *pInfo,
700 tDot11fIEWMMParams *pParams,
701 tDot11fIEWMMCaps *pCaps,
702 tpPESession psessionEntry);
703
704void PopulateDot11fWMMCaps(tDot11fIEWMMCaps *pCaps);
705
706#ifdef FEATURE_WLAN_CCX
707void PopulateDot11TSRSIE(tpAniSirGlobal pMac,
708 tSirMacCCXTSRSIE *pOld,
709 tDot11fIECCXTrafStrmRateSet *pDot11f,
710 tANI_U8 rate_length);
711void PopulateDot11fReAssocTspec(tpAniSirGlobal pMac, tDot11fReAssocRequest *pReassoc, tpPESession psessionEntry);
712#endif
713
714void PopulateDot11fWMMInfoAp(tpAniSirGlobal pMac,
715 tDot11fIEWMMInfoAp *pInfo,
716 tpPESession psessionEntry);
717
718void PopulateDot11fWMMInfoStation(tpAniSirGlobal pMac,
719 tDot11fIEWMMInfoStation *pInfo);
720
721#ifdef WLAN_SOFTAP_FEATURE
722void PopulateDot11fWMMParams(tpAniSirGlobal pMac,
723 tDot11fIEWMMParams *pParams,
724 tpPESession psessionEntry);
725#else
726void PopulateDot11fWMMParams(tpAniSirGlobal pMac,
727 tDot11fIEWMMParams *pParams);
728#endif
729
730/**
731 * \brief Populate a tDot11fIEWMMSchedule
732 *
733 * \sa PopulatedDot11fSchedule
734 *
735 *
736 * \param pSchedule Address of a tSirMacScheduleIE struct
737 *
738 * \param pDot11f Address of a tDot11fIEWMMSchedule to be filled in
739 *
740 *
741 */
742
743void
744PopulateDot11fWMMSchedule(tSirMacScheduleIE *pSchedule,
745 tDot11fIEWMMSchedule *pDot11f);
746
747tSirRetStatus
748PopulateDot11fWPA(tpAniSirGlobal pMac,
749 tpSirRSNie pRsnIe,
750 tDot11fIEWPA *pDot11f);
751
752tSirRetStatus
753PopulateDot11fWPAOpaque( tpAniSirGlobal pMac,
754 tpSirRSNie pRsnIe,
755 tDot11fIEWPAOpaque *pDot11f );
756
757void
758PopulateDot11fTSPEC(tSirMacTspecIE *pOld,
759 tDot11fIETSPEC *pDot11f);
760
761void
762PopulateDot11fWMMTSPEC(tSirMacTspecIE *pOld,
763 tDot11fIEWMMTSPEC *pDot11f);
764
765tSirRetStatus
766PopulateDot11fTCLAS(tpAniSirGlobal pMac,
767 tSirTclasInfo *pOld,
768 tDot11fIETCLAS *pDot11f);
769
770tSirRetStatus
771PopulateDot11fWMMTCLAS(tpAniSirGlobal pMac,
772 tSirTclasInfo *pOld,
773 tDot11fIEWMMTCLAS *pDot11f);
774
775#if ( WNI_POLARIS_FW_PRODUCT == AP )
776
777tSirRetStatus
778PopulateDot11fCFParams(tpAniSirGlobal pMac,
779 tDot11fFfCapabilities *pCaps,
780 tDot11fIECFParams *pDot11f);
781
782void
783PopulateDot11fQuiet(tpAniSirGlobal pMac,
784 tDot11fIEQuiet *pDot11f);
785
786tSirRetStatus
787PopulateDot11fAPName(tpAniSirGlobal pMac,
788 tANI_U32 capEnable,
789 tDot11fIEAPName *pDot11f);
790
791void
792PopulateDot11fPropQuietBSS(tpAniSirGlobal pMac,
793 tANI_U32 capsEnable,
794 tDot11fIEPropQuietBSS *pDot11f);
795
796void
797PopulateDot11fTrigStaBkScan(tpAniSirGlobal pMac,
798 tANI_U32 capsEnable,
799 tDot11fIETriggerStaBgScan *pDot11f);
800
801#if (WNI_POLARIS_FW_PACKAGE == ADVANCED)
802
803tSirRetStatus
804PopulateDot11fWDS(tpAniSirGlobal pMac,
805 tANI_U32 capEnable,
806 tDot11fIEWDS *pDot11f );
807
808#endif // WNI_POLARIS_FW_PACKAGE == ADVANCED
809
810#endif // WNI_POLARIS_FW_PRODUCT == AP
811
812tSirRetStatus PopulateDot11fWsc(tpAniSirGlobal pMac,
813 tDot11fIEWscBeacon *pDot11f);
814
815tSirRetStatus PopulateDot11fWscRegistrarInfo(tpAniSirGlobal pMac,
816 tDot11fIEWscBeacon *pDot11f);
817
818tSirRetStatus DePopulateDot11fWscRegistrarInfo(tpAniSirGlobal pMac,
819 tDot11fIEWscBeacon *pDot11f);
820
821#ifdef WLAN_SOFTAP_FEATURE
822tSirRetStatus PopulateDot11fProbeResWPSIEs(tpAniSirGlobal pMac, tDot11fIEWscProbeRes *pDot11f, tpPESession psessionEntry);
823tSirRetStatus PopulateDot11fAssocResWPSIEs(tpAniSirGlobal pMac, tDot11fIEWscAssocRes *pDot11f, tpPESession psessionEntry);
824tSirRetStatus PopulateDot11fBeaconWPSIEs(tpAniSirGlobal pMac, tDot11fIEWscBeacon *pDot11f, tpPESession psessionEntry);
825#endif
826
827tSirRetStatus PopulateDot11fWscInProbeRes(tpAniSirGlobal pMac,
828 tDot11fIEWscProbeRes *pDot11f);
829
830tSirRetStatus PopulateDot11fWscRegistrarInfoInProbeRes(tpAniSirGlobal pMac,
831 tDot11fIEWscProbeRes *pDot11f);
832
833tSirRetStatus DePopulateDot11fWscRegistrarInfoInProbeRes(tpAniSirGlobal pMac,
834 tDot11fIEWscProbeRes *pDot11f);
835
836
837tSirRetStatus PopulateDot11fAssocResWscIE(tpAniSirGlobal pMac,
838 tDot11fIEWscAssocRes *pDot11f,
839 tpSirAssocReq pRcvdAssocReq);
840
841#ifdef WLAN_FEATURE_P2P
842tSirRetStatus PopulateDot11AssocResP2PIE(tpAniSirGlobal pMac,
843 tDot11fIEP2PAssocRes *pDot11f,
844 tpSirAssocReq pRcvdAssocReq);
845#endif
846
847tSirRetStatus PopulateDot11fWscInAssocRes(tpAniSirGlobal pMac,
848 tDot11fIEWscAssocRes *pDot11f);
849
850
851#if defined WLAN_FEATURE_VOWIFI
852tSirRetStatus PopulateDot11fWFATPC( tpAniSirGlobal pMac,
853 tDot11fIEWFATPC *pDot11f, tANI_U8 txPower, tANI_U8 linkMargin );
854
855tSirRetStatus PopulateDot11fRRMIe( tpAniSirGlobal pMac,
856 tDot11fIERRMEnabledCap *pDot11f,
857 tpPESession psessionEntry );
858#endif
859
860#if defined WLAN_FEATURE_VOWIFI_11R
861void PopulateMDIE( tpAniSirGlobal pMac,
862 tDot11fIEMobilityDomain *pDot11f, tANI_U8 mdie[] );
863void PopulateFTInfo( tpAniSirGlobal pMac,
864 tDot11fIEFTInfo *pDot11f );
865#endif
866
867void PopulateDot11fAssocRspRates ( tpAniSirGlobal pMac, tDot11fIESuppRates *pSupp,
868 tDot11fIEExtSuppRates *pExt, tANI_U16 *_11bRates, tANI_U16 *_11aRates );
869
870int FindIELocation( tpAniSirGlobal pMac,
871 tpSirRSNie pRsnIe,
872 tANI_U8 EID);
873#endif
Jeff Johnsone7245742012-09-05 17:12:55 -0700874
875#ifdef WLAN_FEATURE_11AC
876tSirRetStatus
877PopulateDot11fVHTCaps(tpAniSirGlobal pMac, tDot11fIEVHTCaps *pDot11f);
878
879tSirRetStatus
880PopulateDot11fVHTOperation(tpAniSirGlobal pMac, tDot11fIEVHTOperation *pDot11f);
881
882tSirRetStatus
883PopulateDot11fVHTExtBssLoad(tpAniSirGlobal pMac, tDot11fIEVHTExtBssLoad *pDot11f);
884
Mohit Khanna4a70d262012-09-11 16:30:12 -0700885tSirRetStatus
886PopulateDot11fExtCap(tpAniSirGlobal pMac, tDot11fIEExtCap * pDot11f);
887
888tSirRetStatus
889PopulateDot11fOperatingMode(tpAniSirGlobal pMac, tDot11fIEOperatingMode *pDot11f, tpPESession psessionEntry );
Madan Mohan Koyyalamudic6226de2012-09-18 16:33:31 -0700890
891void
892PopulateDot11fWiderBWChanSwitchAnn(tpAniSirGlobal pMac,
893 tDot11fIEWiderBWChanSwitchAnn *pDot11f,
894 tpPESession psessionEntry);
Jeff Johnsone7245742012-09-05 17:12:55 -0700895#endif