Govind Singh | 3ddda1f | 2016-03-09 11:34:12 +0530 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (c) 2016 The Linux Foundation. All rights reserved. |
| 3 | * |
| 4 | * Previously licensed under the ISC license by Qualcomm Atheros, Inc. |
| 5 | * |
| 6 | * |
| 7 | * Permission to use, copy, modify, and/or distribute this software for |
| 8 | * any purpose with or without fee is hereby granted, provided that the |
| 9 | * above copyright notice and this permission notice appear in all |
| 10 | * copies. |
| 11 | * |
| 12 | * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL |
| 13 | * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED |
| 14 | * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE |
| 15 | * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL |
| 16 | * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR |
| 17 | * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER |
| 18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR |
| 19 | * PERFORMANCE OF THIS SOFTWARE. |
| 20 | */ |
| 21 | |
| 22 | /* |
| 23 | * This file was originally distributed by Qualcomm Atheros, Inc. |
| 24 | * under proprietary terms before Copyright ownership was assigned |
| 25 | * to the Linux Foundation. |
| 26 | */ |
| 27 | |
| 28 | /* |
| 29 | * This file contains the API definitions for the Unified Wireless Module |
| 30 | * Interface (WMI). |
| 31 | */ |
| 32 | |
| 33 | #ifndef _WMI_UNIFIED_PARAM_H_ |
| 34 | #define _WMI_UNIFIED_PARAM_H_ |
| 35 | #include "wmi_unified.h" |
| 36 | #define IEEE80211_ADDR_LEN 6 /* size of 802.11 address */ |
Govind Singh | 3ddda1f | 2016-03-09 11:34:12 +0530 | [diff] [blame] | 37 | #define WMI_MAC_MAX_SSID_LENGTH 32 |
| 38 | #define WMI_SCAN_MAX_NUM_SSID 0x0A |
| 39 | #define mgmt_tx_dl_frm_len 64 |
| 40 | #define WMI_SMPS_MASK_LOWER_16BITS 0xFF |
| 41 | #define WMI_SMPS_MASK_UPPER_3BITS 0x7 |
| 42 | #define WMI_SMPS_PARAM_VALUE_S 29 |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 43 | #define WMI_MAX_NUM_ARGS 8 |
Govind Singh | e7b800c | 2016-03-01 15:30:53 +0530 | [diff] [blame] | 44 | /* The size of the utc time in bytes. */ |
| 45 | #define WMI_SIZE_UTC_TIME (10) |
| 46 | /* The size of the utc time error in bytes. */ |
| 47 | #define WMI_SIZE_UTC_TIME_ERROR (5) |
Govind Singh | 9bad000 | 2016-03-01 15:54:59 +0530 | [diff] [blame] | 48 | #define WMI_MCC_MIN_CHANNEL_QUOTA 20 |
| 49 | #define WMI_MCC_MAX_CHANNEL_QUOTA 80 |
| 50 | #define WMI_MCC_MIN_NON_ZERO_CHANNEL_LATENCY 30 |
| 51 | #define WMI_BEACON_TX_BUFFER_SIZE (512) |
| 52 | #define WMI_WIFI_SCANNING_MAC_OUI_LENGTH 3 |
| 53 | #define WMI_EXTSCAN_MAX_SIGNIFICANT_CHANGE_APS 64 |
| 54 | #define WMI_RSSI_THOLD_DEFAULT -300 |
| 55 | #define WMI_NLO_FREQ_THRESH 1000 |
| 56 | #define WMI_SEC_TO_MSEC(sec) (sec * 1000) |
| 57 | #define WMI_MSEC_TO_USEC(msec) (msec * 1000) |
| 58 | #define WMI_ETH_LEN 64 |
| 59 | #define WMI_QOS_NUM_TSPEC_MAX 2 |
| 60 | #define WMI_QOS_NUM_AC_MAX 4 |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 61 | #define WMI_IPV4_ADDR_LEN 4 |
| 62 | #define WMI_KEEP_ALIVE_NULL_PKT 1 |
| 63 | #define WMI_KEEP_ALIVE_UNSOLICIT_ARP_RSP 2 |
| 64 | #ifdef WLAN_NS_OFFLOAD |
| 65 | /* support only one IPv6 offload */ |
| 66 | #define WMI_MAC_NS_OFFLOAD_SIZE 1 |
| 67 | /* Number of target IP V6 addresses for NS offload */ |
| 68 | #define WMI_MAC_NUM_TARGET_IPV6_NS_OFFLOAD_NA 16 |
| 69 | #define WMI_MAC_IPV6_ADDR_LEN 16 |
| 70 | #define WMI_IPV6_ADDR_VALID 1 |
| 71 | #endif /* WLAN_NS_OFFLOAD */ |
| 72 | #define WMI_EXTSCAN_MAX_HOTLIST_SSIDS 8 |
| 73 | #define WMI_ROAM_MAX_CHANNELS 80 |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 74 | #ifdef FEATURE_WLAN_EXTSCAN |
| 75 | #define WMI_MAX_EXTSCAN_MSG_SIZE 1536 |
| 76 | #define WMI_EXTSCAN_REST_TIME 100 |
| 77 | #define WMI_EXTSCAN_MAX_SCAN_TIME 50000 |
| 78 | #define WMI_EXTSCAN_BURST_DURATION 150 |
| 79 | #endif |
| 80 | #define WMI_SCAN_NPROBES_DEFAULT (2) |
| 81 | #define WMI_SEC_TO_MSEC(sec) (sec * 1000) /* sec to msec */ |
| 82 | #define WMI_MSEC_TO_USEC(msec) (msec * 1000) /* msec to usec */ |
| 83 | #define WMI_NLO_FREQ_THRESH 1000 /* in MHz */ |
| 84 | |
Govind Singh | 3ddda1f | 2016-03-09 11:34:12 +0530 | [diff] [blame] | 85 | /** |
| 86 | * struct vdev_create_params - vdev create cmd parameter |
| 87 | * @if_id: interface id |
| 88 | * @type: interface type |
| 89 | * @subtype: interface subtype |
| 90 | */ |
| 91 | struct vdev_create_params { |
| 92 | uint8_t if_id; |
| 93 | uint32_t type; |
| 94 | uint32_t subtype; |
| 95 | }; |
| 96 | |
| 97 | /** |
| 98 | * struct vdev_delete_params - vdev delete cmd parameter |
| 99 | * @if_id: interface id |
| 100 | */ |
| 101 | struct vdev_delete_params { |
| 102 | uint8_t if_id; |
| 103 | }; |
| 104 | |
| 105 | /** |
| 106 | * struct vdev_start_params - vdev start cmd parameter |
| 107 | * @beacon_intval: beacon intval |
| 108 | * @dtim_period: dtim period |
| 109 | * @max_txpow: max tx power |
| 110 | * @phy_ch_width chan_width: channel width |
| 111 | * @is_dfs: flag to check if dfs enabled |
| 112 | * @vdev_id: vdev id |
| 113 | * @chan: channel no |
| 114 | * @oper_mode: operating mode |
| 115 | * @length: length |
| 116 | * @ssId[32]: ssid |
| 117 | * @hidden_ssid: hidden ssid |
| 118 | * @pmf_enabled: is pmf enabled |
| 119 | * @vht_capable: is vht capable |
| 120 | * @ch_center_freq_seg0: center freq seq 0 |
| 121 | * @ch_center_freq_seg1: center freq seq 1 |
| 122 | * @ht_capable: is ht capable |
| 123 | * @dfs_pri_multiplier: DFS multiplier |
| 124 | * @dot11_mode: dot11 mode |
| 125 | * @is_half_rate: Indicates half rate channel |
| 126 | * @is_quarter_rate: Indicates quarter rate channel |
| 127 | * @preferred_tx_streams: preferred tx streams |
| 128 | * @preferred_rx_streams: preferred rx streams |
| 129 | */ |
| 130 | struct vdev_start_params { |
| 131 | uint32_t beacon_intval; |
| 132 | uint32_t dtim_period; |
| 133 | int32_t max_txpow; |
| 134 | bool is_dfs; |
| 135 | uint8_t vdev_id; |
| 136 | uint8_t chan; |
| 137 | uint8_t oper_mode; |
| 138 | uint8_t length; |
| 139 | uint8_t ssId[32]; |
| 140 | uint8_t hidden_ssid; |
| 141 | uint8_t pmf_enabled; |
| 142 | uint8_t vht_capable; |
| 143 | uint8_t ch_center_freq_seg0; |
| 144 | uint8_t ch_center_freq_seg1; |
| 145 | uint8_t ht_capable; |
| 146 | int32_t dfs_pri_multiplier; |
| 147 | uint8_t dot11_mode; |
| 148 | bool is_half_rate; |
| 149 | bool is_quarter_rate; |
| 150 | uint32_t preferred_tx_streams; |
| 151 | uint32_t preferred_rx_streams; |
| 152 | }; |
| 153 | |
| 154 | /** |
| 155 | * struct vdev_stop_params - vdev stop cmd parameter |
| 156 | * @vdev_id: vdev id |
| 157 | */ |
| 158 | struct vdev_stop_params { |
| 159 | uint8_t vdev_id; |
| 160 | }; |
| 161 | |
| 162 | /** |
| 163 | * struct vdev_up_params - vdev up cmd parameter |
| 164 | * @vdev_id: vdev id |
| 165 | * @assoc_id: association id |
| 166 | */ |
| 167 | struct vdev_up_params { |
| 168 | uint8_t vdev_id; |
| 169 | uint16_t assoc_id; |
| 170 | }; |
| 171 | |
| 172 | /** |
| 173 | * struct vdev_down_params - vdev down cmd parameter |
| 174 | * @vdev_id: vdev id |
| 175 | */ |
| 176 | struct vdev_down_params { |
| 177 | uint8_t vdev_id; |
| 178 | }; |
| 179 | |
| 180 | /** |
| 181 | * struct vdev_set_params - vdev set cmd parameter |
| 182 | * @if_id: vdev id |
| 183 | * @param_id: parameter id |
| 184 | * @param_value: parameter value |
| 185 | */ |
| 186 | struct vdev_set_params { |
| 187 | uint32_t if_id; |
| 188 | uint32_t param_id; |
| 189 | uint32_t param_value; |
| 190 | }; |
| 191 | |
| 192 | /** |
| 193 | * struct peer_delete_params - peer delete cmd parameter |
| 194 | * @vdev_id: vdev id |
| 195 | */ |
| 196 | struct peer_delete_params { |
| 197 | uint8_t vdev_id; |
| 198 | }; |
| 199 | |
| 200 | /** |
| 201 | * struct peer_flush_params - peer flush cmd parameter |
| 202 | * @peer_tid_bitmap: peer tid bitmap |
| 203 | * @vdev_id: vdev id |
| 204 | */ |
| 205 | struct peer_flush_params { |
| 206 | uint32_t peer_tid_bitmap; |
| 207 | uint8_t vdev_id; |
| 208 | }; |
| 209 | |
| 210 | /** |
| 211 | * struct peer_set_params - peer set cmd parameter |
| 212 | * @param_id: parameter id |
| 213 | * @param_value: parameter value |
| 214 | * @vdev_id: vdev id |
| 215 | */ |
| 216 | struct peer_set_params { |
| 217 | uint32_t param_id; |
| 218 | uint32_t param_value; |
| 219 | uint32_t vdev_id; |
| 220 | }; |
| 221 | |
| 222 | /** |
| 223 | * struct peer_create_params - peer create cmd parameter |
| 224 | * @peer_addr: peer mac addr |
| 225 | * @peer_type: peer type |
| 226 | * @vdev_id: vdev id |
| 227 | */ |
| 228 | struct peer_create_params { |
| 229 | const uint8_t *peer_addr; |
| 230 | uint32_t peer_type; |
| 231 | uint32_t vdev_id; |
| 232 | }; |
| 233 | |
| 234 | /** |
| 235 | * struct peer_remove_params - peer remove cmd parameter |
| 236 | * @bssid: bss id |
| 237 | * @vdev_id: vdev id |
| 238 | * @roam_synch_in_progress: flag to indicate if roaming is in progress |
| 239 | */ |
| 240 | struct peer_remove_params { |
| 241 | uint8_t *bssid; |
| 242 | uint8_t vdev_id; |
| 243 | bool roam_synch_in_progress; |
| 244 | }; |
| 245 | |
| 246 | /** |
| 247 | * struct stats_request_params - stats_request cmd parameter |
| 248 | * @stats_id: statistics id |
| 249 | * @vdev_id: vdev id |
| 250 | */ |
| 251 | struct stats_request_params { |
| 252 | uint32_t stats_id; |
| 253 | uint32_t vdev_id; |
| 254 | }; |
| 255 | |
| 256 | /** |
| 257 | * struct green_ap_ps_params - green ap ps cmd parameter |
| 258 | * @value: parameter value |
| 259 | */ |
| 260 | struct green_ap_ps_params { |
| 261 | uint32_t value; |
| 262 | }; |
| 263 | |
| 264 | /** |
| 265 | * struct wow_cmd_params - wow cmd parameter |
| 266 | * @enable: wow enable or disable flag |
| 267 | * @can_suspend_link: flag to indicate if link can be suspended |
| 268 | * @pause_iface_config: interface config |
| 269 | */ |
| 270 | struct wow_cmd_params { |
| 271 | bool enable; |
| 272 | bool can_suspend_link; |
| 273 | uint8_t pause_iface_config; |
| 274 | }; |
| 275 | |
| 276 | /** |
| 277 | * struct packet_enable_params - packet enable cmd parameter |
| 278 | * @vdev_id: vdev id |
| 279 | * @enable: flag to indicate if parameter can be enabled or disabled |
| 280 | */ |
| 281 | struct packet_enable_params { |
| 282 | uint8_t vdev_id; |
| 283 | bool enable; |
| 284 | }; |
| 285 | |
| 286 | /** |
| 287 | * struct suspend_params - suspend cmd parameter |
| 288 | * @disable_target_intr: disable target interrupt |
| 289 | */ |
| 290 | struct suspend_params { |
| 291 | uint8_t disable_target_intr; |
| 292 | }; |
| 293 | |
| 294 | /** |
| 295 | * struct pdev_params - pdev set cmd parameter |
| 296 | * @param_id: parameter id |
| 297 | * @param_value: parameter value |
| 298 | */ |
| 299 | struct pdev_params { |
| 300 | uint32_t param_id; |
| 301 | uint32_t param_value; |
| 302 | }; |
| 303 | |
| 304 | /** |
| 305 | * struct beacon_params - beacon template cmd parameter |
| 306 | * @vdev_id: vdev id |
| 307 | * @tim_ie_offset: tim ie offset |
| 308 | * @tmpl_len: beacon template length |
| 309 | * @tmpl_len_aligned: beacon template alignment |
| 310 | * @frm: beacon template parameter |
| 311 | */ |
| 312 | struct beacon_params { |
| 313 | uint8_t vdev_id; |
| 314 | uint32_t tim_ie_offset; |
| 315 | uint32_t tmpl_len; |
| 316 | uint32_t tmpl_len_aligned; |
| 317 | uint8_t *frm; |
| 318 | }; |
| 319 | |
| 320 | /** |
| 321 | * struct peer_assoc_params - peer assoc cmd parameter |
| 322 | * @peer_macaddr: peer mac address |
| 323 | * @vdev_id: vdev id |
| 324 | * @peer_new_assoc: peer association type |
| 325 | * @peer_associd: peer association id |
| 326 | * @peer_flags: peer flags |
| 327 | * @peer_caps: peer capabalities |
| 328 | * @peer_listen_intval: peer listen interval |
| 329 | * @peer_ht_caps: HT capabalities |
| 330 | * @peer_max_mpdu: 0 : 8k , 1 : 16k, 2 : 32k, 3 : 64k |
| 331 | * @peer_mpdu_density: 3 : 0~7 : 2^(11nAMPDUdensity -4) |
| 332 | * @peer_rate_caps: peer rate capabalities |
| 333 | * @peer_nss: peer nss |
| 334 | * @peer_phymode: peer phymode |
| 335 | * @peer_ht_info: peer HT info |
| 336 | * @peer_legacy_rates: peer legacy rates |
| 337 | * @peer_ht_rates: peer ht rates |
| 338 | * @num_peer_legacy_rates: no of peer legacy rates |
| 339 | * @num_peer_ht_rates: no of peer ht rates |
| 340 | * @rx_max_rate: max rx rates |
| 341 | * @rx_mcs_set: rx mcs |
| 342 | * @tx_max_rate: max tx rates |
| 343 | * @tx_mcs_set: tx mcs |
| 344 | * @vht_capable: VHT capabalities |
| 345 | */ |
| 346 | struct peer_assoc_params { |
| 347 | wmi_mac_addr peer_macaddr; |
| 348 | uint32_t vdev_id; |
| 349 | uint32_t peer_new_assoc; |
| 350 | uint32_t peer_associd; |
| 351 | uint32_t peer_flags; |
| 352 | uint32_t peer_caps; |
| 353 | uint32_t peer_listen_intval; |
| 354 | uint32_t peer_ht_caps; |
| 355 | uint32_t peer_max_mpdu; |
| 356 | uint32_t peer_mpdu_density; |
| 357 | uint32_t peer_rate_caps; |
| 358 | uint32_t peer_nss; |
| 359 | uint32_t peer_vht_caps; |
| 360 | uint32_t peer_phymode; |
| 361 | uint32_t peer_ht_info[2]; |
| 362 | wmi_rate_set peer_legacy_rates; |
| 363 | wmi_rate_set peer_ht_rates; |
| 364 | uint32_t num_peer_legacy_rates; |
| 365 | uint32_t num_peer_ht_rates; |
| 366 | uint32_t rx_max_rate; |
| 367 | uint32_t rx_mcs_set; |
| 368 | uint32_t tx_max_rate; |
| 369 | uint32_t tx_mcs_set; |
| 370 | uint8_t vht_capable; |
| 371 | }; |
| 372 | |
| 373 | /** |
| 374 | * struct sta_ps_params - sta ps cmd parameter |
| 375 | * @vdev_id: vdev id |
| 376 | * @param: sta ps paramter |
| 377 | * @value: sta ps parameter value |
| 378 | */ |
| 379 | struct sta_ps_params { |
| 380 | uint32_t vdev_id; |
| 381 | uint32_t param; |
| 382 | uint32_t value; |
| 383 | }; |
| 384 | |
| 385 | /** |
| 386 | * struct ap_ps_params - ap ps cmd parameter |
| 387 | * @vdev_id: vdev id |
| 388 | * @param: ap ps paramter |
| 389 | * @value: ap ps paramter value |
| 390 | */ |
| 391 | struct ap_ps_params { |
| 392 | uint32_t vdev_id; |
| 393 | uint32_t param; |
| 394 | uint32_t value; |
| 395 | }; |
| 396 | |
| 397 | /** |
| 398 | * struct mac_ssid - mac ssid structure |
| 399 | * @length: |
| 400 | * @mac_ssid[WMI_MAC_MAX_SSID_LENGTH]: |
| 401 | */ |
| 402 | struct mac_ssid { |
| 403 | uint8_t length; |
| 404 | uint8_t mac_ssid[WMI_MAC_MAX_SSID_LENGTH]; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 405 | } qdf_packed; |
Govind Singh | 3ddda1f | 2016-03-09 11:34:12 +0530 | [diff] [blame] | 406 | |
| 407 | /** |
| 408 | * struct scan_start_params - start scan cmd parameter |
| 409 | * @scan_id: scan id |
| 410 | * @scan_req_id: requeted scan id |
| 411 | * @vdev_id: vdev id |
| 412 | * @scan_priority: scan priority |
| 413 | * @notify_scan_events: flag to indicate if scan to be notified |
| 414 | * @dwell_time_active: active dwell time |
| 415 | * @dwell_time_passive: passive dwell time |
| 416 | * @min_rest_time: min rest time |
| 417 | * @max_rest_time: max rest time |
| 418 | * @repeat_probe_time: repeat probe time |
| 419 | * @probe_spacing_time: probe spacing time |
| 420 | * @idle_time: idle time |
| 421 | * @max_scan_time: max scan time |
| 422 | * @probe_delay: probe delay |
| 423 | * @scan_ctrl_flags: scan control flag |
| 424 | * @burst_duration: burst duration |
| 425 | * @num_chan: no of channel |
| 426 | * @num_bssid: no of bssid |
| 427 | * @num_ssids: no of ssid |
| 428 | * @ie_len: ie length |
| 429 | * @n_probes: no of probe |
| 430 | * @chan_list: channel list |
| 431 | * @ie_len_with_pad: ie length with padding |
| 432 | * @num_ssid: no of ssid |
| 433 | * @sid: pointer to mac_ssid structure |
| 434 | * @uie_fieldOffset: ie field offset |
| 435 | * @mac_add_bytes: mac address bytes |
| 436 | */ |
| 437 | struct scan_start_params { |
| 438 | uint32_t scan_id; |
| 439 | uint32_t scan_req_id; |
| 440 | uint32_t vdev_id; |
| 441 | uint32_t scan_priority; |
| 442 | uint32_t notify_scan_events; |
| 443 | uint32_t dwell_time_active; |
| 444 | uint32_t dwell_time_passive; |
| 445 | uint32_t min_rest_time; |
| 446 | uint32_t max_rest_time; |
| 447 | uint32_t repeat_probe_time; |
| 448 | uint32_t probe_spacing_time; |
| 449 | uint32_t idle_time; |
| 450 | uint32_t max_scan_time; |
| 451 | uint32_t probe_delay; |
| 452 | uint32_t scan_ctrl_flags; |
| 453 | uint32_t burst_duration; |
| 454 | uint32_t num_chan; |
| 455 | uint32_t num_bssid; |
| 456 | uint32_t num_ssids; |
| 457 | uint32_t ie_len; |
| 458 | uint32_t n_probes; |
| 459 | uint32_t *chan_list; |
| 460 | uint32_t ie_len_with_pad; |
| 461 | struct mac_ssid ssid[WMI_SCAN_MAX_NUM_SSID]; |
| 462 | uint8_t *ie_base; |
| 463 | uint16_t uie_fieldOffset; |
| 464 | uint8_t mac_add_bytes[IEEE80211_ADDR_LEN]; |
| 465 | }; |
| 466 | |
| 467 | /** |
| 468 | * struct scan_stop_params - stop scan cmd parameter |
| 469 | * @requestor: scan requestor |
| 470 | * @scan_id: scan id |
| 471 | * @req_type: scan request type |
| 472 | * @vdev_id: vdev id |
| 473 | */ |
| 474 | struct scan_stop_params { |
| 475 | uint32_t requestor; |
| 476 | uint32_t scan_id; |
| 477 | uint32_t req_type; |
| 478 | uint32_t vdev_id; |
| 479 | }; |
| 480 | |
| 481 | /** |
| 482 | * struct scan_chan_list_params - scan channel list cmd parameter |
| 483 | * @num_scan_chans: no of scan channels |
| 484 | * @chan_info: pointer to wmi channel info |
| 485 | */ |
| 486 | struct scan_chan_list_params { |
| 487 | uint8_t num_scan_chans; |
| 488 | wmi_channel *chan_info; |
| 489 | }; |
| 490 | |
| 491 | /** |
| 492 | * struct fw_hang_params - fw hang command parameters |
| 493 | * @type: 0:unused 1: ASSERT, 2:not respond detect command, 3:simulate ep-full |
| 494 | * @delay_time_ms: 0xffffffff means the simulate will delay for random time (0 ~0xffffffff ms) |
| 495 | */ |
| 496 | struct fw_hang_params { |
| 497 | uint32_t type; |
| 498 | uint32_t delay_time_ms; |
| 499 | }; |
| 500 | |
| 501 | /** |
| 502 | * struct pdev_utf_params - pdev utf command parameters |
| 503 | * @utf_payload: |
| 504 | * @len: |
| 505 | */ |
| 506 | struct pdev_utf_params { |
| 507 | uint8_t *utf_payload; |
| 508 | uint32_t len; |
| 509 | }; |
| 510 | |
| 511 | /** |
| 512 | * struct crash_inject - crash inject command parameters |
| 513 | * @type: crash inject type |
| 514 | * @delay_time_ms: time in milliseconds for FW to delay the crash |
| 515 | */ |
| 516 | struct crash_inject { |
| 517 | uint32_t type; |
| 518 | uint32_t delay_time_ms; |
| 519 | }; |
| 520 | |
| 521 | /** |
| 522 | * struct dbglog_params - fw deboglog command parameters |
| 523 | * @param: command parameter |
| 524 | * @val: parameter value |
| 525 | * @module_id_bitmap: fixed length module id bitmap |
| 526 | * @bitmap_len: module id bitmap length |
| 527 | */ |
| 528 | struct dbglog_params { |
| 529 | uint32_t param; |
| 530 | uint32_t val; |
| 531 | uint32_t *module_id_bitmap; |
| 532 | uint32_t bitmap_len; |
| 533 | }; |
| 534 | |
| 535 | /** |
| 536 | * struct seg_hdr_info - header info |
| 537 | * @len: length |
| 538 | * @msgref: message refrence |
| 539 | * @segmentInfo: segment info |
| 540 | * @pad: padding |
| 541 | */ |
| 542 | struct seg_hdr_info { |
| 543 | uint32_t len; |
| 544 | uint32_t msgref; |
| 545 | uint32_t segmentInfo; |
| 546 | uint32_t pad; |
| 547 | }; |
| 548 | |
| 549 | /** |
| 550 | * struct wmi_mgmt_params - wmi mgmt cmd paramters |
| 551 | * @tx_frame: management tx frame |
| 552 | * @frmLen: frame length |
| 553 | * @vdev_id: vdev id |
| 554 | * @tx_complete_cb: tx download callback handler |
| 555 | * @tx_ota_post_proc_cb: OTA complition handler |
| 556 | * @chanfreq: channel frequency |
| 557 | * @pdata: frame data |
| 558 | * @wmi_desc: command descriptor |
| 559 | */ |
| 560 | struct wmi_mgmt_params { |
| 561 | void *tx_frame; |
| 562 | uint16_t frm_len; |
| 563 | uint8_t vdev_id; |
| 564 | void *tx_complete_cb; |
| 565 | void *tx_ota_post_proc_cb; |
| 566 | uint16_t chanfreq; |
| 567 | void *pdata; |
| 568 | struct wmi_desc_t *wmi_desc; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 569 | void *qdf_ctx; |
Govind Singh | 3ddda1f | 2016-03-09 11:34:12 +0530 | [diff] [blame] | 570 | }; |
Govind Singh | bffe4de | 2016-02-26 17:50:39 +0530 | [diff] [blame] | 571 | |
| 572 | /** |
| 573 | * struct p2p_ps_params - P2P powersave related params |
| 574 | * @opp_ps: opportunistic power save |
| 575 | * @ctwindow: CT window |
| 576 | * @count: count |
| 577 | * @duration: duration |
| 578 | * @interval: interval |
| 579 | * @single_noa_duration: single shot noa duration |
| 580 | * @ps_selection: power save selection |
| 581 | * @session_id: session id |
| 582 | */ |
| 583 | struct p2p_ps_params { |
| 584 | uint8_t opp_ps; |
| 585 | uint32_t ctwindow; |
| 586 | uint8_t count; |
| 587 | uint32_t duration; |
| 588 | uint32_t interval; |
| 589 | uint32_t single_noa_duration; |
| 590 | uint8_t ps_selection; |
| 591 | uint8_t session_id; |
| 592 | }; |
| 593 | |
| 594 | |
| 595 | /** |
| 596 | * struct ta_uapsd_trig_params - uapsd trigger parameter |
| 597 | * @vdevid: vdev id |
| 598 | * @peer_addr: peer address |
| 599 | * @auto_triggerparam: trigger parameters |
| 600 | * @num_ac: no of access category |
| 601 | */ |
| 602 | struct sta_uapsd_trig_params { |
| 603 | uint32_t vdevid; |
| 604 | uint8_t peer_addr[IEEE80211_ADDR_LEN]; |
| 605 | uint8_t *auto_triggerparam; |
| 606 | uint32_t num_ac; |
| 607 | }; |
Govind Singh | e7b800c | 2016-03-01 15:30:53 +0530 | [diff] [blame] | 608 | |
| 609 | /** |
| 610 | * struct ocb_utc_param |
| 611 | * @vdev_id: session id |
| 612 | * @utc_time: number of nanoseconds from Jan 1st 1958 |
| 613 | * @time_error: the error in the UTC time. All 1's for unknown |
| 614 | */ |
| 615 | struct ocb_utc_param { |
| 616 | uint32_t vdev_id; |
| 617 | uint8_t utc_time[WMI_SIZE_UTC_TIME]; |
| 618 | uint8_t time_error[WMI_SIZE_UTC_TIME_ERROR]; |
| 619 | }; |
| 620 | |
| 621 | /** |
| 622 | * struct ocb_timing_advert_param |
| 623 | * @vdev_id: session id |
| 624 | * @chan_freq: frequency on which to advertise |
| 625 | * @repeat_rate: the number of times it will send TA in 5 seconds |
| 626 | * @timestamp_offset: offset of the timestamp field in the TA frame |
| 627 | * @time_value_offset: offset of the time_value field in the TA frame |
| 628 | * @template_length: size in bytes of the TA frame |
| 629 | * @template_value: the TA frame |
| 630 | */ |
| 631 | struct ocb_timing_advert_param { |
| 632 | uint32_t vdev_id; |
| 633 | uint32_t chan_freq; |
| 634 | uint32_t repeat_rate; |
| 635 | uint32_t timestamp_offset; |
| 636 | uint32_t time_value_offset; |
| 637 | uint32_t template_length; |
| 638 | uint8_t *template_value; |
| 639 | }; |
| 640 | |
| 641 | /** |
| 642 | * struct dcc_get_stats_param |
| 643 | * @vdev_id: session id |
| 644 | * @channel_count: number of dcc channels |
| 645 | * @request_array_len: size in bytes of the request array |
| 646 | * @request_array: the request array |
| 647 | */ |
| 648 | struct dcc_get_stats_param { |
| 649 | uint32_t vdev_id; |
| 650 | uint32_t channel_count; |
| 651 | uint32_t request_array_len; |
| 652 | void *request_array; |
| 653 | }; |
| 654 | |
| 655 | /** |
| 656 | * struct dcc_update_ndl_param |
| 657 | * @vdev_id: session id |
| 658 | * @channel_count: number of channels to be updated |
| 659 | * @dcc_ndl_chan_list_len: size in bytes of the ndl_chan array |
| 660 | * @dcc_ndl_chan_list: the ndl_chan array |
| 661 | * @dcc_ndl_active_state_list_len: size in bytes of the active_state array |
| 662 | * @dcc_ndl_active_state_list: the active state array |
| 663 | */ |
| 664 | struct dcc_update_ndl_param { |
| 665 | uint32_t vdev_id; |
| 666 | uint32_t channel_count; |
| 667 | uint32_t dcc_ndl_chan_list_len; |
| 668 | void *dcc_ndl_chan_list; |
| 669 | uint32_t dcc_ndl_active_state_list_len; |
| 670 | void *dcc_ndl_active_state_list; |
| 671 | }; |
| 672 | |
| 673 | /** |
| 674 | * struct ocb_config_sched |
| 675 | * @chan_freq: frequency of the channel |
| 676 | * @total_duration: duration of the schedule |
| 677 | * @guard_interval: guard interval on the start of the schedule |
| 678 | */ |
| 679 | struct ocb_config_sched { |
| 680 | uint32_t chan_freq; |
| 681 | uint32_t total_duration; |
| 682 | uint32_t guard_interval; |
| 683 | }; |
| 684 | |
| 685 | /** |
| 686 | * OCB structures |
| 687 | */ |
| 688 | |
| 689 | #define WMI_NUM_AC (4) |
| 690 | #define WMI_OCB_CHANNEL_MAX (5) |
| 691 | #define WMI_MAX_NUM_AC 4 |
| 692 | struct wmi_ocb_qos_params { |
| 693 | uint8_t aifsn; |
| 694 | uint8_t cwmin; |
| 695 | uint8_t cwmax; |
| 696 | }; |
| 697 | /** |
| 698 | * struct ocb_config_channel |
| 699 | * @chan_freq: frequency of the channel |
| 700 | * @bandwidth: bandwidth of the channel, either 10 or 20 MHz |
| 701 | * @mac_address: MAC address assigned to this channel |
| 702 | * @qos_params: QoS parameters |
| 703 | * @max_pwr: maximum transmit power of the channel (dBm) |
| 704 | * @min_pwr: minimum transmit power of the channel (dBm) |
| 705 | * @reg_pwr: maximum transmit power specified by the regulatory domain (dBm) |
| 706 | * @antenna_max: maximum antenna gain specified by the regulatory domain (dB) |
| 707 | */ |
| 708 | struct ocb_config_channel { |
| 709 | uint32_t chan_freq; |
| 710 | uint32_t bandwidth; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 711 | struct qdf_mac_addr mac_address; |
Govind Singh | e7b800c | 2016-03-01 15:30:53 +0530 | [diff] [blame] | 712 | struct wmi_ocb_qos_params qos_params[WMI_MAX_NUM_AC]; |
| 713 | uint32_t max_pwr; |
| 714 | uint32_t min_pwr; |
| 715 | uint8_t reg_pwr; |
| 716 | uint8_t antenna_max; |
| 717 | uint16_t flags; |
| 718 | }; |
| 719 | |
| 720 | /** |
| 721 | * struct ocb_config_param |
| 722 | * @session_id: session id |
| 723 | * @channel_count: number of channels |
| 724 | * @schedule_size: size of the channel schedule |
| 725 | * @flags: reserved |
| 726 | * @channels: array of OCB channels |
| 727 | * @schedule: array of OCB schedule elements |
| 728 | * @dcc_ndl_chan_list_len: size of the ndl_chan array |
| 729 | * @dcc_ndl_chan_list: array of dcc channel info |
| 730 | * @dcc_ndl_active_state_list_len: size of the active state array |
| 731 | * @dcc_ndl_active_state_list: array of active states |
| 732 | * @adapter: the OCB adapter |
| 733 | * @dcc_stats_callback: callback for the response event |
| 734 | */ |
| 735 | struct ocb_config_param { |
| 736 | uint8_t session_id; |
| 737 | uint32_t channel_count; |
| 738 | uint32_t schedule_size; |
| 739 | uint32_t flags; |
| 740 | struct ocb_config_channel *channels; |
| 741 | struct ocb_config_sched *schedule; |
| 742 | uint32_t dcc_ndl_chan_list_len; |
| 743 | void *dcc_ndl_chan_list; |
| 744 | uint32_t dcc_ndl_active_state_list_len; |
| 745 | void *dcc_ndl_active_state_list; |
| 746 | }; |
Govind Singh | 9bad000 | 2016-03-01 15:54:59 +0530 | [diff] [blame] | 747 | |
| 748 | /** |
| 749 | * struct t_thermal_cmd_params - thermal command parameters |
| 750 | * @min_temp: minimum temprature |
| 751 | * @max_temp: maximum temprature |
| 752 | * @thermal_enable: thermal enable |
| 753 | */ |
| 754 | struct thermal_cmd_params { |
| 755 | uint16_t min_temp; |
| 756 | uint16_t max_temp; |
| 757 | uint8_t thermal_enable; |
| 758 | }; |
| 759 | |
| 760 | #define WMI_LRO_IPV4_SEED_ARR_SZ 5 |
| 761 | #define WMI_LRO_IPV6_SEED_ARR_SZ 11 |
| 762 | |
| 763 | /** |
| 764 | * struct wmi_lro_config_cmd_t - set LRO init parameters |
| 765 | * @lro_enable: indicates whether lro is enabled |
| 766 | * @tcp_flag: If the TCP flags from the packet do not match |
| 767 | * the values in this field after masking with TCP flags mask |
| 768 | * below, packet is not LRO eligible |
| 769 | * @tcp_flag_mask: field for comparing the TCP values provided |
| 770 | * above with the TCP flags field in the received packet |
| 771 | * @toeplitz_hash_ipv4: contains seed needed to compute the flow id |
| 772 | * 5-tuple toeplitz hash for ipv4 packets |
| 773 | * @toeplitz_hash_ipv6: contains seed needed to compute the flow id |
| 774 | * 5-tuple toeplitz hash for ipv6 packets |
| 775 | */ |
| 776 | struct wmi_lro_config_cmd_t { |
| 777 | uint32_t lro_enable; |
| 778 | uint32_t tcp_flag:9, |
| 779 | tcp_flag_mask:9; |
| 780 | uint32_t toeplitz_hash_ipv4[WMI_LRO_IPV4_SEED_ARR_SZ]; |
| 781 | uint32_t toeplitz_hash_ipv6[WMI_LRO_IPV6_SEED_ARR_SZ]; |
| 782 | }; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 783 | |
| 784 | /** |
| 785 | * struct gtx_config_t - GTX config |
| 786 | * @gtx_rt_mask: for HT and VHT rate masks |
| 787 | * @gtx_usrcfg: host request for GTX mask |
| 788 | * @gtx_threshold: PER Threshold (default: 10%) |
| 789 | * @gtx_margin: PER margin (default: 2%) |
| 790 | * @gtx_tcpstep: TCP step (default: 1) |
| 791 | * @gtx_tpcMin: TCP min (default: 5) |
| 792 | * @gtx_bwmask: BW mask (20/40/80/160 Mhz) |
| 793 | */ |
| 794 | struct wmi_gtx_config { |
| 795 | uint32_t gtx_rt_mask[2]; |
| 796 | uint32_t gtx_usrcfg; |
| 797 | uint32_t gtx_threshold; |
| 798 | uint32_t gtx_margin; |
| 799 | uint32_t gtx_tpcstep; |
| 800 | uint32_t gtx_tpcmin; |
| 801 | uint32_t gtx_bwmask; |
| 802 | }; |
| 803 | |
| 804 | /** |
| 805 | * struct wmi_probe_resp_params - send probe response parameters |
| 806 | * @bssId: BSSID |
| 807 | * @pProbeRespTemplate: probe response template |
| 808 | * @probeRespTemplateLen: probe response template length |
| 809 | * @ucProxyProbeReqValidIEBmap: valid IE bitmap |
| 810 | */ |
| 811 | struct wmi_probe_resp_params { |
| 812 | uint8_t bssId[WMI_ETH_LEN]; |
| 813 | uint8_t *pProbeRespTemplate; |
| 814 | uint32_t probeRespTemplateLen; |
| 815 | uint32_t ucProxyProbeReqValidIEBmap[8]; |
| 816 | }; |
| 817 | |
| 818 | /** |
| 819 | * struct sta_params - sta keep alive parameters |
| 820 | * @vdev_id: vdev id |
| 821 | * @method: keep alive method |
| 822 | * @timeperiod: time to keep alive |
| 823 | * @hostv4addr: host ipv4 address |
| 824 | * @destv4addr: destination ipv4 address |
| 825 | * @destmac: destination mac address |
| 826 | */ |
| 827 | struct sta_params { |
| 828 | uint8_t vdev_id; |
| 829 | uint32_t method; |
| 830 | uint32_t timeperiod; |
| 831 | uint8_t *hostv4addr; |
| 832 | uint8_t *destv4addr; |
| 833 | uint8_t *destmac; |
| 834 | }; |
| 835 | |
| 836 | /** |
| 837 | * struct gateway_update_req_param - gateway parameter update request |
| 838 | * @request_id: request id |
| 839 | * @session_id: session id |
| 840 | * @max_retries: Max ARP/NS retry attempts |
| 841 | * @timeout: Retry interval |
| 842 | * @ipv4_addr_type: on ipv4 network |
| 843 | * @ipv6_addr_type: on ipv6 network |
| 844 | * @gw_mac_addr: gateway mac addr |
| 845 | * @ipv4_addr: ipv4 addr |
| 846 | * @ipv6_addr: ipv6 addr |
| 847 | */ |
| 848 | struct gateway_update_req_param { |
| 849 | uint32_t request_id; |
| 850 | uint32_t session_id; |
| 851 | uint32_t max_retries; |
| 852 | uint32_t timeout; |
| 853 | uint32_t ipv4_addr_type; |
| 854 | uint32_t ipv6_addr_type; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 855 | struct qdf_mac_addr gw_mac_addr; |
| 856 | uint8_t ipv4_addr[QDF_IPV4_ADDR_SIZE]; |
| 857 | uint8_t ipv6_addr[QDF_IPV6_ADDR_SIZE]; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 858 | }; |
| 859 | |
| 860 | /** |
| 861 | * struct rssi_monitor_param - rssi monitoring |
| 862 | * @request_id: request id |
| 863 | * @session_id: session id |
| 864 | * @min_rssi: minimum rssi |
| 865 | * @max_rssi: maximum rssi |
| 866 | * @control: flag to indicate start or stop |
| 867 | */ |
| 868 | struct rssi_monitor_param { |
| 869 | uint32_t request_id; |
| 870 | uint32_t session_id; |
| 871 | int8_t min_rssi; |
| 872 | int8_t max_rssi; |
| 873 | bool control; |
| 874 | }; |
| 875 | |
| 876 | /** |
| 877 | * struct scan_mac_oui - oui paramters |
| 878 | * @oui: oui parameters |
| 879 | */ |
| 880 | struct scan_mac_oui { |
| 881 | uint8_t oui[WMI_WIFI_SCANNING_MAC_OUI_LENGTH]; |
| 882 | }; |
| 883 | |
| 884 | #define WMI_PASSPOINT_REALM_LEN 256 |
| 885 | #define WMI_PASSPOINT_ROAMING_CONSORTIUM_ID_NUM 16 |
| 886 | #define WMI_PASSPOINT_PLMN_LEN 3 |
| 887 | /** |
| 888 | * struct wifi_passpoint_network_param - passpoint network block |
| 889 | * @id: identifier of this network block |
| 890 | * @realm: null terminated UTF8 encoded realm, 0 if unspecified |
| 891 | * @roaming_consortium_ids: roaming consortium ids to match, 0s if unspecified |
| 892 | * @plmn: mcc/mnc combination as per rules, 0s if unspecified |
| 893 | */ |
| 894 | struct wifi_passpoint_network_param { |
| 895 | uint32_t id; |
| 896 | uint8_t realm[WMI_PASSPOINT_REALM_LEN]; |
| 897 | int64_t roaming_consortium_ids[WMI_PASSPOINT_ROAMING_CONSORTIUM_ID_NUM]; |
| 898 | uint8_t plmn[WMI_PASSPOINT_PLMN_LEN]; |
| 899 | }; |
| 900 | |
| 901 | /** |
| 902 | * struct wifi_passpoint_req_param - passpoint request |
| 903 | * @request_id: request identifier |
| 904 | * @num_networks: number of networks |
| 905 | * @networks: passpoint networks |
| 906 | */ |
| 907 | struct wifi_passpoint_req_param { |
| 908 | uint32_t request_id; |
| 909 | uint32_t session_id; |
| 910 | uint32_t num_networks; |
| 911 | struct wifi_passpoint_network_param networks[]; |
| 912 | }; |
| 913 | |
| 914 | /** |
| 915 | * struct wifi_epno_network - enhanced pno network block |
| 916 | * @ssid: ssid |
| 917 | * @rssi_threshold: threshold for considering this SSID as found, required |
| 918 | * granularity for this threshold is 4dBm to 8dBm |
| 919 | * @flags: WIFI_PNO_FLAG_XXX |
| 920 | * @auth_bit_field: auth bit field for matching WPA IE |
| 921 | */ |
| 922 | struct wifi_epno_network_params { |
| 923 | struct mac_ssid ssid; |
| 924 | int8_t rssi_threshold; |
| 925 | uint8_t flags; |
| 926 | uint8_t auth_bit_field; |
| 927 | }; |
| 928 | |
| 929 | /** |
| 930 | * struct wifi_enhanched_pno_params - enhanced pno network params |
| 931 | * @num_networks: number of ssids |
| 932 | * @networks: PNO networks |
| 933 | */ |
| 934 | struct wifi_enhanched_pno_params { |
| 935 | uint32_t request_id; |
| 936 | uint32_t session_id; |
| 937 | uint32_t num_networks; |
| 938 | struct wifi_epno_network_params networks[]; |
| 939 | }; |
| 940 | |
| 941 | enum { |
| 942 | WMI_AP_RX_DATA_OFFLOAD = 0x00, |
| 943 | WMI_STA_RX_DATA_OFFLOAD = 0x01, |
| 944 | }; |
| 945 | |
| 946 | /** |
| 947 | * enum extscan_report_events_type - extscan report events type |
| 948 | * @EXTSCAN_REPORT_EVENTS_BUFFER_FULL: report only when scan history is % full |
| 949 | * @EXTSCAN_REPORT_EVENTS_EACH_SCAN: report a scan completion event after scan |
| 950 | * @EXTSCAN_REPORT_EVENTS_FULL_RESULTS: forward scan results |
| 951 | * (beacons/probe responses + IEs) |
| 952 | * in real time to HAL, in addition to completion events. |
| 953 | * Note: To keep backward compatibility, |
| 954 | * fire completion events regardless of REPORT_EVENTS_EACH_SCAN. |
| 955 | * @EXTSCAN_REPORT_EVENTS_NO_BATCH: controls batching, |
| 956 | * 0 => batching, 1 => no batching |
| 957 | */ |
| 958 | enum wmi_extscan_report_events_type { |
| 959 | WMI_EXTSCAN_REPORT_EVENTS_BUFFER_FULL = 0x00, |
| 960 | WMI_EXTSCAN_REPORT_EVENTS_EACH_SCAN = 0x01, |
| 961 | WMI_EXTSCAN_REPORT_EVENTS_FULL_RESULTS = 0x02, |
| 962 | WMI_EXTSCAN_REPORT_EVENTS_NO_BATCH = 0x04, |
| 963 | }; |
| 964 | |
| 965 | /** |
| 966 | * struct ipa_offload_control_params - ipa offload parameters |
| 967 | * @offload_type: ipa offload type |
| 968 | * @vdev_id: vdev id |
| 969 | * @enable: ipa offload enable/disable |
| 970 | */ |
| 971 | struct ipa_offload_control_params { |
| 972 | uint32_t offload_type; |
| 973 | uint32_t vdev_id; |
| 974 | uint32_t enable; |
| 975 | }; |
| 976 | |
| 977 | /** |
| 978 | * struct extscan_capabilities_params - ext scan capablities |
| 979 | * @request_id: request_id |
| 980 | * @session_id: session_id |
| 981 | */ |
| 982 | struct extscan_capabilities_params { |
| 983 | uint32_t request_id; |
| 984 | uint8_t session_id; |
| 985 | }; |
| 986 | |
| 987 | /** |
| 988 | * struct extscan_capabilities_reset_params - ext scan capablities reset parameter |
| 989 | * @request_id: request_id |
| 990 | * @session_id: session_id |
| 991 | */ |
| 992 | struct extscan_capabilities_reset_params { |
| 993 | uint32_t request_id; |
| 994 | uint8_t session_id; |
| 995 | }; |
| 996 | |
| 997 | /** |
| 998 | * struct extscan_bssid_hotlist_reset_params - ext scan hotlist reset parameter |
| 999 | * @request_id: request_id |
| 1000 | * @session_id: session_id |
| 1001 | */ |
| 1002 | struct extscan_bssid_hotlist_reset_params { |
| 1003 | uint32_t request_id; |
| 1004 | uint8_t session_id; |
| 1005 | }; |
| 1006 | |
| 1007 | /** |
| 1008 | * struct extscan_stop_req_params - ext scan stop parameter |
| 1009 | * @request_id: request_id |
| 1010 | * @session_id: session_id |
| 1011 | */ |
| 1012 | struct extscan_stop_req_params { |
| 1013 | uint32_t request_id; |
| 1014 | uint8_t session_id; |
| 1015 | }; |
| 1016 | |
| 1017 | /** |
| 1018 | * struct ap_threshold_params - ap threshold parameter |
| 1019 | * @bssid: mac address |
| 1020 | * @low: low threshold |
| 1021 | * @high: high threshold |
| 1022 | */ |
| 1023 | struct ap_threshold_params { |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1024 | struct qdf_mac_addr bssid; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1025 | int32_t low; |
| 1026 | int32_t high; |
| 1027 | }; |
| 1028 | |
| 1029 | /** |
| 1030 | * struct extscan_set_sig_changereq_params - ext scan channel parameter |
| 1031 | * @request_id: mac address |
| 1032 | * @session_id: low threshold |
| 1033 | * @rssi_sample_size: Number of samples for averaging RSSI |
| 1034 | * @lostap_sample_size: Number of missed samples to confirm AP loss |
| 1035 | * @min_breaching: Number of APs breaching threshold required for firmware |
| 1036 | * @num_ap: no of scanned ap |
| 1037 | * @ap: ap threshold parameter |
| 1038 | */ |
| 1039 | struct extscan_set_sig_changereq_params { |
| 1040 | uint32_t request_id; |
| 1041 | uint8_t session_id; |
| 1042 | uint32_t rssi_sample_size; |
| 1043 | uint32_t lostap_sample_size; |
| 1044 | uint32_t min_breaching; |
| 1045 | uint32_t num_ap; |
| 1046 | struct ap_threshold_params ap[WMI_EXTSCAN_MAX_SIGNIFICANT_CHANGE_APS]; |
| 1047 | }; |
| 1048 | |
| 1049 | /** |
| 1050 | * struct extscan_cached_result_params - ext scan cached parameter |
| 1051 | * @request_id: mac address |
| 1052 | * @session_id: low threshold |
| 1053 | * @flush: cached results flush |
| 1054 | */ |
| 1055 | struct extscan_cached_result_params { |
| 1056 | uint32_t request_id; |
| 1057 | uint8_t session_id; |
| 1058 | bool flush; |
| 1059 | }; |
| 1060 | |
| 1061 | #ifdef FEATURE_WLAN_SCAN_PNO |
| 1062 | /* Set PNO */ |
| 1063 | #define WMI_PNO_MAX_NETW_CHANNELS 26 |
| 1064 | #define WMI_PNO_MAX_NETW_CHANNELS_EX 60 |
| 1065 | #define WMI_PNO_MAX_SUPP_NETWORKS 16 |
| 1066 | |
| 1067 | /* |
| 1068 | * size based of dot11 declaration without extra IEs as we will not carry those |
| 1069 | * for PNO |
| 1070 | */ |
| 1071 | #define WMI_PNO_MAX_PB_REQ_SIZE 450 |
| 1072 | |
| 1073 | #define WMI_PNO_24G_DEFAULT_CH 1 |
| 1074 | #define WMI_PNO_5G_DEFAULT_CH 36 |
| 1075 | |
| 1076 | /** |
| 1077 | * enum pno_mode - pno mode types |
| 1078 | * @WMI_PNO_MODE_IMMEDIATE: immidiate mode |
| 1079 | * @WMI_PNO_MODE_ON_SUSPEND: suspend on mode |
| 1080 | * @WMI_PNO_MODE_ON_RESUME: resume on mode |
| 1081 | * @WMI_PNO_MODE_MAX: max range |
| 1082 | */ |
| 1083 | enum pno_mode { |
| 1084 | WMI_PNO_MODE_IMMEDIATE, |
| 1085 | WMI_PNO_MODE_ON_SUSPEND, |
| 1086 | WMI_PNO_MODE_ON_RESUME, |
| 1087 | WMI_PNO_MODE_MAX |
| 1088 | }; |
| 1089 | |
| 1090 | /** |
| 1091 | * struct pno_nw_type - pno nw type |
| 1092 | * @ssid: mac ssid |
| 1093 | * @authentication: authentication type |
| 1094 | * @encryption: encryption type |
| 1095 | * @bcastNetwType: broadcast nw type |
| 1096 | * @ucChannelCount: uc channel count |
| 1097 | * @aChannels: pno channel |
| 1098 | * @rssiThreshold: rssi threshold |
| 1099 | */ |
| 1100 | struct pno_nw_type { |
| 1101 | struct mac_ssid ssid; |
| 1102 | uint32_t authentication; |
| 1103 | uint32_t encryption; |
| 1104 | uint32_t bcastNetwType; |
| 1105 | uint8_t ucChannelCount; |
| 1106 | uint8_t aChannels[WMI_PNO_MAX_NETW_CHANNELS_EX]; |
| 1107 | int32_t rssiThreshold; |
| 1108 | }; |
| 1109 | |
| 1110 | /** |
| 1111 | * struct pno_scan_req_params - PNO Scan request structure |
| 1112 | * @enable: flag to enable or disable |
| 1113 | * @modePNO: PNO Mode |
| 1114 | * @ucNetworksCount: Number of networks |
| 1115 | * @aNetworks: Preferred network list |
| 1116 | * @sessionId: Session identifier |
| 1117 | * @fast_scan_period: Fast Scan period |
| 1118 | * @slow_scan_period: Slow scan period |
| 1119 | * @fast_scan_max_cycles: Fast scan max cycles |
| 1120 | * @us24GProbeTemplateLen: 2.4G probe template length |
| 1121 | * @p24GProbeTemplate: 2.4G probe template |
| 1122 | * @us5GProbeTemplateLen: 5G probe template length |
| 1123 | * @p5GProbeTemplate: 5G probe template |
| 1124 | */ |
| 1125 | struct pno_scan_req_params { |
| 1126 | uint8_t enable; |
| 1127 | enum pno_mode modePNO; |
| 1128 | uint8_t ucNetworksCount; |
| 1129 | struct pno_nw_type aNetworks[WMI_PNO_MAX_SUPP_NETWORKS]; |
| 1130 | uint8_t sessionId; |
| 1131 | uint32_t fast_scan_period; |
| 1132 | uint32_t slow_scan_period; |
| 1133 | uint8_t fast_scan_max_cycles; |
| 1134 | uint32_t active_min_time; |
| 1135 | uint32_t active_max_time; |
| 1136 | uint32_t passive_min_time; |
| 1137 | uint32_t passive_max_time; |
| 1138 | uint16_t us24GProbeTemplateLen; |
| 1139 | uint8_t p24GProbeTemplate[WMI_PNO_MAX_PB_REQ_SIZE]; |
| 1140 | uint16_t us5GProbeTemplateLen; |
| 1141 | uint8_t p5GProbeTemplate[WMI_PNO_MAX_PB_REQ_SIZE]; |
| 1142 | #ifdef FEATURE_WLAN_SCAN_PNO |
| 1143 | bool pno_channel_prediction; |
| 1144 | uint8_t top_k_num_of_channels; |
| 1145 | uint8_t stationary_thresh; |
| 1146 | uint32_t channel_prediction_full_scan; |
| 1147 | #endif |
| 1148 | }; |
| 1149 | |
| 1150 | #endif /* FEATURE_WLAN_SCAN_PNO */ |
| 1151 | |
| 1152 | #define WMI_WLAN_EXTSCAN_MAX_CHANNELS 36 |
| 1153 | #define WMI_WLAN_EXTSCAN_MAX_BUCKETS 16 |
| 1154 | #define WMI_WLAN_EXTSCAN_MAX_HOTLIST_APS 128 |
| 1155 | #define WMI_WLAN_EXTSCAN_MAX_SIGNIFICANT_CHANGE_APS 64 |
| 1156 | #define WMI_EXTSCAN_MAX_HOTLIST_SSIDS 8 |
| 1157 | |
| 1158 | /** |
| 1159 | * struct wifi_scan_channelspec_params - wifi scan channel parameter |
| 1160 | * @channel: Frequency in MHz |
| 1161 | * @dwellTimeMs: dwell time |
| 1162 | * @flush: cached results flush |
| 1163 | * @passive: passive scan |
| 1164 | * @chnlClass: channel class |
| 1165 | */ |
| 1166 | struct wifi_scan_channelspec_params { |
| 1167 | uint32_t channel; |
| 1168 | uint32_t dwellTimeMs; |
| 1169 | bool passive; |
| 1170 | uint8_t chnlClass; |
| 1171 | }; |
| 1172 | |
| 1173 | /** |
| 1174 | * enum wmi_wifi_band - wifi band |
| 1175 | * @WMI_WIFI_BAND_UNSPECIFIED: unspecified band |
| 1176 | * @WMI_WIFI_BAND_BG: 2.4 GHz |
| 1177 | * @WMI_WIFI_BAND_A: 5 GHz without DFS |
| 1178 | * @WMI_WIFI_BAND_ABG: 2.4 GHz + 5 GHz; no DFS |
| 1179 | * @WMI_WIFI_BAND_A_DFS_ONLY: 5 GHz DFS only |
| 1180 | * @WMI_WIFI_BAND_A_WITH_DFS: 5 GHz with DFS |
| 1181 | * @WMI_WIFI_BAND_ABG_WITH_DFS: 2.4 GHz + 5 GHz with DFS |
| 1182 | * @WMI_WIFI_BAND_MAX: max range |
| 1183 | */ |
| 1184 | enum wmi_wifi_band { |
| 1185 | WMI_WIFI_BAND_UNSPECIFIED, |
| 1186 | WMI_WIFI_BAND_BG = 1, |
| 1187 | WMI_WIFI_BAND_A = 2, |
| 1188 | WMI_WIFI_BAND_ABG = 3, |
| 1189 | WMI_WIFI_BAND_A_DFS_ONLY = 4, |
| 1190 | /* 5 is reserved */ |
| 1191 | WMI_WIFI_BAND_A_WITH_DFS = 6, |
| 1192 | WMI_WIFI_BAND_ABG_WITH_DFS = 7, |
| 1193 | /* Keep it last */ |
| 1194 | WMI_WIFI_BAND_MAX |
| 1195 | }; |
| 1196 | |
| 1197 | /** |
| 1198 | * struct wifi_scan_bucket_params - wifi scan bucket spec |
| 1199 | * @bucket: bucket identifier |
| 1200 | * @band: wifi band |
| 1201 | * @period: Desired period, in millisecond; if this is too |
| 1202 | * low, the firmware should choose to generate results as fast as |
| 1203 | * it can instead of failing the command byte |
| 1204 | * for exponential backoff bucket this is the min_period |
| 1205 | * @reportEvents: 0 => normal reporting (reporting rssi history |
| 1206 | * only, when rssi history buffer is % full) |
| 1207 | * 1 => same as 0 + report a scan completion event after scanning |
| 1208 | * this bucket |
| 1209 | * 2 => same as 1 + forward scan results |
| 1210 | * (beacons/probe responses + IEs) in real time to HAL |
| 1211 | * @max_period: if max_period is non zero or different than period, |
| 1212 | * then this bucket is an exponential backoff bucket and |
| 1213 | * the scan period will grow exponentially as per formula: |
| 1214 | * actual_period(N) = period ^ (N/(step_count+1)) to a |
| 1215 | * maximum period of max_period |
| 1216 | * @exponent: for exponential back off bucket: multiplier: |
| 1217 | * new_period = old_period * exponent |
| 1218 | * @step_count: for exponential back off bucket, number of scans performed |
| 1219 | * at a given period and until the exponent is applied |
| 1220 | * @numChannels: channels to scan; these may include DFS channels |
| 1221 | * Note that a given channel may appear in multiple buckets |
| 1222 | * @min_dwell_time_active: per bucket minimum active dwell time |
| 1223 | * @max_dwell_time_active: per bucket maximum active dwell time |
| 1224 | * @min_dwell_time_passive: per bucket minimum passive dwell time |
| 1225 | * @max_dwell_time_passive: per bucket maximum passive dwell time |
| 1226 | * @channels: Channel list |
| 1227 | */ |
| 1228 | struct wifi_scan_bucket_params { |
| 1229 | uint8_t bucket; |
| 1230 | enum wmi_wifi_band band; |
| 1231 | uint32_t period; |
| 1232 | uint32_t reportEvents; |
| 1233 | uint32_t max_period; |
| 1234 | uint32_t exponent; |
| 1235 | uint32_t step_count; |
| 1236 | uint32_t numChannels; |
| 1237 | uint32_t min_dwell_time_active; |
| 1238 | uint32_t max_dwell_time_active; |
| 1239 | uint32_t min_dwell_time_passive; |
| 1240 | uint32_t max_dwell_time_passive; |
| 1241 | struct wifi_scan_channelspec_params channels[WMI_WLAN_EXTSCAN_MAX_CHANNELS]; |
| 1242 | }; |
| 1243 | |
| 1244 | /** |
| 1245 | * struct wifi_scan_cmd_req_params - wifi scan command request params |
| 1246 | * @basePeriod: base timer period |
| 1247 | * @maxAPperScan: max ap per scan |
| 1248 | * @report_threshold_percent: report threshold |
| 1249 | * in %, when buffer is this much full, wake up host |
| 1250 | * @report_threshold_num_scans: report threshold number of scans |
| 1251 | * in number of scans, wake up host after these many scans |
| 1252 | * @requestId: request id |
| 1253 | * @sessionId: session id |
| 1254 | * @numBuckets: number of buckets |
| 1255 | * @min_dwell_time_active: per bucket minimum active dwell time |
| 1256 | * @max_dwell_time_active: per bucket maximum active dwell time |
| 1257 | * @min_dwell_time_passive: per bucket minimum passive dwell time |
| 1258 | * @max_dwell_time_passive: per bucket maximum passive dwell time |
| 1259 | * @configuration_flags: configuration flags |
| 1260 | * @buckets: buckets array |
| 1261 | */ |
| 1262 | struct wifi_scan_cmd_req_params { |
| 1263 | uint32_t basePeriod; |
| 1264 | uint32_t maxAPperScan; |
| 1265 | |
| 1266 | uint32_t report_threshold_percent; |
| 1267 | uint32_t report_threshold_num_scans; |
| 1268 | |
| 1269 | uint32_t requestId; |
| 1270 | uint8_t sessionId; |
| 1271 | uint32_t numBuckets; |
| 1272 | |
| 1273 | uint32_t min_dwell_time_active; |
| 1274 | uint32_t max_dwell_time_active; |
| 1275 | uint32_t min_dwell_time_passive; |
| 1276 | uint32_t max_dwell_time_passive; |
| 1277 | uint32_t configuration_flags; |
| 1278 | struct wifi_scan_bucket_params buckets[WMI_WLAN_EXTSCAN_MAX_BUCKETS]; |
| 1279 | }; |
| 1280 | |
| 1281 | #if defined(FEATURE_WLAN_ESE) && defined(FEATURE_WLAN_ESE_UPLOAD) |
| 1282 | #define WMI_CFG_VALID_CHANNEL_LIST_LEN 100 |
| 1283 | |
| 1284 | /** |
| 1285 | * struct plm_req_params - plm req parameter |
| 1286 | * @diag_token: Dialog token |
| 1287 | * @meas_token: measurement token |
| 1288 | * @num_bursts: total number of bursts |
| 1289 | * @burst_int: burst interval in seconds |
| 1290 | * @meas_duration:in TU's,STA goes off-ch |
| 1291 | * @burst_len: no of times the STA should cycle through PLM ch list |
| 1292 | * @desired_tx_pwr: desired tx power |
| 1293 | * @mac_addr: MC dest addr |
| 1294 | * @plm_num_ch: channel numbers |
| 1295 | * @plm_ch_list: channel list |
| 1296 | * @session_id: session id |
| 1297 | * @enable: enable/disable |
| 1298 | */ |
| 1299 | struct plm_req_params { |
| 1300 | uint16_t diag_token; |
| 1301 | uint16_t meas_token; |
| 1302 | uint16_t num_bursts; |
| 1303 | uint16_t burst_int; |
| 1304 | uint16_t meas_duration; |
| 1305 | /* no of times the STA should cycle through PLM ch list */ |
| 1306 | uint8_t burst_len; |
| 1307 | int8_t desired_tx_pwr; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1308 | struct qdf_mac_addr mac_addr; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1309 | /* no of channels */ |
| 1310 | uint8_t plm_num_ch; |
| 1311 | /* channel numbers */ |
| 1312 | uint8_t plm_ch_list[WMI_CFG_VALID_CHANNEL_LIST_LEN]; |
| 1313 | uint8_t session_id; |
| 1314 | bool enable; |
| 1315 | }; |
| 1316 | #endif |
| 1317 | |
| 1318 | |
| 1319 | /** |
| 1320 | * struct mac_ts_info_tfc - mac ts info parameters |
| 1321 | * @burstSizeDefn: burst size |
| 1322 | * @reserved: reserved |
| 1323 | * @ackPolicy: ack policy |
| 1324 | * @psb: psb |
| 1325 | * @aggregation: aggregation |
| 1326 | * @accessPolicy: access policy |
| 1327 | * @direction: direction |
| 1328 | * @tsid: direction |
| 1329 | * @trafficType: traffic type |
| 1330 | */ |
| 1331 | struct mac_ts_info_tfc { |
| 1332 | #ifndef ANI_LITTLE_BIT_ENDIAN |
| 1333 | uint8_t burstSizeDefn:1; |
| 1334 | uint8_t reserved:7; |
| 1335 | #else |
| 1336 | uint8_t reserved:7; |
| 1337 | uint8_t burstSizeDefn:1; |
| 1338 | #endif |
| 1339 | |
| 1340 | #ifndef ANI_LITTLE_BIT_ENDIAN |
| 1341 | uint16_t ackPolicy:2; |
| 1342 | uint16_t userPrio:3; |
| 1343 | uint16_t psb:1; |
| 1344 | uint16_t aggregation:1; |
| 1345 | uint16_t accessPolicy:2; |
| 1346 | uint16_t direction:2; |
| 1347 | uint16_t tsid:4; |
| 1348 | uint16_t trafficType:1; |
| 1349 | #else |
| 1350 | uint16_t trafficType:1; |
| 1351 | uint16_t tsid:4; |
| 1352 | uint16_t direction:2; |
| 1353 | uint16_t accessPolicy:2; |
| 1354 | uint16_t aggregation:1; |
| 1355 | uint16_t psb:1; |
| 1356 | uint16_t userPrio:3; |
| 1357 | uint16_t ackPolicy:2; |
| 1358 | #endif |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1359 | } qdf_packed; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1360 | |
| 1361 | /** |
| 1362 | * struct mac_ts_info_sch - mac ts info schedule parameters |
| 1363 | * @rsvd: reserved |
| 1364 | * @schedule: schedule bit |
| 1365 | */ |
| 1366 | struct mac_ts_info_sch { |
| 1367 | #ifndef ANI_LITTLE_BIT_ENDIAN |
| 1368 | uint8_t rsvd:7; |
| 1369 | uint8_t schedule:1; |
| 1370 | #else |
| 1371 | uint8_t schedule:1; |
| 1372 | uint8_t rsvd:7; |
| 1373 | #endif |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1374 | } qdf_packed; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1375 | |
| 1376 | /** |
| 1377 | * struct mac_ts_info_sch - mac ts info schedule parameters |
| 1378 | * @traffic: mac tfc parameter |
| 1379 | * @schedule: mac schedule parameters |
| 1380 | */ |
| 1381 | struct mac_ts_info { |
| 1382 | struct mac_ts_info_tfc traffic; |
| 1383 | struct mac_ts_info_sch schedule; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1384 | } qdf_packed; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1385 | |
| 1386 | /** |
| 1387 | * struct mac_tspec_ie - mac ts spec |
| 1388 | * @type: type |
| 1389 | * @length: length |
| 1390 | * @tsinfo: tsinfo |
| 1391 | * @nomMsduSz: nomMsduSz |
| 1392 | * @maxMsduSz: maxMsduSz |
| 1393 | * @minSvcInterval: minSvcInterval |
| 1394 | * @maxSvcInterval: maxSvcInterval |
| 1395 | * @inactInterval: inactInterval |
| 1396 | * @suspendInterval: suspendInterval |
| 1397 | * @svcStartTime: svcStartTime |
| 1398 | * @minDataRate: minDataRate |
| 1399 | * @meanDataRate: meanDataRate |
| 1400 | * @peakDataRate: peakDataRate |
| 1401 | * @maxBurstSz: maxBurstSz |
| 1402 | * @delayBound: delayBound |
| 1403 | * @minPhyRate: minPhyRate |
| 1404 | * @surplusBw: surplusBw |
| 1405 | * @mediumTime: mediumTime |
| 1406 | */ |
| 1407 | struct mac_tspec_ie { |
| 1408 | uint8_t type; |
| 1409 | uint8_t length; |
| 1410 | struct mac_ts_info tsinfo; |
| 1411 | uint16_t nomMsduSz; |
| 1412 | uint16_t maxMsduSz; |
| 1413 | uint32_t minSvcInterval; |
| 1414 | uint32_t maxSvcInterval; |
| 1415 | uint32_t inactInterval; |
| 1416 | uint32_t suspendInterval; |
| 1417 | uint32_t svcStartTime; |
| 1418 | uint32_t minDataRate; |
| 1419 | uint32_t meanDataRate; |
| 1420 | uint32_t peakDataRate; |
| 1421 | uint32_t maxBurstSz; |
| 1422 | uint32_t delayBound; |
| 1423 | uint32_t minPhyRate; |
| 1424 | uint16_t surplusBw; |
| 1425 | uint16_t mediumTime; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1426 | } qdf_packed; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1427 | |
| 1428 | /** |
| 1429 | * struct add_ts_param - ADDTS related parameters |
| 1430 | * @staIdx: station index |
| 1431 | * @tspecIdx: TSPEC handler uniquely identifying a TSPEC for a STA in a BSS |
| 1432 | * @tspec: tspec value |
| 1433 | * @status: CDF status |
| 1434 | * @sessionId: session id |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1435 | * @tsm_interval: TSM interval period passed from UMAC to WMI |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1436 | * @setRICparams: RIC parameters |
| 1437 | * @sme_session_id: sme session id |
| 1438 | */ |
| 1439 | struct add_ts_param { |
| 1440 | uint16_t staIdx; |
| 1441 | uint16_t tspecIdx; |
| 1442 | struct mac_tspec_ie tspec; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1443 | QDF_STATUS status; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1444 | uint8_t sessionId; |
| 1445 | #ifdef FEATURE_WLAN_ESE |
| 1446 | uint16_t tsm_interval; |
| 1447 | #endif /* FEATURE_WLAN_ESE */ |
| 1448 | #ifdef WLAN_FEATURE_ROAM_OFFLOAD |
| 1449 | uint8_t setRICparams; |
| 1450 | #endif /* WLAN_FEATURE_ROAM_OFFLOAD */ |
| 1451 | uint8_t sme_session_id; |
| 1452 | }; |
| 1453 | |
| 1454 | /** |
| 1455 | * struct delts_req_info - DELTS request parameter |
| 1456 | * @tsinfo: ts info |
| 1457 | * @tspec: ts spec |
| 1458 | * @wmeTspecPresent: wme ts spec flag |
| 1459 | * @wsmTspecPresent: wsm ts spec flag |
| 1460 | * @lleTspecPresent: lle ts spec flag |
| 1461 | */ |
| 1462 | struct delts_req_info { |
| 1463 | struct mac_ts_info tsinfo; |
| 1464 | struct mac_tspec_ie tspec; |
| 1465 | uint8_t wmeTspecPresent:1; |
| 1466 | uint8_t wsmTspecPresent:1; |
| 1467 | uint8_t lleTspecPresent:1; |
| 1468 | }; |
| 1469 | |
| 1470 | /** |
| 1471 | * struct del_ts_params - DELTS related parameters |
| 1472 | * @staIdx: station index |
| 1473 | * @tspecIdx: TSPEC identifier uniquely identifying a TSPEC for a STA in a BSS |
| 1474 | * @bssId: BSSID |
| 1475 | * @sessionId: session id |
| 1476 | * @userPrio: user priority |
| 1477 | * @delTsInfo: DELTS info |
| 1478 | * @setRICparams: RIC parameters |
| 1479 | */ |
| 1480 | struct del_ts_params { |
| 1481 | uint16_t staIdx; |
| 1482 | uint16_t tspecIdx; |
| 1483 | uint8_t bssId[WMI_ETH_LEN]; |
| 1484 | uint8_t sessionId; |
| 1485 | uint8_t userPrio; |
| 1486 | #ifdef WLAN_FEATURE_ROAM_OFFLOAD |
| 1487 | struct delts_req_info delTsInfo; |
| 1488 | uint8_t setRICparams; |
| 1489 | #endif /* WLAN_FEATURE_ROAM_OFFLOAD */ |
| 1490 | }; |
| 1491 | |
| 1492 | /** |
| 1493 | * struct ll_stats_clear_params - ll stats clear parameter |
| 1494 | * @req_id: request id |
| 1495 | * @sta_id: sta id |
| 1496 | * @stats_clear_mask: stats clear mask |
| 1497 | * @stop_req: stop request |
| 1498 | */ |
| 1499 | struct ll_stats_clear_params { |
| 1500 | uint32_t req_id; |
| 1501 | uint8_t sta_id; |
| 1502 | uint32_t stats_clear_mask; |
| 1503 | uint8_t stop_req; |
| 1504 | }; |
| 1505 | |
| 1506 | /** |
| 1507 | * struct ll_stats_set_params - ll stats get parameter |
| 1508 | * @req_id: request id |
| 1509 | * @sta_id: sta id |
| 1510 | * @mpdu_size_threshold: mpdu sixe threshold |
| 1511 | * @aggressive_statistics_gathering: aggressive_statistics_gathering |
| 1512 | */ |
| 1513 | struct ll_stats_set_params { |
| 1514 | uint32_t req_id; |
| 1515 | uint8_t sta_id; |
| 1516 | uint32_t mpdu_size_threshold; |
| 1517 | uint32_t aggressive_statistics_gathering; |
| 1518 | }; |
| 1519 | |
| 1520 | /** |
| 1521 | * struct ll_stats_get_params - ll stats parameter |
| 1522 | * @req_id: request id |
| 1523 | * @sta_id: sta id |
| 1524 | * @param_id_mask: param is mask |
| 1525 | */ |
| 1526 | struct ll_stats_get_params { |
| 1527 | uint32_t req_id; |
| 1528 | uint8_t sta_id; |
| 1529 | uint32_t param_id_mask; |
| 1530 | }; |
| 1531 | |
| 1532 | /** |
| 1533 | * struct pe_stats_req - pe stats parameter |
| 1534 | * @msg_type: message type is same as the request type |
| 1535 | * @msg_len: length of the entire request |
| 1536 | * @sta_id: Per STA stats request must contain valid |
| 1537 | * @stats_mask: categories of stats requested |
| 1538 | * @session_id: wsm ts spec flag |
| 1539 | */ |
| 1540 | struct pe_stats_req { |
| 1541 | /* Common for all types are requests */ |
| 1542 | uint16_t msg_type; |
| 1543 | uint16_t msg_len; |
| 1544 | uint32_t sta_id; |
| 1545 | /* categories of stats requested. look at ePEStatsMask */ |
| 1546 | uint32_t stats_mask; |
| 1547 | uint8_t session_id; |
| 1548 | }; |
| 1549 | |
| 1550 | /** |
| 1551 | * struct link_status_params - link stats parameter |
| 1552 | * @msg_type: message type is same as the request type |
| 1553 | * @msg_len: length of the entire request |
| 1554 | * @link_status: wme ts spec flag |
| 1555 | * @session_id: wsm ts spec flag |
| 1556 | */ |
| 1557 | struct link_status_params { |
| 1558 | uint16_t msg_type; |
| 1559 | uint16_t msg_len; |
| 1560 | uint8_t link_status; |
| 1561 | uint8_t session_id; |
| 1562 | }; |
| 1563 | |
| 1564 | /** |
| 1565 | * struct dhcp_stop_ind_params - DHCP Stop indication message |
| 1566 | * @msgtype: message type is same as the request type |
| 1567 | * @msglen: length of the entire request |
| 1568 | * @device_mode: Mode of the device(ex:STA, AP) |
| 1569 | * @adapter_macaddr: MAC address of the adapter |
| 1570 | * @peer_macaddr: MAC address of the connected peer |
| 1571 | */ |
| 1572 | struct dhcp_stop_ind_params { |
| 1573 | uint16_t msgtype; |
| 1574 | uint16_t msglen; |
| 1575 | uint8_t device_mode; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1576 | struct qdf_mac_addr adapter_macaddr; |
| 1577 | struct qdf_mac_addr peer_macaddr; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1578 | }; |
| 1579 | |
| 1580 | /** |
| 1581 | * struct aggr_add_ts_param - ADDTS parameters |
| 1582 | * @staIdx: station index |
| 1583 | * @tspecIdx: TSPEC handler uniquely identifying a TSPEC for a STA in a BSS |
| 1584 | * @tspec: tspec value |
| 1585 | * @status: CDF status |
| 1586 | * @sessionId: session id |
| 1587 | */ |
| 1588 | struct aggr_add_ts_param { |
| 1589 | uint16_t staIdx; |
| 1590 | uint16_t tspecIdx; |
| 1591 | struct mac_tspec_ie tspec[WMI_QOS_NUM_AC_MAX]; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1592 | QDF_STATUS status[WMI_QOS_NUM_AC_MAX]; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1593 | uint8_t sessionId; |
| 1594 | }; |
| 1595 | |
| 1596 | #define WMI_MAX_FILTER_TEST_DATA_LEN 8 |
| 1597 | #define WMI_MAX_NUM_MULTICAST_ADDRESS 240 |
| 1598 | #define WMI_MAX_NUM_FILTERS 20 |
| 1599 | #define WMI_MAX_NUM_TESTS_PER_FILTER 10 |
| 1600 | |
| 1601 | /** |
| 1602 | * enum packet_filter_type - packet filter type |
| 1603 | * @WMI_RCV_FILTER_TYPE_INVALID: invalid type |
| 1604 | * @WMI_RCV_FILTER_TYPE_FILTER_PKT: filter packet type |
| 1605 | * @WMI_RCV_FILTER_TYPE_BUFFER_PKT: buffer packet type |
| 1606 | * @WMI_RCV_FILTER_TYPE_MAX_ENUM_SIZE: max enum size |
| 1607 | */ |
| 1608 | enum packet_filter_type { |
| 1609 | WMI_RCV_FILTER_TYPE_INVALID, |
| 1610 | WMI_RCV_FILTER_TYPE_FILTER_PKT, |
| 1611 | WMI_RCV_FILTER_TYPE_BUFFER_PKT, |
| 1612 | WMI_RCV_FILTER_TYPE_MAX_ENUM_SIZE |
| 1613 | }; |
| 1614 | |
| 1615 | /** |
| 1616 | * enum packet_protocol_type - packet protocol type |
| 1617 | * @WMI_FILTER_HDR_TYPE_INVALID: invalid type |
| 1618 | * @WMI_FILTER_HDR_TYPE_MAC: mac type |
| 1619 | * @WMI_FILTER_HDR_TYPE_ARP: trp type |
| 1620 | * @WMI_FILTER_HDR_TYPE_IPV4: ipv4 type |
| 1621 | * @WMI_FILTER_HDR_TYPE_IPV6: ipv6 type |
| 1622 | * @WMI_FILTER_HDR_TYPE_UDP: udp type |
| 1623 | * @WMI_FILTER_HDR_TYPE_MAX: max type |
| 1624 | */ |
| 1625 | enum packet_protocol_type { |
| 1626 | WMI_FILTER_HDR_TYPE_INVALID, |
| 1627 | WMI_FILTER_HDR_TYPE_MAC, |
| 1628 | WMI_FILTER_HDR_TYPE_ARP, |
| 1629 | WMI_FILTER_HDR_TYPE_IPV4, |
| 1630 | WMI_FILTER_HDR_TYPE_IPV6, |
| 1631 | WMI_FILTER_HDR_TYPE_UDP, |
| 1632 | WMI_FILTER_HDR_TYPE_MAX |
| 1633 | }; |
| 1634 | |
| 1635 | /** |
| 1636 | * enum packet_filter_comp_type - packet filter comparison type |
| 1637 | * @WMI_FILTER_CMP_TYPE_INVALID: invalid type |
| 1638 | * @WMI_FILTER_CMP_TYPE_EQUAL: type equal |
| 1639 | * @WMI_FILTER_CMP_TYPE_MASK_EQUAL: mask equal |
| 1640 | * @WMI_FILTER_CMP_TYPE_NOT_EQUAL: type not equal |
| 1641 | * @WMI_FILTER_CMP_TYPE_MASK_NOT_EQUAL: mask not equal |
| 1642 | * @WMI_FILTER_CMP_TYPE_MAX: max type |
| 1643 | */ |
| 1644 | enum packet_filter_comp_type { |
| 1645 | WMI_FILTER_CMP_TYPE_INVALID, |
| 1646 | WMI_FILTER_CMP_TYPE_EQUAL, |
| 1647 | WMI_FILTER_CMP_TYPE_MASK_EQUAL, |
| 1648 | WMI_FILTER_CMP_TYPE_NOT_EQUAL, |
| 1649 | WMI_FILTER_CMP_TYPE_MASK_NOT_EQUAL, |
| 1650 | WMI_FILTER_CMP_TYPE_MAX |
| 1651 | }; |
| 1652 | |
| 1653 | /** |
| 1654 | * struct rcv_pkt_filter_params - recieve packet filter parameters |
| 1655 | * @protocolLayer - protocol layer |
| 1656 | * @cmpFlag - comparison flag |
| 1657 | * @dataLength - data length |
| 1658 | * @dataOffset - data offset |
| 1659 | * @reserved - resserved |
| 1660 | * @compareData - compare data |
| 1661 | * @dataMask - data mask |
| 1662 | */ |
| 1663 | struct rcv_pkt_filter_params { |
| 1664 | enum packet_protocol_type protocolLayer; |
| 1665 | enum packet_filter_comp_type cmpFlag; |
| 1666 | uint16_t dataLength; |
| 1667 | uint8_t dataOffset; |
| 1668 | uint8_t reserved; |
| 1669 | uint8_t compareData[WMI_MAX_FILTER_TEST_DATA_LEN]; |
| 1670 | uint8_t dataMask[WMI_MAX_FILTER_TEST_DATA_LEN]; |
| 1671 | }; |
| 1672 | |
| 1673 | /** |
| 1674 | * struct rcv_pkt_filter_config - recieve packet filter info |
| 1675 | * @filterId - filter id |
| 1676 | * @filterType - filter type |
| 1677 | * @numFieldParams - no of fields |
| 1678 | * @coalesceTime - reserved parameter |
| 1679 | * @self_macaddr - self mac address |
| 1680 | * @bssid - Bssid of the connected AP |
| 1681 | * @paramsData - data parameter |
| 1682 | */ |
| 1683 | struct rcv_pkt_filter_config { |
| 1684 | uint8_t filterId; |
| 1685 | enum packet_filter_type filterType; |
| 1686 | uint32_t numFieldParams; |
| 1687 | uint32_t coalesceTime; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1688 | struct qdf_mac_addr self_macaddr; |
| 1689 | struct qdf_mac_addr bssid; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1690 | struct rcv_pkt_filter_params paramsData[WMI_MAX_NUM_TESTS_PER_FILTER]; |
| 1691 | }; |
| 1692 | |
| 1693 | /** |
| 1694 | * struct vdev_ie_info_param - IE info |
| 1695 | * @vdev_id - vdev for which the IE is being sent |
| 1696 | * @ie_id - ID of the IE |
| 1697 | * @length - length of the IE data |
| 1698 | * @data - IE data |
| 1699 | * |
| 1700 | * This structure is used to store the IE information. |
| 1701 | */ |
| 1702 | struct vdev_ie_info_param { |
| 1703 | uint32_t vdev_id; |
| 1704 | uint32_t ie_id; |
| 1705 | uint32_t length; |
| 1706 | uint8_t *data; |
| 1707 | }; |
| 1708 | |
| 1709 | #define WMI_MAX_NUM_FW_SEGMENTS 4 |
| 1710 | |
| 1711 | /** |
| 1712 | * struct fw_dump_seg_req_param - individual segment details |
| 1713 | * @seg_id - segment id. |
| 1714 | * @seg_start_addr_lo - lower address of the segment. |
| 1715 | * @seg_start_addr_hi - higher address of the segment. |
| 1716 | * @seg_length - length of the segment. |
| 1717 | * @dst_addr_lo - lower address of the destination buffer. |
| 1718 | * @dst_addr_hi - higher address of the destination buffer. |
| 1719 | * |
| 1720 | * This structure carries the information to firmware about the |
| 1721 | * individual segments. This structure is part of firmware memory |
| 1722 | * dump request. |
| 1723 | */ |
| 1724 | struct fw_dump_seg_req_param { |
| 1725 | uint8_t seg_id; |
| 1726 | uint32_t seg_start_addr_lo; |
| 1727 | uint32_t seg_start_addr_hi; |
| 1728 | uint32_t seg_length; |
| 1729 | uint32_t dst_addr_lo; |
| 1730 | uint32_t dst_addr_hi; |
| 1731 | }; |
| 1732 | |
| 1733 | /** |
| 1734 | * struct fw_dump_req_param - firmware memory dump request details. |
| 1735 | * @request_id - request id. |
| 1736 | * @num_seg - requested number of segments. |
| 1737 | * @fw_dump_seg_req - individual segment information. |
| 1738 | * |
| 1739 | * This structure carries information about the firmware |
| 1740 | * memory dump request. |
| 1741 | */ |
| 1742 | struct fw_dump_req_param { |
| 1743 | uint32_t request_id; |
| 1744 | uint32_t num_seg; |
| 1745 | struct fw_dump_seg_req_param segment[WMI_MAX_NUM_FW_SEGMENTS]; |
| 1746 | }; |
| 1747 | |
| 1748 | #define WMI_TDLS_MAX_SUPP_CHANNELS 128 |
| 1749 | #define WMI_TDLS_MAX_SUPP_OPER_CLASSES 32 |
| 1750 | #define WMI_2_4_GHZ_MAX_FREQ 3000 |
| 1751 | |
| 1752 | /** |
| 1753 | * struct tdls_update_ch_params - channel parameters |
| 1754 | * @chanId: ID of the channel |
| 1755 | * @pwr: power level |
| 1756 | * @dfsSet: is dfs supported or not |
| 1757 | * @half_rate: is the channel operating at 10MHz |
| 1758 | * @quarter_rate: is the channel operating at 5MHz |
| 1759 | */ |
| 1760 | struct tdls_update_ch_params { |
| 1761 | uint8_t chanId; |
| 1762 | uint8_t pwr; |
| 1763 | bool dfsSet; |
| 1764 | bool half_rate; |
| 1765 | bool quarter_rate; |
| 1766 | }; |
| 1767 | |
| 1768 | /** |
| 1769 | * struct tdls_peer_cap_params - TDLS peer capablities parameters |
| 1770 | * @isPeerResponder: is peer responder or not |
| 1771 | * @peerUapsdQueue: peer uapsd queue |
| 1772 | * @peerMaxSp: peer max SP value |
| 1773 | * @peerBuffStaSupport: peer buffer sta supported or not |
| 1774 | * @peerOffChanSupport: peer offchannel support |
| 1775 | * @peerCurrOperClass: peer current operating class |
| 1776 | * @selfCurrOperClass: self current operating class |
| 1777 | * @peerChanLen: peer channel length |
| 1778 | * @peerChan: peer channel list |
| 1779 | * @peerOperClassLen: peer operating class length |
| 1780 | * @peerOperClass: peer operating class |
| 1781 | * @prefOffChanNum: peer offchannel number |
| 1782 | * @prefOffChanBandwidth: peer offchannel bandwidth |
| 1783 | * @opClassForPrefOffChan: operating class for offchannel |
| 1784 | */ |
| 1785 | struct tdls_peer_cap_params { |
| 1786 | uint8_t isPeerResponder; |
| 1787 | uint8_t peerUapsdQueue; |
| 1788 | uint8_t peerMaxSp; |
| 1789 | uint8_t peerBuffStaSupport; |
| 1790 | uint8_t peerOffChanSupport; |
| 1791 | uint8_t peerCurrOperClass; |
| 1792 | uint8_t selfCurrOperClass; |
| 1793 | uint8_t peerChanLen; |
| 1794 | struct tdls_update_ch_params peerChan[WMI_TDLS_MAX_SUPP_CHANNELS]; |
| 1795 | uint8_t peerOperClassLen; |
| 1796 | uint8_t peerOperClass[WMI_TDLS_MAX_SUPP_OPER_CLASSES]; |
| 1797 | uint8_t prefOffChanNum; |
| 1798 | uint8_t prefOffChanBandwidth; |
| 1799 | uint8_t opClassForPrefOffChan; |
| 1800 | }; |
| 1801 | |
| 1802 | /** |
| 1803 | * struct tdls_peer_state_params - TDLS peer state parameters |
| 1804 | * @vdevId: vdev id |
| 1805 | * @peerMacAddr: peer mac address |
| 1806 | * @peerCap: peer capabality |
| 1807 | */ |
| 1808 | struct tdls_peer_state_params { |
| 1809 | uint32_t vdevId; |
| 1810 | uint8_t peerMacAddr[WMI_ETH_LEN]; |
| 1811 | uint32_t peerState; |
| 1812 | struct tdls_peer_cap_params peerCap; |
| 1813 | }; |
| 1814 | |
| 1815 | /** |
| 1816 | * struct wmi_tdls_params - TDLS parameters |
| 1817 | * @vdev_id: vdev id |
| 1818 | * @tdls_state: TDLS state |
| 1819 | * @notification_interval_ms: notification inerval |
| 1820 | * @tx_discovery_threshold: tx discovery threshold |
| 1821 | * @tx_teardown_threshold: tx teardown threashold |
| 1822 | * @rssi_teardown_threshold: RSSI teardown threshold |
| 1823 | * @rssi_delta: RSSI delta |
| 1824 | * @tdls_options: TDLS options |
| 1825 | * @peer_traffic_ind_window: raffic indication window |
| 1826 | * @peer_traffic_response_timeout: traffic response timeout |
| 1827 | * @puapsd_mask: uapsd mask |
| 1828 | * @puapsd_inactivity_time: uapsd inactivity time |
| 1829 | * @puapsd_rx_frame_threshold: uapsd rx frame threshold |
| 1830 | * @teardown_notification_ms: tdls teardown notification interval |
| 1831 | * @tdls_peer_kickout_threshold: tdls packet threshold for |
| 1832 | * peer kickout operation |
| 1833 | */ |
| 1834 | struct wmi_tdls_params { |
| 1835 | uint32_t vdev_id; |
| 1836 | uint32_t tdls_state; |
| 1837 | uint32_t notification_interval_ms; |
| 1838 | uint32_t tx_discovery_threshold; |
| 1839 | uint32_t tx_teardown_threshold; |
| 1840 | int32_t rssi_teardown_threshold; |
| 1841 | int32_t rssi_delta; |
| 1842 | uint32_t tdls_options; |
| 1843 | uint32_t peer_traffic_ind_window; |
| 1844 | uint32_t peer_traffic_response_timeout; |
| 1845 | uint32_t puapsd_mask; |
| 1846 | uint32_t puapsd_inactivity_time; |
| 1847 | uint32_t puapsd_rx_frame_threshold; |
| 1848 | uint32_t teardown_notification_ms; |
| 1849 | uint32_t tdls_peer_kickout_threshold; |
| 1850 | }; |
| 1851 | |
| 1852 | /** |
| 1853 | * struct tdls_chan_switch_params - channel switch parameter structure |
| 1854 | * @vdev_id: vdev ID |
| 1855 | * @peer_mac_addr: Peer mac address |
| 1856 | * @tdls_off_ch_bw_offset: Target off-channel bandwitdh offset |
| 1857 | * @tdls_off_ch: Target Off Channel |
| 1858 | * @oper_class: Operating class for target channel |
| 1859 | * @is_responder: Responder or initiator |
| 1860 | */ |
| 1861 | struct tdls_channel_switch_params { |
| 1862 | uint32_t vdev_id; |
| 1863 | uint8_t peer_mac_addr[WMI_ETH_LEN]; |
| 1864 | uint16_t tdls_off_ch_bw_offset; |
| 1865 | uint8_t tdls_off_ch; |
| 1866 | uint8_t tdls_sw_mode; |
| 1867 | uint8_t oper_class; |
| 1868 | uint8_t is_responder; |
| 1869 | }; |
| 1870 | |
| 1871 | /** |
| 1872 | * struct dhcp_offload_info_params - dhcp offload parameters |
| 1873 | * @vdev_id: request data length |
| 1874 | * @dhcpSrvOffloadEnabled: dhcp offload enabled |
| 1875 | * @dhcpClientNum: dhcp client no |
| 1876 | * @dhcpSrvIP: dhcp server ip |
| 1877 | */ |
| 1878 | struct dhcp_offload_info_params { |
| 1879 | uint32_t vdev_id; |
| 1880 | uint32_t dhcpSrvOffloadEnabled; |
| 1881 | uint32_t dhcpClientNum; |
| 1882 | uint32_t dhcpSrvIP; |
| 1883 | }; |
| 1884 | |
| 1885 | /** |
| 1886 | * struct nan_req_params - NAN request params |
| 1887 | * @request_data_len: request data length |
| 1888 | * @request_data: request data |
| 1889 | */ |
| 1890 | struct nan_req_params { |
| 1891 | uint16_t request_data_len; |
| 1892 | uint8_t request_data[]; |
| 1893 | }; |
| 1894 | |
| 1895 | |
| 1896 | /** |
| 1897 | * struct app_type2_params - app type2parameter |
| 1898 | * @vdev_id: vdev id |
| 1899 | * @rc4_key: rc4 key |
| 1900 | * @rc4_key_len: rc4 key length |
| 1901 | * @ip_id: NC id |
| 1902 | * @ip_device_ip: NC IP addres |
| 1903 | * @ip_server_ip: Push server IP address |
| 1904 | * @tcp_src_port: NC TCP port |
| 1905 | * @tcp_dst_port: Push server TCP port |
| 1906 | * @tcp_seq: tcp sequence |
| 1907 | * @tcp_ack_seq: tcp ack sequence |
| 1908 | * @keepalive_init: Initial ping interval |
| 1909 | * @keepalive_min: Minimum ping interval |
| 1910 | * @keepalive_max: Maximum ping interval |
| 1911 | * @keepalive_inc: Increment of ping interval |
| 1912 | * @gateway_mac: gateway mac address |
| 1913 | * @tcp_tx_timeout_val: tcp tx timeout value |
| 1914 | * @tcp_rx_timeout_val: tcp rx timeout value |
| 1915 | */ |
| 1916 | struct app_type2_params { |
| 1917 | uint8_t vdev_id; |
| 1918 | uint8_t rc4_key[16]; |
| 1919 | uint32_t rc4_key_len; |
| 1920 | /** ip header parameter */ |
| 1921 | uint32_t ip_id; |
| 1922 | uint32_t ip_device_ip; |
| 1923 | uint32_t ip_server_ip; |
| 1924 | /** tcp header parameter */ |
| 1925 | uint16_t tcp_src_port; |
| 1926 | uint16_t tcp_dst_port; |
| 1927 | uint32_t tcp_seq; |
| 1928 | uint32_t tcp_ack_seq; |
| 1929 | uint32_t keepalive_init; |
| 1930 | uint32_t keepalive_min; |
| 1931 | uint32_t keepalive_max; |
| 1932 | uint32_t keepalive_inc; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1933 | struct qdf_mac_addr gateway_mac; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1934 | uint32_t tcp_tx_timeout_val; |
| 1935 | uint32_t tcp_rx_timeout_val; |
| 1936 | }; |
| 1937 | |
| 1938 | /** |
| 1939 | * struct app_type1_params - app type1 parameter |
| 1940 | * @vdev_id: vdev id |
| 1941 | * @wakee_mac_addr: mac address |
| 1942 | * @identification_id: identification id |
| 1943 | * @password: password |
| 1944 | * @id_length: id length |
| 1945 | * @pass_length: password length |
| 1946 | */ |
| 1947 | struct app_type1_params { |
| 1948 | uint8_t vdev_id; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 1949 | struct qdf_mac_addr wakee_mac_addr; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 1950 | uint8_t identification_id[8]; |
| 1951 | uint8_t password[16]; |
| 1952 | uint32_t id_length; |
| 1953 | uint32_t pass_length; |
| 1954 | }; |
| 1955 | |
| 1956 | /** |
| 1957 | * enum wmi_ext_wow_type - wow type |
| 1958 | * @WMI_EXT_WOW_TYPE_APP_TYPE1: only enable wakeup for app type1 |
| 1959 | * @WMI_EXT_WOW_TYPE_APP_TYPE2: only enable wakeup for app type2 |
| 1960 | * @WMI_EXT_WOW_TYPE_APP_TYPE1_2: enable wakeup for app type1&2 |
| 1961 | */ |
| 1962 | enum wmi_ext_wow_type { |
| 1963 | WMI_EXT_WOW_TYPE_APP_TYPE1, |
| 1964 | WMI_EXT_WOW_TYPE_APP_TYPE2, |
| 1965 | WMI_EXT_WOW_TYPE_APP_TYPE1_2, |
| 1966 | }; |
| 1967 | |
| 1968 | /** |
| 1969 | * struct ext_wow_params - ext wow parameters |
| 1970 | * @vdev_id: vdev id |
| 1971 | * @type: wow type |
| 1972 | * @wakeup_pin_num: wake up gpio no |
| 1973 | */ |
| 1974 | struct ext_wow_params { |
| 1975 | uint8_t vdev_id; |
| 1976 | enum wmi_ext_wow_type type; |
| 1977 | uint32_t wakeup_pin_num; |
| 1978 | }; |
| 1979 | |
| 1980 | /** |
| 1981 | * struct stats_ext_params - ext stats request |
| 1982 | * @vdev_id: vdev id |
| 1983 | * @request_data_len: request data length |
| 1984 | * @request_data: request data |
| 1985 | */ |
| 1986 | struct stats_ext_params { |
| 1987 | uint32_t vdev_id; |
| 1988 | uint32_t request_data_len; |
| 1989 | uint8_t request_data[]; |
| 1990 | }; |
| 1991 | |
| 1992 | #define WMI_PERIODIC_TX_PTRN_MAX_SIZE 1536 |
| 1993 | /** |
| 1994 | * struct periodic_tx_pattern - periodic tx pattern |
| 1995 | * @mac_address: MAC Address for the adapter |
| 1996 | * @ucPtrnId: Pattern ID |
| 1997 | * @ucPtrnSize: Pattern size |
| 1998 | * @usPtrnIntervalMs: in ms |
| 1999 | * @ucPattern: Pattern buffer |
| 2000 | */ |
| 2001 | struct periodic_tx_pattern { |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 2002 | struct qdf_mac_addr mac_address; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 2003 | uint8_t ucPtrnId; |
| 2004 | uint16_t ucPtrnSize; |
| 2005 | uint32_t usPtrnIntervalMs; |
| 2006 | uint8_t ucPattern[WMI_PERIODIC_TX_PTRN_MAX_SIZE]; |
| 2007 | }; |
| 2008 | |
| 2009 | #define WMI_GTK_OFFLOAD_KEK_BYTES 16 |
| 2010 | #define WMI_GTK_OFFLOAD_KCK_BYTES 16 |
| 2011 | |
| 2012 | /** |
| 2013 | * struct gtk_offload_params - gtk offload parameters |
| 2014 | * @ulFlags: optional flags |
| 2015 | * @aKCK: Key confirmation key |
| 2016 | * @aKEK: key encryption key |
| 2017 | * @ullKeyReplayCounter: replay counter |
| 2018 | * @bssid: bss id |
| 2019 | */ |
| 2020 | struct gtk_offload_params { |
| 2021 | uint32_t ulFlags; |
| 2022 | uint8_t aKCK[WMI_GTK_OFFLOAD_KCK_BYTES]; |
| 2023 | uint8_t aKEK[WMI_GTK_OFFLOAD_KEK_BYTES]; |
| 2024 | uint64_t ullKeyReplayCounter; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 2025 | struct qdf_mac_addr bssid; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 2026 | }; |
| 2027 | |
| 2028 | /** |
| 2029 | * struct flashing_req_params - led flashing parameter |
| 2030 | * @reqId: request id |
| 2031 | * @pattern_id: pattern identifier. 0: disconnected 1: connected |
| 2032 | * @led_x0: led flashing parameter0 |
| 2033 | * @led_x1: led flashing parameter1 |
| 2034 | */ |
| 2035 | struct flashing_req_params { |
| 2036 | uint32_t req_id; |
| 2037 | uint32_t pattern_id; |
| 2038 | uint32_t led_x0; |
| 2039 | uint32_t led_x1; |
| 2040 | }; |
| 2041 | |
| 2042 | struct wmi_host_mem_chunk { |
| 2043 | uint32_t *vaddr; |
| 2044 | uint32_t paddr; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 2045 | qdf_dma_mem_context(memctx); |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 2046 | uint32_t len; |
| 2047 | uint32_t req_id; |
| 2048 | }; |
| 2049 | |
| 2050 | struct target_resource_config { |
| 2051 | uint32_t num_vdevs; |
| 2052 | uint32_t num_peers; |
| 2053 | uint32_t num_active_peers; |
| 2054 | uint32_t num_offload_peers; |
| 2055 | uint32_t num_offload_reorder_buffs; |
| 2056 | uint32_t num_peer_keys; |
| 2057 | uint32_t num_tids; |
| 2058 | uint32_t ast_skid_limit; |
| 2059 | uint32_t tx_chain_mask; |
| 2060 | uint32_t rx_chain_mask; |
| 2061 | uint32_t rx_timeout_pri[4]; |
| 2062 | uint32_t rx_decap_mode; |
| 2063 | uint32_t scan_max_pending_req; |
| 2064 | uint32_t bmiss_offload_max_vdev; |
| 2065 | uint32_t roam_offload_max_vdev; |
| 2066 | uint32_t roam_offload_max_ap_profiles; |
| 2067 | uint32_t num_mcast_groups; |
| 2068 | uint32_t num_mcast_table_elems; |
| 2069 | uint32_t mcast2ucast_mode; |
| 2070 | uint32_t tx_dbg_log_size; |
| 2071 | uint32_t num_wds_entries; |
| 2072 | uint32_t dma_burst_size; |
| 2073 | uint32_t mac_aggr_delim; |
| 2074 | uint32_t rx_skip_defrag_timeout_dup_detection_check; |
| 2075 | uint32_t vow_config; |
| 2076 | uint32_t gtk_offload_max_vdev; |
| 2077 | uint32_t num_msdu_desc; /* Number of msdu desc */ |
| 2078 | uint32_t max_frag_entries; |
| 2079 | /* End common */ |
| 2080 | |
| 2081 | /* Added in MCL */ |
| 2082 | uint32_t num_tdls_vdevs; |
| 2083 | uint32_t num_tdls_conn_table_entries; |
| 2084 | uint32_t beacon_tx_offload_max_vdev; |
| 2085 | uint32_t num_multicast_filter_entries; |
| 2086 | uint32_t num_wow_filters; |
| 2087 | uint32_t num_keep_alive_pattern; |
| 2088 | uint32_t keep_alive_pattern_size; |
| 2089 | uint32_t max_tdls_concurrent_sleep_sta; |
| 2090 | uint32_t max_tdls_concurrent_buffer_sta; |
| 2091 | uint32_t wmi_send_separate; |
| 2092 | uint32_t num_ocb_vdevs; |
| 2093 | uint32_t num_ocb_channels; |
| 2094 | uint32_t num_ocb_schedules; |
| 2095 | }; |
| 2096 | |
| 2097 | /** |
| 2098 | * struct wmi_wifi_start_log - Structure to store the params sent to start/ |
| 2099 | * stop logging |
| 2100 | * @name: Attribute which indicates the type of logging like per packet |
| 2101 | * statistics, connectivity etc. |
| 2102 | * @verbose_level: Verbose level which can be 0,1,2,3 |
| 2103 | * @flag: Flag field for future use |
| 2104 | */ |
| 2105 | struct wmi_wifi_start_log { |
| 2106 | uint32_t ring_id; |
| 2107 | uint32_t verbose_level; |
| 2108 | uint32_t flag; |
| 2109 | }; |
| 2110 | |
| 2111 | /** |
| 2112 | * struct wmi_pcl_list - Format of PCL |
| 2113 | * @pcl_list: List of preferred channels |
| 2114 | * @pcl_len: Number of channels in the PCL |
| 2115 | */ |
| 2116 | struct wmi_pcl_list { |
| 2117 | uint8_t pcl_list[128]; |
| 2118 | uint32_t pcl_len; |
| 2119 | }; |
| 2120 | |
| 2121 | /** |
| 2122 | * struct wmi_hw_mode_params - HW mode params |
| 2123 | * @mac0_tx_ss: MAC0 Tx spatial stream |
| 2124 | * @mac0_rx_ss: MAC0 Rx spatial stream |
| 2125 | * @mac1_tx_ss: MAC1 Tx spatial stream |
| 2126 | * @mac1_rx_ss: MAC1 Rx spatial stream |
| 2127 | * @mac0_bw: MAC0 bandwidth |
| 2128 | * @mac1_bw: MAC1 bandwidth |
| 2129 | * @dbs_cap: DBS capabality |
| 2130 | * @agile_dfs_cap: Agile DFS capabality |
| 2131 | */ |
| 2132 | struct wmi_hw_mode_params { |
| 2133 | uint8_t mac0_tx_ss; |
| 2134 | uint8_t mac0_rx_ss; |
| 2135 | uint8_t mac1_tx_ss; |
| 2136 | uint8_t mac1_rx_ss; |
| 2137 | uint8_t mac0_bw; |
| 2138 | uint8_t mac1_bw; |
| 2139 | uint8_t dbs_cap; |
| 2140 | uint8_t agile_dfs_cap; |
| 2141 | }; |
| 2142 | |
| 2143 | /** |
| 2144 | * struct wmi_dual_mac_config - Dual MAC configuration |
| 2145 | * @scan_config: Scan configuration |
| 2146 | * @fw_mode_config: FW mode configuration |
| 2147 | * @set_dual_mac_cb: Callback function to be executed on response to the command |
| 2148 | */ |
| 2149 | struct wmi_dual_mac_config { |
| 2150 | uint32_t scan_config; |
| 2151 | uint32_t fw_mode_config; |
| 2152 | void *set_dual_mac_cb; |
| 2153 | }; |
| 2154 | |
| 2155 | #ifdef WLAN_NS_OFFLOAD |
| 2156 | /** |
| 2157 | * struct ns_offload_req_params - ns offload request paramter |
| 2158 | * @srcIPv6Addr: src ipv6 address |
| 2159 | * @selfIPv6Addr: self ipv6 address |
| 2160 | * @targetIPv6Addr: target ipv6 address |
| 2161 | * @self_macaddr: self mac address |
| 2162 | * @srcIPv6AddrValid: src ipv6 address valid flag |
| 2163 | * @targetIPv6AddrValid: target ipv6 address valid flag |
| 2164 | * @slotIdx: slot index |
| 2165 | */ |
| 2166 | struct ns_offload_req_params { |
| 2167 | uint8_t srcIPv6Addr[WMI_MAC_IPV6_ADDR_LEN]; |
| 2168 | uint8_t selfIPv6Addr[WMI_MAC_NUM_TARGET_IPV6_NS_OFFLOAD_NA][WMI_MAC_IPV6_ADDR_LEN]; |
| 2169 | uint8_t targetIPv6Addr[WMI_MAC_NUM_TARGET_IPV6_NS_OFFLOAD_NA][WMI_MAC_IPV6_ADDR_LEN]; |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 2170 | struct qdf_mac_addr self_macaddr; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 2171 | uint8_t srcIPv6AddrValid; |
| 2172 | uint8_t targetIPv6AddrValid[WMI_MAC_NUM_TARGET_IPV6_NS_OFFLOAD_NA]; |
| 2173 | uint8_t slotIdx; |
| 2174 | }; |
| 2175 | #endif /* WLAN_NS_OFFLOAD */ |
| 2176 | |
| 2177 | /** |
| 2178 | * struct host_offload_req_param - arp offload parameter |
| 2179 | * @offloadType: offload type |
| 2180 | * @enableOrDisable: enable or disable |
| 2181 | * @num_ns_offload_count: offload count |
| 2182 | */ |
| 2183 | struct host_offload_req_param { |
| 2184 | uint8_t offloadType; |
| 2185 | uint8_t enableOrDisable; |
| 2186 | uint32_t num_ns_offload_count; |
| 2187 | union { |
| 2188 | uint8_t hostIpv4Addr[WMI_IPV4_ADDR_LEN]; |
| 2189 | uint8_t hostIpv6Addr[WMI_MAC_IPV6_ADDR_LEN]; |
| 2190 | } params; |
| 2191 | #ifdef WLAN_NS_OFFLOAD |
| 2192 | struct ns_offload_req_params nsOffloadInfo; |
| 2193 | #endif /* WLAN_NS_OFFLOAD */ |
Govind Singh | d7468a5 | 2016-03-09 14:32:57 +0530 | [diff] [blame] | 2194 | struct qdf_mac_addr bssid; |
Govind Singh | ae85536 | 2016-03-07 14:24:22 +0530 | [diff] [blame] | 2195 | }; |
| 2196 | |
| 2197 | /** |
| 2198 | * struct ssid_hotlist_param - param for SSID Hotlist |
| 2199 | * @ssid: SSID which is being hotlisted |
| 2200 | * @band: Band in which the given SSID should be scanned |
| 2201 | * @rssi_low: Low bound on RSSI |
| 2202 | * @rssi_high: High bound on RSSI |
| 2203 | */ |
| 2204 | struct ssid_hotlist_param { |
| 2205 | struct mac_ssid ssid; |
| 2206 | uint8_t band; |
| 2207 | int32_t rssi_low; |
| 2208 | int32_t rssi_high; |
| 2209 | }; |
| 2210 | |
| 2211 | /** |
| 2212 | * struct ssid_hotlist_request_params - set SSID hotlist request struct |
| 2213 | * @request_id: ID of the request |
| 2214 | * @session_id: ID of the session |
| 2215 | * @lost_ssid_sample_size: Number of consecutive scans in which the SSID |
| 2216 | * must not be seen in order to consider the SSID "lost" |
| 2217 | * @ssid_count: Number of valid entries in the @ssids array |
| 2218 | * @ssids: Array that defines the SSIDs that are in the hotlist |
| 2219 | */ |
| 2220 | struct ssid_hotlist_request_params { |
| 2221 | uint32_t request_id; |
| 2222 | uint8_t session_id; |
| 2223 | uint32_t lost_ssid_sample_size; |
| 2224 | uint32_t ssid_count; |
| 2225 | struct ssid_hotlist_param ssids[WMI_EXTSCAN_MAX_HOTLIST_SSIDS]; |
| 2226 | }; |
| 2227 | |
| 2228 | /** |
| 2229 | * struct wmi_unit_test_cmd - unit test command parameters |
| 2230 | * @vdev_id: vdev id |
| 2231 | * @module_id: module id |
| 2232 | * @num_args: number of arguments |
| 2233 | * @args: arguments |
| 2234 | */ |
| 2235 | struct wmi_unit_test_cmd { |
| 2236 | uint32_t vdev_id; |
| 2237 | WLAN_MODULE_ID module_id; |
| 2238 | uint32_t num_args; |
| 2239 | uint32_t args[WMI_MAX_NUM_ARGS]; |
| 2240 | }; |
| 2241 | |
| 2242 | /** |
| 2243 | * struct wmi_roam_invoke_cmd - roam invoke command |
| 2244 | * @vdev_id: vdev id |
| 2245 | * @bssid: mac address |
| 2246 | * @channel: channel |
| 2247 | */ |
| 2248 | struct wmi_roam_invoke_cmd { |
| 2249 | uint32_t vdev_id; |
| 2250 | uint8_t bssid[IEEE80211_ADDR_LEN]; |
| 2251 | uint32_t channel; |
| 2252 | }; |
| 2253 | |
| 2254 | /** |
| 2255 | * struct ext_scan_setbssi_hotlist_params - set hotlist request |
| 2256 | * @requestId: request identifier |
| 2257 | * @sessionId: session identifier |
| 2258 | * @lost_ap_sample_size: number of samples to confirm AP loss |
| 2259 | * @numAp: Number of hotlist APs |
| 2260 | * @ap: hotlist APs |
| 2261 | */ |
| 2262 | struct ext_scan_setbssi_hotlist_params { |
| 2263 | uint32_t requestId; |
| 2264 | uint8_t sessionId; |
| 2265 | |
| 2266 | uint32_t lost_ap_sample_size; |
| 2267 | uint32_t numAp; |
| 2268 | struct ap_threshold_params ap[WMI_WLAN_EXTSCAN_MAX_HOTLIST_APS]; |
| 2269 | }; |
Govind Singh | 3ddda1f | 2016-03-09 11:34:12 +0530 | [diff] [blame] | 2270 | #endif /* _WMI_UNIFIED_PARAM_H_ */ |
| 2271 | |