Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2012, Code Aurora Forum. All rights reserved. |
| 3 | * |
| 4 | * Previously licensed under the ISC license by Qualcomm Atheros, Inc. |
| 5 | * |
| 6 | * |
| 7 | * Permission to use, copy, modify, and/or distribute this software for |
| 8 | * any purpose with or without fee is hereby granted, provided that the |
| 9 | * above copyright notice and this permission notice appear in all |
| 10 | * copies. |
| 11 | * |
| 12 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL |
| 13 | * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED |
| 14 | * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE |
| 15 | * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL |
| 16 | * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR |
| 17 | * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
| 18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
| 19 | * PERFORMANCE OF THIS SOFTWARE. |
| 20 | */ |
| 21 | |
| 22 | /** ------------------------------------------------------------------------- * |
| 23 | ------------------------------------------------------------------------- * |
| 24 | |
| 25 | |
| 26 | \file csrInternal.h |
| 27 | |
| 28 | Define internal data structure for MAC. |
| 29 | |
| 30 | Copyright (C) 2006 Airgo Networks, Incorporated |
| 31 | ========================================================================== */ |
| 32 | #ifndef CSRINTERNAL_H__ |
| 33 | #define CSRINTERNAL_H__ |
| 34 | |
| 35 | #if defined(VOSS_ENABLED) |
| 36 | #include "vos_status.h" |
| 37 | #include "vos_lock.h" |
| 38 | #endif //#if defined(VOSS_ENABLED) |
| 39 | |
| 40 | #include "palTimer.h" |
| 41 | #include "csrSupport.h" |
| 42 | #include "vos_nvitem.h" |
| 43 | #include "wlan_qct_tl.h" |
| 44 | |
| 45 | #ifdef WLAN_FEATURE_NEIGHBOR_ROAMING |
| 46 | #include "csrNeighborRoam.h" |
| 47 | #endif |
| 48 | |
| 49 | #define CSR_MAX_STA (HAL_NUM_STA) |
| 50 | |
| 51 | #define CSR_SME_SCAN_FLAGS_DELETE_CACHE 0x80 |
| 52 | |
| 53 | #define CSR_TITAN_MAX_RATE_MIMO_CB 240 |
| 54 | #define CSR_TITAN_MAX_RATE_MIMO 126 |
| 55 | |
| 56 | //define scan return criteria. LIM should use these define as well |
| 57 | #define CSR_SCAN_RETURN_AFTER_ALL_CHANNELS ( 0 ) |
| 58 | #define CSR_SCAN_RETURN_AFTER_FIRST_MATCH ( 0x01 ) |
| 59 | #define CSR_SCAN_RETURN_AFTER_5_BAND_11d_FOUND ( 0x80 ) |
| 60 | #define CSR_SCAN_RETURN_AFTER_24_BAND_11d_FOUND ( 0x40 ) |
| 61 | #define CSR_SCAN_RETURN_AFTER_EITHER_BAND_11d_FOUND ( CSR_SCAN_RETURN_AFTER_5_BAND_11d_FOUND | CSR_SCAN_RETURN_AFTER_24_BAND_11d_FOUND ) |
| 62 | #define CSR_NUM_RSSI_CAT 5 |
| 63 | #define CSR_MAX_STATISTICS_REQ 10 |
| 64 | |
| 65 | //Support for multiple session |
| 66 | #define CSR_SESSION_ID_INVALID 0xFF // session ID invalid |
| 67 | #define CSR_ROAM_SESSION_MAX 5 // No of sessions to be supported, and a |
| 68 | // session is for Infra, IBSS or BT-AMP |
| 69 | |
| 70 | #define CSR_IS_SESSION_VALID( pMac, sessionId ) ( ( (sessionId) < CSR_ROAM_SESSION_MAX ) \ |
| 71 | && ( (pMac)->roam.roamSession[(sessionId)].sessionActive ) ) |
| 72 | #define CSR_GET_SESSION( pMac, sessionId ) \ |
| 73 | ( \ |
| 74 | (sessionId < CSR_ROAM_SESSION_MAX) ? \ |
| 75 | (&(pMac)->roam.roamSession[(sessionId)]) :\ |
| 76 | NULL \ |
| 77 | ) |
| 78 | |
| 79 | |
| 80 | |
| 81 | typedef enum |
| 82 | { |
| 83 | //eCSR_CFG_DOT11_MODE_BEST = 0, |
| 84 | eCSR_CFG_DOT11_MODE_TAURUS = 0, |
| 85 | eCSR_CFG_DOT11_MODE_ABG, |
| 86 | eCSR_CFG_DOT11_MODE_11A, |
| 87 | eCSR_CFG_DOT11_MODE_11B, |
| 88 | eCSR_CFG_DOT11_MODE_11G, |
| 89 | eCSR_CFG_DOT11_MODE_11N, |
| 90 | eCSR_CFG_DOT11_MODE_POLARIS, |
| 91 | eCSR_CFG_DOT11_MODE_TITAN, |
| 92 | #ifdef WLAN_SOFTAP_FEATURE |
| 93 | eCSR_CFG_DOT11_MODE_11G_ONLY, |
| 94 | eCSR_CFG_DOT11_MODE_11N_ONLY, |
| 95 | #endif |
| 96 | //This value can never set to CFG. It is for CSR's internal use |
| 97 | eCSR_CFG_DOT11_MODE_AUTO, |
| 98 | }eCsrCfgDot11Mode; //Used to determine what to set to the WNI_CFG_DOT11_MODE |
| 99 | |
| 100 | typedef enum etCsrRoamCommands |
| 101 | { |
| 102 | eCsrRoamNoCommand, |
| 103 | eCsrRoamCommandScan, |
| 104 | eCsrRoamCommandRoam, |
| 105 | eCsrRoamCommandWmStatusChange, |
| 106 | eCsrRoamCommandSetKey, |
| 107 | eCsrRoamCommandRemoveKey, |
| 108 | |
| 109 | } eCsrRoamCommands; |
| 110 | |
| 111 | typedef enum |
| 112 | { |
| 113 | eCsrScanOther = 1, |
| 114 | eCsrScanLostLink1, |
| 115 | eCsrScanLostLink2, |
| 116 | eCsrScanLostLink3, |
| 117 | eCsrScanLostLink4, |
| 118 | eCsrScan11d1, //First 11d scan |
| 119 | eCsrScan11d2, //First 11d scan has failed |
| 120 | eCsrScan11dDone, //11d scan succeeded, try the rest of the channel |
| 121 | eCsrScanUserRequest, |
| 122 | eCsrScanGetResult, |
| 123 | eCsrScanSetBGScanParam, //used for HO too - bg scan request in NT Handoff sub-state |
| 124 | eCsrScanForSsid, |
| 125 | eCsrScanForCapsChange, |
| 126 | eCsrScanBGScanAbort, |
| 127 | eCsrScanBGScanEnable, |
| 128 | eCsrScanIdleScan, |
| 129 | eCsrScanGetScanChnInfo, //To get the list of channels scanned |
| 130 | |
| 131 | eCsrScanBgScan, // bg scan request in NRT & RT Handoff sub-states |
| 132 | eCsrScanProbeBss, // directed probe on an entry from the candidate list - HO |
| 133 | eCsrScanAbortBgScan, //aborting a BG scan (meaning the scan is triggered by LIM timer) |
| 134 | eCsrScanAbortNormalScan, //aborting a normal scan (the scan is trigger by eWNI_SME_SCAN_REQ) |
| 135 | eCsrScanP2PFindPeer |
| 136 | }eCsrScanReason; |
| 137 | |
| 138 | typedef enum |
| 139 | { |
| 140 | eCsrNoConnection, // Roaming because we have not established the initial connection. |
| 141 | eCsrCapsChange, // roaming because LIM reported a Capability change in the associated AP. |
| 142 | eCsrForcedDisassoc, // roaming becuase someone asked us to Disassoc and stay disassociated. |
| 143 | eCsrHddIssued, // roaming because an 802.11 request was issued to the driver. |
| 144 | eCsrLostLink1, // roaming because we lost link to an associated AP |
| 145 | eCsrLostLink2, |
| 146 | eCsrLostLink3, |
| 147 | eCsrForcedDisassocMICFailure, // roaming because we need to force a Disassoc due to MIC failure |
| 148 | eCsrHddIssuedReassocToSameAP, |
| 149 | eCsrSmeIssuedReassocToSameAP, |
| 150 | eCsrSmeIssuedReassocToDiffAP, |
| 151 | eCsrForcedDeauth, // roaming becuase someone asked us to deauth and stay disassociated. |
| 152 | eCsrSmeIssuedDisassocForHandoff, // will be issued by Handoff logic to disconect from current AP |
| 153 | eCsrSmeIssuedAssocToSimilarAP, // will be issued by Handoff logic to join a new AP with same profile |
| 154 | eCsrSmeIssuedIbssJoinFailure, // ibss join timer fired before any perr showed up, so shut down the network |
| 155 | eCsrForcedIbssLeave, |
| 156 | eCsrStopBss, |
| 157 | eCsrSmeIssuedFTReassoc, |
| 158 | eCsrForcedDisassocSta, |
| 159 | eCsrForcedDeauthSta, |
| 160 | |
| 161 | }eCsrRoamReason; |
| 162 | |
| 163 | typedef enum |
| 164 | { |
| 165 | eCSR_ROAM_SUBSTATE_NONE = 0, |
| 166 | eCSR_ROAM_SUBSTATE_START_BSS_REQ, |
| 167 | eCSR_ROAM_SUBSTATE_JOIN_REQ, |
| 168 | eCSR_ROAM_SUBSTATE_REASSOC_REQ, |
| 169 | eCSR_ROAM_SUBSTATE_DISASSOC_REQ, |
| 170 | eCSR_ROAM_SUBSTATE_STOP_BSS_REQ, |
| 171 | eCSR_ROAM_SUBSTATE_DISCONNECT_CONTINUE_ROAMING, //Continue the current roam command after disconnect |
| 172 | eCSR_ROAM_SUBSTATE_AUTH_REQ, |
| 173 | eCSR_ROAM_SUBSTATE_CONFIG, |
| 174 | eCSR_ROAM_SUBSTATE_DEAUTH_REQ, |
| 175 | eCSR_ROAM_SUBSTATE_DISASSOC_NOTHING_TO_JOIN, |
| 176 | eCSR_ROAM_SUBSTATE_DISASSOC_REASSOC_FAILURE, |
| 177 | eCSR_ROAM_SUBSTATE_DISASSOC_FORCED, |
| 178 | eCSR_ROAM_SUBSTATE_WAIT_FOR_KEY, |
| 179 | eCSR_ROAM_SUBSTATE_DISASSOC_HANDOFF, |
| 180 | eCSR_ROAM_SUBSTATE_JOINED_NO_TRAFFIC, |
| 181 | eCSR_ROAM_SUBSTATE_JOINED_NON_REALTIME_TRAFFIC, |
| 182 | eCSR_ROAM_SUBSTATE_JOINED_REALTIME_TRAFFIC, |
| 183 | // max is 15 unless the bitfield is expanded... |
| 184 | } eCsrRoamSubState; |
| 185 | |
| 186 | |
| 187 | typedef enum |
| 188 | { |
| 189 | eCSR_ROAMING_STATE_STOP = 0, |
| 190 | eCSR_ROAMING_STATE_IDLE, |
| 191 | eCSR_ROAMING_STATE_SCANNING, |
| 192 | eCSR_ROAMING_STATE_JOINING, |
| 193 | eCSR_ROAMING_STATE_JOINED, |
| 194 | }eCsrRoamState; |
| 195 | |
| 196 | |
| 197 | typedef enum |
| 198 | { |
| 199 | eCsrContinueRoaming, |
| 200 | eCsrStopRoaming, |
| 201 | eCsrStartIbss, |
| 202 | eCsrStartIbssSameIbss, |
| 203 | eCsrReassocToSelfNoCapChange, |
| 204 | |
| 205 | }eCsrJoinState; |
| 206 | |
| 207 | typedef enum |
| 208 | { |
| 209 | eCsrNotRoaming, |
| 210 | eCsrLostlinkRoamingDisassoc, |
| 211 | eCsrLostlinkRoamingDeauth, |
| 212 | eCsrDynamicRoaming, |
| 213 | eCsrReassocRoaming, |
| 214 | }eCsrRoamingReason; |
| 215 | |
| 216 | typedef enum |
| 217 | { |
| 218 | eCsrDisassociated, |
| 219 | eCsrDeauthenticated |
| 220 | |
| 221 | }eCsrRoamWmStatusChangeTypes; |
| 222 | |
| 223 | typedef enum |
| 224 | { |
| 225 | eCsrSummaryStats = 0, |
| 226 | eCsrGlobalClassAStats, |
| 227 | eCsrGlobalClassBStats, |
| 228 | eCsrGlobalClassCStats, |
| 229 | eCsrGlobalClassDStats, |
| 230 | eCsrPerStaStats, |
| 231 | eCsrMaxStats |
| 232 | }eCsrRoamStatsClassTypes; |
| 233 | |
| 234 | #ifdef FEATURE_WLAN_DIAG_SUPPORT |
| 235 | typedef enum |
| 236 | { |
| 237 | eCSR_WLAN_STATUS_CONNECT =0, |
| 238 | eCSR_WLAN_STATUS_DISCONNECT |
| 239 | |
| 240 | }eCsrDiagWlanStatusEventSubtype; |
| 241 | |
| 242 | typedef enum |
| 243 | { |
| 244 | eCSR_REASON_UNSPECIFIED = 0, |
| 245 | eCSR_REASON_USER_REQUESTED, |
| 246 | eCSR_REASON_MIC_ERROR, |
| 247 | eCSR_REASON_DISASSOC, |
| 248 | eCSR_REASON_DEAUTH, |
| 249 | eCSR_REASON_HANDOFF, |
| 250 | |
| 251 | }eCsrDiagWlanStatusEventReason; |
| 252 | |
| 253 | typedef enum |
| 254 | { |
| 255 | eCSR_WLAN_HANDOFF_EVENT =0, |
| 256 | |
| 257 | }eCsrDiagWlanHandoffEventSubtype; |
| 258 | |
| 259 | typedef enum |
| 260 | { |
| 261 | eCSR_WLAN_VCC_EVENT =0, |
| 262 | |
| 263 | }eCsrDiagWlanVccEventSubtype; |
| 264 | |
| 265 | #endif //FEATURE_WLAN_DIAG_SUPPORT |
| 266 | |
| 267 | typedef struct tagCsrChannel |
| 268 | { |
| 269 | tANI_U8 numChannels; |
| 270 | tANI_U8 channelList[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 271 | }tCsrChannel; |
| 272 | |
| 273 | typedef struct tagScanProfile |
| 274 | { |
| 275 | tANI_U32 minChnTime; |
| 276 | tANI_U32 maxChnTime; |
| 277 | tANI_U32 restTime; //This is ignored if not associated |
| 278 | tANI_U32 numOfChannels; |
| 279 | tANI_U8 *pChannelList; |
| 280 | tSirScanType scanType; //active or passive |
| 281 | eCsrRoamBssType bssType; //BSS or IBSS |
| 282 | tANI_U8 ssid[WNI_CFG_SSID_LEN]; |
| 283 | tANI_U8 bReturnAfter1stMatch; |
| 284 | tANI_U8 fUniqueResult; |
| 285 | tANI_U8 freshScan; |
| 286 | tCsrBssid bssid; |
| 287 | }tScanProfile; |
| 288 | |
| 289 | typedef struct tagBssConfigParam |
| 290 | { |
| 291 | eCsrMediaAccessType qosType; |
| 292 | tSirMacSSid SSID; |
| 293 | tANI_U32 uRTSThresh; |
| 294 | tANI_U32 uDeferThresh; // |
| 295 | eCsrCfgDot11Mode uCfgDot11Mode; |
| 296 | eCsrBand eBand; |
| 297 | tANI_U8 standardRate[CSR_DOT11_SUPPORTED_RATES_MAX]; |
| 298 | tANI_U8 extendedRate[CSR_DOT11_EXTENDED_SUPPORTED_RATES_MAX]; |
| 299 | eCsrExposedTxRate txRate; |
| 300 | tAniAuthType authType; |
| 301 | eCsrEncryptionType encType; |
| 302 | tANI_U32 uShortSlotTime; |
| 303 | tANI_U32 uHTSupport; //High throughput |
| 304 | tANI_U32 uPowerLimit; |
| 305 | tANI_U32 uHeartBeatThresh; |
| 306 | tANI_U32 uJoinTimeOut; |
| 307 | tSirMacCapabilityInfo BssCap; |
| 308 | tANI_BOOLEAN f11hSupport; |
| 309 | tAniCBSecondaryMode cbMode; |
| 310 | }tBssConfigParam; |
| 311 | |
| 312 | |
| 313 | typedef struct tagCsrRoamStartBssParams |
| 314 | { |
| 315 | tSirMacSSid ssId; |
| 316 | tCsrBssid bssid; //this is the BSSID for the party we want to join (only use for IBSS or WDS) |
| 317 | tSirNwType sirNwType; |
| 318 | tAniCBSecondaryMode cbMode; |
| 319 | tSirMacRateSet operationalRateSet; |
| 320 | tSirMacRateSet extendedRateSet; |
| 321 | tANI_U8 operationChn; |
| 322 | eCsrCfgDot11Mode uCfgDot11Mode; |
| 323 | #ifdef WLAN_SOFTAP_FEATURE |
| 324 | tANI_U8 privacy; |
| 325 | tANI_BOOLEAN fwdWPSPBCProbeReq; |
| 326 | tANI_BOOLEAN protEnabled; |
| 327 | tANI_BOOLEAN obssProtEnabled; |
| 328 | tAniAuthType authType; |
| 329 | tANI_U16 beaconInterval; //If this is 0, SME will fill in for caller. |
| 330 | tANI_U16 ht_protection; |
| 331 | tANI_U32 dtimPeriod; |
| 332 | tANI_U8 ApUapsdEnable; |
| 333 | tANI_U8 ssidHidden; |
| 334 | tANI_U8 wps_state; |
| 335 | #endif |
| 336 | tVOS_CON_MODE bssPersona; |
| 337 | tANI_U16 nRSNIELength; //The byte count in the pRSNIE, if 0, pRSNIE is ignored. |
| 338 | tANI_U8 *pRSNIE; //If not null, it has the IE byte stream for RSN |
| 339 | }tCsrRoamStartBssParams; |
| 340 | |
| 341 | |
| 342 | typedef struct tagScanCmd |
| 343 | { |
| 344 | tANI_U32 scanID; |
| 345 | csrScanCompleteCallback callback; |
| 346 | void *pContext; |
| 347 | eCsrScanReason reason; |
| 348 | eCsrRoamState lastRoamState[CSR_ROAM_SESSION_MAX]; |
| 349 | tCsrRoamProfile *pToRoamProfile; |
| 350 | tANI_U32 roamId; //this is the ID related to the pToRoamProfile |
| 351 | union |
| 352 | { |
| 353 | tCsrScanRequest scanRequest; |
| 354 | tCsrBGScanRequest bgScanRequest; |
| 355 | }u; |
| 356 | }tScanCmd; |
| 357 | |
| 358 | typedef struct tagRoamCmd |
| 359 | { |
| 360 | tANI_U32 roamId; |
| 361 | eCsrRoamReason roamReason; |
| 362 | tCsrRoamProfile roamProfile; |
| 363 | tScanResultHandle hBSSList; //BSS list fits the profile |
| 364 | tListElem *pRoamBssEntry; //point to the current BSS in the list that is roaming. It starts from head to tail |
| 365 | tSirBssDescription *pLastRoamBss; //the last BSS we try and failed |
| 366 | tANI_BOOLEAN fReleaseBssList; //whether to free hBSSList |
| 367 | tANI_BOOLEAN fReleaseProfile; //whether to free roamProfile |
| 368 | tANI_BOOLEAN fReassoc; //whether this command is for reassociation |
| 369 | tANI_BOOLEAN fUpdateCurRoamProfile; //whether pMac->roam.pCurRoamProfile needs to be updated |
| 370 | //this is for CSR internal used only. And it should not be assigned when creating the command |
| 371 | //This causes the roam command not to do anything. |
| 372 | tANI_BOOLEAN fReassocToSelfNoCapChange; |
| 373 | |
| 374 | tANI_BOOLEAN fStopWds; |
| 375 | tSirMacAddr peerMac; |
| 376 | tSirMacReasonCodes reason; |
| 377 | }tRoamCmd; |
| 378 | |
| 379 | typedef struct tagSetKeyCmd |
| 380 | { |
| 381 | tANI_U32 roamId; |
| 382 | eCsrEncryptionType encType; |
| 383 | eCsrAuthType authType; |
| 384 | tAniKeyDirection keyDirection; //Tx, Rx or Tx-and-Rx |
| 385 | tSirMacAddr peerMac; //Peer's MAC address. ALL 1's for group key |
| 386 | tANI_U8 paeRole; //0 for supplicant |
| 387 | tANI_U8 keyId; // Kye index |
| 388 | tANI_U8 keyLength; //Number of bytes containing the key in pKey |
| 389 | tANI_U8 Key[CSR_MAX_KEY_LEN]; |
| 390 | tANI_U8 keyRsc[CSR_MAX_RSC_LEN]; |
| 391 | } tSetKeyCmd; |
| 392 | |
| 393 | typedef struct tahRemoveKeyCmd |
| 394 | { |
| 395 | tANI_U32 roamId; |
| 396 | eCsrEncryptionType encType; |
| 397 | eCsrAuthType authType; |
| 398 | tSirMacAddr peerMac; //Peer's MAC address. ALL 1's for group key |
| 399 | tANI_U8 keyId; //key index |
| 400 | } tRemoveKeyCmd; |
| 401 | |
| 402 | typedef struct tagWmStatusChangeCmd |
| 403 | { |
| 404 | eCsrRoamWmStatusChangeTypes Type; |
| 405 | union |
| 406 | { |
| 407 | tSirSmeDeauthInd DeauthIndMsg; |
| 408 | tSirSmeDisassocInd DisassocIndMsg; |
| 409 | }u; |
| 410 | |
| 411 | }tWmStatusChangeCmd; |
| 412 | |
| 413 | typedef struct tagAddStaForSessionCmd |
| 414 | { |
| 415 | //Session self mac addr |
| 416 | tSirMacAddr selfMacAddr; |
| 417 | }tAddStaForSessionCmd; |
| 418 | |
| 419 | typedef struct tagDelStaForSessionCmd |
| 420 | { |
| 421 | //Session self mac addr |
| 422 | tSirMacAddr selfMacAddr; |
| 423 | csrRoamSessionCloseCallback callback; |
| 424 | void *pContext; |
| 425 | }tDelStaForSessionCmd; |
| 426 | |
| 427 | //This structure represents one scan request |
| 428 | typedef struct tagCsrCmd |
| 429 | { |
| 430 | tListElem Link; |
| 431 | eCsrRoamCommands command; |
| 432 | tANI_U8 sessionId; // Session ID for this command |
| 433 | union |
| 434 | { |
| 435 | tScanCmd scanCmd; |
| 436 | tRoamCmd roamCmd; |
| 437 | tWmStatusChangeCmd wmStatusChangeCmd; |
| 438 | tSetKeyCmd setKeyCmd; |
| 439 | tRemoveKeyCmd removeKeyCmd; |
| 440 | tAddStaForSessionCmd addStaSessionCmd; |
| 441 | tDelStaForSessionCmd delStaSessionCmd; |
| 442 | }u; |
| 443 | }tCsrCmd; |
| 444 | |
| 445 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 446 | typedef struct tagCsr11rConfig |
| 447 | { |
| 448 | tANI_BOOLEAN IsFTResourceReqSupported; |
| 449 | } tCsr11rConfig; |
| 450 | #endif |
| 451 | |
| 452 | #ifdef WLAN_FEATURE_NEIGHBOR_ROAMING |
| 453 | typedef struct tagCsrNeighborRoamConfig |
| 454 | { |
| 455 | tANI_U32 nNeighborScanTimerPeriod; |
| 456 | tANI_U8 nNeighborLookupRssiThreshold; |
| 457 | tANI_U8 nNeighborReassocRssiThreshold; |
| 458 | tANI_U16 nNeighborScanMinChanTime; |
| 459 | tANI_U16 nNeighborScanMaxChanTime; |
| 460 | sCsrChannel neighborScanChanList; |
| 461 | tANI_U8 nMaxNeighborRetries; |
| 462 | tANI_U16 nNeighborResultsRefreshPeriod; |
| 463 | }tCsrNeighborRoamConfig; |
| 464 | #endif |
| 465 | |
| 466 | typedef struct tagCsrConfig |
| 467 | { |
| 468 | tANI_U32 agingCount; |
| 469 | tANI_U32 FragmentationThreshold; |
| 470 | tANI_U32 channelBondingMode24GHz; |
| 471 | tANI_U32 channelBondingMode5GHz; |
| 472 | tANI_U32 RTSThreshold; |
| 473 | eCsrPhyMode phyMode; |
| 474 | eCsrCfgDot11Mode uCfgDot11Mode; |
| 475 | eCsrBand eBand; |
| 476 | tANI_U32 HeartbeatThresh50; |
| 477 | tANI_U32 HeartbeatThresh24; |
| 478 | tANI_U32 bgScanInterval; |
| 479 | eCsrCBChoice cbChoice; |
| 480 | eCsrBand bandCapability; //indicate hw capability |
| 481 | eCsrRoamWmmUserModeType WMMSupportMode; |
| 482 | tANI_BOOLEAN Is11eSupportEnabled; |
| 483 | tANI_BOOLEAN Is11dSupportEnabled; |
| 484 | tANI_BOOLEAN Is11dSupportEnabledOriginal; |
| 485 | tANI_BOOLEAN Is11hSupportEnabled; |
| 486 | tANI_BOOLEAN shortSlotTime; |
| 487 | tANI_BOOLEAN ProprietaryRatesEnabled; |
| 488 | tANI_BOOLEAN fenableMCCMode; |
| 489 | tANI_U16 TxRate; |
| 490 | tANI_U8 AdHocChannel24; |
| 491 | tANI_U8 AdHocChannel5G; |
| 492 | tANI_U32 impsSleepTime; //in units of microseconds |
| 493 | tANI_U32 scanAgeTimeNCNPS; //scan result aging time threshold when Not-Connect-No-Power-Save, in seconds |
| 494 | tANI_U32 scanAgeTimeNCPS; //scan result aging time threshold when Not-Connect-Power-Save, in seconds |
| 495 | tANI_U32 scanAgeTimeCNPS; //scan result aging time threshold when Connect-No-Power-Save, in seconds, |
| 496 | tANI_U32 scanAgeTimeCPS; //scan result aging time threshold when Connect-Power-Savein seconds |
| 497 | tANI_U32 BssPreferValue[CSR_NUM_RSSI_CAT]; //each RSSI category has one value |
| 498 | int RSSICat[CSR_NUM_RSSI_CAT]; |
| 499 | tANI_U8 bCatRssiOffset; //to set the RSSI difference for each category |
| 500 | tANI_U32 nRoamingTime; //In seconds, CSR will try this long before gives up, 0 means no roaming |
| 501 | //Whether to limit the channels to the ones set in Csr11dInfo. If true, the opertaional |
| 502 | //channels are limited to the default channel list. It is an "AND" operation between the |
| 503 | //default channels and the channels in the 802.11d IE. |
| 504 | tANI_BOOLEAN fEnforce11dChannels; |
| 505 | //Country Code Priority |
| 506 | //0 = 802.11D > Configured Country > NV |
| 507 | //1 = Configured Country > 802.11D > NV |
| 508 | tANI_BOOLEAN fSupplicantCountryCodeHasPriority; |
| 509 | //When true, AP with unknown country code won't be see. |
| 510 | //"Unknown country code" means either Ap doesn't have 11d IE or we cannot |
| 511 | //find a domain for the country code in its 11d IE. |
| 512 | tANI_BOOLEAN fEnforceCountryCodeMatch; |
| 513 | //When true, only APs in the default domain can be seen. If the Ap has "unknown country |
| 514 | //code", or the doamin of the country code doesn't match the default domain, the Ap is |
| 515 | //not acceptable. |
| 516 | tANI_BOOLEAN fEnforceDefaultDomain; |
| 517 | |
| 518 | tANI_U16 vccRssiThreshold; |
| 519 | tANI_U32 vccUlMacLossThreshold; |
| 520 | |
| 521 | tANI_U32 nPassiveMinChnTime; //in units of milliseconds |
| 522 | tANI_U32 nPassiveMaxChnTime; //in units of milliseconds |
| 523 | tANI_U32 nActiveMinChnTime; //in units of milliseconds |
| 524 | tANI_U32 nActiveMaxChnTime; //in units of milliseconds |
| 525 | |
| 526 | tANI_BOOLEAN IsIdleScanEnabled; |
| 527 | //in dBm, the maximum TX power |
| 528 | //The actual TX power is the lesser of this value and 11d. |
| 529 | //If 11d is disable, the lesser of this and default setting. |
| 530 | tANI_U8 nTxPowerCap; |
| 531 | tANI_U32 statsReqPeriodicity; //stats request frequency from PE while in full power |
| 532 | tANI_U32 statsReqPeriodicityInPS;//stats request frequency from PE while in power save |
| 533 | #ifdef WLAN_SOFTAP_FEATURE |
| 534 | tANI_U32 dtimPeriod; |
| 535 | tANI_BOOLEAN ssidHidden; |
| 536 | #endif |
| 537 | |
| 538 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 539 | tCsr11rConfig csr11rConfig; |
| 540 | #endif |
| 541 | |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 542 | #ifdef FEATURE_WLAN_LFR |
| 543 | tANI_U8 isFastRoamIniFeatureEnabled; |
| 544 | #endif |
| 545 | |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 546 | #ifdef FEATURE_WLAN_CCX |
| 547 | tANI_U8 isCcxIniFeatureEnabled; |
| 548 | #endif |
| 549 | |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 550 | #if defined (WLAN_FEATURE_VOWIFI_11R) || defined (FEATURE_WLAN_CCX) || defined(FEATURE_WLAN_LFR) |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 551 | tANI_U8 isFastTransitionEnabled; |
| 552 | #endif |
| 553 | |
| 554 | #ifdef WLAN_FEATURE_NEIGHBOR_ROAMING |
| 555 | tCsrNeighborRoamConfig neighborRoamConfig; |
| 556 | #endif |
| 557 | |
| 558 | /* Instead of Reassoc, send ADDTS/DELTS even when ACM is off for that AC |
| 559 | * This is mandated by WMM-AC certification */ |
| 560 | tANI_BOOLEAN addTSWhenACMIsOff; |
| 561 | |
| 562 | tANI_BOOLEAN fValidateList; |
| 563 | tANI_BOOLEAN concurrencyEnabled; |
| 564 | |
| 565 | //To enable/disable scanning 2.4Ghz channels twice on a single scan request from HDD |
| 566 | tANI_BOOLEAN fScanTwice; |
| 567 | |
| 568 | }tCsrConfig; |
| 569 | |
| 570 | typedef struct tagCsrChannelPowerInfo |
| 571 | { |
| 572 | tListElem link; |
| 573 | tANI_U8 firstChannel; |
| 574 | tANI_U8 numChannels; |
| 575 | tANI_U8 txPower; |
| 576 | tANI_U8 interChannelOffset; |
| 577 | }tCsrChannelPowerInfo; |
| 578 | |
| 579 | typedef struct tagRoamJoinStatus |
| 580 | { |
| 581 | tSirResultCodes statusCode; |
| 582 | //this is set to unspecified if statusCode indicates timeout. Or it is the failed reason from the other BSS(per 802.11 spec) |
| 583 | tANI_U32 reasonCode; |
| 584 | }tCsrRoamJoinStatus; |
| 585 | |
| 586 | typedef struct tagCsrOsChannelMask |
| 587 | { |
| 588 | tANI_U8 numChannels; |
| 589 | tANI_BOOLEAN scanEnabled[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 590 | tANI_U8 channelList[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 591 | }tCsrOsChannelMask; |
| 592 | |
| 593 | |
| 594 | typedef struct tagCsrScanStruct |
| 595 | { |
| 596 | tScanProfile scanProfile; |
| 597 | tANI_U32 nextScanID; |
| 598 | tDblLinkList scanResultList; |
| 599 | tDblLinkList tempScanResults; |
| 600 | tANI_BOOLEAN fScanEnable; |
| 601 | tANI_BOOLEAN fFullScanIssued; |
| 602 | tPalTimerHandle hTimerGetResult; |
| 603 | #ifdef WLAN_AP_STA_CONCURRENCY |
| 604 | tPalTimerHandle hTimerStaApConcTimer; |
| 605 | #endif |
| 606 | tPalTimerHandle hTimerIdleScan; |
| 607 | tPalTimerHandle hTimerResultAging; |
| 608 | tPalTimerHandle hTimerBgScan; |
| 609 | //changes on every scan, it is used as a flag for whether 11d info is found on every scan |
| 610 | tANI_U8 channelOf11dInfo; |
| 611 | //changes on every scan, a flag to tell whether conflict 11d info found on each BSS |
| 612 | tANI_BOOLEAN fAmbiguous11dInfoFound; |
| 613 | //Tush: changes on every scan, a flag to tell whether the applied 11d info present in one of the scan results |
| 614 | tANI_BOOLEAN fCurrent11dInfoMatch; |
| 615 | tANI_BOOLEAN f11dInfoReset; //to indicate whether the 11d info in CFG is reset to default |
| 616 | tSirScanType curScanType; |
| 617 | tCsrChannel baseChannels; //This are all the supported channels AND(&) to the current eBand |
| 618 | tCsrChannel channels11d; |
| 619 | tChannelListWithPower defaultPowerTable[WNI_CFG_VALID_CHANNEL_LIST_LEN]; //From NV |
| 620 | tChannelListWithPower defaultPowerTable40MHz[WNI_CFG_VALID_CHANNEL_LIST_LEN]; //From NV |
| 621 | tANI_U32 numChannelsDefault; //total channels of NV |
| 622 | tCsrChannel base20MHzChannels; //The channel base to work on |
| 623 | tCsrChannel base40MHzChannels; //center channels for 40MHz channels |
| 624 | tDblLinkList channelPowerInfoList24; |
| 625 | tDblLinkList channelPowerInfoList5G; |
| 626 | tANI_U32 nLastAgeTimeOut; |
| 627 | tANI_U32 nAgingCountDown; |
| 628 | tANI_U8 countryCodeDefault[WNI_CFG_COUNTRY_CODE_LEN+1]; //The country code from NV |
| 629 | tANI_U8 countryCodeCurrent[WNI_CFG_COUNTRY_CODE_LEN+1]; |
| 630 | tANI_U8 countryCode11d[WNI_CFG_COUNTRY_CODE_LEN+1]; |
| 631 | v_REGDOMAIN_t domainIdDefault; //default regulatory domain |
| 632 | v_REGDOMAIN_t domainIdCurrent; //current regulatory domain |
| 633 | tANI_BOOLEAN f11dInfoApplied; |
| 634 | tANI_BOOLEAN fCancelIdleScan; |
| 635 | #ifdef FEATURE_WLAN_WAPI |
| 636 | // tANI_U16 NumBkidCandidate; |
| 637 | // tBkidCandidateInfo BkidCandidateInfo[CSR_MAX_BKID_ALLOWED]; /* Move this as part of SessionEntry */ |
| 638 | #endif /* FEATURE_WLAN_WAPI */ |
| 639 | tANI_U8 numBGScanChannel; //number of valid channels in the bgScanChannelList |
| 640 | tANI_U8 bgScanChannelList[WNI_CFG_BG_SCAN_CHANNEL_LIST_LEN]; |
| 641 | //the ChannelInfo member is not used in this structure. |
| 642 | //numBGScanChannel and bgScanChannelList are used for the BG scan channel info |
| 643 | tCsrBGScanRequest bgScanParams; |
| 644 | tANI_BOOLEAN fRestartIdleScan; |
| 645 | tANI_U32 nIdleScanTimeGap; //the time since last trying to trigger idle scan |
| 646 | tCsrOsChannelMask osScanChannelMask;//keep a track of channels to be scnned while in traffic condition |
| 647 | tANI_U16 nBssLimit; //the maximum number of BSS in scan cache |
| 648 | /*channelPowerInfoList24 has been seen corrupted. Set this flag to true trying to |
| 649 | * detect when it happens. Adding this into code because we can't reproduce it easily. |
| 650 | * We don't know when it happens. */ |
| 651 | tANI_BOOLEAN fValidateList; |
| 652 | /*Customer wants to start with an active scan based on the default country code. |
| 653 | * This optimization will minimize the driver load to association time. |
| 654 | * Based on this flag we will bypass the initial passive scan needed for 11d |
| 655 | * to determine the country code & domain */ |
| 656 | tANI_BOOLEAN fEnableBypass11d; |
| 657 | |
| 658 | /*Customer wants to optimize the scan time. Avoiding scans(passive) on DFS |
| 659 | * channels while swipping through both bands can save some time |
| 660 | * (apprx 1.3 sec) */ |
| 661 | tANI_BOOLEAN fEnableDFSChnlScan; |
| 662 | |
| 663 | tANI_BOOLEAN fDropScanCmd; //true means we don't accept scan commands |
| 664 | |
| 665 | #ifdef WLAN_AP_STA_CONCURRENCY |
| 666 | tDblLinkList scanCmdPendingList; |
| 667 | #endif |
| 668 | }tCsrScanStruct; |
| 669 | |
| 670 | |
| 671 | //Save the connected information. This structure + connectedProfile |
| 672 | //should contain all information about the connection |
| 673 | typedef struct tagRoamCsrConnectedInfo |
| 674 | { |
| 675 | tANI_U32 nBeaconLength; //the length, in bytes, of the beacon frame, can be 0 |
| 676 | tANI_U32 nAssocReqLength; //the length, in bytes, of the assoc req frame, can be 0 |
| 677 | tANI_U32 nAssocRspLength; //The length, in bytes, of the assoc rsp frame, can be 0 |
| 678 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 679 | tANI_U32 nRICRspLength; //Length of the parsed RIC response IEs received in reassoc response |
| 680 | #endif |
| 681 | #ifdef FEATURE_WLAN_CCX |
| 682 | tANI_U32 nTspecIeLength; |
| 683 | #endif |
| 684 | tANI_U8 *pbFrames; //Point to a buffer contain the beacon, assoc req, assoc rsp frame, in that order |
| 685 | //user needs to use nBeaconLength, nAssocReqLength, nAssocRspLength to desice where |
| 686 | //each frame starts and ends. |
| 687 | tANI_U8 staId; |
| 688 | }tCsrRoamConnectedInfo; |
| 689 | |
| 690 | |
| 691 | typedef struct tagCsrLinkQualityIndInfo |
| 692 | { |
| 693 | csrRoamLinkQualityIndCallback callback; |
| 694 | void *context; |
| 695 | }tCsrLinkQualityIndInfo; |
| 696 | |
| 697 | typedef struct tagCsrPeStatsReqInfo |
| 698 | { |
| 699 | tListElem link; /* list links */ |
| 700 | tANI_U32 statsMask; |
| 701 | tANI_U32 periodicity; |
| 702 | tANI_BOOLEAN rspPending; |
| 703 | vos_timer_t hPeStatsTimer; |
| 704 | tANI_BOOLEAN timerRunning; |
| 705 | tANI_U8 staId; |
| 706 | tANI_U8 numClient; |
| 707 | tpAniSirGlobal pMac; |
| 708 | /* To remember if the peStats timer is stopped successfully or not */ |
| 709 | tANI_BOOLEAN timerStopFailed; |
| 710 | |
| 711 | }tCsrPeStatsReqInfo; |
| 712 | |
| 713 | typedef struct tagCsrStatsClientReqInfo |
| 714 | { |
| 715 | tListElem link; /* list links */ |
| 716 | eCsrStatsRequesterType requesterId; |
| 717 | tCsrStatsCallback callback; |
| 718 | tANI_U32 periodicity; |
| 719 | void *pContext; |
| 720 | tANI_U32 statsMask; |
| 721 | tCsrPeStatsReqInfo *pPeStaEntry; |
| 722 | tANI_U8 staId; |
| 723 | vos_timer_t timer; |
| 724 | tANI_BOOLEAN timerExpired; |
| 725 | tpAniSirGlobal pMac; // TODO: Confirm this change BTAMP |
| 726 | }tCsrStatsClientReqInfo; |
| 727 | |
| 728 | typedef struct tagCsrTlStatsReqInfo |
| 729 | { |
| 730 | tANI_U32 periodicity; |
| 731 | tANI_BOOLEAN timerRunning; |
| 732 | tPalTimerHandle hTlStatsTimer; |
| 733 | tANI_U8 numClient; |
| 734 | }tCsrTlStatsReqInfo; |
| 735 | |
| 736 | typedef struct tagCsrRoamSession |
| 737 | { |
| 738 | tANI_U8 sessionId; // Session ID |
| 739 | tANI_BOOLEAN sessionActive; // TRUE if it is used |
| 740 | tCsrBssid selfMacAddr; // For BT-AMP station, this serve as BSSID for self-BSS. |
| 741 | csrRoamCompleteCallback callback; |
| 742 | void *pContext; |
| 743 | eCsrConnectState connectState; |
| 744 | tCsrRoamConnectedProfile connectedProfile; |
| 745 | tCsrRoamConnectedInfo connectedInfo; |
| 746 | tCsrRoamProfile *pCurRoamProfile; |
| 747 | tSirBssDescription *pConnectBssDesc; |
| 748 | tANI_U16 NumPmkidCache; |
| 749 | tPmkidCacheInfo PmkidCacheInfo[CSR_MAX_PMKID_ALLOWED]; |
| 750 | tANI_U8 cJoinAttemps; |
| 751 | //This may or may not have the up-to-date valid channel list |
| 752 | //It is used to get WNI_CFG_VALID_CHANNEL_LIST and not allocate memory all the time |
| 753 | tSirMacChanNum validChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 754 | tANI_S32 sPendingCommands; //0 means CSR is ok to low power |
| 755 | #ifdef FEATURE_WLAN_WAPI |
| 756 | tANI_U16 NumBkidCache; |
| 757 | tBkidCacheInfo BkidCacheInfo[CSR_MAX_BKID_ALLOWED]; |
| 758 | #endif /* FEATURE_WLAN_WAPI */ |
| 759 | tANI_BOOLEAN fRoaming; //indicate whether CSR is roaming (either via lostlink or dynamic roaming) |
| 760 | //to remember some parameters needed for START_BSS. |
| 761 | //All member must be set every time we try to join or start an IBSS or BT-AMP |
| 762 | tCsrRoamStartBssParams bssParams; |
| 763 | tANI_U32 nWpaRsnReqIeLength; //the byte count of pWpaRsnIE; |
| 764 | tANI_U8 *pWpaRsnReqIE; //this contain the WPA/RSN IE in assoc request or the one sent in beacon (IBSS) |
| 765 | tANI_U32 nWpaRsnRspIeLength; //the byte count for pWpaRsnRspIE |
| 766 | tANI_U8 *pWpaRsnRspIE; //this contain the WPA/RSN IE in beacon/probe rsp |
| 767 | #ifdef FEATURE_WLAN_WAPI |
| 768 | tANI_U32 nWapiReqIeLength; //the byte count of pWapiReqIE; |
| 769 | tANI_U8 *pWapiReqIE; //this contain the WAPI IE in assoc request or the one sent in beacon (IBSS) |
| 770 | tANI_U32 nWapiRspIeLength; //the byte count for pWapiRspIE |
| 771 | tANI_U8 *pWapiRspIE; //this contain the WAPI IE in beacon/probe rsp |
| 772 | #endif /* FEATURE_WLAN_WAPI */ |
| 773 | tANI_U32 nAddIEScanLength; //the byte count of pAddIeScanIE; |
| 774 | tANI_U8 *pAddIEScan; //this contains the additional IE in (unicast) probe request at the time of join |
| 775 | tANI_U32 nAddIEAssocLength; //the byte count for pAddIeAssocIE |
| 776 | tANI_U8 *pAddIEAssoc; //this contains the additional IE in (re) assoc request |
| 777 | |
| 778 | tANI_TIMESTAMP roamingStartTime; //in units of 10ms |
| 779 | tCsrTimerInfo roamingTimerInfo; |
| 780 | eCsrRoamingReason roamingReason; |
| 781 | tANI_BOOLEAN fCancelRoaming; |
| 782 | tPalTimerHandle hTimerRoaming; |
| 783 | tPalTimerHandle hTimerIbssJoining; |
| 784 | tCsrTimerInfo ibssJoinTimerInfo; |
| 785 | tANI_BOOLEAN ibss_join_pending; |
| 786 | eCsrRoamResult roamResult; //the roamResult that is used when the roaming timer fires |
| 787 | tCsrRoamJoinStatus joinFailStatusCode; //This is the reason code for join(assoc) failure |
| 788 | //The status code returned from PE for deauth or disassoc (in case of lostlink), or our own dynamic roaming |
| 789 | tANI_U32 roamingStatusCode; |
| 790 | tANI_U16 NumPmkidCandidate; |
| 791 | tPmkidCandidateInfo PmkidCandidateInfo[CSR_MAX_PMKID_ALLOWED]; |
| 792 | #ifdef FEATURE_WLAN_WAPI |
| 793 | tANI_U16 NumBkidCandidate; |
| 794 | tBkidCandidateInfo BkidCandidateInfo[CSR_MAX_BKID_ALLOWED]; |
| 795 | #endif |
| 796 | tANI_BOOLEAN fWMMConnection; |
| 797 | #ifdef FEATURE_WLAN_BTAMP_UT_RF |
| 798 | //To retry a join later when it fails if so desired |
| 799 | tPalTimerHandle hTimerJoinRetry; |
| 800 | tCsrTimerInfo joinRetryTimerInfo; |
| 801 | tANI_U32 maxRetryCount; |
| 802 | #endif |
| 803 | #ifdef FEATURE_WLAN_CCX |
| 804 | tCsrCcxCckmInfo ccxCckmInfo; |
| 805 | tANI_BOOLEAN isPrevApInfoValid; |
| 806 | tSirMacSSid prevApSSID; |
| 807 | tCsrBssid prevApBssid; |
| 808 | tANI_U8 prevOpChannel; |
| 809 | tANI_U16 clientDissSecs; |
| 810 | tANI_U32 roamTS1; |
| 811 | #endif |
| 812 | tANI_U8 bRefAssocStartCnt; //Tracking assoc start indication |
| 813 | } tCsrRoamSession; |
| 814 | |
| 815 | typedef struct tagCsrRoamStruct |
| 816 | { |
| 817 | tANI_U32 nextRoamId; |
| 818 | tDblLinkList roamCmdPendingList; |
| 819 | tDblLinkList channelList5G; |
| 820 | tDblLinkList channelList24; |
| 821 | tCsrConfig configParam; |
| 822 | tANI_U32 numChannelsEeprom; //total channels of eeprom |
| 823 | tCsrChannel base20MHzChannels; //The channel base to work on |
| 824 | tCsrChannel base40MHzChannels; //center channels for 40MHz channels |
| 825 | eCsrRoamState curState[CSR_ROAM_SESSION_MAX]; |
| 826 | eCsrRoamSubState curSubState[CSR_ROAM_SESSION_MAX]; |
| 827 | //This may or may not have the up-to-date valid channel list |
| 828 | //It is used to get WNI_CFG_VALID_CHANNEL_LIST and not allocate memory all the time |
| 829 | tSirMacChanNum validChannelList[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 830 | tANI_U32 numValidChannels; //total number of channels in CFG |
| 831 | |
| 832 | tANI_S32 sPendingCommands; |
| 833 | tChannelListWithPower *powerTableFromEeprom; |
| 834 | tChannelListWithPower *powerTableFromEeprom40MHz; |
| 835 | tPalTimerHandle hTimerWaitForKey; //To support timeout for WaitForKey state |
| 836 | tCsrSummaryStatsInfo summaryStatsInfo; |
| 837 | tCsrGlobalClassAStatsInfo classAStatsInfo; |
| 838 | tCsrGlobalClassBStatsInfo classBStatsInfo; |
| 839 | tCsrGlobalClassCStatsInfo classCStatsInfo; |
| 840 | tCsrGlobalClassDStatsInfo classDStatsInfo; |
| 841 | tCsrPerStaStatsInfo perStaStatsInfo[CSR_MAX_STA]; |
| 842 | tDblLinkList statsClientReqList; |
| 843 | tDblLinkList peStatsReqList; |
| 844 | tCsrTlStatsReqInfo tlStatsReqInfo; |
| 845 | eCsrRoamLinkQualityInd vccLinkQuality; |
| 846 | tCsrLinkQualityIndInfo linkQualityIndInfo; |
| 847 | v_CONTEXT_t gVosContext; //used for interaction with TL |
| 848 | //To specify whether an association or a IBSS is WMM enabled |
| 849 | //This parameter is only valid during a join or start BSS command is being executed |
| 850 | //tANI_BOOLEAN fWMMConnection; /* Moving it to be part of roamsession */ |
| 851 | v_U8_t ucACWeights[WLANTL_MAX_AC]; |
| 852 | /* TODO : Upto here */ |
| 853 | tCsrTimerInfo WaitForKeyTimerInfo; |
| 854 | tCsrRoamSession *roamSession; |
| 855 | tANI_U32 transactionId; // Current transaction ID for internal use. |
| 856 | #ifdef WLAN_FEATURE_NEIGHBOR_ROAMING |
| 857 | tCsrNeighborRoamControlInfo neighborRoamInfo; |
| 858 | #endif |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 859 | #ifdef FEATURE_WLAN_LFR |
| 860 | tANI_U8 isFastRoamIniFeatureEnabled; |
| 861 | #endif |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 862 | #ifdef FEATURE_WLAN_CCX |
| 863 | tANI_U8 isCcxIniFeatureEnabled; |
| 864 | #endif |
| 865 | }tCsrRoamStruct; |
| 866 | |
| 867 | |
| 868 | #define GET_NEXT_ROAM_ID(pRoamStruct) (((pRoamStruct)->nextRoamId + 1 == 0) ? 1 : (pRoamStruct)->nextRoamId) |
| 869 | #define CSR_IS_ROAM_STATE(pMac, state, sessionId) ( (state) == (pMac)->roam.curState[sessionId] ) |
| 870 | |
| 871 | #define CSR_IS_ROAM_STOP(pMac, sessionId) CSR_IS_ROAM_STATE( (pMac), eCSR_ROAMING_STATE_STOP, sessionId ) |
| 872 | #define CSR_IS_ROAM_INIT(pMac, sessionId) CSR_IS_ROAM_STATE( (pMac), eCSR_ROAMING_STATE_INIT, sessionId ) |
| 873 | #define CSR_IS_ROAM_SCANNING(pMac, sessionId) CSR_IS_ROAM_STATE( pMac, eCSR_ROAMING_STATE_SCANNING, sessionId ) |
| 874 | #define CSR_IS_ROAM_JOINING(pMac, sessionId) CSR_IS_ROAM_STATE( pMac, eCSR_ROAMING_STATE_JOINING, sessionId ) |
| 875 | #define CSR_IS_ROAM_IDLE(pMac, sessionId) CSR_IS_ROAM_STATE( pMac, eCSR_ROAMING_STATE_IDLE, sessionId ) |
| 876 | #define CSR_IS_ROAM_JOINED(pMac, sessionId) CSR_IS_ROAM_STATE( pMac, eCSR_ROAMING_STATE_JOINED, sessionId ) |
| 877 | |
| 878 | #define CSR_IS_ROAM_SUBSTATE(pMac, subState, sessionId) ((subState) == (pMac)->roam.curSubState[sessionId]) |
| 879 | #define CSR_IS_ROAM_SUBSTATE_JOIN_REQ(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_JOIN_REQ, sessionId) |
| 880 | #define CSR_IS_ROAM_SUBSTATE_AUTH_REQ(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_AUTH_REQ, sessionId) |
| 881 | #define CSR_IS_ROAM_SUBSTATE_REASSOC_REQ(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_REASSOC_REQ, sessionId) |
| 882 | #define CSR_IS_ROAM_SUBSTATE_DISASSOC_REQ(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_DISASSOC_REQ, sessionId) |
| 883 | #define CSR_IS_ROAM_SUBSTATE_DISASSOC_NO_JOIN(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_DISASSOC_NOTHING_TO_JOIN, sessionId) |
| 884 | #define CSR_IS_ROAM_SUBSTATE_REASSOC_FAIL(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_DISASSOC_REASSOC_FAILURE, sessionId) |
| 885 | #define CSR_IS_ROAM_SUBSTATE_DISASSOC_FORCED(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_DISASSOC_FORCED, sessionId) |
| 886 | #define CSR_IS_ROAM_SUBSTATE_DEAUTH_REQ(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_DEAUTH_REQ, sessionId) |
| 887 | #define CSR_IS_ROAM_SUBSTATE_START_BSS_REQ(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_START_BSS_REQ, sessionId) |
| 888 | #define CSR_IS_ROAM_SUBSTATE_STOP_BSS_REQ(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_STOP_BSS_REQ, sessionId) |
| 889 | #define CSR_IS_ROAM_SUBSTATE_DISCONNECT_CONTINUE(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_DISCONNECT_CONTINUE_ROAMING, sessionId) |
| 890 | #define CSR_IS_ROAM_SUBSTATE_CONFIG(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_CONFIG, sessionId) |
| 891 | #define CSR_IS_ROAM_SUBSTATE_WAITFORKEY(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_WAIT_FOR_KEY, sessionId) |
| 892 | #define CSR_IS_ROAM_SUBSTATE_DISASSOC_HO(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_DISASSOC_HANDOFF, sessionId) |
| 893 | #define CSR_IS_ROAM_SUBSTATE_HO_NT(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_JOINED_NO_TRAFFIC, sessionId) |
| 894 | #define CSR_IS_ROAM_SUBSTATE_HO_NRT(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_JOINED_NON_REALTIME_TRAFFIC, sessionId) |
| 895 | #define CSR_IS_ROAM_SUBSTATE_HO_RT(pMac, sessionId) CSR_IS_ROAM_SUBSTATE((pMac), eCSR_ROAM_SUBSTATE_JOINED_REALTIME_TRAFFIC, sessionId) |
| 896 | |
| 897 | #define CSR_IS_PHY_MODE_B_ONLY(pMac) \ |
| 898 | ((eCSR_DOT11_MODE_11b == (pMac)->roam.configParam.phyMode) ||\ |
| 899 | (eCSR_DOT11_MODE_11b_ONLY == (pMac)->roam.configParam.phyMode)) |
| 900 | |
| 901 | #define CSR_IS_PHY_MODE_G_ONLY(pMac) \ |
| 902 | (eCSR_DOT11_MODE_11g == (pMac)->roam.configParam.phyMode || eCSR_DOT11_MODE_11g_ONLY == (pMac)->roam.configParam.phyMode) |
| 903 | |
| 904 | #define CSR_IS_PHY_MODE_A_ONLY(pMac) \ |
| 905 | ((eCSR_DOT11_MODE_11a == (pMac)->roam.configParam.phyMode) ||\ |
| 906 | (eCSR_DOT11_MODE_11a_ONLY == (pMac)->roam.configParam.phyMode)) |
| 907 | |
| 908 | #define CSR_IS_PHY_MODE_DUAL_BAND(phyMode) \ |
| 909 | ((eCSR_DOT11_MODE_abg & (phyMode)) || (eCSR_DOT11_MODE_11n & (phyMode)) || \ |
| 910 | (eCSR_DOT11_MODE_TAURUS & (phyMode)) || \ |
| 911 | (eCSR_DOT11_MODE_AUTO & (phyMode))) |
| 912 | |
| 913 | // this function returns TRUE if the NIC is operating exclusively in the 2.4 GHz band, meaning |
| 914 | // it is NOT operating in the 5.0 GHz band. |
| 915 | #define CSR_IS_24_BAND_ONLY(pMac) \ |
| 916 | (eCSR_BAND_24 == (pMac)->roam.configParam.eBand) |
| 917 | |
| 918 | #define CSR_IS_5G_BAND_ONLY(pMac) \ |
| 919 | (eCSR_BAND_5G == (pMac)->roam.configParam.eBand) |
| 920 | |
| 921 | #define CSR_IS_RADIO_DUAL_BAND(pMac) \ |
| 922 | (eCSR_BAND_ALL == (pMac)->roam.configParam.bandCapability) |
| 923 | |
| 924 | #define CSR_IS_RADIO_BG_ONLY(pMac) \ |
| 925 | (eCSR_BAND_24 == (pMac)->roam.configParam.bandCapability) |
| 926 | |
| 927 | // this function returns TRUE if the NIC is operating exclusively in the 5.0 GHz band, meaning |
| 928 | // it is NOT operating in the 2.4 GHz band |
| 929 | #define CSR_IS_RADIO_A_ONLY(pMac) \ |
| 930 | (eCSR_BAND_5G == (pMac)->roam.configParam.bandCapability) |
| 931 | |
| 932 | // this function returns TRUE if the NIC is operating in both bands. |
| 933 | #define CSR_IS_OPEARTING_DUAL_BAND(pMac) \ |
| 934 | ((eCSR_BAND_ALL == (pMac)->roam.configParam.bandCapability) && (eCSR_BAND_ALL == (pMac)->roam.configParam.eBand)) |
| 935 | |
| 936 | // this function returns TRUE if the NIC can operate in the 5.0 GHz band (could operate in the |
| 937 | // 2.4 GHz band also). |
| 938 | #define CSR_IS_OPERATING_A_BAND(pMac) \ |
| 939 | (CSR_IS_OPEARTING_DUAL_BAND((pMac)) || CSR_IS_RADIO_A_ONLY((pMac)) || CSR_IS_5G_BAND_ONLY((pMac))) |
| 940 | |
| 941 | // this function returns TRUE if the NIC can operate in the 2.4 GHz band (could operate in the |
| 942 | // 5.0 GHz band also). |
| 943 | #define CSR_IS_OPERATING_BG_BAND(pMac) \ |
| 944 | (CSR_IS_OPEARTING_DUAL_BAND((pMac)) || CSR_IS_RADIO_BG_ONLY((pMac)) || CSR_IS_24_BAND_ONLY((pMac))) |
| 945 | |
| 946 | #define CSR_IS_CHANNEL_5GHZ(chnNum) \ |
| 947 | ((chnNum) > CSR_MAX_24GHz_CHANNEL_NUMBER) |
| 948 | |
| 949 | #define CSR_IS_CHANNEL_24GHZ(chnNum) \ |
| 950 | (((chnNum) > 0) && ((chnNum) <= CSR_MAX_24GHz_CHANNEL_NUMBER)) |
| 951 | |
| 952 | #define CSR_IS_SAME_BAND_CHANNELS(ch1, ch2) (CSR_IS_CHANNEL_5GHZ(ch1) == CSR_IS_CHANNEL_5GHZ(ch2)) |
| 953 | |
| 954 | |
| 955 | #define CSR_IS_11D_INFO_FOUND(pMac) \ |
| 956 | (0 != (pMac)->scan.channelOf11dInfo) |
| 957 | // DEAUTHIND |
| 958 | #define CSR_IS_ROAMING(pSession) ((CSR_IS_LOSTLINK_ROAMING((pSession)->roamingReason)) || \ |
| 959 | (eCsrDynamicRoaming == (pSession)->roamingReason) || \ |
| 960 | (eCsrReassocRoaming == (pSession)->roamingReason)) |
| 961 | |
| 962 | |
| 963 | #define CSR_IS_SET_KEY_COMMAND( pCommand ) ( eSmeCommandSetKey == (pCommand)->command ) |
| 964 | |
| 965 | #define CSR_IS_ADDTS_WHEN_ACMOFF_SUPPORTED(pMac) (pMac->roam.configParam.addTSWhenACMIsOff) |
| 966 | // DEAUTHIND |
| 967 | #define CSR_IS_LOSTLINK_ROAMING(reason) ((eCsrLostlinkRoamingDisassoc == (reason)) || (eCsrLostlinkRoamingDeauth == (reason))) |
| 968 | |
| 969 | //Stop CSR from asking for IMPS, This function doesn't disable IMPS from CSR |
| 970 | void csrScanSuspendIMPS( tpAniSirGlobal pMac ); |
| 971 | //Start CSR from asking for IMPS. This function doesn't trigger CSR to request entering IMPS |
| 972 | //because IMPS maybe disabled. |
| 973 | void csrScanResumeIMPS( tpAniSirGlobal pMac ); |
| 974 | |
| 975 | eHalStatus csrInitGetChannels(tpAniSirGlobal pMac); |
| 976 | |
| 977 | eHalStatus csrSetModifyProfileFields(tpAniSirGlobal pMac, tANI_U32 sessionId, |
| 978 | tCsrRoamModifyProfileFields *pModifyProfileFields); |
| 979 | /* --------------------------------------------------------------------------- |
| 980 | \fn csrGetModifyProfileFields |
| 981 | \brief HDD or SME - QOS calls this function to get the current values of |
| 982 | connected profile fields changing which can cause reassoc. |
| 983 | This function must be called after CFG is downloaded and STA is in connected |
| 984 | state. |
| 985 | \param pModifyProfileFields - pointer to the connected profile fields |
| 986 | changing which can cause reassoc |
| 987 | |
| 988 | \return eHalStatus |
| 989 | -------------------------------------------------------------------------------*/ |
| 990 | eHalStatus csrGetModifyProfileFields(tpAniSirGlobal pMac, tANI_U32 sessionId, |
| 991 | tCsrRoamModifyProfileFields * pModifyProfileFields); |
| 992 | void csrSetGlobalCfgs( tpAniSirGlobal pMac ); |
| 993 | void csrSetDefaultDot11Mode( tpAniSirGlobal pMac ); |
| 994 | void csrScanSetChannelMask(tpAniSirGlobal pMac, tCsrChannelInfo *pChannelInfo); |
| 995 | tANI_BOOLEAN csrIsConnStateDisconnected(tpAniSirGlobal pMac, tANI_U32 sessionId); |
| 996 | tANI_BOOLEAN csrIsConnStateConnectedIbss( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 997 | tANI_BOOLEAN csrIsConnStateDisconnectedIbss( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 998 | tANI_BOOLEAN csrIsConnStateConnectedInfra( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 999 | tANI_BOOLEAN csrIsConnStateConnected( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1000 | tANI_BOOLEAN csrIsConnStateInfra( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1001 | tANI_BOOLEAN csrIsConnStateIbss( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1002 | tANI_BOOLEAN csrIsConnStateWds( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1003 | tANI_BOOLEAN csrIsConnStateConnectedWds( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1004 | tANI_BOOLEAN csrIsConnStateDisconnectedWds( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1005 | tANI_BOOLEAN csrIsAnySessionInConnectState( tpAniSirGlobal pMac ); |
| 1006 | tANI_BOOLEAN csrIsAllSessionDisconnected( tpAniSirGlobal pMac ); |
| 1007 | tANI_BOOLEAN csrIsInfraConnected( tpAniSirGlobal pMac ); |
| 1008 | tANI_BOOLEAN csrIsConcurrentInfraConnected( tpAniSirGlobal pMac ); |
| 1009 | tANI_BOOLEAN csrIsIBSSStarted( tpAniSirGlobal pMac ); |
| 1010 | tANI_BOOLEAN csrIsBTAMPStarted( tpAniSirGlobal pMac ); |
| 1011 | tANI_BOOLEAN csrIsBTAMP( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1012 | eHalStatus csrIsBTAMPAllowed( tpAniSirGlobal pMac, tANI_U32 chnId ); |
| 1013 | tANI_BOOLEAN csrIsValidMcConcurrentSession(tpAniSirGlobal pMac, tANI_U32 sessionId); |
| 1014 | #ifdef WLAN_SOFTAP_FEATURE |
| 1015 | tANI_BOOLEAN csrIsConnStateConnectedInfraAp( tpAniSirGlobal pMac, tANI_U32 sessionId ); |
| 1016 | #endif |
| 1017 | /*---------------------------------------------------------------------------- |
| 1018 | \fn csrRoamRegisterLinkQualityIndCallback |
| 1019 | |
| 1020 | \brief |
| 1021 | a CSR function to allow HDD to register a callback handler with CSR for |
| 1022 | link quality indications. |
| 1023 | |
| 1024 | Only one callback may be registered at any time. |
| 1025 | In order to deregister the callback, a NULL cback may be provided. |
| 1026 | |
| 1027 | Registration happens in the task context of the caller. |
| 1028 | |
| 1029 | \param callback - Call back being registered |
| 1030 | \param pContext - user data |
| 1031 | |
| 1032 | DEPENDENCIES: After CSR open |
| 1033 | |
| 1034 | \return eHalStatus |
| 1035 | -----------------------------------------------------------------------------*/ |
| 1036 | eHalStatus csrRoamRegisterLinkQualityIndCallback(tpAniSirGlobal pMac, |
| 1037 | csrRoamLinkQualityIndCallback callback, |
| 1038 | void *pContext); |
| 1039 | /* --------------------------------------------------------------------------- |
| 1040 | \fn csrGetStatistics |
| 1041 | \brief csr function that client calls to register a callback to get |
| 1042 | different PHY level statistics from CSR. |
| 1043 | |
| 1044 | \param requesterId - different client requesting for statistics, HDD, UMA/GAN etc |
| 1045 | \param statsMask - The different category/categories of stats requester is looking for |
| 1046 | \param callback - SME sends back the requested stats using the callback |
| 1047 | \param periodicity - If requester needs periodic update, 0 means it's an one |
| 1048 | time request |
| 1049 | \param cache - If requester is happy with cached stats |
| 1050 | \param staId - The station ID for which the stats is requested for |
| 1051 | \param pContext - user context to be passed back along with the callback |
| 1052 | |
| 1053 | \return eHalStatus |
| 1054 | ---------------------------------------------------------------------------*/ |
| 1055 | eHalStatus csrGetStatistics(tpAniSirGlobal pMac, eCsrStatsRequesterType requesterId, |
| 1056 | tANI_U32 statsMask, |
| 1057 | tCsrStatsCallback callback, |
| 1058 | tANI_U32 periodicity, tANI_BOOLEAN cache, |
| 1059 | tANI_U8 staId, void *pContext); |
| 1060 | |
| 1061 | |
| 1062 | eHalStatus csrGetRssi(tpAniSirGlobal pMac,tCsrRssiCallback callback,tANI_U8 staId,tCsrBssid bssId,void * pContext,void * pVosContext); |
| 1063 | eHalStatus csrRoamRegisterCallback(tpAniSirGlobal pMac, csrRoamCompleteCallback callback, void *pContext); |
| 1064 | /* --------------------------------------------------------------------------- |
| 1065 | \fn csrGetConfigParam |
| 1066 | \brief HDD calls this function to get the global settings currently maintained by CSR. |
| 1067 | \param pParam - caller allocated memory |
| 1068 | \return eHalStatus |
| 1069 | -------------------------------------------------------------------------------*/ |
| 1070 | eHalStatus csrGetConfigParam(tpAniSirGlobal pMac, tCsrConfigParam *pParam); |
| 1071 | |
| 1072 | /* --------------------------------------------------------------------------- |
| 1073 | \fn csrMsgProcessor |
| 1074 | \brief HDD calls this function to change some global settings. |
| 1075 | caller must set the all fields or call csrGetConfigParam to prefill the fields. |
| 1076 | \param pParam - caller allocated memory |
| 1077 | \return eHalStatus |
| 1078 | -------------------------------------------------------------------------------*/ |
| 1079 | eHalStatus csrChangeDefaultConfigParam(tpAniSirGlobal pMac, tCsrConfigParam *pParam); |
| 1080 | |
| 1081 | |
| 1082 | /* --------------------------------------------------------------------------- |
| 1083 | \fn csrMsgProcessor |
| 1084 | \brief HDD calls this function for the messages that are handled by CSR. |
| 1085 | \param pMsgBuf - a pointer to a buffer that maps to various structures base on the message type. |
| 1086 | The beginning of the buffer can always map to tSirSmeRsp. |
| 1087 | \return eHalStatus |
| 1088 | -------------------------------------------------------------------------------*/ |
| 1089 | eHalStatus csrMsgProcessor( tpAniSirGlobal pMac, void *pMsgBuf ); |
| 1090 | |
| 1091 | /* --------------------------------------------------------------------------- |
| 1092 | \fn csrOpen |
| 1093 | \brief This function must be called before any API call to CSR. |
| 1094 | \return eHalStatus |
| 1095 | -------------------------------------------------------------------------------*/ |
| 1096 | eHalStatus csrOpen(tpAniSirGlobal pMac); |
| 1097 | /* --------------------------------------------------------------------------- |
| 1098 | \fn csrClose |
| 1099 | \brief To close down CSR module. There should not be any API call into CSR after calling this function. |
| 1100 | \return eHalStatus |
| 1101 | -------------------------------------------------------------------------------*/ |
| 1102 | eHalStatus csrClose(tpAniSirGlobal pMac); |
| 1103 | /* --------------------------------------------------------------------------- |
| 1104 | \fn csrStart |
| 1105 | \brief To start CSR. |
| 1106 | \return eHalStatus |
| 1107 | -------------------------------------------------------------------------------*/ |
| 1108 | eHalStatus csrStart(tpAniSirGlobal pMac); |
| 1109 | /* --------------------------------------------------------------------------- |
| 1110 | \fn csrStop |
| 1111 | \brief To stop CSR. CSR still keeps its current setting. |
| 1112 | \return eHalStatus |
| 1113 | -------------------------------------------------------------------------------*/ |
| 1114 | eHalStatus csrStop(tpAniSirGlobal pMac); |
| 1115 | /* --------------------------------------------------------------------------- |
| 1116 | \fn csrReady |
| 1117 | \brief To let CSR is ready to operate |
| 1118 | \return eHalStatus |
| 1119 | -------------------------------------------------------------------------------*/ |
| 1120 | eHalStatus csrReady(tpAniSirGlobal pMac); |
| 1121 | |
| 1122 | #ifdef FEATURE_WLAN_WAPI |
| 1123 | eHalStatus csrRoamGetBKIDCache(tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_U32 *pNum, |
| 1124 | tBkidCacheInfo *pBkidCache); |
| 1125 | |
| 1126 | |
| 1127 | eHalStatus csrScanGetBKIDCandidateList(tpAniSirGlobal pMac, tANI_U32 sessionId, |
| 1128 | tBkidCandidateInfo *pBkidList, tANI_U32 *pNumItems ); |
| 1129 | tANI_U32 csrRoamGetNumBKIDCache(tpAniSirGlobal pMac, tANI_U32 sessionId); |
| 1130 | eHalStatus csrRoamSetBKIDCache( tpAniSirGlobal pMac, tANI_U32 sessionId, tBkidCacheInfo *pBKIDCache, |
| 1131 | tANI_U32 numItems ); |
| 1132 | /* --------------------------------------------------------------------------- |
| 1133 | \fn csrRoamGetWapiReqIE |
| 1134 | \brief return the WAPI IE CSR passes to PE to JOIN request or START_BSS request |
| 1135 | \param pLen - caller allocated memory that has the length of pBuf as input. Upon returned, *pLen has the |
| 1136 | needed or IE length in pBuf. |
| 1137 | \param pBuf - Caller allocated memory that contain the IE field, if any, upon return |
| 1138 | \return eHalStatus - when fail, it usually means the buffer allocated is not big enough |
| 1139 | -------------------------------------------------------------------------------*/ |
| 1140 | eHalStatus csrRoamGetWapiReqIE(tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_U32 *pLen, tANI_U8 *pBuf); |
| 1141 | |
| 1142 | /* --------------------------------------------------------------------------- |
| 1143 | \fn csrRoamGetWapiRspIE |
| 1144 | \brief return the WAPI IE from the beacon or probe rsp if connected |
| 1145 | \param pLen - caller allocated memory that has the length of pBuf as input. Upon returned, *pLen has the |
| 1146 | needed or IE length in pBuf. |
| 1147 | \param pBuf - Caller allocated memory that contain the IE field, if any, upon return |
| 1148 | \return eHalStatus - when fail, it usually means the buffer allocated is not big enough |
| 1149 | -------------------------------------------------------------------------------*/ |
| 1150 | eHalStatus csrRoamGetWapiRspIE(tpAniSirGlobal pMac, tANI_U32 sessionId, tANI_U32 *pLen, tANI_U8 *pBuf); |
| 1151 | tANI_U8 csrConstructWapiIe( tpAniSirGlobal pMac, tANI_U32 sessionId, tCsrRoamProfile *pProfile, |
| 1152 | tSirBssDescription *pSirBssDesc, tDot11fBeaconIEs *pIes, tCsrWapiIe *pWapiIe ); |
| 1153 | #endif /* FEATURE_WLAN_WAPI */ |
| 1154 | |
| 1155 | #ifdef WLAN_SOFTAP_FEATURE |
| 1156 | eHalStatus csrRoamUpdateAPWPSIE( tpAniSirGlobal pMac, tANI_U32 sessionId, tSirAPWPSIEs *pAPWPSIES ); |
| 1157 | eHalStatus csrRoamUpdateWPARSNIEs( tpAniSirGlobal pMac, tANI_U32 sessionId, tSirRSNie * pAPSirRSNie); |
| 1158 | #endif |
| 1159 | void csrSetCfgPrivacy( tpAniSirGlobal pMac, tCsrRoamProfile *pProfile, tANI_BOOLEAN fPrivacy ); |
| 1160 | tANI_S8 csrGetInfraSessionId( tpAniSirGlobal pMac ); |
| 1161 | tANI_U8 csrGetInfraOperationChannel( tpAniSirGlobal pMac, tANI_U8 sessionId); |
| 1162 | tANI_U8 csrGetConcurrentOperationChannel( tpAniSirGlobal pMac ); |
| 1163 | |
| 1164 | eHalStatus csrRoamCopyConnectProfile(tpAniSirGlobal pMac, tANI_U32 sessionId, |
| 1165 | tCsrRoamConnectedProfile *pProfile); |
| 1166 | tANI_BOOLEAN csrIsSetKeyAllowed(tpAniSirGlobal pMac, tANI_U32 sessionId); |
| 1167 | |
| 1168 | void csrSetOppositeBandChannelInfo( tpAniSirGlobal pMac ); |
| 1169 | void csrConstructCurrentValidChannelList( tpAniSirGlobal pMac, tDblLinkList *pChannelSetList, |
| 1170 | tANI_U8 *pChannelList, tANI_U8 bSize, tANI_U8 *pNumChannels ); |
| 1171 | |
| 1172 | #endif |
| 1173 | |
| 1174 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 1175 | //Returns whether the current association is a 11r assoc or not |
| 1176 | tANI_BOOLEAN csrRoamIs11rAssoc(tpAniSirGlobal pMac); |
| 1177 | #endif |
| 1178 | |
| 1179 | #ifdef FEATURE_WLAN_CCX |
| 1180 | //Returns whether the current association is a CCX assoc or not |
| 1181 | tANI_BOOLEAN csrRoamIsCCXAssoc(tpAniSirGlobal pMac); |
| 1182 | #endif |
| 1183 | |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 1184 | |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1185 | void csrDisconnectAllActiveSessions(tpAniSirGlobal pMac); |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 1186 | #ifdef FEATURE_WLAN_LFR |
| 1187 | //Returns whether "Legacy Fast Roaming" is enabled...or not |
| 1188 | tANI_BOOLEAN csrRoamIsFastRoamEnabled(tpAniSirGlobal pMac); |
| 1189 | #endif |
| 1190 | |