Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1 | /* |
Ashish Kumar Dhanotiya | 443d31f | 2017-10-13 12:41:19 +0530 | [diff] [blame] | 2 | * Copyright (c) 2012-2018 The Linux Foundation. All rights reserved. |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3 | * |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4 | * Permission to use, copy, modify, and/or distribute this software for |
| 5 | * any purpose with or without fee is hereby granted, provided that the |
| 6 | * above copyright notice and this permission notice appear in all |
| 7 | * copies. |
| 8 | * |
| 9 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL |
| 10 | * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED |
| 11 | * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE |
| 12 | * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL |
| 13 | * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR |
| 14 | * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
| 15 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
| 16 | * PERFORMANCE OF THIS SOFTWARE. |
| 17 | */ |
| 18 | |
| 19 | /* |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 20 | * This file sir_api.h contains definitions exported by |
| 21 | * Sirius software. |
| 22 | * Author: Chandra Modumudi |
| 23 | * Date: 04/16/2002 |
| 24 | * History:- |
| 25 | * Date Modified by Modification Information |
| 26 | * -------------------------------------------------------------------- |
| 27 | */ |
| 28 | |
| 29 | #ifndef __SIR_API_H |
| 30 | #define __SIR_API_H |
| 31 | |
Jeff Johnson | 009c40f | 2018-11-05 09:54:37 -0800 | [diff] [blame] | 32 | /* legacy definition */ |
Jeff Johnson | 17c631b | 2018-12-10 09:10:58 -0800 | [diff] [blame] | 33 | typedef void *tpAniSirGlobal; |
Anurag Chouhan | 5de8d17 | 2016-07-13 14:44:28 +0530 | [diff] [blame] | 34 | |
Jeff Johnson | 17c631b | 2018-12-10 09:10:58 -0800 | [diff] [blame] | 35 | struct mac_context; |
Amar Singhal | e4f28ee | 2015-10-21 14:36:56 -0700 | [diff] [blame] | 36 | #include "qdf_types.h" |
Amar Singhal | e4f28ee | 2015-10-21 14:36:56 -0700 | [diff] [blame] | 37 | #include "cds_regdomain.h" |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 38 | #include "sir_types.h" |
| 39 | #include "sir_mac_prot_def.h" |
| 40 | #include "ani_system_defs.h" |
| 41 | #include "sir_params.h" |
Naveen Rawat | 3b6068c | 2016-04-14 19:01:06 -0700 | [diff] [blame] | 42 | #include "cds_regdomain.h" |
Dustin Brown | 877a5a9 | 2016-11-17 13:56:52 -0800 | [diff] [blame] | 43 | #include "wmi_unified.h" |
Gupta, Kapil | 96c7f2f | 2016-04-25 19:13:41 +0530 | [diff] [blame] | 44 | #include "wmi_unified_param.h" |
Zhang Qian | a6e9c10 | 2016-12-22 16:47:24 +0800 | [diff] [blame] | 45 | #include "ol_txrx_htt_api.h" |
Kiran Kumar Lokere | a3de226 | 2017-04-12 12:15:04 -0700 | [diff] [blame] | 46 | #include "wlan_reg_services_api.h" |
Anurag Chouhan | 5de8d17 | 2016-07-13 14:44:28 +0530 | [diff] [blame] | 47 | #include <dot11f.h> |
Tushnim Bhattacharyya | 9e81b4c | 2017-02-15 17:11:14 -0800 | [diff] [blame] | 48 | #include "wlan_policy_mgr_api.h" |
Bala Venkatesh | 4a72b06 | 2018-11-13 13:04:49 +0530 | [diff] [blame] | 49 | #include "wlan_tdls_public_structs.h" |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 50 | |
Rachit Kankane | 154559c | 2018-07-12 14:02:30 +0530 | [diff] [blame] | 51 | #ifndef SIR_MAX_SUPPORTED_BSS |
Naveen Rawat | b0c5b6b | 2017-11-27 17:37:40 -0800 | [diff] [blame] | 52 | #define SIR_MAX_SUPPORTED_BSS 5 |
Rachit Kankane | 154559c | 2018-07-12 14:02:30 +0530 | [diff] [blame] | 53 | #endif |
Naveen Rawat | b0c5b6b | 2017-11-27 17:37:40 -0800 | [diff] [blame] | 54 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 55 | #define OFFSET_OF(structType, fldName) (&((structType *)0)->fldName) |
| 56 | |
| 57 | /* / Max supported channel list */ |
| 58 | #define SIR_MAX_SUPPORTED_CHANNEL_LIST 96 |
| 59 | |
| 60 | #define SIR_MDIE_ELEMENT_ID 54 |
Srinivas Girigowda | d65dc5a | 2016-01-14 17:08:26 -0800 | [diff] [blame] | 61 | #define SIR_MDIE_SIZE 3 /* MD ID(2 bytes), Capability(1 byte) */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 62 | |
Sridhar Selvaraj | 8c6f5e8 | 2017-08-21 14:53:46 +0530 | [diff] [blame] | 63 | #define SIR_MAX_ELEMENT_ID 255 |
| 64 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 65 | /* Max number of channels are 165, but to access 165th element of array, |
| 66 | *array of 166 is required. |
| 67 | */ |
| 68 | #define SIR_MAX_24G_5G_CHANNEL_RANGE 166 |
| 69 | #define SIR_BCN_REPORT_MAX_BSS_DESC 4 |
| 70 | |
| 71 | #define SIR_NUM_11B_RATES 4 /* 1,2,5.5,11 */ |
| 72 | #define SIR_NUM_11A_RATES 8 /* 6,9,12,18,24,36,48,54 */ |
| 73 | |
| 74 | #define SIR_PM_SLEEP_MODE 0 |
| 75 | #define SIR_PM_ACTIVE_MODE 1 |
| 76 | |
| 77 | /* hidden SSID options */ |
| 78 | #define SIR_SCAN_NO_HIDDEN_SSID 0 |
| 79 | #define SIR_SCAN_HIDDEN_SSID_PE_DECISION 1 |
| 80 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 81 | #define SIR_IPV4_ADDR_LEN 4 |
| 82 | |
| 83 | typedef uint8_t tSirIpv4Addr[SIR_IPV4_ADDR_LEN]; |
| 84 | |
| 85 | #define SIR_VERSION_STRING_LEN 64 |
| 86 | typedef uint8_t tSirVersionString[SIR_VERSION_STRING_LEN]; |
| 87 | |
| 88 | /* Periodic Tx pattern offload feature */ |
| 89 | #define PERIODIC_TX_PTRN_MAX_SIZE 1536 |
| 90 | #define MAXNUM_PERIODIC_TX_PTRNS 6 |
| 91 | #define WIFI_SCANNING_MAC_OUI_LENGTH 3 |
| 92 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 93 | /* This should not be greater than MAX_NUMBER_OF_CONC_CONNECTIONS */ |
| 94 | #define MAX_VDEV_SUPPORTED 4 |
| 95 | |
Manjeet Singh | f82ed07 | 2016-07-08 11:40:00 +0530 | [diff] [blame] | 96 | #define MAX_POWER_DBG_ARGS_SUPPORTED 8 |
Agrawal Ashish | ad16bda | 2016-09-16 20:16:04 +0530 | [diff] [blame] | 97 | #define QOS_MAP_MAX_EX 21 |
| 98 | #define QOS_MAP_LEN_MIN 16 |
| 99 | #define QOS_MAP_LEN_MAX \ |
| 100 | (QOS_MAP_LEN_MIN + 2 * QOS_MAP_MAX_EX) |
Himanshu Agarwal | 37e4241 | 2016-07-21 14:35:09 +0530 | [diff] [blame] | 101 | #define NUM_CHAINS_MAX 2 |
| 102 | |
Abhishek Singh | f3756fc | 2017-06-28 16:04:06 +0530 | [diff] [blame] | 103 | #define MAX_RSSI_AVOID_BSSID_LIST 10 |
Sridhar Selvaraj | a44c19e | 2017-08-21 14:20:20 +0530 | [diff] [blame] | 104 | |
| 105 | /* Maximum number of realms present in fils indication element */ |
| 106 | #define SIR_MAX_REALM_COUNT 7 |
| 107 | /* Realm length */ |
| 108 | #define SIR_REALM_LEN 2 |
| 109 | /* Cache ID length */ |
| 110 | #define CACHE_ID_LEN 2 |
| 111 | |
Will Huang | 496b36c | 2017-07-11 16:38:50 +0800 | [diff] [blame] | 112 | /* Maximum peer station number query one time */ |
| 113 | #define MAX_PEER_STA 12 |
| 114 | |
Naveen Rawat | b0c5b6b | 2017-11-27 17:37:40 -0800 | [diff] [blame] | 115 | /* Maximum number of peers for SAP */ |
Rachit Kankane | 154559c | 2018-07-12 14:02:30 +0530 | [diff] [blame] | 116 | #ifndef SIR_SAP_MAX_NUM_PEERS |
Naveen Rawat | b0c5b6b | 2017-11-27 17:37:40 -0800 | [diff] [blame] | 117 | #define SIR_SAP_MAX_NUM_PEERS 32 |
Rachit Kankane | 154559c | 2018-07-12 14:02:30 +0530 | [diff] [blame] | 118 | #endif |
Naveen Rawat | b0c5b6b | 2017-11-27 17:37:40 -0800 | [diff] [blame] | 119 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 120 | #define SIR_KRK_KEY_LEN 16 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 121 | #define SIR_BTK_KEY_LEN 32 |
| 122 | #define SIR_KCK_KEY_LEN 16 |
| 123 | #define SIR_KEK_KEY_LEN 16 |
Vignesh Viswanathan | c6d1e1c | 2017-09-18 12:32:49 +0530 | [diff] [blame] | 124 | #define SIR_KEK_KEY_LEN_FILS 64 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 125 | #define SIR_REPLAY_CTR_LEN 8 |
Vignesh Viswanathan | c6d1e1c | 2017-09-18 12:32:49 +0530 | [diff] [blame] | 126 | #define SIR_PMK_LEN 48 |
| 127 | #define SIR_PMKID_LEN 16 |
Varun Reddy Yeturu | bbbbe23 | 2016-02-29 14:01:57 -0800 | [diff] [blame] | 128 | #ifdef WLAN_FEATURE_ROAM_OFFLOAD |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 129 | #define SIR_UAPSD_BITOFFSET_ACVO 0 |
| 130 | #define SIR_UAPSD_BITOFFSET_ACVI 1 |
| 131 | #define SIR_UAPSD_BITOFFSET_ACBK 2 |
| 132 | #define SIR_UAPSD_BITOFFSET_ACBE 3 |
| 133 | |
| 134 | #define SIR_UAPSD_FLAG_ACVO (1 << SIR_UAPSD_BITOFFSET_ACVO) |
| 135 | #define SIR_UAPSD_FLAG_ACVI (1 << SIR_UAPSD_BITOFFSET_ACVI) |
| 136 | #define SIR_UAPSD_FLAG_ACBK (1 << SIR_UAPSD_BITOFFSET_ACBK) |
| 137 | #define SIR_UAPSD_FLAG_ACBE (1 << SIR_UAPSD_BITOFFSET_ACBE) |
| 138 | #define SIR_UAPSD_GET(ac, mask) (((mask) & (SIR_UAPSD_FLAG_ ## ac)) >> SIR_UAPSD_BITOFFSET_ ## ac) |
Varun Reddy Yeturu | d5939f8 | 2015-12-24 18:14:02 -0800 | [diff] [blame] | 139 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 140 | #endif |
| 141 | |
Nachiket Kukade | 63bb63d | 2018-11-21 14:42:14 +0530 | [diff] [blame] | 142 | struct scheduler_msg; |
| 143 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 144 | /** |
Varun Reddy Yeturu | f907f91 | 2016-03-21 15:06:22 -0700 | [diff] [blame] | 145 | * enum sir_roam_op_code - Operation to be done by the callback. |
| 146 | * @SIR_ROAM_SYNCH_PROPAGATION: Propagate the new BSS info after roaming. |
| 147 | * @SIR_ROAMING_DEREGISTER_STA: Deregister the old STA after roaming. |
Naveen Rawat | 8cc23b0 | 2016-07-14 12:22:56 -0700 | [diff] [blame] | 148 | * @SIR_ROAMING_START: Firmware started roaming operation |
| 149 | * @SIR_ROAMING_ABORT: Firmware aborted roaming operation, still connected. |
| 150 | * @SIR_ROAM_SYNCH_COMPLETE: Roam sync propagation is complete. |
Arif Hussain | 43354e6 | 2017-05-24 11:24:25 -0700 | [diff] [blame] | 151 | * @SIR_ROAMING_INVOKE_FAIL: Firmware roaming failed. |
Varun Reddy Yeturu | f907f91 | 2016-03-21 15:06:22 -0700 | [diff] [blame] | 152 | */ |
| 153 | enum sir_roam_op_code { |
| 154 | SIR_ROAM_SYNCH_PROPAGATION = 1, |
| 155 | SIR_ROAMING_DEREGISTER_STA, |
Naveen Rawat | 8cc23b0 | 2016-07-14 12:22:56 -0700 | [diff] [blame] | 156 | SIR_ROAMING_START, |
| 157 | SIR_ROAMING_ABORT, |
| 158 | SIR_ROAM_SYNCH_COMPLETE, |
Varun Reddy Yeturu | 0425186 | 2016-09-16 10:33:19 -0700 | [diff] [blame] | 159 | SIR_ROAM_SYNCH_NAPI_OFF, |
Arif Hussain | 43354e6 | 2017-05-24 11:24:25 -0700 | [diff] [blame] | 160 | SIR_ROAMING_INVOKE_FAIL, |
Varun Reddy Yeturu | f907f91 | 2016-03-21 15:06:22 -0700 | [diff] [blame] | 161 | }; |
| 162 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 163 | * Module ID definitions. |
| 164 | */ |
| 165 | enum { |
| 166 | SIR_BOOT_MODULE_ID = 1, |
| 167 | SIR_HAL_MODULE_ID = 0x10, |
| 168 | SIR_CFG_MODULE_ID = 0x12, |
| 169 | SIR_LIM_MODULE_ID, |
| 170 | SIR_ARQ_MODULE_ID, |
| 171 | SIR_SCH_MODULE_ID, |
| 172 | SIR_PMM_MODULE_ID, |
| 173 | SIR_MNT_MODULE_ID, |
| 174 | SIR_DBG_MODULE_ID, |
| 175 | SIR_DPH_MODULE_ID, |
| 176 | SIR_SYS_MODULE_ID, |
| 177 | SIR_SMS_MODULE_ID, |
| 178 | }; |
| 179 | |
| 180 | #define SIR_WMA_MODULE_ID SIR_HAL_MODULE_ID |
| 181 | |
| 182 | /** |
| 183 | * First and last module definition for logging utility |
| 184 | * |
| 185 | * NOTE: The following definitions need to be updated if |
| 186 | * the above list is changed. |
| 187 | */ |
| 188 | #define SIR_FIRST_MODULE_ID SIR_HAL_MODULE_ID |
| 189 | #define SIR_LAST_MODULE_ID SIR_SMS_MODULE_ID |
| 190 | |
| 191 | /* Type declarations used by Firmware and Host software */ |
| 192 | |
| 193 | /* Scan type enum used in scan request */ |
| 194 | typedef enum eSirScanType { |
| 195 | eSIR_PASSIVE_SCAN, |
| 196 | eSIR_ACTIVE_SCAN, |
| 197 | eSIR_BEACON_TABLE, |
| 198 | } tSirScanType; |
| 199 | |
gaurank kathpalia | c63859d | 2018-05-03 18:48:41 +0530 | [diff] [blame] | 200 | /* Rsn Capabilities structure */ |
| 201 | struct rsn_caps { |
| 202 | uint16_t PreAuthSupported:1; |
| 203 | uint16_t NoPairwise:1; |
| 204 | uint16_t PTKSAReplayCounter:2; |
| 205 | uint16_t GTKSAReplayCounter:2; |
| 206 | uint16_t MFPRequired:1; |
| 207 | uint16_t MFPCapable:1; |
| 208 | uint16_t Reserved:8; |
| 209 | }; |
| 210 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 211 | /* / Result codes Firmware return to Host SW */ |
| 212 | typedef enum eSirResultCodes { |
| 213 | eSIR_SME_SUCCESS, |
Abhishek Singh | 4294f80 | 2017-08-10 16:37:07 +0530 | [diff] [blame] | 214 | eSIR_LOGE_EXCEPTION, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 215 | eSIR_SME_INVALID_PARAMETERS = 500, |
| 216 | eSIR_SME_UNEXPECTED_REQ_RESULT_CODE, |
| 217 | eSIR_SME_RESOURCES_UNAVAILABLE, |
| 218 | /* Unable to find a BssDescription */ |
| 219 | eSIR_SME_SCAN_FAILED, |
| 220 | /* matching requested scan criteria */ |
| 221 | eSIR_SME_BSS_ALREADY_STARTED_OR_JOINED, |
| 222 | eSIR_SME_LOST_LINK_WITH_PEER_RESULT_CODE, |
| 223 | eSIR_SME_REFUSED, |
| 224 | eSIR_SME_JOIN_DEAUTH_FROM_AP_DURING_ADD_STA, |
| 225 | eSIR_SME_JOIN_TIMEOUT_RESULT_CODE, |
| 226 | eSIR_SME_AUTH_TIMEOUT_RESULT_CODE, |
| 227 | eSIR_SME_ASSOC_TIMEOUT_RESULT_CODE, |
| 228 | eSIR_SME_REASSOC_TIMEOUT_RESULT_CODE, |
| 229 | eSIR_SME_MAX_NUM_OF_PRE_AUTH_REACHED, |
| 230 | eSIR_SME_AUTH_REFUSED, |
| 231 | eSIR_SME_INVALID_WEP_DEFAULT_KEY, |
| 232 | eSIR_SME_NO_KEY_MAPPING_KEY_FOR_PEER, |
| 233 | eSIR_SME_ASSOC_REFUSED, |
| 234 | eSIR_SME_REASSOC_REFUSED, |
| 235 | /* Recvd Deauth while join/pre-auth */ |
| 236 | eSIR_SME_DEAUTH_WHILE_JOIN, |
| 237 | eSIR_SME_STA_NOT_AUTHENTICATED, |
| 238 | eSIR_SME_STA_NOT_ASSOCIATED, |
| 239 | eSIR_SME_ALREADY_JOINED_A_BSS, |
| 240 | /* Given in SME_SCAN_RSP msg */ |
| 241 | eSIR_SME_MORE_SCAN_RESULTS_FOLLOW, |
| 242 | /* that more SME_SCAN_RSP */ |
| 243 | /* messages are following. */ |
| 244 | /* SME_SCAN_RSP message with */ |
| 245 | /* eSIR_SME_SUCCESS status */ |
| 246 | /* code is the last one. */ |
| 247 | /* Sent in SME_JOIN/REASSOC_RSP */ |
| 248 | eSIR_SME_INVALID_ASSOC_RSP_RXED, |
| 249 | /* messages upon receiving */ |
| 250 | /* invalid Re/Assoc Rsp frame. */ |
| 251 | /* STOP BSS triggered by MIC failures: MAC software to |
| 252 | * disassoc all stations |
| 253 | */ |
| 254 | eSIR_SME_MIC_COUNTER_MEASURES, |
| 255 | /* with MIC_FAILURE reason code and perform the stop bss operation */ |
| 256 | /* didn't get rsp from peer within timeout interval */ |
| 257 | eSIR_SME_ADDTS_RSP_TIMEOUT, |
| 258 | /* didn't get success rsp from HAL */ |
| 259 | eSIR_SME_ADDTS_RSP_FAILED, |
| 260 | /* failed to send ch switch act frm */ |
| 261 | eSIR_SME_CHANNEL_SWITCH_FAIL, |
| 262 | eSIR_SME_INVALID_STATE, |
| 263 | /* SIR_HAL_SIR_HAL_INIT_SCAN_RSP returned failed status */ |
| 264 | eSIR_SME_HAL_SCAN_INIT_FAILED, |
| 265 | /* SIR_HAL_END_SCAN_RSP returned failed status */ |
| 266 | eSIR_SME_HAL_SCAN_END_FAILED, |
| 267 | /* SIR_HAL_FINISH_SCAN_RSP returned failed status */ |
| 268 | eSIR_SME_HAL_SCAN_FINISH_FAILED, |
| 269 | /* Failed to send a message to HAL */ |
| 270 | eSIR_SME_HAL_SEND_MESSAGE_FAIL, |
| 271 | /* Failed to stop the bss */ |
| 272 | eSIR_SME_STOP_BSS_FAILURE, |
| 273 | eSIR_SME_WOWL_ENTER_REQ_FAILED, |
| 274 | eSIR_SME_WOWL_EXIT_REQ_FAILED, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 275 | eSIR_SME_FT_REASSOC_TIMEOUT_FAILURE, |
| 276 | eSIR_SME_FT_REASSOC_FAILURE, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 277 | eSIR_SME_SEND_ACTION_FAIL, |
| 278 | eSIR_SME_DEAUTH_STATUS, |
| 279 | eSIR_PNO_SCAN_SUCCESS, |
Varun Reddy Yeturu | 371404b | 2017-11-30 15:31:35 -0800 | [diff] [blame] | 280 | eSIR_SME_INVALID_SESSION, |
Varun Reddy Yeturu | a47f08f | 2018-08-07 14:45:31 -0700 | [diff] [blame] | 281 | eSIR_SME_PEER_CREATE_FAILED, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 282 | eSIR_DONOT_USE_RESULT_CODE = SIR_MAX_ENUM_SIZE |
| 283 | } tSirResultCodes; |
| 284 | |
Sridhar Selvaraj | 0d5d2c7 | 2017-08-17 17:30:01 +0530 | [diff] [blame] | 285 | #ifdef WLAN_FEATURE_FILS_SK |
| 286 | struct fils_join_rsp_params { |
| 287 | uint8_t *fils_pmk; |
| 288 | uint8_t fils_pmk_len; |
| 289 | uint8_t fils_pmkid[PMKID_LEN]; |
| 290 | uint8_t kek[MAX_KEK_LEN]; |
| 291 | uint8_t kek_len; |
| 292 | uint8_t tk[MAX_TK_LEN]; |
| 293 | uint8_t tk_len; |
| 294 | uint8_t gtk_len; |
| 295 | uint8_t gtk[MAX_GTK_LEN]; |
Vignesh Viswanathan | a1bb092 | 2017-09-15 12:58:48 +0530 | [diff] [blame] | 296 | struct qdf_mac_addr dst_mac; |
| 297 | struct qdf_mac_addr src_mac; |
| 298 | uint16_t hlp_data_len; |
| 299 | uint8_t hlp_data[FILS_MAX_HLP_DATA_LEN]; |
Sridhar Selvaraj | 0d5d2c7 | 2017-08-17 17:30:01 +0530 | [diff] [blame] | 300 | }; |
| 301 | #endif |
| 302 | |
Krishna Kumaar Natarajan | f599c6e | 2015-11-03 11:44:03 -0800 | [diff] [blame] | 303 | #define RMENABLEDCAP_MAX_LEN 5 |
| 304 | |
| 305 | struct rrm_config_param { |
| 306 | uint8_t rrm_enabled; |
| 307 | uint8_t max_randn_interval; |
| 308 | uint8_t rm_capability[RMENABLEDCAP_MAX_LEN]; |
| 309 | }; |
| 310 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 311 | /* |
| 312 | * although in tSirSupportedRates each IE is 16bit but PE only passes IEs in 8 |
| 313 | * bits with MSB=1 for basic rates. change the mask for bit0-7 only so HAL gets |
| 314 | * correct basic rates for setting response rates. |
| 315 | */ |
| 316 | #define IERATE_BASICRATE_MASK 0x80 |
| 317 | #define IERATE_RATE_MASK 0x7f |
| 318 | #define IERATE_IS_BASICRATE(x) ((x) & IERATE_BASICRATE_MASK) |
| 319 | |
Sreelakshmi Konamki | 39acb13 | 2015-12-16 13:06:22 +0530 | [diff] [blame] | 320 | const char *lim_bss_type_to_string(const uint16_t bss_type); |
Krishna Kumaar Natarajan | d1cd56e | 2016-09-30 08:43:03 -0700 | [diff] [blame] | 321 | /** |
| 322 | * struct sSirSupportedRates - stores rates/MCS supported |
| 323 | * @llbRates: 11b rates in unit of 500kbps |
| 324 | * @llaRates: 11a rates in unit of 500kbps |
| 325 | * @supportedMCSSet: supported basic MCS, 0-76 bits used, remaining reserved |
| 326 | * bits 0-15 and 32 should be set. |
| 327 | * @rxHighestDataRate: RX Highest Supported Data Rate defines the highest data |
| 328 | * rate that the STA is able to receive, in unites of 1Mbps |
| 329 | * This value is derived from "Supported MCS Set field" |
| 330 | * inside the HT capability element. |
| 331 | * @vhtRxMCSMap: Indicates the Maximum MCS(VHT) that can be received for each |
| 332 | * number of spacial streams |
| 333 | * @vhtRxHighestDataRate: Indicate the highest VHT data rate that the STA is |
| 334 | * able to receive |
| 335 | * @vhtTxMCSMap: Indicates the Maximum MCS(VHT) that can be transmitted for |
| 336 | * each number of spacial streams |
| 337 | * @vhtTxHighestDataRate: Indicate the highest VHT data rate that the STA is |
| 338 | * able to transmit |
| 339 | * @he_rx_mcs: Indicates the Maximum MCS(HE) that can be received for each |
| 340 | * number of spacial streams |
| 341 | * @he_tx_mcs: Indicates the Maximum MCS(HE) that can be transmitted for each |
| 342 | * number of spacial streams |
| 343 | */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 344 | typedef struct sSirSupportedRates { |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 345 | uint16_t llbRates[SIR_NUM_11B_RATES]; |
| 346 | uint16_t llaRates[SIR_NUM_11A_RATES]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 347 | uint8_t supportedMCSSet[SIR_MAC_MAX_SUPPORTED_MCS_SET]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 348 | uint16_t rxHighestDataRate; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 349 | uint16_t vhtRxMCSMap; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 350 | uint16_t vhtRxHighestDataRate; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 351 | uint16_t vhtTxMCSMap; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 352 | uint16_t vhtTxHighestDataRate; |
Krishna Kumaar Natarajan | d1cd56e | 2016-09-30 08:43:03 -0700 | [diff] [blame] | 353 | #ifdef WLAN_FEATURE_11AX |
Naveen Rawat | aeca1b9 | 2017-10-16 16:55:31 -0700 | [diff] [blame] | 354 | uint16_t rx_he_mcs_map_lt_80; |
| 355 | uint16_t tx_he_mcs_map_lt_80; |
| 356 | uint16_t rx_he_mcs_map_160; |
| 357 | uint16_t tx_he_mcs_map_160; |
| 358 | uint16_t rx_he_mcs_map_80_80; |
| 359 | uint16_t tx_he_mcs_map_80_80; |
Krishna Kumaar Natarajan | d1cd56e | 2016-09-30 08:43:03 -0700 | [diff] [blame] | 360 | #endif |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 361 | } tSirSupportedRates, *tpSirSupportedRates; |
| 362 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 363 | typedef struct sSirRegisterMgmtFrame { |
| 364 | uint16_t messageType; |
| 365 | uint16_t length; |
| 366 | uint8_t sessionId; |
| 367 | bool registerFrame; |
| 368 | uint16_t frameType; |
| 369 | uint16_t matchLen; |
| 370 | uint8_t matchData[1]; |
| 371 | } tSirRegisterMgmtFrame, *tpSirRegisterMgmtFrame; |
| 372 | |
| 373 | /* / Generic type for sending a response message */ |
| 374 | /* / with result code to host software */ |
| 375 | typedef struct sSirSmeRsp { |
| 376 | uint16_t messageType; /* eWNI_SME_*_RSP */ |
| 377 | uint16_t length; |
| 378 | uint8_t sessionId; /* To support BT-AMP */ |
| 379 | uint16_t transactionId; /* To support BT-AMP */ |
| 380 | tSirResultCodes statusCode; |
Kabilan Kannan | f56f9d5 | 2017-04-05 03:31:34 -0700 | [diff] [blame] | 381 | struct wlan_objmgr_psoc *psoc; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 382 | } tSirSmeRsp, *tpSirSmeRsp; |
| 383 | |
| 384 | /* / Definition for indicating all modules ready on STA */ |
| 385 | typedef struct sSirSmeReadyReq { |
| 386 | uint16_t messageType; /* eWNI_SME_SYS_READY_IND */ |
| 387 | uint16_t length; |
| 388 | uint16_t transactionId; |
Varun Reddy Yeturu | d5939f8 | 2015-12-24 18:14:02 -0800 | [diff] [blame] | 389 | void *csr_roam_synch_cb; |
| 390 | void *pe_roam_synch_cb; |
Vignesh Viswanathan | 3d47803 | 2018-08-02 20:18:53 +0530 | [diff] [blame] | 391 | void *stop_roaming_cb; |
Jeff Johnson | e044f20 | 2018-12-02 10:27:28 -0800 | [diff] [blame] | 392 | QDF_STATUS (*sme_msg_cb)(struct mac_context *mac, |
Jeff Johnson | 5f9ce2d | 2018-06-09 21:20:45 -0700 | [diff] [blame] | 393 | struct scheduler_msg *msg); |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 394 | } tSirSmeReadyReq, *tpSirSmeReadyReq; |
| 395 | |
| 396 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 397 | * struct s_sir_set_hw_mode - Set HW mode request |
| 398 | * @messageType: Message type |
| 399 | * @length: Length of the message |
| 400 | * @set_hw: Params containing the HW mode index and callback |
| 401 | */ |
| 402 | struct s_sir_set_hw_mode { |
| 403 | uint16_t messageType; |
| 404 | uint16_t length; |
Tushnim Bhattacharyya | 0c4ad2d | 2017-03-09 15:59:03 -0800 | [diff] [blame] | 405 | struct policy_mgr_hw_mode set_hw; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 406 | }; |
| 407 | |
| 408 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 409 | * struct sir_set_dual_mac_cfg - Set Dual mac config request |
| 410 | * @message_type: Message type |
| 411 | * @length: Length of the message |
| 412 | * @set_dual_mac: Params containing the dual mac config and callback |
| 413 | */ |
| 414 | struct sir_set_dual_mac_cfg { |
| 415 | uint16_t message_type; |
| 416 | uint16_t length; |
Srinivas Girigowda | eb6ecf3 | 2018-02-15 17:04:22 -0800 | [diff] [blame] | 417 | struct policy_mgr_dual_mac_config set_dual_mac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 418 | }; |
| 419 | |
Archana Ramachandran | d41c3ed | 2016-02-10 15:48:06 -0800 | [diff] [blame] | 420 | /** |
| 421 | * struct sir_antenna_mode_param - antenna mode param |
| 422 | * @num_tx_chains: Number of TX chains |
| 423 | * @num_rx_chains: Number of RX chains |
Archana Ramachandran | d41c3ed | 2016-02-10 15:48:06 -0800 | [diff] [blame] | 424 | * @set_antenna_mode_resp: callback to set antenna mode command |
Dundi Raviteja | 6bb9e32 | 2018-05-16 17:04:41 +0530 | [diff] [blame] | 425 | * @set_antenna_mode_ctx: callback context to set antenna mode command |
Archana Ramachandran | d41c3ed | 2016-02-10 15:48:06 -0800 | [diff] [blame] | 426 | */ |
| 427 | struct sir_antenna_mode_param { |
| 428 | uint32_t num_tx_chains; |
| 429 | uint32_t num_rx_chains; |
| 430 | void *set_antenna_mode_resp; |
Dundi Raviteja | 6bb9e32 | 2018-05-16 17:04:41 +0530 | [diff] [blame] | 431 | void *set_antenna_mode_ctx; |
Archana Ramachandran | d41c3ed | 2016-02-10 15:48:06 -0800 | [diff] [blame] | 432 | }; |
| 433 | |
| 434 | /** |
| 435 | * struct sir_set_antenna_mode - Set antenna mode request |
| 436 | * @message_type: Message type |
| 437 | * @length: Length of the message |
| 438 | * @set_antenna_mode: Params containing antenna mode params |
| 439 | */ |
| 440 | struct sir_set_antenna_mode { |
| 441 | uint16_t message_type; |
| 442 | uint16_t length; |
| 443 | struct sir_antenna_mode_param set_antenna_mode; |
| 444 | }; |
| 445 | |
Deepak Dhamdhere | c9acc44 | 2016-05-26 02:12:58 -0700 | [diff] [blame] | 446 | /** |
| 447 | * enum tSirBssType - Enum for BSS type used in scanning/joining etc. |
| 448 | * |
| 449 | * @eSIR_INFRASTRUCTURE_MODE: Infrastructure station |
| 450 | * @eSIR_INFRA_AP_MODE: softAP mode |
| 451 | * @eSIR_IBSS_MODE: IBSS mode |
| 452 | * @eSIR_AUTO_MODE: Auto role |
| 453 | * @eSIR_MONITOR_MODE: Monitor mode |
| 454 | * @eSIR_NDI_MODE: NAN datapath mode |
| 455 | */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 456 | typedef enum eSirBssType { |
| 457 | eSIR_INFRASTRUCTURE_MODE, |
Deepak Dhamdhere | c9acc44 | 2016-05-26 02:12:58 -0700 | [diff] [blame] | 458 | eSIR_INFRA_AP_MODE, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 459 | eSIR_IBSS_MODE, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 460 | eSIR_AUTO_MODE, |
Manjunathappa Prakash | 59f861d | 2016-04-21 10:33:31 -0700 | [diff] [blame] | 461 | eSIR_MONITOR_MODE, |
Deepak Dhamdhere | c9acc44 | 2016-05-26 02:12:58 -0700 | [diff] [blame] | 462 | eSIR_NDI_MODE, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 463 | eSIR_DONOT_USE_BSS_TYPE = SIR_MAX_ENUM_SIZE |
| 464 | } tSirBssType; |
| 465 | |
| 466 | /* / Power Capability info used in 11H */ |
| 467 | typedef struct sSirMacPowerCapInfo { |
| 468 | uint8_t minTxPower; |
| 469 | uint8_t maxTxPower; |
| 470 | } tSirMacPowerCapInfo, *tpSirMacPowerCapInfo; |
| 471 | |
| 472 | /* / Supported Channel info used in 11H */ |
| 473 | typedef struct sSirSupChnl { |
| 474 | uint8_t numChnl; |
| 475 | uint8_t channelList[SIR_MAX_SUPPORTED_CHANNEL_LIST]; |
| 476 | } tSirSupChnl, *tpSirSupChnl; |
| 477 | |
| 478 | typedef enum eSirNwType { |
| 479 | eSIR_11A_NW_TYPE, |
| 480 | eSIR_11B_NW_TYPE, |
| 481 | eSIR_11G_NW_TYPE, |
| 482 | eSIR_11N_NW_TYPE, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 483 | eSIR_11AC_NW_TYPE, |
Krishna Kumaar Natarajan | 4f1d772 | 2017-03-03 21:12:51 -0800 | [diff] [blame] | 484 | eSIR_11AX_NW_TYPE, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 485 | eSIR_DONOT_USE_NW_TYPE = SIR_MAX_ENUM_SIZE |
| 486 | } tSirNwType; |
| 487 | |
| 488 | /* / Definition for new iBss peer info */ |
| 489 | typedef struct sSirNewIbssPeerInfo { |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 490 | struct qdf_mac_addr peerAddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 491 | uint16_t aid; |
| 492 | } tSirNewIbssPeerInfo, *tpSirNewIbssPeerInfo; |
| 493 | |
| 494 | /* HT configuration values */ |
| 495 | typedef struct sSirHtConfig { |
| 496 | /* Enable/Disable receiving LDPC coded packets */ |
| 497 | uint32_t ht_rx_ldpc:1; |
| 498 | /* Enable/Disable TX STBC */ |
| 499 | uint32_t ht_tx_stbc:1; |
| 500 | /* Enable/Disable RX STBC */ |
| 501 | uint32_t ht_rx_stbc:2; |
| 502 | /* Enable/Disable SGI */ |
Sandeep Puligilla | 607f34a | 2016-05-25 14:37:47 -0700 | [diff] [blame] | 503 | uint32_t ht_sgi20:1; |
| 504 | uint32_t ht_sgi40:1; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 505 | uint32_t unused:27; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 506 | } qdf_packed tSirHTConfig, *tpSirHTConfig; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 507 | |
Sandeep Puligilla | 9891743 | 2016-06-10 13:50:28 -0700 | [diff] [blame] | 508 | /** |
Jeff Johnson | 118a4a0 | 2018-05-06 00:14:15 -0700 | [diff] [blame] | 509 | * struct sir_vht_config - VHT capabilities |
Sandeep Puligilla | 9891743 | 2016-06-10 13:50:28 -0700 | [diff] [blame] | 510 | * @max_mpdu_len: MPDU length |
| 511 | * @supported_channel_widthset: channel width set |
| 512 | * @ldpc_coding: LDPC coding capability |
| 513 | * @shortgi80: short GI 80 support |
| 514 | * @shortgi160and80plus80: short Gi 160 & 80+80 support |
| 515 | * @tx_stbc; Tx STBC cap |
| 516 | * @tx_stbc: Rx STBC cap |
| 517 | * @su_beam_former: SU beam former cap |
| 518 | * @su_beam_formee: SU beam formee cap |
| 519 | * @csnof_beamformer_antSup: Antenna support for beamforming |
| 520 | * @num_soundingdim: Sound dimensions |
| 521 | * @mu_beam_former: MU beam former cap |
| 522 | * @mu_beam_formee: MU beam formee cap |
| 523 | * @vht_txops: TXOP power save |
| 524 | * @htc_vhtcap: HTC VHT capability |
| 525 | * @max_ampdu_lenexp: AMPDU length |
| 526 | * @vht_link_adapt: VHT link adapatation capable |
| 527 | * @rx_antpattern: Rx Antenna pattern |
| 528 | * @tx_antpattern: Tx Antenna pattern |
| 529 | */ |
| 530 | struct sir_vht_config { |
| 531 | uint32_t max_mpdu_len:2; |
| 532 | uint32_t supported_channel_widthset:2; |
| 533 | uint32_t ldpc_coding:1; |
| 534 | uint32_t shortgi80:1; |
| 535 | uint32_t shortgi160and80plus80:1; |
| 536 | uint32_t tx_stbc:1; |
| 537 | uint32_t rx_stbc:3; |
| 538 | uint32_t su_beam_former:1; |
| 539 | uint32_t su_beam_formee:1; |
| 540 | uint32_t csnof_beamformer_antSup:3; |
| 541 | uint32_t num_soundingdim:3; |
| 542 | uint32_t mu_beam_former:1; |
| 543 | uint32_t mu_beam_formee:1; |
| 544 | uint32_t vht_txops:1; |
| 545 | uint32_t htc_vhtcap:1; |
| 546 | uint32_t max_ampdu_lenexp:3; |
| 547 | uint32_t vht_link_adapt:2; |
| 548 | uint32_t rx_antpattern:1; |
| 549 | uint32_t tx_antpattern:1; |
| 550 | uint32_t unused:2; |
| 551 | }; |
| 552 | |
| 553 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 554 | typedef struct sSirAddIeParams { |
| 555 | uint16_t probeRespDataLen; |
| 556 | uint8_t *probeRespData_buff; |
| 557 | uint16_t assocRespDataLen; |
| 558 | uint8_t *assocRespData_buff; |
| 559 | uint16_t probeRespBCNDataLen; |
| 560 | uint8_t *probeRespBCNData_buff; |
| 561 | } tSirAddIeParams, *tpSirAddIeParams; |
| 562 | |
| 563 | /* / Definition for kick starting BSS */ |
| 564 | /* / ---> MAC */ |
| 565 | /** |
| 566 | * Usage of ssId, numSSID & ssIdList: |
| 567 | * --------------------------------- |
| 568 | * 1. ssId.length of zero indicates that Broadcast/Suppress SSID |
| 569 | * feature is enabled. |
| 570 | * 2. If ssId.length is zero, MAC SW will advertise NULL SSID |
| 571 | * and interpret the SSID list from numSSID & ssIdList. |
| 572 | * 3. If ssId.length is non-zero, MAC SW will advertise the SSID |
| 573 | * specified in the ssId field and it is expected that |
| 574 | * application will set numSSID to one (only one SSID present |
| 575 | * in the list) and SSID in the list is same as ssId field. |
| 576 | * 4. Application will always set numSSID >= 1. |
| 577 | */ |
| 578 | /* ***** NOTE: Please make sure all codes are updated if inserting field into |
| 579 | * this structure..********** */ |
| 580 | typedef struct sSirSmeStartBssReq { |
| 581 | uint16_t messageType; /* eWNI_SME_START_BSS_REQ */ |
| 582 | uint16_t length; |
| 583 | uint8_t sessionId; /* Added for BT-AMP Support */ |
| 584 | uint16_t transactionId; /* Added for BT-AMP Support */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 585 | struct qdf_mac_addr bssid; /* Added for BT-AMP Support */ |
| 586 | struct qdf_mac_addr self_macaddr; /* Added for BT-AMP Support */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 587 | uint16_t beaconInterval; /* Added for BT-AMP Support */ |
| 588 | uint8_t dot11mode; |
| 589 | #ifdef FEATURE_WLAN_MCC_TO_SCC_SWITCH |
| 590 | uint8_t cc_switch_mode; |
| 591 | #endif |
| 592 | tSirBssType bssType; |
| 593 | tSirMacSSid ssId; |
| 594 | uint8_t channelId; |
| 595 | ePhyChanBondState cbMode; |
| 596 | uint8_t vht_channel_width; |
| 597 | uint8_t center_freq_seg0; |
| 598 | uint8_t center_freq_seg1; |
| 599 | uint8_t sec_ch_offset; |
| 600 | |
| 601 | uint8_t privacy; |
| 602 | uint8_t apUapsdEnable; |
| 603 | uint8_t ssidHidden; |
| 604 | bool fwdWPSPBCProbeReq; |
| 605 | bool protEnabled; |
| 606 | bool obssProtEnabled; |
| 607 | uint16_t ht_capab; |
| 608 | tAniAuthType authType; |
| 609 | uint32_t dtimPeriod; |
| 610 | uint8_t wps_state; |
| 611 | uint8_t isCoalesingInIBSSAllowed; /* Coalesing on/off knob */ |
Jeff Johnson | c1e6278 | 2017-11-09 09:50:17 -0800 | [diff] [blame] | 612 | enum QDF_OPMODE bssPersona; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 613 | |
| 614 | uint8_t txLdpcIniFeatureEnabled; |
| 615 | |
| 616 | tSirRSNie rsnIE; /* RSN IE to be sent in */ |
| 617 | /* Beacon and Probe */ |
| 618 | /* Response frames */ |
| 619 | tSirNwType nwType; /* Indicates 11a/b/g */ |
| 620 | tSirMacRateSet operationalRateSet; /* Has 11a or 11b rates */ |
| 621 | tSirMacRateSet extendedRateSet; /* Has 11g rates */ |
| 622 | tSirHTConfig htConfig; |
Sandeep Puligilla | 9891743 | 2016-06-10 13:50:28 -0700 | [diff] [blame] | 623 | struct sir_vht_config vht_config; |
Krishna Kumaar Natarajan | 0103ef8 | 2017-02-17 18:15:56 -0800 | [diff] [blame] | 624 | #ifdef WLAN_FEATURE_11AX |
Naveen Rawat | d8feac1 | 2017-09-08 15:08:39 -0700 | [diff] [blame] | 625 | tDot11fIEhe_cap he_config; |
Krishna Kumaar Natarajan | 0103ef8 | 2017-02-17 18:15:56 -0800 | [diff] [blame] | 626 | #endif |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 627 | #ifdef WLAN_FEATURE_11W |
| 628 | bool pmfCapable; |
| 629 | bool pmfRequired; |
| 630 | #endif |
| 631 | |
| 632 | tSirAddIeParams addIeParams; |
| 633 | |
| 634 | bool obssEnabled; |
| 635 | uint8_t sap_dot11mc; |
Jiachao Wu | 712d4fd | 2017-08-23 16:52:34 +0800 | [diff] [blame] | 636 | uint16_t beacon_tx_rate; |
Kapil Gupta | 4b2efbb | 2016-10-03 13:07:20 +0530 | [diff] [blame] | 637 | bool vendor_vht_sap; |
Arif Hussain | 671a190 | 2017-03-17 09:08:32 -0700 | [diff] [blame] | 638 | uint32_t cac_duration_ms; |
| 639 | uint32_t dfs_regdomain; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 640 | |
| 641 | } tSirSmeStartBssReq, *tpSirSmeStartBssReq; |
| 642 | |
| 643 | #define GET_IE_LEN_IN_BSS(lenInBss) (lenInBss + sizeof(lenInBss) - \ |
| 644 | ((uintptr_t)OFFSET_OF(tSirBssDescription,\ |
| 645 | ieFields))) |
| 646 | |
| 647 | #define WSCIE_PROBE_RSP_LEN (317 + 2) |
| 648 | |
Sridhar Selvaraj | a44c19e | 2017-08-21 14:20:20 +0530 | [diff] [blame] | 649 | #ifdef WLAN_FEATURE_FILS_SK |
| 650 | /* struct fils_ind_elements: elements parsed from fils indication present |
| 651 | * in beacon/probe resp |
| 652 | * @realm_cnt: number of realm present |
| 653 | * @realm: realms |
| 654 | * @is_fils_sk_supported: if FILS SK supported |
| 655 | * @is_cache_id_present: if cache id present |
| 656 | * @cache_id: cache id |
| 657 | */ |
| 658 | struct fils_ind_elements { |
| 659 | uint16_t realm_cnt; |
| 660 | uint8_t realm[SIR_MAX_REALM_COUNT][SIR_REALM_LEN]; |
| 661 | bool is_fils_sk_supported; |
| 662 | bool is_cache_id_present; |
| 663 | uint8_t cache_id[CACHE_ID_LEN]; |
| 664 | }; |
| 665 | #endif |
| 666 | |
Jeff Johnson | e58271f | 2017-10-06 09:58:59 -0700 | [diff] [blame] | 667 | struct bss_description { |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 668 | /* offset of the ieFields from bssId. */ |
| 669 | uint16_t length; |
| 670 | tSirMacAddr bssId; |
Arun Khandavalli | 8a711cb | 2017-01-03 20:23:56 +0530 | [diff] [blame] | 671 | unsigned long scansystimensec; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 672 | uint32_t timeStamp[2]; |
| 673 | uint16_t beaconInterval; |
| 674 | uint16_t capabilityInfo; |
| 675 | tSirNwType nwType; /* Indicates 11a/b/g */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 676 | int8_t rssi; |
Deepak Dhamdhere | 68929ec | 2015-08-05 15:16:35 -0700 | [diff] [blame] | 677 | int8_t rssi_raw; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 678 | int8_t sinr; |
| 679 | /* channelId what peer sent in beacon/probersp. */ |
| 680 | uint8_t channelId; |
| 681 | /* channelId on which we are parked at. */ |
| 682 | /* used only in scan case. */ |
| 683 | uint8_t channelIdSelf; |
| 684 | uint8_t sSirBssDescriptionRsvd[3]; |
Deepthi Gowri | 6acee34 | 2016-10-28 15:00:38 +0530 | [diff] [blame] | 685 | /* Based on system time, not a relative time. */ |
| 686 | uint64_t received_time; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 687 | uint32_t parentTSF; |
| 688 | uint32_t startTSF[2]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 689 | uint8_t mdiePresent; |
| 690 | /* MDIE for 11r, picked from the beacons */ |
| 691 | uint8_t mdie[SIR_MDIE_SIZE]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 692 | #ifdef FEATURE_WLAN_ESE |
| 693 | uint16_t QBSSLoad_present; |
| 694 | uint16_t QBSSLoad_avail; |
| 695 | /* To achieve 8-byte alignment with ESE enabled */ |
| 696 | uint32_t reservedPadding5; |
| 697 | #endif |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 698 | /* whether it is from a probe rsp */ |
| 699 | uint8_t fProbeRsp; |
Deepak Dhamdhere | 652d7e8 | 2015-08-06 14:16:53 -0700 | [diff] [blame] | 700 | /* Actual channel the beacon/probe response was received on */ |
| 701 | uint8_t rx_channel; |
Krishna Kumaar Natarajan | 89a99d4 | 2016-08-04 15:44:38 -0700 | [diff] [blame] | 702 | tSirMacSeqCtl seq_ctrl; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 703 | uint32_t WscIeLen; |
| 704 | uint8_t WscIeProbeRsp[WSCIE_PROBE_RSP_LEN]; |
| 705 | uint8_t reservedPadding4; |
| 706 | uint32_t tsf_delta; |
Sridhar Selvaraj | a44c19e | 2017-08-21 14:20:20 +0530 | [diff] [blame] | 707 | #ifdef WLAN_FEATURE_FILS_SK |
| 708 | struct fils_ind_elements fils_info_element; |
| 709 | #endif |
| 710 | /* Please keep the structure 4 bytes aligned above the ieFields */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 711 | uint32_t ieFields[1]; |
Jeff Johnson | e58271f | 2017-10-06 09:58:59 -0700 | [diff] [blame] | 712 | }; |
| 713 | typedef struct bss_description tSirBssDescription, *tpSirBssDescription; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 714 | |
| 715 | #ifdef FEATURE_WLAN_MCC_TO_SCC_SWITCH |
| 716 | typedef struct sSirSmeHTProfile { |
| 717 | uint8_t dot11mode; |
| 718 | uint8_t htCapability; |
| 719 | uint8_t htSupportedChannelWidthSet; |
| 720 | uint8_t htRecommendedTxWidthSet; |
| 721 | ePhyChanBondState htSecondaryChannelOffset; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 722 | uint8_t vhtCapability; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 723 | uint8_t apCenterChan; |
| 724 | uint8_t apChanWidth; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 725 | } tSirSmeHTProfile; |
| 726 | #endif |
| 727 | /* / Definition for response message to previously */ |
| 728 | /* / issued start BSS request */ |
| 729 | /* / MAC ---> */ |
| 730 | typedef struct sSirSmeStartBssRsp { |
| 731 | uint16_t messageType; /* eWNI_SME_START_BSS_RSP */ |
| 732 | uint16_t length; |
| 733 | uint8_t sessionId; |
| 734 | uint16_t transactionId; /* transaction ID for cmd */ |
| 735 | tSirResultCodes statusCode; |
| 736 | tSirBssType bssType; /* Add new type for WDS mode */ |
| 737 | uint16_t beaconInterval; /* Beacon Interval for both type */ |
Jeff Johnson | 179fd8a | 2018-05-11 14:20:05 -0700 | [diff] [blame] | 738 | uint32_t staId; /* Station ID for Self */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 739 | #ifdef FEATURE_WLAN_MCC_TO_SCC_SWITCH |
| 740 | tSirSmeHTProfile HTProfile; |
| 741 | #endif |
| 742 | tSirBssDescription bssDescription; /* Peer BSS description */ |
| 743 | } tSirSmeStartBssRsp, *tpSirSmeStartBssRsp; |
| 744 | |
| 745 | typedef struct sSirChannelList { |
| 746 | uint8_t numChannels; |
| 747 | uint8_t channelNumber[SIR_ESE_MAX_MEAS_IE_REQS]; |
| 748 | } tSirChannelList, *tpSirChannelList; |
| 749 | |
| 750 | typedef struct sSirDFSChannelList { |
| 751 | uint32_t timeStamp[SIR_MAX_24G_5G_CHANNEL_RANGE]; |
| 752 | |
| 753 | } tSirDFSChannelList, *tpSirDFSChannelList; |
| 754 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 755 | /* / Two Background Scan mode */ |
| 756 | typedef enum eSirBackgroundScanMode { |
| 757 | eSIR_ROAMING_SCAN = 2, |
| 758 | } tSirBackgroundScanMode; |
| 759 | |
| 760 | /* / Two types of traffic check */ |
| 761 | typedef enum eSirLinkTrafficCheck { |
| 762 | eSIR_DONT_CHECK_LINK_TRAFFIC_BEFORE_SCAN = 0, |
| 763 | eSIR_CHECK_LINK_TRAFFIC_BEFORE_SCAN = 1, |
| 764 | eSIR_CHECK_ROAMING_SCAN = 2, |
| 765 | } tSirLinkTrafficCheck; |
| 766 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 767 | #ifdef FEATURE_OEM_DATA_SUPPORT |
Krishna Kumaar Natarajan | c1fa17d | 2016-08-03 14:19:20 -0700 | [diff] [blame] | 768 | struct oem_data_req { |
Gupta, Kapil | 8a605e1 | 2016-06-08 14:14:35 +0530 | [diff] [blame] | 769 | uint32_t data_len; |
Krishna Kumaar Natarajan | 9ac8efd | 2015-11-20 13:40:24 -0800 | [diff] [blame] | 770 | uint8_t *data; |
Krishna Kumaar Natarajan | c1fa17d | 2016-08-03 14:19:20 -0700 | [diff] [blame] | 771 | }; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 772 | |
Krishna Kumaar Natarajan | c1fa17d | 2016-08-03 14:19:20 -0700 | [diff] [blame] | 773 | struct oem_data_rsp { |
Krishna Kumaar Natarajan | 608291e | 2015-12-14 18:17:27 -0800 | [diff] [blame] | 774 | uint32_t rsp_len; |
Krishna Kumaar Natarajan | 73ea9f2 | 2016-06-30 18:38:47 -0700 | [diff] [blame] | 775 | uint8_t *data; |
Krishna Kumaar Natarajan | c1fa17d | 2016-08-03 14:19:20 -0700 | [diff] [blame] | 776 | }; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 777 | #endif /* FEATURE_OEM_DATA_SUPPORT */ |
| 778 | |
Srinivas Girigowda | 515a9ef | 2015-12-11 11:00:48 -0800 | [diff] [blame] | 779 | #ifdef FEATURE_WLAN_ESE |
yeshwanth sriram guntuka | 27e4ffc | 2016-12-01 18:00:17 +0530 | [diff] [blame] | 780 | typedef struct ese_wmm_tspec_ie { |
| 781 | uint16_t traffic_type:1; |
| 782 | uint16_t tsid:4; |
| 783 | uint16_t direction:2; |
| 784 | uint16_t access_policy:2; |
| 785 | uint16_t aggregation:1; |
| 786 | uint16_t psb:1; |
| 787 | uint16_t user_priority:3; |
| 788 | uint16_t tsinfo_ack_pol:2; |
| 789 | uint8_t tsinfo_rsvd:7; |
| 790 | uint8_t burst_size_defn:1; |
| 791 | uint16_t size:15; |
| 792 | uint16_t fixed:1; |
| 793 | uint16_t max_msdu_size; |
| 794 | uint32_t min_service_int; |
| 795 | uint32_t max_service_int; |
| 796 | uint32_t inactivity_int; |
| 797 | uint32_t suspension_int; |
| 798 | uint32_t service_start_time; |
| 799 | uint32_t min_data_rate; |
| 800 | uint32_t mean_data_rate; |
| 801 | uint32_t peak_data_rate; |
| 802 | uint32_t burst_size; |
| 803 | uint32_t delay_bound; |
| 804 | uint32_t min_phy_rate; |
| 805 | uint16_t surplus_bw_allowance; |
| 806 | uint16_t medium_time; |
| 807 | } qdf_packed ese_wmm_tspec_ie; |
| 808 | |
Srinivas Girigowda | 515a9ef | 2015-12-11 11:00:48 -0800 | [diff] [blame] | 809 | typedef struct sTspecInfo { |
| 810 | uint8_t valid; |
Jeff Johnson | 56471b9 | 2018-12-22 14:36:06 -0800 | [diff] [blame] | 811 | struct mac_tspec_ie tspec; |
Srinivas Girigowda | 515a9ef | 2015-12-11 11:00:48 -0800 | [diff] [blame] | 812 | } tTspecInfo; |
| 813 | |
| 814 | #define SIR_ESE_MAX_TSPEC_IES 4 |
| 815 | typedef struct sESETspecTspecInfo { |
| 816 | uint8_t numTspecs; |
| 817 | tTspecInfo tspec[SIR_ESE_MAX_TSPEC_IES]; |
| 818 | } tESETspecInfo; |
| 819 | |
| 820 | typedef struct sSirTsmIE { |
| 821 | uint8_t tsid; |
| 822 | uint8_t state; |
| 823 | uint16_t msmt_interval; |
| 824 | } tSirTsmIE, *tpSirTsmIE; |
| 825 | typedef struct sSirSmeTsmIEInd { |
| 826 | tSirTsmIE tsmIe; |
| 827 | uint8_t sessionId; |
| 828 | } tSirSmeTsmIEInd, *tpSirSmeTsmIEInd; |
| 829 | typedef struct sAniTrafStrmMetrics { |
| 830 | uint16_t UplinkPktQueueDly; |
| 831 | uint16_t UplinkPktQueueDlyHist[4]; |
| 832 | uint32_t UplinkPktTxDly; |
| 833 | uint16_t UplinkPktLoss; |
| 834 | uint16_t UplinkPktCount; |
| 835 | uint8_t RoamingCount; |
| 836 | uint16_t RoamingDly; |
| 837 | } tAniTrafStrmMetrics, *tpAniTrafStrmMetrics; |
| 838 | |
| 839 | typedef struct sAniGetTsmStatsReq { |
| 840 | /* Common for all types are requests */ |
| 841 | uint16_t msgType; /* message type is same as the request type */ |
| 842 | uint16_t msgLen; /* length of the entire request */ |
| 843 | uint8_t staId; |
| 844 | uint8_t tid; /* traffic id */ |
| 845 | struct qdf_mac_addr bssId; |
| 846 | void *tsmStatsCallback; |
| 847 | void *pDevContext; /* device context */ |
Srinivas Girigowda | 515a9ef | 2015-12-11 11:00:48 -0800 | [diff] [blame] | 848 | } tAniGetTsmStatsReq, *tpAniGetTsmStatsReq; |
| 849 | |
| 850 | typedef struct sAniGetTsmStatsRsp { |
| 851 | /* Common for all types are responses */ |
| 852 | uint16_t msgType; /* |
| 853 | * message type is same as |
| 854 | * the request type |
| 855 | */ |
| 856 | uint16_t msgLen; /* |
| 857 | * length of the entire request, |
| 858 | * includes the pStatsBuf length too |
| 859 | */ |
| 860 | uint8_t sessionId; |
| 861 | uint32_t rc; /* success/failure */ |
| 862 | uint32_t staId; /* |
| 863 | * Per STA stats request must |
| 864 | * contain valid |
| 865 | */ |
| 866 | tAniTrafStrmMetrics tsmMetrics; |
| 867 | void *tsmStatsReq; /* tsm stats request backup */ |
| 868 | } tAniGetTsmStatsRsp, *tpAniGetTsmStatsRsp; |
| 869 | |
| 870 | typedef struct sSirEseBcnReportBssInfo { |
| 871 | tBcnReportFields bcnReportFields; |
| 872 | uint8_t ieLen; |
| 873 | uint8_t *pBuf; |
| 874 | } tSirEseBcnReportBssInfo, *tpSirEseBcnReportBssInfo; |
| 875 | |
| 876 | typedef struct sSirEseBcnReportRsp { |
| 877 | uint16_t measurementToken; |
| 878 | uint8_t flag; /* Flag to report measurement done and more data */ |
| 879 | uint8_t numBss; |
| 880 | tSirEseBcnReportBssInfo bcnRepBssInfo[SIR_BCN_REPORT_MAX_BSS_DESC]; |
| 881 | } tSirEseBcnReportRsp, *tpSirEseBcnReportRsp; |
| 882 | |
| 883 | #define TSRS_11AG_RATE_6MBPS 0xC |
| 884 | #define TSRS_11B_RATE_5_5MBPS 0xB |
| 885 | typedef struct sSirMacESETSRSIE { |
| 886 | uint8_t tsid; |
| 887 | uint8_t rates[8]; |
| 888 | } tSirMacESETSRSIE; |
| 889 | typedef struct sSirMacESETSMIE { |
| 890 | uint8_t tsid; |
| 891 | uint8_t state; |
| 892 | uint16_t msmt_interval; |
| 893 | } tSirMacESETSMIE; |
| 894 | typedef struct sTSMStats { |
| 895 | uint8_t tid; |
| 896 | struct qdf_mac_addr bssid; |
| 897 | tTrafStrmMetrics tsmMetrics; |
| 898 | } tTSMStats, *tpTSMStats; |
| 899 | typedef struct sEseTSMContext { |
| 900 | uint8_t tid; |
| 901 | tSirMacESETSMIE tsmInfo; |
| 902 | tTrafStrmMetrics tsmMetrics; |
| 903 | } tEseTSMContext, *tpEseTSMContext; |
| 904 | typedef struct sEsePEContext { |
| 905 | tEseTSMContext tsm; |
| 906 | } tEsePEContext, *tpEsePEContext; |
| 907 | |
| 908 | typedef struct sSirPlmReq { |
| 909 | uint16_t diag_token; /* Dialog token */ |
| 910 | uint16_t meas_token; /* measurement token */ |
| 911 | uint16_t numBursts; /* total number of bursts */ |
| 912 | uint16_t burstInt; /* burst interval in seconds */ |
| 913 | uint16_t measDuration; /* in TU's,STA goes off-ch */ |
| 914 | /* no of times the STA should cycle through PLM ch list */ |
| 915 | uint8_t burstLen; |
| 916 | int8_t desiredTxPwr; /* desired tx power */ |
| 917 | struct qdf_mac_addr mac_addr; /* MC dest addr */ |
| 918 | /* no of channels */ |
| 919 | uint8_t plmNumCh; |
| 920 | /* channel numbers */ |
| 921 | uint8_t plmChList[WNI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 922 | uint8_t sessionId; |
| 923 | bool enable; |
| 924 | } tSirPlmReq, *tpSirPlmReq; |
| 925 | |
| 926 | #endif /* FEATURE_WLAN_ESE */ |
| 927 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 928 | /* / Definition for join request */ |
| 929 | /* / ---> MAC */ |
| 930 | /* / WARNING! If you add a field in JOIN REQ. */ |
| 931 | /* / Make sure to add it in REASSOC REQ */ |
| 932 | /* / The Serdes function is the same and its */ |
| 933 | /* / shared with REASSOC. So if we add a field */ |
| 934 | /* here and dont add it in REASSOC REQ. It will BREAK!!! REASSOC. */ |
| 935 | typedef struct sSirSmeJoinReq { |
| 936 | uint16_t messageType; /* eWNI_SME_JOIN_REQ */ |
| 937 | uint16_t length; |
| 938 | uint8_t sessionId; |
| 939 | uint16_t transactionId; |
| 940 | tSirMacSSid ssId; |
| 941 | tSirMacAddr selfMacAddr; /* self Mac address */ |
| 942 | tSirBssType bsstype; /* add new type for BT-AMP STA and AP Modules */ |
| 943 | uint8_t dot11mode; /* to support BT-AMP */ |
| 944 | #ifdef FEATURE_WLAN_MCC_TO_SCC_SWITCH |
| 945 | uint8_t cc_switch_mode; |
| 946 | #endif |
Jeff Johnson | c1e6278 | 2017-11-09 09:50:17 -0800 | [diff] [blame] | 947 | enum QDF_OPMODE staPersona; /* Persona */ |
Abhishek Singh | f78bd2d | 2016-04-27 16:47:56 +0530 | [diff] [blame] | 948 | bool wps_registration; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 949 | ePhyChanBondState cbMode; /* Pass CB mode value in Join. */ |
| 950 | |
| 951 | /*This contains the UAPSD Flag for all 4 AC |
| 952 | * B0: AC_VO UAPSD FLAG |
| 953 | * B1: AC_VI UAPSD FLAG |
| 954 | * B2: AC_BK UAPSD FLAG |
| 955 | * B3: AC_BE UASPD FLAG |
| 956 | */ |
| 957 | uint8_t uapsdPerAcBitmask; |
| 958 | |
| 959 | tSirMacRateSet operationalRateSet; /* Has 11a or 11b rates */ |
| 960 | tSirMacRateSet extendedRateSet; /* Has 11g rates */ |
| 961 | tSirRSNie rsnIE; /* RSN IE to be sent in */ |
| 962 | /* (Re) Association Request */ |
| 963 | #ifdef FEATURE_WLAN_ESE |
| 964 | /* CCMK IE to be included as handler for join and reassoc is */ |
| 965 | tSirCCKMie cckmIE; |
| 966 | /* the same. The join will never carry cckm, but will be set to */ |
| 967 | /* 0. */ |
| 968 | #endif |
| 969 | |
| 970 | tSirAddie addIEScan; /* Additional IE to be sent in */ |
| 971 | /* (unicast) Probe Request at the time of join */ |
| 972 | |
| 973 | tSirAddie addIEAssoc; /* Additional IE to be sent in */ |
| 974 | /* (Re) Association Request */ |
| 975 | |
| 976 | tAniEdType UCEncryptionType; |
| 977 | |
| 978 | tAniEdType MCEncryptionType; |
| 979 | |
| 980 | #ifdef WLAN_FEATURE_11W |
| 981 | tAniEdType MgmtEncryptionType; |
| 982 | #endif |
| 983 | |
Srinivas Girigowda | 74a66d6 | 2017-06-21 23:28:25 -0700 | [diff] [blame] | 984 | bool is11Rconnection; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 985 | #ifdef FEATURE_WLAN_ESE |
Srinivas Girigowda | 74a66d6 | 2017-06-21 23:28:25 -0700 | [diff] [blame] | 986 | bool isESEFeatureIniEnabled; |
| 987 | bool isESEconnection; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 988 | tESETspecInfo eseTspecInfo; |
| 989 | #endif |
| 990 | |
Srinivas Girigowda | 74a66d6 | 2017-06-21 23:28:25 -0700 | [diff] [blame] | 991 | bool isFastTransitionEnabled; |
| 992 | bool isFastRoamIniFeatureEnabled; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 993 | |
| 994 | uint8_t txLdpcIniFeatureEnabled; |
| 995 | tSirHTConfig htConfig; |
Sandeep Puligilla | 9891743 | 2016-06-10 13:50:28 -0700 | [diff] [blame] | 996 | struct sir_vht_config vht_config; |
Krishna Kumaar Natarajan | 0103ef8 | 2017-02-17 18:15:56 -0800 | [diff] [blame] | 997 | #ifdef WLAN_FEATURE_11AX |
Naveen Rawat | d8feac1 | 2017-09-08 15:08:39 -0700 | [diff] [blame] | 998 | tDot11fIEhe_cap he_config; |
Krishna Kumaar Natarajan | 0103ef8 | 2017-02-17 18:15:56 -0800 | [diff] [blame] | 999 | #endif |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1000 | uint8_t enableVhtpAid; |
| 1001 | uint8_t enableVhtGid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1002 | uint8_t enableAmpduPs; |
| 1003 | uint8_t enableHtSmps; |
| 1004 | uint8_t htSmps; |
Archana Ramachandran | fec2481 | 2016-02-16 16:31:56 -0800 | [diff] [blame] | 1005 | bool send_smps_action; |
Kiran Kumar Lokere | 722dccd | 2018-02-23 13:23:52 -0800 | [diff] [blame] | 1006 | bool he_with_wep_tkip; |
Deepak Dhamdhere | 612392c | 2016-08-28 02:56:51 -0700 | [diff] [blame] | 1007 | uint8_t max_amsdu_num; |
Srinivas Girigowda | 74a66d6 | 2017-06-21 23:28:25 -0700 | [diff] [blame] | 1008 | bool isWMEenabled; |
| 1009 | bool isQosEnabled; |
| 1010 | bool isOSENConnection; |
Krishna Kumaar Natarajan | f599c6e | 2015-11-03 11:44:03 -0800 | [diff] [blame] | 1011 | struct rrm_config_param rrm_config; |
Srinivas Girigowda | 74a66d6 | 2017-06-21 23:28:25 -0700 | [diff] [blame] | 1012 | bool spectrumMgtIndicator; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1013 | tSirMacPowerCapInfo powerCap; |
| 1014 | tSirSupChnl supportedChannels; |
Selvaraj, Sridhar | 05ea079 | 2017-05-17 12:17:03 +0530 | [diff] [blame] | 1015 | bool enable_bcast_probe_rsp; |
Sridhar Selvaraj | 8c6f5e8 | 2017-08-21 14:53:46 +0530 | [diff] [blame] | 1016 | #ifdef WLAN_FEATURE_FILS_SK |
| 1017 | struct cds_fils_connection_info fils_con_info; |
| 1018 | #endif |
Padma, Santhosh Kumar | b8f65d9 | 2017-09-14 13:05:42 +0530 | [diff] [blame] | 1019 | bool sae_pmk_cached; |
Sridhar Selvaraj | 8c6f5e8 | 2017-08-21 14:53:46 +0530 | [diff] [blame] | 1020 | /* Pls make this as last variable in struct */ |
Abhishek Singh | b59f8d4 | 2017-07-31 14:42:47 +0530 | [diff] [blame] | 1021 | bool force_24ghz_in_ht20; |
Abhishek Singh | 6454ad3 | 2017-12-20 10:42:21 +0530 | [diff] [blame] | 1022 | bool force_rsne_override; |
Vignesh Viswanathan | d5a5f2e | 2018-06-01 15:35:51 +0530 | [diff] [blame] | 1023 | bool supported_nss_1x1; |
| 1024 | uint8_t vdev_nss; |
| 1025 | uint8_t nss; |
| 1026 | bool nss_forced_1x1; |
Arif Hussain | 6686c0b | 2018-08-21 18:21:05 -0700 | [diff] [blame] | 1027 | bool enable_session_twt_support; |
Selvaraj, Sridhar | 81ab80d | 2017-06-08 12:21:39 +0530 | [diff] [blame] | 1028 | tSirBssDescription bssDescription; |
| 1029 | /* |
| 1030 | * WARNING: Pls make bssDescription as last variable in struct |
| 1031 | * tSirSmeJoinReq as it has ieFields followed after this bss |
| 1032 | * description. Adding a variable after this corrupts the ieFields |
| 1033 | */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1034 | } tSirSmeJoinReq, *tpSirSmeJoinReq; |
| 1035 | |
Jeff Johnson | 47d7524 | 2018-05-12 15:58:53 -0700 | [diff] [blame] | 1036 | /* / Definition for response message to previously issued join request */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1037 | /* / MAC ---> */ |
| 1038 | typedef struct sSirSmeJoinRsp { |
| 1039 | uint16_t messageType; /* eWNI_SME_JOIN_RSP */ |
| 1040 | uint16_t length; |
| 1041 | uint8_t sessionId; /* Session ID */ |
| 1042 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 1043 | tSirResultCodes statusCode; |
| 1044 | tAniAuthType authType; |
| 1045 | uint32_t vht_channel_width; |
| 1046 | /* It holds reasonCode when join fails due to deauth/disassoc frame. |
| 1047 | * Otherwise it holds status code. |
| 1048 | */ |
| 1049 | uint16_t protStatusCode; |
| 1050 | uint16_t aid; |
| 1051 | uint32_t beaconLength; |
| 1052 | uint32_t assocReqLength; |
| 1053 | uint32_t assocRspLength; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1054 | uint32_t parsedRicRspLen; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1055 | #ifdef FEATURE_WLAN_ESE |
| 1056 | uint32_t tspecIeLen; |
| 1057 | #endif |
| 1058 | uint32_t staId; /* Station ID for peer */ |
| 1059 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1060 | /*Timing measurement capability */ |
| 1061 | uint8_t timingMeasCap; |
| 1062 | |
| 1063 | #ifdef FEATURE_WLAN_TDLS |
| 1064 | /* TDLS prohibited and TDLS channel switch prohibited are set as |
| 1065 | * per ExtCap IE in received assoc/re-assoc response from AP |
| 1066 | */ |
| 1067 | bool tdls_prohibited; |
| 1068 | bool tdls_chan_swit_prohibited; |
| 1069 | #endif |
Kanchanapally, Vidyullatha | e306281 | 2015-05-22 17:28:57 +0530 | [diff] [blame] | 1070 | uint8_t nss; |
| 1071 | uint32_t max_rate_flags; |
| 1072 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1073 | #ifdef FEATURE_WLAN_MCC_TO_SCC_SWITCH |
| 1074 | tSirSmeHTProfile HTProfile; |
| 1075 | #endif |
Archana Ramachandran | 20d2e23 | 2016-02-11 16:58:40 -0800 | [diff] [blame] | 1076 | bool supported_nss_1x1; |
Anurag Chouhan | 5de8d17 | 2016-07-13 14:44:28 +0530 | [diff] [blame] | 1077 | tDot11fIEHTCaps ht_caps; |
| 1078 | tDot11fIEVHTCaps vht_caps; |
| 1079 | tDot11fIEHTInfo ht_operation; |
| 1080 | tDot11fIEVHTOperation vht_operation; |
| 1081 | tDot11fIEhs20vendor_ie hs20vendor_ie; |
Sridhar Selvaraj | 0d5d2c7 | 2017-08-17 17:30:01 +0530 | [diff] [blame] | 1082 | bool is_fils_connection; |
Sridhar Selvaraj | 0d5d2c7 | 2017-08-17 17:30:01 +0530 | [diff] [blame] | 1083 | uint16_t fils_seq_num; |
Vignesh Viswanathan | 0b0fa27 | 2017-09-18 17:12:04 +0530 | [diff] [blame] | 1084 | #ifdef WLAN_FEATURE_FILS_SK |
Sridhar Selvaraj | 0d5d2c7 | 2017-08-17 17:30:01 +0530 | [diff] [blame] | 1085 | struct fils_join_rsp_params *fils_join_rsp; |
| 1086 | #endif |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1087 | uint8_t frames[1]; |
| 1088 | } tSirSmeJoinRsp, *tpSirSmeJoinRsp; |
| 1089 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1090 | typedef struct sSirSmeChanInfo { |
| 1091 | uint8_t chan_id; |
| 1092 | uint32_t mhz; |
| 1093 | uint32_t band_center_freq1; |
| 1094 | uint32_t band_center_freq2; |
| 1095 | uint32_t info; |
| 1096 | uint32_t reg_info_1; |
| 1097 | uint32_t reg_info_2; |
Kanchanapally, Vidyullatha | e306281 | 2015-05-22 17:28:57 +0530 | [diff] [blame] | 1098 | uint8_t nss; |
| 1099 | uint32_t rate_flags; |
Manishekar Chandrasekaran | ec26759 | 2016-05-26 19:10:04 +0530 | [diff] [blame] | 1100 | uint8_t sec_ch_offset; |
| 1101 | enum phy_ch_width ch_width; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1102 | } tSirSmeChanInfo, *tpSirSmeChanInfo; |
Kanchanapally, Vidyullatha | e306281 | 2015-05-22 17:28:57 +0530 | [diff] [blame] | 1103 | |
Will Huang | 558f808 | 2017-05-31 16:22:24 +0800 | [diff] [blame] | 1104 | enum sir_sme_phy_mode { |
| 1105 | SIR_SME_PHY_MODE_LEGACY = 0, |
| 1106 | SIR_SME_PHY_MODE_HT = 1, |
| 1107 | SIR_SME_PHY_MODE_VHT = 2 |
| 1108 | }; |
| 1109 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1110 | /* / Definition for Association indication from peer */ |
| 1111 | /* / MAC ---> */ |
| 1112 | typedef struct sSirSmeAssocInd { |
| 1113 | uint16_t messageType; /* eWNI_SME_ASSOC_IND */ |
| 1114 | uint16_t length; |
| 1115 | uint8_t sessionId; |
| 1116 | tSirMacAddr peerMacAddr; |
| 1117 | uint16_t aid; |
| 1118 | tSirMacAddr bssId; /* Self BSSID */ |
| 1119 | uint16_t staId; /* Station ID for peer */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1120 | tAniAuthType authType; |
| 1121 | tAniSSID ssId; /* SSID used by STA to associate */ |
| 1122 | tSirWAPIie wapiIE; /* WAPI IE received from peer */ |
| 1123 | tSirRSNie rsnIE; /* RSN IE received from peer */ |
| 1124 | /* Additional IE received from peer, which possibly include |
| 1125 | * WSC IE and/or P2P IE |
| 1126 | */ |
| 1127 | tSirAddie addIE; |
| 1128 | |
| 1129 | /* powerCap & supportedChannels are present only when */ |
| 1130 | /* spectrumMgtIndicator flag is set */ |
Srinivas Girigowda | 74a66d6 | 2017-06-21 23:28:25 -0700 | [diff] [blame] | 1131 | bool spectrumMgtIndicator; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1132 | tSirMacPowerCapInfo powerCap; |
| 1133 | tSirSupChnl supportedChannels; |
Srinivas Girigowda | 74a66d6 | 2017-06-21 23:28:25 -0700 | [diff] [blame] | 1134 | bool wmmEnabledSta; /* if present - STA is WMM enabled */ |
| 1135 | bool reassocReq; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1136 | /* Required for indicating the frames to upper layer */ |
| 1137 | uint32_t beaconLength; |
| 1138 | uint8_t *beaconPtr; |
| 1139 | uint32_t assocReqLength; |
| 1140 | uint8_t *assocReqPtr; |
| 1141 | |
| 1142 | /* Timing measurement capability */ |
| 1143 | uint8_t timingMeasCap; |
| 1144 | tSirSmeChanInfo chan_info; |
Will Huang | 558f808 | 2017-05-31 16:22:24 +0800 | [diff] [blame] | 1145 | bool ampdu; |
| 1146 | bool sgi_enable; |
| 1147 | bool tx_stbc; |
| 1148 | bool rx_stbc; |
| 1149 | tSirMacHTChannelWidth ch_width; |
| 1150 | enum sir_sme_phy_mode mode; |
| 1151 | uint8_t max_supp_idx; |
| 1152 | uint8_t max_ext_idx; |
| 1153 | uint8_t max_mcs_idx; |
| 1154 | uint8_t rx_mcs_map; |
| 1155 | uint8_t tx_mcs_map; |
gaolez | 7bb1e74 | 2017-03-21 16:37:38 +0800 | [diff] [blame] | 1156 | /* Extended CSA capability of station */ |
| 1157 | uint8_t ecsa_capable; |
Ashish Kumar Dhanotiya | 443d31f | 2017-10-13 12:41:19 +0530 | [diff] [blame] | 1158 | tDot11fIEHTCaps HTCaps; |
| 1159 | tDot11fIEVHTCaps VHTCaps; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1160 | } tSirSmeAssocInd, *tpSirSmeAssocInd; |
| 1161 | |
| 1162 | /* / Definition for Association confirm */ |
| 1163 | /* / ---> MAC */ |
| 1164 | typedef struct sSirSmeAssocCnf { |
| 1165 | uint16_t messageType; /* eWNI_SME_ASSOC_CNF */ |
| 1166 | uint16_t length; |
| 1167 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1168 | struct qdf_mac_addr bssid; /* Self BSSID */ |
| 1169 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1170 | uint16_t aid; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1171 | struct qdf_mac_addr alternate_bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1172 | uint8_t alternateChannelId; |
| 1173 | } tSirSmeAssocCnf, *tpSirSmeAssocCnf; |
| 1174 | |
| 1175 | /* / Enum definition for Wireless medium status change codes */ |
| 1176 | typedef enum eSirSmeStatusChangeCode { |
| 1177 | eSIR_SME_DEAUTH_FROM_PEER, |
| 1178 | eSIR_SME_DISASSOC_FROM_PEER, |
| 1179 | eSIR_SME_LOST_LINK_WITH_PEER, |
| 1180 | eSIR_SME_CHANNEL_SWITCH, |
| 1181 | eSIR_SME_JOINED_NEW_BSS, |
| 1182 | eSIR_SME_LEAVING_BSS, |
| 1183 | eSIR_SME_IBSS_ACTIVE, |
| 1184 | eSIR_SME_IBSS_INACTIVE, |
| 1185 | eSIR_SME_IBSS_PEER_DEPARTED, |
| 1186 | eSIR_SME_RADAR_DETECTED, |
| 1187 | eSIR_SME_IBSS_NEW_PEER, |
| 1188 | eSIR_SME_AP_CAPS_CHANGED, |
| 1189 | } tSirSmeStatusChangeCode; |
| 1190 | |
| 1191 | typedef struct sSirSmeNewBssInfo { |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1192 | struct qdf_mac_addr bssId; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1193 | uint8_t channelNumber; |
| 1194 | uint8_t reserved; |
| 1195 | tSirMacSSid ssId; |
| 1196 | } tSirSmeNewBssInfo, *tpSirSmeNewBssInfo; |
| 1197 | |
| 1198 | typedef struct sSirSmeApNewCaps { |
| 1199 | uint16_t capabilityInfo; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1200 | struct qdf_mac_addr bssId; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1201 | uint8_t channelId; |
| 1202 | uint8_t reserved[3]; |
| 1203 | tSirMacSSid ssId; |
| 1204 | } tSirSmeApNewCaps, *tpSirSmeApNewCaps; |
| 1205 | |
| 1206 | /** |
| 1207 | * Table below indicates what information is passed for each of |
| 1208 | * the Wireless Media status change notifications: |
| 1209 | * |
| 1210 | * Status Change code Status change info |
| 1211 | * ---------------------------------------------------------------------- |
| 1212 | * eSIR_SME_DEAUTH_FROM_PEER Reason code received in DEAUTH frame |
| 1213 | * eSIR_SME_DISASSOC_FROM_PEER Reason code received in DISASSOC frame |
| 1214 | * eSIR_SME_LOST_LINK_WITH_PEER None |
| 1215 | * eSIR_SME_CHANNEL_SWITCH New channel number |
| 1216 | * eSIR_SME_JOINED_NEW_BSS BSSID, SSID and channel number |
| 1217 | * eSIR_SME_LEAVING_BSS None |
| 1218 | * eSIR_SME_IBSS_ACTIVE Indicates that another STA joined |
| 1219 | * IBSS apart from this STA that |
| 1220 | * started IBSS |
| 1221 | * eSIR_SME_IBSS_INACTIVE Indicates that only this STA is left |
| 1222 | * in IBSS |
| 1223 | * eSIR_SME_RADAR_DETECTED Indicates that radar is detected |
| 1224 | * eSIR_SME_IBSS_NEW_PEER Indicates that a new peer is detected |
| 1225 | * eSIR_SME_AP_CAPS_CHANGED Indicates that capabilities of the AP |
| 1226 | * that STA is currently associated with |
| 1227 | * have changed. |
| 1228 | */ |
| 1229 | |
| 1230 | /* / Definition for Wireless medium status change notification */ |
| 1231 | typedef struct sSirSmeWmStatusChangeNtf { |
| 1232 | uint16_t messageType; /* eWNI_SME_WM_STATUS_CHANGE_NTF */ |
| 1233 | uint16_t length; |
| 1234 | uint8_t sessionId; /* Session ID */ |
| 1235 | tSirSmeStatusChangeCode statusChangeCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1236 | struct qdf_mac_addr bssid; /* Self BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1237 | union { |
| 1238 | uint16_t deAuthReasonCode; /* eSIR_SME_DEAUTH_FROM_PEER */ |
| 1239 | /* eSIR_SME_DISASSOC_FROM_PEER */ |
| 1240 | uint16_t disassocReasonCode; |
| 1241 | /* none for eSIR_SME_LOST_LINK_WITH_PEER */ |
| 1242 | uint8_t newChannelId; /* eSIR_SME_CHANNEL_SWITCH */ |
| 1243 | tSirSmeNewBssInfo newBssInfo; /* eSIR_SME_JOINED_NEW_BSS */ |
| 1244 | /* none for eSIR_SME_LEAVING_BSS */ |
| 1245 | /* none for eSIR_SME_IBSS_ACTIVE */ |
| 1246 | /* none for eSIR_SME_IBSS_INACTIVE */ |
| 1247 | /* eSIR_SME_IBSS_NEW_PEER */ |
| 1248 | tSirNewIbssPeerInfo newIbssPeerInfo; |
| 1249 | tSirSmeApNewCaps apNewCaps; /* eSIR_SME_AP_CAPS_CHANGED */ |
| 1250 | } statusChangeInfo; |
| 1251 | } tSirSmeWmStatusChangeNtf, *tpSirSmeWmStatusChangeNtf; |
| 1252 | |
| 1253 | /* Definition for Disassociation request */ |
| 1254 | typedef struct sSirSmeDisassocReq { |
| 1255 | uint16_t messageType; /* eWNI_SME_DISASSOC_REQ */ |
| 1256 | uint16_t length; |
| 1257 | uint8_t sessionId; /* Session ID */ |
| 1258 | uint16_t transactionId; /* Transaction ID for cmd */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1259 | struct qdf_mac_addr bssid; /* Peer BSSID */ |
| 1260 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1261 | uint16_t reasonCode; |
| 1262 | /* This flag tells LIM whether to send the disassoc OTA or not */ |
| 1263 | /* This will be set in while handing off from one AP to other */ |
| 1264 | uint8_t doNotSendOverTheAir; |
Deepak Dhamdhere | 2dae1bd | 2016-10-27 10:58:29 -0700 | [diff] [blame] | 1265 | bool process_ho_fail; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1266 | } qdf_packed tSirSmeDisassocReq, *tpSirSmeDisassocReq; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1267 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1268 | /* / Definition for Disassociation response */ |
| 1269 | typedef struct sSirSmeDisassocRsp { |
| 1270 | uint16_t messageType; /* eWNI_SME_DISASSOC_RSP */ |
| 1271 | uint16_t length; |
| 1272 | uint8_t sessionId; /* Session ID */ |
| 1273 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 1274 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1275 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1276 | uint16_t staId; |
Srinivas Girigowda | eaf136a | 2017-06-12 19:03:19 -0700 | [diff] [blame] | 1277 | } tSirSmeDisassocRsp, *tpSirSmeDisassocRsp; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1278 | |
| 1279 | /* / Definition for Disassociation indication from peer */ |
| 1280 | typedef struct sSirSmeDisassocInd { |
| 1281 | uint16_t messageType; /* eWNI_SME_DISASSOC_IND */ |
| 1282 | uint16_t length; |
| 1283 | uint8_t sessionId; /* Session Identifier */ |
| 1284 | uint16_t transactionId; /* Transaction Identifier with PE */ |
| 1285 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1286 | struct qdf_mac_addr bssid; |
| 1287 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1288 | uint16_t staId; |
| 1289 | uint32_t reasonCode; |
| 1290 | } tSirSmeDisassocInd, *tpSirSmeDisassocInd; |
| 1291 | |
| 1292 | /* / Definition for Disassociation confirm */ |
| 1293 | /* / MAC ---> */ |
| 1294 | typedef struct sSirSmeDisassocCnf { |
| 1295 | uint16_t messageType; /* eWNI_SME_DISASSOC_CNF */ |
| 1296 | uint16_t length; |
Vignesh Viswanathan | b2dcdd0 | 2018-05-24 11:48:12 +0530 | [diff] [blame] | 1297 | uint8_t sme_session_id; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1298 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1299 | struct qdf_mac_addr bssid; |
| 1300 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1301 | } tSirSmeDisassocCnf, *tpSirSmeDisassocCnf, |
| 1302 | tSirSmeDeauthCnf, *tpSirSmeDeauthCnf; |
| 1303 | |
Hanumantha Reddy Pothula | 3e5d6aa | 2016-09-08 15:21:54 +0530 | [diff] [blame] | 1304 | /** |
| 1305 | * struct sir_sme_discon_done_ind - disconnect done indiaction |
| 1306 | * @message_type: msg type |
| 1307 | * @length: length of msg |
| 1308 | * @session_id: session id of the indication |
| 1309 | * @reason_code: reason for disconnect indication |
| 1310 | * @peer_mac: peer mac |
| 1311 | */ |
| 1312 | struct sir_sme_discon_done_ind { |
| 1313 | uint16_t message_type; |
| 1314 | uint16_t length; |
| 1315 | uint8_t session_id; |
| 1316 | tSirResultCodes reason_code; |
| 1317 | tSirMacAddr peer_mac; |
| 1318 | }; |
| 1319 | |
| 1320 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1321 | /* / Definition for Deauthetication request */ |
| 1322 | typedef struct sSirSmeDeauthReq { |
| 1323 | uint16_t messageType; /* eWNI_SME_DEAUTH_REQ */ |
| 1324 | uint16_t length; |
| 1325 | uint8_t sessionId; /* Session ID */ |
| 1326 | uint16_t transactionId; /* Transaction ID for cmd */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1327 | struct qdf_mac_addr bssid; /* AP BSSID */ |
| 1328 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1329 | uint16_t reasonCode; |
| 1330 | } tSirSmeDeauthReq, *tpSirSmeDeauthReq; |
| 1331 | |
| 1332 | /* / Definition for Deauthetication response */ |
| 1333 | typedef struct sSirSmeDeauthRsp { |
| 1334 | uint16_t messageType; /* eWNI_SME_DEAUTH_RSP */ |
| 1335 | uint16_t length; |
| 1336 | uint8_t sessionId; /* Session ID */ |
| 1337 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 1338 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1339 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1340 | } tSirSmeDeauthRsp, *tpSirSmeDeauthRsp; |
| 1341 | |
| 1342 | /* / Definition for Deauthetication indication from peer */ |
| 1343 | typedef struct sSirSmeDeauthInd { |
| 1344 | uint16_t messageType; /* eWNI_SME_DEAUTH_IND */ |
| 1345 | uint16_t length; |
| 1346 | uint8_t sessionId; /* Added for BT-AMP */ |
| 1347 | uint16_t transactionId; /* Added for BT-AMP */ |
| 1348 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1349 | struct qdf_mac_addr bssid; /* AP BSSID */ |
| 1350 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1351 | |
| 1352 | uint16_t staId; |
| 1353 | uint32_t reasonCode; |
Kiran Kumar Lokere | 37d3aa2 | 2015-11-03 14:58:26 -0800 | [diff] [blame] | 1354 | int8_t rssi; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1355 | } tSirSmeDeauthInd, *tpSirSmeDeauthInd; |
| 1356 | |
| 1357 | /* / Definition for stop BSS request message */ |
| 1358 | typedef struct sSirSmeStopBssReq { |
| 1359 | uint16_t messageType; /* eWNI_SME_STOP_BSS_REQ */ |
| 1360 | uint16_t length; |
| 1361 | uint8_t sessionId; /* Session ID */ |
| 1362 | uint16_t transactionId; /* tranSaction ID for cmd */ |
| 1363 | tSirResultCodes reasonCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1364 | struct qdf_mac_addr bssid; /* Self BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1365 | } tSirSmeStopBssReq, *tpSirSmeStopBssReq; |
| 1366 | |
| 1367 | /* / Definition for stop BSS response message */ |
| 1368 | typedef struct sSirSmeStopBssRsp { |
| 1369 | uint16_t messageType; /* eWNI_SME_STOP_BSS_RSP */ |
| 1370 | uint16_t length; |
| 1371 | tSirResultCodes statusCode; |
| 1372 | uint8_t sessionId; /* Session ID */ |
| 1373 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 1374 | } tSirSmeStopBssRsp, *tpSirSmeStopBssRsp; |
| 1375 | |
| 1376 | /* / Definition for Channel Switch indication for station */ |
| 1377 | /* / MAC ---> */ |
| 1378 | typedef struct sSirSmeSwitchChannelInd { |
| 1379 | uint16_t messageType; /* eWNI_SME_SWITCH_CHL_IND */ |
| 1380 | uint16_t length; |
| 1381 | uint8_t sessionId; |
| 1382 | uint16_t newChannelId; |
Amar Singhal | 5cccafe | 2017-02-15 12:42:58 -0800 | [diff] [blame] | 1383 | struct ch_params chan_params; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1384 | struct qdf_mac_addr bssid; /* BSSID */ |
Jianmin Zhu | 3c50e40 | 2018-12-04 18:52:54 +0800 | [diff] [blame] | 1385 | QDF_STATUS status; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1386 | } tSirSmeSwitchChannelInd, *tpSirSmeSwitchChannelInd; |
| 1387 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1388 | /* / Definition for MIC failure indication */ |
| 1389 | /* / MAC ---> */ |
| 1390 | /* / MAC reports this each time a MIC failure occures on Rx TKIP packet */ |
| 1391 | typedef struct sSirSmeMicFailureInd { |
| 1392 | uint16_t messageType; /* eWNI_SME_MIC_FAILURE_IND */ |
| 1393 | uint16_t length; |
| 1394 | uint8_t sessionId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1395 | struct qdf_mac_addr bssId; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1396 | tSirMicFailureInfo info; |
| 1397 | } tSirSmeMicFailureInd, *tpSirSmeMicFailureInd; |
| 1398 | |
| 1399 | typedef struct sSirSmeMissedBeaconInd { |
| 1400 | uint16_t messageType; /* eWNI_SME_MISSED_BEACON_IND */ |
| 1401 | uint16_t length; |
| 1402 | uint8_t bssIdx; |
| 1403 | } tSirSmeMissedBeaconInd, *tpSirSmeMissedBeaconInd; |
| 1404 | |
| 1405 | /* / Definition for Set Context request */ |
| 1406 | /* / ---> MAC */ |
| 1407 | typedef struct sSirSmeSetContextReq { |
| 1408 | uint16_t messageType; /* eWNI_SME_SET_CONTEXT_REQ */ |
| 1409 | uint16_t length; |
| 1410 | uint8_t sessionId; /* Session ID */ |
| 1411 | uint16_t transactionId; /* Transaction ID for cmd */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1412 | struct qdf_mac_addr peer_macaddr; |
| 1413 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1414 | tSirKeyMaterial keyMaterial; |
| 1415 | } tSirSmeSetContextReq, *tpSirSmeSetContextReq; |
| 1416 | |
| 1417 | /* / Definition for Set Context response */ |
| 1418 | /* / MAC ---> */ |
| 1419 | typedef struct sSirSmeSetContextRsp { |
| 1420 | uint16_t messageType; /* eWNI_SME_SET_CONTEXT_RSP */ |
| 1421 | uint16_t length; |
| 1422 | uint8_t sessionId; /* Session ID */ |
| 1423 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 1424 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1425 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1426 | } tSirSmeSetContextRsp, *tpSirSmeSetContextRsp; |
| 1427 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1428 | /*******************PE Statistics*************************/ |
| 1429 | |
| 1430 | /* |
| 1431 | * tpAniGetPEStatsReq is tied to |
| 1432 | * for SME ==> PE eWNI_SME_GET_STATISTICS_REQ msgId and |
| 1433 | * for PE ==> HAL SIR_HAL_GET_STATISTICS_REQ msgId |
| 1434 | */ |
| 1435 | typedef struct sAniGetPEStatsReq { |
| 1436 | /* Common for all types are requests */ |
| 1437 | uint16_t msgType; /* message type is same as the request type */ |
| 1438 | uint16_t msgLen; /* length of the entire request */ |
| 1439 | uint32_t staId; /* Per STA stats request must contain valid */ |
| 1440 | /* categories of stats requested. look at ePEStatsMask */ |
| 1441 | uint32_t statsMask; |
| 1442 | uint8_t sessionId; |
| 1443 | } tAniGetPEStatsReq, *tpAniGetPEStatsReq; |
| 1444 | |
| 1445 | /* |
| 1446 | * tpAniGetPEStatsRsp is tied to |
| 1447 | * for PE ==> SME eWNI_SME_GET_STATISTICS_RSP msgId and |
| 1448 | * for HAL ==> PE SIR_HAL_GET_STATISTICS_RSP msgId |
| 1449 | */ |
| 1450 | typedef struct sAniGetPEStatsRsp { |
| 1451 | /* Common for all types are responses */ |
| 1452 | uint16_t msgType; /* message type is same as the request type */ |
| 1453 | /* length of the entire request, includes the pStatsBuf length too */ |
| 1454 | uint16_t msgLen; |
| 1455 | uint8_t sessionId; |
| 1456 | uint32_t rc; /* success/failure */ |
| 1457 | uint32_t staId; /* Per STA stats request must contain valid */ |
| 1458 | /* categories of stats requested. look at ePEStatsMask */ |
| 1459 | uint32_t statsMask; |
| 1460 | /* void *pStatsBuf; */ |
| 1461 | /* |
| 1462 | * The Stats buffer starts here and can be an aggregate of more than one |
| 1463 | * statistics structure depending on statsMask. The void pointer |
| 1464 | * "pStatsBuf" is commented out intentionally and the src code that uses |
| 1465 | * this structure should take that into account. |
| 1466 | */ |
| 1467 | } tAniGetPEStatsRsp, *tpAniGetPEStatsRsp; |
| 1468 | |
| 1469 | typedef struct sAniGetRssiReq { |
| 1470 | /* Common for all types are requests */ |
| 1471 | uint16_t msgType; /* message type is same as the request type */ |
| 1472 | uint16_t msgLen; /* length of the entire request */ |
| 1473 | uint8_t sessionId; |
| 1474 | uint8_t staId; |
| 1475 | int8_t lastRSSI; /* in case of error, return last RSSI */ |
| 1476 | void *rssiCallback; |
| 1477 | void *pDevContext; /* device context */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1478 | } tAniGetRssiReq, *tpAniGetRssiReq; |
| 1479 | |
| 1480 | typedef struct sAniGetSnrReq { |
| 1481 | /* Common for all types are requests */ |
| 1482 | uint16_t msgType; /* message type is same as the request type */ |
| 1483 | uint16_t msgLen; /* length of the entire request */ |
| 1484 | uint8_t sessionId; |
| 1485 | uint8_t staId; |
| 1486 | void *snrCallback; |
| 1487 | void *pDevContext; /* device context */ |
| 1488 | int8_t snr; |
| 1489 | } tAniGetSnrReq, *tpAniGetSnrReq; |
| 1490 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1491 | /* generic country code change request MSG structure */ |
| 1492 | typedef struct sAniGenericChangeCountryCodeReq { |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1493 | uint16_t msgType; /* message type is same as the request type */ |
| 1494 | uint16_t msgLen; /* length of the entire request */ |
| 1495 | uint8_t countryCode[WNI_CFG_COUNTRY_CODE_LEN]; /* 3 char country code */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1496 | } tAniGenericChangeCountryCodeReq, *tpAniGenericChangeCountryCodeReq; |
| 1497 | |
Srinivas Girigowda | 296105a | 2015-09-24 16:31:16 -0700 | [diff] [blame] | 1498 | /** |
| 1499 | * struct sAniDHCPStopInd - DHCP Stop indication message |
| 1500 | * @msgType: message type is same as the request type |
| 1501 | * @msgLen: length of the entire request |
| 1502 | * @device_mode: Mode of the device(ex:STA, AP) |
| 1503 | * @adapterMacAddr: MAC address of the adapter |
| 1504 | * @peerMacAddr: MAC address of the connected peer |
| 1505 | */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1506 | typedef struct sAniDHCPStopInd { |
Srinivas Girigowda | 296105a | 2015-09-24 16:31:16 -0700 | [diff] [blame] | 1507 | uint16_t msgType; |
| 1508 | uint16_t msgLen; |
| 1509 | uint8_t device_mode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1510 | struct qdf_mac_addr adapterMacAddr; |
| 1511 | struct qdf_mac_addr peerMacAddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1512 | } tAniDHCPInd, *tpAniDHCPInd; |
| 1513 | |
Rajeev Kumar | 8e3e283 | 2015-11-06 16:02:54 -0800 | [diff] [blame] | 1514 | typedef struct sAniTXFailMonitorInd { |
| 1515 | uint16_t msgType; /* message type is same as the request type */ |
| 1516 | uint16_t msgLen; /* length of the entire request */ |
| 1517 | uint8_t tx_fail_count; |
| 1518 | void *txFailIndCallback; |
| 1519 | } tAniTXFailMonitorInd, *tpAniTXFailMonitorInd; |
| 1520 | |
Naveen Rawat | ea1564b | 2018-05-17 15:56:11 -0700 | [diff] [blame] | 1521 | #ifndef QCA_SUPPORT_CP_STATS |
| 1522 | /** |
| 1523 | * enum tx_rate_info - tx_rate flags |
| 1524 | * @TX_RATE_LEGACY: Legacy rates |
| 1525 | * @TX_RATE_HT20: HT20 rates |
| 1526 | * @TX_RATE_HT40: HT40 rates |
| 1527 | * @TX_RATE_SGI: Rate with Short guard interval |
| 1528 | * @TX_RATE_LGI: Rate with Long guard interval |
| 1529 | * @TX_RATE_VHT20: VHT 20 rates |
| 1530 | * @TX_RATE_VHT40: VHT 40 rates |
| 1531 | * @TX_RATE_VHT80: VHT 80 rates |
| 1532 | */ |
| 1533 | enum tx_rate_info { |
| 1534 | TX_RATE_LEGACY = 0x1, |
| 1535 | TX_RATE_HT20 = 0x2, |
| 1536 | TX_RATE_HT40 = 0x4, |
| 1537 | TX_RATE_SGI = 0x8, |
| 1538 | TX_RATE_LGI = 0x10, |
| 1539 | TX_RATE_VHT20 = 0x20, |
| 1540 | TX_RATE_VHT40 = 0x40, |
| 1541 | TX_RATE_VHT80 = 0x80 |
| 1542 | }; |
| 1543 | #endif |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1544 | /**********************PE Statistics end*************************/ |
| 1545 | |
| 1546 | typedef struct sSirP2PNoaStart { |
| 1547 | uint32_t status; |
| 1548 | uint32_t bssIdx; |
| 1549 | } tSirP2PNoaStart, *tpSirP2PNoaStart; |
| 1550 | |
| 1551 | typedef struct sSirTdlsInd { |
| 1552 | uint16_t status; |
| 1553 | uint16_t assocId; |
| 1554 | uint16_t staIdx; |
| 1555 | uint16_t reasonCode; |
| 1556 | } tSirTdlsInd, *tpSirTdlsInd; |
| 1557 | |
| 1558 | typedef struct sSirP2PNoaAttr { |
| 1559 | #ifdef ANI_BIG_BYTE_ENDIAN |
| 1560 | uint32_t index:8; |
| 1561 | uint32_t oppPsFlag:1; |
| 1562 | uint32_t ctWin:7; |
| 1563 | uint32_t rsvd1:16; |
| 1564 | #else |
| 1565 | uint32_t rsvd1:16; |
| 1566 | uint32_t ctWin:7; |
| 1567 | uint32_t oppPsFlag:1; |
| 1568 | uint32_t index:8; |
| 1569 | #endif |
| 1570 | |
| 1571 | #ifdef ANI_BIG_BYTE_ENDIAN |
| 1572 | uint32_t uNoa1IntervalCnt:8; |
| 1573 | uint32_t rsvd2:24; |
| 1574 | #else |
| 1575 | uint32_t rsvd2:24; |
| 1576 | uint32_t uNoa1IntervalCnt:8; |
| 1577 | #endif |
| 1578 | uint32_t uNoa1Duration; |
| 1579 | uint32_t uNoa1Interval; |
| 1580 | uint32_t uNoa1StartTime; |
| 1581 | |
| 1582 | #ifdef ANI_BIG_BYTE_ENDIAN |
| 1583 | uint32_t uNoa2IntervalCnt:8; |
| 1584 | uint32_t rsvd3:24; |
| 1585 | #else |
| 1586 | uint32_t rsvd3:24; |
| 1587 | uint32_t uNoa2IntervalCnt:8; |
| 1588 | #endif |
| 1589 | uint32_t uNoa2Duration; |
| 1590 | uint32_t uNoa2Interval; |
| 1591 | uint32_t uNoa2StartTime; |
| 1592 | } tSirP2PNoaAttr, *tpSirP2PNoaAttr; |
| 1593 | |
| 1594 | typedef struct sSirTclasInfo { |
| 1595 | tSirMacTclasIE tclas; |
| 1596 | uint8_t version; /* applies only for classifier type ip */ |
| 1597 | union { |
| 1598 | tSirMacTclasParamEthernet eth; |
| 1599 | tSirMacTclasParamIPv4 ipv4; |
| 1600 | tSirMacTclasParamIPv6 ipv6; |
| 1601 | tSirMacTclasParam8021dq t8021dq; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1602 | } qdf_packed tclasParams; |
| 1603 | } qdf_packed tSirTclasInfo; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1604 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1605 | typedef struct sSirAddtsReqInfo { |
| 1606 | uint8_t dialogToken; |
Jeff Johnson | 56471b9 | 2018-12-22 14:36:06 -0800 | [diff] [blame] | 1607 | struct mac_tspec_ie tspec; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1608 | |
| 1609 | uint8_t numTclas; /* number of Tclas elements */ |
| 1610 | tSirTclasInfo tclasInfo[SIR_MAC_TCLASIE_MAXNUM]; |
| 1611 | uint8_t tclasProc; |
| 1612 | #if defined(FEATURE_WLAN_ESE) |
| 1613 | tSirMacESETSRSIE tsrsIE; |
| 1614 | uint8_t tsrsPresent:1; |
| 1615 | #endif |
| 1616 | uint8_t wmeTspecPresent:1; |
| 1617 | uint8_t wsmTspecPresent:1; |
| 1618 | uint8_t lleTspecPresent:1; |
| 1619 | uint8_t tclasProcPresent:1; |
| 1620 | } tSirAddtsReqInfo, *tpSirAddtsReqInfo; |
| 1621 | |
| 1622 | typedef struct sSirAddtsRspInfo { |
| 1623 | uint8_t dialogToken; |
| 1624 | tSirMacStatusCodes status; |
| 1625 | tSirMacTsDelayIE delay; |
| 1626 | |
Jeff Johnson | 56471b9 | 2018-12-22 14:36:06 -0800 | [diff] [blame] | 1627 | struct mac_tspec_ie tspec; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1628 | uint8_t numTclas; /* number of Tclas elements */ |
| 1629 | tSirTclasInfo tclasInfo[SIR_MAC_TCLASIE_MAXNUM]; |
| 1630 | uint8_t tclasProc; |
| 1631 | tSirMacScheduleIE schedule; |
Srinivas Girigowda | 515a9ef | 2015-12-11 11:00:48 -0800 | [diff] [blame] | 1632 | #ifdef FEATURE_WLAN_ESE |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1633 | tSirMacESETSMIE tsmIE; |
| 1634 | uint8_t tsmPresent:1; |
| 1635 | #endif |
| 1636 | uint8_t wmeTspecPresent:1; |
| 1637 | uint8_t wsmTspecPresent:1; |
| 1638 | uint8_t lleTspecPresent:1; |
| 1639 | uint8_t tclasProcPresent:1; |
| 1640 | uint8_t schedulePresent:1; |
| 1641 | } tSirAddtsRspInfo, *tpSirAddtsRspInfo; |
| 1642 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1643 | /* / Add a tspec as defined */ |
| 1644 | typedef struct sSirAddtsReq { |
| 1645 | uint16_t messageType; /* eWNI_SME_ADDTS_REQ */ |
| 1646 | uint16_t length; |
| 1647 | uint8_t sessionId; /* Session ID */ |
| 1648 | uint16_t transactionId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1649 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1650 | uint32_t timeout; /* in ms */ |
| 1651 | uint8_t rspReqd; |
| 1652 | tSirAddtsReqInfo req; |
| 1653 | } tSirAddtsReq, *tpSirAddtsReq; |
| 1654 | |
| 1655 | typedef struct sSirAddtsRsp { |
| 1656 | uint16_t messageType; /* eWNI_SME_ADDTS_RSP */ |
| 1657 | uint16_t length; |
| 1658 | uint8_t sessionId; /* sme sessionId Added for BT-AMP support */ |
| 1659 | uint16_t transactionId; /* sme transaction Id - for BT-AMP Support */ |
| 1660 | uint32_t rc; /* return code */ |
| 1661 | tSirAddtsRspInfo rsp; |
| 1662 | } tSirAddtsRsp, *tpSirAddtsRsp; |
| 1663 | |
| 1664 | typedef struct sSirDeltsReq { |
| 1665 | uint16_t messageType; /* eWNI_SME_DELTS_REQ */ |
| 1666 | uint16_t length; |
| 1667 | uint8_t sessionId; /* Session ID */ |
| 1668 | uint16_t transactionId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1669 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1670 | uint16_t aid; /* use 0 if macAddr is being specified */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1671 | struct qdf_mac_addr macaddr; /* only on AP to specify the STA */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1672 | uint8_t rspReqd; |
Jeff Johnson | cf2ec16 | 2018-12-22 16:46:43 -0800 | [diff] [blame] | 1673 | struct delts_req_info req; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1674 | } tSirDeltsReq, *tpSirDeltsReq; |
| 1675 | |
| 1676 | typedef struct sSirDeltsRsp { |
| 1677 | uint16_t messageType; /* eWNI_SME_DELTS_RSP */ |
| 1678 | uint16_t length; |
| 1679 | uint8_t sessionId; /* sme sessionId Added for BT-AMP support */ |
| 1680 | uint16_t transactionId; /* sme transaction Id - for BT-AMP Support */ |
| 1681 | uint32_t rc; |
| 1682 | uint16_t aid; /* use 0 if macAddr is being specified */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1683 | struct qdf_mac_addr macaddr; /* only on AP to specify the STA */ |
Jeff Johnson | cf2ec16 | 2018-12-22 16:46:43 -0800 | [diff] [blame] | 1684 | struct delts_req_info rsp; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1685 | } tSirDeltsRsp, *tpSirDeltsRsp; |
| 1686 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1687 | #define SIR_QOS_NUM_AC_MAX 4 |
| 1688 | |
| 1689 | typedef struct sSirAggrQosReqInfo { |
| 1690 | uint16_t tspecIdx; |
| 1691 | tSirAddtsReqInfo aggrAddTsInfo[SIR_QOS_NUM_AC_MAX]; |
| 1692 | } tSirAggrQosReqInfo, *tpSirAggrQosReqInfo; |
| 1693 | |
| 1694 | typedef struct sSirAggrQosReq { |
| 1695 | uint16_t messageType; /* eWNI_SME_ADDTS_REQ */ |
| 1696 | uint16_t length; |
| 1697 | uint8_t sessionId; /* Session ID */ |
| 1698 | uint16_t transactionId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1699 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1700 | uint32_t timeout; /* in ms */ |
| 1701 | uint8_t rspReqd; |
| 1702 | tSirAggrQosReqInfo aggrInfo; |
| 1703 | } tSirAggrQosReq, *tpSirAggrQosReq; |
| 1704 | |
| 1705 | typedef struct sSirAggrQosRspInfo { |
| 1706 | uint16_t tspecIdx; |
| 1707 | tSirAddtsRspInfo aggrRsp[SIR_QOS_NUM_AC_MAX]; |
| 1708 | } tSirAggrQosRspInfo, *tpSirAggrQosRspInfo; |
| 1709 | |
| 1710 | typedef struct sSirAggrQosRsp { |
| 1711 | uint16_t messageType; |
| 1712 | uint16_t length; |
| 1713 | uint8_t sessionId; |
| 1714 | tSirAggrQosRspInfo aggrInfo; |
| 1715 | } tSirAggrQosRsp, *tpSirAggrQosRsp; |
| 1716 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1717 | |
| 1718 | typedef struct sSirQosMapSet { |
| 1719 | uint8_t present; |
| 1720 | uint8_t num_dscp_exceptions; |
| 1721 | uint8_t dscp_exceptions[21][2]; |
| 1722 | uint8_t dscp_range[8][2]; |
| 1723 | } tSirQosMapSet, *tpSirQosMapSet; |
| 1724 | |
| 1725 | typedef struct sSmeIbssPeerInd { |
| 1726 | uint16_t mesgType; |
| 1727 | uint16_t mesgLen; |
| 1728 | uint8_t sessionId; |
| 1729 | |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1730 | struct qdf_mac_addr peer_addr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1731 | uint16_t staId; |
| 1732 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1733 | /* Beacon will be appended for new Peer indication. */ |
| 1734 | } tSmeIbssPeerInd, *tpSmeIbssPeerInd; |
| 1735 | |
| 1736 | typedef struct sSirIbssPeerInactivityInd { |
| 1737 | uint8_t bssIdx; |
| 1738 | uint8_t staIdx; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1739 | struct qdf_mac_addr peer_addr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1740 | } tSirIbssPeerInactivityInd, *tpSirIbssPeerInactivityInd; |
| 1741 | |
gaolez | e510894 | 2017-03-31 16:56:42 +0800 | [diff] [blame] | 1742 | /** |
| 1743 | * struct lim_channel_status |
| 1744 | * @channelfreq: Channel freq |
| 1745 | * @noise_floor: Noise Floor value |
| 1746 | * @rx_clear_count: rx clear count |
| 1747 | * @cycle_count: cycle count |
| 1748 | * @chan_tx_pwr_range: channel tx power per range in 0.5dBm steps |
| 1749 | * @chan_tx_pwr_throughput: channel tx power per throughput |
| 1750 | * @rx_frame_count: rx frame count (cumulative) |
| 1751 | * @bss_rx_cycle_count: BSS rx cycle count |
| 1752 | * @rx_11b_mode_data_duration: b-mode data rx time (units are microseconds) |
| 1753 | * @tx_frame_count: BSS tx cycle count |
| 1754 | * @mac_clk_mhz: sample frequency |
| 1755 | * @channel_id: channel index |
| 1756 | * @cmd_flags: indicate which stat event is this status coming from |
| 1757 | */ |
| 1758 | struct lim_channel_status { |
| 1759 | uint32_t channelfreq; |
| 1760 | uint32_t noise_floor; |
| 1761 | uint32_t rx_clear_count; |
| 1762 | uint32_t cycle_count; |
| 1763 | uint32_t chan_tx_pwr_range; |
| 1764 | uint32_t chan_tx_pwr_throughput; |
| 1765 | uint32_t rx_frame_count; |
| 1766 | uint32_t bss_rx_cycle_count; |
| 1767 | uint32_t rx_11b_mode_data_duration; |
| 1768 | uint32_t tx_frame_count; |
| 1769 | uint32_t mac_clk_mhz; |
| 1770 | uint32_t channel_id; |
| 1771 | uint32_t cmd_flags; |
| 1772 | }; |
| 1773 | |
| 1774 | /** |
| 1775 | * struct lim_scan_channel_status |
| 1776 | * @total_channel: total number of be scanned channel |
| 1777 | * @channel_status_list: channel status info store in this array |
| 1778 | */ |
| 1779 | struct lim_scan_channel_status { |
| 1780 | uint8_t total_channel; |
| 1781 | struct lim_channel_status |
| 1782 | channel_status_list[SIR_MAX_SUPPORTED_CHANNEL_LIST]; |
| 1783 | }; |
| 1784 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1785 | typedef struct sSirSmeGetAssocSTAsReq { |
| 1786 | uint16_t messageType; /* eWNI_SME_GET_ASSOC_STAS_REQ */ |
| 1787 | uint16_t length; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1788 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1789 | uint16_t modId; |
| 1790 | void *pUsrContext; |
| 1791 | void *pSapEventCallback; |
| 1792 | /* Pointer to allocated mem passed in wlansap_get_assoc_stations API */ |
| 1793 | void *pAssocStasArray; |
| 1794 | } tSirSmeGetAssocSTAsReq, *tpSirSmeGetAssocSTAsReq; |
| 1795 | |
| 1796 | typedef struct sSmeMaxAssocInd { |
| 1797 | uint16_t mesgType; /* eWNI_SME_MAX_ASSOC_EXCEEDED */ |
| 1798 | uint16_t mesgLen; |
| 1799 | uint8_t sessionId; |
| 1800 | /* the new peer that got rejected max assoc limit reached */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1801 | struct qdf_mac_addr peer_mac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1802 | } tSmeMaxAssocInd, *tpSmeMaxAssocInd; |
| 1803 | |
| 1804 | typedef struct sSmeCsaOffloadInd { |
| 1805 | uint16_t mesgType; /* eWNI_SME_CSA_OFFLOAD_EVENT */ |
| 1806 | uint16_t mesgLen; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1807 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1808 | } tSmeCsaOffloadInd, *tpSmeCsaOffloadInd; |
| 1809 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1810 | #define SIR_MAX_NAME_SIZE 64 |
| 1811 | #define SIR_MAX_TEXT_SIZE 32 |
| 1812 | |
| 1813 | typedef struct sSirName { |
| 1814 | uint8_t num_name; |
| 1815 | uint8_t name[SIR_MAX_NAME_SIZE]; |
| 1816 | } tSirName; |
| 1817 | |
| 1818 | typedef struct sSirText { |
| 1819 | uint8_t num_text; |
| 1820 | uint8_t text[SIR_MAX_TEXT_SIZE]; |
| 1821 | } tSirText; |
| 1822 | |
| 1823 | #define SIR_WPS_PROBRSP_VER_PRESENT 0x00000001 |
| 1824 | #define SIR_WPS_PROBRSP_STATE_PRESENT 0x00000002 |
| 1825 | #define SIR_WPS_PROBRSP_APSETUPLOCK_PRESENT 0x00000004 |
| 1826 | #define SIR_WPS_PROBRSP_SELECTEDREGISTRA_PRESENT 0x00000008 |
| 1827 | #define SIR_WPS_PROBRSP_DEVICEPASSWORDID_PRESENT 0x00000010 |
| 1828 | #define SIR_WPS_PROBRSP_SELECTEDREGISTRACFGMETHOD_PRESENT 0x00000020 |
| 1829 | #define SIR_WPS_PROBRSP_RESPONSETYPE_PRESENT 0x00000040 |
| 1830 | #define SIR_WPS_PROBRSP_UUIDE_PRESENT 0x00000080 |
| 1831 | #define SIR_WPS_PROBRSP_MANUFACTURE_PRESENT 0x00000100 |
| 1832 | #define SIR_WPS_PROBRSP_MODELNAME_PRESENT 0x00000200 |
| 1833 | #define SIR_WPS_PROBRSP_MODELNUMBER_PRESENT 0x00000400 |
| 1834 | #define SIR_WPS_PROBRSP_SERIALNUMBER_PRESENT 0x00000800 |
| 1835 | #define SIR_WPS_PROBRSP_PRIMARYDEVICETYPE_PRESENT 0x00001000 |
| 1836 | #define SIR_WPS_PROBRSP_DEVICENAME_PRESENT 0x00002000 |
| 1837 | #define SIR_WPS_PROBRSP_CONFIGMETHODS_PRESENT 0x00004000 |
| 1838 | #define SIR_WPS_PROBRSP_RF_BANDS_PRESENT 0x00008000 |
| 1839 | |
| 1840 | typedef struct sSirWPSProbeRspIE { |
| 1841 | uint32_t FieldPresent; |
| 1842 | uint32_t Version; /* Version. 0x10 = version 1.0, 0x11 = etc. */ |
| 1843 | uint32_t wpsState; /* 1 = unconfigured, 2 = configured. */ |
| 1844 | bool APSetupLocked; /* Must be included if value is true */ |
| 1845 | /* |
| 1846 | * BOOL: indicates if the user has recently activated a Registrar to |
| 1847 | * add an Enrollee. |
| 1848 | */ |
| 1849 | bool SelectedRegistra; |
| 1850 | uint16_t DevicePasswordID; /* Device Password ID */ |
| 1851 | /* Selected Registrar config method */ |
| 1852 | uint16_t SelectedRegistraCfgMethod; |
| 1853 | uint8_t ResponseType; /* Response type */ |
| 1854 | uint8_t UUID_E[16]; /* Unique identifier of the AP. */ |
| 1855 | tSirName Manufacture; |
| 1856 | tSirText ModelName; |
| 1857 | tSirText ModelNumber; |
| 1858 | tSirText SerialNumber; |
| 1859 | /* Device Category ID: 1Computer, 2Input Device, ... */ |
| 1860 | uint32_t PrimaryDeviceCategory; |
| 1861 | /* Vendor specific OUI for Device Sub Category */ |
| 1862 | uint8_t PrimaryDeviceOUI[4]; |
| 1863 | /* |
| 1864 | Device Sub Category ID: 1-PC, 2-Server if Device Category ID |
| 1865 | * is computer |
| 1866 | */ |
| 1867 | uint32_t DeviceSubCategory; |
| 1868 | tSirText DeviceName; |
| 1869 | uint16_t ConfigMethod; /* Configuaration method */ |
| 1870 | uint8_t RFBand; /* RF bands available on the AP */ |
| 1871 | } tSirWPSProbeRspIE; |
| 1872 | |
| 1873 | #define SIR_WPS_BEACON_VER_PRESENT 0x00000001 |
| 1874 | #define SIR_WPS_BEACON_STATE_PRESENT 0x00000002 |
| 1875 | #define SIR_WPS_BEACON_APSETUPLOCK_PRESENT 0x00000004 |
| 1876 | #define SIR_WPS_BEACON_SELECTEDREGISTRA_PRESENT 0x00000008 |
| 1877 | #define SIR_WPS_BEACON_DEVICEPASSWORDID_PRESENT 0x00000010 |
| 1878 | #define SIR_WPS_BEACON_SELECTEDREGISTRACFGMETHOD_PRESENT 0x00000020 |
| 1879 | #define SIR_WPS_BEACON_UUIDE_PRESENT 0x00000080 |
| 1880 | #define SIR_WPS_BEACON_RF_BANDS_PRESENT 0x00000100 |
| 1881 | #define SIR_WPS_UUID_LEN 16 |
| 1882 | |
| 1883 | typedef struct sSirWPSBeaconIE { |
| 1884 | uint32_t FieldPresent; |
| 1885 | uint32_t Version; /* Version. 0x10 = version 1.0, 0x11 = etc. */ |
| 1886 | uint32_t wpsState; /* 1 = unconfigured, 2 = configured. */ |
| 1887 | bool APSetupLocked; /* Must be included if value is true */ |
| 1888 | /* |
| 1889 | * BOOL: indicates if the user has recently activated a Registrar to |
| 1890 | * add an Enrollee. |
| 1891 | */ |
| 1892 | bool SelectedRegistra; |
| 1893 | uint16_t DevicePasswordID; /* Device Password ID */ |
| 1894 | /* Selected Registrar config method */ |
| 1895 | uint16_t SelectedRegistraCfgMethod; |
| 1896 | uint8_t UUID_E[SIR_WPS_UUID_LEN]; /* Unique identifier of the AP. */ |
| 1897 | uint8_t RFBand; /* RF bands available on the AP */ |
| 1898 | } tSirWPSBeaconIE; |
| 1899 | |
| 1900 | #define SIR_WPS_ASSOCRSP_VER_PRESENT 0x00000001 |
| 1901 | #define SIR_WPS_ASSOCRSP_RESPONSETYPE_PRESENT 0x00000002 |
| 1902 | |
| 1903 | typedef struct sSirWPSAssocRspIE { |
| 1904 | uint32_t FieldPresent; |
| 1905 | uint32_t Version; |
| 1906 | uint8_t ResposeType; |
| 1907 | } tSirWPSAssocRspIE; |
| 1908 | |
| 1909 | typedef struct sSirAPWPSIEs { |
| 1910 | tSirWPSProbeRspIE SirWPSProbeRspIE; /*WPS Set Probe Respose IE */ |
| 1911 | tSirWPSBeaconIE SirWPSBeaconIE; /*WPS Set Beacon IE */ |
| 1912 | tSirWPSAssocRspIE SirWPSAssocRspIE; /*WPS Set Assoc Response IE */ |
| 1913 | } tSirAPWPSIEs, *tpSiriAPWPSIEs; |
| 1914 | |
| 1915 | typedef struct sSirUpdateAPWPSIEsReq { |
| 1916 | uint16_t messageType; /* eWNI_SME_UPDATE_APWPSIE_REQ */ |
| 1917 | uint16_t length; |
| 1918 | uint16_t transactionId; /* Transaction ID for cmd */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1919 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1920 | uint8_t sessionId; /* Session ID */ |
| 1921 | tSirAPWPSIEs APWPSIEs; |
| 1922 | } tSirUpdateAPWPSIEsReq, *tpSirUpdateAPWPSIEsReq; |
| 1923 | |
Naveen Rawat | 8029a40 | 2017-06-01 10:54:19 -0700 | [diff] [blame] | 1924 | struct update_config { |
| 1925 | uint16_t messageType; /* eWNI_SME_UPDATE_CONFIG */ |
| 1926 | uint16_t length; |
| 1927 | uint8_t sme_session_id; |
| 1928 | uint16_t capab; |
| 1929 | uint32_t value; |
| 1930 | }; |
| 1931 | |
Selvaraj, Sridhar | 7231c5f | 2016-09-28 12:42:33 +0530 | [diff] [blame] | 1932 | /* |
| 1933 | * enum sir_update_session_param_type - session param type |
| 1934 | * @SIR_PARAM_SSID_HIDDEN: ssidHidden parameter |
Selvaraj, Sridhar | ac4fcf3 | 2016-09-28 12:57:32 +0530 | [diff] [blame] | 1935 | * @SIR_PARAM_IGNORE_ASSOC_DISALLOWED: ignore_assoc_disallowed parameter |
Selvaraj, Sridhar | 7231c5f | 2016-09-28 12:42:33 +0530 | [diff] [blame] | 1936 | */ |
| 1937 | enum sir_update_session_param_type { |
| 1938 | SIR_PARAM_SSID_HIDDEN, |
Selvaraj, Sridhar | ac4fcf3 | 2016-09-28 12:57:32 +0530 | [diff] [blame] | 1939 | SIR_PARAM_IGNORE_ASSOC_DISALLOWED, |
Selvaraj, Sridhar | 7231c5f | 2016-09-28 12:42:33 +0530 | [diff] [blame] | 1940 | }; |
| 1941 | |
| 1942 | /* |
| 1943 | * struct sir_update_session_param |
| 1944 | * @message_type: SME message type |
| 1945 | * @length: size of struct sir_update_session_param |
| 1946 | * @session_id: Session ID |
| 1947 | * @param_type: parameter to be updated |
| 1948 | * @param_val: Parameter value to update |
| 1949 | */ |
| 1950 | struct sir_update_session_param { |
| 1951 | uint16_t message_type; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1952 | uint16_t length; |
Selvaraj, Sridhar | 7231c5f | 2016-09-28 12:42:33 +0530 | [diff] [blame] | 1953 | uint8_t session_id; |
| 1954 | uint32_t param_type; |
| 1955 | uint32_t param_val; |
| 1956 | }; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1957 | |
Manjunathappa Prakash | 59f861d | 2016-04-21 10:33:31 -0700 | [diff] [blame] | 1958 | /** |
Kiran Kumar Lokere | e6476b2 | 2017-10-16 23:40:32 -0700 | [diff] [blame] | 1959 | * struct sir_set_he_bss_color |
| 1960 | * @message_type: SME message type |
| 1961 | * @length: size of struct sir_set_he_bss_color |
| 1962 | * @session_id: Session ID |
| 1963 | * @bss_color: bss color value |
| 1964 | */ |
| 1965 | struct sir_set_he_bss_color { |
| 1966 | uint16_t message_type; |
| 1967 | uint16_t length; |
| 1968 | uint8_t session_id; |
| 1969 | uint8_t bss_color; |
| 1970 | }; |
| 1971 | |
| 1972 | /** |
Manjunathappa Prakash | 59f861d | 2016-04-21 10:33:31 -0700 | [diff] [blame] | 1973 | * struct sir_create_session - Used for creating session in monitor mode |
| 1974 | * @type: SME host message type. |
| 1975 | * @msg_len: Length of the message. |
| 1976 | * @bss_id: bss_id for creating the session. |
| 1977 | */ |
| 1978 | struct sir_create_session { |
| 1979 | uint16_t type; |
| 1980 | uint16_t msg_len; |
Rajeev Kumar Sirasanagandla | e3b5991 | 2018-08-24 15:53:31 +0530 | [diff] [blame] | 1981 | uint8_t vdev_id; |
Manjunathappa Prakash | 59f861d | 2016-04-21 10:33:31 -0700 | [diff] [blame] | 1982 | struct qdf_mac_addr bss_id; |
| 1983 | }; |
| 1984 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1985 | /* Beacon Interval */ |
| 1986 | typedef struct sSirChangeBIParams { |
| 1987 | uint16_t messageType; |
| 1988 | uint16_t length; |
| 1989 | uint16_t beaconInterval; /* Beacon Interval */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 1990 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 1991 | uint8_t sessionId; /* Session ID */ |
| 1992 | } tSirChangeBIParams, *tpSirChangeBIParams; |
| 1993 | |
| 1994 | #ifdef QCA_HT_2040_COEX |
| 1995 | typedef struct sSirSetHT2040Mode { |
| 1996 | uint16_t messageType; |
| 1997 | uint16_t length; |
| 1998 | uint8_t cbMode; |
| 1999 | bool obssEnabled; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2000 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2001 | uint8_t sessionId; /* Session ID */ |
| 2002 | } tSirSetHT2040Mode, *tpSirSetHT2040Mode; |
| 2003 | #endif |
| 2004 | |
| 2005 | #define SIR_WPS_PBC_WALK_TIME 120 /* 120 Second */ |
| 2006 | |
| 2007 | typedef struct sSirWPSPBCSession { |
| 2008 | struct sSirWPSPBCSession *next; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2009 | struct qdf_mac_addr addr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2010 | uint8_t uuid_e[SIR_WPS_UUID_LEN]; |
| 2011 | uint32_t timestamp; |
| 2012 | } tSirWPSPBCSession; |
| 2013 | |
| 2014 | typedef struct sSirSmeGetWPSPBCSessionsReq { |
| 2015 | uint16_t messageType; /* eWNI_SME_GET_WPSPBC_SESSION_REQ */ |
| 2016 | uint16_t length; |
| 2017 | void *pUsrContext; |
| 2018 | void *pSapEventCallback; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2019 | struct qdf_mac_addr bssid; /* BSSID */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2020 | /* MAC Address of STA in WPS Session to be removed */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2021 | struct qdf_mac_addr remove_mac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2022 | } tSirSmeGetWPSPBCSessionsReq, *tpSirSmeGetWPSPBCSessionsReq; |
| 2023 | |
| 2024 | typedef struct sSirWPSPBCProbeReq { |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2025 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2026 | uint16_t probeReqIELen; |
| 2027 | uint8_t probeReqIE[512]; |
| 2028 | } tSirWPSPBCProbeReq, *tpSirWPSPBCProbeReq; |
| 2029 | |
| 2030 | /* probereq from peer, when wsc is enabled */ |
| 2031 | typedef struct sSirSmeProbeReqInd { |
| 2032 | uint16_t messageType; /* eWNI_SME_WPS_PBC_PROBE_REQ_IND */ |
| 2033 | uint16_t length; |
| 2034 | uint8_t sessionId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2035 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2036 | tSirWPSPBCProbeReq WPSPBCProbeReq; |
| 2037 | } tSirSmeProbeReqInd, *tpSirSmeProbeReqInd; |
| 2038 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2039 | #define SIR_ROAM_MAX_CHANNELS 80 |
| 2040 | #define SIR_ROAM_SCAN_MAX_PB_REQ_SIZE 450 |
| 2041 | /* Occupied channel list remains static */ |
| 2042 | #define CHANNEL_LIST_STATIC 1 |
Himanshu Agarwal | b23aa57 | 2018-06-14 17:04:44 +0530 | [diff] [blame] | 2043 | /* Occupied channel list can be dynamic */ |
| 2044 | #define CHANNEL_LIST_DYNAMIC 2 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2045 | #define SIR_ROAM_SCAN_24G_DEFAULT_CH 1 |
| 2046 | #define SIR_ROAM_SCAN_5G_DEFAULT_CH 36 |
| 2047 | #define SIR_ROAM_SCAN_RESERVED_BYTES 61 |
| 2048 | |
| 2049 | #ifdef WLAN_FEATURE_ROAM_OFFLOAD |
hangtian | b95e63b | 2018-11-28 12:10:00 +0800 | [diff] [blame] | 2050 | #define SIR_ROAM_SCAN_PSK_SIZE 48 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2051 | #define SIR_ROAM_R0KH_ID_MAX_LEN 48 |
| 2052 | #endif |
| 2053 | /* SME -> HAL - This is the host offload request. */ |
| 2054 | #define SIR_IPV4_ARP_REPLY_OFFLOAD 0 |
| 2055 | #define SIR_IPV6_NEIGHBOR_DISCOVERY_OFFLOAD 1 |
| 2056 | #define SIR_IPV6_NS_OFFLOAD 2 |
| 2057 | #define SIR_OFFLOAD_DISABLE 0 |
| 2058 | #define SIR_OFFLOAD_ENABLE 1 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2059 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2060 | typedef struct sSirHostOffloadReq { |
| 2061 | uint8_t offloadType; |
| 2062 | uint8_t enableOrDisable; |
| 2063 | uint32_t num_ns_offload_count; |
| 2064 | union { |
Srinivas Girigowda | c79a710 | 2015-12-08 15:18:26 -0800 | [diff] [blame] | 2065 | uint8_t hostIpv4Addr[SIR_IPV4_ADDR_LEN]; |
| 2066 | uint8_t hostIpv6Addr[SIR_MAC_IPV6_ADDR_LEN]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2067 | } params; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2068 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2069 | } tSirHostOffloadReq, *tpSirHostOffloadReq; |
| 2070 | |
| 2071 | /* Packet Types. */ |
| 2072 | #define SIR_KEEP_ALIVE_NULL_PKT 1 |
| 2073 | #define SIR_KEEP_ALIVE_UNSOLICIT_ARP_RSP 2 |
| 2074 | |
| 2075 | /* Keep Alive request. */ |
| 2076 | typedef struct sSirKeepAliveReq { |
| 2077 | uint8_t packetType; |
| 2078 | uint32_t timePeriod; |
| 2079 | tSirIpv4Addr hostIpv4Addr; |
| 2080 | tSirIpv4Addr destIpv4Addr; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2081 | struct qdf_mac_addr dest_macaddr; |
| 2082 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2083 | uint8_t sessionId; |
| 2084 | } tSirKeepAliveReq, *tpSirKeepAliveReq; |
| 2085 | |
| 2086 | typedef struct sSirSmeMgmtFrameInd { |
Abhishek Singh | 7996eb7 | 2015-12-30 17:24:02 +0530 | [diff] [blame] | 2087 | uint16_t frame_len; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2088 | uint32_t rxChan; |
| 2089 | uint8_t sessionId; |
| 2090 | uint8_t frameType; |
| 2091 | int8_t rxRssi; |
| 2092 | uint8_t frameBuf[1]; /* variable */ |
| 2093 | } tSirSmeMgmtFrameInd, *tpSirSmeMgmtFrameInd; |
| 2094 | |
Abhishek Singh | 7996eb7 | 2015-12-30 17:24:02 +0530 | [diff] [blame] | 2095 | typedef void (*sir_mgmt_frame_ind_callback)(tSirSmeMgmtFrameInd *frame_ind); |
| 2096 | /** |
| 2097 | * struct sir_sme_mgmt_frame_cb_req - Register a |
| 2098 | * management frame callback req |
| 2099 | * |
| 2100 | * @message_type: message id |
| 2101 | * @length: msg length |
| 2102 | * @callback: callback for management frame indication |
| 2103 | */ |
| 2104 | struct sir_sme_mgmt_frame_cb_req { |
| 2105 | uint16_t message_type; |
| 2106 | uint16_t length; |
| 2107 | sir_mgmt_frame_ind_callback callback; |
| 2108 | }; |
| 2109 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2110 | #ifdef WLAN_FEATURE_11W |
| 2111 | typedef struct sSirSmeUnprotMgmtFrameInd { |
| 2112 | uint8_t sessionId; |
| 2113 | uint8_t frameType; |
| 2114 | uint8_t frameLen; |
| 2115 | uint8_t frameBuf[1]; /* variable */ |
| 2116 | } tSirSmeUnprotMgmtFrameInd, *tpSirSmeUnprotMgmtFrameInd; |
| 2117 | #endif |
| 2118 | |
| 2119 | #define SIR_IS_FULL_POWER_REASON_DISCONNECTED(eReason) \ |
| 2120 | ((eSME_LINK_DISCONNECTED_BY_HDD == (eReason)) || \ |
| 2121 | (eSME_LINK_DISCONNECTED_BY_OTHER == (eReason))) |
| 2122 | #define SIR_IS_FULL_POWER_NEEDED_BY_HDD(eReason) \ |
| 2123 | ((eSME_LINK_DISCONNECTED_BY_HDD == (eReason)) || \ |
| 2124 | (eSME_FULL_PWR_NEEDED_BY_HDD == (eReason))) |
| 2125 | |
| 2126 | /* P2P Power Save Related */ |
| 2127 | typedef struct sSirNoAParam { |
| 2128 | uint8_t ctWindow:7; |
| 2129 | uint8_t OppPS:1; |
| 2130 | uint8_t count; |
| 2131 | uint32_t duration; |
| 2132 | uint32_t interval; |
| 2133 | uint32_t singleNoADuration; |
| 2134 | uint8_t psSelection; |
| 2135 | } tSirNoAParam, *tpSirNoAParam; |
| 2136 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2137 | #ifdef WLAN_FEATURE_EXTWOW_SUPPORT |
| 2138 | |
| 2139 | typedef enum ext_wow_type { |
| 2140 | EXT_WOW_TYPE_APP_TYPE1, /* wow type: only enable wakeup for app type1 */ |
| 2141 | EXT_WOW_TYPE_APP_TYPE2, /* wow type: only enable wakeup for app type2 */ |
| 2142 | EXT_WOW_TYPE_APP_TYPE1_2, /* wow type: enable wakeup for app type1&2 */ |
| 2143 | } EXT_WOW_TYPE; |
| 2144 | |
| 2145 | typedef struct { |
| 2146 | uint8_t vdev_id; |
| 2147 | EXT_WOW_TYPE type; |
| 2148 | uint32_t wakeup_pin_num; |
| 2149 | } tSirExtWoWParams, *tpSirExtWoWParams; |
| 2150 | |
| 2151 | typedef struct { |
| 2152 | uint8_t vdev_id; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2153 | struct qdf_mac_addr wakee_mac_addr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2154 | uint8_t identification_id[8]; |
| 2155 | uint8_t password[16]; |
| 2156 | uint32_t id_length; |
| 2157 | uint32_t pass_length; |
| 2158 | } tSirAppType1Params, *tpSirAppType1Params; |
| 2159 | |
| 2160 | typedef struct { |
| 2161 | uint8_t vdev_id; |
| 2162 | |
| 2163 | uint8_t rc4_key[16]; |
| 2164 | uint32_t rc4_key_len; |
| 2165 | |
| 2166 | /** ip header parameter */ |
| 2167 | uint32_t ip_id; /* NC id */ |
| 2168 | uint32_t ip_device_ip; /* NC IP address */ |
| 2169 | uint32_t ip_server_ip; /* Push server IP address */ |
| 2170 | |
| 2171 | /** tcp header parameter */ |
| 2172 | uint16_t tcp_src_port; /* NC TCP port */ |
| 2173 | uint16_t tcp_dst_port; /* Push server TCP port */ |
| 2174 | uint32_t tcp_seq; |
| 2175 | uint32_t tcp_ack_seq; |
| 2176 | |
| 2177 | uint32_t keepalive_init; /* Initial ping interval */ |
| 2178 | uint32_t keepalive_min; /* Minimum ping interval */ |
| 2179 | uint32_t keepalive_max; /* Maximum ping interval */ |
| 2180 | uint32_t keepalive_inc; /* Increment of ping interval */ |
| 2181 | |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2182 | struct qdf_mac_addr gateway_mac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2183 | uint32_t tcp_tx_timeout_val; |
| 2184 | uint32_t tcp_rx_timeout_val; |
| 2185 | } tSirAppType2Params, *tpSirAppType2Params; |
| 2186 | #endif |
| 2187 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2188 | #ifdef WLAN_FEATURE_ROAM_OFFLOAD |
| 2189 | typedef struct { |
| 2190 | uint8_t acvo_uapsd:1; |
| 2191 | uint8_t acvi_uapsd:1; |
| 2192 | uint8_t acbk_uapsd:1; |
| 2193 | uint8_t acbe_uapsd:1; |
| 2194 | uint8_t reserved:4; |
| 2195 | } tSirAcUapsd, *tpSirAcUapsd; |
| 2196 | #endif |
| 2197 | |
| 2198 | typedef struct { |
| 2199 | tSirMacSSid ssId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2200 | uint8_t currAPbssid[QDF_MAC_ADDR_SIZE]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2201 | uint32_t authentication; |
| 2202 | uint8_t encryption; |
| 2203 | uint8_t mcencryption; |
| 2204 | uint8_t ChannelCount; |
| 2205 | uint8_t ChannelCache[SIR_ROAM_MAX_CHANNELS]; |
| 2206 | #ifdef WLAN_FEATURE_11W |
| 2207 | bool mfp_enabled; |
| 2208 | #endif |
| 2209 | |
| 2210 | } tSirRoamNetworkType; |
| 2211 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2212 | typedef enum { |
| 2213 | SIR_ROAMING_DFS_CHANNEL_DISABLED = 0, |
| 2214 | SIR_ROAMING_DFS_CHANNEL_ENABLED_NORMAL = 1, |
| 2215 | SIR_ROAMING_DFS_CHANNEL_ENABLED_ACTIVE = 2 |
| 2216 | } eSirDFSRoamScanMode; |
| 2217 | #define MAX_SSID_ALLOWED_LIST 4 |
| 2218 | #define MAX_BSSID_AVOID_LIST 16 |
| 2219 | #define MAX_BSSID_FAVORED 16 |
| 2220 | /** |
| 2221 | * struct roam_ext_params - Structure holding roaming parameters |
| 2222 | * @num_bssid_avoid_list: The number of BSSID's that we should |
| 2223 | * avoid connecting to. It is like a |
| 2224 | * blacklist of BSSID's. |
| 2225 | * @num_ssid_allowed_list: The number of SSID profiles that are |
| 2226 | * in the Whitelist. When roaming, we |
| 2227 | * consider the BSSID's with this SSID |
| 2228 | * also for roaming apart from the connected one's |
| 2229 | * @num_bssid_favored: Number of BSSID's which have a preference over |
| 2230 | * others |
| 2231 | * @ssid_allowed_list: Whitelist SSID's |
| 2232 | * @bssid_avoid_list: Blacklist SSID's |
| 2233 | * @bssid_favored: Favorable BSSID's |
| 2234 | * @bssid_favored_factor: RSSI to be added to this BSSID to prefer it |
| 2235 | * @raise_rssi_thresh_5g: The RSSI threshold below which the |
| 2236 | * raise_factor_5g (boost factor) should be |
| 2237 | * applied. |
| 2238 | * @drop_rssi_thresh_5g: The RSSI threshold beyond which the |
| 2239 | * drop_factor_5g (penalty factor) should be |
| 2240 | * applied |
| 2241 | * @raise_rssi_type_5g: Algorithm to apply the boost factor |
| 2242 | * @raise_factor_5g: Boost factor |
| 2243 | * @drop_rssi_type_5g: Algorithm to apply the penalty factor |
| 2244 | * @drop_factor_5g: Penalty factor |
| 2245 | * @max_raise_rssi_5g: Maximum amount of Boost that can added |
| 2246 | * @max_drop_rssi_5g: Maximum amount of penalty that can be subtracted |
| 2247 | * @good_rssi_threshold: The Lookup UP threshold beyond which roaming |
| 2248 | * scan should be performed. |
| 2249 | * @rssi_diff: RSSI difference for the AP to be better over the |
| 2250 | * current AP to avoid ping pong effects |
| 2251 | * @good_rssi_roam: Lazy Roam |
Varun Reddy Yeturu | faad37e | 2017-07-26 10:54:13 -0700 | [diff] [blame] | 2252 | * @bg_scan_bad_rssi_thresh: Bad RSSI threshold to perform bg scan. |
Vignesh Viswanathan | c018e98 | 2017-09-07 18:49:19 +0530 | [diff] [blame] | 2253 | * @bad_rssi_thresh_offset_2g: Offset from Bad RSSI threshold for 2G to 5G Roam |
Varun Reddy Yeturu | faad37e | 2017-07-26 10:54:13 -0700 | [diff] [blame] | 2254 | * @bg_scan_client_bitmap: Bitmap to identify the client scans to snoop. |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2255 | * |
| 2256 | * This structure holds all the key parameters related to |
| 2257 | * initial connection and also roaming connections. |
| 2258 | * */ |
| 2259 | struct roam_ext_params { |
| 2260 | uint8_t num_bssid_avoid_list; |
| 2261 | uint8_t num_ssid_allowed_list; |
| 2262 | uint8_t num_bssid_favored; |
| 2263 | tSirMacSSid ssid_allowed_list[MAX_SSID_ALLOWED_LIST]; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2264 | struct qdf_mac_addr bssid_avoid_list[MAX_BSSID_AVOID_LIST]; |
| 2265 | struct qdf_mac_addr bssid_favored[MAX_BSSID_FAVORED]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2266 | uint8_t bssid_favored_factor[MAX_BSSID_FAVORED]; |
| 2267 | int raise_rssi_thresh_5g; |
| 2268 | int drop_rssi_thresh_5g; |
| 2269 | uint8_t raise_rssi_type_5g; |
| 2270 | uint8_t raise_factor_5g; |
| 2271 | uint8_t drop_rssi_type_5g; |
| 2272 | uint8_t drop_factor_5g; |
| 2273 | int max_raise_rssi_5g; |
| 2274 | int max_drop_rssi_5g; |
| 2275 | int alert_rssi_threshold; |
| 2276 | int rssi_diff; |
| 2277 | int good_rssi_roam; |
Gupta, Kapil | c68ad46 | 2016-02-01 19:17:23 +0530 | [diff] [blame] | 2278 | int dense_rssi_thresh_offset; |
| 2279 | int dense_min_aps_cnt; |
| 2280 | int initial_dense_status; |
| 2281 | int traffic_threshold; |
Abhishek Singh | 4db8c15 | 2017-07-18 10:40:08 +0530 | [diff] [blame] | 2282 | uint8_t num_rssi_rejection_ap; |
| 2283 | struct rssi_disallow_bssid rssi_rejection_ap[MAX_RSSI_AVOID_BSSID_LIST]; |
Varun Reddy Yeturu | faad37e | 2017-07-26 10:54:13 -0700 | [diff] [blame] | 2284 | int8_t bg_scan_bad_rssi_thresh; |
Vignesh Viswanathan | c018e98 | 2017-09-07 18:49:19 +0530 | [diff] [blame] | 2285 | uint8_t roam_bad_rssi_thresh_offset_2g; |
Varun Reddy Yeturu | faad37e | 2017-07-26 10:54:13 -0700 | [diff] [blame] | 2286 | uint32_t bg_scan_client_bitmap; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2287 | }; |
| 2288 | |
Deepak Dhamdhere | 828f189 | 2017-02-09 11:51:19 -0800 | [diff] [blame] | 2289 | /** |
| 2290 | * struct pmkid_mode_bits - Bit flags for PMKID usage in RSN IE |
| 2291 | * @fw_okc: Opportunistic key caching enable in firmware |
| 2292 | * @fw_pmksa_cache: PMKSA caching enable in firmware, remember previously |
| 2293 | * visited BSSID/PMK pairs |
| 2294 | */ |
| 2295 | struct pmkid_mode_bits { |
| 2296 | uint32_t fw_okc:1; |
| 2297 | uint32_t fw_pmksa_cache:1; |
| 2298 | uint32_t unused:30; |
| 2299 | }; |
| 2300 | |
Selvaraj, Sridhar | 57ce4df | 2017-05-29 18:30:49 +0530 | [diff] [blame] | 2301 | /** |
| 2302 | * struct lca_disallow_config_params - LCA[Last Connected AP] |
| 2303 | * disallow config params |
| 2304 | * @disallow_duration: LCA AP disallowed duration |
| 2305 | * @rssi_channel_penalization: RSSI channel Penalization |
| 2306 | * @num_disallowed_aps: Maximum number of AP's in LCA list |
| 2307 | * |
| 2308 | */ |
Srinivas Girigowda | ea4d806 | 2017-10-14 12:40:48 -0700 | [diff] [blame] | 2309 | struct lca_disallow_config_params { |
Selvaraj, Sridhar | 57ce4df | 2017-05-29 18:30:49 +0530 | [diff] [blame] | 2310 | uint32_t disallow_duration; |
| 2311 | uint32_t rssi_channel_penalization; |
| 2312 | uint32_t num_disallowed_aps; |
| 2313 | }; |
| 2314 | |
Varun Reddy Yeturu | 061d4d6 | 2017-07-20 09:39:32 -0700 | [diff] [blame] | 2315 | /** |
| 2316 | * struct mawc_params - Motion Aided Wireless Connectivity configuration |
Wu Gao | ca416ff | 2018-09-17 11:05:07 +0800 | [diff] [blame] | 2317 | * @mawc_enabled: Global configuration for MAWC (Roaming/PNO/ExtScan) |
Varun Reddy Yeturu | 061d4d6 | 2017-07-20 09:39:32 -0700 | [diff] [blame] | 2318 | * @mawc_roam_enabled: MAWC roaming enable/disable |
| 2319 | * @mawc_roam_traffic_threshold: Traffic threshold in kBps for MAWC roaming |
| 2320 | * @mawc_roam_ap_rssi_threshold: AP RSSI threshold for MAWC roaming |
| 2321 | * @mawc_roam_rssi_high_adjust: High Adjustment value for suppressing scan |
| 2322 | * @mawc_roam_rssi_low_adjust: Low Adjustment value for suppressing scan |
| 2323 | */ |
| 2324 | struct mawc_params { |
| 2325 | bool mawc_enabled; |
| 2326 | bool mawc_roam_enabled; |
| 2327 | uint32_t mawc_roam_traffic_threshold; |
| 2328 | int8_t mawc_roam_ap_rssi_threshold; |
| 2329 | uint8_t mawc_roam_rssi_high_adjust; |
| 2330 | uint8_t mawc_roam_rssi_low_adjust; |
| 2331 | }; |
| 2332 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2333 | typedef struct sSirRoamOffloadScanReq { |
Selvaraj, Sridhar | 0174182 | 2016-08-30 18:26:19 +0530 | [diff] [blame] | 2334 | uint16_t message_type; |
| 2335 | uint16_t length; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2336 | bool RoamScanOffloadEnabled; |
Varun Reddy Yeturu | 061d4d6 | 2017-07-20 09:39:32 -0700 | [diff] [blame] | 2337 | struct mawc_params mawc_roam_params; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2338 | int8_t LookupThreshold; |
Varun Reddy Yeturu | 168134f | 2017-06-26 13:46:05 -0700 | [diff] [blame] | 2339 | int8_t rssi_thresh_offset_5g; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2340 | uint8_t delay_before_vdev_stop; |
| 2341 | uint8_t OpportunisticScanThresholdDiff; |
| 2342 | uint8_t RoamRescanRssiDiff; |
| 2343 | uint8_t RoamRssiDiff; |
gaurank kathpalia | c63859d | 2018-05-03 18:48:41 +0530 | [diff] [blame] | 2344 | struct rsn_caps rsn_caps; |
Abhishek Singh | 34c0e63 | 2017-09-28 14:39:29 +0530 | [diff] [blame] | 2345 | int32_t rssi_abs_thresh; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2346 | uint8_t ChannelCacheType; |
| 2347 | uint8_t Command; |
| 2348 | uint8_t reason; |
| 2349 | uint16_t NeighborScanTimerPeriod; |
Sridhar Selvaraj | 1b2330c | 2017-07-21 15:16:42 +0530 | [diff] [blame] | 2350 | uint16_t neighbor_scan_min_timer_period; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2351 | uint16_t NeighborScanChannelMinTime; |
| 2352 | uint16_t NeighborScanChannelMaxTime; |
| 2353 | uint16_t EmptyRefreshScanPeriod; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2354 | bool IsESEAssoc; |
Abhinav Kumar | 271f063 | 2018-03-29 16:01:30 +0530 | [diff] [blame] | 2355 | bool is_11r_assoc; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2356 | uint8_t nProbes; |
| 2357 | uint16_t HomeAwayTime; |
| 2358 | tSirRoamNetworkType ConnectedNetwork; |
Jeff Johnson | 9e76083 | 2018-12-15 12:41:36 -0800 | [diff] [blame] | 2359 | struct mobility_domain_info mdid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2360 | uint8_t sessionId; |
| 2361 | uint8_t RoamBmissFirstBcnt; |
| 2362 | uint8_t RoamBmissFinalBcnt; |
| 2363 | uint8_t RoamBeaconRssiWeight; |
| 2364 | eSirDFSRoamScanMode allowDFSChannelRoam; |
| 2365 | #ifdef WLAN_FEATURE_ROAM_OFFLOAD |
Jianmin Zhu | bf84593 | 2018-12-17 11:52:50 +0800 | [diff] [blame] | 2366 | uint8_t roam_offload_enabled; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2367 | uint8_t PSK_PMK[SIR_ROAM_SCAN_PSK_SIZE]; |
| 2368 | uint32_t pmk_len; |
| 2369 | uint8_t Prefer5GHz; |
| 2370 | uint8_t RoamRssiCatGap; |
| 2371 | uint8_t Select5GHzMargin; |
| 2372 | uint8_t KRK[SIR_KRK_KEY_LEN]; |
| 2373 | uint8_t BTK[SIR_BTK_KEY_LEN]; |
| 2374 | uint32_t ReassocFailureTimeout; |
| 2375 | tSirAcUapsd AcUapsd; |
| 2376 | uint8_t R0KH_ID[SIR_ROAM_R0KH_ID_MAX_LEN]; |
| 2377 | uint32_t R0KH_ID_Length; |
| 2378 | uint8_t RoamKeyMgmtOffloadEnabled; |
Deepak Dhamdhere | 828f189 | 2017-02-09 11:51:19 -0800 | [diff] [blame] | 2379 | struct pmkid_mode_bits pmkid_modes; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2380 | #endif |
| 2381 | struct roam_ext_params roam_params; |
| 2382 | uint8_t middle_of_roaming; |
| 2383 | uint32_t hi_rssi_scan_max_count; |
| 2384 | uint32_t hi_rssi_scan_rssi_delta; |
| 2385 | uint32_t hi_rssi_scan_delay; |
| 2386 | int32_t hi_rssi_scan_rssi_ub; |
Varun Reddy Yeturu | 0518629 | 2015-09-28 17:12:33 -0700 | [diff] [blame] | 2387 | uint8_t early_stop_scan_enable; |
| 2388 | int8_t early_stop_scan_min_threshold; |
| 2389 | int8_t early_stop_scan_max_threshold; |
Sandeep Puligilla | f5ccbf6 | 2018-03-26 16:37:05 -0700 | [diff] [blame] | 2390 | enum scan_dwelltime_adaptive_mode roamscan_adaptive_dwell_mode; |
Selvaraj, Sridhar | a7fc763 | 2016-09-04 13:13:38 +0530 | [diff] [blame] | 2391 | tSirAddie assoc_ie; |
Selvaraj, Sridhar | 57ce4df | 2017-05-29 18:30:49 +0530 | [diff] [blame] | 2392 | struct lca_disallow_config_params lca_config_params; |
Himanshu Agarwal | 8bcec57 | 2017-09-28 11:54:37 +0530 | [diff] [blame] | 2393 | struct scoring_param score_params; |
Vignesh Viswanathan | c6d1e1c | 2017-09-18 12:32:49 +0530 | [diff] [blame] | 2394 | #ifdef WLAN_FEATURE_FILS_SK |
| 2395 | bool is_fils_connection; |
| 2396 | struct roam_fils_params roam_fils_params; |
| 2397 | #endif |
yeshwanth sriram guntuka | 41f936c | 2017-09-01 17:53:49 +0530 | [diff] [blame] | 2398 | uint32_t btm_offload_config; |
Jiachao Wu | 84bb2ea | 2018-01-08 16:17:33 +0800 | [diff] [blame] | 2399 | uint32_t btm_solicited_timeout; |
| 2400 | uint32_t btm_max_attempt_cnt; |
| 2401 | uint32_t btm_sticky_time; |
Vignesh Viswanathan | fb9d075 | 2018-02-06 16:19:00 +0530 | [diff] [blame] | 2402 | struct wmi_11k_offload_params offload_11k_params; |
Abhinav Kumar | a083f21 | 2018-04-05 18:49:45 +0530 | [diff] [blame] | 2403 | uint32_t ho_delay_for_rx; |
Sourav Mohapatra | 5ba8da3 | 2018-07-16 09:21:15 +0530 | [diff] [blame] | 2404 | uint32_t roam_preauth_retry_count; |
| 2405 | uint32_t roam_preauth_no_ack_timeout; |
Abhinav Kumar | a95af7c | 2018-04-06 17:08:00 +0530 | [diff] [blame] | 2406 | uint32_t min_delay_btw_roam_scans; |
| 2407 | uint32_t roam_trigger_reason_bitmask; |
Abhinav Kumar | edd1d37 | 2018-05-11 15:33:35 +0530 | [diff] [blame] | 2408 | bool roam_force_rssi_trigger; |
Pragaspathi Thilagaraj | 69f0b69 | 2018-12-16 22:23:04 +0530 | [diff] [blame^] | 2409 | /* bss load triggered roam related params */ |
| 2410 | bool bss_load_trig_enabled; |
| 2411 | struct wmi_bss_load_config bss_load_config; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2412 | } tSirRoamOffloadScanReq, *tpSirRoamOffloadScanReq; |
| 2413 | |
| 2414 | typedef struct sSirRoamOffloadScanRsp { |
| 2415 | uint8_t sessionId; |
| 2416 | uint32_t reason; |
| 2417 | } tSirRoamOffloadScanRsp, *tpSirRoamOffloadScanRsp; |
| 2418 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2419 | /*--------------------------------------------------------------------------- |
| 2420 | Packet Filtering Parameters |
| 2421 | ---------------------------------------------------------------------------*/ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2422 | #define SIR_MAX_FILTER_TEST_DATA_LEN 8 |
Dustin Brown | 4d1e846 | 2016-12-14 12:12:24 -0800 | [diff] [blame] | 2423 | #define SIR_MAX_FILTER_TEST_DATA_OFFSET 200 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2424 | #define SIR_MAX_NUM_MULTICAST_ADDRESS 240 |
| 2425 | #define SIR_MAX_NUM_FILTERS 20 |
| 2426 | #define SIR_MAX_NUM_TESTS_PER_FILTER 10 |
| 2427 | |
Qiwei Cai | 4505fc6 | 2018-05-17 18:35:19 +0800 | [diff] [blame] | 2428 | #ifdef WLAN_FEATURE_PACKET_FILTERING |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2429 | /* */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2430 | /* Filter Packet Match Count Parameters */ |
| 2431 | /* */ |
| 2432 | typedef struct sSirRcvFltPktMatchCnt { |
| 2433 | uint8_t filterId; |
| 2434 | uint32_t matchCnt; |
| 2435 | } tSirRcvFltPktMatchCnt, tpSirRcvFltPktMatchCnt; |
| 2436 | |
| 2437 | typedef struct sSirRcvFltPktMatchRsp { |
| 2438 | uint16_t mesgType; |
| 2439 | uint16_t mesgLen; |
| 2440 | |
| 2441 | /* Success or Failure */ |
| 2442 | uint32_t status; |
| 2443 | tSirRcvFltPktMatchCnt filterMatchCnt[SIR_MAX_NUM_FILTERS]; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2444 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2445 | } tSirRcvFltPktMatchRsp, *tpSirRcvFltPktMatchRsp; |
| 2446 | |
| 2447 | /* */ |
| 2448 | /* Receive Filter Clear Parameters */ |
| 2449 | /* */ |
| 2450 | typedef struct sSirRcvFltPktClearParam { |
| 2451 | uint32_t status; /* only valid for response message */ |
| 2452 | uint8_t filterId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2453 | struct qdf_mac_addr self_macaddr; |
| 2454 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2455 | } tSirRcvFltPktClearParam, *tpSirRcvFltPktClearParam; |
Qiwei Cai | 4505fc6 | 2018-05-17 18:35:19 +0800 | [diff] [blame] | 2456 | #endif /* WLAN_FEATURE_PACKET_FILTERING */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2457 | |
| 2458 | /* */ |
| 2459 | /* Multicast Address List Parameters */ |
| 2460 | /* */ |
| 2461 | typedef struct sSirRcvFltMcAddrList { |
| 2462 | uint32_t ulMulticastAddrCnt; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2463 | struct qdf_mac_addr multicastAddr[SIR_MAX_NUM_MULTICAST_ADDRESS]; |
| 2464 | struct qdf_mac_addr self_macaddr; |
| 2465 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2466 | uint8_t action; |
| 2467 | } tSirRcvFltMcAddrList, *tpSirRcvFltMcAddrList; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2468 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2469 | /** |
| 2470 | * struct sir_wifi_start_log - Structure to store the params sent to start/ |
| 2471 | * stop logging |
| 2472 | * @name: Attribute which indicates the type of logging like per packet |
| 2473 | * statistics, connectivity etc. |
| 2474 | * @verbose_level: Verbose level which can be 0,1,2,3 |
Poddar, Siddarth | eefe348 | 2016-09-21 18:12:59 +0530 | [diff] [blame] | 2475 | * @is_iwpriv_command: Set 1 for iwpriv command |
Srinivas Girigowda | c34f11d | 2016-02-25 16:02:42 -0800 | [diff] [blame] | 2476 | * @ini_triggered: triggered using ini |
| 2477 | * @user_triggered: triggered by user |
Poddar, Siddarth | 176c436 | 2016-10-03 12:25:00 +0530 | [diff] [blame] | 2478 | * @size: pktlog buffer size |
Poddar, Siddarth | ab99a27 | 2017-04-10 12:53:26 +0530 | [diff] [blame] | 2479 | * @is_pktlog_buff_clear: clear the pktlog buffer |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2480 | */ |
| 2481 | struct sir_wifi_start_log { |
| 2482 | uint32_t ring_id; |
| 2483 | uint32_t verbose_level; |
Poddar, Siddarth | eefe348 | 2016-09-21 18:12:59 +0530 | [diff] [blame] | 2484 | uint32_t is_iwpriv_command; |
Srinivas Girigowda | c34f11d | 2016-02-25 16:02:42 -0800 | [diff] [blame] | 2485 | bool ini_triggered; |
| 2486 | uint8_t user_triggered; |
Poddar, Siddarth | 176c436 | 2016-10-03 12:25:00 +0530 | [diff] [blame] | 2487 | int size; |
Poddar, Siddarth | ab99a27 | 2017-04-10 12:53:26 +0530 | [diff] [blame] | 2488 | bool is_pktlog_buff_clear; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2489 | }; |
| 2490 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2491 | |
| 2492 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2493 | * struct sir_pcl_list - Format of PCL |
| 2494 | * @pcl_list: List of preferred channels |
Manishekar Chandrasekaran | 7009f25 | 2016-04-21 19:14:15 +0530 | [diff] [blame] | 2495 | * @weight_list: Weights of the PCL |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2496 | * @pcl_len: Number of channels in the PCL |
| 2497 | */ |
| 2498 | struct sir_pcl_list { |
Rajeev Kumar Sirasanagandla | 4133d86 | 2018-08-23 12:21:36 +0530 | [diff] [blame] | 2499 | uint32_t pcl_len; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2500 | uint8_t pcl_list[128]; |
Manishekar Chandrasekaran | 7009f25 | 2016-04-21 19:14:15 +0530 | [diff] [blame] | 2501 | uint8_t weight_list[128]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2502 | }; |
| 2503 | |
| 2504 | /** |
Manishekar Chandrasekaran | 7009f25 | 2016-04-21 19:14:15 +0530 | [diff] [blame] | 2505 | * struct sir_pcl_chan_weights - Params to get the valid weighed list |
| 2506 | * @pcl_list: Preferred channel list already sorted in the order of preference |
| 2507 | * @pcl_len: Length of the PCL |
| 2508 | * @saved_chan_list: Valid channel list updated as part of |
| 2509 | * WMA_UPDATE_CHAN_LIST_REQ |
| 2510 | * @saved_num_chan: Length of the valid channel list |
| 2511 | * @weighed_valid_list: Weights of the valid channel list. This will have one |
| 2512 | * to one mapping with valid_chan_list. FW expects channel order and size to be |
| 2513 | * as per the list provided in WMI_SCAN_CHAN_LIST_CMDID. |
| 2514 | * @weight_list: Weights assigned by policy manager |
| 2515 | */ |
| 2516 | struct sir_pcl_chan_weights { |
| 2517 | uint8_t pcl_list[128]; |
| 2518 | uint32_t pcl_len; |
| 2519 | uint8_t saved_chan_list[128]; |
| 2520 | uint32_t saved_num_chan; |
| 2521 | uint8_t weighed_valid_list[128]; |
| 2522 | uint8_t weight_list[128]; |
| 2523 | }; |
| 2524 | |
| 2525 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2526 | * struct sir_hw_mode_params - HW mode params |
| 2527 | * @mac0_tx_ss: MAC0 Tx spatial stream |
| 2528 | * @mac0_rx_ss: MAC0 Rx spatial stream |
| 2529 | * @mac1_tx_ss: MAC1 Tx spatial stream |
| 2530 | * @mac1_rx_ss: MAC1 Rx spatial stream |
| 2531 | * @mac0_bw: MAC0 bandwidth |
| 2532 | * @mac1_bw: MAC1 bandwidth |
| 2533 | * @dbs_cap: DBS capabality |
| 2534 | * @agile_dfs_cap: Agile DFS capabality |
| 2535 | */ |
| 2536 | struct sir_hw_mode_params { |
| 2537 | uint8_t mac0_tx_ss; |
| 2538 | uint8_t mac0_rx_ss; |
| 2539 | uint8_t mac1_tx_ss; |
| 2540 | uint8_t mac1_rx_ss; |
| 2541 | uint8_t mac0_bw; |
| 2542 | uint8_t mac1_bw; |
| 2543 | uint8_t dbs_cap; |
| 2544 | uint8_t agile_dfs_cap; |
Nitesh Shah | 5b7bae0 | 2016-09-28 18:58:33 +0530 | [diff] [blame] | 2545 | uint8_t sbs_cap; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2546 | }; |
| 2547 | |
| 2548 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2549 | * struct sir_set_hw_mode_resp - HW mode response |
| 2550 | * @status: Status |
| 2551 | * @cfgd_hw_mode_index: Configured HW mode index |
| 2552 | * @num_vdev_mac_entries: Number of vdev-mac id entries |
| 2553 | * @vdev_mac_map: vdev id-mac id map |
| 2554 | */ |
| 2555 | struct sir_set_hw_mode_resp { |
| 2556 | uint32_t status; |
| 2557 | uint32_t cfgd_hw_mode_index; |
| 2558 | uint32_t num_vdev_mac_entries; |
Tushnim Bhattacharyya | eab33dd | 2017-11-15 15:20:02 -0800 | [diff] [blame] | 2559 | struct policy_mgr_vdev_mac_map vdev_mac_map[MAX_VDEV_SUPPORTED]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2560 | }; |
| 2561 | |
| 2562 | /** |
| 2563 | * struct sir_hw_mode_trans_ind - HW mode transition indication |
| 2564 | * @old_hw_mode_index: Index of old HW mode |
| 2565 | * @new_hw_mode_index: Index of new HW mode |
| 2566 | * @num_vdev_mac_entries: Number of vdev-mac id entries |
| 2567 | * @vdev_mac_map: vdev id-mac id map |
| 2568 | */ |
| 2569 | struct sir_hw_mode_trans_ind { |
| 2570 | uint32_t old_hw_mode_index; |
| 2571 | uint32_t new_hw_mode_index; |
| 2572 | uint32_t num_vdev_mac_entries; |
Tushnim Bhattacharyya | 0c4ad2d | 2017-03-09 15:59:03 -0800 | [diff] [blame] | 2573 | struct policy_mgr_vdev_mac_map vdev_mac_map[MAX_VDEV_SUPPORTED]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2574 | }; |
| 2575 | |
| 2576 | /** |
| 2577 | * struct sir_dual_mac_config_resp - Dual MAC config response |
| 2578 | * @status: Status of setting the dual mac configuration |
| 2579 | */ |
| 2580 | struct sir_dual_mac_config_resp { |
| 2581 | uint32_t status; |
| 2582 | }; |
| 2583 | |
Archana Ramachandran | d41c3ed | 2016-02-10 15:48:06 -0800 | [diff] [blame] | 2584 | /** |
| 2585 | * enum set_antenna_mode_status - Status of set antenna mode |
| 2586 | * command |
| 2587 | * @SET_ANTENNA_MODE_STATUS_OK: command successful |
| 2588 | * @SET_ANTENNA_MODE_STATUS_EINVAL: invalid antenna mode |
| 2589 | * @SET_ANTENNA_MODE_STATUS_ECANCELED: mode change cancelled |
| 2590 | * @SET_ANTENNA_MODE_STATUS_ENOTSUP: mode not supported |
| 2591 | */ |
| 2592 | enum set_antenna_mode_status { |
| 2593 | SET_ANTENNA_MODE_STATUS_OK, |
| 2594 | SET_ANTENNA_MODE_STATUS_EINVAL, |
| 2595 | SET_ANTENNA_MODE_STATUS_ECANCELED, |
| 2596 | SET_ANTENNA_MODE_STATUS_ENOTSUP, |
| 2597 | }; |
| 2598 | |
| 2599 | /** |
| 2600 | * struct sir_antenna_mode_resp - set antenna mode response |
| 2601 | * @status: Status of setting the antenna mode |
| 2602 | */ |
| 2603 | struct sir_antenna_mode_resp { |
| 2604 | enum set_antenna_mode_status status; |
| 2605 | }; |
| 2606 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2607 | #ifdef FEATURE_WLAN_TDLS |
| 2608 | /* TDLS Request struct SME-->PE */ |
| 2609 | typedef struct sSirTdlsSendMgmtReq { |
| 2610 | uint16_t messageType; /* eWNI_SME_TDLS_DISCOVERY_START_REQ */ |
| 2611 | uint16_t length; |
| 2612 | uint8_t sessionId; /* Session ID */ |
| 2613 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 2614 | uint8_t reqType; |
| 2615 | uint8_t dialog; |
| 2616 | uint16_t statusCode; |
| 2617 | uint8_t responder; |
| 2618 | uint32_t peerCapability; |
| 2619 | /* For multi-session, for PE to locate peSession ID */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2620 | struct qdf_mac_addr bssid; |
| 2621 | struct qdf_mac_addr peer_mac; |
Ganesh Kondabattini | dd72652 | 2017-05-10 18:09:37 +0530 | [diff] [blame] | 2622 | enum wifi_traffic_ac ac; |
Srinivas Girigowda | a9d12f1 | 2015-11-24 11:26:40 -0800 | [diff] [blame] | 2623 | /* Variable length. Dont add any field after this. */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2624 | uint8_t addIe[1]; |
| 2625 | } tSirTdlsSendMgmtReq, *tpSirSmeTdlsSendMgmtReq; |
| 2626 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2627 | /* TDLS Request struct SME-->PE */ |
| 2628 | typedef struct sSirTdlsAddStaReq { |
| 2629 | uint16_t messageType; /* eWNI_SME_TDLS_DISCOVERY_START_REQ */ |
| 2630 | uint16_t length; |
| 2631 | uint8_t sessionId; /* Session ID */ |
| 2632 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 2633 | /* For multi-session, for PE to locate peSession ID */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2634 | struct qdf_mac_addr bssid; |
Bala Venkatesh | 4a72b06 | 2018-11-13 13:04:49 +0530 | [diff] [blame] | 2635 | enum tdls_add_oper tdlsAddOper; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2636 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2637 | uint16_t capability; |
| 2638 | uint8_t extn_capability[SIR_MAC_MAX_EXTN_CAP]; |
| 2639 | uint8_t supported_rates_length; |
| 2640 | uint8_t supported_rates[SIR_MAC_MAX_SUPP_RATES]; |
| 2641 | uint8_t htcap_present; |
Bala Venkatesh | 02d5235 | 2018-11-26 15:12:58 +0530 | [diff] [blame] | 2642 | struct htcap_cmn_ie htCap; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2643 | uint8_t vhtcap_present; |
| 2644 | tSirVHTCap vhtCap; |
| 2645 | uint8_t uapsd_queues; |
| 2646 | uint8_t max_sp; |
| 2647 | } tSirTdlsAddStaReq, *tpSirSmeTdlsAddStaReq; |
| 2648 | |
| 2649 | /* TDLS Response struct PE-->SME */ |
| 2650 | typedef struct sSirTdlsAddStaRsp { |
| 2651 | uint16_t messageType; |
| 2652 | uint16_t length; |
| 2653 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2654 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2655 | uint8_t sessionId; /* Session ID */ |
| 2656 | uint16_t staId; |
| 2657 | uint16_t staType; |
Bala Venkatesh | 4a72b06 | 2018-11-13 13:04:49 +0530 | [diff] [blame] | 2658 | enum tdls_add_oper tdlsAddOper; |
Frank Liu | d4b2fa0 | 2017-03-29 11:46:48 +0800 | [diff] [blame] | 2659 | struct wlan_objmgr_psoc *psoc; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2660 | } tSirTdlsAddStaRsp; |
| 2661 | |
| 2662 | /* TDLS Request struct SME-->PE */ |
| 2663 | typedef struct { |
| 2664 | uint16_t messageType; /* eWNI_SME_TDLS_LINK_ESTABLISH_REQ */ |
| 2665 | uint16_t length; |
| 2666 | uint8_t sessionId; /* Session ID */ |
| 2667 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 2668 | uint8_t uapsdQueues; /* Peer's uapsd Queues Information */ |
| 2669 | uint8_t maxSp; /* Peer's Supported Maximum Service Period */ |
| 2670 | uint8_t isBufSta; /* Does Peer Support as Buffer Station. */ |
| 2671 | /* Does Peer Support as TDLS Off Channel. */ |
| 2672 | uint8_t isOffChannelSupported; |
| 2673 | uint8_t isResponder; /* Is Peer a responder. */ |
| 2674 | /* For multi-session, for PE to locate peSession ID */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2675 | struct qdf_mac_addr bssid; |
| 2676 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2677 | uint8_t supportedChannelsLen; |
| 2678 | uint8_t supportedChannels[SIR_MAC_MAX_SUPP_CHANNELS]; |
| 2679 | uint8_t supportedOperClassesLen; |
Kiran Kumar Lokere | a3de226 | 2017-04-12 12:15:04 -0700 | [diff] [blame] | 2680 | uint8_t supportedOperClasses[REG_MAX_SUPP_OPER_CLASSES]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2681 | } tSirTdlsLinkEstablishReq, *tpSirTdlsLinkEstablishReq; |
| 2682 | |
| 2683 | /* TDLS Request struct SME-->PE */ |
| 2684 | typedef struct { |
| 2685 | uint16_t messageType; /* eWNI_SME_TDLS_LINK_ESTABLISH_RSP */ |
| 2686 | uint16_t length; |
| 2687 | uint8_t sessionId; /* Session ID */ |
| 2688 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 2689 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2690 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2691 | } tSirTdlsLinkEstablishReqRsp, *tpSirTdlsLinkEstablishReqRsp; |
| 2692 | |
| 2693 | /* TDLS Request struct SME-->PE */ |
| 2694 | typedef struct sSirTdlsDelStaReq { |
| 2695 | uint16_t messageType; /* eWNI_SME_TDLS_DISCOVERY_START_REQ */ |
| 2696 | uint16_t length; |
| 2697 | uint8_t sessionId; /* Session ID */ |
| 2698 | uint16_t transactionId; /* Transaction ID for cmd */ |
| 2699 | /* For multi-session, for PE to locate peSession ID */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2700 | struct qdf_mac_addr bssid; |
| 2701 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2702 | } tSirTdlsDelStaReq, *tpSirSmeTdlsDelStaReq; |
| 2703 | /* TDLS Response struct PE-->SME */ |
| 2704 | typedef struct sSirTdlsDelStaRsp { |
| 2705 | uint16_t messageType; |
| 2706 | uint16_t length; |
| 2707 | uint8_t sessionId; /* Session ID */ |
| 2708 | tSirResultCodes statusCode; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2709 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2710 | uint16_t staId; |
Frank Liu | d4b2fa0 | 2017-03-29 11:46:48 +0800 | [diff] [blame] | 2711 | struct wlan_objmgr_psoc *psoc; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2712 | } tSirTdlsDelStaRsp, *tpSirTdlsDelStaRsp; |
| 2713 | /* TDLS Delete Indication struct PE-->SME */ |
| 2714 | typedef struct sSirTdlsDelStaInd { |
| 2715 | uint16_t messageType; |
| 2716 | uint16_t length; |
| 2717 | uint8_t sessionId; /* Session ID */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2718 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2719 | uint16_t staId; |
| 2720 | uint16_t reasonCode; |
| 2721 | } tSirTdlsDelStaInd, *tpSirTdlsDelStaInd; |
| 2722 | typedef struct sSirTdlsDelAllPeerInd { |
| 2723 | uint16_t messageType; |
| 2724 | uint16_t length; |
| 2725 | uint8_t sessionId; /* Session ID */ |
| 2726 | } tSirTdlsDelAllPeerInd, *tpSirTdlsDelAllPeerInd; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2727 | typedef struct sSirMgmtTxCompletionInd { |
| 2728 | uint16_t messageType; |
| 2729 | uint16_t length; |
| 2730 | uint8_t sessionId; /* Session ID */ |
| 2731 | uint32_t txCompleteStatus; |
Kabilan Kannan | f56f9d5 | 2017-04-05 03:31:34 -0700 | [diff] [blame] | 2732 | struct wlan_objmgr_psoc *psoc; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2733 | } tSirMgmtTxCompletionInd, *tpSirMgmtTxCompletionInd; |
| 2734 | |
| 2735 | typedef struct sSirTdlsEventnotify { |
| 2736 | uint8_t sessionId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2737 | struct qdf_mac_addr peermac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2738 | uint16_t messageType; |
| 2739 | uint32_t peer_reason; |
| 2740 | } tSirTdlsEventnotify; |
| 2741 | #endif /* FEATURE_WLAN_TDLS */ |
| 2742 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2743 | /* Reset AP Caps Changed */ |
| 2744 | typedef struct sSirResetAPCapsChange { |
| 2745 | uint16_t messageType; |
| 2746 | uint16_t length; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2747 | struct qdf_mac_addr bssId; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2748 | } tSirResetAPCapsChange, *tpSirResetAPCapsChange; |
| 2749 | |
| 2750 | /* / Definition for Candidate found indication from FW */ |
| 2751 | typedef struct sSirSmeCandidateFoundInd { |
| 2752 | uint16_t messageType; /* eWNI_SME_CANDIDATE_FOUND_IND */ |
| 2753 | uint16_t length; |
| 2754 | uint8_t sessionId; /* Session Identifier */ |
| 2755 | } tSirSmeCandidateFoundInd, *tpSirSmeCandidateFoundInd; |
| 2756 | |
| 2757 | #ifdef WLAN_FEATURE_11W |
| 2758 | typedef struct sSirWlanExcludeUnencryptParam { |
| 2759 | bool excludeUnencrypt; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2760 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2761 | } tSirWlanExcludeUnencryptParam, *tpSirWlanExcludeUnencryptParam; |
| 2762 | #endif |
| 2763 | |
| 2764 | typedef enum { |
| 2765 | P2P_SCAN_TYPE_SEARCH = 1, /* P2P Search */ |
| 2766 | P2P_SCAN_TYPE_LISTEN /* P2P Listen */ |
| 2767 | } tSirP2pScanType; |
| 2768 | |
| 2769 | typedef struct sAniHandoffReq { |
| 2770 | /* Common for all types are requests */ |
| 2771 | uint16_t msgType; /* message type is same as the request type */ |
| 2772 | uint16_t msgLen; /* length of the entire request */ |
| 2773 | uint8_t sessionId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2774 | uint8_t bssid[QDF_MAC_ADDR_SIZE]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2775 | uint8_t channel; |
| 2776 | uint8_t handoff_src; |
| 2777 | } tAniHandoffReq, *tpAniHandoffReq; |
| 2778 | |
Krishna Kumaar Natarajan | 3c44355 | 2016-02-19 18:34:40 -0800 | [diff] [blame] | 2779 | /** |
Krishna Kumaar Natarajan | 3eed86b | 2016-03-25 16:55:21 -0700 | [diff] [blame] | 2780 | * sir_scan_event_type - scan event types used in LIM |
| 2781 | * @SIR_SCAN_EVENT_STARTED - scan command accepted by FW |
| 2782 | * @SIR_SCAN_EVENT_COMPLETED - scan has been completed by FW |
| 2783 | * @SIR_SCAN_EVENT_BSS_CHANNEL - FW is going to move to HOME channel |
| 2784 | * @SIR_SCAN_EVENT_FOREIGN_CHANNEL - FW is going to move to FORIEGN channel |
| 2785 | * @SIR_SCAN_EVENT_DEQUEUED - scan request got dequeued |
| 2786 | * @SIR_SCAN_EVENT_PREEMPTED - preempted by other high priority scan |
| 2787 | * @SIR_SCAN_EVENT_START_FAILED - scan start failed |
| 2788 | * @SIR_SCAN_EVENT_RESTARTED - scan restarted |
| 2789 | * @SIR_SCAN_EVENT_MAX - max value for event type |
Krishna Kumaar Natarajan | 3c44355 | 2016-02-19 18:34:40 -0800 | [diff] [blame] | 2790 | */ |
Krishna Kumaar Natarajan | 3eed86b | 2016-03-25 16:55:21 -0700 | [diff] [blame] | 2791 | enum sir_scan_event_type { |
| 2792 | SIR_SCAN_EVENT_STARTED = 0x1, |
| 2793 | SIR_SCAN_EVENT_COMPLETED = 0x2, |
| 2794 | SIR_SCAN_EVENT_BSS_CHANNEL = 0x4, |
| 2795 | SIR_SCAN_EVENT_FOREIGN_CHANNEL = 0x8, |
| 2796 | SIR_SCAN_EVENT_DEQUEUED = 0x10, |
| 2797 | SIR_SCAN_EVENT_PREEMPTED = 0x20, |
| 2798 | SIR_SCAN_EVENT_START_FAILED = 0x40, |
| 2799 | SIR_SCAN_EVENT_RESTARTED = 0x80, |
| 2800 | SIR_SCAN_EVENT_MAX = 0x8000 |
Krishna Kumaar Natarajan | 3c44355 | 2016-02-19 18:34:40 -0800 | [diff] [blame] | 2801 | }; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2802 | |
| 2803 | typedef struct sSirScanOffloadEvent { |
Krishna Kumaar Natarajan | 3eed86b | 2016-03-25 16:55:21 -0700 | [diff] [blame] | 2804 | enum sir_scan_event_type event; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2805 | tSirResultCodes reasonCode; |
| 2806 | uint32_t chanFreq; |
| 2807 | uint32_t requestor; |
| 2808 | uint32_t scanId; |
| 2809 | tSirP2pScanType p2pScanType; |
| 2810 | uint8_t sessionId; |
| 2811 | } tSirScanOffloadEvent, *tpSirScanOffloadEvent; |
| 2812 | |
| 2813 | /** |
| 2814 | * struct sSirUpdateChanParam - channel parameters |
| 2815 | * @chanId: ID of the channel |
| 2816 | * @pwr: power level |
| 2817 | * @dfsSet: is dfs supported or not |
| 2818 | * @half_rate: is the channel operating at 10MHz |
| 2819 | * @quarter_rate: is the channel operating at 5MHz |
| 2820 | */ |
| 2821 | typedef struct sSirUpdateChanParam { |
| 2822 | uint8_t chanId; |
| 2823 | uint8_t pwr; |
| 2824 | bool dfsSet; |
| 2825 | bool half_rate; |
| 2826 | bool quarter_rate; |
| 2827 | } tSirUpdateChanParam, *tpSirUpdateChanParam; |
| 2828 | |
| 2829 | typedef struct sSirUpdateChan { |
| 2830 | uint8_t numChan; |
Kiran Kumar Lokere | 666bf85 | 2016-05-02 12:23:02 -0700 | [diff] [blame] | 2831 | uint8_t ht_en; |
| 2832 | uint8_t vht_en; |
| 2833 | uint8_t vht_24_en; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2834 | tSirUpdateChanParam chanParam[1]; |
| 2835 | } tSirUpdateChanList, *tpSirUpdateChanList; |
| 2836 | |
| 2837 | typedef enum eSirAddonPsReq { |
| 2838 | eSIR_ADDON_NOTHING, |
| 2839 | eSIR_ADDON_ENABLE_UAPSD, |
| 2840 | eSIR_ADDON_DISABLE_UAPSD |
| 2841 | } tSirAddonPsReq; |
| 2842 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2843 | #ifdef FEATURE_WLAN_CH_AVOID |
| 2844 | typedef struct sSirChAvoidUpdateReq { |
| 2845 | uint32_t reserved_param; |
| 2846 | } tSirChAvoidUpdateReq; |
| 2847 | #endif /* FEATURE_WLAN_CH_AVOID */ |
| 2848 | |
| 2849 | typedef struct sSirLinkSpeedInfo { |
| 2850 | /* MAC Address for the peer */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2851 | struct qdf_mac_addr peer_macaddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2852 | uint32_t estLinkSpeed; /* Linkspeed from firmware */ |
| 2853 | } tSirLinkSpeedInfo, *tpSirLinkSpeedInfo; |
| 2854 | |
Will Huang | a981459 | 2017-05-24 15:47:58 +0800 | [diff] [blame] | 2855 | /** |
| 2856 | * struct sir_peer_info_req - peer info request struct |
| 2857 | * @peer_macaddr: MAC address |
| 2858 | * @sessionid: vdev id |
| 2859 | * |
| 2860 | * peer info request message's struct |
| 2861 | */ |
| 2862 | struct sir_peer_info_req { |
| 2863 | struct qdf_mac_addr peer_macaddr; |
| 2864 | uint8_t sessionid; |
| 2865 | }; |
| 2866 | |
| 2867 | /** |
| 2868 | * struct sir_peer_info - peer information struct |
| 2869 | * @peer_macaddr: MAC address |
| 2870 | * @rssi: rssi |
| 2871 | * @tx_rate: last tx rate |
| 2872 | * @rx_rate: last rx rate |
| 2873 | * |
| 2874 | * a station's information |
| 2875 | */ |
| 2876 | struct sir_peer_info { |
| 2877 | struct qdf_mac_addr peer_macaddr; |
| 2878 | int8_t rssi; |
| 2879 | uint32_t tx_rate; |
| 2880 | uint32_t rx_rate; |
| 2881 | }; |
| 2882 | |
| 2883 | /** |
| 2884 | * struct sir_peer_info_resp - all peers information struct |
| 2885 | * @count: peer's number |
| 2886 | * @info: peer information |
| 2887 | * |
| 2888 | * all station's information |
| 2889 | */ |
| 2890 | struct sir_peer_info_resp { |
| 2891 | uint8_t count; |
| 2892 | struct sir_peer_info info[0]; |
| 2893 | }; |
| 2894 | |
| 2895 | /** |
| 2896 | * struct sir_peer_info_ext_req - peer info request struct |
| 2897 | * @peer_macaddr: MAC address |
| 2898 | * @sessionid: vdev id |
| 2899 | * @reset_after_request: fw reset statistics after query |
| 2900 | * |
| 2901 | * peer info request message's struct |
| 2902 | */ |
| 2903 | struct sir_peer_info_ext_req { |
| 2904 | struct qdf_mac_addr peer_macaddr; |
| 2905 | uint8_t sessionid; |
| 2906 | uint8_t reset_after_request; |
| 2907 | }; |
| 2908 | |
| 2909 | /** |
| 2910 | * struct sir_peer_info_ext - peer info information struct |
| 2911 | * (refer to station_info struct in Kernel) |
| 2912 | * @peer_macaddr: MAC address |
| 2913 | * @tx_packets: packets transmitted to this station |
| 2914 | * @tx_bytes: bytes transmitted to this station |
| 2915 | * @rx_packets: packets received from this station |
| 2916 | * @rx_bytes: bytes received from this station |
| 2917 | * @rx_retries: cumulative retry counts |
| 2918 | * @tx_failed: number of failed transmissions |
| 2919 | * @rssi: The signal strength |
| 2920 | * @tx_rate: last used tx bitrate (kbps) |
| 2921 | * @tx_rate_code: last tx rate code (last_tx_rate_code of wmi_peer_stats_info) |
| 2922 | * @rx_rate: last used rx bitrate (kbps) |
| 2923 | * @rx_rate_code: last rx rate code (last_rx_rate_code of wmi_peer_stats_info) |
| 2924 | * |
| 2925 | * a station's information |
| 2926 | */ |
| 2927 | struct sir_peer_info_ext { |
| 2928 | struct qdf_mac_addr peer_macaddr; |
| 2929 | uint32_t tx_packets; |
| 2930 | uint64_t tx_bytes; |
| 2931 | uint32_t rx_packets; |
| 2932 | uint64_t rx_bytes; |
| 2933 | uint32_t tx_retries; |
| 2934 | uint32_t tx_failed; |
| 2935 | int32_t rssi; |
| 2936 | uint32_t tx_rate; |
| 2937 | uint32_t tx_rate_code; |
| 2938 | uint32_t rx_rate; |
| 2939 | uint32_t rx_rate_code; |
| 2940 | }; |
| 2941 | |
| 2942 | /** |
| 2943 | * struct sir_peer_info_ext_resp - all peers' information struct |
| 2944 | * @count: peer's number |
| 2945 | * @info: peer information |
| 2946 | * |
| 2947 | * all station's information |
| 2948 | */ |
| 2949 | struct sir_peer_info_ext_resp { |
| 2950 | uint8_t count; |
| 2951 | struct sir_peer_info_ext info[0]; |
| 2952 | }; |
| 2953 | |
Will Huang | 496b36c | 2017-07-11 16:38:50 +0800 | [diff] [blame] | 2954 | /** |
| 2955 | * @sta_num: number of peer station which has valid info |
| 2956 | * @info: peer information |
| 2957 | * |
| 2958 | * all SAP peer station's information retrieved |
| 2959 | */ |
| 2960 | struct sir_peer_sta_info { |
| 2961 | uint8_t sta_num; |
| 2962 | struct sir_peer_info info[MAX_PEER_STA]; |
| 2963 | }; |
| 2964 | |
| 2965 | /** |
| 2966 | * @sta_num: number of peer station which has valid info |
| 2967 | * @info: peer extended information |
| 2968 | * |
| 2969 | * all SAP peer station's extended information retrieved |
| 2970 | */ |
| 2971 | struct sir_peer_sta_ext_info { |
| 2972 | uint8_t sta_num; |
| 2973 | struct sir_peer_info_ext info[MAX_PEER_STA]; |
| 2974 | }; |
| 2975 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2976 | typedef struct sSirAddPeriodicTxPtrn { |
| 2977 | /* MAC Address for the adapter */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2978 | struct qdf_mac_addr mac_address; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2979 | uint8_t ucPtrnId; /* Pattern ID */ |
| 2980 | uint16_t ucPtrnSize; /* Pattern size */ |
| 2981 | uint32_t usPtrnIntervalMs; /* In msec */ |
| 2982 | uint8_t ucPattern[PERIODIC_TX_PTRN_MAX_SIZE]; /* Pattern buffer */ |
| 2983 | } tSirAddPeriodicTxPtrn, *tpSirAddPeriodicTxPtrn; |
| 2984 | |
| 2985 | typedef struct sSirDelPeriodicTxPtrn { |
| 2986 | /* MAC Address for the adapter */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 2987 | struct qdf_mac_addr mac_address; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 2988 | /* Bitmap of pattern IDs that need to be deleted */ |
| 2989 | uint32_t ucPatternIdBitmap; |
| 2990 | uint8_t ucPtrnId; /* Pattern ID */ |
| 2991 | } tSirDelPeriodicTxPtrn, *tpSirDelPeriodicTxPtrn; |
| 2992 | |
Rajeev Kumar | 8e3e283 | 2015-11-06 16:02:54 -0800 | [diff] [blame] | 2993 | /*--------------------------------------------------------------------------- |
| 2994 | * tSirIbssGetPeerInfoReqParams |
| 2995 | *--------------------------------------------------------------------------*/ |
| 2996 | typedef struct { |
| 2997 | bool allPeerInfoReqd; /* If set, all IBSS peers stats are reported */ |
| 2998 | uint8_t staIdx; /* If allPeerInfoReqd is not set, only stats */ |
| 2999 | /* of peer with staIdx is reported */ |
| 3000 | } tSirIbssGetPeerInfoReqParams, *tpSirIbssGetPeerInfoReqParams; |
| 3001 | |
Rajeev Kumar | 94c9b45 | 2016-03-24 12:58:47 -0700 | [diff] [blame] | 3002 | /** |
| 3003 | * typedef struct - tSirIbssGetPeerInfoParams |
| 3004 | * @mac_addr: mac address received from target |
| 3005 | * @txRate: TX rate |
| 3006 | * @mcsIndex: MCS index |
| 3007 | * @txRateFlags: TX rate flags |
| 3008 | * @rssi: RSSI |
| 3009 | */ |
Rajeev Kumar | 8e3e283 | 2015-11-06 16:02:54 -0800 | [diff] [blame] | 3010 | typedef struct { |
Rajeev Kumar | 94c9b45 | 2016-03-24 12:58:47 -0700 | [diff] [blame] | 3011 | uint8_t mac_addr[QDF_MAC_ADDR_SIZE]; |
| 3012 | uint32_t txRate; |
| 3013 | uint32_t mcsIndex; |
| 3014 | uint32_t txRateFlags; |
| 3015 | int8_t rssi; |
Rajeev Kumar | 8e3e283 | 2015-11-06 16:02:54 -0800 | [diff] [blame] | 3016 | } tSirIbssPeerInfoParams; |
| 3017 | |
| 3018 | typedef struct { |
| 3019 | uint32_t status; |
| 3020 | uint8_t numPeers; |
| 3021 | tSirIbssPeerInfoParams peerInfoParams[32]; |
| 3022 | } tSirPeerInfoRspParams, *tpSirIbssPeerInfoRspParams; |
| 3023 | |
| 3024 | /*--------------------------------------------------------------------------- |
| 3025 | * tSirIbssGetPeerInfoRspParams |
| 3026 | *--------------------------------------------------------------------------*/ |
| 3027 | typedef struct { |
| 3028 | uint16_t mesgType; |
| 3029 | uint16_t mesgLen; |
| 3030 | tSirPeerInfoRspParams ibssPeerInfoRspParams; |
| 3031 | } tSirIbssGetPeerInfoRspParams, *tpSirIbssGetPeerInfoRspParams; |
| 3032 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3033 | #ifdef WLAN_FEATURE_EXTWOW_SUPPORT |
| 3034 | typedef struct { |
| 3035 | uint16_t mesgType; |
| 3036 | uint16_t mesgLen; |
| 3037 | bool status; |
| 3038 | } tSirReadyToExtWoWInd, *tpSirReadyToExtWoWInd; |
| 3039 | #endif |
| 3040 | typedef struct sSirRateUpdateInd { |
| 3041 | uint8_t nss; /* 0: 1x1, 1: 2x2 */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3042 | struct qdf_mac_addr bssid; |
Jeff Johnson | c1e6278 | 2017-11-09 09:50:17 -0800 | [diff] [blame] | 3043 | enum QDF_OPMODE dev_mode; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3044 | int32_t bcastDataRate; /* bcast rate unit Mbpsx10, -1:not used */ |
| 3045 | /* |
| 3046 | * 0 implies RA, positive value implies fixed rate, -1 implies ignore |
| 3047 | * this param. |
| 3048 | */ |
| 3049 | int32_t ucastDataRate; |
| 3050 | |
| 3051 | /* TX flag to differentiate between HT20, HT40 etc */ |
Naveen Rawat | ea1564b | 2018-05-17 15:56:11 -0700 | [diff] [blame] | 3052 | enum tx_rate_info ucastDataRateTxFlag; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3053 | |
| 3054 | /* |
| 3055 | * 0 implies MCAST RA, positive value implies fixed rate, |
| 3056 | * -1 implies ignore this param |
| 3057 | */ |
| 3058 | int32_t reliableMcastDataRate; /* unit Mbpsx10 */ |
| 3059 | |
| 3060 | /* TX flag to differentiate between HT20, HT40 etc */ |
Naveen Rawat | ea1564b | 2018-05-17 15:56:11 -0700 | [diff] [blame] | 3061 | enum tx_rate_info reliableMcastDataRateTxFlag; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3062 | |
| 3063 | /* |
| 3064 | * MCAST(or BCAST) fixed data rate in 2.4 GHz, unit Mbpsx10, |
| 3065 | * 0 implies ignore |
| 3066 | */ |
| 3067 | uint32_t mcastDataRate24GHz; |
| 3068 | |
| 3069 | /* TX flag to differentiate between HT20, HT40 etc */ |
Naveen Rawat | ea1564b | 2018-05-17 15:56:11 -0700 | [diff] [blame] | 3070 | enum tx_rate_info mcastDataRate24GHzTxFlag; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3071 | |
| 3072 | /* |
| 3073 | * MCAST(or BCAST) fixed data rate in 5 GHz, |
| 3074 | * unit Mbpsx10, 0 implies ignore |
| 3075 | */ |
| 3076 | uint32_t mcastDataRate5GHz; |
| 3077 | |
| 3078 | /* TX flag to differentiate between HT20, HT40 etc */ |
Naveen Rawat | ea1564b | 2018-05-17 15:56:11 -0700 | [diff] [blame] | 3079 | enum tx_rate_info mcastDataRate5GHzTxFlag; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3080 | |
| 3081 | } tSirRateUpdateInd, *tpSirRateUpdateInd; |
| 3082 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3083 | #define SIR_DFS_MAX_20M_SUB_CH 8 |
Sandeep Puligilla | 949eaa7 | 2015-12-17 18:43:52 -0800 | [diff] [blame] | 3084 | #define SIR_80MHZ_START_CENTER_CH_DIFF 6 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3085 | |
| 3086 | typedef struct sSirSmeDfsChannelList { |
| 3087 | uint32_t nchannels; |
| 3088 | /* Ch num including bonded channels on which the RADAR is present */ |
| 3089 | uint8_t channels[SIR_DFS_MAX_20M_SUB_CH]; |
| 3090 | } tSirSmeDfsChannelList, *tpSirSmeDfsChannelList; |
| 3091 | |
| 3092 | typedef struct sSirSmeDfsEventInd { |
| 3093 | uint32_t sessionId; |
| 3094 | tSirSmeDfsChannelList chan_list; |
| 3095 | uint32_t dfs_radar_status; |
| 3096 | int use_nol; |
| 3097 | } tSirSmeDfsEventInd, *tpSirSmeDfsEventInd; |
| 3098 | |
| 3099 | typedef struct sSirChanChangeRequest { |
| 3100 | uint16_t messageType; |
| 3101 | uint16_t messageLen; |
| 3102 | uint8_t targetChannel; |
Kiran Kumar Lokere | 999e58c | 2016-01-07 02:18:39 -0800 | [diff] [blame] | 3103 | uint8_t sec_ch_offset; |
Kiran Kumar Lokere | 1364467 | 2016-02-29 15:40:10 -0800 | [diff] [blame] | 3104 | enum phy_ch_width ch_width; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3105 | uint8_t center_freq_seg_0; |
| 3106 | uint8_t center_freq_seg_1; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3107 | uint8_t bssid[QDF_MAC_ADDR_SIZE]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3108 | uint32_t dot11mode; |
Bala Venkatesh | b39ed15 | 2017-12-26 19:35:27 +0530 | [diff] [blame] | 3109 | tSirNwType nw_type; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3110 | tSirMacRateSet operational_rateset; |
| 3111 | tSirMacRateSet extended_rateset; |
Arif Hussain | 671a190 | 2017-03-17 09:08:32 -0700 | [diff] [blame] | 3112 | uint32_t cac_duration_ms; |
| 3113 | uint32_t dfs_regdomain; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3114 | } tSirChanChangeRequest, *tpSirChanChangeRequest; |
| 3115 | |
| 3116 | typedef struct sSirChanChangeResponse { |
| 3117 | uint8_t sessionId; |
| 3118 | uint8_t newChannelNumber; |
| 3119 | uint8_t channelChangeStatus; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3120 | } tSirChanChangeResponse, *tpSirChanChangeResponse; |
| 3121 | |
| 3122 | typedef struct sSirStartBeaconIndication { |
| 3123 | uint16_t messageType; |
| 3124 | uint16_t messageLen; |
| 3125 | uint8_t beaconStartStatus; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3126 | uint8_t bssid[QDF_MAC_ADDR_SIZE]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3127 | } tSirStartBeaconIndication, *tpSirStartBeaconIndication; |
| 3128 | |
| 3129 | /* additional IE type */ |
| 3130 | typedef enum tUpdateIEsType { |
| 3131 | eUPDATE_IE_NONE, |
| 3132 | eUPDATE_IE_PROBE_BCN, |
| 3133 | eUPDATE_IE_PROBE_RESP, |
| 3134 | eUPDATE_IE_ASSOC_RESP, |
| 3135 | |
| 3136 | /* Add type above this line */ |
| 3137 | /* this is used to reset all buffer */ |
| 3138 | eUPDATE_IE_ALL, |
| 3139 | eUPDATE_IE_MAX |
| 3140 | } eUpdateIEsType; |
| 3141 | |
| 3142 | /* Modify particular IE in addition IE for prob resp Bcn */ |
| 3143 | typedef struct sSirModifyIE { |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3144 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3145 | uint16_t smeSessionId; |
| 3146 | bool notify; |
| 3147 | uint8_t ieID; |
| 3148 | uint8_t ieIDLen; /*ie length as per spec */ |
| 3149 | uint16_t ieBufferlength; |
| 3150 | uint8_t *pIEBuffer; |
Rajeev Kumar | 8e3e283 | 2015-11-06 16:02:54 -0800 | [diff] [blame] | 3151 | int32_t oui_length; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3152 | |
| 3153 | } tSirModifyIE, *tpSirModifyIE; |
| 3154 | |
Kiran Kumar Lokere | bc87bec | 2018-02-27 20:06:42 -0800 | [diff] [blame] | 3155 | struct send_add_ba_req { |
| 3156 | uint8_t mac_addr[QDF_MAC_ADDR_SIZE]; |
| 3157 | struct addba_send_params param; |
| 3158 | }; |
| 3159 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3160 | /* Message format for Update IE message sent to PE */ |
| 3161 | typedef struct sSirModifyIEsInd { |
| 3162 | uint16_t msgType; |
| 3163 | uint16_t msgLen; |
| 3164 | tSirModifyIE modifyIE; |
| 3165 | eUpdateIEsType updateType; |
| 3166 | } tSirModifyIEsInd, *tpSirModifyIEsInd; |
| 3167 | |
| 3168 | /* Message format for Update IE message sent to PE */ |
| 3169 | typedef struct sSirUpdateIE { |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3170 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3171 | uint16_t smeSessionId; |
| 3172 | bool append; |
| 3173 | bool notify; |
| 3174 | uint16_t ieBufferlength; |
| 3175 | uint8_t *pAdditionIEBuffer; |
| 3176 | } tSirUpdateIE, *tpSirUpdateIE; |
| 3177 | |
| 3178 | /* Message format for Update IE message sent to PE */ |
| 3179 | typedef struct sSirUpdateIEsInd { |
| 3180 | uint16_t msgType; |
| 3181 | uint16_t msgLen; |
| 3182 | tSirUpdateIE updateIE; |
| 3183 | eUpdateIEsType updateType; |
| 3184 | } tSirUpdateIEsInd, *tpSirUpdateIEsInd; |
| 3185 | |
| 3186 | /* Message format for requesting channel switch announcement to lower layers */ |
| 3187 | typedef struct sSirDfsCsaIeRequest { |
| 3188 | uint16_t msgType; |
| 3189 | uint16_t msgLen; |
| 3190 | uint8_t targetChannel; |
| 3191 | uint8_t csaIeRequired; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3192 | uint8_t bssid[QDF_MAC_ADDR_SIZE]; |
Amar Singhal | 5cccafe | 2017-02-15 12:42:58 -0800 | [diff] [blame] | 3193 | struct ch_params ch_params; |
gaolez | e2920bd | 2017-03-21 17:38:42 +0800 | [diff] [blame] | 3194 | uint8_t ch_switch_beacon_cnt; |
gaolez | 76d2a16 | 2017-03-21 19:23:58 +0800 | [diff] [blame] | 3195 | uint8_t ch_switch_mode; |
| 3196 | uint8_t dfs_ch_switch_disable; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3197 | } tSirDfsCsaIeRequest, *tpSirDfsCsaIeRequest; |
| 3198 | |
| 3199 | /* Indication from lower layer indicating the completion of first beacon send |
| 3200 | * after the beacon template update |
| 3201 | */ |
| 3202 | typedef struct sSirFirstBeaconTxCompleteInd { |
| 3203 | uint16_t messageType; /* eWNI_SME_MISSED_BEACON_IND */ |
| 3204 | uint16_t length; |
| 3205 | uint8_t bssIdx; |
| 3206 | } tSirFirstBeaconTxCompleteInd, *tpSirFirstBeaconTxCompleteInd; |
| 3207 | |
| 3208 | typedef struct sSirSmeCSAIeTxCompleteRsp { |
| 3209 | uint8_t sessionId; |
| 3210 | uint8_t chanSwIeTxStatus; |
| 3211 | } tSirSmeCSAIeTxCompleteRsp, *tpSirSmeCSAIeTxCompleteRsp; |
| 3212 | |
| 3213 | /* Thermal Mitigation*/ |
| 3214 | |
| 3215 | typedef struct { |
| 3216 | uint16_t minTempThreshold; |
| 3217 | uint16_t maxTempThreshold; |
| 3218 | } t_thermal_level_info, *tp_thermal_level_info; |
| 3219 | |
| 3220 | typedef enum { |
| 3221 | WLAN_WMA_THERMAL_LEVEL_0, |
| 3222 | WLAN_WMA_THERMAL_LEVEL_1, |
| 3223 | WLAN_WMA_THERMAL_LEVEL_2, |
| 3224 | WLAN_WMA_THERMAL_LEVEL_3, |
| 3225 | WLAN_WMA_MAX_THERMAL_LEVELS |
| 3226 | } t_thermal_level; |
| 3227 | |
Poddar, Siddarth | 8390502 | 2016-04-16 17:56:08 -0700 | [diff] [blame] | 3228 | #define WLAN_THROTTLE_DUTY_CYCLE_LEVEL_MAX (4) |
| 3229 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3230 | typedef struct { |
| 3231 | /* Array of thermal levels */ |
| 3232 | t_thermal_level_info thermalLevels[WLAN_WMA_MAX_THERMAL_LEVELS]; |
| 3233 | uint8_t thermalCurrLevel; |
| 3234 | uint8_t thermalMgmtEnabled; |
| 3235 | uint32_t throttlePeriod; |
Poddar, Siddarth | 8390502 | 2016-04-16 17:56:08 -0700 | [diff] [blame] | 3236 | uint8_t throttle_duty_cycle_tbl[WLAN_THROTTLE_DUTY_CYCLE_LEVEL_MAX]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3237 | } t_thermal_mgmt, *tp_thermal_mgmt; |
| 3238 | |
| 3239 | typedef struct sSirTxPowerLimit { |
| 3240 | /* Thermal limits for 2g and 5g */ |
| 3241 | uint32_t txPower2g; |
| 3242 | uint32_t txPower5g; |
| 3243 | } tSirTxPowerLimit; |
| 3244 | |
Poddar, Siddarth | 5a91f5b | 2016-04-28 12:24:10 +0530 | [diff] [blame] | 3245 | enum bad_peer_thresh_levels { |
| 3246 | WLAN_WMA_IEEE80211_B_LEVEL = 0, |
| 3247 | WLAN_WMA_IEEE80211_AG_LEVEL, |
| 3248 | WLAN_WMA_IEEE80211_N_LEVEL, |
| 3249 | WLAN_WMA_IEEE80211_AC_LEVEL, |
| 3250 | WLAN_WMA_IEEE80211_AX_LEVEL, |
| 3251 | WLAN_WMA_IEEE80211_MAX_LEVEL, |
| 3252 | }; |
| 3253 | |
| 3254 | #define NUM_OF_RATE_THRESH_MAX (4) |
| 3255 | struct t_bad_peer_info { |
| 3256 | uint32_t cond; |
| 3257 | uint32_t delta; |
| 3258 | uint32_t percentage; |
| 3259 | uint32_t thresh[NUM_OF_RATE_THRESH_MAX]; |
| 3260 | uint32_t txlimit; |
| 3261 | }; |
| 3262 | |
| 3263 | struct t_bad_peer_txtcl_config { |
| 3264 | /* Array of thermal levels */ |
| 3265 | struct t_bad_peer_info threshold[WLAN_WMA_IEEE80211_MAX_LEVEL]; |
| 3266 | uint32_t enable; |
| 3267 | uint32_t period; |
| 3268 | uint32_t txq_limit; |
| 3269 | uint32_t tgt_backoff; |
| 3270 | uint32_t tgt_report_prd; |
| 3271 | }; |
| 3272 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3273 | /* notify MODEM power state to FW */ |
| 3274 | typedef struct { |
| 3275 | uint32_t param; |
| 3276 | } tSirModemPowerStateInd, *tpSirModemPowerStateInd; |
| 3277 | |
| 3278 | #ifdef WLAN_FEATURE_STATS_EXT |
| 3279 | typedef struct { |
| 3280 | uint32_t vdev_id; |
| 3281 | uint32_t event_data_len; |
| 3282 | uint8_t event_data[]; |
| 3283 | } tSirStatsExtEvent, *tpSirStatsExtEvent; |
| 3284 | #endif |
| 3285 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3286 | typedef struct { |
| 3287 | uint32_t event_data_len; |
| 3288 | uint8_t event_data[]; |
| 3289 | } tSirNanEvent, *tpSirNanEvent; |
Mahesh Kumar Kalikot Veetil | 919e01d | 2016-09-09 17:09:10 -0700 | [diff] [blame] | 3290 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3291 | typedef struct sSirSmeRoamOffloadSynchInd { |
| 3292 | uint16_t messageType; /*eWNI_SME_ROAM_OFFLOAD_SYNCH_IND */ |
| 3293 | uint16_t length; |
| 3294 | uint16_t beaconProbeRespOffset; |
| 3295 | uint16_t beaconProbeRespLength; |
| 3296 | uint16_t reassocRespOffset; |
| 3297 | uint16_t reassocRespLength; |
Naveen Rawat | 14298b9 | 2015-11-25 16:27:41 -0800 | [diff] [blame] | 3298 | uint16_t reassoc_req_offset; |
| 3299 | uint16_t reassoc_req_length; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3300 | uint8_t isBeacon; |
| 3301 | uint8_t roamedVdevId; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3302 | struct qdf_mac_addr bssid; |
Varun Reddy Yeturu | 28925b4 | 2016-02-08 07:18:50 -0800 | [diff] [blame] | 3303 | struct qdf_mac_addr self_mac; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3304 | int8_t txMgmtPower; |
| 3305 | uint32_t authStatus; |
| 3306 | uint8_t rssi; |
| 3307 | uint8_t roamReason; |
| 3308 | uint32_t chan_freq; |
| 3309 | uint8_t kck[SIR_KCK_KEY_LEN]; |
Vignesh Viswanathan | c6d1e1c | 2017-09-18 12:32:49 +0530 | [diff] [blame] | 3310 | uint32_t kek_len; |
| 3311 | uint8_t kek[SIR_KEK_KEY_LEN_FILS]; |
| 3312 | uint32_t pmk_len; |
| 3313 | uint8_t pmk[SIR_PMK_LEN]; |
| 3314 | uint8_t pmkid[SIR_PMKID_LEN]; |
| 3315 | bool update_erp_next_seq_num; |
| 3316 | uint16_t next_erp_seq_num; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3317 | uint8_t replay_ctr[SIR_REPLAY_CTR_LEN]; |
Varun Reddy Yeturu | d5939f8 | 2015-12-24 18:14:02 -0800 | [diff] [blame] | 3318 | void *add_bss_params; |
| 3319 | tpSirSmeJoinRsp join_rsp; |
| 3320 | uint16_t aid; |
Naveen Rawat | 8cc23b0 | 2016-07-14 12:22:56 -0700 | [diff] [blame] | 3321 | struct sir_hw_mode_trans_ind hw_mode_trans_ind; |
Naveen Rawat | 746a90b | 2017-06-07 15:16:35 -0700 | [diff] [blame] | 3322 | uint8_t nss; |
Vignesh Viswanathan | c6d1e1c | 2017-09-18 12:32:49 +0530 | [diff] [blame] | 3323 | struct qdf_mac_addr dst_mac; |
| 3324 | struct qdf_mac_addr src_mac; |
| 3325 | uint16_t hlp_data_len; |
| 3326 | uint8_t hlp_data[FILS_MAX_HLP_DATA_LEN]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3327 | } roam_offload_synch_ind; |
| 3328 | |
Varun Reddy Yeturu | bbbbe23 | 2016-02-29 14:01:57 -0800 | [diff] [blame] | 3329 | #ifdef WLAN_FEATURE_ROAM_OFFLOAD |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3330 | typedef struct sSirSmeRoamOffloadSynchCnf { |
| 3331 | uint8_t sessionId; |
| 3332 | } tSirSmeRoamOffloadSynchCnf, *tpSirSmeRoamOffloadSynchCnf; |
| 3333 | |
| 3334 | typedef struct sSirSmeHOFailureInd { |
| 3335 | uint8_t sessionId; |
| 3336 | } tSirSmeHOFailureInd, *tpSirSmeHOFailureInd; |
| 3337 | |
| 3338 | struct roam_offload_synch_fail { |
| 3339 | uint8_t session_id; |
| 3340 | }; |
| 3341 | |
| 3342 | #endif |
| 3343 | |
Wen Gong | 7952fbd | 2018-04-18 11:27:23 +0800 | [diff] [blame] | 3344 | /** |
| 3345 | * struct sir_wisa_params - WISA Mode Parameters |
| 3346 | * @mode: WISA mode |
| 3347 | * @session_id: Session ID of vdev |
| 3348 | */ |
| 3349 | struct sir_wisa_params { |
| 3350 | bool mode; |
| 3351 | uint8_t vdev_id; |
| 3352 | }; |
| 3353 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3354 | #ifdef FEATURE_WLAN_EXTSCAN |
| 3355 | |
Wen Gong | 7952fbd | 2018-04-18 11:27:23 +0800 | [diff] [blame] | 3356 | #define WLAN_EXTSCAN_MAX_CHANNELS 36 |
| 3357 | #define WLAN_EXTSCAN_MAX_BUCKETS 16 |
Wen Gong | 7952fbd | 2018-04-18 11:27:23 +0800 | [diff] [blame] | 3358 | #define WLAN_EXTSCAN_MAX_SIGNIFICANT_CHANGE_APS 64 |
| 3359 | |
| 3360 | typedef enum { |
| 3361 | eSIR_EXTSCAN_INVALID, |
| 3362 | eSIR_EXTSCAN_START_RSP, |
| 3363 | eSIR_EXTSCAN_STOP_RSP, |
| 3364 | eSIR_EXTSCAN_CACHED_RESULTS_RSP, |
| 3365 | eSIR_EXTSCAN_SET_BSSID_HOTLIST_RSP, |
| 3366 | eSIR_EXTSCAN_RESET_BSSID_HOTLIST_RSP, |
| 3367 | eSIR_EXTSCAN_SET_SIGNIFICANT_WIFI_CHANGE_RSP, |
| 3368 | eSIR_EXTSCAN_RESET_SIGNIFICANT_WIFI_CHANGE_RSP, |
| 3369 | |
| 3370 | eSIR_EXTSCAN_GET_CAPABILITIES_IND, |
| 3371 | eSIR_EXTSCAN_HOTLIST_MATCH_IND, |
| 3372 | eSIR_EXTSCAN_SIGNIFICANT_WIFI_CHANGE_RESULTS_IND, |
| 3373 | eSIR_EXTSCAN_CACHED_RESULTS_IND, |
| 3374 | eSIR_EXTSCAN_SCAN_RES_AVAILABLE_IND, |
| 3375 | eSIR_EXTSCAN_SCAN_PROGRESS_EVENT_IND, |
| 3376 | eSIR_EXTSCAN_FULL_SCAN_RESULT_IND, |
| 3377 | eSIR_EPNO_NETWORK_FOUND_IND, |
| 3378 | eSIR_PASSPOINT_NETWORK_FOUND_IND, |
| 3379 | eSIR_EXTSCAN_SET_SSID_HOTLIST_RSP, |
| 3380 | eSIR_EXTSCAN_RESET_SSID_HOTLIST_RSP, |
| 3381 | |
| 3382 | /* Keep this last */ |
| 3383 | eSIR_EXTSCAN_CALLBACK_TYPE_MAX, |
| 3384 | } tSirExtScanCallbackType; |
| 3385 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3386 | /** |
| 3387 | * typedef enum wifi_scan_flags - wifi scan flags |
| 3388 | * @WIFI_SCAN_FLAG_INTERRUPTED: Indicates that scan results are not complete |
| 3389 | * because probes were not sent on some channels |
| 3390 | */ |
| 3391 | typedef enum { |
| 3392 | WIFI_SCAN_FLAG_INTERRUPTED = 1, |
| 3393 | } wifi_scan_flags; |
| 3394 | |
| 3395 | typedef enum { |
| 3396 | WIFI_BAND_UNSPECIFIED, |
| 3397 | WIFI_BAND_BG = 1, /* 2.4 GHz */ |
| 3398 | WIFI_BAND_A = 2, /* 5 GHz without DFS */ |
| 3399 | WIFI_BAND_ABG = 3, /* 2.4 GHz + 5 GHz; no DFS */ |
| 3400 | WIFI_BAND_A_DFS_ONLY = 4, /* 5 GHz DFS only */ |
| 3401 | /* 5 is reserved */ |
| 3402 | WIFI_BAND_A_WITH_DFS = 6, /* 5 GHz with DFS */ |
| 3403 | WIFI_BAND_ABG_WITH_DFS = 7, /* 2.4 GHz + 5 GHz with DFS */ |
| 3404 | |
| 3405 | /* Keep it last */ |
| 3406 | WIFI_BAND_MAX |
| 3407 | } tWifiBand; |
| 3408 | |
Mukul Sharma | 45114d9 | 2016-08-12 19:34:14 +0530 | [diff] [blame] | 3409 | /** |
| 3410 | * enum wifi_extscan_event_type - extscan event type |
| 3411 | * @WIFI_EXTSCAN_RESULTS_AVAILABLE: reported when REPORT_EVENTS_EACH_SCAN is set |
| 3412 | * and a scan cycle completes. WIFI_SCAN_THRESHOLD_NUM_SCANS or |
| 3413 | * WIFI_SCAN_THRESHOLD_PERCENT can be reported instead if the |
| 3414 | * reason for the event is available; however, at most one of |
| 3415 | * these events should be reported per scan. |
| 3416 | * @WIFI_EXTSCAN_THRESHOLD_NUM_SCANS: can be reported when |
| 3417 | * REPORT_EVENTS_EACH_SCAN is not set and |
| 3418 | * report_threshold_num_scans is reached. |
| 3419 | * @WIFI_EXTSCAN_THRESHOLD_PERCENT: can be reported when REPORT_EVENTS_EACH_SCAN |
| 3420 | * is not set and report_threshold_percent is reached. |
| 3421 | * @WIFI_SCAN_DISABLED: reported when currently executing gscans are disabled |
| 3422 | * start_gscan will need to be called again in order to continue |
| 3423 | * scanning. |
| 3424 | * @WIFI_EXTSCAN_BUCKET_STARTED_EVENT: Bucket started event |
| 3425 | * This event is consumed in driver only. |
| 3426 | * @WIFI_EXTSCAN_CYCLE_STARTED_EVENT: Cycle started event. |
| 3427 | * This event is consumed in driver only. |
| 3428 | * @WIFI_EXTSCAN_CYCLE_COMPLETED_EVENT: Cycle complete event. This event |
| 3429 | * triggers @WIFI_EXTSCAN_RESULTS_AVAILABLE to the user space. |
| 3430 | */ |
| 3431 | enum wifi_extscan_event_type { |
Mukul Sharma | fa937be | 2016-08-12 18:13:36 +0530 | [diff] [blame] | 3432 | WIFI_EXTSCAN_RESULTS_AVAILABLE, |
Mukul Sharma | fa937be | 2016-08-12 18:13:36 +0530 | [diff] [blame] | 3433 | WIFI_EXTSCAN_THRESHOLD_NUM_SCANS, |
Mukul Sharma | fa937be | 2016-08-12 18:13:36 +0530 | [diff] [blame] | 3434 | WIFI_EXTSCAN_THRESHOLD_PERCENT, |
Mukul Sharma | fa937be | 2016-08-12 18:13:36 +0530 | [diff] [blame] | 3435 | WIFI_SCAN_DISABLED, |
| 3436 | |
Mukul Sharma | fa937be | 2016-08-12 18:13:36 +0530 | [diff] [blame] | 3437 | WIFI_EXTSCAN_BUCKET_STARTED_EVENT = 0x10, |
| 3438 | WIFI_EXTSCAN_CYCLE_STARTED_EVENT, |
| 3439 | WIFI_EXTSCAN_CYCLE_COMPLETED_EVENT, |
Mukul Sharma | 45114d9 | 2016-08-12 19:34:14 +0530 | [diff] [blame] | 3440 | }; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3441 | |
| 3442 | /** |
| 3443 | * enum extscan_configuration_flags - extscan config flags |
| 3444 | * @EXTSCAN_LP_EXTENDED_BATCHING: extended batching |
| 3445 | */ |
| 3446 | enum extscan_configuration_flags { |
| 3447 | EXTSCAN_LP_EXTENDED_BATCHING = 0x00000001, |
| 3448 | }; |
| 3449 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3450 | /** |
| 3451 | * struct ext_scan_capabilities_response - extscan capabilities response data |
| 3452 | * @requestId: request identifier |
| 3453 | * @status: status |
| 3454 | * @max_scan_cache_size: total space allocated for scan (in bytes) |
| 3455 | * @max_scan_buckets: maximum number of channel buckets |
| 3456 | * @max_ap_cache_per_scan: maximum number of APs that can be stored per scan |
| 3457 | * @max_rssi_sample_size: number of RSSI samples used for averaging RSSI |
| 3458 | * @ax_scan_reporting_threshold: max possible report_threshold |
| 3459 | * @max_hotlist_bssids: maximum number of entries for hotlist APs |
| 3460 | * @max_significant_wifi_change_aps: maximum number of entries for |
| 3461 | * significant wifi change APs |
| 3462 | * @max_bssid_history_entries: number of BSSID/RSSI entries that device can hold |
| 3463 | * @max_hotlist_ssids: maximum number of entries for hotlist SSIDs |
| 3464 | * @max_number_epno_networks: max number of epno entries |
| 3465 | * @max_number_epno_networks_by_ssid: max number of epno entries |
| 3466 | * if ssid is specified, that is, epno entries for |
| 3467 | * which an exact match is required, |
| 3468 | * or entries corresponding to hidden ssids |
| 3469 | * @max_number_of_white_listed_ssid: max number of white listed SSIDs |
Padma, Santhosh Kumar | 1ac0240 | 2016-11-02 18:04:14 +0530 | [diff] [blame] | 3470 | * @max_number_of_black_listed_bssid: max number of black listed BSSIDs |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3471 | */ |
| 3472 | struct ext_scan_capabilities_response { |
| 3473 | uint32_t requestId; |
| 3474 | uint32_t status; |
| 3475 | |
| 3476 | uint32_t max_scan_cache_size; |
| 3477 | uint32_t max_scan_buckets; |
| 3478 | uint32_t max_ap_cache_per_scan; |
| 3479 | uint32_t max_rssi_sample_size; |
| 3480 | uint32_t max_scan_reporting_threshold; |
| 3481 | |
| 3482 | uint32_t max_hotlist_bssids; |
| 3483 | uint32_t max_significant_wifi_change_aps; |
| 3484 | |
| 3485 | uint32_t max_bssid_history_entries; |
| 3486 | uint32_t max_hotlist_ssids; |
| 3487 | uint32_t max_number_epno_networks; |
| 3488 | uint32_t max_number_epno_networks_by_ssid; |
| 3489 | uint32_t max_number_of_white_listed_ssid; |
Padma, Santhosh Kumar | 1ac0240 | 2016-11-02 18:04:14 +0530 | [diff] [blame] | 3490 | uint32_t max_number_of_black_listed_bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3491 | }; |
| 3492 | |
| 3493 | typedef struct { |
| 3494 | uint32_t requestId; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3495 | uint32_t status; |
| 3496 | } tSirExtScanGetCachedResultsRspParams, *tpSirExtScanGetCachedResultsRspParams; |
| 3497 | |
| 3498 | typedef struct { |
| 3499 | /* Time of discovery */ |
| 3500 | uint64_t ts; |
| 3501 | |
| 3502 | /* Null terminated SSID */ |
| 3503 | uint8_t ssid[SIR_MAC_MAX_SSID_LENGTH + 1]; |
| 3504 | |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3505 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3506 | |
| 3507 | /* Frequency in MHz */ |
| 3508 | uint32_t channel; |
| 3509 | |
| 3510 | /* RSSI in dBm */ |
| 3511 | int32_t rssi; |
| 3512 | |
| 3513 | /* RTT in nanoseconds */ |
| 3514 | uint32_t rtt; |
| 3515 | |
| 3516 | /* Standard deviation in rtt */ |
| 3517 | uint32_t rtt_sd; |
| 3518 | |
| 3519 | /* Period advertised in the beacon */ |
| 3520 | uint16_t beaconPeriod; |
| 3521 | |
| 3522 | /* Capabilities advertised in the beacon */ |
| 3523 | uint16_t capability; |
| 3524 | |
| 3525 | uint16_t ieLength; |
| 3526 | |
| 3527 | uint8_t ieData[]; |
| 3528 | } tSirWifiScanResult, *tpSirWifiScanResult; |
| 3529 | |
| 3530 | /** |
| 3531 | * struct extscan_hotlist_match - extscan hotlist match |
| 3532 | * @requestId: request identifier |
| 3533 | * @numOfAps: number of bssids retrieved by the scan |
| 3534 | * @moreData: 0 - for last fragment |
| 3535 | * 1 - still more fragment(s) coming |
| 3536 | * @ap: wifi scan result |
| 3537 | */ |
| 3538 | struct extscan_hotlist_match { |
| 3539 | uint32_t requestId; |
| 3540 | bool moreData; |
| 3541 | bool ap_found; |
| 3542 | uint32_t numOfAps; |
| 3543 | tSirWifiScanResult ap[]; |
| 3544 | }; |
| 3545 | |
| 3546 | /** |
| 3547 | * struct extscan_cached_scan_result - extscan cached scan result |
| 3548 | * @scan_id: a unique identifier for the scan unit |
| 3549 | * @flags: a bitmask with additional information about scan |
| 3550 | * @num_results: number of bssids retrieved by the scan |
Mukul Sharma | f7cb3ab | 2016-08-12 19:53:52 +0530 | [diff] [blame] | 3551 | * @buckets_scanned: bitmask of buckets scanned in current extscan cycle |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3552 | * @ap: wifi scan bssid results info |
| 3553 | */ |
| 3554 | struct extscan_cached_scan_result { |
| 3555 | uint32_t scan_id; |
| 3556 | uint32_t flags; |
| 3557 | uint32_t num_results; |
Mukul Sharma | f7cb3ab | 2016-08-12 19:53:52 +0530 | [diff] [blame] | 3558 | uint32_t buckets_scanned; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3559 | tSirWifiScanResult *ap; |
| 3560 | }; |
| 3561 | |
| 3562 | /** |
| 3563 | * struct tSirWifiScanResultEvent - wifi scan result event |
| 3564 | * @requestId: request identifier |
| 3565 | * @ap_found: flag to indicate ap found or not |
| 3566 | * true: AP was found |
| 3567 | * false: AP was lost |
| 3568 | * @numOfAps: number of aps |
| 3569 | * @moreData: more data |
| 3570 | * @ap: bssid information |
| 3571 | * |
| 3572 | */ |
| 3573 | typedef struct { |
| 3574 | uint32_t requestId; |
| 3575 | bool ap_found; |
| 3576 | uint32_t numOfAps; |
| 3577 | bool moreData; |
| 3578 | tSirWifiScanResult ap[]; |
| 3579 | } tSirWifiScanResultEvent, *tpSirWifiScanResultEvent; |
| 3580 | |
| 3581 | /** |
| 3582 | * struct extscan_cached_scan_results - extscan cached scan results |
| 3583 | * @request_id: request identifier |
| 3584 | * @more_data: 0 - for last fragment |
| 3585 | * 1 - still more fragment(s) coming |
| 3586 | * @num_scan_ids: number of scan ids |
| 3587 | * @result: wifi scan result |
| 3588 | */ |
| 3589 | struct extscan_cached_scan_results { |
| 3590 | uint32_t request_id; |
| 3591 | bool more_data; |
| 3592 | uint32_t num_scan_ids; |
| 3593 | struct extscan_cached_scan_result *result; |
| 3594 | }; |
| 3595 | |
| 3596 | |
| 3597 | /** |
| 3598 | * struct tSirWifiFullScanResultEvent - extscan full scan event |
| 3599 | * @request_id: request identifier |
| 3600 | * @moreData: 0 - for last fragment |
| 3601 | * 1 - still more fragment(s) coming |
| 3602 | * @ap: bssid info |
| 3603 | * |
Jeff Johnson | dab5860 | 2018-07-14 15:30:24 -0700 | [diff] [blame] | 3604 | * Reported when each probe response is received, if report_events |
| 3605 | * enabled in struct wifi_scan_cmd_req_params |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3606 | */ |
| 3607 | typedef struct { |
| 3608 | uint32_t requestId; |
| 3609 | bool moreData; |
| 3610 | tSirWifiScanResult ap; |
| 3611 | } tSirWifiFullScanResultEvent, *tpSirWifiFullScanResultEvent; |
| 3612 | |
| 3613 | /** |
| 3614 | * struct pno_match_found - epno match found |
| 3615 | * @request_id: request identifier |
| 3616 | * @moreData: 0 - for last fragment |
| 3617 | * 1 - still more fragment(s) coming |
| 3618 | * @num_results: number of bssids, driver sends this event to upper layer |
| 3619 | * for every beacon, hence %num_results is always set to 1. |
| 3620 | * @ap: bssid info |
| 3621 | * |
| 3622 | * Reported when each beacon probe response is received with |
| 3623 | * epno match found tag. |
| 3624 | */ |
| 3625 | struct pno_match_found { |
| 3626 | uint32_t request_id; |
| 3627 | bool more_data; |
| 3628 | uint32_t num_results; |
| 3629 | tSirWifiScanResult ap[]; |
| 3630 | }; |
| 3631 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3632 | /** |
| 3633 | * struct sir_extscan_generic_response - |
| 3634 | * Generic ExtScan Response structure |
| 3635 | * @request_id: ID of the request |
| 3636 | * @status: operation status returned by firmware |
| 3637 | */ |
| 3638 | struct sir_extscan_generic_response { |
| 3639 | uint32_t request_id; |
| 3640 | uint32_t status; |
| 3641 | }; |
| 3642 | |
| 3643 | typedef struct { |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3644 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3645 | uint32_t channel; |
| 3646 | uint32_t numOfRssi; |
| 3647 | |
| 3648 | /* Rssi history in db */ |
| 3649 | int32_t rssi[]; |
| 3650 | } tSirWifiSignificantChange, *tpSirWifiSignificantChange; |
| 3651 | |
| 3652 | typedef struct { |
| 3653 | uint32_t requestId; |
| 3654 | |
| 3655 | bool moreData; |
| 3656 | uint32_t numResults; |
| 3657 | tSirWifiSignificantChange ap[]; |
| 3658 | } tSirWifiSignificantChangeEvent, *tpSirWifiSignificantChangeEvent; |
| 3659 | |
| 3660 | typedef struct { |
| 3661 | uint32_t requestId; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3662 | uint32_t numResultsAvailable; |
| 3663 | } tSirExtScanResultsAvailableIndParams, *tpSirExtScanResultsAvailableIndParams; |
| 3664 | |
| 3665 | typedef struct { |
| 3666 | uint32_t requestId; |
| 3667 | uint32_t status; |
| 3668 | uint8_t scanEventType; |
Mukul Sharma | fa937be | 2016-08-12 18:13:36 +0530 | [diff] [blame] | 3669 | uint32_t buckets_scanned; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3670 | } tSirExtScanOnScanEventIndParams, *tpSirExtScanOnScanEventIndParams; |
| 3671 | |
Mukul Sharma | e8c919f | 2016-10-02 20:35:15 +0530 | [diff] [blame] | 3672 | #define MAX_EPNO_NETWORKS 64 |
| 3673 | |
Jeff Johnson | 96f93a3 | 2016-11-18 11:02:24 -0800 | [diff] [blame] | 3674 | #define SIR_PASSPOINT_LIST_MAX_NETWORKS 8 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3675 | |
| 3676 | /** |
| 3677 | * struct wifi_passpoint_match - wifi passpoint network match |
| 3678 | * @id: network block identifier for the matched network |
| 3679 | * @anqp_len: length of ANQP blob |
| 3680 | * @ap: scan result, with channel and beacon information |
| 3681 | * @anqp: ANQP data, in the information_element format |
| 3682 | */ |
| 3683 | struct wifi_passpoint_match { |
| 3684 | uint32_t request_id; |
| 3685 | uint32_t id; |
| 3686 | uint32_t anqp_len; |
| 3687 | tSirWifiScanResult ap; |
| 3688 | uint8_t anqp[]; |
| 3689 | }; |
| 3690 | #endif /* FEATURE_WLAN_EXTSCAN */ |
| 3691 | |
| 3692 | #ifdef FEATURE_WLAN_AUTO_SHUTDOWN |
| 3693 | typedef struct { |
| 3694 | uint32_t timer_val; |
| 3695 | } tSirAutoShutdownCmdParams; |
| 3696 | |
| 3697 | typedef struct { |
| 3698 | uint32_t shutdown_reason; |
| 3699 | } tSirAutoShutdownEvtParams; |
| 3700 | #endif |
| 3701 | |
Sridhar Selvaraj | dc400d2 | 2016-10-18 17:18:03 +0530 | [diff] [blame] | 3702 | #ifdef WLAN_POWER_DEBUGFS |
| 3703 | /** |
| 3704 | * struct power_stats_response - Power stats response |
| 3705 | * @cumulative_sleep_time_ms: cumulative sleep time in ms |
| 3706 | * @cumulative_total_on_time_ms: total awake time in ms |
| 3707 | * @deep_sleep_enter_counter: deep sleep enter counter |
| 3708 | * @last_deep_sleep_enter_tstamp_ms: last deep sleep enter timestamp |
| 3709 | * @debug_register_fmt: debug registers format |
| 3710 | * @num_debug_register: number of debug registers |
| 3711 | * @debug_registers: Pointer to the debug registers buffer |
| 3712 | */ |
| 3713 | struct power_stats_response { |
| 3714 | uint32_t cumulative_sleep_time_ms; |
| 3715 | uint32_t cumulative_total_on_time_ms; |
| 3716 | uint32_t deep_sleep_enter_counter; |
| 3717 | uint32_t last_deep_sleep_enter_tstamp_ms; |
| 3718 | uint32_t debug_register_fmt; |
| 3719 | uint32_t num_debug_register; |
| 3720 | uint32_t *debug_registers; |
| 3721 | }; |
| 3722 | #endif |
| 3723 | |
Arunk Khandavalli | ca56d4b | 2018-11-29 15:46:00 +0530 | [diff] [blame] | 3724 | #ifdef WLAN_FEATURE_BEACON_RECEPTION_STATS |
| 3725 | #define MAX_BCNMISS_BITMAP 8 |
| 3726 | /** |
| 3727 | * struct bcn_reception_stats_rsp - beacon stats response |
| 3728 | * @total_bcn_cnt: total beacon count (tbtt instances) |
| 3729 | * @total_bmiss_cnt: Total beacon miss count in last 255 beacons, max 255 |
| 3730 | * @bmiss_bitmap: This bitmap indicates the status of the last 255 beacons. |
| 3731 | * If a bit is set, that means the corresponding beacon was missed. |
| 3732 | * Bit 0 of bmiss_bitmap[0] represents the most recent beacon. |
| 3733 | * The total_bcn_cnt field indicates how many bits within bmiss_bitmap |
| 3734 | * are valid. |
| 3735 | */ |
| 3736 | struct bcn_reception_stats_rsp { |
| 3737 | uint32_t vdev_id; |
| 3738 | uint32_t total_bcn_cnt; |
| 3739 | uint32_t total_bmiss_cnt; |
| 3740 | uint32_t bmiss_bitmap[MAX_BCNMISS_BITMAP]; |
| 3741 | }; |
| 3742 | #endif |
| 3743 | |
Sreelakshmi Konamki | 88a2a41 | 2017-04-14 15:11:55 +0530 | [diff] [blame] | 3744 | /** |
| 3745 | * struct lfr_firmware_status - LFR status in firmware |
| 3746 | * @is_disabled: Is LFR disabled in FW |
| 3747 | * @disable_lfr_event: Disable attempt done in FW |
| 3748 | */ |
| 3749 | struct lfr_firmware_status { |
| 3750 | uint32_t is_disabled; |
| 3751 | struct completion disable_lfr_event; |
| 3752 | }; |
| 3753 | |
| 3754 | /** |
| 3755 | * struct rso_cmd_status - RSO Command status |
| 3756 | * @vdev_id: Vdev ID for which RSO command sent |
| 3757 | * @status: Status of RSO command sent to FW |
| 3758 | */ |
| 3759 | struct rso_cmd_status { |
| 3760 | uint32_t vdev_id; |
| 3761 | bool status; |
| 3762 | }; |
| 3763 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3764 | typedef struct { |
| 3765 | uint8_t oui[WIFI_SCANNING_MAC_OUI_LENGTH]; |
Rajeev Kumar Sirasanagandla | 686abd9 | 2017-06-08 18:09:01 +0530 | [diff] [blame] | 3766 | uint32_t vdev_id; |
| 3767 | bool enb_probe_req_sno_randomization; |
Rajeev Kumar Sirasanagandla | aec0b08 | 2017-06-21 11:59:41 +0530 | [diff] [blame] | 3768 | struct probe_req_whitelist_attr ie_whitelist; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3769 | } tSirScanMacOui, *tpSirScanMacOui; |
| 3770 | |
| 3771 | enum { |
| 3772 | SIR_AP_RX_DATA_OFFLOAD = 0x00, |
| 3773 | SIR_STA_RX_DATA_OFFLOAD = 0x01, |
| 3774 | }; |
| 3775 | |
Kiran Kumar Lokere | 666bf85 | 2016-05-02 12:23:02 -0700 | [diff] [blame] | 3776 | /** |
Naveen Rawat | a410c5a | 2016-09-19 14:22:33 -0700 | [diff] [blame] | 3777 | * struct sir_set_vdev_ies_per_band |
| 3778 | * @msg_type: message type |
| 3779 | * @len: message length |
| 3780 | * @vdev_id: vdev id |
| 3781 | * |
| 3782 | * Message wrapper structure for eWNI_SME_SET_VDEV_IES_PER_BAND. |
| 3783 | */ |
| 3784 | struct sir_set_vdev_ies_per_band { |
| 3785 | uint16_t msg_type; |
| 3786 | uint16_t len; |
| 3787 | uint32_t vdev_id; |
| 3788 | }; |
| 3789 | |
| 3790 | /** |
Kiran Kumar Lokere | 666bf85 | 2016-05-02 12:23:02 -0700 | [diff] [blame] | 3791 | * struct sir_set_ht_vht_cfg - ht, vht IE config |
| 3792 | * @msg_type: message type |
| 3793 | * @len: message length |
| 3794 | * @pdev_id: pdev id |
| 3795 | * @nss: Nss value |
| 3796 | * @dot11mode: Dot11 mode. |
| 3797 | * |
| 3798 | * Message wrapper structure for set HT/VHT IE req. |
| 3799 | */ |
| 3800 | struct sir_set_ht_vht_cfg { |
| 3801 | uint16_t msg_type; |
| 3802 | uint16_t len; |
| 3803 | uint32_t pdev_id; |
| 3804 | uint32_t nss; |
| 3805 | uint32_t dot11mode; |
| 3806 | }; |
| 3807 | |
Qiwei Cai | 3719efe | 2018-06-11 21:09:29 +0800 | [diff] [blame] | 3808 | #define WIFI_INVALID_PEER_ID (-1) |
| 3809 | #define WIFI_INVALID_VDEV_ID (-1) |
| 3810 | #define WIFI_MAX_AC (4) |
| 3811 | |
| 3812 | typedef struct { |
| 3813 | uint32_t paramId; |
| 3814 | uint8_t ifaceId; |
| 3815 | uint32_t rspId; |
| 3816 | uint32_t moreResultToFollow; |
| 3817 | uint32_t nr_received; |
| 3818 | union { |
| 3819 | uint32_t num_peers; |
| 3820 | uint32_t num_radio; |
| 3821 | }; |
| 3822 | |
| 3823 | uint32_t peer_event_number; |
| 3824 | /* Variable length field - Do not add anything after this */ |
| 3825 | uint8_t results[0]; |
| 3826 | } tSirLLStatsResults, *tpSirLLStatsResults; |
| 3827 | |
| 3828 | #ifdef WLAN_FEATURE_LINK_LAYER_STATS |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3829 | /*--------------------------------------------------------------------------- |
| 3830 | WLAN_HAL_LL_NOTIFY_STATS |
| 3831 | ---------------------------------------------------------------------------*/ |
| 3832 | |
| 3833 | /******************************LINK LAYER Statistics**********************/ |
| 3834 | |
| 3835 | typedef int tSirWifiRadio; |
| 3836 | typedef int tSirWifiChannel; |
| 3837 | typedef int tSirwifiTxRate; |
| 3838 | |
Qiwei Cai | 3719efe | 2018-06-11 21:09:29 +0800 | [diff] [blame] | 3839 | typedef struct { |
| 3840 | uint32_t reqId; |
| 3841 | uint8_t staId; |
| 3842 | uint32_t mpduSizeThreshold; |
| 3843 | uint32_t aggressiveStatisticsGathering; |
| 3844 | } tSirLLStatsSetReq, *tpSirLLStatsSetReq; |
| 3845 | |
| 3846 | typedef struct { |
| 3847 | uint32_t reqId; |
| 3848 | uint8_t staId; |
| 3849 | uint32_t paramIdMask; |
| 3850 | } tSirLLStatsGetReq, *tpSirLLStatsGetReq; |
| 3851 | |
| 3852 | typedef struct { |
| 3853 | uint32_t reqId; |
| 3854 | uint8_t staId; |
| 3855 | uint32_t statsClearReqMask; |
| 3856 | uint8_t stopReq; |
| 3857 | } tSirLLStatsClearReq, *tpSirLLStatsClearReq; |
| 3858 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3859 | /* channel operating width */ |
| 3860 | typedef enum { |
| 3861 | WIFI_CHAN_WIDTH_20 = 0, |
| 3862 | WIFI_CHAN_WIDTH_40 = 1, |
| 3863 | WIFI_CHAN_WIDTH_80 = 2, |
| 3864 | WIFI_CHAN_WIDTH_160 = 3, |
| 3865 | WIFI_CHAN_WIDTH_80P80 = 4, |
| 3866 | WIFI_CHAN_WIDTH_5 = 5, |
| 3867 | WIFI_CHAN_WIDTH_10 = 6, |
| 3868 | } tSirWifiChannelWidth; |
| 3869 | |
| 3870 | typedef enum { |
| 3871 | WIFI_DISCONNECTED = 0, |
| 3872 | WIFI_AUTHENTICATING = 1, |
| 3873 | WIFI_ASSOCIATING = 2, |
| 3874 | WIFI_ASSOCIATED = 3, |
| 3875 | WIFI_EAPOL_STARTED = 4, /* if done by firmware/driver */ |
| 3876 | WIFI_EAPOL_COMPLETED = 5, /* if done by firmware/driver */ |
| 3877 | } tSirWifiConnectionState; |
| 3878 | |
| 3879 | typedef enum { |
| 3880 | WIFI_ROAMING_IDLE = 0, |
| 3881 | WIFI_ROAMING_ACTIVE = 1, |
| 3882 | } tSirWifiRoamState; |
| 3883 | |
| 3884 | typedef enum { |
| 3885 | WIFI_INTERFACE_STA = 0, |
| 3886 | WIFI_INTERFACE_SOFTAP = 1, |
| 3887 | WIFI_INTERFACE_IBSS = 2, |
| 3888 | WIFI_INTERFACE_P2P_CLIENT = 3, |
| 3889 | WIFI_INTERFACE_P2P_GO = 4, |
| 3890 | WIFI_INTERFACE_NAN = 5, |
| 3891 | WIFI_INTERFACE_MESH = 6, |
Deepak Dhamdhere | c9acc44 | 2016-05-26 02:12:58 -0700 | [diff] [blame] | 3892 | WIFI_INTERFACE_NDI = 7, |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3893 | } tSirWifiInterfaceMode; |
| 3894 | |
| 3895 | /* set for QOS association */ |
| 3896 | #define WIFI_CAPABILITY_QOS 0x00000001 |
| 3897 | /* set for protected assoc (802.11 beacon frame control protected bit set) */ |
| 3898 | #define WIFI_CAPABILITY_PROTECTED 0x00000002 |
| 3899 | /* set if 802.11 Extended Capabilities element interworking bit is set */ |
| 3900 | #define WIFI_CAPABILITY_INTERWORKING 0x00000004 |
| 3901 | /* set for HS20 association */ |
| 3902 | #define WIFI_CAPABILITY_HS20 0x00000008 |
| 3903 | /* set is 802.11 Extended Capabilities element UTF-8 SSID bit is set */ |
| 3904 | #define WIFI_CAPABILITY_SSID_UTF8 0x00000010 |
| 3905 | /* set is 802.11 Country Element is present */ |
| 3906 | #define WIFI_CAPABILITY_COUNTRY 0x00000020 |
| 3907 | |
| 3908 | typedef struct { |
| 3909 | /* tSirWifiInterfaceMode */ |
| 3910 | /* interface mode */ |
| 3911 | uint8_t mode; |
| 3912 | /* interface mac address (self) */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3913 | struct qdf_mac_addr macAddr; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3914 | /* tSirWifiConnectionState */ |
| 3915 | /* connection state (valid for STA, CLI only) */ |
| 3916 | uint8_t state; |
| 3917 | /* tSirWifiRoamState */ |
| 3918 | /* roaming state */ |
| 3919 | uint32_t roaming; |
| 3920 | /* WIFI_CAPABILITY_XXX (self) */ |
| 3921 | uint32_t capabilities; |
| 3922 | /* null terminated SSID */ |
| 3923 | uint8_t ssid[33]; |
| 3924 | /* bssid */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 3925 | struct qdf_mac_addr bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3926 | /* country string advertised by AP */ |
| 3927 | uint8_t apCountryStr[WNI_CFG_COUNTRY_CODE_LEN]; |
| 3928 | /* country string for this association */ |
| 3929 | uint8_t countryStr[WNI_CFG_COUNTRY_CODE_LEN]; |
| 3930 | } tSirWifiInterfaceInfo, *tpSirWifiInterfaceInfo; |
| 3931 | |
| 3932 | /* channel information */ |
| 3933 | typedef struct { |
| 3934 | /* channel width (20, 40, 80, 80+80, 160) */ |
| 3935 | tSirWifiChannelWidth width; |
| 3936 | /* primary 20 MHz channel */ |
| 3937 | tSirWifiChannel centerFreq; |
| 3938 | /* center frequency (MHz) first segment */ |
| 3939 | tSirWifiChannel centerFreq0; |
| 3940 | /* center frequency (MHz) second segment */ |
| 3941 | tSirWifiChannel centerFreq1; |
| 3942 | } tSirWifiChannelInfo, *tpSirWifiChannelInfo; |
| 3943 | |
| 3944 | /* wifi rate info */ |
| 3945 | typedef struct { |
| 3946 | /* 0: OFDM, 1:CCK, 2:HT 3:VHT 4..7 reserved */ |
| 3947 | uint32_t preamble:3; |
| 3948 | /* 0:1x1, 1:2x2, 3:3x3, 4:4x4 */ |
| 3949 | uint32_t nss:2; |
| 3950 | /* 0:20MHz, 1:40Mhz, 2:80Mhz, 3:160Mhz */ |
| 3951 | uint32_t bw:3; |
| 3952 | /* OFDM/CCK rate code would be as per ieee std in units of 0.5mbps */ |
| 3953 | /* HT/VHT it would be mcs index */ |
| 3954 | uint32_t rateMcsIdx:8; |
| 3955 | /* reserved */ |
| 3956 | uint32_t reserved:16; |
| 3957 | /* units of 100 Kbps */ |
| 3958 | uint32_t bitrate; |
| 3959 | } tSirWifiRate, *tpSirWifiRate; |
| 3960 | |
| 3961 | /* channel statistics */ |
| 3962 | typedef struct { |
| 3963 | /* channel */ |
| 3964 | tSirWifiChannelInfo channel; |
| 3965 | /* msecs the radio is awake (32 bits number accruing over time) */ |
| 3966 | uint32_t onTime; |
| 3967 | /* msecs the CCA register is busy (32 bits number accruing over time) */ |
| 3968 | uint32_t ccaBusyTime; |
| 3969 | } tSirWifiChannelStats, *tpSirWifiChannelStats; |
| 3970 | |
Srinivas Girigowda | 458f228 | 2016-10-25 11:27:52 -0700 | [diff] [blame] | 3971 | #define MAX_TPC_LEVELS 64 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 3972 | /* radio statistics */ |
| 3973 | typedef struct { |
| 3974 | /* wifi radio (if multiple radio supported) */ |
| 3975 | tSirWifiRadio radio; |
| 3976 | /* msecs the radio is awake (32 bits number accruing over time) */ |
| 3977 | uint32_t onTime; |
| 3978 | /* msecs the radio is transmitting |
| 3979 | * (32 bits number accruing over time) |
| 3980 | */ |
| 3981 | uint32_t txTime; |
| 3982 | /* msecs the radio is in active receive |
| 3983 | *(32 bits number accruing over time) |
| 3984 | */ |
| 3985 | uint32_t rxTime; |
| 3986 | /* msecs the radio is awake due to all scan |
| 3987 | * (32 bits number accruing over time) |
| 3988 | */ |
| 3989 | uint32_t onTimeScan; |
| 3990 | /* msecs the radio is awake due to NAN |
| 3991 | * (32 bits number accruing over time) |
| 3992 | */ |
| 3993 | uint32_t onTimeNbd; |
| 3994 | /* msecs the radio is awake due to Gscan |
| 3995 | * (32 bits number accruing over time) |
| 3996 | */ |
| 3997 | uint32_t onTimeGscan; |
| 3998 | /* msecs the radio is awake due to roam?scan |
| 3999 | * (32 bits number accruing over time) |
| 4000 | */ |
| 4001 | uint32_t onTimeRoamScan; |
| 4002 | /* msecs the radio is awake due to PNO scan |
| 4003 | * (32 bits number accruing over time) |
| 4004 | */ |
| 4005 | uint32_t onTimePnoScan; |
| 4006 | /* msecs the radio is awake due to HS2.0 scans and GAS exchange |
| 4007 | * (32 bits number accruing over time) |
| 4008 | */ |
| 4009 | uint32_t onTimeHs20; |
Srinivas Girigowda | ad874a8 | 2016-10-25 14:08:00 -0700 | [diff] [blame] | 4010 | |
| 4011 | /* tx time (in milliseconds) per TPC level (0.5 dBm) */ |
| 4012 | uint32_t total_num_tx_power_levels; |
| 4013 | uint32_t *tx_time_per_power_level; |
| 4014 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4015 | /* number of channels */ |
| 4016 | uint32_t numChannels; |
Srinivas Girigowda | 458f228 | 2016-10-25 11:27:52 -0700 | [diff] [blame] | 4017 | |
| 4018 | /* tx time (in milliseconds) per TPC level (0.5 dBm) */ |
| 4019 | uint32_t tx_time_per_tpc[MAX_TPC_LEVELS]; |
| 4020 | |
Krishna Kumaar Natarajan | 7bff29b | 2017-03-08 16:05:05 -0800 | [diff] [blame] | 4021 | uint32_t on_time_host_scan; |
| 4022 | uint32_t on_time_lpi_scan; |
| 4023 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4024 | /* channel statistics tSirWifiChannelStats */ |
Srinivas Girigowda | 57b450e | 2016-10-27 21:00:46 -0700 | [diff] [blame] | 4025 | tSirWifiChannelStats *channels; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4026 | } tSirWifiRadioStat, *tpSirWifiRadioStat; |
| 4027 | |
| 4028 | /* per rate statistics */ |
| 4029 | typedef struct { |
| 4030 | /* rate information */ |
| 4031 | tSirWifiRate rate; |
| 4032 | /* number of successfully transmitted data pkts (ACK rcvd) */ |
| 4033 | uint32_t txMpdu; |
| 4034 | /* number of received data pkts */ |
| 4035 | uint32_t rxMpdu; |
| 4036 | /* number of data packet losses (no ACK) */ |
| 4037 | uint32_t mpduLost; |
| 4038 | /* total number of data pkt retries * */ |
| 4039 | uint32_t retries; |
| 4040 | /* number of short data pkt retries */ |
| 4041 | uint32_t retriesShort; |
| 4042 | /* number of long data pkt retries */ |
| 4043 | uint32_t retriesLong; |
| 4044 | } tSirWifiRateStat, *tpSirWifiRateStat; |
| 4045 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4046 | /* wifi peer type */ |
| 4047 | typedef enum { |
| 4048 | WIFI_PEER_STA, |
| 4049 | WIFI_PEER_AP, |
| 4050 | WIFI_PEER_P2P_GO, |
| 4051 | WIFI_PEER_P2P_CLIENT, |
| 4052 | WIFI_PEER_NAN, |
| 4053 | WIFI_PEER_TDLS, |
| 4054 | WIFI_PEER_INVALID, |
| 4055 | } tSirWifiPeerType; |
| 4056 | |
| 4057 | /* per peer statistics */ |
| 4058 | typedef struct { |
| 4059 | /* peer type (AP, TDLS, GO etc.) */ |
Dustin Brown | 877a5a9 | 2016-11-17 13:56:52 -0800 | [diff] [blame] | 4060 | enum wmi_peer_type type; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4061 | /* mac address */ |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 4062 | struct qdf_mac_addr peerMacAddress; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4063 | /* peer WIFI_CAPABILITY_XXX */ |
| 4064 | uint32_t capabilities; |
Zhang Qian | a6e9c10 | 2016-12-22 16:47:24 +0800 | [diff] [blame] | 4065 | union { |
| 4066 | /* peer power saving mode */ |
| 4067 | uint32_t power_saving; |
| 4068 | /* number of rates */ |
| 4069 | uint32_t numRate; |
| 4070 | }; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4071 | /* per rate statistics, number of entries = num_rate */ |
| 4072 | tSirWifiRateStat rateStats[0]; |
| 4073 | } tSirWifiPeerInfo, *tpSirWifiPeerInfo; |
| 4074 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4075 | /* Interface statistics - corresponding to 2nd most |
| 4076 | * LSB in wifi statistics bitmap for getting statistics |
| 4077 | */ |
| 4078 | typedef struct { |
| 4079 | /* current state of the interface */ |
| 4080 | tSirWifiInterfaceInfo info; |
Min Liu | ffb250d | 2018-07-11 17:35:32 +0800 | [diff] [blame] | 4081 | |
gaolez | b432ed9 | 2017-03-16 18:40:04 +0800 | [diff] [blame] | 4082 | uint32_t rts_succ_cnt; |
| 4083 | uint32_t rts_fail_cnt; |
| 4084 | uint32_t ppdu_succ_cnt; |
| 4085 | uint32_t ppdu_fail_cnt; |
Krishna Kumaar Natarajan | 7bff29b | 2017-03-08 16:05:05 -0800 | [diff] [blame] | 4086 | |
Min Liu | ffb250d | 2018-07-11 17:35:32 +0800 | [diff] [blame] | 4087 | /* link statistics */ |
| 4088 | wmi_iface_link_stats link_stats; |
Krishna Kumaar Natarajan | 7bff29b | 2017-03-08 16:05:05 -0800 | [diff] [blame] | 4089 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4090 | /* per ac data packet statistics */ |
Min Liu | ffb250d | 2018-07-11 17:35:32 +0800 | [diff] [blame] | 4091 | wmi_wmm_ac_stats ac_stats[WIFI_AC_MAX]; |
Krishna Kumaar Natarajan | 7bff29b | 2017-03-08 16:05:05 -0800 | [diff] [blame] | 4092 | |
| 4093 | uint32_t num_offload_stats; |
Min Liu | ffb250d | 2018-07-11 17:35:32 +0800 | [diff] [blame] | 4094 | wmi_iface_offload_stats offload_stats[WMI_OFFLOAD_STATS_TYPE_MAX]; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4095 | } tSirWifiIfaceStat, *tpSirWifiIfaceStat; |
| 4096 | |
| 4097 | /* Peer statistics - corresponding to 3rd most LSB in |
| 4098 | * wifi statistics bitmap for getting statistics |
| 4099 | */ |
| 4100 | typedef struct { |
| 4101 | /* number of peers */ |
| 4102 | uint32_t numPeers; |
| 4103 | /* per peer statistics */ |
| 4104 | tSirWifiPeerInfo peerInfo[0]; |
| 4105 | } tSirWifiPeerStat, *tpSirWifiPeerStat; |
| 4106 | |
| 4107 | /* wifi statistics bitmap for getting statistics */ |
| 4108 | #define WMI_LINK_STATS_RADIO 0x00000001 |
| 4109 | #define WMI_LINK_STATS_IFACE 0x00000002 |
| 4110 | #define WMI_LINK_STATS_ALL_PEER 0x00000004 |
| 4111 | #define WMI_LINK_STATS_PER_PEER 0x00000008 |
| 4112 | |
| 4113 | /* wifi statistics bitmap for clearing statistics */ |
| 4114 | /* all radio statistics */ |
| 4115 | #define WIFI_STATS_RADIO 0x00000001 |
| 4116 | /* cca_busy_time (within radio statistics) */ |
| 4117 | #define WIFI_STATS_RADIO_CCA 0x00000002 |
| 4118 | /* all channel statistics (within radio statistics) */ |
| 4119 | #define WIFI_STATS_RADIO_CHANNELS 0x00000004 |
| 4120 | /* all scan statistics (within radio statistics) */ |
| 4121 | #define WIFI_STATS_RADIO_SCAN 0x00000008 |
| 4122 | /* all interface statistics */ |
| 4123 | #define WIFI_STATS_IFACE 0x00000010 |
| 4124 | /* all tx rate statistics (within interface statistics) */ |
| 4125 | #define WIFI_STATS_IFACE_TXRATE 0x00000020 |
| 4126 | /* all ac statistics (within interface statistics) */ |
| 4127 | #define WIFI_STATS_IFACE_AC 0x00000040 |
| 4128 | /* all contention (min, max, avg) statistics (within ac statistics) */ |
| 4129 | #define WIFI_STATS_IFACE_CONTENTION 0x00000080 |
Mukul Sharma | 491021c | 2016-09-29 21:39:19 +0530 | [diff] [blame] | 4130 | /* All peer stats on this interface */ |
| 4131 | #define WIFI_STATS_IFACE_ALL_PEER 0x00000100 |
| 4132 | /* Clear particular peer stats depending on the peer_mac */ |
| 4133 | #define WIFI_STATS_IFACE_PER_PEER 0x00000200 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4134 | |
Zhang Qian | a6e9c10 | 2016-12-22 16:47:24 +0800 | [diff] [blame] | 4135 | /** |
| 4136 | * struct sir_wifi_iface_tx_fail - TX failure event |
| 4137 | * @tid: TX TID |
| 4138 | * @msdu_num: TX MSDU failed counter |
| 4139 | * @status: TX status from HTT message. |
| 4140 | * Only failure status will be involved. |
| 4141 | */ |
| 4142 | struct sir_wifi_iface_tx_fail { |
| 4143 | uint8_t tid; |
| 4144 | uint16_t msdu_num; |
| 4145 | enum htt_tx_status status; |
| 4146 | }; |
| 4147 | |
Zhang Qian | 73c348a | 2017-03-13 16:15:55 +0800 | [diff] [blame] | 4148 | /** |
| 4149 | * struct sir_wifi_chan_cca_stats - channal CCA stats |
| 4150 | * @vdev_id: vdev ID |
| 4151 | * @idle_time: percentage of idle time, no TX, no RX, no interference |
| 4152 | * @tx_time: percentage of time transmitting packets |
| 4153 | * @rx_in_bss_time: percentage of time receiving packets in current BSS |
| 4154 | * @rx_out_bss_time: percentage of time receiving packets not in current BSS |
| 4155 | * @rx_busy_time: percentage of time interference detected |
| 4156 | * @rx_in_bad_cond_time: percentage of time receiving packets with errors |
| 4157 | * or packets flagged as retransmission or seqnum discontinued. |
| 4158 | * @tx_in_bad_cond_time: percentage of time the device transmitted packets |
| 4159 | * that haven't been ACKed. |
| 4160 | * @wlan_not_avail_time: percentage of time the chip is unable to |
| 4161 | * work in normal conditions. |
| 4162 | */ |
| 4163 | struct sir_wifi_chan_cca_stats { |
| 4164 | uint32_t vdev_id; |
| 4165 | uint32_t idle_time; |
| 4166 | uint32_t tx_time; |
| 4167 | uint32_t rx_in_bss_time; |
| 4168 | uint32_t rx_out_bss_time; |
| 4169 | uint32_t rx_busy_time; |
| 4170 | uint32_t rx_in_bad_cond_time; |
| 4171 | uint32_t tx_in_bad_cond_time; |
| 4172 | uint32_t wlan_not_avail_time; |
| 4173 | }; |
| 4174 | |
| 4175 | #define WIFI_MAX_CHAINS 8 |
| 4176 | |
| 4177 | /** |
| 4178 | * struct sir_wifi_peer_signal_stats - peer signal stats |
| 4179 | * @vdev_id: vdev ID |
| 4180 | * @peer_id: peer ID |
| 4181 | * @per_ant_snr: per antenna SNR |
| 4182 | * @nf: peer background noise |
Zhang Qian | 303ebe9 | 2017-05-18 13:59:07 +0800 | [diff] [blame] | 4183 | * @per_ant_rx_mpdus: MPDUs received per antenna |
| 4184 | * @per_ant_tx_mpdus: MPDUs transferred per antenna |
| 4185 | * @num_chain: valid chain count |
Zhang Qian | 73c348a | 2017-03-13 16:15:55 +0800 | [diff] [blame] | 4186 | */ |
| 4187 | struct sir_wifi_peer_signal_stats { |
| 4188 | uint32_t vdev_id; |
| 4189 | uint32_t peer_id; |
| 4190 | |
| 4191 | /* per antenna SNR in current bss */ |
| 4192 | int32_t per_ant_snr[WIFI_MAX_CHAINS]; |
| 4193 | |
| 4194 | /* Background noise */ |
| 4195 | int32_t nf[WIFI_MAX_CHAINS]; |
Zhang Qian | 303ebe9 | 2017-05-18 13:59:07 +0800 | [diff] [blame] | 4196 | |
| 4197 | int32_t per_ant_rx_mpdus[WIFI_MAX_CHAINS]; |
| 4198 | int32_t per_ant_tx_mpdus[WIFI_MAX_CHAINS]; |
| 4199 | int32_t num_chain; |
Zhang Qian | 73c348a | 2017-03-13 16:15:55 +0800 | [diff] [blame] | 4200 | }; |
| 4201 | |
| 4202 | #define WIFI_VDEV_NUM 4 |
| 4203 | #define WFIF_MCS_NUM 10 |
| 4204 | #define WIFI_AGGR_NUM 8 |
| 4205 | #define WIFI_DELAY_SIZE 11 |
| 4206 | |
| 4207 | /** |
| 4208 | * struct sir_wifi_tx - per AC tx stats |
| 4209 | * @msdus: number of totoal MSDUs on MAC layer in the period |
| 4210 | * @mpdus: number of totoal MPDUs on MAC layer in the period |
| 4211 | * @ppdus: number of totoal PPDUs on PHY layer in the period |
| 4212 | * @bytes: bytes of tx data on MAC layer in the period |
| 4213 | * @drops: number of TX packets cancelled due to any reason in the period, |
| 4214 | * such as WMM limitation/bandwidth limitation/radio congestion |
| 4215 | * @drop_bytes: bytes of dropped TX packets in the period |
| 4216 | * @retries: number of unacked transmissions of MPDUs |
| 4217 | * @failed: number of packets have not been ACKed despite retried |
| 4218 | * @aggr_len: length of the MPDU aggregation size buffer |
| 4219 | * @mpdu_aggr_size: histogram of MPDU aggregation size |
| 4220 | * @success_mcs_len: length of success mcs buffer |
| 4221 | * @success_mcs: histogram of successed received MPDUs encoding rate |
| 4222 | * @fail_mcs_len: length of failed mcs buffer |
| 4223 | * @fail_mcs: histogram of failed received MPDUs encoding rate |
| 4224 | * @delay_len: length of the delay histofram buffer |
| 4225 | * @delay: histogram of delays on MAC layer |
| 4226 | */ |
| 4227 | struct sir_wifi_tx { |
| 4228 | uint32_t msdus; |
| 4229 | uint32_t mpdus; |
| 4230 | uint32_t ppdus; |
| 4231 | uint32_t bytes; |
| 4232 | uint32_t drops; |
| 4233 | uint32_t drop_bytes; |
| 4234 | uint32_t retries; |
| 4235 | uint32_t failed; |
| 4236 | uint32_t aggr_len; |
| 4237 | uint32_t *mpdu_aggr_size; |
| 4238 | uint32_t success_mcs_len; |
| 4239 | uint32_t *success_mcs; |
| 4240 | uint32_t fail_mcs_len; |
| 4241 | uint32_t *fail_mcs; |
| 4242 | uint32_t delay_len; |
| 4243 | uint32_t *delay; |
| 4244 | }; |
| 4245 | |
| 4246 | /** |
| 4247 | * struct sir_wifi_rx - per AC rx stats |
| 4248 | * @mpdus: number of RX packets on MAC layer |
| 4249 | * @bytes: bytes of RX packets on MAC layer |
| 4250 | * @ppdus: number of RX packets on PHY layer |
| 4251 | * @ppdu_bytes: bytes of RX packets on PHY layer |
| 4252 | * @mpdu_lost: number of discontinuity in seqnum |
| 4253 | * @mpdu_retry: number of RX packets flagged as retransmissions |
| 4254 | * @mpdu_dup: number of RX packets identified as duplicates |
| 4255 | * @mpdu_discard: number of RX packets discarded |
| 4256 | * @aggr_len: length of MPDU aggregation histogram buffer |
| 4257 | * @mpdu_aggr: histogram of MPDU aggregation size |
| 4258 | * @mcs_len: length of mcs histogram buffer |
| 4259 | * @mcs: histogram of encoding rate. |
| 4260 | */ |
| 4261 | struct sir_wifi_rx { |
| 4262 | uint32_t mpdus; |
| 4263 | uint32_t bytes; |
| 4264 | uint32_t ppdus; |
| 4265 | uint32_t ppdu_bytes; |
| 4266 | uint32_t mpdu_lost; |
| 4267 | uint32_t mpdu_retry; |
| 4268 | uint32_t mpdu_dup; |
| 4269 | uint32_t mpdu_discard; |
| 4270 | uint32_t aggr_len; |
| 4271 | uint32_t *mpdu_aggr; |
| 4272 | uint32_t mcs_len; |
| 4273 | uint32_t *mcs; |
| 4274 | }; |
| 4275 | |
| 4276 | /** |
| 4277 | * struct sir_wifi_ll_ext_wmm_ac_stats - stats for WMM AC |
| 4278 | * @type: WMM AC type |
| 4279 | * @tx_stats: pointer to TX stats |
| 4280 | * @rx_stats: pointer to RX stats |
| 4281 | */ |
| 4282 | struct sir_wifi_ll_ext_wmm_ac_stats { |
| 4283 | uint32_t type; |
| 4284 | struct sir_wifi_tx *tx_stats; |
| 4285 | struct sir_wifi_rx *rx_stats; |
| 4286 | }; |
| 4287 | |
Zhang Qian | 73c348a | 2017-03-13 16:15:55 +0800 | [diff] [blame] | 4288 | /** |
| 4289 | * struct sir_wifi_ll_ext_peer_stats - per peer stats |
| 4290 | * @peer_id: peer ID |
| 4291 | * @vdev_id: VDEV ID |
| 4292 | * mac_address: MAC address |
| 4293 | * @sta_ps_inds: how many times STAs go to sleep |
| 4294 | * @sta_ps_durs: total sleep time of STAs (units in ms) |
| 4295 | * @rx_probe_reqs: number of probe requests received |
| 4296 | * @rx_oth_mgmts: number of other management frames received, |
| 4297 | * not including probe requests |
| 4298 | * @peer_signal_stat: signal stats |
| 4299 | * @ac_stats: WMM BE/BK/VI/VO stats |
| 4300 | */ |
| 4301 | struct sir_wifi_ll_ext_peer_stats { |
| 4302 | uint32_t peer_id; |
| 4303 | uint32_t vdev_id; |
| 4304 | tSirMacAddr mac_address; |
| 4305 | uint32_t sta_ps_inds; |
| 4306 | uint32_t sta_ps_durs; |
| 4307 | uint32_t rx_probe_reqs; |
| 4308 | uint32_t rx_oth_mgmts; |
| 4309 | struct sir_wifi_peer_signal_stats peer_signal_stats; |
| 4310 | struct sir_wifi_ll_ext_wmm_ac_stats ac_stats[WIFI_MAX_AC]; |
| 4311 | }; |
| 4312 | |
| 4313 | /** |
| 4314 | * struct sir_wifi_ll_ext_stats - link layer stats report |
| 4315 | * @trigger_cond_id: Indicate what triggered this event. |
| 4316 | * 1: timeout. 2: threshold |
| 4317 | * @cca_chgd_bitmap: Bitmap to indicate changed channel CCA stats |
| 4318 | * which exceeded the thresholds |
| 4319 | * @sig_chgd_bitmap: Bitmap to indicate changed peer signal stats |
| 4320 | * which exceeded the thresholds |
| 4321 | * @tx_chgd_bitmap: Bitmap to indicate changed TX counters |
| 4322 | * which exceeded the thresholds |
| 4323 | * @rx_chgd_bitmap: Bitmap to indicate changed RX counters |
| 4324 | * which exceeded the thresholds |
| 4325 | * @chan_cca_stats: channel CCA stats |
| 4326 | * @peer_signal_stats: peer signal stats |
| 4327 | * @tx_mpdu_aggr_array_len: length of TX MPDU aggregation buffer |
| 4328 | * @tx_succ_mcs_array_len: length of mcs buffer for ACKed MPDUs |
| 4329 | * @tx_fail_mcs_array_len: length of mcs buffer for no-ACKed MPDUs |
| 4330 | * @tx_delay_array_len: length of delay stats buffer |
| 4331 | * @rx_mpdu_aggr_array_len: length of RX MPDU aggregation buffer |
| 4332 | * @rx_mcs_array_len: length of RX mcs stats buffer |
| 4333 | * @peer_stats: peer stats |
| 4334 | * @cca: physical channel CCA stats |
| 4335 | * @stats: pointer to stats data buffer. |
| 4336 | * |
| 4337 | * Structure of the whole statictics is like this: |
| 4338 | * --------------------------------- |
| 4339 | * | trigger_cond_i | |
| 4340 | * +-------------------------------+ |
| 4341 | * | cca_chgd_bitmap | |
| 4342 | * +-------------------------------+ |
| 4343 | * | sig_chgd_bitmap | |
| 4344 | * +-------------------------------+ |
| 4345 | * | tx_chgd_bitmap | |
| 4346 | * +-------------------------------+ |
| 4347 | * | rx_chgd_bitmap | |
| 4348 | * +-------------------------------+ |
| 4349 | * | peer_num | |
| 4350 | * +-------------------------------+ |
| 4351 | * | channel_num | |
| 4352 | * +-------------------------------+ |
| 4353 | * | tx_mpdu_aggr_array_len | |
| 4354 | * +-------------------------------+ |
| 4355 | * | tx_succ_mcs_array_len | |
| 4356 | * +-------------------------------+ |
| 4357 | * | tx_fail_mcs_array_len | |
| 4358 | * +-------------------------------+ |
| 4359 | * | tx_delay_array_len | |
| 4360 | * +-------------------------------+ |
| 4361 | * | rx_mpdu_aggr_array_len | |
| 4362 | * +-------------------------------+ |
| 4363 | * | rx_mcs_array_len | |
| 4364 | * +-------------------------------+ |
| 4365 | * | pointer to CCA stats | |
| 4366 | * +-------------------------------+ |
| 4367 | * | pointer to peer stats | |
| 4368 | * +-------------------------------+ |
| 4369 | * | CCA stats | |
| 4370 | * +-------------------------------+ |
| 4371 | * | peer_stats |----+ |
| 4372 | * +-------------------------------+ | |
| 4373 | * | per peer signals stats |<---+ |
| 4374 | * | peer0 ~ peern | | |
| 4375 | * +-------------------------------+ | |
| 4376 | * | TX aggr/mcs parameters array | | |
| 4377 | * | Length of this buffer is | | |
| 4378 | * | configurable for user layer. |<-+ | |
| 4379 | * +-------------------------------+ | | |
| 4380 | * | per peer tx stats |--+ | |
| 4381 | * | BE | <--+ |
| 4382 | * | BK | | |
| 4383 | * | VI | | |
| 4384 | * | VO | | |
| 4385 | * +-------------------------------+ | |
| 4386 | * | TX aggr/mcs parameters array | | |
| 4387 | * | Length of this buffer is | | |
| 4388 | * | configurable for user layer. |<-+ | |
| 4389 | * +-------------------------------+ | | |
| 4390 | * | peer peer rx stats |--+ | |
| 4391 | * | BE | <--+ |
| 4392 | * | BE | |
| 4393 | * | BK | |
| 4394 | * | VI | |
| 4395 | * | VO | |
| 4396 | * --------------------------------- |
| 4397 | */ |
| 4398 | struct sir_wifi_ll_ext_stats { |
| 4399 | uint32_t trigger_cond_id; |
| 4400 | uint32_t cca_chgd_bitmap; |
| 4401 | uint32_t sig_chgd_bitmap; |
| 4402 | uint32_t tx_chgd_bitmap; |
| 4403 | uint32_t rx_chgd_bitmap; |
| 4404 | uint8_t peer_num; |
| 4405 | uint8_t channel_num; |
| 4406 | uint32_t tx_mpdu_aggr_array_len; |
| 4407 | uint32_t tx_succ_mcs_array_len; |
| 4408 | uint32_t tx_fail_mcs_array_len; |
| 4409 | uint32_t tx_delay_array_len; |
| 4410 | uint32_t rx_mpdu_aggr_array_len; |
| 4411 | uint32_t rx_mcs_array_len; |
| 4412 | struct sir_wifi_ll_ext_peer_stats *peer_stats; |
| 4413 | struct sir_wifi_chan_cca_stats *cca; |
| 4414 | uint8_t stats[]; |
| 4415 | }; |
| 4416 | |
| 4417 | /** |
| 4418 | * struct sir_channel_cca_threshold - threshold for channel CCA |
| 4419 | * @idle_time: idle time, no TX, no RX, no interference |
| 4420 | * @tx_time: time transmitting packets |
| 4421 | * @rx_in_bss_time: time receiving packets in current BSSs |
| 4422 | * @rx_out_bss_time: time receiving packets not in current BSSs |
| 4423 | * @rx_busy_time: time interference detected |
| 4424 | * @rx_in_bad_cond_time: receiving packets with errors |
| 4425 | * @tx_in_bad_cond_time: time transmitted packets not been ACKed |
| 4426 | * @wlan_not_avail_time: wlan card cannot work |
| 4427 | */ |
| 4428 | struct sir_channel_cca_threshold { |
| 4429 | uint32_t idle_time; |
| 4430 | uint32_t tx_time; |
| 4431 | uint32_t rx_in_bss_time; |
| 4432 | uint32_t rx_out_bss_time; |
| 4433 | uint32_t rx_busy_time; |
| 4434 | uint32_t rx_in_bad_cond_time; |
| 4435 | uint32_t tx_in_bad_cond_time; |
| 4436 | uint32_t wlan_not_avail_time; |
| 4437 | }; |
| 4438 | |
| 4439 | /** |
| 4440 | * struct sir_signal_threshold - threshold for per peer sigbal |
| 4441 | * @snr: signal to noise rate |
| 4442 | * @nf: noise floor |
| 4443 | */ |
| 4444 | struct sir_signal_threshold { |
| 4445 | uint32_t snr; |
| 4446 | uint32_t nf; |
| 4447 | }; |
| 4448 | |
| 4449 | /** |
| 4450 | * struct sir_tx_threshold - threshold for TX |
| 4451 | * @msdu: TX MSDUs on MAC layer |
| 4452 | * @mpdu: TX MPDUs on MAC layer |
| 4453 | * @ppdu: TX PPDUs on MAC layer |
| 4454 | * @bytes: TX bytes on MAC layer |
| 4455 | * @msdu_drop: drooped MSDUs |
| 4456 | * @byte_drop: dropped Bytes |
| 4457 | * @mpdu_retry: MPDU not acked |
| 4458 | * @ppdu_fail: PPDUs which received no block ack |
| 4459 | * @aggregation: aggregation size |
| 4460 | * @succ_mcs: histogram of encoding rate for acked PPDUs |
| 4461 | * @fail_mcs: histogram of encoding rate for no-acked PPDUs |
| 4462 | */ |
| 4463 | struct sir_tx_threshold { |
| 4464 | uint32_t msdu; |
| 4465 | uint32_t mpdu; |
| 4466 | uint32_t ppdu; |
| 4467 | uint32_t bytes; |
| 4468 | uint32_t msdu_drop; |
| 4469 | uint32_t byte_drop; |
| 4470 | uint32_t mpdu_retry; |
| 4471 | uint32_t mpdu_fail; |
| 4472 | uint32_t ppdu_fail; |
| 4473 | uint32_t aggregation; |
| 4474 | uint32_t succ_mcs; |
| 4475 | uint32_t fail_mcs; |
| 4476 | uint32_t delay; |
| 4477 | }; |
| 4478 | |
| 4479 | /** |
| 4480 | * struct sir_rx_threshold - threshold for RX |
| 4481 | * @mpdu: RX MPDUs on MAC layer |
| 4482 | * @bytes: RX bytes on MAC layer |
| 4483 | * @ppdu: RX PPDU on PHY layer |
| 4484 | * @ppdu_bytes: RX bytes on PHY layer |
| 4485 | * @disorder: discontinuity in seqnum |
| 4486 | * @mpdu_retry: MPDUs flagged as retry |
| 4487 | * @mpdu_dup: MPDUs identified as duplicated |
| 4488 | * @aggregation: aggregation size |
| 4489 | * @mcs: histogram of encoding rate for PPDUs |
| 4490 | * @ps_inds: power save indication |
| 4491 | * @ps_durs: total time in power save |
| 4492 | * @probe_reqs: probe request received |
| 4493 | * @other_mgmt: other MGMT frames received |
| 4494 | */ |
| 4495 | struct sir_rx_threshold { |
| 4496 | uint32_t mpdu; |
| 4497 | uint32_t bytes; |
| 4498 | uint32_t ppdu; |
| 4499 | uint32_t ppdu_bytes; |
| 4500 | uint32_t disorder; |
| 4501 | uint32_t mpdu_lost; |
| 4502 | uint32_t mpdu_retry; |
| 4503 | uint32_t mpdu_dup; |
| 4504 | uint32_t mpdu_discard; |
| 4505 | uint32_t aggregation; |
| 4506 | uint32_t mcs; |
| 4507 | uint32_t ps_inds; |
| 4508 | uint32_t ps_durs; |
| 4509 | uint32_t probe_reqs; |
| 4510 | uint32_t other_mgmt; |
| 4511 | }; |
| 4512 | |
| 4513 | /** |
| 4514 | * struct sir_wifi_ll_ext_stats_threshold - Threshold for stats update |
| 4515 | * @period: MAC counter indication period (unit in ms) |
| 4516 | * @enable: if threshold mechnism is enabled or disabled |
| 4517 | * @enable_bitmap: whether dedicated threshold is enabed. |
| 4518 | * Every MAC counter has a dedicated threshold. If the dedicated |
| 4519 | * threshold is not set in the bitmap, global threshold will take |
| 4520 | * effect. |
| 4521 | * @global: whether clobal threshold is enabled. |
Jeff Johnson | f2cf659 | 2018-05-06 16:27:44 -0700 | [diff] [blame] | 4522 | * When both global and dedicated threshold are disabled, MAC counter |
Zhang Qian | 73c348a | 2017-03-13 16:15:55 +0800 | [diff] [blame] | 4523 | * will indicate stats periodically. |
| 4524 | * @global_threshold: global threshold value |
| 4525 | * @cca_bitmap: bitmap for CCA. |
| 4526 | * Bit0: idle time |
| 4527 | * Bit1: tx time |
| 4528 | * Bit2: RX in BSS |
| 4529 | * Bit3: RX out of BSS |
| 4530 | * Bit4: medium busy |
| 4531 | * Bit5: RX bad |
| 4532 | * Bit6: TX bad |
| 4533 | * Bit7: WLAN card not available |
| 4534 | * @signal_bitmap: |
| 4535 | * Bit0: Per channel SNR counter |
| 4536 | * Bit1: Per channel noise floor counter |
| 4537 | * @tx_bitmap: bitmap for TX counters |
| 4538 | * Bit0: TX counter unit in MSDU |
| 4539 | * Bit1: TX counter unit in MPDU |
| 4540 | * Bit2: TX counter unit in PPDU |
| 4541 | * Bit3: TX counter unit in byte |
| 4542 | * Bit4: Dropped MSDUs |
| 4543 | * Bit5: Dropped Bytes |
| 4544 | * Bit6: MPDU retry counter |
| 4545 | * Bit7: MPDU failure counter |
| 4546 | * Bit8: PPDU failure counter |
| 4547 | * Bit9: MPDU aggregation counter |
| 4548 | * Bit10: MCS counter for ACKed MPDUs |
| 4549 | * Bit11: MCS counter for Failed MPDUs |
| 4550 | * Bit12: TX Delay counter |
| 4551 | * @rx_bitmap:bitmap for RX counters |
| 4552 | * Bit0: MAC RX counter unit in MPDU |
| 4553 | * Bit1: MAC RX counter unit in byte |
| 4554 | * Bit2: PHY RX counter unit in PPDU |
| 4555 | * Bit3: PHY RX counter unit in byte |
| 4556 | * Bit4: Disorder counter |
| 4557 | * Bit5: Retry counter |
| 4558 | * Bit6: Duplication counter |
| 4559 | * Bit7: Discard counter |
| 4560 | * Bit8: MPDU aggregation size counter |
| 4561 | * Bit9: MCS counter |
| 4562 | * Bit10: Peer STA power state change (wake to sleep) counter |
| 4563 | * Bit11: Peer STA power save counter, total time in PS mode |
| 4564 | * Bit12: Probe request counter |
| 4565 | * Bit13: Other management frames counter |
| 4566 | * @cca_thresh: CCA threshold |
| 4567 | * @signal_thresh: signal threshold |
| 4568 | * @tx_thresh: TX threshold |
| 4569 | * @rx_thresh: RX threshold |
| 4570 | * |
| 4571 | * Generally, Link layer statistics is reported periodically. But if the |
| 4572 | * variation of one stats of compared to the pervious notification exceeds |
| 4573 | * a threshold, FW will report the new stats immediately. |
| 4574 | * This structure contains threshold for different counters. |
| 4575 | */ |
| 4576 | struct sir_ll_ext_stats_threshold { |
| 4577 | uint32_t period; |
| 4578 | uint32_t enable; |
| 4579 | uint32_t enable_bitmap; |
| 4580 | uint32_t global; |
| 4581 | uint32_t global_threshold; |
| 4582 | uint32_t cca_bitmap; |
| 4583 | uint32_t signal_bitmap; |
| 4584 | uint32_t tx_bitmap; |
| 4585 | uint32_t rx_bitmap; |
| 4586 | struct sir_channel_cca_threshold cca; |
| 4587 | struct sir_signal_threshold signal; |
| 4588 | struct sir_tx_threshold tx; |
| 4589 | struct sir_rx_threshold rx; |
| 4590 | }; |
| 4591 | |
| 4592 | #define LL_STATS_MIN_PERIOD 10 |
| 4593 | #define LL_STATS_INVALID_PERIOD 0xFFFFFFFF |
| 4594 | |
Zhang Qian | a6e9c10 | 2016-12-22 16:47:24 +0800 | [diff] [blame] | 4595 | /* Result ID for LL stats extension */ |
| 4596 | #define WMI_LL_STATS_EXT_PS_CHG 0x00000100 |
| 4597 | #define WMI_LL_STATS_EXT_TX_FAIL 0x00000200 |
| 4598 | #define WMI_LL_STATS_EXT_MAC_COUNTER 0x00000400 |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4599 | #endif /* WLAN_FEATURE_LINK_LAYER_STATS */ |
| 4600 | |
| 4601 | typedef struct sAniGetLinkStatus { |
| 4602 | uint16_t msgType; /* message type is same as the request type */ |
| 4603 | uint16_t msgLen; /* length of the entire request */ |
| 4604 | uint8_t linkStatus; |
| 4605 | uint8_t sessionId; |
| 4606 | } tAniGetLinkStatus, *tpAniGetLinkStatus; |
| 4607 | |
| 4608 | #ifdef DHCP_SERVER_OFFLOAD |
| 4609 | typedef struct { |
| 4610 | uint32_t vdev_id; |
| 4611 | uint32_t dhcpSrvOffloadEnabled; |
| 4612 | uint32_t dhcpClientNum; |
| 4613 | uint32_t dhcpSrvIP; |
| 4614 | } tSirDhcpSrvOffloadInfo, *tpSirDhcpSrvOffloadInfo; |
| 4615 | #endif /* DHCP_SERVER_OFFLOAD */ |
Sreelakshmi Konamki | 58c7243 | 2016-11-09 17:06:44 +0530 | [diff] [blame] | 4616 | |
| 4617 | /** |
| 4618 | * struct sir_lost_link_info - lost link information structure. |
| 4619 | * |
| 4620 | * @vdev_id: vdev_id from WMA. some modules call sessionId. |
| 4621 | * @rssi: rssi at disconnection time. |
| 4622 | * |
| 4623 | * driver uses this structure to communicate information collected at |
| 4624 | * disconnection time. |
| 4625 | */ |
| 4626 | struct sir_lost_link_info { |
| 4627 | uint32_t vdev_id; |
| 4628 | int32_t rssi; |
| 4629 | }; |
| 4630 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4631 | /* find the size of given member within a structure */ |
| 4632 | #ifndef member_size |
| 4633 | #define member_size(type, member) (sizeof(((type *)0)->member)) |
| 4634 | #endif |
| 4635 | |
| 4636 | #define RTT_INVALID 0x00 |
| 4637 | #define RTT_TIMING_MEAS_CAPABILITY 0x01 |
| 4638 | #define RTT_FINE_TIME_MEAS_INITIATOR_CAPABILITY 0x02 |
| 4639 | #define RTT_FINE_TIME_MEAS_RESPONDER_CAPABILITY 0x03 |
| 4640 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4641 | /* number of neighbor reports that we can handle in Neighbor Report Response */ |
| 4642 | #define MAX_SUPPORTED_NEIGHBOR_RPT 15 |
| 4643 | |
| 4644 | /** |
| 4645 | * struct sir_stats_avg_factor |
| 4646 | * @vdev_id: session id |
| 4647 | * @stats_avg_factor: average factor |
| 4648 | */ |
| 4649 | struct sir_stats_avg_factor { |
| 4650 | uint8_t vdev_id; |
| 4651 | uint16_t stats_avg_factor; |
| 4652 | }; |
| 4653 | |
| 4654 | /** |
| 4655 | * struct sir_guard_time_request |
| 4656 | * @vdev_id: session id |
| 4657 | * @guard_time: guard time |
| 4658 | */ |
| 4659 | struct sir_guard_time_request { |
| 4660 | uint8_t vdev_id; |
| 4661 | uint32_t guard_time; |
| 4662 | }; |
| 4663 | |
| 4664 | /* Max number of rates allowed in Supported Rates IE */ |
| 4665 | #define MAX_NUM_SUPPORTED_RATES (8) |
| 4666 | |
| 4667 | /* |
| 4668 | * struct rssi_monitor_req - rssi monitoring |
| 4669 | * @request_id: request id |
| 4670 | * @session_id: session id |
| 4671 | * @min_rssi: minimum rssi |
| 4672 | * @max_rssi: maximum rssi |
| 4673 | * @control: flag to indicate start or stop |
| 4674 | */ |
| 4675 | struct rssi_monitor_req { |
| 4676 | uint32_t request_id; |
| 4677 | uint32_t session_id; |
| 4678 | int8_t min_rssi; |
| 4679 | int8_t max_rssi; |
| 4680 | bool control; |
| 4681 | }; |
| 4682 | |
| 4683 | /** |
| 4684 | * struct rssi_breach_event - rssi breached event structure |
| 4685 | * @request_id: request id |
| 4686 | * @session_id: session id |
| 4687 | * @curr_rssi: current rssi |
| 4688 | * @curr_bssid: current bssid |
| 4689 | */ |
| 4690 | struct rssi_breach_event { |
| 4691 | uint32_t request_id; |
| 4692 | uint32_t session_id; |
| 4693 | int8_t curr_rssi; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 4694 | struct qdf_mac_addr curr_bssid; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4695 | }; |
| 4696 | |
Ravi Kumar Bokka | 05c14e5 | 2017-03-27 14:48:23 +0530 | [diff] [blame] | 4697 | /** |
| 4698 | * struct chip_pwr_save_fail_detected_params - chip power save failure detected |
| 4699 | * event params |
| 4700 | * @failure_reason_code:failure reason code |
| 4701 | * @wake_lock_bitmap:bitmap for modules voting against sleep for long duration. |
| 4702 | */ |
| 4703 | struct chip_pwr_save_fail_detected_params { |
| 4704 | uint32_t failure_reason_code; |
| 4705 | uint32_t wake_lock_bitmap[4]; |
| 4706 | }; |
| 4707 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4708 | #define MAX_NUM_FW_SEGMENTS 4 |
| 4709 | |
| 4710 | /** |
Deepak Dhamdhere | b106ae5 | 2016-08-10 20:55:30 +0530 | [diff] [blame] | 4711 | * DEFAULT_SCAN_IE_ID - Identifier for the collection of IE's added |
| 4712 | * by default to the probe request |
| 4713 | */ |
| 4714 | #define DEFAULT_SCAN_IE_ID 256 |
| 4715 | |
| 4716 | /* MAX_DEFAULT_SCAN_IE_LEN - Maxmimum length of Default Scan IE's */ |
Selvaraj, Sridhar | 021ee0a | 2017-04-07 16:53:31 +0530 | [diff] [blame] | 4717 | #define MAX_DEFAULT_SCAN_IE_LEN 2048 |
Deepak Dhamdhere | b106ae5 | 2016-08-10 20:55:30 +0530 | [diff] [blame] | 4718 | |
| 4719 | /* Extended Capabilities IE header(IE Id + IE Length) length */ |
| 4720 | #define EXT_CAP_IE_HDR_LEN 2 |
| 4721 | |
| 4722 | /** |
| 4723 | * struct hdd_default_scan_ie - HDD default scan IE structure |
| 4724 | * @message_type: message type to be set with eWNI_SME_DEFAULT_SCAN_IE |
| 4725 | * @length: length of the struct hdd_default_scan_ie |
| 4726 | * @session_id: Session Id |
| 4727 | * @ie_len: Default scan IE length |
| 4728 | * @ie_data: Pointer to default scan IE data |
| 4729 | */ |
| 4730 | struct hdd_default_scan_ie { |
| 4731 | uint16_t message_type; |
| 4732 | uint16_t length; |
| 4733 | uint16_t session_id; |
| 4734 | uint16_t ie_len; |
| 4735 | uint8_t ie_data[MAX_DEFAULT_SCAN_IE_LEN]; |
| 4736 | }; |
| 4737 | |
| 4738 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4739 | * struct vdev_ie_info - IE info |
| 4740 | * @vdev_id - vdev for which the IE is being sent |
| 4741 | * @ie_id - ID of the IE |
| 4742 | * @length - length of the IE data |
Naveen Rawat | 03e8d95 | 2016-08-01 15:22:20 -0700 | [diff] [blame] | 4743 | * @band - indicates IE is intended for which band |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4744 | * @data - IE data |
| 4745 | * |
| 4746 | * This structure is used to store the IE information. |
| 4747 | */ |
| 4748 | struct vdev_ie_info { |
| 4749 | uint32_t vdev_id; |
| 4750 | uint32_t ie_id; |
| 4751 | uint32_t length; |
Naveen Rawat | 03e8d95 | 2016-08-01 15:22:20 -0700 | [diff] [blame] | 4752 | uint32_t band; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4753 | uint8_t *data; |
| 4754 | }; |
| 4755 | |
| 4756 | /** |
| 4757 | * struct send_extcap_ie - used to pass send_extcap_ie msg from SME to PE |
| 4758 | * @type - MSG type |
| 4759 | * @length - length of the message |
| 4760 | * @seesion_id - session_id for which the message is intended for |
| 4761 | * |
| 4762 | * This structure is used to pass send_extcap_ie msg from SME to PE |
| 4763 | */ |
| 4764 | struct send_extcap_ie { |
| 4765 | uint16_t msg_type; /* eWNI_SME_SET_IE_REQ */ |
| 4766 | uint16_t length; |
| 4767 | uint8_t session_id; |
| 4768 | }; |
| 4769 | |
Dundi Raviteja | 6bb9e32 | 2018-05-16 17:04:41 +0530 | [diff] [blame] | 4770 | typedef void (*antenna_mode_cb)(uint32_t status, void *context); |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4771 | |
| 4772 | /** |
Kiran Kumar Lokere | ee20577 | 2018-09-27 00:27:27 -0700 | [diff] [blame] | 4773 | * struct cfg_action_frm_tb_ppdu - action frame TB PPDU cfg |
| 4774 | * @vdev_id - vdev id |
| 4775 | * @cfg - enable/disable |
| 4776 | * @frm_len - frame length |
| 4777 | * @data - frame data |
| 4778 | * |
| 4779 | * This structure is used to cfg action frame tb ppdu. |
| 4780 | */ |
| 4781 | struct cfg_action_frm_tb_ppdu { |
| 4782 | uint8_t vdev_id; |
| 4783 | uint8_t cfg; |
| 4784 | uint8_t frm_len; |
| 4785 | uint8_t *data; |
| 4786 | }; |
| 4787 | |
| 4788 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4789 | * struct sir_nss_update_request |
| 4790 | * @msgType: nss update msg type |
| 4791 | * @msgLen: length of the msg |
| 4792 | * @new_nss: new spatial stream value |
| 4793 | * @vdev_id: session id |
| 4794 | */ |
| 4795 | struct sir_nss_update_request { |
| 4796 | uint16_t msgType; |
| 4797 | uint16_t msgLen; |
| 4798 | uint8_t new_nss; |
| 4799 | uint32_t vdev_id; |
| 4800 | }; |
| 4801 | |
| 4802 | /** |
Abhishek Singh | fc740be | 2018-10-12 11:34:26 +0530 | [diff] [blame] | 4803 | * enum sir_bcn_update_reason: bcn update reason |
| 4804 | * @REASON_DEFAULT: reason default |
| 4805 | * @REASON_NSS_UPDATE: If NSS is updated |
| 4806 | * @REASON_CONFIG_UPDATE: Config update |
| 4807 | * @REASON_SET_HT2040: HT2040 update |
| 4808 | * @REASON_COLOR_CHANGE: Color change |
| 4809 | * @REASON_CHANNEL_SWITCH: channel switch |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4810 | */ |
Abhishek Singh | fc740be | 2018-10-12 11:34:26 +0530 | [diff] [blame] | 4811 | enum sir_bcn_update_reason { |
| 4812 | REASON_DEFAULT = 0, |
| 4813 | REASON_NSS_UPDATE = 1, |
| 4814 | REASON_CONFIG_UPDATE = 2, |
| 4815 | REASON_SET_HT2040 = 3, |
| 4816 | REASON_COLOR_CHANGE = 4, |
| 4817 | REASON_CHANNEL_SWITCH = 5, |
| 4818 | }; |
| 4819 | |
| 4820 | /** |
| 4821 | * struct sir_bcn_update_rsp |
| 4822 | * |
| 4823 | * @vdev_id: session for which bcn was updated |
| 4824 | * @reason: bcn update reason |
| 4825 | * @status: status of the beacon sent to FW |
| 4826 | */ |
| 4827 | struct sir_bcn_update_rsp { |
| 4828 | uint8_t vdev_id; |
| 4829 | enum sir_bcn_update_reason reason; |
| 4830 | QDF_STATUS status; |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4831 | }; |
| 4832 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4833 | struct sir_qos_params { |
| 4834 | uint8_t aifsn; |
| 4835 | uint8_t cwmin; |
| 4836 | uint8_t cwmax; |
| 4837 | }; |
| 4838 | |
| 4839 | /** |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4840 | * enum powersave_qpower_mode: QPOWER modes |
| 4841 | * @QPOWER_DISABLED: Qpower is disabled |
| 4842 | * @QPOWER_ENABLED: Qpower is enabled |
| 4843 | * @QPOWER_DUTY_CYCLING: Qpower is enabled with duty cycling |
| 4844 | */ |
| 4845 | enum powersave_qpower_mode { |
| 4846 | QPOWER_DISABLED = 0, |
| 4847 | QPOWER_ENABLED = 1, |
| 4848 | QPOWER_DUTY_CYCLING = 2 |
| 4849 | }; |
| 4850 | |
Ravi Joshi | 61c3c7a | 2015-11-09 18:41:20 -0800 | [diff] [blame] | 4851 | #ifdef FEATURE_LFR_SUBNET_DETECTION |
| 4852 | /** |
| 4853 | * struct gateway_param_update_req - gateway parameter update request |
| 4854 | * @request_id: request id |
| 4855 | * @session_id: session id |
| 4856 | * @max_retries: Max ARP/NS retry attempts |
| 4857 | * @timeout: Retry interval |
| 4858 | * @ipv4_addr_type: on ipv4 network |
| 4859 | * @ipv6_addr_type: on ipv6 network |
| 4860 | * @gw_mac_addr: gateway mac addr |
| 4861 | * @ipv4_addr: ipv4 addr |
| 4862 | * @ipv6_addr: ipv6 addr |
| 4863 | */ |
| 4864 | struct gateway_param_update_req { |
| 4865 | uint32_t request_id; |
| 4866 | uint32_t session_id; |
| 4867 | uint32_t max_retries; |
| 4868 | uint32_t timeout; |
| 4869 | uint32_t ipv4_addr_type; |
| 4870 | uint32_t ipv6_addr_type; |
Anurag Chouhan | 6d76066 | 2016-02-20 16:05:43 +0530 | [diff] [blame] | 4871 | struct qdf_mac_addr gw_mac_addr; |
| 4872 | uint8_t ipv4_addr[QDF_IPV4_ADDR_SIZE]; |
| 4873 | uint8_t ipv6_addr[QDF_IPV6_ADDR_SIZE]; |
Ravi Joshi | 61c3c7a | 2015-11-09 18:41:20 -0800 | [diff] [blame] | 4874 | }; |
| 4875 | #else |
| 4876 | struct gateway_param_update_req; |
| 4877 | #endif /* FEATURE_LFR_SUBNET_DETECTION */ |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 4878 | |
Abhishek Singh | 518323d | 2015-10-19 17:42:01 +0530 | [diff] [blame] | 4879 | /** |
| 4880 | * struct sir_sme_ext_change_chan_req - channel change request |
| 4881 | * @message_type: message id |
| 4882 | * @length: msg length |
| 4883 | * @new_channel: new channel |
| 4884 | * @session_id: session id |
| 4885 | */ |
| 4886 | struct sir_sme_ext_cng_chan_req { |
| 4887 | uint16_t message_type; /* eWNI_SME_EXT_CHANGE_CHANNEL */ |
| 4888 | uint16_t length; |
| 4889 | uint32_t new_channel; |
| 4890 | uint8_t session_id; |
| 4891 | }; |
| 4892 | |
| 4893 | /** |
| 4894 | * struct sir_sme_ext_change_chan_ind. |
| 4895 | * @session_id: session id |
| 4896 | * @new_channel: new channel to change |
| 4897 | */ |
| 4898 | struct sir_sme_ext_cng_chan_ind { |
| 4899 | uint8_t session_id; |
| 4900 | uint8_t new_channel; |
| 4901 | }; |
| 4902 | |
Ryan Hsu | 3c8f79f | 2015-12-02 16:45:09 -0800 | [diff] [blame] | 4903 | /** |
Manikandan Mohan | dcc21ba | 2016-03-15 14:31:56 -0700 | [diff] [blame] | 4904 | * struct stsf - the basic stsf structure |
| 4905 | * |
| 4906 | * @vdev_id: vdev id |
| 4907 | * @tsf_low: low 32bits of tsf |
| 4908 | * @tsf_high: high 32bits of tsf |
Manikandan Mohan | 5356c2b | 2016-04-03 15:51:35 -0700 | [diff] [blame] | 4909 | * @soc_timer_low: low 32bits of synced SOC timer value |
| 4910 | * @soc_timer_high: high 32bits of synced SOC timer value |
Manikandan Mohan | dcc21ba | 2016-03-15 14:31:56 -0700 | [diff] [blame] | 4911 | * |
| 4912 | * driver use this struct to store the tsf info |
| 4913 | */ |
| 4914 | struct stsf { |
| 4915 | uint32_t vdev_id; |
| 4916 | uint32_t tsf_low; |
| 4917 | uint32_t tsf_high; |
Manikandan Mohan | 5356c2b | 2016-04-03 15:51:35 -0700 | [diff] [blame] | 4918 | uint32_t soc_timer_low; |
| 4919 | uint32_t soc_timer_high; |
Manikandan Mohan | dcc21ba | 2016-03-15 14:31:56 -0700 | [diff] [blame] | 4920 | }; |
| 4921 | |
Gupta, Kapil | 4cb1d7d | 2016-04-16 18:16:25 -0700 | [diff] [blame] | 4922 | #define SIR_BCN_FLT_MAX_ELEMS_IE_LIST 8 |
| 4923 | /** |
| 4924 | * struct beacon_filter_param - parameters for beacon filtering |
| 4925 | * @vdev_id: vdev id |
| 4926 | * @ie_map: bitwise map of IEs that needs to be filtered |
| 4927 | * |
| 4928 | */ |
| 4929 | struct beacon_filter_param { |
| 4930 | uint32_t vdev_id; |
| 4931 | uint32_t ie_map[SIR_BCN_FLT_MAX_ELEMS_IE_LIST]; |
| 4932 | }; |
| 4933 | |
Chandrasekaran, Manishekar | 5c19dc5 | 2016-02-04 14:58:26 +0530 | [diff] [blame] | 4934 | /** |
Gupta, Kapil | 96c7f2f | 2016-04-25 19:13:41 +0530 | [diff] [blame] | 4935 | * struct adaptive_dwelltime_params - the adaptive dwelltime params |
| 4936 | * @vdev_id: vdev id |
| 4937 | * @is_enabled: Adaptive dwell time is enabled/disabled |
| 4938 | * @dwelltime_mode: global default adaptive dwell mode |
| 4939 | * @lpf_weight: weight to calculate the average low pass |
| 4940 | * filter for channel congestion |
| 4941 | * @passive_mon_intval: intval to monitor wifi activity in passive scan in msec |
| 4942 | * @wifi_act_threshold: % of wifi activity used in passive scan 0-100 |
| 4943 | * |
| 4944 | */ |
| 4945 | struct adaptive_dwelltime_params { |
| 4946 | uint32_t vdev_id; |
| 4947 | bool is_enabled; |
| 4948 | uint8_t dwelltime_mode; |
| 4949 | uint8_t lpf_weight; |
| 4950 | uint8_t passive_mon_intval; |
| 4951 | uint8_t wifi_act_threshold; |
| 4952 | }; |
| 4953 | |
| 4954 | /** |
Chandrasekaran, Manishekar | 5c19dc5 | 2016-02-04 14:58:26 +0530 | [diff] [blame] | 4955 | * struct csa_offload_params - CSA offload request parameters |
| 4956 | * @channel: channel |
| 4957 | * @switch_mode: switch mode |
| 4958 | * @sec_chan_offset: second channel offset |
| 4959 | * @new_ch_width: new channel width |
| 4960 | * @new_ch_freq_seg1: channel center freq 1 |
| 4961 | * @new_ch_freq_seg2: channel center freq 2 |
| 4962 | * @ies_present_flag: IE present flag |
| 4963 | */ |
| 4964 | struct csa_offload_params { |
| 4965 | uint8_t channel; |
| 4966 | uint8_t switch_mode; |
| 4967 | uint8_t sec_chan_offset; |
| 4968 | uint8_t new_ch_width; |
| 4969 | uint8_t new_op_class; |
| 4970 | uint8_t new_ch_freq_seg1; |
| 4971 | uint8_t new_ch_freq_seg2; |
| 4972 | uint32_t ies_present_flag; |
| 4973 | tSirMacAddr bssId; |
| 4974 | }; |
| 4975 | |
| 4976 | /** |
Sandeep Puligilla | e087566 | 2016-02-12 16:09:21 -0800 | [diff] [blame] | 4977 | * enum obss_ht40_scancmd_type - obss scan command type |
| 4978 | * @HT40_OBSS_SCAN_PARAM_START: OBSS scan start |
| 4979 | * @HT40_OBSS_SCAN_PARAM_UPDATE: OBSS scan param update |
| 4980 | */ |
| 4981 | enum obss_ht40_scancmd_type { |
| 4982 | HT40_OBSS_SCAN_PARAM_START, |
| 4983 | HT40_OBSS_SCAN_PARAM_UPDATE |
| 4984 | }; |
| 4985 | |
| 4986 | /** |
| 4987 | * struct sme_obss_ht40_scanind_msg - sme obss scan params |
| 4988 | * @msg_type: message type |
| 4989 | * @length: message length |
| 4990 | * @mac_addr: mac address |
| 4991 | */ |
| 4992 | struct sme_obss_ht40_scanind_msg { |
| 4993 | uint16_t msg_type; |
| 4994 | uint16_t length; |
| 4995 | struct qdf_mac_addr mac_addr; |
| 4996 | }; |
| 4997 | |
| 4998 | /** |
| 4999 | * struct obss_ht40_scanind - ht40 obss scan request |
| 5000 | * @cmd: message type |
| 5001 | * @scan_type: message length |
| 5002 | * @obss_passive_dwelltime: obss passive dwelltime |
| 5003 | * @obss_active_dwelltime: obss active dwelltime |
| 5004 | * @obss_width_trigger_interval: scan interval |
| 5005 | * @obss_passive_total_per_channel: total passive scan time per channel |
| 5006 | * @obss_active_total_per_channel: total active scan time per channel |
| 5007 | * @bsswidth_ch_trans_delay: OBSS transition delay time |
| 5008 | * @obss_activity_threshold: OBSS activity threshold |
| 5009 | * @self_sta_id: self sta identification |
| 5010 | * @bss_id: BSS index |
| 5011 | * @fortymhz_intolerent: Ht40mhz intolerance |
| 5012 | * @channel_count: channel count |
| 5013 | * @channels: channel information |
| 5014 | * @current_operatingclass: operating class |
| 5015 | * @iefield_len: ie's length |
| 5016 | * @iefiled: ie's information |
| 5017 | */ |
| 5018 | struct obss_ht40_scanind { |
| 5019 | enum obss_ht40_scancmd_type cmd; |
| 5020 | enum eSirScanType scan_type; |
| 5021 | /* In TUs */ |
| 5022 | uint16_t obss_passive_dwelltime; |
| 5023 | uint16_t obss_active_dwelltime; |
| 5024 | /* In seconds */ |
| 5025 | uint16_t obss_width_trigger_interval; |
| 5026 | /* In TU's */ |
| 5027 | uint16_t obss_passive_total_per_channel; |
| 5028 | uint16_t obss_active_total_per_channel; |
| 5029 | uint16_t bsswidth_ch_trans_delay; |
| 5030 | uint16_t obss_activity_threshold; |
| 5031 | uint8_t self_sta_idx; |
| 5032 | uint8_t bss_id; |
| 5033 | uint8_t fortymhz_intolerent; |
| 5034 | uint8_t channel_count; |
| 5035 | uint8_t channels[SIR_ROAM_MAX_CHANNELS]; |
| 5036 | uint8_t current_operatingclass; |
| 5037 | uint16_t iefield_len; |
| 5038 | uint8_t iefield[SIR_ROAM_SCAN_MAX_PB_REQ_SIZE]; |
| 5039 | }; |
| 5040 | |
| 5041 | /** |
| 5042 | * struct obss_scanparam - OBSS scan parameters |
| 5043 | * @obss_passive_dwelltime: message type |
| 5044 | * @obss_active_dwelltime: message length |
| 5045 | * @obss_width_trigger_interval: obss passive dwelltime |
| 5046 | * @obss_passive_total_per_channel: obss passive total scan time |
| 5047 | * @obss_active_total_per_channel: obss active total scan time |
| 5048 | * @bsswidth_ch_trans_delay: OBSS transition delay time |
| 5049 | * @obss_activity_threshold: OBSS activity threshold |
| 5050 | */ |
| 5051 | struct obss_scanparam { |
| 5052 | uint16_t obss_passive_dwelltime; |
| 5053 | uint16_t obss_active_dwelltime; |
| 5054 | uint16_t obss_width_trigger_interval; |
| 5055 | uint16_t obss_passive_total_per_channel; |
| 5056 | uint16_t obss_active_total_per_channel; |
| 5057 | uint16_t bsswidth_ch_trans_delay; |
| 5058 | uint16_t obss_activity_threshold; |
| 5059 | }; |
| 5060 | |
Arun Khandavalli | 2476ef5 | 2016-04-26 20:19:43 +0530 | [diff] [blame] | 5061 | /** |
Nachiket Kukade | e547a48 | 2018-05-22 16:43:30 +0530 | [diff] [blame] | 5062 | * struct sir_apf_set_offload - set apf filter instructions |
Arun Khandavalli | 2476ef5 | 2016-04-26 20:19:43 +0530 | [diff] [blame] | 5063 | * @session_id: session identifier |
Nachiket Kukade | e547a48 | 2018-05-22 16:43:30 +0530 | [diff] [blame] | 5064 | * @version: host apf version |
| 5065 | * @filter_id: Filter ID for APF filter |
Arun Khandavalli | 2476ef5 | 2016-04-26 20:19:43 +0530 | [diff] [blame] | 5066 | * @total_length: The total length of the full instruction |
| 5067 | * total_length equal to 0 means reset |
| 5068 | * @current_offset: current offset, 0 means start a new setting |
| 5069 | * @current_length: Length of current @program |
Nachiket Kukade | e547a48 | 2018-05-22 16:43:30 +0530 | [diff] [blame] | 5070 | * @program: APF instructions |
Arun Khandavalli | 2476ef5 | 2016-04-26 20:19:43 +0530 | [diff] [blame] | 5071 | */ |
Nachiket Kukade | e547a48 | 2018-05-22 16:43:30 +0530 | [diff] [blame] | 5072 | struct sir_apf_set_offload { |
Arun Khandavalli | 2476ef5 | 2016-04-26 20:19:43 +0530 | [diff] [blame] | 5073 | uint8_t session_id; |
| 5074 | uint32_t version; |
| 5075 | uint32_t filter_id; |
| 5076 | uint32_t total_length; |
| 5077 | uint32_t current_offset; |
| 5078 | uint32_t current_length; |
| 5079 | uint8_t *program; |
| 5080 | }; |
| 5081 | |
| 5082 | /** |
Nachiket Kukade | e547a48 | 2018-05-22 16:43:30 +0530 | [diff] [blame] | 5083 | * struct sir_apf_offload_capabilities - get apf Capabilities |
| 5084 | * @apf_version: fw's implement version |
| 5085 | * @max_apf_filters: max filters that fw supports |
| 5086 | * @max_bytes_for_apf_inst: the max bytes that can be used as apf instructions |
Arun Khandavalli | 2476ef5 | 2016-04-26 20:19:43 +0530 | [diff] [blame] | 5087 | */ |
Nachiket Kukade | e547a48 | 2018-05-22 16:43:30 +0530 | [diff] [blame] | 5088 | struct sir_apf_get_offload { |
| 5089 | uint32_t apf_version; |
| 5090 | uint32_t max_apf_filters; |
| 5091 | uint32_t max_bytes_for_apf_inst; |
Arun Khandavalli | 2476ef5 | 2016-04-26 20:19:43 +0530 | [diff] [blame] | 5092 | }; |
| 5093 | |
Naveen Rawat | 3ff5cff | 2018-01-29 14:31:16 -0800 | [diff] [blame] | 5094 | #ifndef QCA_SUPPORT_CP_STATS |
Sandeep Puligilla | 607f34a | 2016-05-25 14:37:47 -0700 | [diff] [blame] | 5095 | /** |
Padma, Santhosh Kumar | 5e33beb | 2016-08-08 19:07:06 +0530 | [diff] [blame] | 5096 | * struct sir_wake_lock_stats - wake lock stats structure |
Dustin Brown | 9d797d6 | 2017-01-11 16:39:12 -0800 | [diff] [blame] | 5097 | * @wow_unspecified_wake_up_count: number of non-wow related wake ups |
Padma, Santhosh Kumar | 5e33beb | 2016-08-08 19:07:06 +0530 | [diff] [blame] | 5098 | * @wow_ucast_wake_up_count: Unicast wakeup count |
| 5099 | * @wow_bcast_wake_up_count: Broadcast wakeup count |
| 5100 | * @wow_ipv4_mcast_wake_up_count: ipv4 multicast wakeup count |
| 5101 | * @wow_ipv6_mcast_wake_up_count: ipv6 multicast wakeup count |
| 5102 | * @wow_ipv6_mcast_ra_stats: ipv6 multicast ra stats |
| 5103 | * @wow_ipv6_mcast_ns_stats: ipv6 multicast ns stats |
| 5104 | * @wow_ipv6_mcast_na_stats: ipv6 multicast na stats |
Sreelakshmi Konamki | e1cd51f | 2016-08-19 16:58:24 +0530 | [diff] [blame] | 5105 | * @wow_icmpv4_count: ipv4 icmp packet count |
Himanshu Agarwal | 4574e28 | 2016-08-10 15:22:45 +0530 | [diff] [blame] | 5106 | * @wow_icmpv6_count: ipv6 icmp packet count |
Poddar, Siddarth | c01681a | 2016-12-21 18:36:30 +0530 | [diff] [blame] | 5107 | * @wow_rssi_breach_wake_up_count: rssi breach wakeup count |
| 5108 | * @wow_low_rssi_wake_up_count: low rssi wakeup count |
| 5109 | * @wow_gscan_wake_up_count: gscan wakeup count |
| 5110 | * @wow_pno_complete_wake_up_count: pno complete wakeup count |
| 5111 | * @wow_pno_match_wake_up_count: pno match wakeup count |
Dustin Brown | 9d797d6 | 2017-01-11 16:39:12 -0800 | [diff] [blame] | 5112 | * @wow_oem_response_wake_up_count: oem response wakeup count |
Ravi Kumar Bokka | 05c14e5 | 2017-03-27 14:48:23 +0530 | [diff] [blame] | 5113 | * @pwr_save_fail_detected: pwr save fail detected wakeup count |
Padma, Santhosh Kumar | 5e33beb | 2016-08-08 19:07:06 +0530 | [diff] [blame] | 5114 | */ |
| 5115 | struct sir_wake_lock_stats { |
Dustin Brown | 9d797d6 | 2017-01-11 16:39:12 -0800 | [diff] [blame] | 5116 | uint32_t wow_unspecified_wake_up_count; |
Padma, Santhosh Kumar | 5e33beb | 2016-08-08 19:07:06 +0530 | [diff] [blame] | 5117 | uint32_t wow_ucast_wake_up_count; |
| 5118 | uint32_t wow_bcast_wake_up_count; |
| 5119 | uint32_t wow_ipv4_mcast_wake_up_count; |
| 5120 | uint32_t wow_ipv6_mcast_wake_up_count; |
| 5121 | uint32_t wow_ipv6_mcast_ra_stats; |
| 5122 | uint32_t wow_ipv6_mcast_ns_stats; |
| 5123 | uint32_t wow_ipv6_mcast_na_stats; |
Sreelakshmi Konamki | e1cd51f | 2016-08-19 16:58:24 +0530 | [diff] [blame] | 5124 | uint32_t wow_icmpv4_count; |
Himanshu Agarwal | 4574e28 | 2016-08-10 15:22:45 +0530 | [diff] [blame] | 5125 | uint32_t wow_icmpv6_count; |
Poddar, Siddarth | c01681a | 2016-12-21 18:36:30 +0530 | [diff] [blame] | 5126 | uint32_t wow_rssi_breach_wake_up_count; |
| 5127 | uint32_t wow_low_rssi_wake_up_count; |
| 5128 | uint32_t wow_gscan_wake_up_count; |
| 5129 | uint32_t wow_pno_complete_wake_up_count; |
| 5130 | uint32_t wow_pno_match_wake_up_count; |
Dustin Brown | 9d797d6 | 2017-01-11 16:39:12 -0800 | [diff] [blame] | 5131 | uint32_t wow_oem_response_wake_up_count; |
Ravi Kumar Bokka | 05c14e5 | 2017-03-27 14:48:23 +0530 | [diff] [blame] | 5132 | uint32_t pwr_save_fail_detected; |
Dustin Brown | 9d797d6 | 2017-01-11 16:39:12 -0800 | [diff] [blame] | 5133 | }; |
| 5134 | |
| 5135 | /** |
| 5136 | * struct sir_vdev_wow_stats - container for per vdev wow related stat counters |
| 5137 | * @ucast: Unicast wakeup count |
| 5138 | * @bcast: Broadcast wakeup count |
| 5139 | * @ipv4_mcast: ipv4 multicast wakeup count |
| 5140 | * @ipv6_mcast: ipv6 multicast wakeup count |
| 5141 | * @ipv6_mcast_ra: ipv6 multicast ra stats |
| 5142 | * @ipv6_mcast_ns: ipv6 multicast ns stats |
| 5143 | * @ipv6_mcast_na: ipv6 multicast na stats |
| 5144 | * @icmpv4: ipv4 icmp packet count |
| 5145 | * @icmpv6: ipv6 icmp packet count |
| 5146 | * @rssi_breach: rssi breach wakeup count |
| 5147 | * @low_rssi: low rssi wakeup count |
| 5148 | * @gscan: gscan wakeup count |
| 5149 | * @pno_complete: pno complete wakeup count |
| 5150 | * @pno_match: pno match wakeup count |
Amar Singhal | 5eb9acb | 2017-05-26 15:25:27 -0700 | [diff] [blame] | 5151 | * @oem_response: oem response wakeup coun |
| 5152 | * @scan_11d: 11d scan wakeup count |
Dustin Brown | 9d797d6 | 2017-01-11 16:39:12 -0800 | [diff] [blame] | 5153 | */ |
| 5154 | struct sir_vdev_wow_stats { |
| 5155 | uint32_t ucast; |
| 5156 | uint32_t bcast; |
| 5157 | uint32_t ipv4_mcast; |
| 5158 | uint32_t ipv6_mcast; |
| 5159 | uint32_t ipv6_mcast_ra; |
| 5160 | uint32_t ipv6_mcast_ns; |
| 5161 | uint32_t ipv6_mcast_na; |
| 5162 | uint32_t icmpv4; |
| 5163 | uint32_t icmpv6; |
| 5164 | uint32_t rssi_breach; |
| 5165 | uint32_t low_rssi; |
| 5166 | uint32_t gscan; |
| 5167 | uint32_t pno_complete; |
| 5168 | uint32_t pno_match; |
| 5169 | uint32_t oem_response; |
Ravi Kumar Bokka | 05c14e5 | 2017-03-27 14:48:23 +0530 | [diff] [blame] | 5170 | uint32_t pwr_save_fail_detected; |
Amar Singhal | 5eb9acb | 2017-05-26 15:25:27 -0700 | [diff] [blame] | 5171 | uint32_t scan_11d; |
Padma, Santhosh Kumar | 5e33beb | 2016-08-08 19:07:06 +0530 | [diff] [blame] | 5172 | }; |
Naveen Rawat | 3ff5cff | 2018-01-29 14:31:16 -0800 | [diff] [blame] | 5173 | #endif |
Padma, Santhosh Kumar | 5e33beb | 2016-08-08 19:07:06 +0530 | [diff] [blame] | 5174 | |
| 5175 | /** |
Sandeep Puligilla | 607f34a | 2016-05-25 14:37:47 -0700 | [diff] [blame] | 5176 | * enum ht_capability_fields - HT Capabilities bit fields |
| 5177 | * @HT_CAPS_LDPC: ldpc coding capability bit field |
| 5178 | * @HT_CAPS_SUPPORTED_CHANNEL_SET: channel width set bit field |
| 5179 | * @HT_CAPS_SM_PWR_SAVE: SM power save bit field |
| 5180 | * @HT_CAPS_GREENFIELD: greenfield capability bit field |
| 5181 | * @HT_CAPS_SHORT_GI20: short GI 20 bit field |
| 5182 | * @HT_CAPS_SHORT_GI40: short GI 40 bit field |
| 5183 | * @HT_CAPS_TX_STBC: Tx STBC bit field |
| 5184 | * @HT_CAPS_RX_STBC: Rx STBC bit fields |
| 5185 | */ |
| 5186 | enum ht_capability_fields { |
| 5187 | HT_CAPS_LDPC = 0x0001, |
| 5188 | HT_CAPS_SUPPORTED_CHANNEL_SET = 0x0002, |
| 5189 | HT_CAPS_SM_PWR_SAVE = 0x000c, |
| 5190 | HT_CAPS_GREENFIELD = 0x0010, |
| 5191 | HT_CAPS_SHORT_GI20 = 0x0020, |
| 5192 | HT_CAPS_SHORT_GI40 = 0x0040, |
| 5193 | HT_CAPS_TX_STBC = 0x0080, |
| 5194 | HT_CAPS_RX_STBC = 0x0300 |
| 5195 | }; |
| 5196 | |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5197 | #ifdef WLAN_FEATURE_NAN_DATAPATH |
| 5198 | |
| 5199 | #define IFACE_NAME_SIZE 64 |
| 5200 | |
| 5201 | /** |
| 5202 | * enum ndp_accept_policy - nan data path accept policy |
| 5203 | * @NDP_ACCEPT_POLICY_NONE: the framework will decide the policy |
| 5204 | * @NDP_ACCEPT_POLICY_ALL: accept policy offloaded to fw |
| 5205 | * |
| 5206 | */ |
| 5207 | enum ndp_accept_policy { |
| 5208 | NDP_ACCEPT_POLICY_NONE = 0, |
| 5209 | NDP_ACCEPT_POLICY_ALL = 1, |
| 5210 | }; |
| 5211 | |
| 5212 | /** |
| 5213 | * enum ndp_self_role - nan data path role |
| 5214 | * @NDP_ROLE_INITIATOR: initiator of nan data path request |
| 5215 | * @NDP_ROLE_RESPONDER: responder to nan data path request |
| 5216 | * |
| 5217 | */ |
| 5218 | enum ndp_self_role { |
| 5219 | NDP_ROLE_INITIATOR = 0, |
| 5220 | NDP_ROLE_RESPONDER = 1, |
| 5221 | }; |
| 5222 | |
| 5223 | /** |
| 5224 | * enum ndp_response_code - responder's response code to nan data path request |
| 5225 | * @NDP_RESPONSE_ACCEPT: ndp request accepted |
| 5226 | * @NDP_RESPONSE_REJECT: ndp request rejected |
| 5227 | * @NDP_RESPONSE_DEFER: ndp request deferred until later (response to follow |
| 5228 | * any time later) |
| 5229 | * |
| 5230 | */ |
| 5231 | enum ndp_response_code { |
| 5232 | NDP_RESPONSE_ACCEPT = 0, |
| 5233 | NDP_RESPONSE_REJECT = 1, |
| 5234 | NDP_RESPONSE_DEFER = 2, |
| 5235 | }; |
| 5236 | |
| 5237 | /** |
Deepak Dhamdhere | a6d2f4c | 2016-06-04 00:24:52 -0700 | [diff] [blame] | 5238 | * enum ndp_end_type - NDP end type |
| 5239 | * @NDP_END_TYPE_UNSPECIFIED: type is unspecified |
| 5240 | * @NDP_END_TYPE_PEER_UNAVAILABLE: type is peer unavailable |
| 5241 | * @NDP_END_TYPE_OTA_FRAME: NDP end frame received from peer |
| 5242 | * |
| 5243 | */ |
| 5244 | enum ndp_end_type { |
| 5245 | NDP_END_TYPE_UNSPECIFIED = 0x00, |
| 5246 | NDP_END_TYPE_PEER_UNAVAILABLE = 0x01, |
| 5247 | NDP_END_TYPE_OTA_FRAME = 0x02, |
| 5248 | }; |
| 5249 | |
| 5250 | /** |
| 5251 | * enum ndp_end_reason_code - NDP end reason code |
| 5252 | * @NDP_END_REASON_UNSPECIFIED: reason is unspecified |
| 5253 | * @NDP_END_REASON_INACTIVITY: reason is peer inactivity |
| 5254 | * @NDP_END_REASON_PEER_DATA_END: data end indication received from peer |
| 5255 | * |
| 5256 | */ |
| 5257 | enum ndp_end_reason_code { |
| 5258 | NDP_END_REASON_UNSPECIFIED = 0x00, |
| 5259 | NDP_END_REASON_INACTIVITY = 0x01, |
| 5260 | NDP_END_REASON_PEER_DATA_END = 0x02, |
| 5261 | }; |
| 5262 | |
| 5263 | /** |
Naveen Rawat | 8d63a59 | 2016-06-29 18:30:59 -0700 | [diff] [blame] | 5264 | * enum nan_status_type - NDP status type |
| 5265 | * @NDP_RSP_STATUS_SUCCESS: request was successful |
| 5266 | * @NDP_RSP_STATUS_ERROR: request failed |
| 5267 | */ |
| 5268 | enum nan_status_type { |
| 5269 | NDP_RSP_STATUS_SUCCESS = 0x00, |
| 5270 | NDP_RSP_STATUS_ERROR = 0x01, |
| 5271 | }; |
| 5272 | |
| 5273 | /** |
| 5274 | * enum nan_reason_code - NDP command rsp reason code value |
| 5275 | * @NDP_UNSUPPORTED_CONCURRENCY: Will be used in unsupported concurrency cases |
| 5276 | * @NDP_NAN_DATA_IFACE_CREATE_FAILED: ndi create failed |
| 5277 | * @NDP_NAN_DATA_IFACE_DELETE_FAILED: ndi delete failed |
| 5278 | * @NDP_DATA_INITIATOR_REQ_FAILED: data initiator request failed |
| 5279 | * @NDP_DATA_RESPONDER_REQ_FAILED: data responder request failed |
| 5280 | * @NDP_INVALID_SERVICE_INSTANCE_ID: invalid service instance id |
| 5281 | * @NDP_INVALID_NDP_INSTANCE_ID: invalid ndp instance id |
| 5282 | * @NDP_INVALID_RSP_CODE: invalid response code in ndp responder request |
| 5283 | * @NDP_INVALID_APP_INFO_LEN: invalid app info length |
| 5284 | * @NDP_NMF_REQ_FAIL: OTA nan mgmt frame failure for data request |
| 5285 | * @NDP_NMF_RSP_FAIL: OTA nan mgmt frame failure for data response |
| 5286 | * @NDP_NMF_CNF_FAIL: OTA nan mgmt frame failure for confirm |
| 5287 | * @NDP_END_FAILED: ndp end failed |
| 5288 | * @NDP_NMF_END_REQ_FAIL: OTA nan mgmt frame failure for data end |
| 5289 | * @NDP_VENDOR_SPECIFIC_ERROR: other vendor specific failures |
| 5290 | */ |
| 5291 | enum nan_reason_code { |
| 5292 | NDP_UNSUPPORTED_CONCURRENCY = 9000, |
| 5293 | NDP_NAN_DATA_IFACE_CREATE_FAILED = 9001, |
| 5294 | NDP_NAN_DATA_IFACE_DELETE_FAILED = 9002, |
| 5295 | NDP_DATA_INITIATOR_REQ_FAILED = 9003, |
| 5296 | NDP_DATA_RESPONDER_REQ_FAILED = 9004, |
| 5297 | NDP_INVALID_SERVICE_INSTANCE_ID = 9005, |
| 5298 | NDP_INVALID_NDP_INSTANCE_ID = 9006, |
| 5299 | NDP_INVALID_RSP_CODE = 9007, |
| 5300 | NDP_INVALID_APP_INFO_LEN = 9008, |
| 5301 | NDP_NMF_REQ_FAIL = 9009, |
| 5302 | NDP_NMF_RSP_FAIL = 9010, |
| 5303 | NDP_NMF_CNF_FAIL = 9011, |
| 5304 | NDP_END_FAILED = 9012, |
| 5305 | NDP_NMF_END_REQ_FAIL = 9013, |
| 5306 | /* 9500 onwards vendor specific error codes */ |
| 5307 | NDP_VENDOR_SPECIFIC_ERROR = 9500, |
| 5308 | }; |
| 5309 | |
| 5310 | /** |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5311 | * struct ndp_cfg - ndp configuration |
| 5312 | * @tag: unique identifier |
| 5313 | * @ndp_cfg_len: ndp configuration length |
| 5314 | * @ndp_cfg: variable length ndp configuration |
| 5315 | * |
| 5316 | */ |
| 5317 | struct ndp_cfg { |
| 5318 | uint32_t tag; |
| 5319 | uint32_t ndp_cfg_len; |
Deepak Dhamdhere | 0f076bd | 2016-06-02 11:29:21 -0700 | [diff] [blame] | 5320 | uint8_t *ndp_cfg; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5321 | }; |
| 5322 | |
| 5323 | /** |
| 5324 | * struct ndp_qos_cfg - ndp qos configuration |
| 5325 | * @tag: unique identifier |
| 5326 | * @ndp_qos_cfg_len: ndp qos configuration length |
| 5327 | * @ndp_qos_cfg: variable length ndp qos configuration |
| 5328 | * |
| 5329 | */ |
| 5330 | struct ndp_qos_cfg { |
| 5331 | uint32_t tag; |
| 5332 | uint32_t ndp_qos_cfg_len; |
| 5333 | uint8_t ndp_qos_cfg[]; |
| 5334 | }; |
| 5335 | |
| 5336 | /** |
| 5337 | * struct ndp_app_info - application info shared during ndp setup |
| 5338 | * @tag: unique identifier |
| 5339 | * @ndp_app_info_len: ndp app info length |
| 5340 | * @ndp_app_info: variable length application information |
| 5341 | * |
| 5342 | */ |
| 5343 | struct ndp_app_info { |
| 5344 | uint32_t tag; |
| 5345 | uint32_t ndp_app_info_len; |
Deepak Dhamdhere | 0f076bd | 2016-06-02 11:29:21 -0700 | [diff] [blame] | 5346 | uint8_t *ndp_app_info; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5347 | }; |
| 5348 | |
| 5349 | /** |
Naveen Rawat | 4f3983e | 2016-11-29 16:12:09 -0800 | [diff] [blame] | 5350 | * struct ndp_scid - structure to hold sceurity context identifier |
| 5351 | * @scid_len: length of scid |
| 5352 | * @scid: scid |
| 5353 | * |
| 5354 | */ |
| 5355 | struct ndp_scid { |
| 5356 | uint32_t scid_len; |
| 5357 | uint8_t *scid; |
| 5358 | }; |
| 5359 | |
| 5360 | /** |
| 5361 | * struct ndp_pmk - structure to hold pairwise master key |
| 5362 | * @pmk_len: length of pairwise master key |
| 5363 | * @pmk: buffer containing pairwise master key |
| 5364 | * |
| 5365 | */ |
| 5366 | struct ndp_pmk { |
| 5367 | uint32_t pmk_len; |
| 5368 | uint8_t *pmk; |
| 5369 | }; |
| 5370 | |
| 5371 | /** |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5372 | * struct ndi_create_req - ndi create request params |
| 5373 | * @transaction_id: unique identifier |
| 5374 | * @iface_name: interface name |
| 5375 | * |
| 5376 | */ |
| 5377 | struct ndi_create_req { |
| 5378 | uint32_t transaction_id; |
| 5379 | char iface_name[IFACE_NAME_SIZE]; |
| 5380 | }; |
| 5381 | |
| 5382 | /** |
| 5383 | * struct ndi_create_rsp - ndi create response params |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5384 | * @status: request status |
| 5385 | * @reason: reason if any |
| 5386 | * |
| 5387 | */ |
| 5388 | struct ndi_create_rsp { |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5389 | uint32_t status; |
| 5390 | uint32_t reason; |
Rakesh Sunki | cf1c9ab | 2016-08-25 14:11:25 -0700 | [diff] [blame] | 5391 | uint8_t sta_id; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5392 | }; |
| 5393 | |
| 5394 | /** |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5395 | * struct ndi_delete_rsp - ndi delete response params |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5396 | * @status: request status |
| 5397 | * @reason: reason if any |
| 5398 | * |
| 5399 | */ |
| 5400 | struct ndi_delete_rsp { |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5401 | uint32_t status; |
| 5402 | uint32_t reason; |
| 5403 | }; |
| 5404 | |
| 5405 | /** |
| 5406 | * struct ndp_initiator_req - ndp initiator request params |
| 5407 | * @transaction_id: unique identifier |
| 5408 | * @vdev_id: session id of the interface over which ndp is being created |
| 5409 | * @channel: suggested channel for ndp creation |
Naveen Rawat | 0a01705 | 2016-10-19 14:17:07 -0700 | [diff] [blame] | 5410 | * @channel_cfg: channel config, 0=no channel, 1=optional, 2=mandatory |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5411 | * @service_instance_id: Service identifier |
| 5412 | * @peer_discovery_mac_addr: Peer's discovery mac address |
| 5413 | * @self_ndi_mac_addr: self NDI mac address |
| 5414 | * @ndp_config: ndp configuration params |
| 5415 | * @ndp_info: ndp application info |
Naveen Rawat | 4f3983e | 2016-11-29 16:12:09 -0800 | [diff] [blame] | 5416 | * @ncs_sk_type: indicates NCS_SK_128 or NCS_SK_256 |
| 5417 | * @pmk: pairwise master key |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5418 | * |
| 5419 | */ |
| 5420 | struct ndp_initiator_req { |
| 5421 | uint32_t transaction_id; |
| 5422 | uint32_t vdev_id; |
| 5423 | uint32_t channel; |
Naveen Rawat | 0a01705 | 2016-10-19 14:17:07 -0700 | [diff] [blame] | 5424 | uint32_t channel_cfg; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5425 | uint32_t service_instance_id; |
| 5426 | struct qdf_mac_addr peer_discovery_mac_addr; |
| 5427 | struct qdf_mac_addr self_ndi_mac_addr; |
| 5428 | struct ndp_cfg ndp_config; |
| 5429 | struct ndp_app_info ndp_info; |
Naveen Rawat | 4f3983e | 2016-11-29 16:12:09 -0800 | [diff] [blame] | 5430 | uint32_t ncs_sk_type; |
| 5431 | struct ndp_pmk pmk; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5432 | }; |
| 5433 | |
| 5434 | /** |
Deepak Dhamdhere | 0f076bd | 2016-06-02 11:29:21 -0700 | [diff] [blame] | 5435 | * struct ndp_initiator_rsp - response event from FW |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5436 | * @transaction_id: unique identifier |
| 5437 | * @vdev_id: session id of the interface over which ndp is being created |
| 5438 | * @ndp_instance_id: locally created NDP instance ID |
| 5439 | * @status: status of the ndp request |
| 5440 | * @reason: reason for failure if any |
| 5441 | * |
| 5442 | */ |
Deepak Dhamdhere | 0f076bd | 2016-06-02 11:29:21 -0700 | [diff] [blame] | 5443 | struct ndp_initiator_rsp { |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5444 | uint32_t transaction_id; |
| 5445 | uint32_t vdev_id; |
| 5446 | uint32_t ndp_instance_id; |
| 5447 | uint32_t status; |
Naveen Rawat | 8d63a59 | 2016-06-29 18:30:59 -0700 | [diff] [blame] | 5448 | uint32_t reason; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5449 | }; |
| 5450 | |
| 5451 | /** |
| 5452 | * struct ndp_indication_event - create ndp indication on the responder |
| 5453 | * @vdev_id: session id of the interface over which ndp is being created |
| 5454 | * @service_instance_id: Service identifier |
| 5455 | * @peer_discovery_mac_addr: Peer's discovery mac address |
Deepak Dhamdhere | 0f076bd | 2016-06-02 11:29:21 -0700 | [diff] [blame] | 5456 | * @peer_mac_addr: Peer's NDI mac address |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5457 | * @ndp_initiator_mac_addr: NDI mac address of the peer initiating NDP |
| 5458 | * @ndp_instance_id: locally created NDP instance ID |
| 5459 | * @role: self role for NDP |
| 5460 | * @ndp_accept_policy: accept policy configured by the upper layer |
| 5461 | * @ndp_config: ndp configuration params |
| 5462 | * @ndp_info: ndp application info |
Naveen Rawat | 4f3983e | 2016-11-29 16:12:09 -0800 | [diff] [blame] | 5463 | * @ncs_sk_type: indicates NCS_SK_128 or NCS_SK_256 |
| 5464 | * @scid: security context identifier |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5465 | * |
| 5466 | */ |
| 5467 | struct ndp_indication_event { |
| 5468 | uint32_t vdev_id; |
| 5469 | uint32_t service_instance_id; |
| 5470 | struct qdf_mac_addr peer_discovery_mac_addr; |
Deepak Dhamdhere | 0f076bd | 2016-06-02 11:29:21 -0700 | [diff] [blame] | 5471 | struct qdf_mac_addr peer_mac_addr; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5472 | uint32_t ndp_instance_id; |
| 5473 | enum ndp_self_role role; |
| 5474 | enum ndp_accept_policy policy; |
| 5475 | struct ndp_cfg ndp_config; |
| 5476 | struct ndp_app_info ndp_info; |
Naveen Rawat | 4f3983e | 2016-11-29 16:12:09 -0800 | [diff] [blame] | 5477 | uint32_t ncs_sk_type; |
| 5478 | struct ndp_scid scid; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5479 | }; |
| 5480 | |
| 5481 | /** |
| 5482 | * struct ndp_responder_req - responder's response to ndp create request |
| 5483 | * @transaction_id: unique identifier |
| 5484 | * @vdev_id: session id of the interface over which ndp is being created |
| 5485 | * @ndp_instance_id: locally created NDP instance ID |
| 5486 | * @ndp_rsp: response to the ndp create request |
| 5487 | * @ndp_config: ndp configuration params |
| 5488 | * @ndp_info: ndp application info |
Naveen Rawat | 4f3983e | 2016-11-29 16:12:09 -0800 | [diff] [blame] | 5489 | * @pmk: pairwise master key |
| 5490 | * @ncs_sk_type: indicates NCS_SK_128 or NCS_SK_256 |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5491 | * |
| 5492 | */ |
| 5493 | struct ndp_responder_req { |
| 5494 | uint32_t transaction_id; |
| 5495 | uint32_t vdev_id; |
| 5496 | uint32_t ndp_instance_id; |
| 5497 | enum ndp_response_code ndp_rsp; |
| 5498 | struct ndp_cfg ndp_config; |
| 5499 | struct ndp_app_info ndp_info; |
Naveen Rawat | 4f3983e | 2016-11-29 16:12:09 -0800 | [diff] [blame] | 5500 | struct ndp_pmk pmk; |
| 5501 | uint32_t ncs_sk_type; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5502 | }; |
| 5503 | |
| 5504 | /** |
| 5505 | * struct ndp_responder_rsp_event - response to responder's request |
| 5506 | * @transaction_id: unique identifier |
| 5507 | * @vdev_id: session id of the interface over which ndp is being created |
| 5508 | * @status: command status |
| 5509 | * @reason: reason for failure if any |
Abhishek Singh | 4fef747 | 2016-06-06 11:36:03 -0700 | [diff] [blame] | 5510 | * @peer_mac_addr: Peer's mac address |
Rakesh Sunki | d92d108 | 2017-01-04 15:14:28 -0800 | [diff] [blame] | 5511 | * @create_peer: Flag to indicate to create peer |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5512 | */ |
| 5513 | struct ndp_responder_rsp_event { |
| 5514 | uint32_t transaction_id; |
| 5515 | uint32_t vdev_id; |
| 5516 | uint32_t status; |
| 5517 | uint32_t reason; |
Abhishek Singh | 4fef747 | 2016-06-06 11:36:03 -0700 | [diff] [blame] | 5518 | struct qdf_mac_addr peer_mac_addr; |
Rakesh Sunki | d92d108 | 2017-01-04 15:14:28 -0800 | [diff] [blame] | 5519 | bool create_peer; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5520 | }; |
| 5521 | |
| 5522 | /** |
| 5523 | * struct ndp_confirm_event - ndp confirmation event from FW |
| 5524 | * @vdev_id: session id of the interface over which ndp is being created |
| 5525 | * @ndp_instance_id: ndp instance id for which confirm is being generated |
Naveen Rawat | 460be78 | 2016-06-29 18:26:22 -0700 | [diff] [blame] | 5526 | * @reason_code : reason code(opaque to driver) |
| 5527 | * @num_active_ndps_on_peer: number of ndp instances on peer |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5528 | * @peer_ndi_mac_addr: peer NDI mac address |
| 5529 | * @rsp_code: ndp response code |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5530 | * @ndp_info: ndp application info |
| 5531 | * |
| 5532 | */ |
| 5533 | struct ndp_confirm_event { |
| 5534 | uint32_t vdev_id; |
| 5535 | uint32_t ndp_instance_id; |
Naveen Rawat | 460be78 | 2016-06-29 18:26:22 -0700 | [diff] [blame] | 5536 | uint32_t reason_code; |
| 5537 | uint32_t num_active_ndps_on_peer; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5538 | struct qdf_mac_addr peer_ndi_mac_addr; |
| 5539 | enum ndp_response_code rsp_code; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5540 | struct ndp_app_info ndp_info; |
| 5541 | }; |
| 5542 | |
| 5543 | /** |
| 5544 | * struct ndp_end_req - ndp end request |
| 5545 | * @transaction_id: unique transaction identifier |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5546 | * @num_ndp_instances: number of ndp instances to be terminated |
Naveen Rawat | f28315c | 2016-06-29 18:06:02 -0700 | [diff] [blame] | 5547 | * @ndp_ids: pointer to array of ndp_instance_id to be terminated |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5548 | * |
| 5549 | */ |
| 5550 | struct ndp_end_req { |
| 5551 | uint32_t transaction_id; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5552 | uint32_t num_ndp_instances; |
Naveen Rawat | f28315c | 2016-06-29 18:06:02 -0700 | [diff] [blame] | 5553 | uint32_t *ndp_ids; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5554 | }; |
| 5555 | |
| 5556 | /** |
| 5557 | * struct peer_ndp_map - mapping of NDP instances to peer to VDEV |
| 5558 | * @vdev_id: session id of the interface over which ndp is being created |
| 5559 | * @peer_ndi_mac_addr: peer NDI mac address |
| 5560 | * @num_active_ndp_sessions: number of active NDP sessions on the peer |
Deepak Dhamdhere | a6d2f4c | 2016-06-04 00:24:52 -0700 | [diff] [blame] | 5561 | * @type: NDP end indication type |
| 5562 | * @reason_code: NDP end indication reason code |
| 5563 | * @ndp_instance_id: NDP instance ID |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5564 | * |
| 5565 | */ |
| 5566 | struct peer_ndp_map { |
| 5567 | uint32_t vdev_id; |
| 5568 | struct qdf_mac_addr peer_ndi_mac_addr; |
| 5569 | uint32_t num_active_ndp_sessions; |
Deepak Dhamdhere | a6d2f4c | 2016-06-04 00:24:52 -0700 | [diff] [blame] | 5570 | enum ndp_end_type type; |
| 5571 | enum ndp_end_reason_code reason_code; |
| 5572 | uint32_t ndp_instance_id; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5573 | }; |
| 5574 | |
| 5575 | /** |
| 5576 | * struct ndp_end_rsp_event - firmware response to ndp end request |
| 5577 | * @transaction_id: unique identifier for the request |
Naveen Rawat | f28315c | 2016-06-29 18:06:02 -0700 | [diff] [blame] | 5578 | * @status: status of operation |
| 5579 | * @reason: reason(opaque to host driver) |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5580 | * |
| 5581 | */ |
| 5582 | struct ndp_end_rsp_event { |
| 5583 | uint32_t transaction_id; |
Naveen Rawat | f28315c | 2016-06-29 18:06:02 -0700 | [diff] [blame] | 5584 | uint32_t status; |
| 5585 | uint32_t reason; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5586 | }; |
| 5587 | |
| 5588 | /** |
| 5589 | * struct ndp_end_indication_event - ndp termination notification from FW |
Deepak Dhamdhere | a6d2f4c | 2016-06-04 00:24:52 -0700 | [diff] [blame] | 5590 | * @num_ndp_ids: number of NDP ids |
| 5591 | * @ndp_map: mapping of NDP instances to peer and vdev |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5592 | * |
| 5593 | */ |
| 5594 | struct ndp_end_indication_event { |
Deepak Dhamdhere | a6d2f4c | 2016-06-04 00:24:52 -0700 | [diff] [blame] | 5595 | uint32_t num_ndp_ids; |
Ravi Joshi | 412f23d | 2016-05-26 15:09:23 -0700 | [diff] [blame] | 5596 | struct peer_ndp_map ndp_map[]; |
| 5597 | }; |
| 5598 | |
| 5599 | /** |
| 5600 | * struct ndp_schedule_update_req - ndp schedule update request |
| 5601 | * @transaction_id: unique identifier |
| 5602 | * @vdev_id: session id of the interface over which ndp is being created |
| 5603 | * @ndp_instance_id: ndp instance id for which schedule update is requested |
| 5604 | * @ndp_qos: new set of qos parameters |
| 5605 | * |
| 5606 | */ |
| 5607 | struct ndp_schedule_update_req { |
| 5608 | uint32_t transaction_id; |
| 5609 | uint32_t vdev_id; |
| 5610 | uint32_t ndp_instance_id; |
| 5611 | struct ndp_qos_cfg ndp_qos; |
| 5612 | }; |
| 5613 | |
| 5614 | /** |
| 5615 | * struct ndp_schedule_update_rsp - ndp schedule update response |
| 5616 | * @transaction_id: unique identifier |
| 5617 | * @vdev_id: session id of the interface over which ndp is being created |
| 5618 | * @status: status of the request |
| 5619 | * @reason: reason code for failure if any |
| 5620 | * |
| 5621 | */ |
| 5622 | struct ndp_schedule_update_rsp { |
| 5623 | uint32_t transaction_id; |
| 5624 | uint32_t vdev_id; |
| 5625 | uint32_t status; |
| 5626 | uint32_t reason; |
| 5627 | }; |
| 5628 | |
| 5629 | /** |
| 5630 | * struct sme_ndp_peer_ind - ndp peer indication |
| 5631 | * @msg_type: message id |
| 5632 | * @msg_len: message length |
| 5633 | * @session_id: session id |
| 5634 | * @peer_mac_addr: peer mac address |
| 5635 | * @sta_id: station id |
| 5636 | * |
| 5637 | */ |
| 5638 | struct sme_ndp_peer_ind { |
| 5639 | uint16_t msg_type; |
| 5640 | uint16_t msg_len; |
| 5641 | uint8_t session_id; |
| 5642 | struct qdf_mac_addr peer_mac_addr; |
| 5643 | uint16_t sta_id; |
| 5644 | }; |
| 5645 | |
| 5646 | #endif /* WLAN_FEATURE_NAN_DATAPATH */ |
| 5647 | |
Peng Xu | 8fdaa49 | 2016-06-22 10:20:47 -0700 | [diff] [blame] | 5648 | /** |
Padma, Santhosh Kumar | a711967 | 2016-08-16 16:05:14 +0530 | [diff] [blame] | 5649 | * struct sir_set_tx_rx_aggregation_size - sets tx rx aggregation size |
| 5650 | * @vdev_id: vdev id of the session |
Arif Hussain | 0e24680 | 2018-05-01 18:13:44 -0700 | [diff] [blame] | 5651 | * @aggr_type: TX Aggregation Type (0=A-MPDU, 1=A-MSDU) |
Padma, Santhosh Kumar | a711967 | 2016-08-16 16:05:14 +0530 | [diff] [blame] | 5652 | * @tx_aggregation_size: Tx aggregation size |
Paul Zhang | ee09f8e | 2018-04-23 16:11:32 +0800 | [diff] [blame] | 5653 | * @tx_aggregation_size_be: Tx aggregation size for be queue |
| 5654 | * @tx_aggregation_size_bk: Tx aggregation size for bk queue |
| 5655 | * @tx_aggregation_size_vi: Tx aggregation size for vi queue |
| 5656 | * @tx_aggregation_size_vo: Tx aggregation size for vo queue |
Padma, Santhosh Kumar | a711967 | 2016-08-16 16:05:14 +0530 | [diff] [blame] | 5657 | * @rx_aggregation_size: Rx aggregation size |
| 5658 | */ |
| 5659 | struct sir_set_tx_rx_aggregation_size { |
| 5660 | uint8_t vdev_id; |
Arif Hussain | 0e24680 | 2018-05-01 18:13:44 -0700 | [diff] [blame] | 5661 | wmi_vdev_custom_aggr_type_t aggr_type; |
Padma, Santhosh Kumar | a711967 | 2016-08-16 16:05:14 +0530 | [diff] [blame] | 5662 | uint32_t tx_aggregation_size; |
Paul Zhang | ee09f8e | 2018-04-23 16:11:32 +0800 | [diff] [blame] | 5663 | uint32_t tx_aggregation_size_be; |
| 5664 | uint32_t tx_aggregation_size_bk; |
| 5665 | uint32_t tx_aggregation_size_vi; |
| 5666 | uint32_t tx_aggregation_size_vo; |
Padma, Santhosh Kumar | a711967 | 2016-08-16 16:05:14 +0530 | [diff] [blame] | 5667 | uint32_t rx_aggregation_size; |
| 5668 | }; |
| 5669 | |
| 5670 | /** |
stonez | 26388d0 | 2018-10-17 13:37:48 +0800 | [diff] [blame] | 5671 | * struct sir_set_tx_sw_retry_threshold - set sw retry threshold |
Paul Zhang | 33fae27 | 2018-04-23 16:19:00 +0800 | [diff] [blame] | 5672 | * @vdev_id: vdev id of the session |
stonez | 26388d0 | 2018-10-17 13:37:48 +0800 | [diff] [blame] | 5673 | * @tx_aggr_sw_retry_threshold_be: aggr sw retry threshold for BE |
| 5674 | * @tx_aggr_sw_retry_threshold_bk: aggr sw retry threshold for BK |
| 5675 | * @tx_aggr_sw_retry_threshold_vi: aggr sw retry threshold for VI |
| 5676 | * @tx_aggr_sw_retry_threshold_vo: aggr sw retry threshold for VO |
| 5677 | * @tx_non_aggr_sw_retry_threshold_be: non aggr sw retry threshold for BE |
| 5678 | * @tx_non_aggr_sw_retry_threshold_bk: non aggr sw retry threshold for BK |
| 5679 | * @tx_non_aggr_sw_retry_threshold_vi: non aggr sw retry threshold for VI |
| 5680 | * @tx_non_aggr_sw_retry_threshold_vo: non aggr sw retry threshold for VO |
Paul Zhang | 33fae27 | 2018-04-23 16:19:00 +0800 | [diff] [blame] | 5681 | */ |
stonez | 26388d0 | 2018-10-17 13:37:48 +0800 | [diff] [blame] | 5682 | struct sir_set_tx_sw_retry_threshold { |
Paul Zhang | 33fae27 | 2018-04-23 16:19:00 +0800 | [diff] [blame] | 5683 | uint8_t vdev_id; |
| 5684 | uint32_t tx_aggr_sw_retry_threshold_be; |
| 5685 | uint32_t tx_aggr_sw_retry_threshold_bk; |
| 5686 | uint32_t tx_aggr_sw_retry_threshold_vi; |
| 5687 | uint32_t tx_aggr_sw_retry_threshold_vo; |
stonez | 26388d0 | 2018-10-17 13:37:48 +0800 | [diff] [blame] | 5688 | uint32_t tx_non_aggr_sw_retry_threshold_be; |
| 5689 | uint32_t tx_non_aggr_sw_retry_threshold_bk; |
| 5690 | uint32_t tx_non_aggr_sw_retry_threshold_vi; |
| 5691 | uint32_t tx_non_aggr_sw_retry_threshold_vo; |
Paul Zhang | 33fae27 | 2018-04-23 16:19:00 +0800 | [diff] [blame] | 5692 | }; |
| 5693 | |
| 5694 | /** |
Peng Xu | 8fdaa49 | 2016-06-22 10:20:47 -0700 | [diff] [blame] | 5695 | * struct sir_p2p_lo_start - p2p listen offload start |
| 5696 | * @vdev_id: vdev identifier |
| 5697 | * @ctl_flags: control flag |
| 5698 | * @freq: p2p listen frequency |
| 5699 | * @period: listen offload period |
| 5700 | * @interval: listen offload interval |
| 5701 | * @count: number listen offload intervals |
| 5702 | * @device_types: device types |
| 5703 | * @dev_types_len: device types length |
| 5704 | * @probe_resp_tmplt: probe response template |
| 5705 | * @probe_resp_len: probe response template length |
| 5706 | */ |
| 5707 | struct sir_p2p_lo_start { |
| 5708 | uint32_t vdev_id; |
| 5709 | uint32_t ctl_flags; |
| 5710 | uint32_t freq; |
| 5711 | uint32_t period; |
| 5712 | uint32_t interval; |
| 5713 | uint32_t count; |
| 5714 | uint8_t *device_types; |
| 5715 | uint32_t dev_types_len; |
| 5716 | uint8_t *probe_resp_tmplt; |
| 5717 | uint32_t probe_resp_len; |
| 5718 | }; |
| 5719 | |
| 5720 | /** |
| 5721 | * struct sir_p2p_lo_event - P2P listen offload stop event |
| 5722 | * @vdev_id: vdev identifier |
| 5723 | * @reason_code: P2P listen offload stop reason |
| 5724 | */ |
| 5725 | struct sir_p2p_lo_event { |
| 5726 | uint32_t vdev_id; |
| 5727 | uint32_t reason_code; |
| 5728 | }; |
Manjeet Singh | f82ed07 | 2016-07-08 11:40:00 +0530 | [diff] [blame] | 5729 | |
| 5730 | /** |
| 5731 | * struct sir_hal_pwr_dbg_cmd - unit test command parameters |
| 5732 | * @pdev_id: pdev id |
| 5733 | * @module_id: module id |
| 5734 | * @num_args: number of arguments |
| 5735 | * @args: arguments |
| 5736 | */ |
| 5737 | struct sir_mac_pwr_dbg_cmd { |
| 5738 | uint32_t pdev_id; |
| 5739 | uint32_t module_id; |
| 5740 | uint32_t num_args; |
| 5741 | uint32_t args[MAX_POWER_DBG_ARGS_SUPPORTED]; |
| 5742 | }; |
| 5743 | |
Kondabattini, Ganesh | 3f2d02c | 2016-09-13 12:23:47 +0530 | [diff] [blame] | 5744 | /** |
| 5745 | * struct sme_send_disassoc_frm_req - send disassoc request frame |
| 5746 | * @msg_type: message type |
| 5747 | * @length: length of message |
| 5748 | * @session_id: session id |
| 5749 | * @trans_id: transaction id |
| 5750 | * @peer_mac: peer mac address |
| 5751 | * @reason: reason for disassoc |
| 5752 | * @wait_for_ack: wait for acknowledgment |
| 5753 | **/ |
| 5754 | struct sme_send_disassoc_frm_req { |
| 5755 | uint16_t msg_type; |
| 5756 | uint16_t length; |
| 5757 | uint8_t session_id; |
| 5758 | uint16_t trans_id; |
| 5759 | uint8_t peer_mac[6]; |
| 5760 | uint16_t reason; |
| 5761 | uint8_t wait_for_ack; |
| 5762 | }; |
| 5763 | |
Kondabattini, Ganesh | e4f18e0 | 2016-09-13 13:01:22 +0530 | [diff] [blame] | 5764 | /** |
| 5765 | * struct sme_update_access_policy_vendor_ie - update vendor ie and access |
| 5766 | * policy |
| 5767 | * @msg_type: message id |
| 5768 | * @msg_len: message length |
| 5769 | * @sme_session_id: sme session id |
| 5770 | * @ie: vendor ie |
| 5771 | * @access_policy: access policy for vendor ie |
| 5772 | */ |
| 5773 | struct sme_update_access_policy_vendor_ie { |
| 5774 | uint16_t msg_type; |
| 5775 | uint16_t length; |
| 5776 | uint32_t sme_session_id; |
| 5777 | uint8_t ie[SIR_MAC_MAX_IE_LENGTH]; |
| 5778 | uint8_t access_policy; |
| 5779 | }; |
| 5780 | |
Padma, Santhosh Kumar | d7cc079 | 2016-06-28 18:54:12 +0530 | [diff] [blame] | 5781 | /** |
| 5782 | * struct sir_encrypt_decrypt_rsp_params - encrypt/decrypt rsp params |
| 5783 | * @vdev_id: vdev id |
| 5784 | * @status: status |
| 5785 | * @data_length: data length |
| 5786 | * @data: data pointer |
| 5787 | */ |
| 5788 | struct sir_encrypt_decrypt_rsp_params { |
| 5789 | uint32_t vdev_id; |
| 5790 | int32_t status; |
| 5791 | uint32_t data_length; |
| 5792 | uint8_t *data; |
| 5793 | }; |
| 5794 | |
Agrawal, Ashish | 35b251d | 2016-09-08 19:21:03 +0530 | [diff] [blame] | 5795 | /** |
| 5796 | * struct sme_tx_fail_cnt_threshold - tx failure count for disconnect to fw |
| 5797 | * @session_id: Session id |
| 5798 | * @tx_fail_cnt_threshold: Tx failure count to do disconnect |
| 5799 | */ |
| 5800 | struct sme_tx_fail_cnt_threshold { |
| 5801 | uint8_t session_id; |
| 5802 | uint32_t tx_fail_cnt_threshold; |
| 5803 | }; |
Agrawal Ashish | da3e950 | 2016-09-21 17:43:51 +0530 | [diff] [blame] | 5804 | |
| 5805 | /** |
| 5806 | * struct sme_short_retry_limit - transmission retry limit for short frames. |
| 5807 | * @session_id: Session id |
| 5808 | * @short_retry_limit: tranmission retry limit for short frame. |
| 5809 | * |
| 5810 | */ |
| 5811 | struct sme_short_retry_limit { |
| 5812 | uint8_t session_id; |
| 5813 | uint32_t short_retry_limit; |
| 5814 | }; |
| 5815 | |
| 5816 | /** |
| 5817 | * struct sme_long_retry_limit - tranmission retry limit for long frames |
| 5818 | * @session_id: Session id |
| 5819 | * @short_retry_limit: tranmission retry limit for long frames. |
| 5820 | * |
| 5821 | */ |
| 5822 | struct sme_long_retry_limit { |
| 5823 | uint8_t session_id; |
| 5824 | uint32_t long_retry_limit; |
| 5825 | }; |
Agrawal, Ashish | 4e5fa1c | 2016-09-21 19:03:43 +0530 | [diff] [blame] | 5826 | |
| 5827 | /** |
Kiran Kumar Lokere | 08195ef | 2018-01-17 19:25:15 -0800 | [diff] [blame] | 5828 | * struct sme_addba_accept - Allow/reject the addba request frame |
| 5829 | * @session_id: Session id |
| 5830 | * @addba_accept: Allow/reject the addba request frame |
| 5831 | */ |
| 5832 | struct sme_addba_accept { |
| 5833 | uint8_t session_id; |
| 5834 | uint8_t addba_accept; |
| 5835 | }; |
| 5836 | |
| 5837 | /** |
Agrawal, Ashish | 4e5fa1c | 2016-09-21 19:03:43 +0530 | [diff] [blame] | 5838 | * struct sme_sta_inactivity_timeout - set sta_inactivity_timeout |
| 5839 | * @session_id: session Id. |
| 5840 | * @sta_inactivity_timeout: Timeout to disconnect STA after there |
| 5841 | * is no activity. |
| 5842 | */ |
| 5843 | struct sme_sta_inactivity_timeout { |
| 5844 | uint8_t session_id; |
| 5845 | uint32_t sta_inactivity_timeout; |
| 5846 | }; |
Yingying Tang | 9540997 | 2016-10-20 15:16:15 +0800 | [diff] [blame] | 5847 | |
| 5848 | /* |
| 5849 | * struct wow_pulse_mode - WoW Pulse set cmd struct |
| 5850 | * @wow_pulse_enable: enable or disable this feature |
| 5851 | * @wow_pulse_pin: GPIO PIN for Pulse |
| 5852 | * @wow_pulse_interval_low: Pulse interval low |
| 5853 | * @wow_pulse_interval_high: Pulse interval high |
| 5854 | * |
| 5855 | * SME uses this structure to configure wow pulse info |
| 5856 | * and send it to WMA |
| 5857 | */ |
| 5858 | struct wow_pulse_mode { |
| 5859 | bool wow_pulse_enable; |
| 5860 | uint8_t wow_pulse_pin; |
| 5861 | uint16_t wow_pulse_interval_high; |
| 5862 | uint16_t wow_pulse_interval_low; |
| 5863 | }; |
| 5864 | |
Rajeev Kumar | e406d65 | 2017-01-30 17:47:05 -0800 | [diff] [blame] | 5865 | |
| 5866 | /** |
Rajeev Kumar | d138ac5 | 2017-01-30 18:38:37 -0800 | [diff] [blame] | 5867 | * umac_send_mb_message_to_mac(): post message to umac |
Rajeev Kumar | e406d65 | 2017-01-30 17:47:05 -0800 | [diff] [blame] | 5868 | * @msg: opaque message pointer |
| 5869 | * |
| 5870 | * Return: QDF status |
| 5871 | */ |
Rajeev Kumar | d138ac5 | 2017-01-30 18:38:37 -0800 | [diff] [blame] | 5872 | QDF_STATUS umac_send_mb_message_to_mac(void *msg); |
Rajeev Kumar | e406d65 | 2017-01-30 17:47:05 -0800 | [diff] [blame] | 5873 | |
Kapil Gupta | 4f0c0c1 | 2017-02-07 15:21:15 +0530 | [diff] [blame] | 5874 | /** |
| 5875 | * struct scan_chan_info - channel info |
| 5876 | * @freq: radio frequence |
| 5877 | * @cmd flag: cmd flag |
| 5878 | * @noise_floor: noise floor |
| 5879 | * @cycle_count: cycle count |
| 5880 | * @rx_clear_count: rx clear count |
| 5881 | * @tx_frame_count: TX frame count |
| 5882 | * @clock_freq: clock frequence MHZ |
| 5883 | */ |
| 5884 | struct scan_chan_info { |
| 5885 | uint32_t freq; |
| 5886 | uint32_t cmd_flag; |
| 5887 | uint32_t noise_floor; |
| 5888 | uint32_t cycle_count; |
| 5889 | uint32_t rx_clear_count; |
| 5890 | uint32_t tx_frame_count; |
| 5891 | uint32_t clock_freq; |
| 5892 | }; |
Dustin Brown | 5409643 | 2017-02-23 13:00:44 -0800 | [diff] [blame] | 5893 | |
| 5894 | /** |
| 5895 | * enum wow_resume_trigger - resume trigger override setting values |
| 5896 | * @WOW_RESUME_TRIGGER_DEFAULT: fw to use platform default resume trigger |
| 5897 | * @WOW_RESUME_TRIGGER_HTC_WAKEUP: force fw to use HTC Wakeup to resume |
| 5898 | * @WOW_RESUME_TRIGGER_GPIO: force fw to use GPIO to resume |
| 5899 | * @WOW_RESUME_TRIGGER_COUNT: number of resume trigger options |
| 5900 | */ |
| 5901 | enum wow_resume_trigger { |
| 5902 | /* always first */ |
| 5903 | WOW_RESUME_TRIGGER_DEFAULT = 0, |
| 5904 | WOW_RESUME_TRIGGER_HTC_WAKEUP, |
| 5905 | WOW_RESUME_TRIGGER_GPIO, |
| 5906 | /* always last */ |
| 5907 | WOW_RESUME_TRIGGER_COUNT |
| 5908 | }; |
| 5909 | |
| 5910 | /** |
| 5911 | * enum wow_interface_pause - interface pause override setting values |
| 5912 | * @WOW_INTERFACE_PAUSE_DEFAULT: use platform default interface pause setting |
| 5913 | * @WOW_INTERFACE_PAUSE_ENABLE: force interface pause setting to enabled |
| 5914 | * @WOW_INTERFACE_PAUSE_DISABLE: force interface pause setting to disabled |
| 5915 | * @WOW_INTERFACE_PAUSE_COUNT: number of interface pause options |
| 5916 | */ |
| 5917 | enum wow_interface_pause { |
| 5918 | /* always first */ |
| 5919 | WOW_INTERFACE_PAUSE_DEFAULT = 0, |
| 5920 | WOW_INTERFACE_PAUSE_ENABLE, |
| 5921 | WOW_INTERFACE_PAUSE_DISABLE, |
| 5922 | /* always last */ |
| 5923 | WOW_INTERFACE_PAUSE_COUNT |
| 5924 | }; |
| 5925 | |
| 5926 | /** |
| 5927 | * struct wow_enable_params - A collection of wow enable override parameters |
| 5928 | * @is_unit_test: true to notify fw this is a unit-test suspend |
| 5929 | * @interface_pause: used to override the interface pause indication sent to fw |
| 5930 | * @resume_trigger: used to force fw to use a particular resume method |
| 5931 | */ |
| 5932 | struct wow_enable_params { |
| 5933 | bool is_unit_test; |
| 5934 | enum wow_interface_pause interface_pause; |
| 5935 | enum wow_resume_trigger resume_trigger; |
| 5936 | }; |
Krishna Kumaar Natarajan | d0bbb3c | 2017-03-13 17:04:58 -0700 | [diff] [blame] | 5937 | |
Kiran Kumar Lokere | a006a30 | 2018-03-07 20:58:13 -0800 | [diff] [blame] | 5938 | #define HE_LTF_1X 0 |
| 5939 | #define HE_LTF_2X 1 |
| 5940 | #define HE_LTF_4X 2 |
| 5941 | |
| 5942 | #define HE_LTF_ALL 0x7 |
| 5943 | #define HE_SGI_MASK 0xFF00 |
| 5944 | |
| 5945 | #define AUTO_RATE_GI_400NS 8 |
| 5946 | #define AUTO_RATE_GI_800NS 9 |
| 5947 | #define AUTO_RATE_GI_1600NS 10 |
| 5948 | #define AUTO_RATE_GI_3200NS 11 |
| 5949 | |
| 5950 | #define SET_AUTO_RATE_SGI_VAL(set_val, bit_mask) \ |
| 5951 | (set_val = (set_val & HE_LTF_ALL) | bit_mask) |
| 5952 | |
| 5953 | #define SET_AUTO_RATE_HE_LTF_VAL(set_val, bit_mask) \ |
| 5954 | (set_val = (set_val & HE_SGI_MASK) | bit_mask) |
| 5955 | |
Krishna Kumaar Natarajan | d0bbb3c | 2017-03-13 17:04:58 -0700 | [diff] [blame] | 5956 | #ifdef WLAN_FEATURE_11AX |
Naveen Rawat | d8feac1 | 2017-09-08 15:08:39 -0700 | [diff] [blame] | 5957 | #define HE_CAP_OUI_TYPE "\x23" |
| 5958 | #define HE_CAP_OUI_SIZE 1 |
| 5959 | #define HE_OP_OUI_TYPE "\x24" |
| 5960 | #define HE_OP_OUI_SIZE 1 |
Krishna Kumaar Natarajan | 0103ef8 | 2017-02-17 18:15:56 -0800 | [diff] [blame] | 5961 | |
Krishna Kumaar Natarajan | d0bbb3c | 2017-03-13 17:04:58 -0700 | [diff] [blame] | 5962 | #define HE_RU_ALLOC_INDX0_MASK (0x01 << 0) |
| 5963 | #define HE_RU_ALLOC_INDX1_MASK (0x01 << 1) |
| 5964 | #define HE_RU_ALLOC_INDX2_MASK (0x01 << 2) |
| 5965 | #define HE_RU_ALLOC_INDX3_MASK (0x01 << 3) |
| 5966 | |
| 5967 | /* 3 bits for NSS and 4 bits for RU Index */ |
| 5968 | #define HE_PPET_NSS_LEN 3 |
| 5969 | #define HE_PEPT_RU_IDX_LEN 4 |
| 5970 | #define HE_PPET_NSS_RU_LEN (HE_PPET_NSS_LEN + HE_PEPT_RU_IDX_LEN) |
| 5971 | #define HE_PPET_SIZE 3 |
| 5972 | #define HE_BYTE_SIZE 8 |
| 5973 | |
Naveen Rawat | 819158d | 2018-01-16 10:56:45 -0800 | [diff] [blame] | 5974 | struct ppet_hdr { |
| 5975 | uint8_t nss:3; |
| 5976 | uint8_t ru_idx_mask:4; |
| 5977 | uint8_t remaining:1; |
| 5978 | }; |
| 5979 | |
| 5980 | /* MAX PPET size = 7 bits + (max_nss X max_ru_number X 6) = 25 bytes */ |
| 5981 | #define HE_MAX_PPET_SIZE WNI_CFG_HE_PPET_LEN |
| 5982 | |
Krishna Kumaar Natarajan | f567650 | 2017-03-06 10:28:44 -0800 | [diff] [blame] | 5983 | #define HE_MAX_PHY_CAP_SIZE 3 |
| 5984 | |
Naveen Rawat | aeca1b9 | 2017-10-16 16:55:31 -0700 | [diff] [blame] | 5985 | #define HE_CH_WIDTH_GET_BIT(ch_wd, bit) (((ch_wd) >> (bit)) & 1) |
| 5986 | #define HE_CH_WIDTH_COMBINE(b0, b1, b2, b3, b4, b5, b6) \ |
| 5987 | ((uint8_t)(b0) | ((b1) << 1) | ((b2) << 2) | ((b3) << 3) | \ |
| 5988 | ((b4) << 4) | ((b5) << 5) | ((b6) << 6)) |
Krishna Kumaar Natarajan | d1cd56e | 2016-09-30 08:43:03 -0700 | [diff] [blame] | 5989 | |
Naveen Rawat | aeca1b9 | 2017-10-16 16:55:31 -0700 | [diff] [blame] | 5990 | /* |
| 5991 | * MCS values are interpreted as in IEEE 11ax-D1.4 spec onwards |
| 5992 | * +-----------------------------------------------------+ |
| 5993 | * | SS8 | SS7 | SS6 | SS5 | SS4 | SS3 | SS2 | SS1 | |
| 5994 | * +-----------------------------------------------------+ |
| 5995 | * | 15-14 | 13-12 | 11-10 | 9-8 | 7-6 | 5-4 | 3-2 | 1-0 | |
| 5996 | * +-----------------------------------------------------+ |
| 5997 | */ |
| 5998 | #define HE_MCS_NSS_SHIFT(nss) (((nss) - 1) << 1) |
| 5999 | #define HE_MCS_MSK_4_NSS(nss) (3 << HE_MCS_NSS_SHIFT(nss)) |
| 6000 | #define HE_MCS_INV_MSK_4_NSS(nss) (~HE_MCS_MSK_4_NSS(nss)) |
| 6001 | #define HE_GET_MCS_4_NSS(mcs_set, nss) \ |
| 6002 | (((mcs_set) >> HE_MCS_NSS_SHIFT(nss)) & 3) |
| 6003 | #define HE_SET_MCS_4_NSS(mcs_set, mcs, nss) \ |
| 6004 | (((mcs_set) & HE_MCS_INV_MSK_4_NSS(nss)) | \ |
| 6005 | ((mcs) << HE_MCS_NSS_SHIFT(nss))) |
| 6006 | #define HE_MCS_IS_NSS_ENABLED(mcs_set, nss) \ |
| 6007 | ((HE_MCS_MSK_4_NSS(nss) & (mcs_set)) != HE_MCS_MSK_4_NSS(nss)) |
| 6008 | |
| 6009 | #define HE_MCS_ALL_DISABLED 0xFFFF |
Kiran Kumar Lokere | 59a569e | 2018-01-24 15:00:50 -0800 | [diff] [blame] | 6010 | |
| 6011 | #define HE_MCS_0_7 0x0 |
| 6012 | #define HE_MCS_0_9 0x1 |
| 6013 | #define HE_MCS_0_11 0x2 |
| 6014 | #define HE_MCS_DISABLE 0x3 |
Kiran Kumar Lokere | a006a30 | 2018-03-07 20:58:13 -0800 | [diff] [blame] | 6015 | |
Naveen Rawat | aeca1b9 | 2017-10-16 16:55:31 -0700 | [diff] [blame] | 6016 | /* |
| 6017 | * Following formuala has been arrived at using karnaugh map and unit tested |
| 6018 | * with sample code. Take MCS for each NSS as 2 bit value first and solve for |
| 6019 | * 2 bit intersection of NSS. Use following table/Matrix as guide for solving |
| 6020 | * K-Maps |
| 6021 | * MCS 1\MCS 2 00 01 10 11 |
| 6022 | * 00 00 00 00 11 |
| 6023 | * 01 00 01 01 11 |
| 6024 | * 10 00 01 10 11 |
| 6025 | * 11 11 11 11 11 |
| 6026 | * if output MCS is o1o0, then as per K-map reduction: |
| 6027 | * o0 = m1.m0 | n1.n0 | (~m1).m0.(n1^n0) | (~n1).n0.(m1^m0) |
| 6028 | * o1 = m1.m0 | n1.n0 | m1.(~m0).n1.(~n0) |
| 6029 | * |
| 6030 | * Please note: Calculating MCS intersection is 80211 protocol specific and |
| 6031 | * should be implemented in PE. WMA can use this macro rather than calling any |
| 6032 | * lim API to do the intersection. |
| 6033 | */ |
| 6034 | #define HE_INTERSECT_MCS_BITS_PER_NSS(m1, m0, n1, n0) \ |
| 6035 | (((m1 & m0) | (n1 & n0) | (((~m1) & m0) & (n1 ^ n0)) | \ |
| 6036 | (((~n1) & n0) & (m1 ^ m0))) | (((m1 & m0) | (n1 & n0) | \ |
| 6037 | (m1 & ~m0 & n1 & ~n0)) << 1)) |
| 6038 | |
| 6039 | /* following takes MCS as 2 bits */ |
| 6040 | #define HE_INTERSECT_MCS_PER_NSS(mcs_1, mcs_2) \ |
| 6041 | HE_INTERSECT_MCS_BITS_PER_NSS((mcs_1 >> 1), (mcs_1 & 1), \ |
| 6042 | (mcs_2 >> 1), (mcs_2 & 1)) |
| 6043 | |
| 6044 | /* following takes MCS as 16 bits */ |
| 6045 | #define HE_INTERSECT_MCS(mcs_1, mcs_2) ( \ |
| 6046 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 1), \ |
| 6047 | HE_GET_MCS_4_NSS(mcs_2, 1)) << HE_MCS_NSS_SHIFT(1) | \ |
| 6048 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 2), \ |
| 6049 | HE_GET_MCS_4_NSS(mcs_2, 2)) << HE_MCS_NSS_SHIFT(2) | \ |
| 6050 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 3), \ |
| 6051 | HE_GET_MCS_4_NSS(mcs_2, 3)) << HE_MCS_NSS_SHIFT(3) | \ |
| 6052 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 4), \ |
| 6053 | HE_GET_MCS_4_NSS(mcs_2, 4)) << HE_MCS_NSS_SHIFT(4) | \ |
| 6054 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 5), \ |
| 6055 | HE_GET_MCS_4_NSS(mcs_2, 5)) << HE_MCS_NSS_SHIFT(5) | \ |
| 6056 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 6), \ |
| 6057 | HE_GET_MCS_4_NSS(mcs_2, 6)) << HE_MCS_NSS_SHIFT(6) | \ |
| 6058 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 7), \ |
| 6059 | HE_GET_MCS_4_NSS(mcs_2, 7)) << HE_MCS_NSS_SHIFT(7) | \ |
| 6060 | HE_INTERSECT_MCS_PER_NSS(HE_GET_MCS_4_NSS(mcs_1, 8), \ |
| 6061 | HE_GET_MCS_4_NSS(mcs_2, 8)) << HE_MCS_NSS_SHIFT(8)) |
Krishna Kumaar Natarajan | d1cd56e | 2016-09-30 08:43:03 -0700 | [diff] [blame] | 6062 | |
Krishna Kumaar Natarajan | f567650 | 2017-03-06 10:28:44 -0800 | [diff] [blame] | 6063 | /** |
| 6064 | * struct he_capability - to store 11ax HE capabilities |
| 6065 | * @phy_cap: HE PHY capabilities |
| 6066 | * @mac_cap: HE MAC capabilities |
| 6067 | * @mcs: HE MCS |
| 6068 | * @ppet: HE PPE threshold |
| 6069 | */ |
| 6070 | struct he_capability { |
| 6071 | uint32_t phy_cap[HE_MAX_PHY_CAP_SIZE]; |
| 6072 | uint32_t mac_cap; |
| 6073 | uint32_t mcs; |
| 6074 | struct wlan_psoc_host_ppe_threshold ppet; |
| 6075 | }; |
Krishna Kumaar Natarajan | d0bbb3c | 2017-03-13 17:04:58 -0700 | [diff] [blame] | 6076 | #endif |
| 6077 | |
Naveen Rawat | aeca1b9 | 2017-10-16 16:55:31 -0700 | [diff] [blame] | 6078 | #define HE_GET_NSS(mcs, nss) \ |
| 6079 | do { \ |
| 6080 | (nss) = 0; \ |
Naveen Rawat | cbcc654 | 2017-10-30 17:55:03 -0700 | [diff] [blame] | 6081 | while ((((mcs) >> ((nss)*2)) & 3) != 3 && nss < 8) \ |
Naveen Rawat | aeca1b9 | 2017-10-16 16:55:31 -0700 | [diff] [blame] | 6082 | (nss)++; \ |
| 6083 | } while (0) |
| 6084 | |
Nitesh Shah | 99dd955 | 2017-03-20 19:27:47 +0530 | [diff] [blame] | 6085 | /** |
| 6086 | * struct sir_del_all_tdls_peers - delete all tdls peers |
| 6087 | * @msg_type: type of message |
| 6088 | * @msg_len: length of message |
| 6089 | * @bssid: bssid of peer device |
| 6090 | */ |
| 6091 | struct sir_del_all_tdls_peers { |
| 6092 | uint16_t msg_type; |
| 6093 | uint16_t msg_len; |
| 6094 | struct qdf_mac_addr bssid; |
| 6095 | }; |
Tushnim Bhattacharyya | 0c4ad2d | 2017-03-09 15:59:03 -0800 | [diff] [blame] | 6096 | |
Anurag Chouhan | 3920c0f | 2017-09-11 17:10:56 +0530 | [diff] [blame] | 6097 | /** |
| 6098 | * struct rsp_stats - arp packet stats |
| 6099 | * @arp_req_enqueue: fw tx count |
| 6100 | * @arp_req_tx_success: tx ack count |
| 6101 | * @arp_req_tx_failure: tx ack fail count |
| 6102 | * @arp_rsp_recvd: rx fw count |
| 6103 | * @out_of_order_arp_rsp_drop_cnt: out of order count |
| 6104 | * @dad_detected: dad detected |
| 6105 | * @connect_status: connection status |
| 6106 | * @ba_session_establishment_status: BA session status |
Poddar, Siddarth | 465330e | 2018-01-08 18:23:54 +0530 | [diff] [blame] | 6107 | * @connect_stats_present: connectivity stats present or not |
| 6108 | * @tcp_ack_recvd: tcp syn ack's count |
| 6109 | * @icmpv4_rsp_recvd: icmpv4 responses count |
Anurag Chouhan | 3920c0f | 2017-09-11 17:10:56 +0530 | [diff] [blame] | 6110 | */ |
| 6111 | struct rsp_stats { |
| 6112 | uint32_t vdev_id; |
| 6113 | uint32_t arp_req_enqueue; |
| 6114 | uint32_t arp_req_tx_success; |
| 6115 | uint32_t arp_req_tx_failure; |
| 6116 | uint32_t arp_rsp_recvd; |
| 6117 | uint32_t out_of_order_arp_rsp_drop_cnt; |
| 6118 | uint32_t dad_detected; |
| 6119 | uint32_t connect_status; |
| 6120 | uint32_t ba_session_establishment_status; |
Poddar, Siddarth | 465330e | 2018-01-08 18:23:54 +0530 | [diff] [blame] | 6121 | bool connect_stats_present; |
| 6122 | uint32_t tcp_ack_recvd; |
| 6123 | uint32_t icmpv4_rsp_recvd; |
Anurag Chouhan | 3920c0f | 2017-09-11 17:10:56 +0530 | [diff] [blame] | 6124 | }; |
| 6125 | |
| 6126 | /** |
| 6127 | * struct set_arp_stats_params - set/reset arp stats |
| 6128 | * @vdev_id: session id |
| 6129 | * @flag: enable/disable stats |
| 6130 | * @pkt_type: type of packet(1 - arp) |
| 6131 | * @ip_addr: subnet ipv4 address in case of encrypted packets |
Poddar, Siddarth | 465330e | 2018-01-08 18:23:54 +0530 | [diff] [blame] | 6132 | * @pkt_type_bitmap: pkt bitmap |
| 6133 | * @tcp_src_port: tcp src port for pkt tracking |
| 6134 | * @tcp_dst_port: tcp dst port for pkt tracking |
| 6135 | * @icmp_ipv4: target ipv4 address to track ping packets |
| 6136 | * @reserved: reserved |
Anurag Chouhan | 3920c0f | 2017-09-11 17:10:56 +0530 | [diff] [blame] | 6137 | */ |
| 6138 | struct set_arp_stats_params { |
| 6139 | uint32_t vdev_id; |
| 6140 | uint8_t flag; |
| 6141 | uint8_t pkt_type; |
| 6142 | uint32_t ip_addr; |
Poddar, Siddarth | 465330e | 2018-01-08 18:23:54 +0530 | [diff] [blame] | 6143 | uint32_t pkt_type_bitmap; |
| 6144 | uint32_t tcp_src_port; |
| 6145 | uint32_t tcp_dst_port; |
| 6146 | uint32_t icmp_ipv4; |
| 6147 | uint32_t reserved; |
Anurag Chouhan | 3920c0f | 2017-09-11 17:10:56 +0530 | [diff] [blame] | 6148 | }; |
| 6149 | |
| 6150 | /** |
| 6151 | * struct get_arp_stats_params - get arp stats from firmware |
| 6152 | * @pkt_type: packet type(1 - ARP) |
| 6153 | * @vdev_id: session id |
| 6154 | */ |
| 6155 | struct get_arp_stats_params { |
| 6156 | uint8_t pkt_type; |
| 6157 | uint32_t vdev_id; |
| 6158 | }; |
| 6159 | |
Rajeev Kumar Sirasanagandla | 996e529 | 2016-11-22 21:20:33 +0530 | [diff] [blame] | 6160 | typedef void (*sme_rcpi_callback)(void *context, struct qdf_mac_addr mac_addr, |
| 6161 | int32_t rcpi, QDF_STATUS status); |
| 6162 | /** |
| 6163 | * struct sme_rcpi_req - structure for querying rcpi info |
| 6164 | * @session_id: session for which rcpi is required |
| 6165 | * @measurement_type: type of measurement from enum rcpi_measurement_type |
| 6166 | * @rcpi_callback: callback function to be invoked for rcpi response |
| 6167 | * @rcpi_context: context info for rcpi callback |
| 6168 | * @mac_addr: peer addr for which rcpi is required |
| 6169 | */ |
| 6170 | struct sme_rcpi_req { |
| 6171 | uint32_t session_id; |
| 6172 | enum rcpi_measurement_type measurement_type; |
| 6173 | sme_rcpi_callback rcpi_callback; |
| 6174 | void *rcpi_context; |
| 6175 | struct qdf_mac_addr mac_addr; |
| 6176 | }; |
| 6177 | |
Tushnim Bhattacharyya | 0c4ad2d | 2017-03-09 15:59:03 -0800 | [diff] [blame] | 6178 | /* |
| 6179 | * @SCAN_REJECT_DEFAULT: default value |
| 6180 | * @CONNECTION_IN_PROGRESS: connection is in progress |
| 6181 | * @REASSOC_IN_PROGRESS: reassociation is in progress |
| 6182 | * @EAPOL_IN_PROGRESS: STA/P2P-CLI is in middle of EAPOL/WPS exchange |
| 6183 | * @SAP_EAPOL_IN_PROGRESS: SAP/P2P-GO is in middle of EAPOL/WPS exchange |
| 6184 | */ |
| 6185 | enum scan_reject_states { |
| 6186 | SCAN_REJECT_DEFAULT = 0, |
| 6187 | CONNECTION_IN_PROGRESS, |
| 6188 | REASSOC_IN_PROGRESS, |
| 6189 | EAPOL_IN_PROGRESS, |
| 6190 | SAP_EAPOL_IN_PROGRESS, |
| 6191 | }; |
Sandeep Puligilla | f587adf | 2017-04-27 19:53:21 -0700 | [diff] [blame] | 6192 | |
| 6193 | /** |
lifeng | 6683166 | 2017-05-19 16:01:35 +0800 | [diff] [blame] | 6194 | * sir_sme_rx_aggr_hole_ind - sme rx aggr hole indication |
| 6195 | * @hole_cnt: num of holes detected |
| 6196 | * @hole_info_array: hole info |
| 6197 | */ |
| 6198 | struct sir_sme_rx_aggr_hole_ind { |
| 6199 | uint32_t hole_cnt; |
| 6200 | uint32_t hole_info_array[]; |
| 6201 | }; |
| 6202 | |
| 6203 | /** |
| 6204 | * struct sir_set_rx_reorder_timeout_val - rx reorder timeout |
| 6205 | * @rx_timeout_pri: reorder timeout for AC |
| 6206 | * rx_timeout_pri[0] : AC_VO |
| 6207 | * rx_timeout_pri[1] : AC_VI |
| 6208 | * rx_timeout_pri[2] : AC_BE |
| 6209 | * rx_timeout_pri[3] : AC_BK |
| 6210 | */ |
| 6211 | struct sir_set_rx_reorder_timeout_val { |
| 6212 | uint32_t rx_timeout_pri[4]; |
| 6213 | }; |
| 6214 | |
| 6215 | /** |
| 6216 | * struct sir_peer_set_rx_blocksize - set rx blocksize |
| 6217 | * @vdev_id: vdev id |
| 6218 | * @peer_macaddr: peer mac address |
| 6219 | * @rx_block_ack_win_limit: windows size limitation |
| 6220 | */ |
| 6221 | struct sir_peer_set_rx_blocksize { |
| 6222 | uint32_t vdev_id; |
| 6223 | struct qdf_mac_addr peer_macaddr; |
| 6224 | uint32_t rx_block_ack_win_limit; |
| 6225 | }; |
Abhishek Singh | f3756fc | 2017-06-28 16:04:06 +0530 | [diff] [blame] | 6226 | |
| 6227 | /** |
| 6228 | * struct sir_rssi_disallow_lst - Structure holding Rssi based avoid candidate |
| 6229 | * list |
| 6230 | * @node: Node pointer |
| 6231 | * @bssid: BSSID of the AP |
| 6232 | * @retry_delay: Retry delay received during last rejection in ms |
| 6233 | * @ expected_rssi: RSSI at which STA can initate |
| 6234 | * @time_during_rejection: Timestamp during last rejection in millisec |
| 6235 | */ |
| 6236 | struct sir_rssi_disallow_lst { |
| 6237 | qdf_list_node_t node; |
| 6238 | struct qdf_mac_addr bssid; |
| 6239 | uint32_t retry_delay; |
| 6240 | int8_t expected_rssi; |
| 6241 | qdf_time_t time_during_rejection; |
| 6242 | }; |
lifeng | d217d19 | 2017-05-09 19:44:16 +0800 | [diff] [blame] | 6243 | |
| 6244 | /** |
| 6245 | * struct chain_rssi_result - chain rssi result |
Jeff Johnson | 00634ab | 2018-05-10 14:27:50 -0700 | [diff] [blame] | 6246 | * num_chains_valid: valid chain num |
lifeng | d217d19 | 2017-05-09 19:44:16 +0800 | [diff] [blame] | 6247 | * @chain_rssi: chain rssi result as dBm unit |
lifeng | fe6c3e2 | 2018-04-03 12:10:04 +0800 | [diff] [blame] | 6248 | * @ant_id: antenna id |
lifeng | d217d19 | 2017-05-09 19:44:16 +0800 | [diff] [blame] | 6249 | */ |
lifeng | fe6c3e2 | 2018-04-03 12:10:04 +0800 | [diff] [blame] | 6250 | #define CHAIN_MAX_NUM 8 |
lifeng | d217d19 | 2017-05-09 19:44:16 +0800 | [diff] [blame] | 6251 | struct chain_rssi_result { |
lifeng | fe6c3e2 | 2018-04-03 12:10:04 +0800 | [diff] [blame] | 6252 | uint32_t num_chains_valid; |
| 6253 | uint32_t chain_rssi[CHAIN_MAX_NUM]; |
| 6254 | uint32_t ant_id[CHAIN_MAX_NUM]; |
lifeng | d217d19 | 2017-05-09 19:44:16 +0800 | [diff] [blame] | 6255 | }; |
| 6256 | |
| 6257 | /** |
| 6258 | * struct get_chain_rssi_req_params - get chain rssi req params |
| 6259 | * @peer_macaddr: specific peer mac address |
| 6260 | * @session_id: session id |
| 6261 | */ |
| 6262 | struct get_chain_rssi_req_params { |
| 6263 | struct qdf_mac_addr peer_macaddr; |
| 6264 | uint8_t session_id; |
| 6265 | }; |
| 6266 | |
Ganesh Kondabattini | 3573957 | 2017-06-21 16:26:39 +0530 | [diff] [blame] | 6267 | /* |
| 6268 | * struct sir_limit_off_chan - limit off-channel command parameters |
| 6269 | * @vdev_id: vdev id |
| 6270 | * @is_tos_active: status of the traffic (active/inactive) |
| 6271 | * @max_off_chan_time: max allowed off channel time |
| 6272 | * @rest_time: home channel time |
| 6273 | * @skip_dfs_chans: skip dfs channels during scan |
| 6274 | */ |
| 6275 | struct sir_limit_off_chan { |
| 6276 | uint8_t vdev_id; |
| 6277 | bool is_tos_active; |
| 6278 | uint32_t max_off_chan_time; |
| 6279 | uint32_t rest_time; |
| 6280 | bool skip_dfs_chans; |
| 6281 | }; |
Padma, Santhosh Kumar | b38ab51 | 2018-01-16 16:16:46 +0530 | [diff] [blame] | 6282 | |
Rajeev Kumar Sirasanagandla | 4f20b67 | 2018-03-12 13:52:50 +0530 | [diff] [blame] | 6283 | typedef void (*roam_scan_stats_cb)(void *context, |
| 6284 | struct wmi_roam_scan_stats_res *res); |
| 6285 | |
| 6286 | /** |
| 6287 | * struct sir_roam_scan_stats - Stores roam scan context |
| 6288 | * @vdev_id: vdev id |
| 6289 | * @cb: callback to be invoked for roam scan stats response |
| 6290 | * @context: context of callback |
| 6291 | */ |
| 6292 | struct sir_roam_scan_stats { |
| 6293 | uint32_t vdev_id; |
| 6294 | roam_scan_stats_cb cb; |
| 6295 | void *context; |
| 6296 | }; |
| 6297 | |
Padma, Santhosh Kumar | b38ab51 | 2018-01-16 16:16:46 +0530 | [diff] [blame] | 6298 | /** |
| 6299 | * struct sae_info - SAE info used for commit/confirm messages |
| 6300 | * @msg_type: Message type |
| 6301 | * @msg_len: length of message |
| 6302 | * @vdev_id: vdev id |
| 6303 | * @peer_mac_addr: peer MAC address |
| 6304 | * @ssid: SSID |
| 6305 | */ |
| 6306 | struct sir_sae_info { |
| 6307 | uint16_t msg_type; |
| 6308 | uint16_t msg_len; |
| 6309 | uint32_t vdev_id; |
| 6310 | struct qdf_mac_addr peer_mac_addr; |
| 6311 | tSirMacSSid ssid; |
| 6312 | }; |
Padma, Santhosh Kumar | dd3f485 | 2018-01-16 18:51:51 +0530 | [diff] [blame] | 6313 | |
| 6314 | /** |
| 6315 | * struct sir_sae_msg - SAE msg used for message posting |
| 6316 | * @message_type: message type |
| 6317 | * @length: message length |
| 6318 | * @session_id: SME session id |
| 6319 | * @sae_status: SAE status, 0: Success, Non-zero: Failure. |
| 6320 | */ |
| 6321 | struct sir_sae_msg { |
| 6322 | uint16_t message_type; |
| 6323 | uint16_t length; |
| 6324 | uint16_t session_id; |
| 6325 | uint8_t sae_status; |
| 6326 | }; |
| 6327 | |
Varun Reddy Yeturu | 951de5d | 2018-09-10 21:36:22 -0700 | [diff] [blame] | 6328 | /** |
| 6329 | * struct set_pcl_req - Request message to set the PCL |
| 6330 | * @chan_weights: PCL channel weights |
| 6331 | * @band: Supported band |
| 6332 | */ |
| 6333 | struct set_pcl_req { |
| 6334 | struct wmi_pcl_chan_weights chan_weights; |
| 6335 | enum band_info band; |
| 6336 | }; |
| 6337 | |
Prakash Dhavali | 7090c5f | 2015-11-02 17:55:19 -0800 | [diff] [blame] | 6338 | #endif /* __SIR_API_H */ |