Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1 | /* |
Gopichand Nakkala | 92f07d8 | 2013-01-08 21:16:34 -0800 | [diff] [blame] | 2 | * Copyright (c) 2012-2013, 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 | /* |
Jeff Johnson | 32d95a3 | 2012-09-10 13:15:23 -0700 | [diff] [blame] | 22 | * Copyright (c) 2012, The Linux Foundation. All rights reserved. |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 23 | * |
| 24 | * Previously licensed under the ISC license by Qualcomm Atheros, Inc. |
| 25 | * |
| 26 | * |
| 27 | * Permission to use, copy, modify, and/or distribute this software for |
| 28 | * any purpose with or without fee is hereby granted, provided that the |
| 29 | * above copyright notice and this permission notice appear in all |
| 30 | * copies. |
| 31 | * |
| 32 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL |
| 33 | * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED |
| 34 | * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE |
| 35 | * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL |
| 36 | * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR |
| 37 | * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
| 38 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
| 39 | * PERFORMANCE OF THIS SOFTWARE. |
| 40 | */ |
| 41 | |
| 42 | /** ------------------------------------------------------------------------- * |
| 43 | ------------------------------------------------------------------------- * |
| 44 | \file csrApi.h |
| 45 | |
| 46 | Exports and types for the Common Scan and Roaming Module interfaces. |
| 47 | |
| 48 | Copyright (C) 2006 Airgo Networks, Incorporated |
| 49 | ========================================================================== */ |
| 50 | #ifndef CSRAPI_H__ |
| 51 | #define CSRAPI_H__ |
| 52 | |
| 53 | #include "sirApi.h" |
| 54 | #include "sirMacProtDef.h" |
| 55 | #ifdef FEATURE_WLAN_NON_INTEGRATED_SOC |
| 56 | #include "halRfTypes.h" |
| 57 | #endif |
| 58 | #include "csrLinkList.h" |
| 59 | |
| 60 | typedef enum |
| 61 | { |
| 62 | eCSR_AUTH_TYPE_NONE, //never used |
| 63 | // MAC layer authentication types |
| 64 | eCSR_AUTH_TYPE_OPEN_SYSTEM, |
| 65 | eCSR_AUTH_TYPE_SHARED_KEY, |
| 66 | eCSR_AUTH_TYPE_AUTOSWITCH, |
| 67 | |
| 68 | // Upper layer authentication types |
| 69 | eCSR_AUTH_TYPE_WPA, |
| 70 | eCSR_AUTH_TYPE_WPA_PSK, |
| 71 | eCSR_AUTH_TYPE_WPA_NONE, |
| 72 | |
| 73 | eCSR_AUTH_TYPE_RSN, |
| 74 | eCSR_AUTH_TYPE_RSN_PSK, |
| 75 | #if defined WLAN_FEATURE_VOWIFI_11R |
| 76 | eCSR_AUTH_TYPE_FT_RSN, |
| 77 | eCSR_AUTH_TYPE_FT_RSN_PSK, |
| 78 | #endif |
| 79 | #ifdef FEATURE_WLAN_WAPI |
| 80 | eCSR_AUTH_TYPE_WAPI_WAI_CERTIFICATE, |
| 81 | eCSR_AUTH_TYPE_WAPI_WAI_PSK, |
| 82 | #endif /* FEATURE_WLAN_WAPI */ |
| 83 | #ifdef FEATURE_WLAN_CCX |
| 84 | eCSR_AUTH_TYPE_CCKM_WPA, |
| 85 | eCSR_AUTH_TYPE_CCKM_RSN, |
| 86 | #endif /* FEATURE_WLAN_CCX */ |
| 87 | eCSR_NUM_OF_SUPPORT_AUTH_TYPE, |
| 88 | eCSR_AUTH_TYPE_FAILED = 0xff, |
| 89 | eCSR_AUTH_TYPE_UNKNOWN = eCSR_AUTH_TYPE_FAILED, |
| 90 | |
| 91 | }eCsrAuthType; |
| 92 | |
| 93 | |
| 94 | typedef enum |
| 95 | { |
| 96 | eCSR_ENCRYPT_TYPE_NONE, |
| 97 | eCSR_ENCRYPT_TYPE_WEP40_STATICKEY, |
| 98 | eCSR_ENCRYPT_TYPE_WEP104_STATICKEY, |
| 99 | |
| 100 | eCSR_ENCRYPT_TYPE_WEP40, |
| 101 | eCSR_ENCRYPT_TYPE_WEP104, |
| 102 | eCSR_ENCRYPT_TYPE_TKIP, |
| 103 | eCSR_ENCRYPT_TYPE_AES, |
| 104 | #ifdef FEATURE_WLAN_WAPI |
| 105 | eCSR_ENCRYPT_TYPE_WPI, //WAPI |
| 106 | #endif /* FEATURE_WLAN_WAPI */ |
| 107 | #ifdef FEATURE_WLAN_CCX |
| 108 | eCSR_ENCRYPT_TYPE_KRK, |
| 109 | #endif /* FEATURE_WLAN_CCX */ |
| 110 | #ifdef WLAN_FEATURE_11W |
| 111 | //11w BIP |
| 112 | eCSR_ENCRYPT_TYPE_AES_CMAC, |
| 113 | #endif |
| 114 | eCSR_ENCRYPT_TYPE_ANY, |
| 115 | eCSR_NUM_OF_ENCRYPT_TYPE = eCSR_ENCRYPT_TYPE_ANY, |
| 116 | |
| 117 | eCSR_ENCRYPT_TYPE_FAILED = 0xff, |
| 118 | eCSR_ENCRYPT_TYPE_UNKNOWN = eCSR_ENCRYPT_TYPE_FAILED, |
| 119 | |
| 120 | }eCsrEncryptionType; |
| 121 | |
| 122 | /*--------------------------------------------------------------------------- |
| 123 | Enumeration of the various Security types |
| 124 | ---------------------------------------------------------------------------*/ |
| 125 | typedef enum |
| 126 | { |
| 127 | eCSR_SECURITY_TYPE_WPA, |
| 128 | eCSR_SECURITY_TYPE_RSN, |
| 129 | #ifdef FEATURE_WLAN_WAPI |
| 130 | eCSR_SECURITY_TYPE_WAPI, |
| 131 | #endif /* FEATURE_WLAN_WAPI */ |
| 132 | eCSR_SECURITY_TYPE_UNKNOWN, |
| 133 | |
| 134 | }eCsrSecurityType; |
| 135 | |
| 136 | typedef enum |
| 137 | { |
| 138 | eCSR_DOT11_MODE_TAURUS = 0, //This mean everything because it covers all thing we support |
| 139 | eCSR_DOT11_MODE_abg = 0x0001, //11a/b/g only, no HT, no proprietary |
| 140 | eCSR_DOT11_MODE_11a = 0x0002, |
| 141 | eCSR_DOT11_MODE_11b = 0x0004, |
| 142 | eCSR_DOT11_MODE_11g = 0x0008, |
| 143 | eCSR_DOT11_MODE_11n = 0x0010, |
| 144 | eCSR_DOT11_MODE_POLARIS = 0x0020, |
| 145 | eCSR_DOT11_MODE_TITAN = 0x0040, |
| 146 | eCSR_DOT11_MODE_11g_ONLY = 0x0080, |
| 147 | eCSR_DOT11_MODE_11n_ONLY = 0x0100, |
| 148 | eCSR_DOT11_MODE_TAURUS_ONLY = 0x0200, |
| 149 | eCSR_DOT11_MODE_11b_ONLY = 0x0400, |
| 150 | eCSR_DOT11_MODE_11a_ONLY = 0x0800, |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 151 | #ifdef WLAN_FEATURE_11AC |
| 152 | eCSR_DOT11_MODE_11ac = 0x1000, |
| 153 | eCSR_DOT11_MODE_11ac_ONLY = 0x2000, |
| 154 | #endif |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 155 | //This is for WIFI test. It is same as eWNIAPI_MAC_PROTOCOL_ALL except when it starts IBSS in 11B of 2.4GHz |
| 156 | //It is for CSR internal use |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 157 | eCSR_DOT11_MODE_AUTO = 0x4000, |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 158 | |
| 159 | eCSR_NUM_PHY_MODE = 16, //specify the number of maximum bits for phyMode |
| 160 | }eCsrPhyMode; |
| 161 | |
| 162 | |
| 163 | typedef tANI_U8 tCsrBssid[WNI_CFG_BSSID_LEN]; |
| 164 | |
| 165 | typedef enum |
| 166 | { |
| 167 | eCSR_BSS_TYPE_INFRASTRUCTURE, |
| 168 | #ifdef WLAN_SOFTAP_FEATURE |
| 169 | eCSR_BSS_TYPE_INFRA_AP, // SoftAP AP |
| 170 | #endif |
| 171 | eCSR_BSS_TYPE_IBSS, // an IBSS network we will NOT start |
| 172 | eCSR_BSS_TYPE_START_IBSS, // an IBSS network we will start if no partners detected. |
| 173 | eCSR_BSS_TYPE_WDS_AP, // BT-AMP AP |
| 174 | eCSR_BSS_TYPE_WDS_STA, // BT-AMP station |
| 175 | eCSR_BSS_TYPE_ANY, // any BSS type (IBSS or Infrastructure). |
| 176 | }eCsrRoamBssType; |
| 177 | |
| 178 | |
| 179 | |
| 180 | typedef enum { |
| 181 | eCSR_SCAN_REQUEST_11D_SCAN = 1, |
| 182 | eCSR_SCAN_REQUEST_FULL_SCAN, |
| 183 | eCSR_SCAN_IDLE_MODE_SCAN, |
| 184 | eCSR_SCAN_HO_BG_SCAN, // bg scan request in NRT & RT Handoff sub-states |
| 185 | eCSR_SCAN_HO_PROBE_SCAN, // directed probe on an entry from the candidate list |
| 186 | eCSR_SCAN_HO_NT_BG_SCAN, // bg scan request in NT sub-state |
| 187 | eCSR_SCAN_P2P_DISCOVERY, |
| 188 | |
| 189 | eCSR_SCAN_SOFTAP_CHANNEL_RANGE, |
| 190 | eCSR_SCAN_P2P_FIND_PEER, |
| 191 | }eCsrRequestType; |
| 192 | |
| 193 | typedef enum { |
| 194 | eCSR_SCAN_RESULT_GET = 0, |
| 195 | eCSR_SCAN_RESULT_FLUSH = 1, //to delete all cached scan results |
| 196 | }eCsrScanResultCmd; |
| 197 | |
| 198 | typedef enum |
| 199 | { |
| 200 | eCSR_SCAN_SUCCESS, |
| 201 | eCSR_SCAN_FAILURE, |
| 202 | eCSR_SCAN_ABORT, |
| 203 | eCSR_SCAN_FOUND_PEER, |
| 204 | }eCsrScanStatus; |
| 205 | |
| 206 | #define CSR_SCAN_TIME_DEFAULT 0 |
| 207 | #define CSR_VALUE_IGNORED 0xFFFFFFFF |
| 208 | #define CSR_RSN_PMKID_SIZE 16 |
| 209 | #define CSR_MAX_PMKID_ALLOWED 16 |
| 210 | #define CSR_WEP40_KEY_LEN 5 |
| 211 | #define CSR_WEP104_KEY_LEN 13 |
| 212 | #define CSR_TKIP_KEY_LEN 32 |
| 213 | #define CSR_AES_KEY_LEN 16 |
| 214 | #define CSR_MAX_TX_POWER ( WNI_CFG_CURRENT_TX_POWER_LEVEL_STAMAX ) |
| 215 | #define CSR_MAX_RSC_LEN 16 |
| 216 | #ifdef FEATURE_WLAN_WAPI |
| 217 | #define CSR_WAPI_BKID_SIZE 16 |
| 218 | #define CSR_MAX_BKID_ALLOWED 16 |
| 219 | #define CSR_WAPI_KEY_LEN 32 |
| 220 | #define CSR_MAX_KEY_LEN ( CSR_WAPI_KEY_LEN ) //longest one is for WAPI |
| 221 | #else |
| 222 | #define CSR_MAX_KEY_LEN ( CSR_TKIP_KEY_LEN ) //longest one is for TKIP |
| 223 | #endif /* FEATURE_WLAN_WAPI */ |
| 224 | #ifdef FEATURE_WLAN_CCX |
| 225 | #define CSR_KRK_KEY_LEN 16 |
| 226 | #endif |
| 227 | |
| 228 | |
| 229 | |
| 230 | typedef struct tagCsrChannelInfo |
| 231 | { |
| 232 | tANI_U8 numOfChannels; |
| 233 | tANI_U8 *ChannelList; //it will be an array of channels |
Madan Mohan Koyyalamudi | dd3c966 | 2012-11-09 17:39:30 -0800 | [diff] [blame] | 234 | }tCsrChannelInfo, *tpCsrChannelInfo; |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 235 | |
| 236 | typedef struct tagCsrSSIDInfo |
| 237 | { |
| 238 | tSirMacSSid SSID; |
| 239 | tANI_BOOLEAN handoffPermitted; |
| 240 | tANI_BOOLEAN ssidHidden; |
| 241 | }tCsrSSIDInfo; |
| 242 | |
| 243 | typedef struct tagCsrSSIDs |
| 244 | { |
| 245 | tANI_U32 numOfSSIDs; |
| 246 | tCsrSSIDInfo *SSIDList; //To be allocated for array of SSIDs |
| 247 | }tCsrSSIDs; |
| 248 | |
| 249 | typedef struct tagCsrBSSIDs |
| 250 | { |
| 251 | tANI_U32 numOfBSSIDs; |
| 252 | tCsrBssid *bssid; |
| 253 | }tCsrBSSIDs; |
| 254 | |
| 255 | |
| 256 | typedef struct tagCsrScanRequest |
| 257 | { |
| 258 | tSirScanType scanType; |
| 259 | tCsrBssid bssid; |
| 260 | eCsrRoamBssType BSSType; |
| 261 | tCsrSSIDs SSIDs; |
| 262 | tCsrChannelInfo ChannelInfo; |
| 263 | tANI_U32 minChnTime; //in units of milliseconds |
| 264 | tANI_U32 maxChnTime; //in units of milliseconds |
| 265 | tANI_U32 restTime; //in units of milliseconds //ignored when not connected |
| 266 | tANI_U32 uIEFieldLen; |
| 267 | tANI_U8 *pIEField; |
| 268 | eCsrRequestType requestType; //11d scan or full scan |
| 269 | #ifdef WLAN_FEATURE_P2P |
| 270 | tANI_BOOLEAN p2pSearch; |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 271 | tANI_BOOLEAN skipDfsChnlInP2pSearch; |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 272 | #endif |
| 273 | }tCsrScanRequest; |
| 274 | |
| 275 | typedef struct tagCsrBGScanRequest |
| 276 | { |
| 277 | tSirScanType scanType; |
| 278 | tSirMacSSid SSID; |
| 279 | tCsrChannelInfo ChannelInfo; |
| 280 | tANI_U32 scanInterval; //in units of milliseconds |
| 281 | tANI_U32 minChnTime; //in units of milliseconds |
| 282 | tANI_U32 maxChnTime; //in units of milliseconds |
| 283 | tANI_U32 restTime; //in units of milliseconds //ignored when not connected |
| 284 | tANI_U32 throughputImpact; //specify whether BG scan cares about impacting throughput //ignored when not connected |
| 285 | tCsrBssid bssid; //how to use it?? Apple |
| 286 | }tCsrBGScanRequest; |
| 287 | |
| 288 | |
| 289 | typedef struct tagCsrScanResultInfo |
| 290 | { |
| 291 | //Carry the IEs for the current BSSDescription. A pointer to tDot11fBeaconIEs. Maybe NULL for start BSS. |
| 292 | void *pvIes; |
| 293 | tAniSSID ssId; |
| 294 | v_TIME_t timer; // timer is variable which is used for hidden SSID's timer value |
| 295 | //This member must be the last in the structure because the end of tSirBssDescription is an |
| 296 | // array with nonknown size at this time |
| 297 | tSirBssDescription BssDescriptor; |
| 298 | }tCsrScanResultInfo; |
| 299 | |
| 300 | typedef struct tagCsrEncryptionList |
| 301 | { |
| 302 | |
| 303 | tANI_U32 numEntries; |
| 304 | eCsrEncryptionType encryptionType[eCSR_NUM_OF_ENCRYPT_TYPE]; |
| 305 | |
| 306 | }tCsrEncryptionList, *tpCsrEncryptionList; |
| 307 | |
| 308 | typedef struct tagCsrAuthList |
| 309 | { |
| 310 | tANI_U32 numEntries; |
| 311 | eCsrAuthType authType[eCSR_NUM_OF_SUPPORT_AUTH_TYPE]; |
| 312 | }tCsrAuthList, *tpCsrAuthList; |
| 313 | |
| 314 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 315 | typedef struct tagCsrMobilityDomainInfo |
| 316 | { |
| 317 | tANI_U8 mdiePresent; |
| 318 | tANI_U16 mobilityDomain; |
| 319 | } tCsrMobilityDomainInfo; |
| 320 | #endif |
| 321 | |
| 322 | #ifdef FEATURE_WLAN_CCX |
| 323 | typedef struct tagCsrCcxCckmInfo |
| 324 | { |
| 325 | tANI_U32 reassoc_req_num; |
| 326 | tANI_BOOLEAN krk_plumbed; |
| 327 | tANI_U8 krk[CSR_KRK_KEY_LEN]; |
| 328 | } tCsrCcxCckmInfo; |
| 329 | #endif |
| 330 | |
| 331 | |
| 332 | typedef struct tagCsrScanResultFilter |
| 333 | { |
| 334 | tCsrBSSIDs BSSIDs; //each bssid has a length of WNI_CFG_BSSID_LEN (6) |
| 335 | tCsrSSIDs SSIDs; |
| 336 | tCsrChannelInfo ChannelInfo; |
| 337 | tCsrAuthList authType; |
| 338 | tCsrEncryptionList EncryptionType; |
| 339 | //eCSR_ENCRYPT_TYPE_ANY cannot be set in multicast encryption type. If caller doesn't case, |
| 340 | //put all supported encryption types in here |
| 341 | tCsrEncryptionList mcEncryptionType; |
| 342 | eCsrRoamBssType BSSType; |
| 343 | //this is a bit mask of all the needed phy mode defined in eCsrPhyMode |
| 344 | tANI_U32 phyMode; |
| 345 | //If countryCode[0] is not 0, countryCode is checked independent of fCheckUnknownCountryCode |
| 346 | tANI_U8 countryCode[WNI_CFG_COUNTRY_CODE_LEN]; |
| 347 | tANI_U8 uapsd_mask; |
| 348 | /*For WPS filtering if true => auth and ecryption should be ignored*/ |
| 349 | tANI_BOOLEAN bWPSAssociation; |
| 350 | #if defined WLAN_FEATURE_VOWIFI |
| 351 | /*For measurement reports --> if set, only SSID, BSSID and channel is considered for filtering.*/ |
| 352 | tANI_BOOLEAN fMeasurement; |
| 353 | #endif |
| 354 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 355 | tCsrMobilityDomainInfo MDID; |
| 356 | #endif |
| 357 | tANI_BOOLEAN p2pResult; |
| 358 | }tCsrScanResultFilter; |
| 359 | |
| 360 | |
| 361 | typedef struct sCsrChnPower_ |
| 362 | { |
| 363 | tANI_U8 firstChannel; |
| 364 | tANI_U8 numChannels; |
| 365 | tANI_U8 maxtxPower; |
| 366 | }sCsrChnPower; |
| 367 | |
| 368 | |
| 369 | typedef struct sCsrChannel_ |
| 370 | { |
| 371 | tANI_U8 numChannels; |
| 372 | tANI_U8 channelList[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 373 | }sCsrChannel; |
| 374 | |
| 375 | |
| 376 | typedef struct tagCsr11dinfo |
| 377 | { |
| 378 | sCsrChannel Channels; |
| 379 | tANI_U8 countryCode[WNI_CFG_COUNTRY_CODE_LEN+1]; |
| 380 | //max power channel list |
| 381 | sCsrChnPower ChnPower[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 382 | }tCsr11dinfo; |
| 383 | |
| 384 | |
| 385 | typedef enum |
| 386 | { |
| 387 | eCSR_ROAM_CANCELLED = 1, |
| 388 | //this mean error happens before association_start or roaming_start is called. |
| 389 | eCSR_ROAM_FAILED, |
| 390 | //a CSR trigger roaming operation starts, callback may get a pointer to tCsrConnectedProfile |
| 391 | eCSR_ROAM_ROAMING_START, |
| 392 | //a CSR trigger roaming operation is completed |
| 393 | eCSR_ROAM_ROAMING_COMPLETION, |
| 394 | //Connection completed status. |
| 395 | eCSR_ROAM_CONNECT_COMPLETION, |
| 396 | //an association or start_IBSS operation starts, |
| 397 | //callback may get a pointer to tCsrRoamProfile and a pointer to tSirBssDescription |
| 398 | eCSR_ROAM_ASSOCIATION_START, |
| 399 | //a roaming operation is finish, see eCsrRoamResult for |
| 400 | //possible data passed back |
| 401 | eCSR_ROAM_ASSOCIATION_COMPLETION, |
| 402 | eCSR_ROAM_DISASSOCIATED, |
| 403 | eCSR_ROAM_ASSOCIATION_FAILURE, |
| 404 | //when callback with this flag. callback gets a pointer to the BSS desc. |
| 405 | eCSR_ROAM_SHOULD_ROAM, |
| 406 | //A new candidate for PMKID is found |
| 407 | eCSR_ROAM_SCAN_FOUND_NEW_BSS, |
| 408 | //CSR is done lostlink roaming and still cannot reconnect |
| 409 | eCSR_ROAM_LOSTLINK, |
| 410 | //a link lost is detected. CSR starts roaming. |
| 411 | eCSR_ROAM_LOSTLINK_DETECTED, |
| 412 | //TKIP MIC error detected, callback gets a pointer to tpSirSmeMicFailureInd |
| 413 | eCSR_ROAM_MIC_ERROR_IND, |
| 414 | eCSR_ROAM_IBSS_IND, //IBSS indications. |
| 415 | //Update the connection status, useful for IBSS: new peer added, network is active etc. |
| 416 | eCSR_ROAM_CONNECT_STATUS_UPDATE, |
| 417 | eCSR_ROAM_GEN_INFO, |
| 418 | eCSR_ROAM_SET_KEY_COMPLETE, |
| 419 | eCSR_ROAM_REMOVE_KEY_COMPLETE, |
| 420 | eCSR_ROAM_IBSS_LEAVE, //IBSS indications. |
| 421 | //BSS in WDS mode status indication |
| 422 | eCSR_ROAM_WDS_IND, |
| 423 | #ifdef WLAN_SOFTAP_FEATURE |
| 424 | //BSS in SoftAP mode status indication |
| 425 | eCSR_ROAM_INFRA_IND, |
| 426 | eCSR_ROAM_WPS_PBC_PROBE_REQ_IND, |
| 427 | #endif |
| 428 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 429 | eCSR_ROAM_FT_RESPONSE, |
| 430 | #endif |
| 431 | eCSR_ROAM_FT_START, |
| 432 | eCSR_ROAM_INDICATE_MGMT_FRAME, |
| 433 | eCSR_ROAM_REMAIN_CHAN_READY, |
| 434 | eCSR_ROAM_SEND_ACTION_CNF, |
| 435 | //this mean error happens before association_start or roaming_start is called. |
| 436 | eCSR_ROAM_SESSION_OPENED, |
| 437 | eCSR_ROAM_FT_REASSOC_FAILED, |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 438 | #ifdef FEATURE_WLAN_LFR |
| 439 | eCSR_ROAM_PMK_NOTIFY, |
| 440 | #endif |
Mohit Khanna | 698ba2a | 2012-12-04 15:08:18 -0800 | [diff] [blame] | 441 | #ifdef FEATURE_WLAN_TDLS |
| 442 | eCSR_ROAM_TDLS_STATUS_UPDATE, |
| 443 | #endif |
Madan Mohan Koyyalamudi | 167b95e | 2012-11-27 15:53:38 -0800 | [diff] [blame] | 444 | eCSR_ROAM_DISCONNECT_ALL_P2P_CLIENTS, //Disaconnect all the clients |
| 445 | eCSR_ROAM_SEND_P2P_STOP_BSS, //Stopbss triggered from SME due to different |
| 446 | // beacon interval |
| 447 | |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 448 | }eRoamCmdStatus; |
| 449 | |
| 450 | |
| 451 | //comment inside indicates what roaming callback gets |
| 452 | typedef enum |
| 453 | { |
| 454 | eCSR_ROAM_RESULT_NONE, |
| 455 | //this means no more action in CSR |
| 456 | //If roamStatus is eCSR_ROAM_ASSOCIATION_COMPLETION, tCsrRoamInfo's pBssDesc may pass back |
| 457 | eCSR_ROAM_RESULT_FAILURE, |
| 458 | //Pass back pointer to tCsrRoamInfo |
| 459 | eCSR_ROAM_RESULT_ASSOCIATED, |
| 460 | eCSR_ROAM_RESULT_NOT_ASSOCIATED, |
| 461 | eCSR_ROAM_RESULT_MIC_FAILURE, |
| 462 | eCSR_ROAM_RESULT_FORCED, |
| 463 | eCSR_ROAM_RESULT_DISASSOC_IND, |
| 464 | eCSR_ROAM_RESULT_DEAUTH_IND, |
| 465 | eCSR_ROAM_RESULT_CAP_CHANGED, |
| 466 | //This means we starts an IBSS |
| 467 | //tCsrRoamInfo's pBssDesc may pass back |
| 468 | eCSR_ROAM_RESULT_IBSS_STARTED, |
| 469 | //START_BSS failed |
| 470 | //tCsrRoamInfo's pBssDesc may pass back |
| 471 | eCSR_ROAM_RESULT_IBSS_START_FAILED, |
| 472 | eCSR_ROAM_RESULT_IBSS_JOIN_SUCCESS, |
| 473 | eCSR_ROAM_RESULT_IBSS_JOIN_FAILED, |
| 474 | eCSR_ROAM_RESULT_IBSS_CONNECT, |
| 475 | eCSR_ROAM_RESULT_IBSS_INACTIVE, |
| 476 | //If roamStatus is eCSR_ROAM_ASSOCIATION_COMPLETION |
| 477 | //tCsrRoamInfo's pBssDesc may pass back. and the peer's MAC address in peerMacOrBssid |
| 478 | //If roamStatus is eCSR_ROAM_IBSS_IND, |
| 479 | //the peer's MAC address in peerMacOrBssid and a beacon frame of the IBSS in pbFrames |
| 480 | eCSR_ROAM_RESULT_IBSS_NEW_PEER, |
| 481 | //Peer departed from IBSS, Callback may get a pointer tSmeIbssPeerInd in pIbssPeerInd |
| 482 | eCSR_ROAM_RESULT_IBSS_PEER_DEPARTED, |
| 483 | //Coalescing in the IBSS network (joined an IBSS network) |
| 484 | //Callback pass a BSSID in peerMacOrBssid |
| 485 | eCSR_ROAM_RESULT_IBSS_COALESCED, |
| 486 | //If roamStatus is eCSR_ROAM_ROAMING_START, callback may get a pointer to tCsrConnectedProfile used to connect. |
| 487 | eCSR_ROAM_RESULT_IBSS_STOP, |
| 488 | eCSR_ROAM_RESULT_LOSTLINK, |
| 489 | eCSR_ROAM_RESULT_MIC_ERROR_UNICAST, |
| 490 | eCSR_ROAM_RESULT_MIC_ERROR_GROUP, |
| 491 | eCSR_ROAM_RESULT_AUTHENTICATED, |
| 492 | eCSR_ROAM_RESULT_NEW_RSN_BSS, |
| 493 | #ifdef FEATURE_WLAN_WAPI |
| 494 | eCSR_ROAM_RESULT_NEW_WAPI_BSS, |
| 495 | #endif /* FEATURE_WLAN_WAPI */ |
| 496 | // WDS started successfully |
| 497 | eCSR_ROAM_RESULT_WDS_STARTED, |
| 498 | // WDS start failed |
| 499 | eCSR_ROAM_RESULT_WDS_START_FAILED, |
| 500 | // WDS stopped |
| 501 | eCSR_ROAM_RESULT_WDS_STOPPED, |
| 502 | // WDS joined successfully in STA mode |
| 503 | eCSR_ROAM_RESULT_WDS_ASSOCIATED, |
| 504 | // A station joined WDS AP |
| 505 | eCSR_ROAM_RESULT_WDS_ASSOCIATION_IND, |
| 506 | // WDS join failed in STA mode |
| 507 | eCSR_ROAM_RESULT_WDS_NOT_ASSOCIATED, |
| 508 | // WDS disassociated |
| 509 | eCSR_ROAM_RESULT_WDS_DISASSOCIATED, |
| 510 | #ifdef WLAN_SOFTAP_FEATURE |
| 511 | // INFRA started successfully |
| 512 | eCSR_ROAM_RESULT_INFRA_STARTED, |
| 513 | // INFRA start failed |
| 514 | eCSR_ROAM_RESULT_INFRA_START_FAILED, |
| 515 | // INFRA stopped |
| 516 | eCSR_ROAM_RESULT_INFRA_STOPPED, |
| 517 | // A station joining INFRA AP |
| 518 | eCSR_ROAM_RESULT_INFRA_ASSOCIATION_IND, |
| 519 | // A station joined INFRA AP |
| 520 | eCSR_ROAM_RESULT_INFRA_ASSOCIATION_CNF, |
| 521 | // INFRA disassociated |
| 522 | eCSR_ROAM_RESULT_INFRA_DISASSOCIATED, |
| 523 | eCSR_ROAM_RESULT_WPS_PBC_PROBE_REQ_IND, |
| 524 | #endif |
| 525 | #ifdef WLAN_FEATURE_P2P |
| 526 | eCSR_ROAM_RESULT_SEND_ACTION_FAIL, |
| 527 | #endif |
| 528 | // peer rejected assoc because max assoc limit reached. callback gets pointer to peer |
| 529 | eCSR_ROAM_RESULT_MAX_ASSOC_EXCEEDED, |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 530 | //Assoc rejected due to concurrent session running on a different channel |
| 531 | eCSR_ROAM_RESULT_ASSOC_FAIL_CON_CHANNEL, |
Mohit Khanna | 698ba2a | 2012-12-04 15:08:18 -0800 | [diff] [blame] | 532 | #ifdef FEATURE_WLAN_TDLS |
| 533 | eCSR_ROAM_RESULT_ADD_TDLS_PEER, |
| 534 | eCSR_ROAM_RESULT_DELETE_TDLS_PEER, |
| 535 | #endif |
| 536 | |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 537 | }eCsrRoamResult; |
| 538 | |
| 539 | |
| 540 | |
| 541 | /*---------------------------------------------------------------------------- |
| 542 | List of link quality indications HDD can receive from SME |
| 543 | -----------------------------------------------------------------------------*/ |
| 544 | typedef enum |
| 545 | { |
| 546 | eCSR_ROAM_LINK_QUAL_MIN_IND = -1, |
| 547 | |
| 548 | eCSR_ROAM_LINK_QUAL_POOR_IND = 0, /* bad link */ |
| 549 | eCSR_ROAM_LINK_QUAL_GOOD_IND = 1, /* acceptable for voice */ |
| 550 | eCSR_ROAM_LINK_QUAL_VERY_GOOD_IND = 2, /* suitable for voice */ |
| 551 | eCSR_ROAM_LINK_QUAL_EXCELLENT_IND = 3, /* suitable for voice */ |
| 552 | |
| 553 | eCSR_ROAM_LINK_QUAL_MAX_IND /* invalid value */ |
| 554 | |
| 555 | } eCsrRoamLinkQualityInd; |
| 556 | |
| 557 | typedef enum |
| 558 | { |
| 559 | eCSR_DISCONNECT_REASON_UNSPECIFIED = 0, |
| 560 | eCSR_DISCONNECT_REASON_MIC_ERROR, |
| 561 | eCSR_DISCONNECT_REASON_DISASSOC, |
| 562 | eCSR_DISCONNECT_REASON_DEAUTH, |
| 563 | eCSR_DISCONNECT_REASON_HANDOFF, |
| 564 | eCSR_DISCONNECT_REASON_IBSS_JOIN_FAILURE, |
| 565 | eCSR_DISCONNECT_REASON_IBSS_LEAVE, |
| 566 | }eCsrRoamDisconnectReason; |
| 567 | |
| 568 | typedef enum |
| 569 | { |
| 570 | // Not associated in Infra or participating in an IBSS / Ad-hoc network. |
| 571 | eCSR_ASSOC_STATE_TYPE_NOT_CONNECTED, |
| 572 | // Associated in an Infrastructure network. |
| 573 | eCSR_ASSOC_STATE_TYPE_INFRA_ASSOCIATED, |
| 574 | // Participating in an IBSS network though disconnected (no partner stations |
| 575 | // in the IBSS). |
| 576 | eCSR_ASSOC_STATE_TYPE_IBSS_DISCONNECTED, |
| 577 | // Participating in an IBSS network with partner stations also present |
| 578 | eCSR_ASSOC_STATE_TYPE_IBSS_CONNECTED, |
| 579 | // Participating in a WDS network in AP or STA mode but not connected yet |
| 580 | eCSR_ASSOC_STATE_TYPE_WDS_DISCONNECTED, |
| 581 | // Participating in a WDS network and connected peer to peer |
| 582 | eCSR_ASSOC_STATE_TYPE_WDS_CONNECTED, |
| 583 | #ifdef WLAN_SOFTAP_FEATURE |
| 584 | // Participating in a Infra network in AP not yet in connected state |
| 585 | eCSR_ASSOC_STATE_TYPE_INFRA_DISCONNECTED, |
| 586 | // Participating in a Infra network and connected to a peer |
| 587 | eCSR_ASSOC_STATE_TYPE_INFRA_CONNECTED, |
| 588 | #endif |
| 589 | |
| 590 | }eCsrConnectState; |
| 591 | |
| 592 | |
| 593 | // This parameter is no longer supported in the Profile. Need to set this in the global properties |
| 594 | // for the adapter. |
| 595 | typedef enum eCSR_MEDIUM_ACCESS |
| 596 | { |
| 597 | eCSR_MEDIUM_ACCESS_AUTO = 0, |
| 598 | eCSR_MEDIUM_ACCESS_DCF, |
| 599 | eCSR_MEDIUM_ACCESS_eDCF, |
| 600 | eCSR_MEDIUM_ACCESS_HCF, |
| 601 | |
| 602 | eCSR_MEDIUM_ACCESS_WMM_eDCF_802dot1p, |
| 603 | eCSR_MEDIUM_ACCESS_WMM_eDCF_DSCP, |
| 604 | eCSR_MEDIUM_ACCESS_WMM_eDCF_NoClassify, |
| 605 | eCSR_MEDIUM_ACCESS_11e_eDCF = eCSR_MEDIUM_ACCESS_eDCF, |
| 606 | eCSR_MEDIUM_ACCESS_11e_HCF = eCSR_MEDIUM_ACCESS_HCF, |
| 607 | }eCsrMediaAccessType; |
| 608 | |
| 609 | typedef enum |
| 610 | { |
| 611 | eCSR_TX_RATE_AUTO = 0, // use rate adaption to determine Tx rate. |
| 612 | |
| 613 | eCSR_TX_RATE_1Mbps = 0x00000001, |
| 614 | eCSR_TX_RATE_2Mbps = 0x00000002, |
| 615 | eCSR_TX_RATE_5_5Mbps = 0x00000004, |
| 616 | eCSR_TX_RATE_6Mbps = 0x00000008, |
| 617 | eCSR_TX_RATE_9Mbps = 0x00000010, |
| 618 | eCSR_TX_RATE_11Mbps = 0x00000020, |
| 619 | eCSR_TX_RATE_12Mbps = 0x00000040, |
| 620 | eCSR_TX_RATE_18Mbps = 0x00000080, |
| 621 | eCSR_TX_RATE_24Mbps = 0x00000100, |
| 622 | eCSR_TX_RATE_36Mbps = 0x00000200, |
| 623 | eCSR_TX_RATE_42Mbps = 0x00000400, |
| 624 | eCSR_TX_RATE_48Mbps = 0x00000800, |
| 625 | eCSR_TX_RATE_54Mbps = 0x00001000, |
| 626 | eCSR_TX_RATE_72Mbps = 0x00002000, |
| 627 | eCSR_TX_RATE_84Mbps = 0x00004000, |
| 628 | eCSR_TX_RATE_96Mbps = 0x00008000, |
| 629 | eCSR_TX_RATE_108Mbps = 0x00010000, |
| 630 | eCSR_TX_RATE_126Mbps = 0x00020000, |
| 631 | eCSR_TX_RATE_144Mbps = 0x00040000, |
| 632 | eCSR_TX_RATE_168Mbps = 0x00080000, |
| 633 | eCSR_TX_RATE_192Mbps = 0x00100000, |
| 634 | eCSR_TX_RATE_216Mbps = 0x00200000, |
| 635 | eCSR_TX_RATE_240Mbps = 0x00400000, |
| 636 | |
| 637 | }eCsrExposedTxRate; |
| 638 | |
| 639 | typedef enum |
| 640 | { |
| 641 | eCSR_OPERATING_CHANNEL_ALL = 0, |
| 642 | eCSR_OPERATING_CHANNEL_AUTO = eCSR_OPERATING_CHANNEL_ALL, |
| 643 | eCSR_OPERATING_CHANNEL_ANY = eCSR_OPERATING_CHANNEL_ALL, |
| 644 | }eOperationChannel; |
| 645 | |
| 646 | typedef enum |
| 647 | { |
| 648 | eCSR_DOT11_FRAG_THRESH_AUTO = -1, |
| 649 | eCSR_DOT11_FRAG_THRESH_MIN = 256, |
| 650 | eCSR_DOT11_FRAG_THRESH_MAX = 2346, |
| 651 | eCSR_DOT11_FRAG_THRESH_DEFAULT = 2000 |
| 652 | }eCsrDot11FragThresh; |
| 653 | |
| 654 | |
| 655 | //for channel bonding for ibss |
| 656 | typedef enum |
| 657 | { |
| 658 | eCSR_CB_OFF = 0, |
| 659 | eCSR_CB_AUTO = 1, |
| 660 | eCSR_CB_DOWN = 2, |
| 661 | eCSR_CB_UP = 3, |
| 662 | }eCsrCBChoice; |
| 663 | |
| 664 | //For channel bonding, the channel number gap is 4, either up or down. For both 11a and 11g mode. |
| 665 | #define CSR_CB_CHANNEL_GAP 4 |
| 666 | #define CSR_CB_CENTER_CHANNEL_OFFSET 2 |
| 667 | #define CSR_MAX_24GHz_CHANNEL_NUMBER ( SIR_11B_CHANNEL_END ) |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 668 | #define CSR_MIN_5GHz_CHANNEL_NUMBER ( SIR_11A_CHANNEL_BEGIN ) |
| 669 | #define CSR_MAX_5GHz_CHANNEL_NUMBER ( SIR_11A_CHANNEL_END ) |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 670 | |
| 671 | // WEP keysize (in bits)... |
| 672 | typedef enum |
| 673 | { |
| 674 | eCSR_SECURITY_WEP_KEYSIZE_40 = 40, // 40 bit key + 24bit IV = 64bit WEP |
| 675 | eCSR_SECURITY_WEP_KEYSIZE_104 = 104, // 104bit key + 24bit IV = 128bit WEP |
| 676 | |
| 677 | eCSR_SECURITY_WEP_KEYSIZE_MIN = eCSR_SECURITY_WEP_KEYSIZE_40, |
| 678 | eCSR_SECURITY_WEP_KEYSIZE_MAX = eCSR_SECURITY_WEP_KEYSIZE_104, |
| 679 | eCSR_SECURITY_WEP_KEYSIZE_MAX_BYTES = ( eCSR_SECURITY_WEP_KEYSIZE_MAX / 8 ), |
| 680 | }eCsrWEPKeySize; |
| 681 | |
| 682 | |
| 683 | // Possible values for the WEP static key ID... |
| 684 | typedef enum |
| 685 | { |
| 686 | |
| 687 | eCSR_SECURITY_WEP_STATIC_KEY_ID_MIN = 0, |
| 688 | eCSR_SECURITY_WEP_STATIC_KEY_ID_MAX = 3, |
| 689 | eCSR_SECURITY_WEP_STATIC_KEY_ID_DEFAULT = 0, |
| 690 | |
| 691 | eCSR_SECURITY_WEP_STATIC_KEY_ID_INVALID = -1, |
| 692 | |
| 693 | }eCsrWEPStaticKeyID; |
| 694 | |
| 695 | #define CSR_MAX_NUM_KEY (eCSR_SECURITY_WEP_STATIC_KEY_ID_MAX + 1) |
| 696 | |
| 697 | typedef enum |
| 698 | { |
| 699 | eCSR_SECURITY_SET_KEY_ACTION_NO_CHANGE, |
| 700 | eCSR_SECURITY_SET_KEY_ACTION_SET_KEY, |
| 701 | eCSR_SECURITY_SET_KEY_ACTION_DELETE_KEY, |
| 702 | }eCsrSetKeyAction; |
| 703 | |
| 704 | typedef enum |
| 705 | { |
| 706 | eCSR_BAND_ALL, |
| 707 | eCSR_BAND_24, |
| 708 | eCSR_BAND_5G, |
| 709 | eCSR_BAND_MAX, |
| 710 | }eCsrBand; |
| 711 | |
| 712 | |
| 713 | typedef enum |
| 714 | { |
| 715 | // Roaming because HDD requested for reassoc by changing one of the fields in |
| 716 | // tCsrRoamModifyProfileFields. OR |
| 717 | // Roaming because SME requested for reassoc by changing one of the fields in |
| 718 | // tCsrRoamModifyProfileFields. |
| 719 | eCsrRoamReasonStaCapabilityChanged, |
| 720 | // Roaming because SME requested for reassoc to a different AP, as part of |
| 721 | // inter AP handoff. |
| 722 | eCsrRoamReasonBetterAP, |
| 723 | // Roaming because SME requested it as the link is lost - placeholder, will |
| 724 | // clean it up once handoff code gets in |
| 725 | eCsrRoamReasonSmeIssuedForLostLink, |
| 726 | |
| 727 | }eCsrRoamReasonCodes; |
| 728 | |
| 729 | typedef enum |
| 730 | { |
| 731 | eCsrRoamWmmAuto = 0, |
| 732 | eCsrRoamWmmQbssOnly = 1, |
| 733 | eCsrRoamWmmNoQos = 2, |
| 734 | |
| 735 | } eCsrRoamWmmUserModeType; |
| 736 | |
| 737 | typedef enum |
| 738 | { |
| 739 | eCSR_REQUESTER_MIN = 0, |
| 740 | eCSR_DIAG, |
| 741 | eCSR_UMA_GAN, |
| 742 | eCSR_HDD |
| 743 | } eCsrStatsRequesterType; |
| 744 | |
| 745 | typedef struct tagPmkidCandidateInfo |
| 746 | { |
| 747 | tCsrBssid BSSID; |
| 748 | tANI_BOOLEAN preAuthSupported; |
| 749 | }tPmkidCandidateInfo; |
| 750 | |
| 751 | typedef struct tagPmkidCacheInfo |
| 752 | { |
| 753 | tCsrBssid BSSID; |
| 754 | tANI_U8 PMKID[CSR_RSN_PMKID_SIZE]; |
| 755 | }tPmkidCacheInfo; |
| 756 | |
| 757 | #ifdef FEATURE_WLAN_WAPI |
| 758 | typedef struct tagBkidCandidateInfo |
| 759 | { |
| 760 | tCsrBssid BSSID; |
| 761 | tANI_BOOLEAN preAuthSupported; |
| 762 | }tBkidCandidateInfo; |
| 763 | |
| 764 | typedef struct tagBkidCacheInfo |
| 765 | { |
| 766 | tCsrBssid BSSID; |
| 767 | tANI_U8 BKID[CSR_WAPI_BKID_SIZE]; |
| 768 | }tBkidCacheInfo; |
| 769 | #endif /* FEATURE_WLAN_WAPI */ |
| 770 | |
| 771 | typedef struct tagCsrKeys |
| 772 | { |
| 773 | tANI_U8 KeyLength[ CSR_MAX_NUM_KEY ]; //Also use to indicate whether the key index is set |
| 774 | tANI_U8 KeyMaterial[ CSR_MAX_NUM_KEY ][ CSR_MAX_KEY_LEN ]; |
| 775 | tANI_U8 defaultIndex; |
| 776 | }tCsrKeys; |
| 777 | |
| 778 | /* Following are fields which are part of tCsrRoamConnectedProfile might need |
| 779 | modification dynamically once STA is up & running and this could trigger |
| 780 | reassoc */ |
| 781 | typedef struct tagCsrRoamModifyProfileFields |
| 782 | { |
| 783 | // during connect this specifies ACs U-APSD is to be setup |
| 784 | // for (Bit0:VO; Bit1:VI; Bit2:BK; Bit3:BE all other bits are ignored). |
| 785 | // During assoc response this COULD carry confirmation of what ACs U-APSD |
| 786 | // got setup for. Later if an APP looking for APSD, SME-QoS might need to |
| 787 | // modify this field |
| 788 | tANI_U8 uapsd_mask; |
| 789 | // HDD might ask to modify this field |
| 790 | tANI_U16 listen_interval; |
| 791 | }tCsrRoamModifyProfileFields; |
| 792 | |
| 793 | typedef struct tagCsrRoamProfile |
| 794 | { |
| 795 | //For eCSR_BSS_TYPE_WDS_AP. There must be one SSID in SSIDs. |
| 796 | //For eCSR_BSS_TYPE_WDS_STA. There must be two SSIDs. Index 0 is the SSID of the WDS-AP |
| 797 | //that we need to join. Index 1 is the SSID for self BSS. |
| 798 | tCsrSSIDs SSIDs; |
| 799 | tCsrBSSIDs BSSIDs; |
| 800 | tANI_U32 phyMode; //this is a bit mask of all the needed phy mode defined in eCsrPhyMode |
| 801 | eCsrRoamBssType BSSType; |
| 802 | |
| 803 | tCsrAuthList AuthType; |
| 804 | eCsrAuthType negotiatedAuthType; |
| 805 | |
| 806 | tCsrEncryptionList EncryptionType; |
| 807 | //This field is for output only, not for input |
| 808 | eCsrEncryptionType negotiatedUCEncryptionType; |
| 809 | |
| 810 | //eCSR_ENCRYPT_TYPE_ANY cannot be set in multicast encryption type. If caller doesn't case, |
| 811 | //put all supported encryption types in here |
| 812 | tCsrEncryptionList mcEncryptionType; |
| 813 | //This field is for output only, not for input |
| 814 | eCsrEncryptionType negotiatedMCEncryptionType; |
| 815 | |
| 816 | tCsrKeys Keys; |
| 817 | eCsrCBChoice CBMode; //up, down or auto |
| 818 | tCsrChannelInfo ChannelInfo; |
| 819 | tANI_U8 operationChannel; |
| 820 | tANI_U16 beaconInterval; //If this is 0, SME will fill in for caller. |
| 821 | // during connect this specifies ACs U-APSD is to be setup |
| 822 | // for (Bit0:VO; Bit1:VI; Bit2:BK; Bit3:BE all other bits are ignored). |
| 823 | // During assoc response this COULD carry confirmation of what ACs U-APSD got setup for |
| 824 | tANI_U8 uapsd_mask; |
| 825 | tANI_U32 nWPAReqIELength; //The byte count in the pWPAReqIE |
| 826 | tANI_U8 *pWPAReqIE; //If not null, it has the IE byte stream for WPA |
| 827 | tANI_U32 nRSNReqIELength; //The byte count in the pRSNReqIE |
| 828 | tANI_U8 *pRSNReqIE; //If not null, it has the IE byte stream for RSN |
| 829 | #ifdef FEATURE_WLAN_WAPI |
| 830 | tANI_U32 nWAPIReqIELength; //The byte count in the pWAPIReqIE |
| 831 | tANI_U8 *pWAPIReqIE; //If not null, it has the IE byte stream for WAPI |
| 832 | #endif /* FEATURE_WLAN_WAPI */ |
| 833 | |
| 834 | tANI_U32 nAddIEScanLength; //The byte count in the pAddIE for scan (at the time of join) |
| 835 | tANI_U8 *pAddIEScan; //If not null, it has the IE byte stream for additional IE, which can be WSC IE and/or P2P IE |
| 836 | tANI_U32 nAddIEAssocLength; //The byte count in the pAddIE for assoc |
| 837 | tANI_U8 *pAddIEAssoc; //If not null, it has the IE byte stream for additional IE, which can be WSC IE and/or P2P IE |
| 838 | |
| 839 | tANI_U8 countryCode[WNI_CFG_COUNTRY_CODE_LEN]; //it is ignored if [0] is 0. |
| 840 | /*WPS Association if true => auth and ecryption should be ignored*/ |
| 841 | tANI_BOOLEAN bWPSAssociation; |
| 842 | tANI_U32 nWSCReqIELength; //The byte count in the pWSCReqIE |
| 843 | tANI_U8 *pWSCReqIE; //If not null, it has the IE byte stream for WSC |
| 844 | |
| 845 | #ifdef WLAN_SOFTAP_FEATURE |
| 846 | tANI_U8 ieee80211d; |
| 847 | tANI_U8 privacy; |
| 848 | tANI_BOOLEAN fwdWPSPBCProbeReq; |
| 849 | tAniAuthType csr80211AuthType; |
| 850 | tANI_U32 dtimPeriod; |
| 851 | tANI_BOOLEAN ApUapsdEnable; |
| 852 | tANI_BOOLEAN protEnabled; |
| 853 | tANI_BOOLEAN obssProtEnabled; |
| 854 | tANI_U16 cfg_protection; |
| 855 | tANI_U8 wps_state; |
| 856 | #endif |
| 857 | |
| 858 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 859 | tCsrMobilityDomainInfo MDID; |
| 860 | #endif |
| 861 | tVOS_CON_MODE csrPersona; |
| 862 | |
| 863 | }tCsrRoamProfile; |
| 864 | |
| 865 | |
| 866 | typedef struct tagCsrRoamConnectedProfile |
| 867 | { |
| 868 | tSirMacSSid SSID; |
| 869 | tANI_BOOLEAN handoffPermitted; |
| 870 | tANI_BOOLEAN ssidHidden; |
| 871 | tCsrBssid bssid; |
| 872 | eCsrRoamBssType BSSType; |
| 873 | eCsrAuthType AuthType; |
| 874 | tCsrAuthList AuthInfo; |
| 875 | eCsrEncryptionType EncryptionType; |
| 876 | tCsrEncryptionList EncryptionInfo; |
| 877 | eCsrEncryptionType mcEncryptionType; |
| 878 | tCsrEncryptionList mcEncryptionInfo; |
| 879 | eCsrCBChoice CBMode; //up, down or auto |
| 880 | tANI_U8 operationChannel; |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 881 | tANI_U16 beaconInterval; |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 882 | tCsrKeys Keys; |
| 883 | // meaningless on connect. It's an OUT param from CSR's point of view |
| 884 | // During assoc response carries the ACM bit-mask i.e. what |
| 885 | // ACs have ACM=1 (if any), |
| 886 | // (Bit0:VO; Bit1:VI; Bit2:BK; Bit3:BE all other bits are ignored) |
| 887 | tANI_U8 acm_mask; |
| 888 | tCsrRoamModifyProfileFields modifyProfileFields; |
Madan Mohan Koyyalamudi | ea22cdc | 2012-10-18 21:02:23 -0700 | [diff] [blame] | 889 | tANI_U32 nAddIEAssocLength; //The byte count in the pAddIE for assoc |
| 890 | tANI_U8 *pAddIEAssoc; //If not null, it has the IE byte stream for additional IE, which can be WSC IE and/or P2P IE |
| 891 | |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 892 | tSirBssDescription *pBssDesc; |
| 893 | tANI_BOOLEAN qap; //AP supports QoS |
| 894 | tANI_BOOLEAN qosConnection; //A connection is QoS enabled |
| 895 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 896 | tCsrMobilityDomainInfo MDID; |
| 897 | #endif |
| 898 | |
| 899 | #ifdef FEATURE_WLAN_CCX |
| 900 | tCsrCcxCckmInfo ccxCckmInfo; |
| 901 | tANI_BOOLEAN isCCXAssoc; |
| 902 | #endif |
| 903 | }tCsrRoamConnectedProfile; |
| 904 | |
| 905 | |
| 906 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 907 | typedef struct tagCsr11rConfigParams |
| 908 | { |
| 909 | tANI_BOOLEAN IsFTResourceReqSupported; |
| 910 | } tCsr11rConfigParams; |
| 911 | #endif |
| 912 | |
| 913 | #ifdef WLAN_FEATURE_NEIGHBOR_ROAMING |
| 914 | typedef struct tagCsrNeighborRoamConfigParams |
| 915 | { |
| 916 | |
| 917 | tANI_U32 nNeighborScanTimerPeriod; |
| 918 | tANI_U8 nNeighborLookupRssiThreshold; |
| 919 | tANI_U8 nNeighborReassocRssiThreshold; |
| 920 | tANI_U16 nNeighborScanMinChanTime; |
| 921 | tANI_U16 nNeighborScanMaxChanTime; |
| 922 | sCsrChannel neighborScanChanList; |
| 923 | tANI_U8 nMaxNeighborRetries; |
| 924 | tANI_U16 nNeighborResultsRefreshPeriod; |
| 925 | }tCsrNeighborRoamConfigParams; |
| 926 | #endif |
| 927 | |
| 928 | typedef struct tagCsrConfigParam |
| 929 | { |
| 930 | tANI_U32 FragmentationThreshold; |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 931 | tANI_U32 channelBondingMode24GHz; // keep this tANI_U32. This gets converted to ePhyChannelBondState |
| 932 | tANI_U32 channelBondingMode5GHz; // in csrChangeDefaultConfigParam using convertCBIniValueToPhyCBState |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 933 | eCsrPhyMode phyMode; |
| 934 | eCsrBand eBand; |
| 935 | tANI_U32 RTSThreshold; |
| 936 | tANI_U32 HeartbeatThresh50; |
| 937 | tANI_U32 HeartbeatThresh24; |
| 938 | eCsrCBChoice cbChoice; |
| 939 | eCsrBand bandCapability; //indicate hw capability |
| 940 | tANI_U32 bgScanInterval; |
| 941 | tANI_U16 TxRate; |
| 942 | eCsrRoamWmmUserModeType WMMSupportMode; |
| 943 | tANI_BOOLEAN Is11eSupportEnabled; |
| 944 | tANI_BOOLEAN Is11dSupportEnabled; |
| 945 | tANI_BOOLEAN Is11dSupportEnabledOriginal; |
| 946 | tANI_BOOLEAN Is11hSupportEnabled; |
| 947 | tANI_BOOLEAN shortSlotTime; |
| 948 | tANI_BOOLEAN ProprietaryRatesEnabled; |
| 949 | tANI_U8 AdHocChannel24; |
| 950 | tANI_U8 AdHocChannel5G; |
| 951 | tANI_U32 impsSleepTime; //in units of seconds |
| 952 | tANI_U32 nScanResultAgeCount; //this number minus one is the number of times a scan doesn't find it before it is removed |
| 953 | tANI_U32 scanAgeTimeNCNPS; //scan result aging time threshold when Not-Connect-No-Power-Save, in seconds |
| 954 | tANI_U32 scanAgeTimeNCPS; //scan result aging time threshold when Not-Connect-Power-Save, in seconds |
| 955 | tANI_U32 scanAgeTimeCNPS; //scan result aging time threshold when Connect-No-Power-Save, in seconds, |
| 956 | tANI_U32 scanAgeTimeCPS; //scan result aging time threshold when Connect-Power-Savein seconds |
| 957 | tANI_U32 nRoamingTime; //In seconds, CSR will try this long before gives up. 0 means no roaming |
| 958 | tANI_U8 bCatRssiOffset; //to set the RSSI difference for each category |
| 959 | tANI_U8 fEnableMCCMode; //to set MCC Enable/Disable mode |
Mohit Khanna | 7ed53f0 | 2012-09-11 17:52:10 -0700 | [diff] [blame] | 960 | tANI_U8 fAllowMCCGODiffBI; //to allow MCC GO different B.I than STA's. NOTE: make sure if RIVA firmware can handle this combination before enabling this |
| 961 | //at the moment, this flag is provided only to pass Wi-Fi Cert. 5.1.12 |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 962 | tCsr11dinfo Csr11dinfo; |
| 963 | //Whether to limit the channels to the ones set in Csr11dInfo. If true, the opertaional |
| 964 | //channels are limited to the default channel list. It is an "AND" operation between the |
| 965 | //default channels and the channels in the 802.11d IE. |
| 966 | tANI_BOOLEAN fEnforce11dChannels; |
| 967 | //Country Code Priority |
| 968 | //0 = 802.11D > Country IOCTL > NV |
| 969 | //1 = Country IOCTL > 802.11D > NV |
| 970 | tANI_BOOLEAN fSupplicantCountryCodeHasPriority; |
| 971 | //When true, AP with unknown country code won't be see. |
| 972 | //"Unknown country code" means either Ap doesn't have 11d IE or we cannot |
| 973 | //find a domain for the country code in its 11d IE. |
| 974 | tANI_BOOLEAN fEnforceCountryCodeMatch; |
| 975 | //When true, only APs in the default domain can be seen. If the Ap has "unknown country |
| 976 | //code", or the domain of the country code doesn't match the default domain, the Ap is |
| 977 | //not acceptable. |
| 978 | tANI_BOOLEAN fEnforceDefaultDomain; |
| 979 | |
| 980 | tANI_U16 vccRssiThreshold; |
| 981 | tANI_U32 vccUlMacLossThreshold; |
| 982 | |
| 983 | tANI_U32 nPassiveMinChnTime; //in units of milliseconds |
| 984 | tANI_U32 nPassiveMaxChnTime; //in units of milliseconds |
| 985 | tANI_U32 nActiveMinChnTime; //in units of milliseconds |
| 986 | tANI_U32 nActiveMaxChnTime; //in units of milliseconds |
Madan Mohan Koyyalamudi | 4ff9cd6 | 2012-10-30 17:48:57 -0700 | [diff] [blame] | 987 | #ifdef WLAN_AP_STA_CONCURRENCY |
| 988 | tANI_U32 nPassiveMinChnTimeConc; //in units of milliseconds |
| 989 | tANI_U32 nPassiveMaxChnTimeConc; //in units of milliseconds |
| 990 | tANI_U32 nActiveMinChnTimeConc; //in units of milliseconds |
| 991 | tANI_U32 nActiveMaxChnTimeConc; //in units of milliseconds |
| 992 | tANI_U32 nRestTimeConc; //in units of milliseconds |
Vinay Malekal | 05fdc81 | 2012-12-17 13:04:30 -0800 | [diff] [blame] | 993 | tANI_U8 nNumChanCombinedConc; //number of channels combined |
| 994 | //in each split scan operation |
Madan Mohan Koyyalamudi | 4ff9cd6 | 2012-10-30 17:48:57 -0700 | [diff] [blame] | 995 | #endif |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 996 | |
| 997 | tANI_BOOLEAN IsIdleScanEnabled; |
| 998 | //in dBm, the maximum TX power |
| 999 | //The actual TX power is the lesser of this value and 11d. |
| 1000 | //If 11d is disable, the lesser of this and default setting. |
| 1001 | tANI_U8 nTxPowerCap; |
| 1002 | tANI_U32 statsReqPeriodicity; //stats request frequency from PE while in full power |
| 1003 | tANI_U32 statsReqPeriodicityInPS;//stats request frequency from PE while in power save |
| 1004 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 1005 | tCsr11rConfigParams csr11rConfig; |
| 1006 | #endif |
| 1007 | #ifdef FEATURE_WLAN_CCX |
| 1008 | tANI_U8 isCcxIniFeatureEnabled; |
| 1009 | #endif |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 1010 | #ifdef FEATURE_WLAN_LFR |
| 1011 | tANI_U8 isFastRoamIniFeatureEnabled; |
| 1012 | #endif |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1013 | |
Jeff Johnson | 04dd8a8 | 2012-06-29 20:41:40 -0700 | [diff] [blame] | 1014 | #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] | 1015 | tANI_U8 isFastTransitionEnabled; |
Jeff Johnson | 43971f5 | 2012-07-17 12:26:56 -0700 | [diff] [blame] | 1016 | tANI_U8 RoamRssiDiff; |
Madan Mohan Koyyalamudi | 62b55b0 | 2012-12-03 16:45:39 -0800 | [diff] [blame] | 1017 | tANI_U8 nImmediateRoamRssiDiff; |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1018 | #endif |
| 1019 | |
| 1020 | #ifdef WLAN_FEATURE_NEIGHBOR_ROAMING |
| 1021 | tCsrNeighborRoamConfigParams neighborRoamConfig; |
| 1022 | #endif |
| 1023 | |
| 1024 | /* Instead of Reassoc, send ADDTS/DELTS even when ACM is off for that AC |
| 1025 | * This is mandated by WMM-AC certification */ |
| 1026 | tANI_BOOLEAN addTSWhenACMIsOff; |
| 1027 | |
| 1028 | |
| 1029 | /*channelPowerInfoList24 has been seen corrupted. Set this flag to true trying to |
| 1030 | * detect when it happens. Adding this into code because we can't reproduce it easily. |
| 1031 | * We don't know when it happens. */ |
| 1032 | tANI_BOOLEAN fValidateList; |
| 1033 | |
| 1034 | /*Customer wants to start with an active scan based on the default country code. |
| 1035 | * This optimization will minimize the driver load to association time. |
| 1036 | * Based on this flag we will bypass the initial passive scan needed for 11d |
| 1037 | * to determine the country code & domain */ |
| 1038 | tANI_BOOLEAN fEnableBypass11d; |
| 1039 | |
| 1040 | /*Customer wants to optimize the scan time. Avoiding scans(passive) on DFS |
| 1041 | * channels while swipping through both bands can save some time |
| 1042 | * (apprx 1.3 sec) */ |
| 1043 | tANI_BOOLEAN fEnableDFSChnlScan; |
| 1044 | |
| 1045 | //To enable/disable scanning 2.4Ghz channels twice on a single scan request from HDD |
| 1046 | tANI_BOOLEAN fScanTwice; |
Jeff Johnson | e724574 | 2012-09-05 17:12:55 -0700 | [diff] [blame] | 1047 | #ifdef WLAN_FEATURE_11AC |
| 1048 | tANI_U32 nVhtChannelWidth; |
| 1049 | #endif |
| 1050 | |
| 1051 | /* |
| 1052 | * To enable/disable scanning only 2.4Ghz channels on first scan |
| 1053 | */ |
| 1054 | tANI_BOOLEAN fFirstScanOnly2GChnl; |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1055 | |
Madan Mohan Koyyalamudi | 3f65e31 | 2012-11-06 15:31:12 -0800 | [diff] [blame] | 1056 | tANI_BOOLEAN fIgnore_chan165; |
Madan Mohan Koyyalamudi | d502607 | 2012-11-30 14:56:21 -0800 | [diff] [blame] | 1057 | #if defined (WLAN_FEATURE_VOWIFI_11R) || defined (FEATURE_WLAN_CCX) || defined(FEATURE_WLAN_LFR) |
| 1058 | tANI_BOOLEAN nRoamPrefer5GHz; |
| 1059 | #endif |
Madan Mohan Koyyalamudi | 3f65e31 | 2012-11-06 15:31:12 -0800 | [diff] [blame] | 1060 | |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1061 | }tCsrConfigParam; |
| 1062 | |
| 1063 | //Tush |
| 1064 | typedef struct tagCsrUpdateConfigParam |
| 1065 | { |
| 1066 | tCsr11dinfo Csr11dinfo; |
| 1067 | }tCsrUpdateConfigParam; |
| 1068 | |
| 1069 | typedef struct tagCsrRoamInfo |
| 1070 | { |
| 1071 | tCsrRoamProfile *pProfile; //may be NULL |
| 1072 | tSirBssDescription *pBssDesc; //May be NULL |
| 1073 | tANI_U32 nBeaconLength; //the length, in bytes, of the beacon frame, can be 0 |
| 1074 | tANI_U32 nAssocReqLength; //the length, in bytes, of the assoc req frame, can be 0 |
| 1075 | tANI_U32 nAssocRspLength; //The length, in bytes, of the assoc rsp frame, can be 0 |
| 1076 | tANI_U32 nFrameLength; |
| 1077 | tANI_U8 frameType; |
| 1078 | tANI_U8 *pbFrames; //Point to a buffer contain the beacon, assoc req, assoc rsp frame, in that order |
| 1079 | //user needs to use nBeaconLength, nAssocReqLength, nAssocRspLength to desice where |
| 1080 | //each frame starts and ends. |
| 1081 | tANI_BOOLEAN fReassocReq; //set to true if for re-association |
| 1082 | tANI_BOOLEAN fReassocRsp; //set to true if for re-association |
| 1083 | tCsrBssid bssid; |
| 1084 | //Only valid in IBSS |
| 1085 | //this is the peers MAC address for eCSR_ROAM_RESULT_IBSS_NEW_PEER or PEER_DEPARTED |
| 1086 | tCsrBssid peerMac; |
| 1087 | tSirResultCodes statusCode; |
| 1088 | tANI_U32 reasonCode; //this could be our own defined or sent from the other BSS(per 802.11 spec) |
| 1089 | tANI_U8 staId; // Peer stationId when connected |
| 1090 | /*The DPU signatures will be sent eventually to TL to help it determine the |
| 1091 | association to which a packet belongs to*/ |
| 1092 | /*Unicast DPU signature*/ |
| 1093 | tANI_U8 ucastSig; |
| 1094 | |
| 1095 | /*Broadcast DPU signature*/ |
| 1096 | tANI_U8 bcastSig; |
| 1097 | |
| 1098 | tANI_BOOLEAN fAuthRequired; //FALSE means auth needed from supplicant. TRUE means authenticated(static WEP, open) |
| 1099 | tANI_U8 sessionId; |
| 1100 | tANI_U8 rsnIELen; |
| 1101 | tANI_U8 *prsnIE; |
| 1102 | |
| 1103 | tANI_U8 addIELen; |
| 1104 | tANI_U8 *paddIE; |
| 1105 | |
| 1106 | union |
| 1107 | { |
| 1108 | tSirMicFailureInfo *pMICFailureInfo; |
| 1109 | tCsrRoamConnectedProfile *pConnectedProfile; |
| 1110 | #ifdef WLAN_SOFTAP_FEATURE |
| 1111 | tSirWPSPBCProbeReq *pWPSPBCProbeReq; |
| 1112 | #endif |
| 1113 | } u; |
| 1114 | |
| 1115 | #ifdef WLAN_SOFTAP_FEATURE |
| 1116 | tANI_BOOLEAN wmmEnabledSta; //set to true if WMM enabled STA |
| 1117 | tANI_U32 dtimPeriod; |
| 1118 | #endif |
| 1119 | |
| 1120 | #ifdef FEATURE_WLAN_CCX |
| 1121 | tANI_BOOLEAN isCCXAssoc; |
| 1122 | #endif |
| 1123 | #ifdef WLAN_FEATURE_P2P |
| 1124 | void* pRemainCtx; |
| 1125 | tANI_U32 rxChan; |
| 1126 | #endif |
| 1127 | |
Mohit Khanna | 698ba2a | 2012-12-04 15:08:18 -0800 | [diff] [blame] | 1128 | #ifdef FEATURE_WLAN_TDLS |
| 1129 | tANI_U8 staType; |
| 1130 | #endif |
| 1131 | |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1132 | // Required for indicating the frames to upper layer |
| 1133 | tANI_U32 beaconLength; |
| 1134 | tANI_U8* beaconPtr; |
| 1135 | tANI_U32 assocReqLength; |
| 1136 | tANI_U8* assocReqPtr; |
| 1137 | }tCsrRoamInfo; |
| 1138 | |
| 1139 | |
| 1140 | |
| 1141 | |
| 1142 | |
| 1143 | typedef struct tagCsrFreqScanInfo |
| 1144 | { |
| 1145 | tANI_U32 nStartFreq; //in unit of MHz |
| 1146 | tANI_U32 nEndFreq; //in unit of MHz |
| 1147 | tSirScanType scanType; |
| 1148 | }tCsrFreqScanInfo; |
| 1149 | |
| 1150 | |
| 1151 | #ifdef WLAN_SOFTAP_FEATURE |
| 1152 | typedef struct sSirSmeAssocIndToUpperLayerCnf |
| 1153 | { |
| 1154 | tANI_U16 messageType; // eWNI_SME_ASSOC_CNF |
| 1155 | tANI_U16 length; |
| 1156 | tANI_U8 sessionId; |
| 1157 | tSirResultCodes statusCode; |
| 1158 | tSirMacAddr bssId; // Self BSSID |
| 1159 | tSirMacAddr peerMacAddr; |
| 1160 | tANI_U16 aid; |
| 1161 | tSirMacAddr alternateBssId; |
| 1162 | tANI_U8 alternateChannelId; |
| 1163 | tANI_U8 wmmEnabledSta; //set to true if WMM enabled STA |
| 1164 | tSirRSNie rsnIE; // RSN IE received from peer |
| 1165 | tSirAddie addIE; // Additional IE received from peer, which can be WSC and/or P2P IE |
| 1166 | tANI_U8 reassocReq; //set to true if reassoc |
| 1167 | } tSirSmeAssocIndToUpperLayerCnf, *tpSirSmeAssocIndToUpperLayerCnf; |
| 1168 | #endif |
| 1169 | |
| 1170 | typedef struct tagCsrSummaryStatsInfo |
| 1171 | { |
| 1172 | tANI_U32 retry_cnt[4]; |
| 1173 | tANI_U32 multiple_retry_cnt[4]; |
| 1174 | tANI_U32 tx_frm_cnt[4]; |
| 1175 | //tANI_U32 num_rx_frm_crc_err; same as rx_error_cnt |
| 1176 | //tANI_U32 num_rx_frm_crc_ok; same as rx_frm_cnt |
| 1177 | tANI_U32 rx_frm_cnt; |
| 1178 | tANI_U32 frm_dup_cnt; |
| 1179 | tANI_U32 fail_cnt[4]; |
| 1180 | tANI_U32 rts_fail_cnt; |
| 1181 | tANI_U32 ack_fail_cnt; |
| 1182 | tANI_U32 rts_succ_cnt; |
| 1183 | tANI_U32 rx_discard_cnt; |
| 1184 | tANI_U32 rx_error_cnt; |
| 1185 | tANI_U32 tx_byte_cnt; |
| 1186 | |
| 1187 | }tCsrSummaryStatsInfo; |
| 1188 | |
| 1189 | typedef struct tagCsrGlobalClassAStatsInfo |
| 1190 | { |
| 1191 | tANI_U32 rx_frag_cnt; |
| 1192 | tANI_U32 promiscuous_rx_frag_cnt; |
| 1193 | //tANI_U32 rx_fcs_err; |
| 1194 | tANI_U32 rx_input_sensitivity; |
| 1195 | tANI_U32 max_pwr; |
| 1196 | //tANI_U32 default_pwr; |
| 1197 | tANI_U32 sync_fail_cnt; |
| 1198 | tANI_U32 tx_rate; |
| 1199 | //mcs index for HT20 and HT40 rates |
| 1200 | tANI_U32 mcs_index; |
| 1201 | //to defferentiate between HT20 and HT40 rates;short and long guard interval |
| 1202 | tANI_U32 tx_rate_flags; |
| 1203 | |
| 1204 | }tCsrGlobalClassAStatsInfo; |
| 1205 | |
| 1206 | typedef struct tagCsrGlobalClassBStatsInfo |
| 1207 | { |
| 1208 | tANI_U32 uc_rx_wep_unencrypted_frm_cnt; |
| 1209 | tANI_U32 uc_rx_mic_fail_cnt; |
| 1210 | tANI_U32 uc_tkip_icv_err; |
| 1211 | tANI_U32 uc_aes_ccmp_format_err; |
| 1212 | tANI_U32 uc_aes_ccmp_replay_cnt; |
| 1213 | tANI_U32 uc_aes_ccmp_decrpt_err; |
| 1214 | tANI_U32 uc_wep_undecryptable_cnt; |
| 1215 | tANI_U32 uc_wep_icv_err; |
| 1216 | tANI_U32 uc_rx_decrypt_succ_cnt; |
| 1217 | tANI_U32 uc_rx_decrypt_fail_cnt; |
| 1218 | tANI_U32 mcbc_rx_wep_unencrypted_frm_cnt; |
| 1219 | tANI_U32 mcbc_rx_mic_fail_cnt; |
| 1220 | tANI_U32 mcbc_tkip_icv_err; |
| 1221 | tANI_U32 mcbc_aes_ccmp_format_err; |
| 1222 | tANI_U32 mcbc_aes_ccmp_replay_cnt; |
| 1223 | tANI_U32 mcbc_aes_ccmp_decrpt_err; |
| 1224 | tANI_U32 mcbc_wep_undecryptable_cnt; |
| 1225 | tANI_U32 mcbc_wep_icv_err; |
| 1226 | tANI_U32 mcbc_rx_decrypt_succ_cnt; |
| 1227 | tANI_U32 mcbc_rx_decrypt_fail_cnt; |
| 1228 | |
| 1229 | }tCsrGlobalClassBStatsInfo; |
| 1230 | |
| 1231 | typedef struct tagCsrGlobalClassCStatsInfo |
| 1232 | { |
| 1233 | tANI_U32 rx_amsdu_cnt; |
| 1234 | tANI_U32 rx_ampdu_cnt; |
| 1235 | tANI_U32 tx_20_frm_cnt; |
| 1236 | tANI_U32 rx_20_frm_cnt; |
| 1237 | tANI_U32 rx_mpdu_in_ampdu_cnt; |
| 1238 | tANI_U32 ampdu_delimiter_crc_err; |
| 1239 | |
| 1240 | }tCsrGlobalClassCStatsInfo; |
| 1241 | |
| 1242 | typedef struct tagCsrGlobalClassDStatsInfo |
| 1243 | { |
| 1244 | tANI_U32 tx_uc_frm_cnt; |
| 1245 | tANI_U32 tx_mc_frm_cnt; |
| 1246 | tANI_U32 tx_bc_frm_cnt; |
| 1247 | tANI_U32 rx_uc_frm_cnt; |
| 1248 | tANI_U32 rx_mc_frm_cnt; |
| 1249 | tANI_U32 rx_bc_frm_cnt; |
| 1250 | tANI_U32 tx_uc_byte_cnt[4]; |
| 1251 | tANI_U32 tx_mc_byte_cnt; |
| 1252 | tANI_U32 tx_bc_byte_cnt; |
| 1253 | tANI_U32 rx_uc_byte_cnt[4]; |
| 1254 | tANI_U32 rx_mc_byte_cnt; |
| 1255 | tANI_U32 rx_bc_byte_cnt; |
| 1256 | tANI_U32 rx_byte_cnt; |
| 1257 | tANI_U32 num_rx_bytes_crc_ok; |
| 1258 | tANI_U32 rx_rate; |
| 1259 | |
| 1260 | }tCsrGlobalClassDStatsInfo; |
| 1261 | |
| 1262 | typedef struct tagCsrPerStaStatsInfo |
| 1263 | { |
| 1264 | tANI_U32 tx_frag_cnt[4]; |
| 1265 | tANI_U32 tx_ampdu_cnt; |
| 1266 | tANI_U32 tx_mpdu_in_ampdu_cnt; |
| 1267 | } tCsrPerStaStatsInfo; |
| 1268 | |
| 1269 | typedef struct tagCsrRoamSetKey |
| 1270 | { |
| 1271 | eCsrEncryptionType encType; |
| 1272 | tAniKeyDirection keyDirection; //Tx, Rx or Tx-and-Rx |
| 1273 | tCsrBssid peerMac; //Peers MAC address. ALL 1's for group key |
| 1274 | tANI_U8 paeRole; //0 for supplicant |
| 1275 | tANI_U8 keyId; // Kye index |
| 1276 | tANI_U16 keyLength; //Number of bytes containing the key in pKey |
| 1277 | tANI_U8 Key[CSR_MAX_KEY_LEN]; |
| 1278 | tANI_U8 keyRsc[CSR_MAX_RSC_LEN]; |
| 1279 | } tCsrRoamSetKey; |
| 1280 | |
| 1281 | typedef struct tagCsrRoamRemoveKey |
| 1282 | { |
| 1283 | eCsrEncryptionType encType; |
| 1284 | tCsrBssid peerMac; //Peers MAC address. ALL 1's for group key |
| 1285 | tANI_U8 keyId; //key index |
| 1286 | } tCsrRoamRemoveKey; |
| 1287 | |
Mohit Khanna | 698ba2a | 2012-12-04 15:08:18 -0800 | [diff] [blame] | 1288 | #ifdef FEATURE_WLAN_TDLS |
| 1289 | typedef struct tagCsrTdlsSendMgmt |
| 1290 | { |
| 1291 | tSirMacAddr peerMac; |
| 1292 | tANI_U8 frameType; |
| 1293 | tANI_U8 dialog; |
| 1294 | tANI_U16 statusCode; |
| 1295 | tANI_U8 *buf; |
| 1296 | tANI_U8 len; |
| 1297 | |
| 1298 | }tCsrTdlsSendMgmt; |
| 1299 | |
| 1300 | #ifdef FEATURE_WLAN_TDLS_INTERNAL |
| 1301 | typedef struct tagCsrTdlsDisRequest |
| 1302 | { |
| 1303 | tSirMacAddr peerMac; |
| 1304 | tANI_U8 disType; |
| 1305 | }tCsrTdlsDisRequest; |
| 1306 | |
| 1307 | typedef struct tagCsrTdlsSetupRequest |
| 1308 | { |
| 1309 | tSirMacAddr peerMac; |
| 1310 | tANI_U8 linkIndex; |
| 1311 | }tCsrTdlsSetupRequest; |
| 1312 | |
| 1313 | typedef struct tagCsrTdlsTeardownRequest |
| 1314 | { |
| 1315 | tSirMacAddr peerMac; |
| 1316 | tANI_U8 linkIndex; |
| 1317 | }tCsrTdlsTeardownRequest ; |
| 1318 | #endif |
| 1319 | #endif |
Jeff Johnson | 295189b | 2012-06-20 16:38:30 -0700 | [diff] [blame] | 1320 | |
| 1321 | typedef void * tScanResultHandle; |
| 1322 | |
| 1323 | #define CSR_INVALID_SCANRESULT_HANDLE (NULL) |
| 1324 | |
| 1325 | |
| 1326 | |
| 1327 | ////////////////////////////////////////////Common SCAN starts |
| 1328 | |
| 1329 | //void *p2 -- the second context pass in for the caller |
| 1330 | //***what if callback is called before requester gets the scanId?? |
| 1331 | typedef eHalStatus (*csrScanCompleteCallback)(tHalHandle, void *p2, tANI_U32 scanID, eCsrScanStatus status); |
| 1332 | |
| 1333 | |
| 1334 | |
| 1335 | ///////////////////////////////////////////Common Roam starts |
| 1336 | |
| 1337 | //pContext is the pContext passed in with the roam request |
| 1338 | //pParam is a pointer to a tCsrRoamInfo, see definition of eRoamCmdStatus and |
| 1339 | // eRoamCmdResult for detail valid members. It may be NULL |
| 1340 | //roamId is to identify the callback related roam request. 0 means unsolicit |
| 1341 | //roamStatus is a flag indicating the status of the callback |
| 1342 | //roamResult is the result |
| 1343 | typedef eHalStatus (*csrRoamCompleteCallback)(void *pContext, tCsrRoamInfo *pParam, tANI_U32 roamId, |
| 1344 | eRoamCmdStatus roamStatus, eCsrRoamResult roamResult); |
| 1345 | |
| 1346 | typedef eHalStatus (*csrRoamSessionCloseCallback)(void *pContext); |
| 1347 | |
| 1348 | /* --------------------------------------------------------------------------- |
| 1349 | \fn csrRoamGetNumPMKIDCache |
| 1350 | \brief return number of PMKID cache entries |
| 1351 | \return tANI_U32 - the number of PMKID cache entries |
| 1352 | -------------------------------------------------------------------------------*/ |
| 1353 | //tANI_U32 csrRoamGetNumPMKIDCache(tHalHandle hHal); |
| 1354 | |
| 1355 | /* --------------------------------------------------------------------------- |
| 1356 | \fn csrRoamGetPMKIDCache |
| 1357 | \brief return PMKID cache from CSR |
| 1358 | \param pNum - caller allocated memory that has the space of the number of pBuf tPmkidCacheInfo as input. Upon returned, *pNum has the |
| 1359 | needed or actually number in tPmkidCacheInfo. |
| 1360 | \param pPmkidCache - Caller allocated memory that contains PMKID cache, if any, upon return |
| 1361 | \return eHalStatus - when fail, it usually means the buffer allocated is not big enough |
| 1362 | -------------------------------------------------------------------------------*/ |
| 1363 | //eHalStatus csrRoamGetPMKIDCache(tHalHandle hHal, tANI_U32 *pNum, tPmkidCacheInfo *pPmkidCache); |
| 1364 | |
| 1365 | //pProfile - pointer to tCsrRoamProfile |
| 1366 | #define CSR_IS_START_IBSS(pProfile) (eCSR_BSS_TYPE_START_IBSS == (pProfile)->BSSType) |
| 1367 | #define CSR_IS_JOIN_TO_IBSS(pProfile) (eCSR_BSS_TYPE_IBSS == (pProfile)->BSSType) |
| 1368 | #define CSR_IS_IBSS(pProfile) ( CSR_IS_START_IBSS(pProfile) || CSR_IS_JOIN_TO_IBSS(pProfile) ) |
| 1369 | #define CSR_IS_INFRASTRUCTURE(pProfile) (eCSR_BSS_TYPE_INFRASTRUCTURE == (pProfile)->BSSType) |
| 1370 | #define CSR_IS_ANY_BSS_TYPE(pProfile) (eCSR_BSS_TYPE_ANY == (pProfile)->BSSType) |
| 1371 | #define CSR_IS_WDS_AP( pProfile ) ( eCSR_BSS_TYPE_WDS_AP == (pProfile)->BSSType ) |
| 1372 | #define CSR_IS_WDS_STA( pProfile ) ( eCSR_BSS_TYPE_WDS_STA == (pProfile)->BSSType ) |
| 1373 | #define CSR_IS_WDS( pProfile ) ( CSR_IS_WDS_AP( pProfile ) || CSR_IS_WDS_STA( pProfile ) ) |
| 1374 | #ifdef WLAN_SOFTAP_FEATURE |
| 1375 | #define CSR_IS_INFRA_AP( pProfile ) ( eCSR_BSS_TYPE_INFRA_AP == (pProfile)->BSSType ) |
| 1376 | #endif |
| 1377 | |
| 1378 | //pProfile - pointer to tCsrRoamConnectedProfile |
| 1379 | #ifdef WLAN_SOFTAP_FEATURE |
| 1380 | #define CSR_IS_CONN_INFRA_AP( pProfile ) ( eCSR_BSS_TYPE_INFRA_AP == (pProfile)->BSSType ) |
| 1381 | #endif |
| 1382 | #define CSR_IS_CONN_WDS_AP( pProfile ) ( eCSR_BSS_TYPE_WDS_AP == (pProfile)->BSSType ) |
| 1383 | #define CSR_IS_CONN_WDS_STA( pProfile ) ( eCSR_BSS_TYPE_WDS_STA == (pProfile)->BSSType ) |
| 1384 | #define CSR_IS_CONN_WDS( pProfile ) ( CSR_IS_WDS_AP( pProfile ) || CSR_IS_WDS_STA( pProfile ) ) |
| 1385 | |
| 1386 | |
| 1387 | |
| 1388 | ///////////////////////////////////////////Common Roam ends |
| 1389 | |
| 1390 | |
| 1391 | |
| 1392 | #ifdef WLAN_SOFTAP_FEATURE |
| 1393 | /* --------------------------------------------------------------------------- |
| 1394 | \fn csrSetChannels |
| 1395 | \brief HDD calls this function to change some global settings. |
| 1396 | caller must set the all fields or call csrGetConfigParam to prefill the fields. |
| 1397 | \param pParam - caller allocated memory |
| 1398 | \return eHalStatus |
| 1399 | -------------------------------------------------------------------------------*/ |
| 1400 | |
| 1401 | eHalStatus csrSetChannels(tHalHandle hHal, tCsrConfigParam *pParam ); |
| 1402 | |
| 1403 | eHalStatus csrSetRegInfo(tHalHandle hHal, tANI_U8 *apCntryCode); |
| 1404 | #endif |
| 1405 | |
| 1406 | |
| 1407 | //enum to string conversion for debug output |
| 1408 | const char * get_eRoamCmdStatus_str(eRoamCmdStatus val); |
| 1409 | const char * get_eCsrRoamResult_str(eCsrRoamResult val); |
| 1410 | /* --------------------------------------------------------------------------- |
| 1411 | \fn csrSetPhyMode |
| 1412 | \brief HDD calls this function to set the phyMode. |
| 1413 | This function must be called after CFG is downloaded and all the band/mode setting already passed into |
| 1414 | CSR. |
| 1415 | \param phyMode - indicate the phyMode needs to set to. The value has to be either 0, or some bits set. |
| 1416 | See eCsrPhyMode for definition |
| 1417 | \param eBand - specify the operational band (2.4, 5 or both) |
| 1418 | \param pfRestartNeeded - pointer to a caller allocated space. Upon successful return, it indicates whether |
| 1419 | a restart is needed to apply the change |
| 1420 | \return eHalStatus |
| 1421 | -------------------------------------------------------------------------------*/ |
| 1422 | eHalStatus csrSetPhyMode(tHalHandle hHal, tANI_U32 phyMode, eCsrBand eBand, tANI_BOOLEAN *pfRestartNeeded); |
| 1423 | |
| 1424 | void csrDumpInit(tHalHandle hHal); |
| 1425 | |
| 1426 | |
| 1427 | /*--------------------------------------------------------------------------- |
| 1428 | This is the type for a link quality callback to be registered with SME |
| 1429 | for indications |
| 1430 | Once the link quality has been indicated, subsequently, link indications are |
| 1431 | posted each time there is a CHANGE in link quality. |
| 1432 | *** If there is no change in link, there will be no indication *** |
| 1433 | |
| 1434 | The indications may be based on one or more criteria internal to SME |
| 1435 | such as RSSI and PER. |
| 1436 | |
| 1437 | \param ind - Indication being posted |
| 1438 | \param pContext - any user data given at callback registration. |
| 1439 | \return None |
| 1440 | |
| 1441 | ---------------------------------------------------------------------------*/ |
| 1442 | typedef void (* csrRoamLinkQualityIndCallback) |
| 1443 | (eCsrRoamLinkQualityInd ind, void *pContext); |
| 1444 | |
| 1445 | |
| 1446 | /*--------------------------------------------------------------------------- |
| 1447 | This is the type for a statistics callback to be registered with SME |
| 1448 | for stats reporting |
| 1449 | |
| 1450 | Since the client requesting for the stats already know which class/type of |
| 1451 | stats it asked for, the callback will carry them in the rsp buffer |
| 1452 | (void * stats) whose size will be same as the size of requested stats & |
| 1453 | will be exactly in the same order requested in the stats mask from LSB to MSB |
| 1454 | |
| 1455 | \param stats - stats rsp buffer sent back with the report |
| 1456 | \param pContext - any user data given at callback registration. |
| 1457 | \return None |
| 1458 | |
| 1459 | ---------------------------------------------------------------------------*/ |
| 1460 | typedef void ( *tCsrStatsCallback) (void * stats, void *pContext); |
| 1461 | |
| 1462 | /*--------------------------------------------------------------------------- |
| 1463 | This is the type for a rssi callback to be registered with SME |
| 1464 | for getting rssi |
| 1465 | |
| 1466 | \param rssi - rssi |
| 1467 | \param pContext - any user data given at callback registration. |
| 1468 | \return None |
| 1469 | |
| 1470 | ---------------------------------------------------------------------------*/ |
| 1471 | |
| 1472 | typedef void ( *tCsrRssiCallback) (v_S7_t rssi, tANI_U32 staId, void *pContext); |
| 1473 | |
| 1474 | #ifdef WLAN_FEATURE_VOWIFI_11R |
| 1475 | eHalStatus csrRoamIssueFTPreauthReq(tHalHandle hHal, tANI_U32 sessionId, tpSirBssDescription pBssDescription); |
| 1476 | #endif |
| 1477 | |
| 1478 | /*--------------------------------------------------------------------------- |
| 1479 | This is the function to change the Band configuraiton (ALL/2.4 GHZ/5 GHZ) |
| 1480 | |
| 1481 | \param hHal - handle to Hal context |
| 1482 | \param eBand - band value |
| 1483 | \return eHalStatus |
| 1484 | |
| 1485 | ---------------------------------------------------------------------------*/ |
| 1486 | eHalStatus csrSetBand(tHalHandle hHal, eCsrBand eBand); |
| 1487 | |
| 1488 | /*--------------------------------------------------------------------------- |
| 1489 | This is the function to get the current operating band value |
| 1490 | \param hHal - handl to Hal context |
| 1491 | \return eCsrband - band value |
| 1492 | |
| 1493 | ---------------------------------------------------------------------------*/ |
| 1494 | eCsrBand csrGetCurrentBand (tHalHandle hHal); |
| 1495 | |
| 1496 | #endif |
| 1497 | |