blob: 09f0db08ffd6c48a218794ce1879315c33f2be0a [file] [log] [blame]
Govind Singhd475ea92016-03-06 19:55:02 +05301/*
Paul Zhanga9ec9432017-01-04 16:45:42 +08002 * Copyright (c) 2013-2017 The Linux Foundation. All rights reserved.
Govind Singhd475ea92016-03-06 19:55:02 +05303 *
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/*
Govind Singh3ddda1f2016-03-09 11:34:12 +053029 * This file contains the API definitions for the Unified Wireless
30 * Module Interface (WMI).
Govind Singhd475ea92016-03-06 19:55:02 +053031 */
32#ifndef _WMI_UNIFIED_PRIV_H_
33#define _WMI_UNIFIED_PRIV_H_
34#include <osdep.h>
35#include "a_types.h"
Govind Singh89727882016-04-15 13:58:27 +053036#include "wmi_unified_param.h"
Om Prakash Tripathi91452bf2017-02-25 15:53:30 +053037#include "wlan_scan_ucfg_api.h"
Govind Singhd7468a52016-03-09 14:32:57 +053038#include "qdf_atomic.h"
Rajeev Kumar0b6b2852017-02-03 00:39:49 -080039#include "wlan_objmgr_psoc_service_ready_api.h"
Govind Singhd475ea92016-03-06 19:55:02 +053040
Wu Gao07ba6b42017-03-13 20:17:34 +080041#ifdef CONVERGED_P2P_ENABLE
42#include <wlan_p2p_public_struct.h>
43#endif
44
Arif Hussaine542fe12017-04-09 01:03:19 -070045#ifdef DFS_COMPONENT_ENABLE
46#include <wlan_dfs_public_struct.h>
47#endif
48
Govind Singhd475ea92016-03-06 19:55:02 +053049#define WMI_UNIFIED_MAX_EVENT 0x100
Mukul Sharmab4ddf9c2016-10-12 23:50:13 +053050#define WMI_MAX_CMDS 1024
Govind Singhd475ea92016-03-06 19:55:02 +053051
Govind Singhd7468a52016-03-09 14:32:57 +053052typedef qdf_nbuf_t wmi_buf_t;
Govind Singhd475ea92016-03-06 19:55:02 +053053
54#ifdef WMI_INTERFACE_EVENT_LOGGING
55
56#define WMI_EVENT_DEBUG_MAX_ENTRY (1024)
Govind Singh5fed03b2016-05-12 12:45:51 +053057#define WMI_EVENT_DEBUG_ENTRY_MAX_LENGTH (16)
58/* wmi_mgmt commands */
59#define WMI_MGMT_EVENT_DEBUG_MAX_ENTRY (256)
Govind Singhd475ea92016-03-06 19:55:02 +053060
Govind Singh5fed03b2016-05-12 12:45:51 +053061/**
62 * struct wmi_command_debug - WMI command log buffer data type
63 * @ command - Store WMI Command id
64 * @ data - Stores WMI command data
65 * @ time - Time of WMI command handling
66 */
Govind Singhd475ea92016-03-06 19:55:02 +053067struct wmi_command_debug {
68 uint32_t command;
Govind Singh5fed03b2016-05-12 12:45:51 +053069 /*16 bytes of WMI cmd excluding TLV and WMI headers */
70 uint32_t data[WMI_EVENT_DEBUG_ENTRY_MAX_LENGTH/sizeof(uint32_t)];
Govind Singhd475ea92016-03-06 19:55:02 +053071 uint64_t time;
72};
73
Govind Singh5fed03b2016-05-12 12:45:51 +053074/**
75 * struct wmi_event_debug - WMI event log buffer data type
76 * @ command - Store WMI Event id
77 * @ data - Stores WMI Event data
78 * @ time - Time of WMI Event handling
79 */
Govind Singhd475ea92016-03-06 19:55:02 +053080struct wmi_event_debug {
81 uint32_t event;
Govind Singh5fed03b2016-05-12 12:45:51 +053082 /*16 bytes of WMI event data excluding TLV header */
83 uint32_t data[WMI_EVENT_DEBUG_ENTRY_MAX_LENGTH/sizeof(uint32_t)];
Govind Singhd475ea92016-03-06 19:55:02 +053084 uint64_t time;
85};
86
Govind Singh5fed03b2016-05-12 12:45:51 +053087/**
Sandeep Puligilla38a294f2016-06-13 15:42:55 -070088 * struct wmi_command_header - Type for accessing frame data
89 * @ type - 802.11 Frame type
90 * @ subType - 802.11 Frame subtype
91 * @ protVer - 802.11 Version
92 */
93struct wmi_command_header {
94#ifndef ANI_LITTLE_BIT_ENDIAN
95
96 uint32_t sub_type:4;
97 uint32_t type:2;
98 uint32_t prot_ver:2;
99
100#else
101
102 uint32_t prot_ver:2;
103 uint32_t type:2;
104 uint32_t sub_type:4;
105
106#endif
107};
108
109/**
Govind Singh5fed03b2016-05-12 12:45:51 +0530110 * struct wmi_log_buf_t - WMI log buffer information type
111 * @buf - Refernce to WMI log buffer
112 * @ length - length of buffer
113 * @ buf_tail_idx - Tail index of buffer
114 * @ p_buf_tail_idx - refernce to buffer tail index. It is added to accommodate
115 * unified design since MCL uses global variable for buffer tail index
Dustin Browne58fbc72017-04-03 17:00:07 -0700116 * @ size - the size of the buffer in number of entries
Govind Singh5fed03b2016-05-12 12:45:51 +0530117 */
118struct wmi_log_buf_t {
119 void *buf;
120 uint32_t length;
121 uint32_t buf_tail_idx;
122 uint32_t *p_buf_tail_idx;
Dustin Browne58fbc72017-04-03 17:00:07 -0700123 uint32_t size;
Govind Singh5fed03b2016-05-12 12:45:51 +0530124};
125
126/**
127 * struct wmi_debug_log_info - Meta data to hold information of all buffers
128 * used for WMI logging
129 * @wmi_command_log_buf_info - Buffer info for WMI Command log
130 * @wmi_command_tx_cmp_log_buf_info - Buffer info for WMI Command Tx completion
131 * log
132 * @wmi_event_log_buf_info - Buffer info for WMI Event log
133 * @wmi_rx_event_log_buf_info - Buffer info for WMI event received log
134 * @wmi_mgmt_command_log_buf_info - Buffer info for WMI Management Command log
135 * @wmi_mgmt_command_tx_cmp_log_buf_info - Buffer info for WMI Management
136 * Command Tx completion log
137 * @wmi_mgmt_event_log_buf_info - Buffer info for WMI Management event log
138 * @wmi_record_lock - Lock WMI recording
139 * @wmi_logging_enable - Enable/Disable state for WMI logging
140 * @buf_offset_command - Offset from where WMI command data should be logged
141 * @buf_offset_event - Offset from where WMI event data should be logged
142 * @is_management_record - Function refernce to check if command/event is
143 * management record
144 * @wmi_id_to_name - Function refernce to API to convert Command id to
145 * string name
146 * @wmi_log_debugfs_dir - refernce to debugfs directory
147 */
148struct wmi_debug_log_info {
149 struct wmi_log_buf_t wmi_command_log_buf_info;
150 struct wmi_log_buf_t wmi_command_tx_cmp_log_buf_info;
151
152 struct wmi_log_buf_t wmi_event_log_buf_info;
153 struct wmi_log_buf_t wmi_rx_event_log_buf_info;
154
155 struct wmi_log_buf_t wmi_mgmt_command_log_buf_info;
156 struct wmi_log_buf_t wmi_mgmt_command_tx_cmp_log_buf_info;
157 struct wmi_log_buf_t wmi_mgmt_event_log_buf_info;
158
159 qdf_spinlock_t wmi_record_lock;
160 bool wmi_logging_enable;
161 uint32_t buf_offset_command;
162 uint32_t buf_offset_event;
Govind Singh5fed03b2016-05-12 12:45:51 +0530163 struct dentry *wmi_log_debugfs_dir;
164 uint8_t wmi_instance_id;
165};
166
Govind Singhd475ea92016-03-06 19:55:02 +0530167#endif /*WMI_INTERFACE_EVENT_LOGGING */
168
169#ifdef WLAN_OPEN_SOURCE
170struct fwdebug {
171 struct sk_buff_head fwlog_queue;
172 struct completion fwlog_completion;
173 A_BOOL fwlog_open;
174};
175#endif /* WLAN_OPEN_SOURCE */
176
Govind Singh3ddda1f2016-03-09 11:34:12 +0530177struct wmi_ops {
Govind Singhd7468a52016-03-09 14:32:57 +0530178QDF_STATUS (*send_vdev_create_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530179 uint8_t macaddr[IEEE80211_ADDR_LEN],
180 struct vdev_create_params *param);
181
Govind Singhd7468a52016-03-09 14:32:57 +0530182QDF_STATUS (*send_vdev_delete_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530183 uint8_t if_id);
184
Govind Singhd7468a52016-03-09 14:32:57 +0530185QDF_STATUS (*send_vdev_stop_cmd)(wmi_unified_t wmi,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530186 uint8_t vdev_id);
187
Govind Singhd7468a52016-03-09 14:32:57 +0530188QDF_STATUS (*send_vdev_down_cmd)(wmi_unified_t wmi,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530189 uint8_t vdev_id);
190
Himanshu Agarwal7e4f4bc2016-03-09 16:49:38 +0530191QDF_STATUS (*send_vdev_start_cmd)(wmi_unified_t wmi,
192 struct vdev_start_params *req);
193
194QDF_STATUS (*send_hidden_ssid_vdev_restart_cmd)(wmi_unified_t wmi_handle,
195 struct hidden_ssid_vdev_restart_params *restart_params);
196
Govind Singhd7468a52016-03-09 14:32:57 +0530197QDF_STATUS (*send_peer_flush_tids_cmd)(wmi_unified_t wmi,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530198 uint8_t peer_addr[IEEE80211_ADDR_LEN],
199 struct peer_flush_params *param);
200
Govind Singhd7468a52016-03-09 14:32:57 +0530201QDF_STATUS (*send_peer_delete_cmd)(wmi_unified_t wmi,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530202 uint8_t peer_addr[IEEE80211_ADDR_LEN],
203 uint8_t vdev_id);
204
Govind Singhd7468a52016-03-09 14:32:57 +0530205QDF_STATUS (*send_peer_param_cmd)(wmi_unified_t wmi,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530206 uint8_t peer_addr[IEEE80211_ADDR_LEN],
207 struct peer_set_params *param);
208
Govind Singhd7468a52016-03-09 14:32:57 +0530209QDF_STATUS (*send_vdev_up_cmd)(wmi_unified_t wmi,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530210 uint8_t bssid[IEEE80211_ADDR_LEN],
211 struct vdev_up_params *params);
212
Govind Singhd7468a52016-03-09 14:32:57 +0530213QDF_STATUS (*send_peer_create_cmd)(wmi_unified_t wmi,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530214 struct peer_create_params *param);
215
Govind Singhd7468a52016-03-09 14:32:57 +0530216QDF_STATUS (*send_green_ap_ps_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530217 uint32_t value, uint8_t mac_id);
218
Govind Singhd7468a52016-03-09 14:32:57 +0530219QDF_STATUS
Govind Singh3ddda1f2016-03-09 11:34:12 +0530220(*send_pdev_utf_cmd)(wmi_unified_t wmi_handle,
221 struct pdev_utf_params *param,
222 uint8_t mac_id);
223
Govind Singhd7468a52016-03-09 14:32:57 +0530224QDF_STATUS
Govind Singh3ddda1f2016-03-09 11:34:12 +0530225(*send_pdev_param_cmd)(wmi_unified_t wmi_handle,
226 struct pdev_params *param,
227 uint8_t mac_id);
228
Govind Singhd7468a52016-03-09 14:32:57 +0530229QDF_STATUS (*send_suspend_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530230 struct suspend_params *param,
231 uint8_t mac_id);
232
Govind Singhd7468a52016-03-09 14:32:57 +0530233QDF_STATUS (*send_resume_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530234 uint8_t mac_id);
235
Govind Singhd7468a52016-03-09 14:32:57 +0530236QDF_STATUS (*send_wow_enable_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530237 struct wow_cmd_params *param,
238 uint8_t mac_id);
239
Govind Singhd7468a52016-03-09 14:32:57 +0530240QDF_STATUS (*send_set_ap_ps_param_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530241 uint8_t *peer_addr,
242 struct ap_ps_params *param);
243
Govind Singhd7468a52016-03-09 14:32:57 +0530244QDF_STATUS (*send_set_sta_ps_param_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530245 struct sta_ps_params *param);
246
Govind Singhd7468a52016-03-09 14:32:57 +0530247QDF_STATUS (*send_crash_inject_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530248 struct crash_inject *param);
249
Govind Singhd7468a52016-03-09 14:32:57 +0530250QDF_STATUS
Govind Singh3ddda1f2016-03-09 11:34:12 +0530251(*send_dbglog_cmd)(wmi_unified_t wmi_handle,
252 struct dbglog_params *dbglog_param);
253
Govind Singhd7468a52016-03-09 14:32:57 +0530254QDF_STATUS (*send_vdev_set_param_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530255 struct vdev_set_params *param);
256
Govind Singhd7468a52016-03-09 14:32:57 +0530257QDF_STATUS (*send_stats_request_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530258 uint8_t macaddr[IEEE80211_ADDR_LEN],
259 struct stats_request_params *param);
260
Govind Singhfa201d92016-06-08 19:40:11 +0530261#ifdef CONFIG_WIN
Govind Singh89727882016-04-15 13:58:27 +0530262QDF_STATUS (*send_packet_log_enable_cmd)(wmi_unified_t wmi_handle,
263 WMI_HOST_PKTLOG_EVENT PKTLOG_EVENT);
264#else
Govind Singhd7468a52016-03-09 14:32:57 +0530265QDF_STATUS (*send_packet_log_enable_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530266 uint8_t macaddr[IEEE80211_ADDR_LEN],
267 struct packet_enable_params *param);
Govind Singh89727882016-04-15 13:58:27 +0530268#endif
269
270QDF_STATUS (*send_packet_log_disable_cmd)(wmi_unified_t wmi_handle);
Govind Singh3ddda1f2016-03-09 11:34:12 +0530271
Govind Singhd7468a52016-03-09 14:32:57 +0530272QDF_STATUS (*send_beacon_send_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530273 struct beacon_params *param);
274
Govind Singh89727882016-04-15 13:58:27 +0530275QDF_STATUS (*send_beacon_tmpl_send_cmd)(wmi_unified_t wmi_handle,
276 struct beacon_tmpl_params *param);
277
Govind Singhd7468a52016-03-09 14:32:57 +0530278QDF_STATUS (*send_peer_assoc_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530279 struct peer_assoc_params *param);
280
Govind Singhd7468a52016-03-09 14:32:57 +0530281QDF_STATUS (*send_scan_start_cmd)(wmi_unified_t wmi_handle,
Om Prakash Tripathi91452bf2017-02-25 15:53:30 +0530282 struct scan_req_params *param);
Govind Singh3ddda1f2016-03-09 11:34:12 +0530283
Govind Singhd7468a52016-03-09 14:32:57 +0530284QDF_STATUS (*send_scan_stop_cmd)(wmi_unified_t wmi_handle,
Om Prakash Tripathi91452bf2017-02-25 15:53:30 +0530285 struct scan_cancel_param *param);
Govind Singh3ddda1f2016-03-09 11:34:12 +0530286
Govind Singhd7468a52016-03-09 14:32:57 +0530287QDF_STATUS (*send_scan_chan_list_cmd)(wmi_unified_t wmi_handle,
Govind Singh3ddda1f2016-03-09 11:34:12 +0530288 struct scan_chan_list_params *param);
Govind Singh50988cc2016-02-26 18:09:36 +0530289
Govind Singhd7468a52016-03-09 14:32:57 +0530290QDF_STATUS (*send_mgmt_cmd)(wmi_unified_t wmi_handle,
Govind Singh50988cc2016-02-26 18:09:36 +0530291 struct wmi_mgmt_params *param);
292
Kiran Venkatappa25c47022017-03-19 22:58:09 +0530293QDF_STATUS (*send_offchan_data_tx_cmd)(wmi_unified_t wmi_handle,
294 struct wmi_offchan_data_tx_params *param);
295
Govind Singhd7468a52016-03-09 14:32:57 +0530296QDF_STATUS (*send_modem_power_state_cmd)(wmi_unified_t wmi_handle,
Govind Singh50988cc2016-02-26 18:09:36 +0530297 uint32_t param_value);
298
Govind Singhd7468a52016-03-09 14:32:57 +0530299QDF_STATUS (*send_set_sta_ps_mode_cmd)(wmi_unified_t wmi_handle,
Govind Singh50988cc2016-02-26 18:09:36 +0530300 uint32_t vdev_id, uint8_t val);
301
Govind Singhd7468a52016-03-09 14:32:57 +0530302QDF_STATUS (*send_get_temperature_cmd)(wmi_unified_t wmi_handle);
Govind Singh50988cc2016-02-26 18:09:36 +0530303
Govind Singhd7468a52016-03-09 14:32:57 +0530304QDF_STATUS (*send_set_p2pgo_oppps_req_cmd)(wmi_unified_t wmi_handle,
Govind Singh50988cc2016-02-26 18:09:36 +0530305 struct p2p_ps_params *oppps);
306
Govind Singhd7468a52016-03-09 14:32:57 +0530307QDF_STATUS (*send_set_p2pgo_noa_req_cmd)(wmi_unified_t wmi_handle,
Govind Singh50988cc2016-02-26 18:09:36 +0530308 struct p2p_ps_params *noa);
309
Wu Gao07ba6b42017-03-13 20:17:34 +0800310#ifdef CONVERGED_P2P_ENABLE
311QDF_STATUS (*send_p2p_lo_start_cmd)(wmi_unified_t wmi_handle,
312 struct p2p_lo_start *param);
313
314QDF_STATUS (*send_p2p_lo_stop_cmd)(wmi_unified_t wmi_handle,
315 uint8_t vdev_id);
316#endif
317
Govind Singhd7468a52016-03-09 14:32:57 +0530318QDF_STATUS (*send_set_smps_params_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530319 uint8_t vdev_id,
320 int value);
Govind Singh50988cc2016-02-26 18:09:36 +0530321
Govind Singhd7468a52016-03-09 14:32:57 +0530322QDF_STATUS (*send_set_mimops_cmd)(wmi_unified_t wmi_handle,
Govind Singh50988cc2016-02-26 18:09:36 +0530323 uint8_t vdev_id, int value);
324
Govind Singhd7468a52016-03-09 14:32:57 +0530325QDF_STATUS (*send_set_sta_uapsd_auto_trig_cmd)(wmi_unified_t wmi_handle,
Govind Singh50988cc2016-02-26 18:09:36 +0530326 struct sta_uapsd_trig_params *param);
Govind Singhe7b800c2016-03-01 15:30:53 +0530327
Govind Singhd7468a52016-03-09 14:32:57 +0530328QDF_STATUS (*send_ocb_set_utc_time_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530329 struct ocb_utc_param *utc);
330
Govind Singhd7468a52016-03-09 14:32:57 +0530331QDF_STATUS (*send_ocb_get_tsf_timer_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530332 uint8_t vdev_id);
333
Govind Singhd7468a52016-03-09 14:32:57 +0530334QDF_STATUS (*send_ocb_start_timing_advert_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530335 struct ocb_timing_advert_param *timing_advert);
336
Govind Singhd7468a52016-03-09 14:32:57 +0530337QDF_STATUS (*send_ocb_stop_timing_advert_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530338 struct ocb_timing_advert_param *timing_advert);
339
Govind Singhd7468a52016-03-09 14:32:57 +0530340QDF_STATUS (*send_dcc_get_stats_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530341 struct dcc_get_stats_param *get_stats_param);
342
Govind Singhd7468a52016-03-09 14:32:57 +0530343QDF_STATUS (*send_dcc_clear_stats_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530344 uint32_t vdev_id, uint32_t dcc_stats_bitmap);
345
Govind Singhd7468a52016-03-09 14:32:57 +0530346QDF_STATUS (*send_dcc_update_ndl_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530347 struct dcc_update_ndl_param *update_ndl_param);
348
Govind Singhd7468a52016-03-09 14:32:57 +0530349QDF_STATUS (*send_ocb_set_config_cmd)(wmi_unified_t wmi_handle,
Govind Singhe7b800c2016-03-01 15:30:53 +0530350 struct ocb_config_param *config, uint32_t *ch_mhz);
Govind Singhae855362016-03-07 14:24:22 +0530351
Govind Singhd7468a52016-03-09 14:32:57 +0530352QDF_STATUS (*send_lro_config_cmd)(wmi_unified_t wmi_handle,
Govind Singh9bad0002016-03-01 15:54:59 +0530353 struct wmi_lro_config_cmd_t *wmi_lro_cmd);
354
Govind Singhd7468a52016-03-09 14:32:57 +0530355QDF_STATUS (*send_set_thermal_mgmt_cmd)(wmi_unified_t wmi_handle,
Govind Singh9bad0002016-03-01 15:54:59 +0530356 struct thermal_cmd_params *thermal_info);
357
Poddar, Siddarth794b9962016-04-28 15:49:11 +0530358QDF_STATUS (*send_peer_rate_report_cmd)(wmi_unified_t wmi_handle,
359 struct wmi_peer_rate_report_params *rate_report_params);
360
Govind Singhd7468a52016-03-09 14:32:57 +0530361QDF_STATUS (*send_set_mcc_channel_time_quota_cmd)
Govind Singh9bad0002016-03-01 15:54:59 +0530362 (wmi_unified_t wmi_handle,
363 uint32_t adapter_1_chan_freq,
364 uint32_t adapter_1_quota, uint32_t adapter_2_chan_freq);
365
Govind Singhd7468a52016-03-09 14:32:57 +0530366QDF_STATUS (*send_set_mcc_channel_time_latency_cmd)
Govind Singh9bad0002016-03-01 15:54:59 +0530367 (wmi_unified_t wmi_handle,
368 uint32_t mcc_channel_freq, uint32_t mcc_channel_time_latency);
369
Govind Singhd7468a52016-03-09 14:32:57 +0530370QDF_STATUS (*send_set_enable_disable_mcc_adaptive_scheduler_cmd)(
Govind Singh608e8892016-04-16 19:24:23 -0700371 wmi_unified_t wmi_handle, uint32_t mcc_adaptive_scheduler,
372 uint32_t pdev_id);
Govind Singhae855362016-03-07 14:24:22 +0530373
Govind Singhd7468a52016-03-09 14:32:57 +0530374QDF_STATUS (*send_p2p_go_set_beacon_ie_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530375 A_UINT32 vdev_id, uint8_t *p2p_ie);
376
Govind Singhd7468a52016-03-09 14:32:57 +0530377QDF_STATUS (*send_probe_rsp_tmpl_send_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530378 uint8_t vdev_id,
379 struct wmi_probe_resp_params *probe_rsp_info,
380 uint8_t *frm);
381
Himanshu Agarwal9efd9bf2016-03-09 18:49:18 +0530382QDF_STATUS (*send_setup_install_key_cmd)(wmi_unified_t wmi_handle,
383 struct set_key_params *key_params);
384
Govind Singhd7468a52016-03-09 14:32:57 +0530385QDF_STATUS (*send_vdev_set_gtx_cfg_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530386 uint32_t if_id,
387 struct wmi_gtx_config *gtx_info);
388
Govind Singhd7468a52016-03-09 14:32:57 +0530389QDF_STATUS (*send_set_sta_keep_alive_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530390 struct sta_params *params);
391
Govind Singhd7468a52016-03-09 14:32:57 +0530392QDF_STATUS (*send_set_sta_sa_query_param_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530393 uint8_t vdev_id, uint32_t max_retries,
394 uint32_t retry_interval);
Govind Singhae855362016-03-07 14:24:22 +0530395
Govind Singhd7468a52016-03-09 14:32:57 +0530396QDF_STATUS (*send_set_gateway_params_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530397 struct gateway_update_req_param *req);
398
Govind Singhd7468a52016-03-09 14:32:57 +0530399QDF_STATUS (*send_set_rssi_monitoring_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530400 struct rssi_monitor_param *req);
401
Govind Singhd7468a52016-03-09 14:32:57 +0530402QDF_STATUS (*send_scan_probe_setoui_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530403 struct scan_mac_oui *psetoui);
404
Govind Singhd7468a52016-03-09 14:32:57 +0530405QDF_STATUS (*send_reset_passpoint_network_list_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530406 struct wifi_passpoint_req_param *req);
Himanshu Agarwal5f2d0482016-03-09 15:25:44 +0530407
408QDF_STATUS (*send_roam_scan_offload_rssi_thresh_cmd)(wmi_unified_t wmi_handle,
409 struct roam_offload_scan_rssi_params *roam_req);
410
411QDF_STATUS (*send_roam_scan_filter_cmd)(wmi_unified_t wmi_handle,
412 struct roam_scan_filter_params *roam_req);
413
Govind Singhd7468a52016-03-09 14:32:57 +0530414QDF_STATUS (*send_set_passpoint_network_list_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530415 struct wifi_passpoint_req_param *req);
416
Govind Singhd7468a52016-03-09 14:32:57 +0530417QDF_STATUS (*send_set_epno_network_list_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530418 struct wifi_enhanched_pno_params *req);
419
Govind Singhd7468a52016-03-09 14:32:57 +0530420QDF_STATUS (*send_extscan_get_capabilities_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530421 struct extscan_capabilities_params *pgetcapab);
422
Govind Singhd7468a52016-03-09 14:32:57 +0530423QDF_STATUS (*send_extscan_get_cached_results_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530424 struct extscan_cached_result_params *pcached_results);
425
Govind Singhd7468a52016-03-09 14:32:57 +0530426QDF_STATUS (*send_extscan_stop_change_monitor_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530427 struct extscan_capabilities_reset_params *reset_req);
428
Govind Singhd7468a52016-03-09 14:32:57 +0530429QDF_STATUS (*send_extscan_start_change_monitor_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530430 struct extscan_set_sig_changereq_params *
431 psigchange);
432
Govind Singhd7468a52016-03-09 14:32:57 +0530433QDF_STATUS (*send_extscan_stop_hotlist_monitor_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530434 struct extscan_bssid_hotlist_reset_params *photlist_reset);
435
Govind Singhd7468a52016-03-09 14:32:57 +0530436QDF_STATUS (*send_stop_extscan_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530437 struct extscan_stop_req_params *pstopcmd);
438
Govind Singhd7468a52016-03-09 14:32:57 +0530439QDF_STATUS (*send_start_extscan_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530440 struct wifi_scan_cmd_req_params *pstart);
441
Govind Singhd7468a52016-03-09 14:32:57 +0530442QDF_STATUS (*send_plm_stop_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530443 const struct plm_req_params *plm);
444
Govind Singh89727882016-04-15 13:58:27 +0530445
Govind Singhd7468a52016-03-09 14:32:57 +0530446QDF_STATUS (*send_plm_start_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530447 const struct plm_req_params *plm,
448 uint32_t *gchannel_list);
449
Govind Singhd7468a52016-03-09 14:32:57 +0530450QDF_STATUS (*send_csa_offload_enable_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530451 uint8_t vdev_id);
452
Govind Singhd7468a52016-03-09 14:32:57 +0530453QDF_STATUS (*send_pno_stop_cmd)(wmi_unified_t wmi_handle, uint8_t vdev_id);
Govind Singhae855362016-03-07 14:24:22 +0530454
Govind Singhd7468a52016-03-09 14:32:57 +0530455QDF_STATUS (*send_pno_start_cmd)(wmi_unified_t wmi_handle,
Abhishek Singhd4184662017-03-03 22:09:07 +0530456 struct pno_scan_req_params *pno);
Govind Singhae855362016-03-07 14:24:22 +0530457
Govind Singhd7468a52016-03-09 14:32:57 +0530458QDF_STATUS (*send_ipa_offload_control_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530459 struct ipa_offload_control_params *ipa_offload);
460
Govind Singhd7468a52016-03-09 14:32:57 +0530461QDF_STATUS (*send_set_ric_req_cmd)(wmi_unified_t wmi_handle, void *msg,
Govind Singhae855362016-03-07 14:24:22 +0530462 uint8_t is_add_ts);
463
Govind Singhd7468a52016-03-09 14:32:57 +0530464QDF_STATUS (*send_process_ll_stats_clear_cmd)
Govind Singhae855362016-03-07 14:24:22 +0530465 (wmi_unified_t wmi_handle,
466 const struct ll_stats_clear_params *clear_req,
467 uint8_t addr[IEEE80211_ADDR_LEN]);
468
Govind Singhd7468a52016-03-09 14:32:57 +0530469QDF_STATUS (*send_process_ll_stats_set_cmd)
Govind Singhae855362016-03-07 14:24:22 +0530470 (wmi_unified_t wmi_handle, const struct ll_stats_set_params *set_req);
471
Govind Singhd7468a52016-03-09 14:32:57 +0530472QDF_STATUS (*send_process_ll_stats_get_cmd)
Govind Singhae855362016-03-07 14:24:22 +0530473 (wmi_unified_t wmi_handle, const struct ll_stats_get_params *get_req,
474 uint8_t addr[IEEE80211_ADDR_LEN]);
475
Govind Singhd7468a52016-03-09 14:32:57 +0530476QDF_STATUS (*send_get_stats_cmd)(wmi_unified_t wmi_handle,
Govind Singhae855362016-03-07 14:24:22 +0530477 struct pe_stats_req *get_stats_param,
478 uint8_t addr[IEEE80211_ADDR_LEN]);
Govind Singh229bc0d2016-03-07 15:33:31 +0530479
Padma, Santhosh Kumard3261902017-03-21 19:09:35 +0530480QDF_STATUS (*send_congestion_cmd)(wmi_unified_t wmi_handle,
481 A_UINT8 vdev_id);
482
Govind Singhd7468a52016-03-09 14:32:57 +0530483QDF_STATUS (*send_snr_request_cmd)(wmi_unified_t wmi_handle);
Govind Singh229bc0d2016-03-07 15:33:31 +0530484
Govind Singhd7468a52016-03-09 14:32:57 +0530485QDF_STATUS (*send_snr_cmd)(wmi_unified_t wmi_handle, uint8_t vdev_id);
Govind Singh229bc0d2016-03-07 15:33:31 +0530486
Govind Singhd7468a52016-03-09 14:32:57 +0530487QDF_STATUS (*send_link_status_req_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530488 struct link_status_params *link_status);
Mukul Sharmaba196f52017-02-25 01:50:47 +0530489#ifdef WLAN_PMO_ENABLE
490QDF_STATUS (*send_add_wow_wakeup_event_cmd)(wmi_unified_t wmi_handle,
491 uint32_t vdev_id,
492 uint32_t bitmap,
493 bool enable);
494
495QDF_STATUS (*send_wow_patterns_to_fw_cmd)(wmi_unified_t wmi_handle,
496 uint8_t vdev_id, uint8_t ptrn_id,
497 const uint8_t *ptrn, uint8_t ptrn_len,
498 uint8_t ptrn_offset, const uint8_t *mask,
499 uint8_t mask_len, bool user,
500 uint8_t default_patterns);
501
502QDF_STATUS (*send_enable_arp_ns_offload_cmd)(wmi_unified_t wmi_handle,
503 struct pmo_arp_offload_params *arp_offload_req,
504 struct pmo_ns_offload_params *ns_offload_req,
505 uint8_t vdev_id);
506
Dustin Brown27a3a922017-05-12 14:01:44 -0700507QDF_STATUS (*send_conf_hw_filter_cmd)(wmi_unified_t wmi,
508 struct pmo_hw_filter_params *req);
Ravi Kumar Bokka998a6ea2017-03-23 15:22:51 +0530509
Mukul Sharmaba196f52017-02-25 01:50:47 +0530510QDF_STATUS (*send_enable_enhance_multicast_offload_cmd)(
511 wmi_unified_t wmi_handle,
512 uint8_t vdev_id, bool action);
513
514QDF_STATUS (*send_add_clear_mcbc_filter_cmd)(wmi_unified_t wmi_handle,
515 uint8_t vdev_id,
516 struct qdf_mac_addr multicast_addr,
517 bool clearList);
518
519QDF_STATUS (*send_gtk_offload_cmd)(wmi_unified_t wmi_handle, uint8_t vdev_id,
520 struct pmo_gtk_req *params,
521 bool enable_offload,
522 uint32_t gtk_offload_opcode);
523
524QDF_STATUS (*send_process_gtk_offload_getinfo_cmd)(wmi_unified_t wmi_handle,
525 uint8_t vdev_id,
526 uint64_t offload_req_opcode);
527
528QDF_STATUS (*send_wow_sta_ra_filter_cmd)(wmi_unified_t wmi_handle,
529 uint8_t vdev_id, uint8_t default_pattern,
530 uint16_t rate_limit_interval);
531
532QDF_STATUS (*send_action_frame_patterns_cmd)(wmi_unified_t wmi_handle,
533 struct pmo_action_wakeup_set_params *action_params);
534
535QDF_STATUS (*extract_gtk_rsp_event)(wmi_unified_t wmi_handle,
536 void *evt_buf,
537 struct pmo_gtk_rsp_params *gtk_rsp_param, uint32_t len);
538
Govind Singhd7468a52016-03-09 14:32:57 +0530539QDF_STATUS (*send_lphb_config_hbenable_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530540 wmi_hb_set_enable_cmd_fixed_param *params);
541
Govind Singhd7468a52016-03-09 14:32:57 +0530542QDF_STATUS (*send_lphb_config_tcp_params_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530543 wmi_hb_set_tcp_params_cmd_fixed_param *lphb_conf_req);
544
Govind Singhd7468a52016-03-09 14:32:57 +0530545QDF_STATUS (*send_lphb_config_tcp_pkt_filter_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530546 wmi_hb_set_tcp_pkt_filter_cmd_fixed_param *g_hb_tcp_filter_fp);
547
Govind Singhd7468a52016-03-09 14:32:57 +0530548QDF_STATUS (*send_lphb_config_udp_params_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530549 wmi_hb_set_udp_params_cmd_fixed_param *lphb_conf_req);
550
Govind Singhd7468a52016-03-09 14:32:57 +0530551QDF_STATUS (*send_lphb_config_udp_pkt_filter_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530552 wmi_hb_set_udp_pkt_filter_cmd_fixed_param *lphb_conf_req);
Ravi Kumar Bokka26800cc2017-04-20 17:14:33 +0530553
554QDF_STATUS (*send_enable_disable_packet_filter_cmd)(wmi_unified_t wmi_handle,
555 uint8_t vdev_id, bool enable);
556
557QDF_STATUS (*send_config_packet_filter_cmd)(wmi_unified_t wmi_handle,
558 uint8_t vdev_id, struct pmo_rcv_pkt_fltr_cfg *rcv_filter_param,
559 uint8_t filter_id, bool enable);
Mukul Sharmaba196f52017-02-25 01:50:47 +0530560#endif /* end of WLAN_PMO_ENABLE */
561#ifdef CONFIG_MCL
Govind Singhd7468a52016-03-09 14:32:57 +0530562QDF_STATUS (*send_process_dhcp_ind_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530563 wmi_peer_set_param_cmd_fixed_param *ta_dhcp_ind);
564
Govind Singhd7468a52016-03-09 14:32:57 +0530565QDF_STATUS (*send_get_link_speed_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530566 wmi_mac_addr peer_macaddr);
567
Govind Singhd7468a52016-03-09 14:32:57 +0530568QDF_STATUS (*send_egap_conf_params_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530569 wmi_ap_ps_egap_param_cmd_fixed_param *egap_params);
Govind Singhfa201d92016-06-08 19:40:11 +0530570
571QDF_STATUS (*send_process_update_edca_param_cmd)(wmi_unified_t wmi_handle,
572 uint8_t vdev_id,
573 wmi_wmm_vparams gwmm_param[WMI_MAX_NUM_AC]);
574
575QDF_STATUS (*send_bcn_buf_ll_cmd)(wmi_unified_t wmi_handle,
576 wmi_bcn_send_from_host_cmd_fixed_param * param);
577
578QDF_STATUS (*send_roam_scan_offload_mode_cmd)(wmi_unified_t wmi_handle,
579 wmi_start_scan_cmd_fixed_param * scan_cmd_fp,
580 struct roam_offload_scan_params *roam_req);
581
582QDF_STATUS (*send_roam_scan_offload_ap_profile_cmd)(wmi_unified_t wmi_handle,
583 wmi_ap_profile * ap_profile_p,
584 uint32_t vdev_id);
585
586QDF_STATUS (*send_pktlog_wmi_send_cmd)(wmi_unified_t wmi_handle,
587 WMI_PKTLOG_EVENT pktlog_event,
Nirav Shah9d1f1ac2016-07-27 19:06:13 +0530588 WMI_CMD_ID cmd_id, uint8_t user_triggered);
Govind Singh89727882016-04-15 13:58:27 +0530589#endif
Govind Singh229bc0d2016-03-07 15:33:31 +0530590
Govind Singhd7468a52016-03-09 14:32:57 +0530591QDF_STATUS (*send_fw_profiling_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530592 uint32_t cmd, uint32_t value1, uint32_t value2);
593
Govind Singhd7468a52016-03-09 14:32:57 +0530594QDF_STATUS (*send_nat_keepalive_en_cmd)(wmi_unified_t wmi_handle, uint8_t vdev_id);
Govind Singh229bc0d2016-03-07 15:33:31 +0530595
Naveen Rawat90bc8fd2017-05-13 15:56:57 -0700596#ifdef WLAN_FEATURE_CIF_CFR
597QDF_STATUS (*send_oem_dma_cfg_cmd)(wmi_unified_t wmi_handle,
598 wmi_oem_dma_ring_cfg_req_fixed_param *cfg);
599#endif
600
Govind Singhd7468a52016-03-09 14:32:57 +0530601QDF_STATUS (*send_start_oem_data_cmd)(wmi_unified_t wmi_handle,
Krishna Kumaar Natarajan7a59ca02016-07-21 15:02:44 -0700602 uint32_t data_len,
Govind Singh229bc0d2016-03-07 15:33:31 +0530603 uint8_t *data);
604
Govind Singhd7468a52016-03-09 14:32:57 +0530605QDF_STATUS
Govind Singh229bc0d2016-03-07 15:33:31 +0530606(*send_dfs_phyerr_filter_offload_en_cmd)(wmi_unified_t wmi_handle,
607 bool dfs_phyerr_filter_offload);
Govind Singh229bc0d2016-03-07 15:33:31 +0530608
Govind Singhd7468a52016-03-09 14:32:57 +0530609QDF_STATUS (*send_wow_delete_pattern_cmd)(wmi_unified_t wmi_handle, uint8_t ptrn_id,
Govind Singh229bc0d2016-03-07 15:33:31 +0530610 uint8_t vdev_id);
611
Govind Singhd7468a52016-03-09 14:32:57 +0530612QDF_STATUS (*send_host_wakeup_ind_to_fw_cmd)(wmi_unified_t wmi_handle);
Govind Singh229bc0d2016-03-07 15:33:31 +0530613
Govind Singhd7468a52016-03-09 14:32:57 +0530614QDF_STATUS (*send_del_ts_cmd)(wmi_unified_t wmi_handle, uint8_t vdev_id,
Govind Singh229bc0d2016-03-07 15:33:31 +0530615 uint8_t ac);
616
Govind Singhd7468a52016-03-09 14:32:57 +0530617QDF_STATUS (*send_aggr_qos_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530618 struct aggr_add_ts_param *aggr_qos_rsp_msg);
619
Govind Singhd7468a52016-03-09 14:32:57 +0530620QDF_STATUS (*send_add_ts_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530621 struct add_ts_param *msg);
622
Govind Singhd7468a52016-03-09 14:32:57 +0530623QDF_STATUS (*send_process_add_periodic_tx_ptrn_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530624 struct periodic_tx_pattern *
625 pAddPeriodicTxPtrnParams,
626 uint8_t vdev_id);
627
Govind Singhd7468a52016-03-09 14:32:57 +0530628QDF_STATUS (*send_process_del_periodic_tx_ptrn_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530629 uint8_t vdev_id,
630 uint8_t pattern_id);
631
Govind Singhd7468a52016-03-09 14:32:57 +0530632QDF_STATUS (*send_stats_ext_req_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530633 struct stats_ext_params *preq);
634
Govind Singhd7468a52016-03-09 14:32:57 +0530635QDF_STATUS (*send_enable_ext_wow_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530636 struct ext_wow_params *params);
637
Govind Singhd7468a52016-03-09 14:32:57 +0530638QDF_STATUS (*send_set_app_type2_params_in_fw_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530639 struct app_type2_params *appType2Params);
640
Govind Singhd7468a52016-03-09 14:32:57 +0530641QDF_STATUS (*send_set_auto_shutdown_timer_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530642 uint32_t timer_val);
643
Govind Singhd7468a52016-03-09 14:32:57 +0530644QDF_STATUS (*send_nan_req_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530645 struct nan_req_params *nan_req);
646
Govind Singhd7468a52016-03-09 14:32:57 +0530647QDF_STATUS (*send_process_dhcpserver_offload_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530648 struct dhcp_offload_info_params *pDhcpSrvOffloadInfo);
649
Govind Singhd7468a52016-03-09 14:32:57 +0530650QDF_STATUS (*send_process_ch_avoid_update_cmd)(wmi_unified_t wmi_handle);
Govind Singh229bc0d2016-03-07 15:33:31 +0530651
Govind Singhd7468a52016-03-09 14:32:57 +0530652QDF_STATUS (*send_regdomain_info_to_fw_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530653 uint32_t reg_dmn, uint16_t regdmn2G,
654 uint16_t regdmn5G, int8_t ctl2G,
655 int8_t ctl5G);
656
Govind Singhd7468a52016-03-09 14:32:57 +0530657QDF_STATUS (*send_set_tdls_offchan_mode_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530658 struct tdls_channel_switch_params *chan_switch_params);
659
Govind Singhd7468a52016-03-09 14:32:57 +0530660QDF_STATUS (*send_update_fw_tdls_state_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530661 void *tdls_param, uint8_t tdls_state);
662
Govind Singhd7468a52016-03-09 14:32:57 +0530663QDF_STATUS (*send_update_tdls_peer_state_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530664 struct tdls_peer_state_params *peerStateParams,
665 uint32_t *ch_mhz);
666
667
Govind Singhd7468a52016-03-09 14:32:57 +0530668QDF_STATUS (*send_process_fw_mem_dump_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530669 struct fw_dump_req_param *mem_dump_req);
670
Govind Singhd7468a52016-03-09 14:32:57 +0530671QDF_STATUS (*send_process_set_ie_info_cmd)(wmi_unified_t wmi_handle,
Govind Singh229bc0d2016-03-07 15:33:31 +0530672 struct vdev_ie_info_param *ie_info);
Govind Singh71ee2d72016-03-07 16:30:32 +0530673
Himanshu Agarwal56c292f2016-07-19 15:41:51 +0530674#ifdef CONFIG_MCL
Govind Singhd7468a52016-03-09 14:32:57 +0530675QDF_STATUS (*send_init_cmd)(wmi_unified_t wmi_handle,
Govind Singh71ee2d72016-03-07 16:30:32 +0530676 wmi_resource_config *res_cfg,
677 uint8_t num_mem_chunks, struct wmi_host_mem_chunk *mem_chunk,
678 bool action);
Himanshu Agarwal56c292f2016-07-19 15:41:51 +0530679#endif
Govind Singh71ee2d72016-03-07 16:30:32 +0530680
Govind Singhd7468a52016-03-09 14:32:57 +0530681QDF_STATUS (*save_fw_version_cmd)(wmi_unified_t wmi_handle, void *evt_buf);
Govind Singh71ee2d72016-03-07 16:30:32 +0530682
Govind Singhd7468a52016-03-09 14:32:57 +0530683QDF_STATUS (*check_and_update_fw_version_cmd)(wmi_unified_t wmi_hdl, void *ev);
Govind Singh71ee2d72016-03-07 16:30:32 +0530684
Govind Singhd7468a52016-03-09 14:32:57 +0530685QDF_STATUS (*send_saved_init_cmd)(wmi_unified_t wmi_handle);
Govind Singh2ae94372016-03-07 16:45:38 +0530686
Govind Singhd7468a52016-03-09 14:32:57 +0530687QDF_STATUS (*send_set_base_macaddr_indicate_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530688 uint8_t *custom_addr);
689
Govind Singhd7468a52016-03-09 14:32:57 +0530690QDF_STATUS (*send_log_supported_evt_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530691 uint8_t *event,
692 uint32_t len);
693
Govind Singhd7468a52016-03-09 14:32:57 +0530694QDF_STATUS (*send_enable_specific_fw_logs_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530695 struct wmi_wifi_start_log *start_log);
696
Govind Singhd7468a52016-03-09 14:32:57 +0530697QDF_STATUS (*send_flush_logs_to_fw_cmd)(wmi_unified_t wmi_handle);
Govind Singh2ae94372016-03-07 16:45:38 +0530698
Manishekar Chandrasekaranb8c59382016-04-21 19:16:32 +0530699QDF_STATUS (*send_pdev_set_pcl_cmd)(wmi_unified_t wmi_handle,
700 struct wmi_pcl_chan_weights *msg);
Govind Singh2ae94372016-03-07 16:45:38 +0530701
Manishekar Chandrasekaran68430d32016-04-27 12:29:16 +0530702QDF_STATUS (*send_pdev_set_hw_mode_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530703 uint32_t hw_mode_index);
704
Manishekar Chandrasekaran81d7aaa2016-04-27 12:52:51 +0530705QDF_STATUS (*send_pdev_set_dual_mac_config_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530706 struct wmi_dual_mac_config *msg);
707
Govind Singhd7468a52016-03-09 14:32:57 +0530708QDF_STATUS (*send_set_led_flashing_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530709 struct flashing_req_params *flashing);
710
Govind Singhd7468a52016-03-09 14:32:57 +0530711QDF_STATUS (*send_app_type1_params_in_fw_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530712 struct app_type1_params *app_type1_params);
713
Govind Singhd7468a52016-03-09 14:32:57 +0530714QDF_STATUS (*send_set_ssid_hotlist_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530715 struct ssid_hotlist_request_params *request);
716
Govind Singhd7468a52016-03-09 14:32:57 +0530717QDF_STATUS (*send_process_roam_synch_complete_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530718 uint8_t vdev_id);
719
Govind Singhd7468a52016-03-09 14:32:57 +0530720QDF_STATUS (*send_unit_test_cmd)(wmi_unified_t wmi_handle,
Anurag Chouhan4d41be72016-07-22 20:19:54 +0530721 struct wmi_unit_test_cmd *wmi_utest);
Govind Singh2ae94372016-03-07 16:45:38 +0530722
Govind Singhd7468a52016-03-09 14:32:57 +0530723QDF_STATUS (*send_roam_invoke_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530724 struct wmi_roam_invoke_cmd *roaminvoke,
725 uint32_t ch_hz);
726
Govind Singhd7468a52016-03-09 14:32:57 +0530727QDF_STATUS (*send_roam_scan_offload_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530728 uint32_t command, uint32_t vdev_id);
Govind Singh2ae94372016-03-07 16:45:38 +0530729
Govind Singhd7468a52016-03-09 14:32:57 +0530730QDF_STATUS (*send_roam_scan_offload_scan_period_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530731 uint32_t scan_period,
732 uint32_t scan_age,
733 uint32_t vdev_id);
734
Govind Singhd7468a52016-03-09 14:32:57 +0530735QDF_STATUS (*send_roam_scan_offload_chan_list_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530736 uint8_t chan_count,
Varun Reddy Yeturub47fa402016-07-07 17:42:49 -0700737 uint32_t *chan_list,
Govind Singh2ae94372016-03-07 16:45:38 +0530738 uint8_t list_type, uint32_t vdev_id);
739
Govind Singhd7468a52016-03-09 14:32:57 +0530740QDF_STATUS (*send_roam_scan_offload_rssi_change_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530741 uint32_t vdev_id,
742 int32_t rssi_change_thresh,
743 uint32_t bcn_rssi_weight,
744 uint32_t hirssi_delay_btw_scans);
745
Kapil Guptaf6eb7312017-02-24 15:50:03 +0530746QDF_STATUS (*send_per_roam_config_cmd)(wmi_unified_t wmi_handle,
747 struct wmi_per_roam_config_req *req_buf);
748
Govind Singhd7468a52016-03-09 14:32:57 +0530749QDF_STATUS (*send_get_buf_extscan_hotlist_cmd)(wmi_unified_t wmi_handle,
Govind Singh2ae94372016-03-07 16:45:38 +0530750 struct ext_scan_setbssi_hotlist_params *
751 photlist, int *buf_len);
Govind Singh89727882016-04-15 13:58:27 +0530752
Dustin Brown4def3162017-01-13 15:24:07 -0800753QDF_STATUS (*send_set_active_bpf_mode_cmd)(wmi_unified_t wmi_handle,
754 uint8_t vdev_id,
755 enum wmi_host_active_bpf_mode ucast_mode,
756 enum wmi_host_active_bpf_mode mcast_bcast_mode);
757
Govind Singh89727882016-04-15 13:58:27 +0530758QDF_STATUS (*send_pdev_get_tpc_config_cmd)(wmi_unified_t wmi_handle,
759 uint32_t param);
760
Sathish Kumar50232d72016-08-09 16:50:46 +0530761QDF_STATUS (*send_set_bwf_cmd)(wmi_unified_t wmi_handle,
762 struct set_bwf_params *param);
763
Govind Singh89727882016-04-15 13:58:27 +0530764QDF_STATUS (*send_set_atf_cmd)(wmi_unified_t wmi_handle,
765 struct set_atf_params *param);
766
767QDF_STATUS (*send_pdev_fips_cmd)(wmi_unified_t wmi_handle,
768 struct fips_params *param);
769
770QDF_STATUS (*send_wlan_profile_enable_cmd)(wmi_unified_t wmi_handle,
771 struct wlan_profile_params *param);
772
773QDF_STATUS (*send_wlan_profile_trigger_cmd)(wmi_unified_t wmi_handle,
774 struct wlan_profile_params *param);
775
776QDF_STATUS (*send_pdev_set_chan_cmd)(wmi_unified_t wmi_handle,
777 struct channel_param *param);
778
779QDF_STATUS (*send_set_ht_ie_cmd)(wmi_unified_t wmi_handle,
780 struct ht_ie_params *param);
781
782QDF_STATUS (*send_set_vht_ie_cmd)(wmi_unified_t wmi_handle,
783 struct vht_ie_params *param);
784
785QDF_STATUS (*send_wmm_update_cmd)(wmi_unified_t wmi_handle,
786 struct wmm_update_params *param);
787
788QDF_STATUS (*send_set_ant_switch_tbl_cmd)(wmi_unified_t wmi_handle,
789 struct ant_switch_tbl_params *param);
790
791QDF_STATUS (*send_set_ratepwr_table_cmd)(wmi_unified_t wmi_handle,
792 struct ratepwr_table_params *param);
793
794QDF_STATUS (*send_get_ratepwr_table_cmd)(wmi_unified_t wmi_handle);
795
796QDF_STATUS (*send_set_ctl_table_cmd)(wmi_unified_t wmi_handle,
797 struct ctl_table_params *param);
798
799QDF_STATUS (*send_set_mimogain_table_cmd)(wmi_unified_t wmi_handle,
800 struct mimogain_table_params *param);
801
802QDF_STATUS (*send_set_ratepwr_chainmsk_cmd)(wmi_unified_t wmi_handle,
803 struct ratepwr_chainmsk_params *param);
804
805QDF_STATUS (*send_set_macaddr_cmd)(wmi_unified_t wmi_handle,
806 struct macaddr_params *param);
807
808QDF_STATUS (*send_pdev_scan_start_cmd)(wmi_unified_t wmi_handle);
809
810QDF_STATUS (*send_pdev_scan_end_cmd)(wmi_unified_t wmi_handle);
811
812QDF_STATUS (*send_set_acparams_cmd)(wmi_unified_t wmi_handle,
813 struct acparams_params *param);
814
815QDF_STATUS (*send_set_vap_dscp_tid_map_cmd)(wmi_unified_t wmi_handle,
816 struct vap_dscp_tid_map_params *param);
817
818QDF_STATUS (*send_proxy_ast_reserve_cmd)(wmi_unified_t wmi_handle,
819 struct proxy_ast_reserve_params *param);
820
821QDF_STATUS (*send_pdev_qvit_cmd)(wmi_unified_t wmi_handle,
822 struct pdev_qvit_params *param);
823
824QDF_STATUS (*send_mcast_group_update_cmd)(wmi_unified_t wmi_handle,
825 struct mcast_group_update_params *param);
826
827QDF_STATUS (*send_peer_add_wds_entry_cmd)(wmi_unified_t wmi_handle,
828 struct peer_add_wds_entry_params *param);
829
830QDF_STATUS (*send_peer_del_wds_entry_cmd)(wmi_unified_t wmi_handle,
831 struct peer_del_wds_entry_params *param);
832
833QDF_STATUS (*send_peer_update_wds_entry_cmd)(wmi_unified_t wmi_handle,
834 struct peer_update_wds_entry_params *param);
835
836QDF_STATUS (*send_phyerr_enable_cmd)(wmi_unified_t wmi_handle);
837
838QDF_STATUS (*send_phyerr_disable_cmd)(wmi_unified_t wmi_handle);
839
840QDF_STATUS (*send_smart_ant_enable_cmd)(wmi_unified_t wmi_handle,
841 struct smart_ant_enable_params *param);
842
843QDF_STATUS (*send_smart_ant_set_rx_ant_cmd)(wmi_unified_t wmi_handle,
844 struct smart_ant_rx_ant_params *param);
845
846QDF_STATUS (*send_smart_ant_set_tx_ant_cmd)(wmi_unified_t wmi_handle,
847 uint8_t macaddr[IEEE80211_ADDR_LEN],
848 struct smart_ant_tx_ant_params *param);
849
850QDF_STATUS (*send_smart_ant_set_training_info_cmd)(wmi_unified_t wmi_handle,
851 uint8_t macaddr[IEEE80211_ADDR_LEN],
852 struct smart_ant_training_info_params *param);
853
854QDF_STATUS (*send_smart_ant_set_node_config_cmd)(wmi_unified_t wmi_handle,
855 uint8_t macaddr[IEEE80211_ADDR_LEN],
856 struct smart_ant_node_config_params *param);
857
858QDF_STATUS (*send_smart_ant_enable_tx_feedback_cmd)(wmi_unified_t wmi_handle,
859 struct smart_ant_enable_tx_feedback_params *param);
860
861QDF_STATUS (*send_vdev_spectral_configure_cmd)(wmi_unified_t wmi_handle,
862 struct vdev_spectral_configure_params *param);
863
864QDF_STATUS (*send_vdev_spectral_enable_cmd)(wmi_unified_t wmi_handle,
865 struct vdev_spectral_enable_params *param);
866
867QDF_STATUS (*send_bss_chan_info_request_cmd)(wmi_unified_t wmi_handle,
868 struct bss_chan_info_request_params *param);
869
870QDF_STATUS (*send_thermal_mitigation_param_cmd)(wmi_unified_t wmi_handle,
871 struct thermal_mitigation_params *param);
872
873QDF_STATUS (*send_vdev_set_neighbour_rx_cmd)(wmi_unified_t wmi_handle,
874 uint8_t macaddr[IEEE80211_ADDR_LEN],
875 struct set_neighbour_rx_params *param);
876
877QDF_STATUS (*send_vdev_set_fwtest_param_cmd)(wmi_unified_t wmi_handle,
878 struct set_fwtest_params *param);
879
880QDF_STATUS (*send_vdev_config_ratemask_cmd)(wmi_unified_t wmi_handle,
881 struct config_ratemask_params *param);
882
Govind Singh89727882016-04-15 13:58:27 +0530883
884QDF_STATUS (*send_wow_wakeup_cmd)(wmi_unified_t wmi_handle);
885
886QDF_STATUS (*send_wow_add_wakeup_event_cmd)(wmi_unified_t wmi_handle,
887 struct wow_add_wakeup_params *param);
888
889QDF_STATUS (*send_wow_add_wakeup_pattern_cmd)(wmi_unified_t wmi_handle,
890 struct wow_add_wakeup_pattern_params *param);
891
892QDF_STATUS (*send_wow_remove_wakeup_pattern_cmd)(wmi_unified_t wmi_handle,
893 struct wow_remove_wakeup_pattern_params *param);
894
895QDF_STATUS (*send_pdev_set_regdomain_cmd)(wmi_unified_t wmi_handle,
896 struct pdev_set_regdomain_params *param);
897
898QDF_STATUS (*send_set_quiet_mode_cmd)(wmi_unified_t wmi_handle,
899 struct set_quiet_mode_params *param);
900
901QDF_STATUS (*send_set_beacon_filter_cmd)(wmi_unified_t wmi_handle,
902 struct set_beacon_filter_params *param);
903
904QDF_STATUS (*send_remove_beacon_filter_cmd)(wmi_unified_t wmi_handle,
905 struct remove_beacon_filter_params *param);
906/*
907QDF_STATUS (*send_mgmt_cmd)(wmi_unified_t wmi_handle,
908 uint8_t macaddr[IEEE80211_ADDR_LEN],
909 struct mgmt_params *param);
910 */
911
912QDF_STATUS (*send_addba_clearresponse_cmd)(wmi_unified_t wmi_handle,
913 uint8_t macaddr[IEEE80211_ADDR_LEN],
914 struct addba_clearresponse_params *param);
915
916QDF_STATUS (*send_addba_send_cmd)(wmi_unified_t wmi_handle,
917 uint8_t macaddr[IEEE80211_ADDR_LEN],
918 struct addba_send_params *param);
919
920QDF_STATUS (*send_delba_send_cmd)(wmi_unified_t wmi_handle,
921 uint8_t macaddr[IEEE80211_ADDR_LEN],
922 struct delba_send_params *param);
923
924QDF_STATUS (*send_addba_setresponse_cmd)(wmi_unified_t wmi_handle,
925 uint8_t macaddr[IEEE80211_ADDR_LEN],
926 struct addba_setresponse_params *param);
927
928QDF_STATUS (*send_singleamsdu_cmd)(wmi_unified_t wmi_handle,
929 uint8_t macaddr[IEEE80211_ADDR_LEN],
930 struct singleamsdu_params *param);
931
932QDF_STATUS (*send_set_qboost_param_cmd)(wmi_unified_t wmi_handle,
933 uint8_t macaddr[IEEE80211_ADDR_LEN],
934 struct set_qboost_params *param);
935
936QDF_STATUS (*send_mu_scan_cmd)(wmi_unified_t wmi_handle,
937 struct mu_scan_params *param);
938
939QDF_STATUS (*send_lteu_config_cmd)(wmi_unified_t wmi_handle,
940 struct lteu_config_params *param);
941
942QDF_STATUS (*send_set_ps_mode_cmd)(wmi_unified_t wmi_handle,
943 struct set_ps_mode_params *param);
944void (*save_service_bitmap)(wmi_unified_t wmi_handle,
Rajeev Kumar5d8497b2017-02-12 02:12:17 -0800945 void *evt_buf, void *bitmap_buf);
Govind Singh89727882016-04-15 13:58:27 +0530946bool (*is_service_enabled)(wmi_unified_t wmi_handle,
947 uint32_t service_id);
948QDF_STATUS (*get_target_cap_from_service_ready)(wmi_unified_t wmi_handle,
Rajeev Kumar0b6b2852017-02-03 00:39:49 -0800949 void *evt_buf, struct wlan_psoc_target_capability_info *ev);
Govind Singh89727882016-04-15 13:58:27 +0530950
951QDF_STATUS (*extract_fw_version)(wmi_unified_t wmi_handle,
952 void *ev, struct wmi_host_fw_ver *fw_ver);
953
954QDF_STATUS (*extract_fw_abi_version)(wmi_unified_t wmi_handle,
955 void *ev, struct wmi_host_fw_abi_ver *fw_ver);
956
957QDF_STATUS (*extract_hal_reg_cap)(wmi_unified_t wmi_handle, void *evt_buf,
Rajeev Kumar0b6b2852017-02-03 00:39:49 -0800958 struct wlan_psoc_hal_reg_capability *hal_reg_cap);
Govind Singh89727882016-04-15 13:58:27 +0530959
960host_mem_req * (*extract_host_mem_req)(wmi_unified_t wmi_handle,
961 void *evt_buf, uint8_t *num_entries);
962
963QDF_STATUS (*init_cmd_send)(wmi_unified_t wmi_handle,
Kiran Venkatappaaf1dae32016-12-23 19:58:54 +0530964 struct wmi_init_cmd_param *param);
Govind Singh89727882016-04-15 13:58:27 +0530965
966QDF_STATUS (*save_fw_version)(wmi_unified_t wmi_handle, void *evt_buf);
967uint32_t (*ready_extract_init_status)(wmi_unified_t wmi_hdl, void *ev);
968QDF_STATUS (*ready_extract_mac_addr)(wmi_unified_t wmi_hdl, void *ev,
969 uint8_t *macaddr);
970QDF_STATUS (*check_and_update_fw_version)(wmi_unified_t wmi_hdl, void *ev);
971uint8_t* (*extract_dbglog_data_len)(wmi_unified_t wmi_handle, void *evt_buf,
Rajeev Kumar45fdf7f2017-01-25 12:46:21 -0800972 uint32_t *len);
Govind Singh89727882016-04-15 13:58:27 +0530973QDF_STATUS (*send_ext_resource_config)(wmi_unified_t wmi_handle,
974 wmi_host_ext_resource_config *ext_cfg);
975
976QDF_STATUS (*send_nf_dbr_dbm_info_get_cmd)(wmi_unified_t wmi_handle);
977
978QDF_STATUS (*send_packet_power_info_get_cmd)(wmi_unified_t wmi_handle,
979 struct packet_power_info_params *param);
980
981QDF_STATUS (*send_gpio_config_cmd)(wmi_unified_t wmi_handle,
982 struct gpio_config_params *param);
983
984QDF_STATUS (*send_gpio_output_cmd)(wmi_unified_t wmi_handle,
985 struct gpio_output_params *param);
986
987QDF_STATUS (*send_rtt_meas_req_test_cmd)(wmi_unified_t wmi_handle,
988 struct rtt_meas_req_test_params *param);
989
990QDF_STATUS (*send_rtt_meas_req_cmd)(wmi_unified_t wmi_handle,
991 struct rtt_meas_req_params *param);
992
993QDF_STATUS (*send_rtt_keepalive_req_cmd)(wmi_unified_t wmi_handle,
994 struct rtt_keepalive_req_params *param);
995
996QDF_STATUS (*send_lci_set_cmd)(wmi_unified_t wmi_handle,
997 struct lci_set_params *param);
998
999QDF_STATUS (*send_lcr_set_cmd)(wmi_unified_t wmi_handle,
1000 struct lcr_set_params *param);
1001
1002QDF_STATUS (*send_periodic_chan_stats_config_cmd)(wmi_unified_t wmi_handle,
1003 struct periodic_chan_stats_params *param);
1004
1005QDF_STATUS
1006(*send_atf_peer_request_cmd)(wmi_unified_t wmi_handle,
1007 struct atf_peer_request_params *param);
1008
1009QDF_STATUS
1010(*send_set_atf_grouping_cmd)(wmi_unified_t wmi_handle,
1011 struct atf_grouping_params *param);
1012
Sathish Kumar7e2eaed2016-11-14 17:44:29 +05301013QDF_STATUS (*send_get_user_position_cmd)(wmi_unified_t wmi_handle,
1014 uint32_t value);
1015
1016QDF_STATUS
1017(*send_reset_peer_mumimo_tx_count_cmd)(wmi_unified_t wmi_handle,
1018 uint32_t value);
1019
1020QDF_STATUS (*send_get_peer_mumimo_tx_count_cmd)(wmi_unified_t wmi_handle,
1021 uint32_t value);
1022
1023QDF_STATUS
1024(*send_pdev_caldata_version_check_cmd)(wmi_unified_t wmi_handle,
1025 uint32_t value);
1026
1027QDF_STATUS
Sathish Kumar7e566c52016-11-10 15:30:22 +05301028(*send_btcoex_wlan_priority_cmd)(wmi_unified_t wmi_handle,
1029 struct btcoex_cfg_params *param);
1030
1031QDF_STATUS
Kiran Kumar Lokerea7e488b2017-04-26 19:51:29 -07001032(*send_start_11d_scan_cmd)(wmi_unified_t wmi_handle,
1033 struct reg_start_11d_scan_req *param);
1034
1035QDF_STATUS
1036(*send_stop_11d_scan_cmd)(wmi_unified_t wmi_handle,
1037 struct reg_stop_11d_scan_req *param);
1038
1039QDF_STATUS
Sathish Kumar7e566c52016-11-10 15:30:22 +05301040(*send_btcoex_duty_cycle_cmd)(wmi_unified_t wmi_handle,
1041 struct btcoex_cfg_params *param);
Sathish Kumar7e2eaed2016-11-14 17:44:29 +05301042
Sathish Kumar612d0c22017-01-19 14:57:37 +05301043QDF_STATUS
1044(*send_coex_ver_cfg_cmd)(wmi_unified_t wmi_handle, coex_ver_cfg_t *param);
1045
Sathish Kumar125754e2017-04-24 11:36:00 +05301046QDF_STATUS
1047(*send_coex_config_cmd)(wmi_unified_t wmi_handle,
1048 struct coex_config_params *param);
1049
Govind Singh89727882016-04-15 13:58:27 +05301050QDF_STATUS (*extract_wds_addr_event)(wmi_unified_t wmi_handle,
1051 void *evt_buf, uint16_t len, wds_addr_event_t *wds_ev);
1052
1053QDF_STATUS (*extract_dcs_interference_type)(wmi_unified_t wmi_handle,
Kiran Venkatappa9b7a9592016-12-29 18:09:32 +05301054 void *evt_buf, struct wmi_host_dcs_interference_param *param);
Govind Singh89727882016-04-15 13:58:27 +05301055
1056QDF_STATUS (*extract_dcs_cw_int)(wmi_unified_t wmi_handle, void *evt_buf,
1057 wmi_host_ath_dcs_cw_int *cw_int);
1058
1059QDF_STATUS (*extract_dcs_im_tgt_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1060 wmi_host_dcs_im_tgt_stats_t *wlan_stat);
1061
Govind Singh89727882016-04-15 13:58:27 +05301062QDF_STATUS (*extract_fips_event_data)(wmi_unified_t wmi_handle,
Kiran Venkatappa9f5fcc02016-12-29 22:07:14 +05301063 void *evt_buf, struct wmi_host_fips_event_param *param);
1064
Govind Singh89727882016-04-15 13:58:27 +05301065QDF_STATUS (*extract_vdev_start_resp)(wmi_unified_t wmi_handle, void *evt_buf,
1066 wmi_host_vdev_start_resp *vdev_rsp);
1067
1068QDF_STATUS (*extract_tbttoffset_update_params)(void *wmi_hdl, void *evt_buf,
Sathish Kumar744fbf72017-05-17 18:05:15 +05301069 uint8_t idx, struct tbttoffset_params *tbtt_param);
1070
1071QDF_STATUS (*extract_ext_tbttoffset_update_params)(void *wmi_hdl, void *evt_buf,
1072 uint8_t idx, struct tbttoffset_params *tbtt_param);
1073
1074QDF_STATUS (*extract_tbttoffset_num_vdevs)(void *wmi_hdl, void *evt_buf,
1075 uint32_t *num_vdevs);
1076
1077QDF_STATUS (*extract_ext_tbttoffset_num_vdevs)(void *wmi_hdl, void *evt_buf,
1078 uint32_t *num_vdevs);
Govind Singh89727882016-04-15 13:58:27 +05301079
1080QDF_STATUS (*extract_mgmt_rx_params)(wmi_unified_t wmi_handle, void *evt_buf,
Himanshu Agarwal53d526b2017-01-05 14:23:18 +05301081 struct mgmt_rx_event_params *hdr, uint8_t **bufp);
Govind Singh89727882016-04-15 13:58:27 +05301082
1083QDF_STATUS (*extract_vdev_stopped_param)(wmi_unified_t wmi_handle,
1084 void *evt_buf, uint32_t *vdev_id);
1085
1086QDF_STATUS (*extract_vdev_roam_param)(wmi_unified_t wmi_handle, void *evt_buf,
1087 wmi_host_roam_event *param);
1088
1089QDF_STATUS (*extract_vdev_scan_ev_param)(wmi_unified_t wmi_handle,
Om Prakash Tripathi91452bf2017-02-25 15:53:30 +05301090 void *evt_buf, struct scan_event *param);
Govind Singh89727882016-04-15 13:58:27 +05301091
Frank Liu0ba573b2017-03-15 17:51:43 +08001092#ifdef CONVERGED_TDLS_ENABLE
1093QDF_STATUS (*extract_vdev_tdls_ev_param)(wmi_unified_t wmi_handle,
1094 void *evt_buf, struct tdls_event_info *param);
1095#endif
1096
Govind Singh89727882016-04-15 13:58:27 +05301097QDF_STATUS (*extract_mu_ev_param)(wmi_unified_t wmi_handle, void *evt_buf,
1098 wmi_host_mu_report_event *param);
1099
Sathish Kumar7e2eaed2016-11-14 17:44:29 +05301100QDF_STATUS (*extract_mu_db_entry)(wmi_unified_t wmi_hdl, void *evt_buf,
1101 uint8_t idx, wmi_host_mu_db_entry *param);
1102
1103QDF_STATUS (*extract_mumimo_tx_count_ev_param)(wmi_unified_t wmi_handle,
1104 void *evt_buf, wmi_host_peer_txmu_cnt_event *param);
1105
1106QDF_STATUS (*extract_peer_gid_userpos_list_ev_param)(wmi_unified_t wmi_handle,
1107 void *evt_buf, wmi_host_peer_gid_userpos_list_event *param);
1108
1109QDF_STATUS (*extract_pdev_caldata_version_check_ev_param)(
1110 wmi_unified_t wmi_handle,
1111 void *evt_buf, wmi_host_pdev_check_cal_version_event *param);
1112
Govind Singh89727882016-04-15 13:58:27 +05301113QDF_STATUS (*extract_pdev_tpc_config_ev_param)(wmi_unified_t wmi_handle,
1114 void *evt_buf, wmi_host_pdev_tpc_config_event *param);
1115
1116QDF_STATUS (*extract_gpio_input_ev_param)(wmi_unified_t wmi_handle,
1117 void *evt_buf, uint32_t *gpio_num);
1118
1119QDF_STATUS (*extract_pdev_reserve_ast_ev_param)(wmi_unified_t wmi_handle,
Kiran Venkatappa3f061a92017-02-08 14:57:16 +05301120 void *evt_buf, struct wmi_host_proxy_ast_reserve_param *param);
Govind Singh89727882016-04-15 13:58:27 +05301121
1122QDF_STATUS (*extract_nfcal_power_ev_param)(wmi_unified_t wmi_handle,
1123 void *evt_buf,
1124 wmi_host_pdev_nfcal_power_all_channels_event *param);
1125
1126QDF_STATUS (*extract_pdev_tpc_ev_param)(wmi_unified_t wmi_handle,
1127 void *evt_buf, wmi_host_pdev_tpc_event *param);
1128
1129QDF_STATUS (*extract_pdev_generic_buffer_ev_param)(wmi_unified_t wmi_handle,
1130 void *evt_buf, wmi_host_pdev_generic_buffer_event *param);
1131
1132QDF_STATUS (*extract_mgmt_tx_compl_param)(wmi_unified_t wmi_handle,
1133 void *evt_buf, wmi_host_mgmt_tx_compl_event *param);
1134
Kiran Venkatappa25c47022017-03-19 22:58:09 +05301135QDF_STATUS (*extract_offchan_data_tx_compl_param)(wmi_unified_t wmi_handle,
1136 void *evt_buf,
1137 struct wmi_host_offchan_data_tx_compl_event *param);
1138
Sathish Kumar907a7462017-02-27 10:35:40 +05301139QDF_STATUS (*extract_pdev_csa_switch_count_status)(wmi_unified_t wmi_handle,
1140 void *evt_buf, struct pdev_csa_switch_count_status *param);
1141
Sathish Kumar744fbf72017-05-17 18:05:15 +05301142QDF_STATUS (*extract_swba_num_vdevs)(wmi_unified_t wmi_handle, void *evt_buf,
1143 uint32_t *num_vdevs);
Govind Singh89727882016-04-15 13:58:27 +05301144
1145QDF_STATUS (*extract_swba_tim_info)(wmi_unified_t wmi_handle, void *evt_buf,
1146 uint32_t idx, wmi_host_tim_info *tim_info);
1147
1148QDF_STATUS (*extract_swba_noa_info)(wmi_unified_t wmi_handle, void *evt_buf,
1149 uint32_t idx, wmi_host_p2p_noa_info *p2p_desc);
1150
Wu Gao07ba6b42017-03-13 20:17:34 +08001151#ifdef CONVERGED_P2P_ENABLE
1152QDF_STATUS (*extract_p2p_lo_stop_ev_param)(wmi_unified_t wmi_handle,
1153 void *evt_buf, struct p2p_lo_event *param);
1154
1155QDF_STATUS (*extract_p2p_noa_ev_param)(wmi_unified_t wmi_handle,
1156 void *evt_buf, struct p2p_noa_info *param);
1157#endif
1158
Govind Singh89727882016-04-15 13:58:27 +05301159QDF_STATUS (*extract_peer_sta_ps_statechange_ev)(wmi_unified_t wmi_handle,
1160 void *evt_buf, wmi_host_peer_sta_ps_statechange_event *ev);
1161
1162QDF_STATUS (*extract_peer_sta_kickout_ev)(wmi_unified_t wmi_handle,
1163 void *evt_buf, wmi_host_peer_sta_kickout_event *ev);
1164
1165QDF_STATUS (*extract_peer_ratecode_list_ev)(wmi_unified_t wmi_handle,
1166 void *evt_buf, uint8_t *peer_mac, wmi_sa_rate_cap *rate_cap);
1167
1168QDF_STATUS (*extract_comb_phyerr)(wmi_unified_t wmi_handle, void *evt_buf,
1169 uint16_t datalen, uint16_t *buf_offset, wmi_host_phyerr_t *phyerr);
1170
1171QDF_STATUS (*extract_single_phyerr)(wmi_unified_t wmi_handle, void *evt_buf,
1172 uint16_t datalen, uint16_t *buf_offset, wmi_host_phyerr_t *phyerr);
1173
1174QDF_STATUS (*extract_composite_phyerr)(wmi_unified_t wmi_handle, void *evt_buf,
1175 uint16_t datalen, wmi_host_phyerr_t *phyerr);
1176
1177QDF_STATUS (*extract_rtt_hdr)(wmi_unified_t wmi_handle, void *evt_buf,
1178 wmi_host_rtt_event_hdr *ev);
1179
1180QDF_STATUS (*extract_rtt_ev)(wmi_unified_t wmi_handle, void *evt_buf,
1181 wmi_host_rtt_meas_event *ev, uint8_t *hdump, uint16_t hdump_len);
1182
1183QDF_STATUS (*extract_rtt_error_report_ev)(wmi_unified_t wmi_handle,
1184 void *evt_buf, wmi_host_rtt_error_report_event *ev);
1185
1186QDF_STATUS (*extract_all_stats_count)(wmi_unified_t wmi_handle, void *evt_buf,
1187 wmi_host_stats_event *stats_param);
1188
1189QDF_STATUS (*extract_pdev_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1190 uint32_t index, wmi_host_pdev_stats *pdev_stats);
1191
1192QDF_STATUS (*extract_pdev_ext_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1193 uint32_t index, wmi_host_pdev_ext_stats *pdev_ext_stats);
1194
1195QDF_STATUS (*extract_vdev_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1196 uint32_t index, wmi_host_vdev_stats *vdev_stats);
1197
1198QDF_STATUS (*extract_peer_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1199 uint32_t index, wmi_host_peer_stats *peer_stats);
1200
1201QDF_STATUS (*extract_bcnflt_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1202 uint32_t index, wmi_host_bcnflt_stats *bcnflt_stats);
1203
1204QDF_STATUS (*extract_peer_extd_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1205 uint32_t index, wmi_host_peer_extd_stats *peer_extd_stats);
1206
1207QDF_STATUS (*extract_chan_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1208 uint32_t index, wmi_host_chan_stats *chan_stats);
1209
1210QDF_STATUS (*extract_thermal_stats)(wmi_unified_t wmi_handle, void *evt_buf,
Om Prakash Tripathi2f54fbb2017-04-19 16:57:31 +05301211 uint32_t *temp, uint32_t *level, uint32_t *pdev_id);
Govind Singh89727882016-04-15 13:58:27 +05301212
1213QDF_STATUS (*extract_thermal_level_stats)(wmi_unified_t wmi_handle,
1214 void *evt_buf, uint8_t idx, uint32_t *levelcount,
1215 uint32_t *dccount);
1216
1217QDF_STATUS (*extract_profile_ctx)(wmi_unified_t wmi_handle, void *evt_buf,
1218 wmi_host_wlan_profile_ctx_t *profile_ctx);
1219
1220QDF_STATUS (*extract_profile_data)(wmi_unified_t wmi_handle, void *evt_buf,
Govind Singh41da3152016-05-06 20:20:25 +05301221 uint8_t idx,
1222 wmi_host_wlan_profile_t *profile_data);
Govind Singh89727882016-04-15 13:58:27 +05301223
1224QDF_STATUS (*extract_chan_info_event)(wmi_unified_t wmi_handle, void *evt_buf,
1225 wmi_host_chan_info_event *chan_info);
1226
1227QDF_STATUS (*extract_channel_hopping_event)(wmi_unified_t wmi_handle,
1228 void *evt_buf,
1229 wmi_host_pdev_channel_hopping_event *ch_hopping);
1230
1231QDF_STATUS (*extract_bss_chan_info_event)(wmi_unified_t wmi_handle,
1232 void *evt_buf,
1233 wmi_host_pdev_bss_chan_info_event *bss_chan_info);
1234
1235QDF_STATUS (*extract_inst_rssi_stats_event)(wmi_unified_t wmi_handle,
1236 void *evt_buf, wmi_host_inst_stats_resp *inst_rssi_resp);
1237
1238QDF_STATUS (*extract_tx_data_traffic_ctrl_ev)(wmi_unified_t wmi_handle,
1239 void *evt_buf, wmi_host_tx_data_traffic_ctrl_event *ev);
1240
Sathish Kumar7e2eaed2016-11-14 17:44:29 +05301241QDF_STATUS (*extract_atf_peer_stats_ev)(wmi_unified_t wmi_handle,
1242 void *evt_buf, wmi_host_atf_peer_stats_event *ev);
1243
1244QDF_STATUS (*extract_atf_token_info_ev)(wmi_unified_t wmi_handle,
1245 void *evt_buf,
1246 uint8_t idx,
1247 wmi_host_atf_peer_stats_info *atf_token_info);
1248
Govind Singh89727882016-04-15 13:58:27 +05301249QDF_STATUS (*extract_vdev_extd_stats)(wmi_unified_t wmi_handle, void *evt_buf,
1250 uint32_t index, wmi_host_vdev_extd_stats *vdev_extd_stats);
Govind Singhc10bde82016-05-02 17:59:24 +05301251
1252QDF_STATUS (*send_power_dbg_cmd)(wmi_unified_t wmi_handle,
1253 struct wmi_power_dbg_params *param);
Gupta, Kapil7b768002016-04-25 19:14:19 +05301254
Sathish Kumar907a7462017-02-27 10:35:40 +05301255QDF_STATUS (*send_multiple_vdev_restart_req_cmd)(wmi_unified_t wmi_handle,
1256 struct multiple_vdev_restart_params *param);
1257
Gupta, Kapil7b768002016-04-25 19:14:19 +05301258QDF_STATUS (*send_adapt_dwelltime_params_cmd)(wmi_unified_t wmi_handle,
1259 struct wmi_adaptive_dwelltime_params *dwelltime_params);
Anurag Chouhan4d41be72016-07-22 20:19:54 +05301260
Nitesh Shahfb9e88b2017-05-22 15:49:00 +05301261QDF_STATUS (*send_dbs_scan_sel_params_cmd)(wmi_unified_t wmi_handle,
1262 struct wmi_dbs_scan_sel_params *dbs_scan_params);
1263
Anurag Chouhan4d41be72016-07-22 20:19:54 +05301264QDF_STATUS (*send_fw_test_cmd)(wmi_unified_t wmi_handle,
1265 struct set_fwtest_params *wmi_fwtest);
Padma, Santhosh Kumar73524052016-09-11 18:24:59 +05301266
1267QDF_STATUS (*send_encrypt_decrypt_send_cmd)(wmi_unified_t wmi_handle,
1268 struct encrypt_decrypt_req_params *params);
Leo Chang8184e9c2016-09-28 13:43:36 -07001269
Manikandan Mohan7e5ad482016-12-13 13:14:06 -08001270QDF_STATUS (*send_sar_limit_cmd)(wmi_unified_t wmi_handle,
1271 struct sar_limit_cmd_params *params);
1272
Leo Chang8184e9c2016-09-28 13:43:36 -07001273QDF_STATUS (*send_peer_rx_reorder_queue_setup_cmd)(wmi_unified_t wmi_handle,
1274 struct rx_reorder_queue_setup_params *param);
1275
1276QDF_STATUS (*send_peer_rx_reorder_queue_remove_cmd)(wmi_unified_t wmi_handle,
1277 struct rx_reorder_queue_remove_params *param);
Kiran Venkatappa9c71b362016-08-10 23:55:40 +05301278
1279QDF_STATUS (*extract_service_ready_ext)(wmi_unified_t wmi_handle,
1280 uint8_t *evt_buf,
Rajeev Kumar0b6b2852017-02-03 00:39:49 -08001281 struct wlan_psoc_host_service_ext_param *param);
Kiran Venkatappa9c71b362016-08-10 23:55:40 +05301282
1283QDF_STATUS (*extract_hw_mode_cap_service_ready_ext)(
1284 wmi_unified_t wmi_handle,
1285 uint8_t *evt_buf, uint8_t hw_mode_idx,
Rajeev Kumar0b6b2852017-02-03 00:39:49 -08001286 struct wlan_psoc_host_hw_mode_caps *param);
Kiran Venkatappa9c71b362016-08-10 23:55:40 +05301287
1288QDF_STATUS (*extract_mac_phy_cap_service_ready_ext)(
1289 wmi_unified_t wmi_handle,
Kiran Venkatappa176fe6c2016-12-26 15:38:06 +05301290 uint8_t *evt_buf,
1291 uint8_t hw_mode_id,
1292 uint8_t phy_id,
Rajeev Kumar0b6b2852017-02-03 00:39:49 -08001293 struct wlan_psoc_host_mac_phy_caps *param);
Kiran Venkatappa9c71b362016-08-10 23:55:40 +05301294
1295QDF_STATUS (*extract_reg_cap_service_ready_ext)(
1296 wmi_unified_t wmi_handle,
1297 uint8_t *evt_buf, uint8_t phy_idx,
Rajeev Kumar0b6b2852017-02-03 00:39:49 -08001298 struct wlan_psoc_host_hal_reg_capabilities_ext *param);
Sathish Kumar617535c2017-01-24 17:51:26 +05301299
1300QDF_STATUS (*extract_pdev_utf_event)(wmi_unified_t wmi_hdl,
1301 uint8_t *evt_buf,
1302 struct wmi_host_pdev_utf_event *param);
1303
Kiran Venkatappa3d514982017-02-28 14:19:17 +05301304QDF_STATUS (*extract_pdev_qvit_event)(wmi_unified_t wmi_hdl,
1305 uint8_t *evt_buf,
1306 struct wmi_host_pdev_qvit_event *param);
1307
Sarada Prasanna Garnayakd49444c2017-01-05 19:30:07 +05301308uint16_t (*wmi_set_htc_tx_tag)(wmi_unified_t wmi_handle,
1309 wmi_buf_t buf, uint32_t cmd_id);
Vijay Pamidipatiadd0ba72017-01-17 12:53:05 +05301310
1311QDF_STATUS (*extract_peer_delete_response_event)(
1312 wmi_unified_t wmi_handle,
1313 void *evt_buf,
1314 struct wmi_host_peer_delete_response_event *param);
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301315
1316bool (*is_management_record)(uint32_t cmd_id);
1317uint8_t *(*wmi_id_to_name)(uint32_t cmd_id);
Arif Hussain85604fb2017-01-07 18:21:55 -08001318QDF_STATUS (*send_dfs_phyerr_offload_en_cmd)(wmi_unified_t wmi_handle,
1319 uint32_t pdev_id);
1320QDF_STATUS (*send_dfs_phyerr_offload_dis_cmd)(wmi_unified_t wmi_handle,
1321 uint32_t pdev_id);
Baila, Shashikala Prabhu6bad1972017-03-17 10:21:14 +05301322QDF_STATUS (*extract_reg_chan_list_update_event)(wmi_unified_t wmi_handle,
1323 uint8_t *evt_buf,
1324 struct cur_regulatory_info
1325 *reg_info,
1326 uint32_t len);
Kiran Kumar Lokerea7e488b2017-04-26 19:51:29 -07001327
1328QDF_STATUS (*extract_reg_11d_new_country_event)(wmi_unified_t wmi_handle,
1329 uint8_t *evt_buf,
1330 struct reg_11d_new_country *reg_11d_country,
1331 uint32_t len);
1332
Vikram Kandukuric83feb62017-03-07 18:40:13 +05301333QDF_STATUS (*extract_chainmask_tables)(wmi_unified_t wmi_handle,
1334 uint8_t *evt_buf,
1335 struct wlan_psoc_host_chainmask_table *chainmask_table);
Arif Hussaine542fe12017-04-09 01:03:19 -07001336
1337#ifdef DFS_COMPONENT_ENABLE
1338QDF_STATUS (*extract_dfs_cac_complete_event)(wmi_unified_t wmi_handle,
1339 uint8_t *evt_buf,
1340 uint32_t *vdev_id,
1341 uint32_t len);
1342QDF_STATUS (*extract_dfs_radar_detection_event)(wmi_unified_t wmi_handle,
1343 uint8_t *evt_buf,
1344 struct radar_found_info *radar_found,
1345 uint32_t len);
1346#endif
Kiran Kumar Lokeree70e6052017-04-24 00:56:03 -07001347QDF_STATUS (*send_set_country_cmd)(wmi_unified_t wmi_handle,
1348 struct set_country *param);
Kiran Venkatappa49341042017-05-10 16:24:51 +05301349
1350uint32_t (*convert_pdev_id_host_to_target)(uint32_t pdev_id);
1351uint32_t (*convert_pdev_id_target_to_host)(uint32_t pdev_id);
1352
Govind Singh89727882016-04-15 13:58:27 +05301353};
1354
1355struct target_abi_version {
1356 A_UINT32 abi_version_0;
1357 /** WMI Major and Minor versions */
1358 A_UINT32 abi_version_1;
1359 /** WMI change revision */
1360 A_UINT32 abi_version_ns_0;
1361 /** ABI version namespace first four dwords */
1362 A_UINT32 abi_version_ns_1;
1363 /** ABI version namespace second four dwords */
1364 A_UINT32 abi_version_ns_2;
1365 /** ABI version namespace third four dwords */
1366 A_UINT32 abi_version_ns_3;
1367 /** ABI version namespace fourth four dwords */
Govind Singh2ae94372016-03-07 16:45:38 +05301368};
1369
Mukul Sharma36d159b2017-01-30 19:55:40 +05301370/* Forward declartion for psoc*/
1371struct wlan_objmgr_psoc;
1372
Govind Singh229bc0d2016-03-07 15:33:31 +05301373/**
1374 * struct wmi_init_cmd - Saved wmi INIT command
1375 * @buf: Buffer containing the wmi INIT command
1376 * @buf_len: Length of the buffer
1377 */
Govind Singhec0bdef2016-03-16 16:27:50 +05301378struct wmi_cmd_init {
Govind Singh229bc0d2016-03-07 15:33:31 +05301379 wmi_buf_t buf;
1380 uint32_t buf_len;
Govind Singh3ddda1f2016-03-09 11:34:12 +05301381};
1382
Govind Singhd475ea92016-03-06 19:55:02 +05301383struct wmi_unified {
Govind Singh89727882016-04-15 13:58:27 +05301384 void *scn_handle; /* handle to device */
Govind Singh6ad6ada2016-02-04 18:42:30 +05301385 osdev_t osdev; /* handle to use OS-independent services */
Govind Singhd7468a52016-03-09 14:32:57 +05301386 qdf_atomic_t pending_cmds;
Govind Singhd475ea92016-03-06 19:55:02 +05301387 HTC_ENDPOINT_ID wmi_endpoint_id;
1388 uint16_t max_msg_len;
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301389 uint32_t *event_id;
1390 wmi_unified_event_handler *event_handler;
1391 enum wmi_rx_exec_ctx *ctx;
Govind Singhd475ea92016-03-06 19:55:02 +05301392 void *htc_handle;
Govind Singhd7468a52016-03-09 14:32:57 +05301393 qdf_spinlock_t eventq_lock;
1394 qdf_nbuf_queue_t event_queue;
Rajeev Kumara0f4e932017-03-29 17:14:14 -07001395 qdf_work_t rx_event_work;
1396 qdf_workqueue_t *wmi_rx_work_queue;
Govind Singh6ad6ada2016-02-04 18:42:30 +05301397 int wmi_stop_in_progress;
Kiran Venkatappa9da7e042016-08-09 22:52:35 +05301398#ifdef CONFIG_MCL
Govind Singh229bc0d2016-03-07 15:33:31 +05301399 struct _wmi_abi_version fw_abi_version;
1400 struct _wmi_abi_version final_abi_vers;
Govind Singh89727882016-04-15 13:58:27 +05301401#endif
Govind Singhec0bdef2016-03-16 16:27:50 +05301402 struct wmi_cmd_init saved_wmi_init_cmd;
Govind Singh229bc0d2016-03-07 15:33:31 +05301403 uint32_t num_of_diag_events_logs;
1404 uint32_t *events_logs_list;
Govind Singhd475ea92016-03-06 19:55:02 +05301405#ifdef WLAN_OPEN_SOURCE
1406 struct fwdebug dbglog;
1407 struct dentry *debugfs_phy;
1408#endif /* WLAN_OPEN_SOURCE */
1409
1410#ifdef WMI_INTERFACE_EVENT_LOGGING
Govind Singh5fed03b2016-05-12 12:45:51 +05301411 struct wmi_debug_log_info log_info;
Govind Singhd475ea92016-03-06 19:55:02 +05301412#endif /*WMI_INTERFACE_EVENT_LOGGING */
1413
Govind Singhd7468a52016-03-09 14:32:57 +05301414 qdf_atomic_t is_target_suspended;
Govind Singhd475ea92016-03-06 19:55:02 +05301415
1416#ifdef FEATURE_RUNTIME_PM
Govind Singhd7468a52016-03-09 14:32:57 +05301417 qdf_atomic_t runtime_pm_inprogress;
Govind Singhd475ea92016-03-06 19:55:02 +05301418#endif
Sarada Prasanna Garnayakd49444c2017-01-05 19:30:07 +05301419 qdf_atomic_t is_wow_bus_suspended;
1420 bool tag_crash_inject;
Govind Singh89727882016-04-15 13:58:27 +05301421 enum wmi_target_type target_type;
Govind Singh3ddda1f2016-03-09 11:34:12 +05301422 struct wmi_rx_ops rx_ops;
1423 struct wmi_ops *ops;
Govind Singh6ad6ada2016-02-04 18:42:30 +05301424 bool use_cookie;
Govind Singh89727882016-04-15 13:58:27 +05301425 bool wmi_stopinprogress;
Soumya Bhat49a84812017-03-22 14:41:01 +05301426 uint32_t *wmi_events;
Kiran Venkatappa9da7e042016-08-09 22:52:35 +05301427#ifndef CONFIG_MCL
Govind Singh89727882016-04-15 13:58:27 +05301428 /* WMI service bitmap recieved from target */
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301429 uint32_t *wmi_service_bitmap;
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301430 uint32_t *pdev_param;
1431 uint32_t *vdev_param;
1432 uint32_t *services;
1433#endif
1434 struct wmi_soc *soc;
1435};
1436
1437#define WMI_MAX_RADIOS 3
1438struct wmi_soc {
1439 struct wlan_objmgr_psoc *wmi_psoc;
1440 void *scn_handle; /* handle to device */
1441 qdf_atomic_t num_pdevs;
1442 enum wmi_target_type target_type;
1443 void *htc_handle;
1444 uint32_t event_id[WMI_UNIFIED_MAX_EVENT];
1445 wmi_unified_event_handler event_handler[WMI_UNIFIED_MAX_EVENT];
Kiran Venkatappa129bd1a2017-03-20 20:38:44 +05301446 uint32_t max_event_idx;
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301447 enum wmi_rx_exec_ctx ctx[WMI_UNIFIED_MAX_EVENT];
Kiran Venkatappa129bd1a2017-03-20 20:38:44 +05301448 qdf_spinlock_t ctx_lock;
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301449 struct wmi_unified *wmi_pdev[WMI_MAX_RADIOS];
1450 HTC_ENDPOINT_ID wmi_endpoint_id[WMI_MAX_RADIOS];
1451 uint16_t max_msg_len[WMI_MAX_RADIOS];
1452 struct wmi_ops *ops;
Soumya Bhat49a84812017-03-22 14:41:01 +05301453 uint32_t wmi_events[wmi_events_max];
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301454#ifndef CONFIG_MCL
1455 /* WMI service bitmap recieved from target */
Govind Singh89727882016-04-15 13:58:27 +05301456 uint32_t wmi_service_bitmap[wmi_services_max];
Govind Singh89727882016-04-15 13:58:27 +05301457 uint32_t pdev_param[wmi_pdev_param_max];
1458 uint32_t vdev_param[wmi_vdev_param_max];
1459 uint32_t services[wmi_services_max];
1460#endif
Govind Singhd475ea92016-03-06 19:55:02 +05301461};
Kiran Venkatappa929dd292017-02-10 16:57:59 +05301462
Govind Singh89727882016-04-15 13:58:27 +05301463#ifdef WMI_NON_TLV_SUPPORT
Govind Singhfa201d92016-06-08 19:40:11 +05301464/* ONLY_NON_TLV_TARGET:TLV attach dummy function defintion for case when
1465 * driver supports only NON-TLV target (WIN mainline) */
Govind Singh89727882016-04-15 13:58:27 +05301466#define wmi_tlv_attach(x) qdf_print("TLV Unavailable\n")
Kiran Venkatappa49341042017-05-10 16:24:51 +05301467#define wmi_tlv_pdev_id_conversion_enable(wmi_hdl) \
1468 qdf_print("PDEV conversion Not Available")
Govind Singh89727882016-04-15 13:58:27 +05301469#else
1470void wmi_tlv_attach(wmi_unified_t wmi_handle);
Kiran Venkatappa49341042017-05-10 16:24:51 +05301471void wmi_tlv_pdev_id_conversion_enable(wmi_unified_t wmi_handle);
Govind Singh89727882016-04-15 13:58:27 +05301472#endif
1473void wmi_non_tlv_attach(wmi_unified_t wmi_handle);
Govind Singh53c7ac82016-03-28 22:02:42 +05301474
1475/**
1476 * wmi_align() - provides word aligned parameter
1477 * @param: parameter to be aligned
1478 *
1479 * Return: word aligned parameter
1480 */
1481static inline uint32_t wmi_align(uint32_t param)
1482{
1483 return roundup(param, sizeof(uint32_t));
1484}
Sathish Kumar744fbf72017-05-17 18:05:15 +05301485
1486/**
1487 * wmi_vdev_map_to_vdev_id() - Provides vdev id corresponding to idx
1488 * from vdev map
1489 * @vdev_map: Bitmask containing information of active vdev ids
1490 * @idx: Index referring to the i'th bit set from LSB in vdev map
1491 *
1492 * This API returns the vdev id for the i'th bit set from LSB in vdev map.
1493 * Index runs through 1 from maximum number of vdevs set in the vdev map
1494 *
1495 * Return: vdev id of the vdev object
1496 */
1497static inline uint32_t wmi_vdev_map_to_vdev_id(uint32_t vdev_map,
1498 uint32_t idx)
1499{
1500 uint32_t vdev_count = 0, vdev_set = 0, vdev_id = WLAN_INVALID_VDEV_ID;
1501
1502 while (vdev_map) {
1503 vdev_set += (vdev_map & 0x1);
1504 if (vdev_set == (idx+1)) {
1505 vdev_id = vdev_count;
1506 break;
1507 }
1508 vdev_map >>= 1;
1509 vdev_count++;
1510 }
1511
1512 return vdev_id;
1513}
1514
1515/**
1516 * wmi_vdev_map_to_num_vdevs() - Provides number of vdevs active based on the
1517 * vdev map received from FW
1518 * @vdev_map: Bitmask containing information of active vdev ids
1519 *
1520 * Return: Number of vdevs set in the vdev bit mask
1521 */
1522static inline uint32_t wmi_vdev_map_to_num_vdevs(uint32_t vdev_map)
1523{
1524 uint32_t num_vdevs = 0;
1525
1526 while (vdev_map) {
1527 num_vdevs += (vdev_map & 0x1);
1528 vdev_map >>= 1;
1529 }
1530
1531 return num_vdevs;
1532}
Govind Singhd475ea92016-03-06 19:55:02 +05301533#endif