1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30 #ifndef __WILOCITY_WMI_H__
31 #define __WILOCITY_WMI_H__
32
33 #define WMI_DEFAULT_ASSOC_STA (1)
34 #define WMI_MAC_LEN (6)
35 #define WMI_PROX_RANGE_NUM (3)
36 #define WMI_MAX_LOSS_DMG_BEACONS (20)
37 #define MAX_NUM_OF_SECTORS (128)
38 #define WMI_INVALID_TEMPERATURE (0xFFFFFFFF)
39 #define WMI_SCHED_MAX_ALLOCS_PER_CMD (4)
40 #define WMI_RF_DTYPE_LENGTH (3)
41 #define WMI_RF_ETYPE_LENGTH (3)
42 #define WMI_RF_RX2TX_LENGTH (3)
43 #define WMI_RF_ETYPE_VAL_PER_RANGE (5)
44
45
46
47 #define WMI_RF_DTYPE_CONF_LENGTH (4)
48
49
50
51
52 #define WMI_RF_ETYPE_CONF_LENGTH (8)
53
54
55
56 #define WMI_RF_RX2TX_CONF_LENGTH (4)
57
58 #define WMI_QOS_NUM_OF_PRIORITY (4)
59 #define WMI_QOS_MIN_DEFAULT_WEIGHT (10)
60 #define WMI_QOS_VRING_SLOT_MIN_MS (2)
61 #define WMI_QOS_VRING_SLOT_MAX_MS (10)
62
63
64
65 #define WMI_QOS_MAX_WEIGHT 50
66 #define WMI_QOS_SET_VIF_PRIORITY (0xFF)
67 #define WMI_QOS_DEFAULT_PRIORITY (WMI_QOS_NUM_OF_PRIORITY)
68 #define WMI_MAX_XIF_PORTS_NUM (8)
69
70
71
72
73 enum wmi_mid {
74 MID_DEFAULT = 0x00,
75 FIRST_DBG_MID_ID = 0x10,
76 LAST_DBG_MID_ID = 0xFE,
77 MID_BROADCAST = 0xFF,
78 };
79
80
81
82
83
84 enum wmi_fw_capability {
85 WMI_FW_CAPABILITY_FTM = 0,
86 WMI_FW_CAPABILITY_PS_CONFIG = 1,
87 WMI_FW_CAPABILITY_RF_SECTORS = 2,
88 WMI_FW_CAPABILITY_MGMT_RETRY_LIMIT = 3,
89 WMI_FW_CAPABILITY_AP_SME_OFFLOAD_PARTIAL = 4,
90 WMI_FW_CAPABILITY_WMI_ONLY = 5,
91 WMI_FW_CAPABILITY_THERMAL_THROTTLING = 7,
92 WMI_FW_CAPABILITY_D3_SUSPEND = 8,
93 WMI_FW_CAPABILITY_LONG_RANGE = 9,
94 WMI_FW_CAPABILITY_FIXED_SCHEDULING = 10,
95 WMI_FW_CAPABILITY_MULTI_DIRECTED_OMNIS = 11,
96 WMI_FW_CAPABILITY_RSSI_REPORTING = 12,
97 WMI_FW_CAPABILITY_SET_SILENT_RSSI_TABLE = 13,
98 WMI_FW_CAPABILITY_LO_POWER_CALIB_FROM_OTP = 14,
99 WMI_FW_CAPABILITY_PNO = 15,
100 WMI_FW_CAPABILITY_CHANNEL_BONDING = 17,
101 WMI_FW_CAPABILITY_REF_CLOCK_CONTROL = 18,
102 WMI_FW_CAPABILITY_AP_SME_OFFLOAD_NONE = 19,
103 WMI_FW_CAPABILITY_MULTI_VIFS = 20,
104 WMI_FW_CAPABILITY_FT_ROAMING = 21,
105 WMI_FW_CAPABILITY_BACK_WIN_SIZE_64 = 22,
106 WMI_FW_CAPABILITY_AMSDU = 23,
107 WMI_FW_CAPABILITY_RAW_MODE = 24,
108 WMI_FW_CAPABILITY_TX_REQ_EXT = 25,
109 WMI_FW_CAPABILITY_CHANNEL_4 = 26,
110 WMI_FW_CAPABILITY_IPA = 27,
111 WMI_FW_CAPABILITY_TEMPERATURE_ALL_RF = 30,
112 WMI_FW_CAPABILITY_SPLIT_REKEY = 31,
113 WMI_FW_CAPABILITY_MAX,
114 };
115
116
117 struct wmi_cmd_hdr {
118 u8 mid;
119 u8 reserved;
120 __le16 command_id;
121 __le32 fw_timestamp;
122 } __packed;
123
124
125 enum wmi_command_id {
126 WMI_CONNECT_CMDID = 0x01,
127 WMI_DISCONNECT_CMDID = 0x03,
128 WMI_DISCONNECT_STA_CMDID = 0x04,
129 WMI_START_SCHED_SCAN_CMDID = 0x05,
130 WMI_STOP_SCHED_SCAN_CMDID = 0x06,
131 WMI_START_SCAN_CMDID = 0x07,
132 WMI_SET_BSS_FILTER_CMDID = 0x09,
133 WMI_SET_PROBED_SSID_CMDID = 0x0A,
134
135 WMI_SET_LISTEN_INT_CMDID = 0x0B,
136 WMI_FT_AUTH_CMDID = 0x0C,
137 WMI_FT_REASSOC_CMDID = 0x0D,
138 WMI_UPDATE_FT_IES_CMDID = 0x0E,
139 WMI_BCON_CTRL_CMDID = 0x0F,
140 WMI_ADD_CIPHER_KEY_CMDID = 0x16,
141 WMI_DELETE_CIPHER_KEY_CMDID = 0x17,
142 WMI_PCP_CONF_CMDID = 0x18,
143 WMI_SET_APPIE_CMDID = 0x3F,
144 WMI_SET_WSC_STATUS_CMDID = 0x41,
145 WMI_PXMT_RANGE_CFG_CMDID = 0x42,
146 WMI_PXMT_SNR2_RANGE_CFG_CMDID = 0x43,
147 WMI_RADAR_GENERAL_CONFIG_CMDID = 0x100,
148 WMI_RADAR_CONFIG_SELECT_CMDID = 0x101,
149 WMI_RADAR_PARAMS_CONFIG_CMDID = 0x102,
150 WMI_RADAR_SET_MODE_CMDID = 0x103,
151 WMI_RADAR_CONTROL_CMDID = 0x104,
152 WMI_RADAR_PCI_CONTROL_CMDID = 0x105,
153 WMI_MEM_READ_CMDID = 0x800,
154 WMI_MEM_WR_CMDID = 0x801,
155 WMI_ECHO_CMDID = 0x803,
156 WMI_DEEP_ECHO_CMDID = 0x804,
157 WMI_CONFIG_MAC_CMDID = 0x805,
158
159 WMI_CONFIG_PHY_DEBUG_CMDID = 0x806,
160 WMI_ADD_DEBUG_TX_PCKT_CMDID = 0x808,
161 WMI_PHY_GET_STATISTICS_CMDID = 0x809,
162
163 WMI_FS_TUNE_CMDID = 0x80A,
164
165 WMI_CORR_MEASURE_CMDID = 0x80B,
166 WMI_READ_RSSI_CMDID = 0x80C,
167 WMI_TEMP_SENSE_CMDID = 0x80E,
168 WMI_DC_CALIB_CMDID = 0x80F,
169
170 WMI_SEND_TONE_CMDID = 0x810,
171
172 WMI_IQ_TX_CALIB_CMDID = 0x811,
173
174 WMI_IQ_RX_CALIB_CMDID = 0x812,
175 WMI_SET_WORK_MODE_CMDID = 0x815,
176 WMI_LO_LEAKAGE_CALIB_CMDID = 0x816,
177 WMI_LO_POWER_CALIB_FROM_OTP_CMDID = 0x817,
178 WMI_SILENT_RSSI_CALIB_CMDID = 0x81D,
179
180 WMI_RF_RX_TEST_CMDID = 0x81E,
181 WMI_CFG_RX_CHAIN_CMDID = 0x820,
182 WMI_VRING_CFG_CMDID = 0x821,
183 WMI_BCAST_VRING_CFG_CMDID = 0x822,
184 WMI_RING_BA_EN_CMDID = 0x823,
185 WMI_RING_BA_DIS_CMDID = 0x824,
186 WMI_RCP_ADDBA_RESP_CMDID = 0x825,
187 WMI_RCP_DELBA_CMDID = 0x826,
188 WMI_SET_SSID_CMDID = 0x827,
189 WMI_GET_SSID_CMDID = 0x828,
190 WMI_SET_PCP_CHANNEL_CMDID = 0x829,
191 WMI_GET_PCP_CHANNEL_CMDID = 0x82A,
192 WMI_SW_TX_REQ_CMDID = 0x82B,
193
194
195
196 WMI_SW_TX_REQ_EXT_CMDID = 0x82C,
197 WMI_MLME_PUSH_CMDID = 0x835,
198 WMI_BEAMFORMING_MGMT_CMDID = 0x836,
199 WMI_BF_TXSS_MGMT_CMDID = 0x837,
200 WMI_BF_SM_MGMT_CMDID = 0x838,
201 WMI_BF_RXSS_MGMT_CMDID = 0x839,
202 WMI_BF_TRIG_CMDID = 0x83A,
203 WMI_RCP_ADDBA_RESP_EDMA_CMDID = 0x83B,
204 WMI_LINK_MAINTAIN_CFG_WRITE_CMDID = 0x842,
205 WMI_LINK_MAINTAIN_CFG_READ_CMDID = 0x843,
206 WMI_SET_SECTORS_CMDID = 0x849,
207 WMI_MAINTAIN_PAUSE_CMDID = 0x850,
208 WMI_MAINTAIN_RESUME_CMDID = 0x851,
209 WMI_RS_MGMT_CMDID = 0x852,
210 WMI_RF_MGMT_CMDID = 0x853,
211 WMI_RF_XPM_READ_CMDID = 0x856,
212 WMI_RF_XPM_WRITE_CMDID = 0x857,
213 WMI_LED_CFG_CMDID = 0x858,
214 WMI_SET_CONNECT_SNR_THR_CMDID = 0x85B,
215 WMI_SET_ACTIVE_SILENT_RSSI_TABLE_CMDID = 0x85C,
216 WMI_RF_PWR_ON_DELAY_CMDID = 0x85D,
217 WMI_SET_HIGH_POWER_TABLE_PARAMS_CMDID = 0x85E,
218 WMI_FIXED_SCHEDULING_UL_CONFIG_CMDID = 0x85F,
219
220 WMI_BF_CTRL_CMDID = 0x862,
221 WMI_NOTIFY_REQ_CMDID = 0x863,
222 WMI_GET_STATUS_CMDID = 0x864,
223 WMI_GET_RF_STATUS_CMDID = 0x866,
224 WMI_GET_BASEBAND_TYPE_CMDID = 0x867,
225 WMI_VRING_SWITCH_TIMING_CONFIG_CMDID = 0x868,
226 WMI_UNIT_TEST_CMDID = 0x900,
227 WMI_FLASH_READ_CMDID = 0x902,
228 WMI_FLASH_WRITE_CMDID = 0x903,
229
230 WMI_TRAFFIC_SUSPEND_CMDID = 0x904,
231 WMI_TRAFFIC_RESUME_CMDID = 0x905,
232
233 WMI_P2P_CFG_CMDID = 0x910,
234 WMI_PORT_ALLOCATE_CMDID = 0x911,
235 WMI_PORT_DELETE_CMDID = 0x912,
236 WMI_POWER_MGMT_CFG_CMDID = 0x913,
237 WMI_START_LISTEN_CMDID = 0x914,
238 WMI_START_SEARCH_CMDID = 0x915,
239 WMI_DISCOVERY_START_CMDID = 0x916,
240 WMI_DISCOVERY_STOP_CMDID = 0x917,
241 WMI_PCP_START_CMDID = 0x918,
242 WMI_PCP_STOP_CMDID = 0x919,
243 WMI_GET_PCP_FACTOR_CMDID = 0x91B,
244
245 WMI_PS_DEV_PROFILE_CFG_CMDID = 0x91C,
246 WMI_RS_ENABLE_CMDID = 0x91E,
247 WMI_RS_CFG_EX_CMDID = 0x91F,
248 WMI_GET_DETAILED_RS_RES_EX_CMDID = 0x920,
249
250 WMI_RS_CFG_CMDID = 0x921,
251
252 WMI_GET_DETAILED_RS_RES_CMDID = 0x922,
253 WMI_AOA_MEAS_CMDID = 0x923,
254 WMI_BRP_SET_ANT_LIMIT_CMDID = 0x924,
255 WMI_SET_MGMT_RETRY_LIMIT_CMDID = 0x930,
256 WMI_GET_MGMT_RETRY_LIMIT_CMDID = 0x931,
257 WMI_NEW_STA_CMDID = 0x935,
258 WMI_DEL_STA_CMDID = 0x936,
259 WMI_SET_THERMAL_THROTTLING_CFG_CMDID = 0x940,
260 WMI_GET_THERMAL_THROTTLING_CFG_CMDID = 0x941,
261
262 WMI_PS_DEV_PROFILE_CFG_READ_CMDID = 0x942,
263 WMI_TSF_SYNC_CMDID = 0x973,
264 WMI_TOF_SESSION_START_CMDID = 0x991,
265 WMI_TOF_GET_CAPABILITIES_CMDID = 0x992,
266 WMI_TOF_SET_LCR_CMDID = 0x993,
267 WMI_TOF_SET_LCI_CMDID = 0x994,
268 WMI_TOF_CFG_RESPONDER_CMDID = 0x996,
269 WMI_TOF_SET_TX_RX_OFFSET_CMDID = 0x997,
270 WMI_TOF_GET_TX_RX_OFFSET_CMDID = 0x998,
271 WMI_TOF_CHANNEL_INFO_CMDID = 0x999,
272 WMI_GET_RF_SECTOR_PARAMS_CMDID = 0x9A0,
273 WMI_SET_RF_SECTOR_PARAMS_CMDID = 0x9A1,
274 WMI_GET_SELECTED_RF_SECTOR_INDEX_CMDID = 0x9A2,
275 WMI_SET_SELECTED_RF_SECTOR_INDEX_CMDID = 0x9A3,
276 WMI_SET_RF_SECTOR_ON_CMDID = 0x9A4,
277 WMI_PRIO_TX_SECTORS_ORDER_CMDID = 0x9A5,
278 WMI_PRIO_TX_SECTORS_NUMBER_CMDID = 0x9A6,
279 WMI_PRIO_TX_SECTORS_SET_DEFAULT_CFG_CMDID = 0x9A7,
280
281 WMI_BF_CONTROL_CMDID = 0x9AA,
282 WMI_BF_CONTROL_EX_CMDID = 0x9AB,
283 WMI_TX_STATUS_RING_ADD_CMDID = 0x9C0,
284 WMI_RX_STATUS_RING_ADD_CMDID = 0x9C1,
285 WMI_TX_DESC_RING_ADD_CMDID = 0x9C2,
286 WMI_RX_DESC_RING_ADD_CMDID = 0x9C3,
287 WMI_BCAST_DESC_RING_ADD_CMDID = 0x9C4,
288 WMI_CFG_DEF_RX_OFFLOAD_CMDID = 0x9C5,
289 WMI_SCHEDULING_SCHEME_CMDID = 0xA01,
290 WMI_FIXED_SCHEDULING_CONFIG_CMDID = 0xA02,
291 WMI_ENABLE_FIXED_SCHEDULING_CMDID = 0xA03,
292 WMI_SET_MULTI_DIRECTED_OMNIS_CONFIG_CMDID = 0xA04,
293 WMI_SET_LONG_RANGE_CONFIG_CMDID = 0xA05,
294 WMI_GET_ASSOC_LIST_CMDID = 0xA06,
295 WMI_GET_CCA_INDICATIONS_CMDID = 0xA07,
296 WMI_SET_CCA_INDICATIONS_BI_AVG_NUM_CMDID = 0xA08,
297 WMI_INTERNAL_FW_IOCTL_CMDID = 0xA0B,
298 WMI_LINK_STATS_CMDID = 0xA0C,
299 WMI_SET_GRANT_MCS_CMDID = 0xA0E,
300 WMI_SET_AP_SLOT_SIZE_CMDID = 0xA0F,
301 WMI_SET_VRING_PRIORITY_WEIGHT_CMDID = 0xA10,
302 WMI_SET_VRING_PRIORITY_CMDID = 0xA11,
303 WMI_RBUFCAP_CFG_CMDID = 0xA12,
304 WMI_TEMP_SENSE_ALL_CMDID = 0xA13,
305 WMI_SET_MAC_ADDRESS_CMDID = 0xF003,
306 WMI_ABORT_SCAN_CMDID = 0xF007,
307 WMI_SET_PROMISCUOUS_MODE_CMDID = 0xF041,
308
309 WMI_GET_PMK_CMDID = 0xF048,
310 WMI_SET_PASSPHRASE_CMDID = 0xF049,
311
312 WMI_SEND_ASSOC_RES_CMDID = 0xF04A,
313
314 WMI_SET_ASSOC_REQ_RELAY_CMDID = 0xF04B,
315 WMI_MAC_ADDR_REQ_CMDID = 0xF04D,
316 WMI_FW_VER_CMDID = 0xF04E,
317 WMI_PMC_CMDID = 0xF04F,
318 };
319
320
321 enum wmi_network_type {
322 WMI_NETTYPE_INFRA = 0x01,
323 WMI_NETTYPE_ADHOC = 0x02,
324 WMI_NETTYPE_ADHOC_CREATOR = 0x04,
325 WMI_NETTYPE_AP = 0x10,
326 WMI_NETTYPE_P2P = 0x20,
327
328 WMI_NETTYPE_WBE = 0x40,
329 };
330
331 enum wmi_dot11_auth_mode {
332 WMI_AUTH11_OPEN = 0x01,
333 WMI_AUTH11_SHARED = 0x02,
334 WMI_AUTH11_LEAP = 0x04,
335 WMI_AUTH11_WSC = 0x08,
336 };
337
338 enum wmi_auth_mode {
339 WMI_AUTH_NONE = 0x01,
340 WMI_AUTH_WPA = 0x02,
341 WMI_AUTH_WPA2 = 0x04,
342 WMI_AUTH_WPA_PSK = 0x08,
343 WMI_AUTH_WPA2_PSK = 0x10,
344 WMI_AUTH_WPA_CCKM = 0x20,
345 WMI_AUTH_WPA2_CCKM = 0x40,
346 };
347
348 enum wmi_crypto_type {
349 WMI_CRYPT_NONE = 0x01,
350 WMI_CRYPT_AES_GCMP = 0x20,
351 };
352
353 enum wmi_connect_ctrl_flag_bits {
354 WMI_CONNECT_ASSOC_POLICY_USER = 0x01,
355 WMI_CONNECT_SEND_REASSOC = 0x02,
356 WMI_CONNECT_IGNORE_WPA_GROUP_CIPHER = 0x04,
357 WMI_CONNECT_PROFILE_MATCH_DONE = 0x08,
358 WMI_CONNECT_IGNORE_AAC_BEACON = 0x10,
359 WMI_CONNECT_CSA_FOLLOW_BSS = 0x20,
360 WMI_CONNECT_DO_WPA_OFFLOAD = 0x40,
361 WMI_CONNECT_DO_NOT_DEAUTH = 0x80,
362 };
363
364 #define WMI_MAX_SSID_LEN (32)
365
366 enum wmi_channel {
367 WMI_CHANNEL_1 = 0x00,
368 WMI_CHANNEL_2 = 0x01,
369 WMI_CHANNEL_3 = 0x02,
370 WMI_CHANNEL_4 = 0x03,
371 WMI_CHANNEL_5 = 0x04,
372 WMI_CHANNEL_6 = 0x05,
373 WMI_CHANNEL_9 = 0x06,
374 WMI_CHANNEL_10 = 0x07,
375 WMI_CHANNEL_11 = 0x08,
376 WMI_CHANNEL_12 = 0x09,
377 };
378
379
380 struct wmi_connect_cmd {
381 u8 network_type;
382 u8 dot11_auth_mode;
383 u8 auth_mode;
384 u8 pairwise_crypto_type;
385 u8 pairwise_crypto_len;
386 u8 group_crypto_type;
387 u8 group_crypto_len;
388 u8 ssid_len;
389 u8 ssid[WMI_MAX_SSID_LEN];
390
391
392
393 u8 channel;
394
395 u8 edmg_channel;
396 u8 bssid[WMI_MAC_LEN];
397 __le32 ctrl_flags;
398 u8 dst_mac[WMI_MAC_LEN];
399 u8 reserved1[2];
400 } __packed;
401
402
403 struct wmi_disconnect_sta_cmd {
404 u8 dst_mac[WMI_MAC_LEN];
405 __le16 disconnect_reason;
406 } __packed;
407
408 #define WMI_MAX_KEY_INDEX (3)
409 #define WMI_MAX_KEY_LEN (32)
410 #define WMI_PASSPHRASE_LEN (64)
411
412
413 struct wmi_set_passphrase_cmd {
414 u8 ssid[WMI_MAX_SSID_LEN];
415 u8 passphrase[WMI_PASSPHRASE_LEN];
416 u8 ssid_len;
417 u8 passphrase_len;
418 } __packed;
419
420
421 enum wmi_key_usage {
422 WMI_KEY_USE_PAIRWISE = 0x00,
423 WMI_KEY_USE_RX_GROUP = 0x01,
424 WMI_KEY_USE_TX_GROUP = 0x02,
425 WMI_KEY_USE_STORE_PTK = 0x03,
426 WMI_KEY_USE_APPLY_PTK = 0x04,
427 };
428
429 struct wmi_add_cipher_key_cmd {
430 u8 key_index;
431 u8 key_type;
432
433 u8 key_usage;
434 u8 key_len;
435
436 u8 key_rsc[8];
437 u8 key[WMI_MAX_KEY_LEN];
438
439 u8 key_op_ctrl;
440 u8 mac[WMI_MAC_LEN];
441 } __packed;
442
443
444 struct wmi_delete_cipher_key_cmd {
445 u8 key_index;
446 u8 mac[WMI_MAC_LEN];
447 } __packed;
448
449
450
451
452
453
454
455
456
457 enum wmi_scan_type {
458 WMI_ACTIVE_SCAN = 0x00,
459 WMI_SHORT_SCAN = 0x01,
460 WMI_PASSIVE_SCAN = 0x02,
461 WMI_DIRECT_SCAN = 0x03,
462 WMI_LONG_SCAN = 0x04,
463 };
464
465
466 struct wmi_start_scan_cmd {
467 u8 direct_scan_mac_addr[WMI_MAC_LEN];
468
469 u8 discovery_mode;
470 u8 reserved;
471
472 __le32 dwell_time;
473
474 __le32 force_scan_interval;
475
476 u8 scan_type;
477
478 u8 num_channels;
479
480
481
482
483
484 struct {
485 u8 channel;
486 u8 reserved;
487 } channel_list[0];
488 } __packed;
489
490 #define WMI_MAX_PNO_SSID_NUM (16)
491 #define WMI_MAX_CHANNEL_NUM (6)
492 #define WMI_MAX_PLANS_NUM (2)
493
494
495 struct wmi_sched_scan_ssid_match {
496 u8 ssid_len;
497 u8 ssid[WMI_MAX_SSID_LEN];
498 s8 rssi_threshold;
499
500 u8 add_ssid_to_probe;
501 u8 reserved;
502 } __packed;
503
504
505 struct wmi_sched_scan_plan {
506 __le16 interval_sec;
507 __le16 num_of_iterations;
508 } __packed;
509
510
511 struct wmi_start_sched_scan_cmd {
512 struct wmi_sched_scan_ssid_match ssid_for_match[WMI_MAX_PNO_SSID_NUM];
513 u8 num_of_ssids;
514 s8 min_rssi_threshold;
515 u8 channel_list[WMI_MAX_CHANNEL_NUM];
516 u8 num_of_channels;
517 u8 reserved;
518 __le16 initial_delay_sec;
519 struct wmi_sched_scan_plan scan_plans[WMI_MAX_PLANS_NUM];
520 } __packed;
521
522
523 struct wmi_ft_auth_cmd {
524 u8 bssid[WMI_MAC_LEN];
525
526 u8 channel;
527
528 u8 edmg_channel;
529 u8 reserved[4];
530 } __packed;
531
532
533 struct wmi_ft_reassoc_cmd {
534 u8 bssid[WMI_MAC_LEN];
535 u8 reserved[2];
536 } __packed;
537
538
539 struct wmi_update_ft_ies_cmd {
540
541 __le16 ie_len;
542 u8 reserved[2];
543 u8 ie_info[0];
544 } __packed;
545
546
547 #define MAX_PROBED_SSID_INDEX (3)
548
549 enum wmi_ssid_flag {
550
551 WMI_SSID_FLAG_DISABLE = 0x00,
552
553 WMI_SSID_FLAG_SPECIFIC = 0x01,
554
555 WMI_SSID_FLAG_ANY = 0x02,
556 };
557
558 struct wmi_probed_ssid_cmd {
559
560 u8 entry_index;
561
562 u8 flag;
563 u8 ssid_len;
564 u8 ssid[WMI_MAX_SSID_LEN];
565 } __packed;
566
567
568
569
570 #define WMI_MAX_IE_LEN (1024)
571
572
573 enum wmi_mgmt_frame_type {
574 WMI_FRAME_BEACON = 0x00,
575 WMI_FRAME_PROBE_REQ = 0x01,
576 WMI_FRAME_PROBE_RESP = 0x02,
577 WMI_FRAME_ASSOC_REQ = 0x03,
578 WMI_FRAME_ASSOC_RESP = 0x04,
579 WMI_NUM_MGMT_FRAME = 0x05,
580 };
581
582 struct wmi_set_appie_cmd {
583
584 u8 mgmt_frm_type;
585 u8 reserved;
586
587 __le16 ie_len;
588 u8 ie_info[0];
589 } __packed;
590
591
592 struct wmi_pxmt_range_cfg_cmd {
593 u8 dst_mac[WMI_MAC_LEN];
594 __le16 range;
595 } __packed;
596
597
598 struct wmi_pxmt_snr2_range_cfg_cmd {
599 s8 snr2range_arr[2];
600 } __packed;
601
602
603 struct wmi_radar_general_config_cmd {
604
605
606
607 __le32 fifo_watermark;
608
609 __le32 t_burst;
610
611 __le32 n_bursts;
612
613 __le32 t_pulse;
614
615 __le16 n_pulses;
616
617 __le16 n_samples;
618
619
620
621 u8 first_sample_offset;
622
623 u8 pulses_to_avg;
624
625 u8 samples_to_avg;
626
627 u8 general_index;
628 u8 reserved[4];
629 } __packed;
630
631
632 struct wmi_radar_config_select_cmd {
633
634 u8 general_index;
635 u8 reserved[3];
636
637 __le32 burst_active_vector;
638
639 __le32 pulse_active_vector;
640 } __packed;
641
642
643 struct wmi_radar_params_config_cmd {
644
645 u8 burst_index;
646
647 u8 burst_en;
648
649 u8 pulse_index;
650
651 u8 pulse_en;
652
653 u8 tx_rfc_idx;
654 u8 tx_sector;
655
656
657
658 s8 tx_rf_gain_comp;
659
660 s8 tx_bb_gain_comp;
661
662 u8 rx_rfc_idx;
663 u8 rx_sector;
664
665
666
667 s8 rx_rf_gain_comp;
668
669 s8 rx_bb_gain_comp;
670
671 s8 rx_timing_offset;
672 u8 reserved[3];
673 } __packed;
674
675
676 struct wmi_radar_set_mode_cmd {
677
678 u8 enable;
679
680 u8 channel;
681
682 u8 tx_rfc_idx;
683
684 u8 rx_rfc_idx;
685 } __packed;
686
687
688 struct wmi_radar_control_cmd {
689
690 u8 start;
691 u8 reserved[3];
692 } __packed;
693
694
695 struct wmi_radar_pci_control_cmd {
696
697 __le64 base_addr;
698
699 __le64 control_block_addr;
700
701 __le32 buffer_size;
702 __le32 reserved;
703 } __packed;
704
705
706 enum wmi_rf_mgmt_type {
707 WMI_RF_MGMT_W_DISABLE = 0x00,
708 WMI_RF_MGMT_W_ENABLE = 0x01,
709 WMI_RF_MGMT_GET_STATUS = 0x02,
710 };
711
712
713 enum wmi_bf_triggers {
714 WMI_BF_TRIGGER_RS_MCS1_TH_FAILURE = 0x01,
715 WMI_BF_TRIGGER_RS_MCS1_NO_BACK_FAILURE = 0x02,
716 WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_TXOP = 0x04,
717 WMI_BF_TRIGGER_MAX_BACK_FAILURE = 0x08,
718 WMI_BF_TRIGGER_FW = 0x10,
719 WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_KEEP_ALIVE = 0x20,
720 WMI_BF_TRIGGER_AOA = 0x40,
721 WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_UPM = 0x80,
722 };
723
724
725 struct wmi_rf_mgmt_cmd {
726 __le32 rf_mgmt_type;
727 } __packed;
728
729
730 struct wmi_corr_measure_cmd {
731 __le32 freq_mhz;
732 __le32 length_samples;
733 __le32 iterations;
734 } __packed;
735
736
737 struct wmi_set_ssid_cmd {
738 __le32 ssid_len;
739 u8 ssid[WMI_MAX_SSID_LEN];
740 } __packed;
741
742
743 struct wmi_set_pcp_channel_cmd {
744 u8 channel;
745 u8 reserved[3];
746 } __packed;
747
748
749 struct wmi_bcon_ctrl_cmd {
750 __le16 bcon_interval;
751 __le16 frag_num;
752 __le64 ss_mask;
753 u8 network_type;
754 u8 pcp_max_assoc_sta;
755 u8 disable_sec_offload;
756 u8 disable_sec;
757 u8 hidden_ssid;
758 u8 is_go;
759
760 u8 abft_len;
761 u8 reserved;
762 } __packed;
763
764
765 enum wmi_port_role {
766 WMI_PORT_STA = 0x00,
767 WMI_PORT_PCP = 0x01,
768 WMI_PORT_AP = 0x02,
769 WMI_PORT_P2P_DEV = 0x03,
770 WMI_PORT_P2P_CLIENT = 0x04,
771 WMI_PORT_P2P_GO = 0x05,
772 };
773
774
775 struct wmi_port_allocate_cmd {
776 u8 mac[WMI_MAC_LEN];
777 u8 port_role;
778 u8 mid;
779 } __packed;
780
781
782 struct wmi_port_delete_cmd {
783 u8 mid;
784 u8 reserved[3];
785 } __packed;
786
787
788 enum wmi_wakeup_trigger {
789 WMI_WAKEUP_TRIGGER_UCAST = 0x01,
790 WMI_WAKEUP_TRIGGER_BCAST = 0x02,
791 };
792
793
794 struct wmi_traffic_suspend_cmd {
795
796 u8 wakeup_trigger;
797 } __packed;
798
799
800 enum wmi_discovery_mode {
801 WMI_DISCOVERY_MODE_NON_OFFLOAD = 0x00,
802 WMI_DISCOVERY_MODE_OFFLOAD = 0x01,
803 WMI_DISCOVERY_MODE_PEER2PEER = 0x02,
804 };
805
806 struct wmi_p2p_cfg_cmd {
807
808 u8 discovery_mode;
809 u8 channel;
810
811 __le16 bcon_interval;
812 } __packed;
813
814
815 enum wmi_power_source_type {
816 WMI_POWER_SOURCE_BATTERY = 0x00,
817 WMI_POWER_SOURCE_OTHER = 0x01,
818 };
819
820 struct wmi_power_mgmt_cfg_cmd {
821
822 u8 power_source;
823 u8 reserved[3];
824 } __packed;
825
826
827 enum wmi_ap_sme_offload_mode {
828
829 WMI_AP_SME_OFFLOAD_FULL = 0x00,
830
831 WMI_AP_SME_OFFLOAD_PARTIAL = 0x01,
832
833 WMI_AP_SME_OFFLOAD_NONE = 0x02,
834 };
835
836
837 struct wmi_pcp_start_cmd {
838 __le16 bcon_interval;
839 u8 pcp_max_assoc_sta;
840 u8 hidden_ssid;
841 u8 is_go;
842
843 u8 edmg_channel;
844 u8 raw_mode;
845 u8 reserved[3];
846
847 u8 abft_len;
848
849 u8 ap_sme_offload_mode;
850 u8 network_type;
851
852
853
854 u8 channel;
855 u8 disable_sec_offload;
856 u8 disable_sec;
857 } __packed;
858
859
860 struct wmi_sw_tx_req_cmd {
861 u8 dst_mac[WMI_MAC_LEN];
862 __le16 len;
863 u8 payload[0];
864 } __packed;
865
866
867 struct wmi_sw_tx_req_ext_cmd {
868 u8 dst_mac[WMI_MAC_LEN];
869 __le16 len;
870 __le16 duration_ms;
871
872 u8 channel;
873 u8 reserved[5];
874 u8 payload[0];
875 } __packed;
876
877
878 struct wmi_vring_switch_timing_config_cmd {
879
880
881
882
883 __le32 interval_usec;
884
885 __le32 idle_th_usec;
886 } __packed;
887
888 struct wmi_sw_ring_cfg {
889 __le64 ring_mem_base;
890 __le16 ring_size;
891 __le16 max_mpdu_size;
892 } __packed;
893
894
895 struct wmi_vring_cfg_schd {
896 __le16 priority;
897 __le16 timeslot_us;
898 } __packed;
899
900 enum wmi_vring_cfg_encap_trans_type {
901 WMI_VRING_ENC_TYPE_802_3 = 0x00,
902 WMI_VRING_ENC_TYPE_NATIVE_WIFI = 0x01,
903 WMI_VRING_ENC_TYPE_NONE = 0x02,
904 };
905
906 enum wmi_vring_cfg_ds_cfg {
907 WMI_VRING_DS_PBSS = 0x00,
908 WMI_VRING_DS_STATION = 0x01,
909 WMI_VRING_DS_AP = 0x02,
910 WMI_VRING_DS_ADDR4 = 0x03,
911 };
912
913 enum wmi_vring_cfg_nwifi_ds_trans_type {
914 WMI_NWIFI_TX_TRANS_MODE_NO = 0x00,
915 WMI_NWIFI_TX_TRANS_MODE_AP2PBSS = 0x01,
916 WMI_NWIFI_TX_TRANS_MODE_STA2PBSS = 0x02,
917 };
918
919 enum wmi_vring_cfg_schd_params_priority {
920 WMI_SCH_PRIO_REGULAR = 0x00,
921 WMI_SCH_PRIO_HIGH = 0x01,
922 };
923
924 #define CIDXTID_EXTENDED_CID_TID (0xFF)
925 #define CIDXTID_CID_POS (0)
926 #define CIDXTID_CID_LEN (4)
927 #define CIDXTID_CID_MSK (0xF)
928 #define CIDXTID_TID_POS (4)
929 #define CIDXTID_TID_LEN (4)
930 #define CIDXTID_TID_MSK (0xF0)
931 #define VRING_CFG_MAC_CTRL_LIFETIME_EN_POS (0)
932 #define VRING_CFG_MAC_CTRL_LIFETIME_EN_LEN (1)
933 #define VRING_CFG_MAC_CTRL_LIFETIME_EN_MSK (0x1)
934 #define VRING_CFG_MAC_CTRL_AGGR_EN_POS (1)
935 #define VRING_CFG_MAC_CTRL_AGGR_EN_LEN (1)
936 #define VRING_CFG_MAC_CTRL_AGGR_EN_MSK (0x2)
937 #define VRING_CFG_TO_RESOLUTION_VALUE_POS (0)
938 #define VRING_CFG_TO_RESOLUTION_VALUE_LEN (6)
939 #define VRING_CFG_TO_RESOLUTION_VALUE_MSK (0x3F)
940
941 struct wmi_vring_cfg {
942 struct wmi_sw_ring_cfg tx_sw_ring;
943
944 u8 ringid;
945
946
947
948 u8 cidxtid;
949 u8 encap_trans_type;
950
951 u8 ds_cfg;
952 u8 nwifi_ds_trans_type;
953 u8 mac_ctrl;
954 u8 to_resolution;
955 u8 agg_max_wsize;
956 struct wmi_vring_cfg_schd schd_params;
957
958 u8 cid;
959
960 u8 tid;
961
962
963
964 u8 qos_priority;
965 u8 reserved;
966 } __packed;
967
968 enum wmi_vring_cfg_cmd_action {
969 WMI_VRING_CMD_ADD = 0x00,
970 WMI_VRING_CMD_MODIFY = 0x01,
971 WMI_VRING_CMD_DELETE = 0x02,
972 };
973
974
975 struct wmi_vring_cfg_cmd {
976 __le32 action;
977 struct wmi_vring_cfg vring_cfg;
978 } __packed;
979
980 struct wmi_bcast_vring_cfg {
981 struct wmi_sw_ring_cfg tx_sw_ring;
982
983 u8 ringid;
984 u8 encap_trans_type;
985
986 u8 ds_cfg;
987 u8 nwifi_ds_trans_type;
988 } __packed;
989
990
991 struct wmi_bcast_vring_cfg_cmd {
992 __le32 action;
993 struct wmi_bcast_vring_cfg vring_cfg;
994 } __packed;
995
996 struct wmi_edma_ring_cfg {
997 __le64 ring_mem_base;
998
999 __le16 ring_size;
1000 u8 ring_id;
1001 u8 reserved;
1002 } __packed;
1003
1004 enum wmi_rx_msg_type {
1005 WMI_RX_MSG_TYPE_COMPRESSED = 0x00,
1006 WMI_RX_MSG_TYPE_EXTENDED = 0x01,
1007 };
1008
1009 enum wmi_ring_add_irq_mode {
1010
1011
1012
1013
1014 WMI_RING_ADD_IRQ_MODE_BWC = 0x00,
1015 WMI_RING_ADD_IRQ_MODE_DISABLE = 0x01,
1016 WMI_RING_ADD_IRQ_MODE_ENABLE = 0x02,
1017 };
1018
1019 struct wmi_tx_status_ring_add_cmd {
1020 struct wmi_edma_ring_cfg ring_cfg;
1021 u8 irq_index;
1022
1023 u8 irq_mode;
1024 u8 reserved[2];
1025 } __packed;
1026
1027 struct wmi_rx_status_ring_add_cmd {
1028 struct wmi_edma_ring_cfg ring_cfg;
1029 u8 irq_index;
1030
1031 u8 rx_msg_type;
1032 u8 reserved[2];
1033 } __packed;
1034
1035 struct wmi_cfg_def_rx_offload_cmd {
1036 __le16 max_msdu_size;
1037 __le16 max_rx_pl_per_desc;
1038 u8 decap_trans_type;
1039 u8 l2_802_3_offload_ctrl;
1040 u8 l2_nwifi_offload_ctrl;
1041 u8 vlan_id;
1042 u8 nwifi_ds_trans_type;
1043 u8 l3_l4_ctrl;
1044 u8 reserved[6];
1045 } __packed;
1046
1047 struct wmi_tx_desc_ring_add_cmd {
1048 struct wmi_edma_ring_cfg ring_cfg;
1049 __le16 max_msdu_size;
1050
1051 u8 status_ring_id;
1052 u8 cid;
1053 u8 tid;
1054 u8 encap_trans_type;
1055 u8 mac_ctrl;
1056 u8 to_resolution;
1057 u8 agg_max_wsize;
1058 u8 irq_index;
1059
1060 u8 irq_mode;
1061 u8 reserved;
1062 struct wmi_vring_cfg_schd schd_params;
1063 } __packed;
1064
1065 struct wmi_rx_desc_ring_add_cmd {
1066 struct wmi_edma_ring_cfg ring_cfg;
1067 u8 irq_index;
1068
1069 u8 status_ring_id;
1070 u8 reserved[2];
1071 __le64 sw_tail_host_addr;
1072 } __packed;
1073
1074 struct wmi_bcast_desc_ring_add_cmd {
1075 struct wmi_edma_ring_cfg ring_cfg;
1076 __le16 max_msdu_size;
1077
1078 u8 status_ring_id;
1079 u8 encap_trans_type;
1080 u8 reserved[4];
1081 } __packed;
1082
1083
1084 struct wmi_lo_power_calib_from_otp_cmd {
1085
1086 u8 index;
1087 u8 reserved[3];
1088 } __packed;
1089
1090
1091 struct wmi_lo_power_calib_from_otp_event {
1092
1093 u8 status;
1094 u8 reserved[3];
1095 } __packed;
1096
1097
1098 struct wmi_ring_ba_en_cmd {
1099 u8 ring_id;
1100 u8 agg_max_wsize;
1101 __le16 ba_timeout;
1102 u8 amsdu;
1103 u8 reserved[3];
1104 } __packed;
1105
1106
1107 struct wmi_ring_ba_dis_cmd {
1108 u8 ring_id;
1109 u8 reserved;
1110 __le16 reason;
1111 } __packed;
1112
1113
1114 struct wmi_notify_req_cmd {
1115 u8 cid;
1116 u8 year;
1117 u8 month;
1118 u8 day;
1119 __le32 interval_usec;
1120 u8 hour;
1121 u8 minute;
1122 u8 second;
1123 u8 miliseconds;
1124 } __packed;
1125
1126
1127 enum wmi_sniffer_cfg_mode {
1128 WMI_SNIFFER_OFF = 0x00,
1129 WMI_SNIFFER_ON = 0x01,
1130 };
1131
1132
1133 enum wmi_silent_rssi_table {
1134 RF_TEMPERATURE_CALIB_DEFAULT_DB = 0x00,
1135 RF_TEMPERATURE_CALIB_HIGH_POWER_DB = 0x01,
1136 };
1137
1138
1139 enum wmi_silent_rssi_status {
1140 SILENT_RSSI_SUCCESS = 0x00,
1141 SILENT_RSSI_FAILURE = 0x01,
1142 };
1143
1144
1145 struct wmi_set_active_silent_rssi_table_cmd {
1146
1147 __le32 table;
1148 } __packed;
1149
1150 enum wmi_sniffer_cfg_phy_info_mode {
1151 WMI_SNIFFER_PHY_INFO_DISABLED = 0x00,
1152 WMI_SNIFFER_PHY_INFO_ENABLED = 0x01,
1153 };
1154
1155 enum wmi_sniffer_cfg_phy_support {
1156 WMI_SNIFFER_CP = 0x00,
1157 WMI_SNIFFER_DP = 0x01,
1158 WMI_SNIFFER_BOTH_PHYS = 0x02,
1159 };
1160
1161
1162 struct wmi_sniffer_cfg {
1163
1164 __le32 mode;
1165
1166 __le32 phy_info_mode;
1167
1168 __le32 phy_support;
1169 u8 channel;
1170 u8 reserved[3];
1171 } __packed;
1172
1173 enum wmi_cfg_rx_chain_cmd_action {
1174 WMI_RX_CHAIN_ADD = 0x00,
1175 WMI_RX_CHAIN_DEL = 0x01,
1176 };
1177
1178 enum wmi_cfg_rx_chain_cmd_decap_trans_type {
1179 WMI_DECAP_TYPE_802_3 = 0x00,
1180 WMI_DECAP_TYPE_NATIVE_WIFI = 0x01,
1181 WMI_DECAP_TYPE_NONE = 0x02,
1182 };
1183
1184 enum wmi_cfg_rx_chain_cmd_nwifi_ds_trans_type {
1185 WMI_NWIFI_RX_TRANS_MODE_NO = 0x00,
1186 WMI_NWIFI_RX_TRANS_MODE_PBSS2AP = 0x01,
1187 WMI_NWIFI_RX_TRANS_MODE_PBSS2STA = 0x02,
1188 };
1189
1190 enum wmi_cfg_rx_chain_cmd_reorder_type {
1191 WMI_RX_HW_REORDER = 0x00,
1192 WMI_RX_SW_REORDER = 0x01,
1193 };
1194
1195 #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_POS (0)
1196 #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_LEN (1)
1197 #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_MSK (0x1)
1198 #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_POS (1)
1199 #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_LEN (1)
1200 #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_MSK (0x2)
1201 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_POS (0)
1202 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_LEN (1)
1203 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_MSK (0x1)
1204 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_POS (1)
1205 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_LEN (1)
1206 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_MSK (0x2)
1207 #define L3_L4_CTRL_IPV4_CHECKSUM_EN_POS (0)
1208 #define L3_L4_CTRL_IPV4_CHECKSUM_EN_LEN (1)
1209 #define L3_L4_CTRL_IPV4_CHECKSUM_EN_MSK (0x1)
1210 #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_POS (1)
1211 #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_LEN (1)
1212 #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_MSK (0x2)
1213 #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_POS (0)
1214 #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_LEN (1)
1215 #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_MSK (0x1)
1216 #define RING_CTRL_OVERRIDE_WB_THRSH_POS (1)
1217 #define RING_CTRL_OVERRIDE_WB_THRSH_LEN (1)
1218 #define RING_CTRL_OVERRIDE_WB_THRSH_MSK (0x2)
1219 #define RING_CTRL_OVERRIDE_ITR_THRSH_POS (2)
1220 #define RING_CTRL_OVERRIDE_ITR_THRSH_LEN (1)
1221 #define RING_CTRL_OVERRIDE_ITR_THRSH_MSK (0x4)
1222 #define RING_CTRL_OVERRIDE_HOST_THRSH_POS (3)
1223 #define RING_CTRL_OVERRIDE_HOST_THRSH_LEN (1)
1224 #define RING_CTRL_OVERRIDE_HOST_THRSH_MSK (0x8)
1225
1226
1227 struct wmi_cfg_rx_chain_cmd {
1228 __le32 action;
1229 struct wmi_sw_ring_cfg rx_sw_ring;
1230 u8 mid;
1231 u8 decap_trans_type;
1232 u8 l2_802_3_offload_ctrl;
1233 u8 l2_nwifi_offload_ctrl;
1234 u8 vlan_id;
1235 u8 nwifi_ds_trans_type;
1236 u8 l3_l4_ctrl;
1237 u8 ring_ctrl;
1238 __le16 prefetch_thrsh;
1239 __le16 wb_thrsh;
1240 __le32 itr_value;
1241 __le16 host_thrsh;
1242 u8 reorder_type;
1243 u8 reserved;
1244 struct wmi_sniffer_cfg sniffer_cfg;
1245 __le16 max_rx_pl_per_desc;
1246 } __packed;
1247
1248
1249 struct wmi_rcp_addba_resp_cmd {
1250
1251
1252
1253 u8 cidxtid;
1254 u8 dialog_token;
1255 __le16 status_code;
1256
1257 __le16 ba_param_set;
1258 __le16 ba_timeout;
1259
1260 u8 cid;
1261
1262 u8 tid;
1263 u8 reserved[2];
1264 } __packed;
1265
1266
1267 struct wmi_rcp_addba_resp_edma_cmd {
1268 u8 cid;
1269 u8 tid;
1270 u8 dialog_token;
1271 u8 reserved;
1272 __le16 status_code;
1273
1274 __le16 ba_param_set;
1275 __le16 ba_timeout;
1276 u8 status_ring_id;
1277
1278 u8 reorder_type;
1279 } __packed;
1280
1281
1282 struct wmi_rcp_delba_cmd {
1283
1284
1285
1286 u8 cidxtid;
1287 u8 reserved;
1288 __le16 reason;
1289
1290 u8 cid;
1291
1292 u8 tid;
1293 u8 reserved2[2];
1294 } __packed;
1295
1296
1297 struct wmi_rcp_addba_req_cmd {
1298
1299
1300
1301 u8 cidxtid;
1302 u8 dialog_token;
1303
1304 __le16 ba_param_set;
1305 __le16 ba_timeout;
1306
1307 __le16 ba_seq_ctrl;
1308
1309 u8 cid;
1310
1311 u8 tid;
1312 u8 reserved[2];
1313 } __packed;
1314
1315
1316 struct wmi_set_mac_address_cmd {
1317 u8 mac[WMI_MAC_LEN];
1318 u8 reserved[2];
1319 } __packed;
1320
1321
1322
1323
1324
1325 struct wmi_echo_cmd {
1326 __le32 value;
1327 } __packed;
1328
1329
1330
1331
1332
1333 struct wmi_deep_echo_cmd {
1334 __le32 value;
1335 } __packed;
1336
1337
1338
1339
1340
1341
1342
1343 struct wmi_rf_pwr_on_delay_cmd {
1344
1345
1346
1347 __le16 down_delay_usec;
1348
1349
1350
1351 __le16 up_delay_usec;
1352 } __packed;
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363 struct wmi_set_high_power_table_params_cmd {
1364
1365 u8 tx_dtype_temp[WMI_RF_DTYPE_LENGTH];
1366 u8 reserved0;
1367
1368 __le32 tx_dtype_conf[WMI_RF_DTYPE_CONF_LENGTH];
1369
1370 u8 tx_etype_temp[WMI_RF_ETYPE_LENGTH];
1371 u8 reserved1;
1372
1373
1374
1375
1376 __le32 tx_etype_conf[WMI_RF_ETYPE_CONF_LENGTH];
1377
1378 u8 rx_dtype_temp[WMI_RF_DTYPE_LENGTH];
1379 u8 reserved2;
1380
1381 __le32 rx_dtype_conf[WMI_RF_DTYPE_CONF_LENGTH];
1382
1383 u8 rx_etype_temp[WMI_RF_ETYPE_LENGTH];
1384 u8 reserved3;
1385
1386
1387
1388
1389 __le32 rx_etype_conf[WMI_RF_ETYPE_CONF_LENGTH];
1390
1391 u8 rx_2_tx_temp[WMI_RF_RX2TX_LENGTH];
1392 u8 reserved4;
1393
1394 s8 rx_2_tx_offs[WMI_RF_RX2TX_CONF_LENGTH];
1395 } __packed;
1396
1397
1398
1399
1400
1401
1402 struct wmi_fixed_scheduling_ul_config_cmd {
1403
1404 s8 mcs;
1405
1406 u8 rd_count_per_slot;
1407 u8 reserved[2];
1408 } __packed;
1409
1410
1411 struct wmi_rf_xpm_read_cmd {
1412 u8 rf_id;
1413 u8 reserved[3];
1414
1415
1416
1417 __le32 xpm_bit_address;
1418 __le32 num_bytes;
1419 } __packed;
1420
1421
1422 struct wmi_rf_xpm_write_cmd {
1423 u8 rf_id;
1424 u8 reserved0[3];
1425
1426
1427
1428 __le32 xpm_bit_address;
1429 __le32 num_bytes;
1430
1431
1432
1433 u8 verify;
1434 u8 reserved1[3];
1435
1436 u8 data_bytes[0];
1437 } __packed;
1438
1439
1440 enum wmi_temperature_measure_mode {
1441 TEMPERATURE_USE_OLD_VALUE = 0x01,
1442 TEMPERATURE_MEASURE_NOW = 0x02,
1443 };
1444
1445
1446 struct wmi_temp_sense_cmd {
1447 __le32 measure_baseband_en;
1448 __le32 measure_rf_en;
1449 __le32 measure_mode;
1450 } __packed;
1451
1452 enum wmi_pmc_op {
1453 WMI_PMC_ALLOCATE = 0x00,
1454 WMI_PMC_RELEASE = 0x01,
1455 };
1456
1457
1458 struct wmi_pmc_cmd {
1459
1460 u8 op;
1461 u8 reserved;
1462 __le16 ring_size;
1463 __le64 mem_base;
1464 } __packed;
1465
1466 enum wmi_aoa_meas_type {
1467 WMI_AOA_PHASE_MEAS = 0x00,
1468 WMI_AOA_PHASE_AMP_MEAS = 0x01,
1469 };
1470
1471
1472 struct wmi_aoa_meas_cmd {
1473 u8 mac_addr[WMI_MAC_LEN];
1474
1475
1476
1477
1478
1479 u8 channel;
1480
1481 u8 aoa_meas_type;
1482 __le32 meas_rf_mask;
1483 } __packed;
1484
1485
1486 struct wmi_set_mgmt_retry_limit_cmd {
1487
1488 u8 mgmt_retry_limit;
1489
1490 u8 reserved[3];
1491 } __packed;
1492
1493
1494 #define WMI_NUM_OF_TT_ZONES (3)
1495
1496 struct wmi_tt_zone_limits {
1497
1498 u8 temperature_high;
1499
1500 u8 temperature_low;
1501 u8 reserved[2];
1502 } __packed;
1503
1504
1505
1506
1507 struct wmi_tt_data {
1508
1509 u8 bb_enabled;
1510 u8 reserved0[3];
1511
1512 struct wmi_tt_zone_limits bb_zones[WMI_NUM_OF_TT_ZONES];
1513
1514 u8 rf_enabled;
1515 u8 reserved1[3];
1516
1517 struct wmi_tt_zone_limits rf_zones[WMI_NUM_OF_TT_ZONES];
1518 } __packed;
1519
1520
1521 struct wmi_set_thermal_throttling_cfg_cmd {
1522
1523 struct wmi_tt_data tt_data;
1524 } __packed;
1525
1526
1527 struct wmi_new_sta_cmd {
1528 u8 dst_mac[WMI_MAC_LEN];
1529 u8 aid;
1530 } __packed;
1531
1532
1533 struct wmi_del_sta_cmd {
1534 u8 dst_mac[WMI_MAC_LEN];
1535 __le16 disconnect_reason;
1536 } __packed;
1537
1538 enum wmi_tof_burst_duration {
1539 WMI_TOF_BURST_DURATION_250_USEC = 2,
1540 WMI_TOF_BURST_DURATION_500_USEC = 3,
1541 WMI_TOF_BURST_DURATION_1_MSEC = 4,
1542 WMI_TOF_BURST_DURATION_2_MSEC = 5,
1543 WMI_TOF_BURST_DURATION_4_MSEC = 6,
1544 WMI_TOF_BURST_DURATION_8_MSEC = 7,
1545 WMI_TOF_BURST_DURATION_16_MSEC = 8,
1546 WMI_TOF_BURST_DURATION_32_MSEC = 9,
1547 WMI_TOF_BURST_DURATION_64_MSEC = 10,
1548 WMI_TOF_BURST_DURATION_128_MSEC = 11,
1549 WMI_TOF_BURST_DURATION_NO_PREFERENCES = 15,
1550 };
1551
1552 enum wmi_tof_session_start_flags {
1553 WMI_TOF_SESSION_START_FLAG_SECURED = 0x1,
1554 WMI_TOF_SESSION_START_FLAG_ASAP = 0x2,
1555 WMI_TOF_SESSION_START_FLAG_LCI_REQ = 0x4,
1556 WMI_TOF_SESSION_START_FLAG_LCR_REQ = 0x8,
1557 };
1558
1559
1560 struct wmi_ftm_dest_info {
1561 u8 channel;
1562
1563 u8 flags;
1564 u8 initial_token;
1565 u8 num_of_ftm_per_burst;
1566 u8 num_of_bursts_exp;
1567
1568 u8 burst_duration;
1569
1570
1571
1572 __le16 burst_period;
1573 u8 dst_mac[WMI_MAC_LEN];
1574 u8 reserved;
1575 u8 num_burst_per_aoa_meas;
1576 } __packed;
1577
1578
1579 struct wmi_tof_session_start_cmd {
1580 __le32 session_id;
1581 u8 reserved1;
1582 u8 aoa_type;
1583 __le16 num_of_dest;
1584 u8 reserved[4];
1585 struct wmi_ftm_dest_info ftm_dest_info[0];
1586 } __packed;
1587
1588
1589 struct wmi_tof_cfg_responder_cmd {
1590 u8 enable;
1591 u8 reserved[3];
1592 } __packed;
1593
1594 enum wmi_tof_channel_info_report_type {
1595 WMI_TOF_CHANNEL_INFO_TYPE_CIR = 0x1,
1596 WMI_TOF_CHANNEL_INFO_TYPE_RSSI = 0x2,
1597 WMI_TOF_CHANNEL_INFO_TYPE_SNR = 0x4,
1598 WMI_TOF_CHANNEL_INFO_TYPE_DEBUG_DATA = 0x8,
1599 WMI_TOF_CHANNEL_INFO_TYPE_VENDOR_SPECIFIC = 0x10,
1600 };
1601
1602
1603 struct wmi_tof_channel_info_cmd {
1604
1605 __le32 channel_info_report_request;
1606 } __packed;
1607
1608
1609 struct wmi_tof_set_tx_rx_offset_cmd {
1610
1611 __le32 tx_offset;
1612
1613 __le32 rx_offset;
1614
1615 __le32 rf_mask;
1616
1617 __le32 precursor;
1618 } __packed;
1619
1620
1621 struct wmi_tof_get_tx_rx_offset_cmd {
1622
1623 u8 rf_index;
1624 u8 reserved[3];
1625 } __packed;
1626
1627
1628 struct wmi_map_mcs_to_schd_params {
1629 u8 mcs;
1630
1631 u8 time_in_usec_before_initiate_tx;
1632
1633 u8 rd_enabled;
1634 u8 reserved;
1635
1636 __le16 time_in_usec_to_stop_vring;
1637
1638 __le16 flush_to_in_usec;
1639
1640 __le32 mac_buff_size_in_bytes;
1641 } __packed;
1642
1643
1644 struct wmi_fixed_scheduling_config_complete_event {
1645
1646 u8 status;
1647 u8 reserved[3];
1648 } __packed;
1649
1650
1651
1652
1653
1654 #define WMI_NUM_MCS (13)
1655
1656
1657 struct wmi_fixed_scheduling_config_cmd {
1658
1659 struct wmi_map_mcs_to_schd_params mcs_to_schd_params_map[WMI_NUM_MCS];
1660
1661 __le16 max_sta_rd_ppdu_duration_in_usec;
1662
1663 __le16 max_sta_grant_ppdu_duration_in_usec;
1664
1665 __le16 assoc_slot_duration_in_usec;
1666
1667 __le16 virtual_slot_duration_in_usec;
1668
1669
1670
1671 u8 number_of_ap_slots_for_initiate_grant;
1672 u8 reserved[3];
1673 } __packed;
1674
1675
1676 struct wmi_enable_fixed_scheduling_cmd {
1677 __le32 reserved;
1678 } __packed;
1679
1680
1681 struct wmi_enable_fixed_scheduling_complete_event {
1682
1683 u8 status;
1684 u8 reserved[3];
1685 } __packed;
1686
1687
1688 struct wmi_set_multi_directed_omnis_config_cmd {
1689
1690 u8 dest_ap_num_directed_omnis;
1691 u8 reserved[3];
1692 } __packed;
1693
1694
1695 struct wmi_set_multi_directed_omnis_config_event {
1696
1697 u8 status;
1698 u8 reserved[3];
1699 } __packed;
1700
1701
1702 struct wmi_radar_general_config_event {
1703
1704 u8 status;
1705 u8 reserved[3];
1706 } __packed;
1707
1708
1709 struct wmi_radar_config_select_event {
1710
1711 u8 status;
1712 u8 reserved[3];
1713
1714 __le32 fifo_size;
1715
1716 __le32 pulse_size;
1717 } __packed;
1718
1719
1720 struct wmi_radar_params_config_event {
1721
1722 u8 status;
1723 u8 reserved[3];
1724 } __packed;
1725
1726
1727 struct wmi_radar_set_mode_event {
1728
1729 u8 status;
1730 u8 reserved[3];
1731 } __packed;
1732
1733
1734 struct wmi_radar_control_event {
1735
1736 u8 status;
1737 u8 reserved[3];
1738 } __packed;
1739
1740
1741 struct wmi_radar_pci_control_event {
1742
1743 u8 status;
1744 u8 reserved[3];
1745 } __packed;
1746
1747
1748 struct wmi_set_long_range_config_cmd {
1749 __le32 reserved;
1750 } __packed;
1751
1752
1753 struct wmi_set_long_range_config_complete_event {
1754
1755 u8 status;
1756 u8 reserved[3];
1757 } __packed;
1758
1759
1760
1761
1762 #define WMI_MAX_IOCTL_PAYLOAD_SIZE (1024)
1763 #define WMI_MAX_IOCTL_REPLY_PAYLOAD_SIZE (1024)
1764 #define WMI_MAX_INTERNAL_EVENT_PAYLOAD_SIZE (1024)
1765
1766 enum wmi_internal_fw_ioctl_code {
1767 WMI_INTERNAL_FW_CODE_NONE = 0x0,
1768 WMI_INTERNAL_FW_CODE_QCOM = 0x1,
1769 };
1770
1771
1772 struct wmi_internal_fw_ioctl_cmd {
1773
1774 __le16 code;
1775 __le16 length;
1776
1777
1778
1779 __le32 payload[0];
1780 } __packed;
1781
1782
1783 struct wmi_internal_fw_ioctl_event {
1784
1785 u8 status;
1786 u8 reserved;
1787 __le16 length;
1788
1789
1790
1791 __le32 payload[0];
1792 } __packed;
1793
1794
1795 struct wmi_internal_fw_event_event {
1796 __le16 id;
1797 __le16 length;
1798
1799
1800
1801 __le32 payload[0];
1802 } __packed;
1803
1804
1805 struct wmi_set_vring_priority_weight_cmd {
1806
1807
1808
1809
1810
1811 u8 weight[3];
1812 u8 reserved;
1813 } __packed;
1814
1815
1816 struct wmi_vring_priority {
1817 u8 vring_idx;
1818
1819 u8 priority;
1820 u8 reserved[2];
1821 } __packed;
1822
1823
1824 struct wmi_set_vring_priority_cmd {
1825
1826
1827
1828
1829 u8 num_of_vrings;
1830 u8 reserved[3];
1831 struct wmi_vring_priority vring_priority[0];
1832 } __packed;
1833
1834
1835 struct wmi_bf_control_cmd {
1836
1837 __le32 triggers;
1838 u8 cid;
1839
1840 u8 txss_mode;
1841
1842 u8 brp_mode;
1843
1844
1845
1846 u8 bf_trigger_max_cts_failure_thr;
1847
1848
1849
1850 u8 bf_trigger_max_cts_failure_dense_thr;
1851
1852
1853
1854 u8 bf_trigger_max_back_failure_thr;
1855
1856
1857
1858 u8 bf_trigger_max_back_failure_dense_thr;
1859 u8 reserved0;
1860
1861 __le32 wrong_sector_bis_thr;
1862
1863 u8 long_term_enable;
1864
1865
1866
1867 u8 long_term_update_thr;
1868
1869 u8 long_term_mbps_th_tbl[WMI_NUM_MCS];
1870 u8 reserved1;
1871
1872 __le16 long_term_trig_timeout_per_mcs[WMI_NUM_MCS];
1873 u8 reserved2[2];
1874 } __packed;
1875
1876
1877 struct wmi_bf_control_ex_mcs {
1878
1879 u8 long_term_mbps_th_tbl;
1880 u8 reserved;
1881
1882 __le16 long_term_trig_timeout_per_mcs;
1883 } __packed;
1884
1885
1886 struct wmi_bf_control_ex_cmd {
1887
1888 __le32 triggers;
1889
1890 u8 tx_mode;
1891
1892 u8 txss_mode;
1893
1894 u8 brp_mode;
1895
1896
1897
1898 u8 bf_trigger_max_cts_failure_thr;
1899
1900
1901
1902 u8 bf_trigger_max_cts_failure_dense_thr;
1903
1904
1905
1906 u8 bf_trigger_max_back_failure_thr;
1907
1908
1909
1910 u8 bf_trigger_max_back_failure_dense_thr;
1911 u8 reserved0;
1912
1913 __le32 wrong_sector_bis_thr;
1914
1915 u8 long_term_enable;
1916
1917
1918
1919 u8 long_term_update_thr;
1920 u8 each_mcs_cfg_size;
1921 u8 reserved1;
1922
1923 struct wmi_bf_control_ex_mcs each_mcs_cfg[0];
1924 } __packed;
1925
1926
1927 enum wmi_link_stats_action {
1928 WMI_LINK_STATS_SNAPSHOT = 0x00,
1929 WMI_LINK_STATS_PERIODIC = 0x01,
1930 WMI_LINK_STATS_STOP_PERIODIC = 0x02,
1931 };
1932
1933
1934 enum wmi_link_stats_record_type {
1935 WMI_LINK_STATS_TYPE_BASIC = 0x01,
1936 WMI_LINK_STATS_TYPE_GLOBAL = 0x02,
1937 };
1938
1939
1940 struct wmi_link_stats_cmd {
1941
1942
1943
1944 __le32 record_type_mask;
1945
1946 u8 cid;
1947
1948 u8 action;
1949 u8 reserved[6];
1950
1951 __le32 interval_msec;
1952 } __packed;
1953
1954
1955 struct wmi_set_grant_mcs_cmd {
1956 u8 mcs;
1957 u8 reserved[3];
1958 } __packed;
1959
1960
1961 struct wmi_set_ap_slot_size_cmd {
1962 __le32 slot_size;
1963 } __packed;
1964
1965
1966 struct wmi_temp_sense_all_cmd {
1967 u8 measure_baseband_en;
1968 u8 measure_rf_en;
1969 u8 measure_mode;
1970 u8 reserved;
1971 } __packed;
1972
1973
1974
1975
1976 enum wmi_event_id {
1977 WMI_READY_EVENTID = 0x1001,
1978 WMI_CONNECT_EVENTID = 0x1002,
1979 WMI_DISCONNECT_EVENTID = 0x1003,
1980 WMI_START_SCHED_SCAN_EVENTID = 0x1005,
1981 WMI_STOP_SCHED_SCAN_EVENTID = 0x1006,
1982 WMI_SCHED_SCAN_RESULT_EVENTID = 0x1007,
1983 WMI_SCAN_COMPLETE_EVENTID = 0x100A,
1984 WMI_REPORT_STATISTICS_EVENTID = 0x100B,
1985 WMI_FT_AUTH_STATUS_EVENTID = 0x100C,
1986 WMI_FT_REASSOC_STATUS_EVENTID = 0x100D,
1987 WMI_RADAR_GENERAL_CONFIG_EVENTID = 0x1100,
1988 WMI_RADAR_CONFIG_SELECT_EVENTID = 0x1101,
1989 WMI_RADAR_PARAMS_CONFIG_EVENTID = 0x1102,
1990 WMI_RADAR_SET_MODE_EVENTID = 0x1103,
1991 WMI_RADAR_CONTROL_EVENTID = 0x1104,
1992 WMI_RADAR_PCI_CONTROL_EVENTID = 0x1105,
1993 WMI_RD_MEM_RSP_EVENTID = 0x1800,
1994 WMI_FW_READY_EVENTID = 0x1801,
1995 WMI_EXIT_FAST_MEM_ACC_MODE_EVENTID = 0x200,
1996 WMI_ECHO_RSP_EVENTID = 0x1803,
1997 WMI_DEEP_ECHO_RSP_EVENTID = 0x1804,
1998
1999 WMI_FS_TUNE_DONE_EVENTID = 0x180A,
2000
2001 WMI_CORR_MEASURE_EVENTID = 0x180B,
2002 WMI_READ_RSSI_EVENTID = 0x180C,
2003 WMI_TEMP_SENSE_DONE_EVENTID = 0x180E,
2004 WMI_DC_CALIB_DONE_EVENTID = 0x180F,
2005
2006 WMI_IQ_TX_CALIB_DONE_EVENTID = 0x1811,
2007
2008 WMI_IQ_RX_CALIB_DONE_EVENTID = 0x1812,
2009 WMI_SET_WORK_MODE_DONE_EVENTID = 0x1815,
2010 WMI_LO_LEAKAGE_CALIB_DONE_EVENTID = 0x1816,
2011 WMI_LO_POWER_CALIB_FROM_OTP_EVENTID = 0x1817,
2012 WMI_SILENT_RSSI_CALIB_DONE_EVENTID = 0x181D,
2013
2014 WMI_RF_RX_TEST_DONE_EVENTID = 0x181E,
2015 WMI_CFG_RX_CHAIN_DONE_EVENTID = 0x1820,
2016 WMI_VRING_CFG_DONE_EVENTID = 0x1821,
2017 WMI_BA_STATUS_EVENTID = 0x1823,
2018 WMI_RCP_ADDBA_REQ_EVENTID = 0x1824,
2019 WMI_RCP_ADDBA_RESP_SENT_EVENTID = 0x1825,
2020 WMI_DELBA_EVENTID = 0x1826,
2021 WMI_GET_SSID_EVENTID = 0x1828,
2022 WMI_GET_PCP_CHANNEL_EVENTID = 0x182A,
2023
2024
2025
2026 WMI_SW_TX_COMPLETE_EVENTID = 0x182B,
2027 WMI_BEAMFORMING_MGMT_DONE_EVENTID = 0x1836,
2028 WMI_BF_TXSS_MGMT_DONE_EVENTID = 0x1837,
2029 WMI_BF_RXSS_MGMT_DONE_EVENTID = 0x1839,
2030 WMI_BF_TRIG_EVENTID = 0x183A,
2031 WMI_RS_MGMT_DONE_EVENTID = 0x1852,
2032 WMI_RF_MGMT_STATUS_EVENTID = 0x1853,
2033 WMI_BF_SM_MGMT_DONE_EVENTID = 0x1838,
2034 WMI_RX_MGMT_PACKET_EVENTID = 0x1840,
2035 WMI_TX_MGMT_PACKET_EVENTID = 0x1841,
2036 WMI_LINK_MAINTAIN_CFG_WRITE_DONE_EVENTID = 0x1842,
2037 WMI_LINK_MAINTAIN_CFG_READ_DONE_EVENTID = 0x1843,
2038 WMI_RF_XPM_READ_RESULT_EVENTID = 0x1856,
2039 WMI_RF_XPM_WRITE_RESULT_EVENTID = 0x1857,
2040 WMI_LED_CFG_DONE_EVENTID = 0x1858,
2041 WMI_SET_SILENT_RSSI_TABLE_DONE_EVENTID = 0x185C,
2042 WMI_RF_PWR_ON_DELAY_RSP_EVENTID = 0x185D,
2043 WMI_SET_HIGH_POWER_TABLE_PARAMS_EVENTID = 0x185E,
2044 WMI_FIXED_SCHEDULING_UL_CONFIG_EVENTID = 0x185F,
2045
2046 WMI_DATA_PORT_OPEN_EVENTID = 0x1860,
2047 WMI_WBE_LINK_DOWN_EVENTID = 0x1861,
2048 WMI_BF_CTRL_DONE_EVENTID = 0x1862,
2049 WMI_NOTIFY_REQ_DONE_EVENTID = 0x1863,
2050 WMI_GET_STATUS_DONE_EVENTID = 0x1864,
2051 WMI_RING_EN_EVENTID = 0x1865,
2052 WMI_GET_RF_STATUS_EVENTID = 0x1866,
2053 WMI_GET_BASEBAND_TYPE_EVENTID = 0x1867,
2054 WMI_VRING_SWITCH_TIMING_CONFIG_EVENTID = 0x1868,
2055 WMI_UNIT_TEST_EVENTID = 0x1900,
2056 WMI_FLASH_READ_DONE_EVENTID = 0x1902,
2057 WMI_FLASH_WRITE_DONE_EVENTID = 0x1903,
2058
2059 WMI_TRAFFIC_SUSPEND_EVENTID = 0x1904,
2060 WMI_TRAFFIC_RESUME_EVENTID = 0x1905,
2061
2062 WMI_P2P_CFG_DONE_EVENTID = 0x1910,
2063 WMI_PORT_ALLOCATED_EVENTID = 0x1911,
2064 WMI_PORT_DELETED_EVENTID = 0x1912,
2065 WMI_LISTEN_STARTED_EVENTID = 0x1914,
2066 WMI_SEARCH_STARTED_EVENTID = 0x1915,
2067 WMI_DISCOVERY_STARTED_EVENTID = 0x1916,
2068 WMI_DISCOVERY_STOPPED_EVENTID = 0x1917,
2069 WMI_PCP_STARTED_EVENTID = 0x1918,
2070 WMI_PCP_STOPPED_EVENTID = 0x1919,
2071 WMI_PCP_FACTOR_EVENTID = 0x191A,
2072
2073 WMI_PS_DEV_PROFILE_CFG_EVENTID = 0x191C,
2074 WMI_RS_ENABLE_EVENTID = 0x191E,
2075 WMI_RS_CFG_EX_EVENTID = 0x191F,
2076 WMI_GET_DETAILED_RS_RES_EX_EVENTID = 0x1920,
2077
2078 WMI_RS_CFG_DONE_EVENTID = 0x1921,
2079
2080 WMI_GET_DETAILED_RS_RES_EVENTID = 0x1922,
2081 WMI_AOA_MEAS_EVENTID = 0x1923,
2082 WMI_BRP_SET_ANT_LIMIT_EVENTID = 0x1924,
2083 WMI_SET_MGMT_RETRY_LIMIT_EVENTID = 0x1930,
2084 WMI_GET_MGMT_RETRY_LIMIT_EVENTID = 0x1931,
2085 WMI_SET_THERMAL_THROTTLING_CFG_EVENTID = 0x1940,
2086 WMI_GET_THERMAL_THROTTLING_CFG_EVENTID = 0x1941,
2087
2088 WMI_PS_DEV_PROFILE_CFG_READ_EVENTID = 0x1942,
2089 WMI_TSF_SYNC_STATUS_EVENTID = 0x1973,
2090 WMI_TOF_SESSION_END_EVENTID = 0x1991,
2091 WMI_TOF_GET_CAPABILITIES_EVENTID = 0x1992,
2092 WMI_TOF_SET_LCR_EVENTID = 0x1993,
2093 WMI_TOF_SET_LCI_EVENTID = 0x1994,
2094 WMI_TOF_FTM_PER_DEST_RES_EVENTID = 0x1995,
2095 WMI_TOF_CFG_RESPONDER_EVENTID = 0x1996,
2096 WMI_TOF_SET_TX_RX_OFFSET_EVENTID = 0x1997,
2097 WMI_TOF_GET_TX_RX_OFFSET_EVENTID = 0x1998,
2098 WMI_TOF_CHANNEL_INFO_EVENTID = 0x1999,
2099 WMI_GET_RF_SECTOR_PARAMS_DONE_EVENTID = 0x19A0,
2100 WMI_SET_RF_SECTOR_PARAMS_DONE_EVENTID = 0x19A1,
2101 WMI_GET_SELECTED_RF_SECTOR_INDEX_DONE_EVENTID = 0x19A2,
2102 WMI_SET_SELECTED_RF_SECTOR_INDEX_DONE_EVENTID = 0x19A3,
2103 WMI_SET_RF_SECTOR_ON_DONE_EVENTID = 0x19A4,
2104 WMI_PRIO_TX_SECTORS_ORDER_EVENTID = 0x19A5,
2105 WMI_PRIO_TX_SECTORS_NUMBER_EVENTID = 0x19A6,
2106 WMI_PRIO_TX_SECTORS_SET_DEFAULT_CFG_EVENTID = 0x19A7,
2107
2108 WMI_BF_CONTROL_EVENTID = 0x19AA,
2109 WMI_BF_CONTROL_EX_EVENTID = 0x19AB,
2110 WMI_TX_STATUS_RING_CFG_DONE_EVENTID = 0x19C0,
2111 WMI_RX_STATUS_RING_CFG_DONE_EVENTID = 0x19C1,
2112 WMI_TX_DESC_RING_CFG_DONE_EVENTID = 0x19C2,
2113 WMI_RX_DESC_RING_CFG_DONE_EVENTID = 0x19C3,
2114 WMI_CFG_DEF_RX_OFFLOAD_DONE_EVENTID = 0x19C5,
2115 WMI_SCHEDULING_SCHEME_EVENTID = 0x1A01,
2116 WMI_FIXED_SCHEDULING_CONFIG_COMPLETE_EVENTID = 0x1A02,
2117 WMI_ENABLE_FIXED_SCHEDULING_COMPLETE_EVENTID = 0x1A03,
2118 WMI_SET_MULTI_DIRECTED_OMNIS_CONFIG_EVENTID = 0x1A04,
2119 WMI_SET_LONG_RANGE_CONFIG_COMPLETE_EVENTID = 0x1A05,
2120 WMI_GET_ASSOC_LIST_RES_EVENTID = 0x1A06,
2121 WMI_GET_CCA_INDICATIONS_EVENTID = 0x1A07,
2122 WMI_SET_CCA_INDICATIONS_BI_AVG_NUM_EVENTID = 0x1A08,
2123 WMI_INTERNAL_FW_EVENT_EVENTID = 0x1A0A,
2124 WMI_INTERNAL_FW_IOCTL_EVENTID = 0x1A0B,
2125 WMI_LINK_STATS_CONFIG_DONE_EVENTID = 0x1A0C,
2126 WMI_LINK_STATS_EVENTID = 0x1A0D,
2127 WMI_SET_GRANT_MCS_EVENTID = 0x1A0E,
2128 WMI_SET_AP_SLOT_SIZE_EVENTID = 0x1A0F,
2129 WMI_SET_VRING_PRIORITY_WEIGHT_EVENTID = 0x1A10,
2130 WMI_SET_VRING_PRIORITY_EVENTID = 0x1A11,
2131 WMI_RBUFCAP_CFG_EVENTID = 0x1A12,
2132 WMI_TEMP_SENSE_ALL_DONE_EVENTID = 0x1A13,
2133 WMI_SET_CHANNEL_EVENTID = 0x9000,
2134 WMI_ASSOC_REQ_EVENTID = 0x9001,
2135 WMI_EAPOL_RX_EVENTID = 0x9002,
2136 WMI_MAC_ADDR_RESP_EVENTID = 0x9003,
2137 WMI_FW_VER_EVENTID = 0x9004,
2138 WMI_ACS_PASSIVE_SCAN_COMPLETE_EVENTID = 0x9005,
2139 WMI_INTERNAL_FW_SET_CHANNEL = 0x9006,
2140 WMI_COMMAND_NOT_SUPPORTED_EVENTID = 0xFFFF,
2141 };
2142
2143
2144 enum wmi_fw_status {
2145 WMI_FW_STATUS_SUCCESS = 0x00,
2146 WMI_FW_STATUS_FAILURE = 0x01,
2147 };
2148
2149
2150 enum wmi_rf_status {
2151 WMI_RF_ENABLED = 0x00,
2152 WMI_RF_DISABLED_HW = 0x01,
2153 WMI_RF_DISABLED_SW = 0x02,
2154 WMI_RF_DISABLED_HW_SW = 0x03,
2155 };
2156
2157
2158 struct wmi_rf_mgmt_status_event {
2159 __le32 rf_status;
2160 } __packed;
2161
2162
2163 struct wmi_get_status_done_event {
2164 __le32 is_associated;
2165 u8 cid;
2166 u8 reserved0[3];
2167 u8 bssid[WMI_MAC_LEN];
2168 u8 channel;
2169 u8 reserved1;
2170 u8 network_type;
2171 u8 reserved2[3];
2172 __le32 ssid_len;
2173 u8 ssid[WMI_MAX_SSID_LEN];
2174 __le32 rf_status;
2175 __le32 is_secured;
2176 } __packed;
2177
2178
2179 struct wmi_fw_ver_event {
2180
2181 __le32 fw_major;
2182 __le32 fw_minor;
2183 __le32 fw_subminor;
2184 __le32 fw_build;
2185
2186 __le32 hour;
2187 __le32 minute;
2188 __le32 second;
2189 __le32 day;
2190 __le32 month;
2191 __le32 year;
2192
2193 __le32 bl_major;
2194 __le32 bl_minor;
2195 __le32 bl_subminor;
2196 __le32 bl_build;
2197
2198 u8 fw_capabilities_len;
2199 u8 reserved[3];
2200
2201
2202
2203 __le32 fw_capabilities[0];
2204 } __packed;
2205
2206
2207 enum rf_type {
2208 RF_UNKNOWN = 0x00,
2209 RF_MARLON = 0x01,
2210 RF_SPARROW = 0x02,
2211 RF_TALYNA1 = 0x03,
2212 RF_TALYNA2 = 0x04,
2213 };
2214
2215
2216 enum board_file_rf_type {
2217 BF_RF_MARLON = 0x00,
2218 BF_RF_SPARROW = 0x01,
2219 BF_RF_TALYNA1 = 0x02,
2220 BF_RF_TALYNA2 = 0x03,
2221 };
2222
2223
2224 enum rf_status {
2225 RF_OK = 0x00,
2226 RF_NO_COMM = 0x01,
2227 RF_WRONG_BOARD_FILE = 0x02,
2228 };
2229
2230
2231 struct wmi_get_rf_status_event {
2232
2233 __le32 rf_type;
2234
2235 __le32 attached_rf_vector;
2236
2237 __le32 enabled_rf_vector;
2238
2239 u8 rf_status[32];
2240
2241 __le32 board_file_rf_type;
2242
2243 __le32 board_file_platform_type;
2244
2245 __le32 board_file_version;
2246
2247 __le32 enabled_xif_vector;
2248 __le32 reserved;
2249 } __packed;
2250
2251
2252 enum baseband_type {
2253 BASEBAND_UNKNOWN = 0x00,
2254 BASEBAND_SPARROW_M_A0 = 0x03,
2255 BASEBAND_SPARROW_M_A1 = 0x04,
2256 BASEBAND_SPARROW_M_B0 = 0x05,
2257 BASEBAND_SPARROW_M_C0 = 0x06,
2258 BASEBAND_SPARROW_M_D0 = 0x07,
2259 BASEBAND_TALYN_M_A0 = 0x08,
2260 BASEBAND_TALYN_M_B0 = 0x09,
2261 };
2262
2263
2264 struct wmi_get_baseband_type_event {
2265
2266 __le32 baseband_type;
2267 } __packed;
2268
2269
2270 struct wmi_mac_addr_resp_event {
2271 u8 mac[WMI_MAC_LEN];
2272 u8 auth_mode;
2273 u8 crypt_mode;
2274 __le32 offload_mode;
2275 } __packed;
2276
2277
2278 struct wmi_eapol_rx_event {
2279 u8 src_mac[WMI_MAC_LEN];
2280 __le16 eapol_len;
2281 u8 eapol[0];
2282 } __packed;
2283
2284
2285 enum wmi_phy_capability {
2286 WMI_11A_CAPABILITY = 0x01,
2287 WMI_11G_CAPABILITY = 0x02,
2288 WMI_11AG_CAPABILITY = 0x03,
2289 WMI_11NA_CAPABILITY = 0x04,
2290 WMI_11NG_CAPABILITY = 0x05,
2291 WMI_11NAG_CAPABILITY = 0x06,
2292 WMI_11AD_CAPABILITY = 0x07,
2293 WMI_11N_CAPABILITY_OFFSET = 0x03,
2294 };
2295
2296 struct wmi_ready_event {
2297 __le32 sw_version;
2298 __le32 abi_version;
2299 u8 mac[WMI_MAC_LEN];
2300
2301 u8 phy_capability;
2302 u8 numof_additional_mids;
2303
2304 u8 rfc_read_calib_result;
2305
2306
2307
2308 u8 max_assoc_sta;
2309 u8 reserved[2];
2310 } __packed;
2311
2312
2313 struct wmi_notify_req_done_event {
2314
2315 __le32 status;
2316 __le64 tsf;
2317 s8 rssi;
2318
2319 u8 tx_mode;
2320 u8 reserved0[2];
2321 __le32 tx_tpt;
2322 __le32 tx_goodput;
2323 __le32 rx_goodput;
2324 __le16 bf_mcs;
2325 __le16 my_rx_sector;
2326 __le16 my_tx_sector;
2327 __le16 other_rx_sector;
2328 __le16 other_tx_sector;
2329 __le16 range;
2330 u8 sqi;
2331 u8 reserved[3];
2332 } __packed;
2333
2334
2335 struct wmi_connect_event {
2336
2337
2338
2339 u8 channel;
2340
2341 u8 edmg_channel;
2342 u8 bssid[WMI_MAC_LEN];
2343 __le16 listen_interval;
2344 __le16 beacon_interval;
2345 u8 network_type;
2346 u8 reserved1[3];
2347 u8 beacon_ie_len;
2348 u8 assoc_req_len;
2349 u8 assoc_resp_len;
2350 u8 cid;
2351 u8 aid;
2352 u8 reserved2[2];
2353
2354 u8 assoc_info[0];
2355 } __packed;
2356
2357
2358 enum wmi_disconnect_reason {
2359 WMI_DIS_REASON_NO_NETWORK_AVAIL = 0x01,
2360
2361 WMI_DIS_REASON_LOST_LINK = 0x02,
2362 WMI_DIS_REASON_DISCONNECT_CMD = 0x03,
2363 WMI_DIS_REASON_BSS_DISCONNECTED = 0x04,
2364 WMI_DIS_REASON_AUTH_FAILED = 0x05,
2365 WMI_DIS_REASON_ASSOC_FAILED = 0x06,
2366 WMI_DIS_REASON_NO_RESOURCES_AVAIL = 0x07,
2367 WMI_DIS_REASON_CSERV_DISCONNECT = 0x08,
2368 WMI_DIS_REASON_INVALID_PROFILE = 0x0A,
2369 WMI_DIS_REASON_DOT11H_CHANNEL_SWITCH = 0x0B,
2370 WMI_DIS_REASON_PROFILE_MISMATCH = 0x0C,
2371 WMI_DIS_REASON_CONNECTION_EVICTED = 0x0D,
2372 WMI_DIS_REASON_IBSS_MERGE = 0x0E,
2373 WMI_DIS_REASON_HIGH_TEMPERATURE = 0x0F,
2374 };
2375
2376
2377 struct wmi_disconnect_event {
2378
2379 __le16 protocol_reason_status;
2380
2381 u8 bssid[WMI_MAC_LEN];
2382
2383 u8 disconnect_reason;
2384
2385 u8 assoc_resp_len;
2386
2387 u8 assoc_info[0];
2388 } __packed;
2389
2390
2391 enum scan_status {
2392 WMI_SCAN_SUCCESS = 0x00,
2393 WMI_SCAN_FAILED = 0x01,
2394 WMI_SCAN_ABORTED = 0x02,
2395 WMI_SCAN_REJECTED = 0x03,
2396 WMI_SCAN_ABORT_REJECTED = 0x04,
2397 };
2398
2399 struct wmi_scan_complete_event {
2400
2401 __le32 status;
2402 } __packed;
2403
2404
2405 struct wmi_ft_auth_status_event {
2406
2407 u8 status;
2408 u8 reserved[3];
2409 u8 mac_addr[WMI_MAC_LEN];
2410 __le16 ie_len;
2411 u8 ie_info[0];
2412 } __packed;
2413
2414
2415 struct wmi_ft_reassoc_status_event {
2416
2417 u8 status;
2418
2419 u8 aid;
2420
2421 u8 channel;
2422
2423 u8 edmg_channel;
2424 u8 mac_addr[WMI_MAC_LEN];
2425 __le16 beacon_ie_len;
2426 __le16 reassoc_req_ie_len;
2427 __le16 reassoc_resp_ie_len;
2428 u8 reserved[4];
2429 u8 ie_info[0];
2430 } __packed;
2431
2432
2433 struct wmi_rx_mgmt_info {
2434 u8 mcs;
2435 s8 rssi;
2436 u8 range;
2437 u8 sqi;
2438 __le16 stype;
2439 __le16 status;
2440 __le32 len;
2441
2442 u8 qid;
2443
2444 u8 mid;
2445 u8 cid;
2446
2447 u8 channel;
2448 } __packed;
2449
2450
2451 enum wmi_pno_result {
2452 WMI_PNO_SUCCESS = 0x00,
2453 WMI_PNO_REJECT = 0x01,
2454 WMI_PNO_INVALID_PARAMETERS = 0x02,
2455 WMI_PNO_NOT_ENABLED = 0x03,
2456 };
2457
2458 struct wmi_start_sched_scan_event {
2459
2460 u8 result;
2461 u8 reserved[3];
2462 } __packed;
2463
2464 struct wmi_stop_sched_scan_event {
2465
2466 u8 result;
2467 u8 reserved[3];
2468 } __packed;
2469
2470 struct wmi_sched_scan_result_event {
2471 struct wmi_rx_mgmt_info info;
2472 u8 payload[0];
2473 } __packed;
2474
2475
2476 enum wmi_acs_info_bitmask {
2477 WMI_ACS_INFO_BITMASK_BEACON_FOUND = 0x01,
2478 WMI_ACS_INFO_BITMASK_BUSY_TIME = 0x02,
2479 WMI_ACS_INFO_BITMASK_TX_TIME = 0x04,
2480 WMI_ACS_INFO_BITMASK_RX_TIME = 0x08,
2481 WMI_ACS_INFO_BITMASK_NOISE = 0x10,
2482 };
2483
2484 struct scan_acs_info {
2485 u8 channel;
2486 u8 beacon_found;
2487
2488 __le16 busy_time;
2489 __le16 tx_time;
2490 __le16 rx_time;
2491 u8 noise;
2492 u8 reserved[3];
2493 } __packed;
2494
2495 struct wmi_acs_passive_scan_complete_event {
2496 __le32 dwell_time;
2497
2498
2499
2500 __le16 filled;
2501 u8 num_scanned_channels;
2502 u8 reserved;
2503 struct scan_acs_info scan_info_list[0];
2504 } __packed;
2505
2506
2507 enum wmi_vring_ba_status {
2508 WMI_BA_AGREED = 0x00,
2509 WMI_BA_NON_AGREED = 0x01,
2510
2511 WMI_BA_TD_WIP = 0x02,
2512
2513 WMI_BA_SETUP_WIP = 0x03,
2514
2515 WMI_BA_SESSION_ACTIVE = 0x04,
2516
2517 WMI_BA_SESSION_NOT_ACTIVE = 0x05,
2518 };
2519
2520 struct wmi_ba_status_event {
2521
2522 __le16 status;
2523 u8 reserved[2];
2524 u8 ringid;
2525 u8 agg_wsize;
2526 __le16 ba_timeout;
2527 u8 amsdu;
2528 } __packed;
2529
2530
2531 struct wmi_delba_event {
2532
2533
2534
2535 u8 cidxtid;
2536 u8 from_initiator;
2537 __le16 reason;
2538
2539 u8 cid;
2540
2541 u8 tid;
2542 u8 reserved[2];
2543 } __packed;
2544
2545
2546 struct wmi_vring_cfg_done_event {
2547 u8 ringid;
2548 u8 status;
2549 u8 reserved[2];
2550 __le32 tx_vring_tail_ptr;
2551 } __packed;
2552
2553
2554 struct wmi_rcp_addba_resp_sent_event {
2555
2556
2557
2558 u8 cidxtid;
2559 u8 reserved;
2560 __le16 status;
2561
2562 u8 cid;
2563
2564 u8 tid;
2565 u8 reserved2[2];
2566 } __packed;
2567
2568
2569 struct wmi_tx_status_ring_cfg_done_event {
2570 u8 ring_id;
2571
2572 u8 status;
2573 u8 reserved[2];
2574 __le32 ring_tail_ptr;
2575 } __packed;
2576
2577
2578 struct wmi_rx_status_ring_cfg_done_event {
2579 u8 ring_id;
2580
2581 u8 status;
2582 u8 reserved[2];
2583 __le32 ring_tail_ptr;
2584 } __packed;
2585
2586
2587 struct wmi_cfg_def_rx_offload_done_event {
2588
2589 u8 status;
2590 u8 reserved[3];
2591 } __packed;
2592
2593
2594 struct wmi_tx_desc_ring_cfg_done_event {
2595 u8 ring_id;
2596
2597 u8 status;
2598 u8 reserved[2];
2599 __le32 ring_tail_ptr;
2600 } __packed;
2601
2602
2603 struct wmi_rx_desc_ring_cfg_done_event {
2604 u8 ring_id;
2605
2606 u8 status;
2607 u8 reserved[2];
2608 __le32 ring_tail_ptr;
2609 } __packed;
2610
2611
2612 struct wmi_rcp_addba_req_event {
2613
2614
2615
2616 u8 cidxtid;
2617 u8 dialog_token;
2618
2619 __le16 ba_param_set;
2620 __le16 ba_timeout;
2621
2622 __le16 ba_seq_ctrl;
2623
2624 u8 cid;
2625
2626 u8 tid;
2627 u8 reserved[2];
2628 } __packed;
2629
2630
2631 enum wmi_cfg_rx_chain_done_event_status {
2632 WMI_CFG_RX_CHAIN_SUCCESS = 0x01,
2633 };
2634
2635 struct wmi_cfg_rx_chain_done_event {
2636
2637 __le32 rx_ring_tail_ptr;
2638 __le32 status;
2639 } __packed;
2640
2641
2642 enum wmi_wbe_link_down_event_reason {
2643 WMI_WBE_REASON_USER_REQUEST = 0x00,
2644 WMI_WBE_REASON_RX_DISASSOC = 0x01,
2645 WMI_WBE_REASON_BAD_PHY_LINK = 0x02,
2646 };
2647
2648
2649 struct wmi_wbe_link_down_event {
2650 u8 cid;
2651 u8 reserved[3];
2652 __le32 reason;
2653 } __packed;
2654
2655
2656 struct wmi_data_port_open_event {
2657 u8 cid;
2658 u8 reserved[3];
2659 } __packed;
2660
2661
2662 struct wmi_ring_en_event {
2663 u8 ring_index;
2664 u8 reserved[3];
2665 } __packed;
2666
2667
2668 struct wmi_get_pcp_channel_event {
2669 u8 channel;
2670 u8 reserved[3];
2671 } __packed;
2672
2673
2674 struct wmi_p2p_cfg_done_event {
2675
2676 u8 status;
2677 u8 reserved[3];
2678 } __packed;
2679
2680
2681 struct wmi_port_allocated_event {
2682
2683 u8 status;
2684 u8 reserved[3];
2685 } __packed;
2686
2687
2688 struct wmi_port_deleted_event {
2689
2690 u8 status;
2691 u8 reserved[3];
2692 } __packed;
2693
2694
2695 struct wmi_listen_started_event {
2696
2697 u8 status;
2698 u8 reserved[3];
2699 } __packed;
2700
2701
2702 struct wmi_search_started_event {
2703
2704 u8 status;
2705 u8 reserved[3];
2706 } __packed;
2707
2708
2709 struct wmi_pcp_started_event {
2710
2711 u8 status;
2712 u8 reserved[3];
2713 } __packed;
2714
2715
2716 struct wmi_pcp_factor_event {
2717 __le32 pcp_factor;
2718 } __packed;
2719
2720 enum wmi_sw_tx_status {
2721 WMI_TX_SW_STATUS_SUCCESS = 0x00,
2722 WMI_TX_SW_STATUS_FAILED_NO_RESOURCES = 0x01,
2723 WMI_TX_SW_STATUS_FAILED_TX = 0x02,
2724 };
2725
2726
2727 struct wmi_sw_tx_complete_event {
2728
2729 u8 status;
2730 u8 reserved[3];
2731 } __packed;
2732
2733
2734 struct wmi_corr_measure_event {
2735
2736 __le32 i;
2737
2738 __le32 q;
2739
2740 __le32 image_i;
2741
2742 __le32 image_q;
2743 } __packed;
2744
2745
2746 struct wmi_read_rssi_event {
2747 __le32 ina_rssi_adc_dbm;
2748 } __packed;
2749
2750
2751 struct wmi_get_ssid_event {
2752 __le32 ssid_len;
2753 u8 ssid[WMI_MAX_SSID_LEN];
2754 } __packed;
2755
2756
2757 struct wmi_rf_xpm_read_result_event {
2758
2759 u8 status;
2760 u8 reserved[3];
2761
2762 u8 data_bytes[0];
2763 } __packed;
2764
2765
2766 struct wmi_rf_xpm_write_result_event {
2767
2768 u8 status;
2769 u8 reserved[3];
2770 } __packed;
2771
2772
2773 struct wmi_tx_mgmt_packet_event {
2774 u8 payload[0];
2775 } __packed;
2776
2777
2778 struct wmi_rx_mgmt_packet_event {
2779 struct wmi_rx_mgmt_info info;
2780 u8 payload[0];
2781 } __packed;
2782
2783
2784 struct wmi_echo_rsp_event {
2785 __le32 echoed_value;
2786 } __packed;
2787
2788
2789 struct wmi_deep_echo_rsp_event {
2790 __le32 echoed_value;
2791 } __packed;
2792
2793
2794 struct wmi_rf_pwr_on_delay_rsp_event {
2795
2796 u8 status;
2797 u8 reserved[3];
2798 } __packed;
2799
2800
2801 struct wmi_set_high_power_table_params_event {
2802
2803 u8 status;
2804 u8 reserved[3];
2805 } __packed;
2806
2807
2808 struct wmi_fixed_scheduling_ul_config_event {
2809
2810 u8 status;
2811 u8 reserved[3];
2812 } __packed;
2813
2814
2815
2816
2817
2818 struct wmi_temp_sense_done_event {
2819
2820
2821
2822
2823 __le32 baseband_t1000;
2824
2825
2826
2827
2828 __le32 rf_t1000;
2829 } __packed;
2830
2831 #define WMI_SCAN_DWELL_TIME_MS (100)
2832 #define WMI_SURVEY_TIMEOUT_MS (10000)
2833
2834 enum wmi_hidden_ssid {
2835 WMI_HIDDEN_SSID_DISABLED = 0x00,
2836 WMI_HIDDEN_SSID_SEND_EMPTY = 0x10,
2837 WMI_HIDDEN_SSID_CLEAR = 0xFE,
2838 };
2839
2840
2841
2842
2843
2844
2845
2846
2847 enum led_mode {
2848 LED_DISABLE = 0x00,
2849 LED_ENABLE = 0x01,
2850 };
2851
2852
2853
2854
2855 enum wmi_led_id {
2856 WMI_LED_WLAN = 0x00,
2857 WMI_LED_WPAN = 0x01,
2858 WMI_LED_WWAN = 0x02,
2859 };
2860
2861
2862 enum wmi_led_polarity {
2863 LED_POLARITY_HIGH_ACTIVE = 0x00,
2864 LED_POLARITY_LOW_ACTIVE = 0x01,
2865 };
2866
2867
2868
2869
2870 struct wmi_led_blink_mode {
2871 __le32 blink_on;
2872 __le32 blink_off;
2873 } __packed;
2874
2875
2876 struct wmi_led_cfg_cmd {
2877
2878 u8 led_mode;
2879
2880 u8 id;
2881
2882 struct wmi_led_blink_mode slow_blink_cfg;
2883
2884 struct wmi_led_blink_mode medium_blink_cfg;
2885
2886 struct wmi_led_blink_mode fast_blink_cfg;
2887
2888 u8 led_polarity;
2889
2890 u8 reserved;
2891 } __packed;
2892
2893
2894 struct wmi_set_connect_snr_thr_cmd {
2895 u8 enable;
2896 u8 reserved;
2897
2898 __le16 omni_snr_thr;
2899
2900 __le16 direct_snr_thr;
2901 } __packed;
2902
2903
2904 struct wmi_led_cfg_done_event {
2905
2906 __le32 status;
2907 } __packed;
2908
2909
2910 struct wmi_rs_cfg {
2911
2912
2913
2914 u8 per_threshold[WMI_NUM_MCS];
2915
2916
2917
2918
2919 u8 min_frame_cnt[WMI_NUM_MCS];
2920
2921 u8 stop_th;
2922
2923 u8 mcs1_fail_th;
2924 u8 max_back_failure_th;
2925
2926
2927
2928 u8 dbg_disable_internal_trigger;
2929 __le32 back_failure_mask;
2930 __le32 mcs_en_vec;
2931 } __packed;
2932
2933 enum wmi_edmg_tx_mode {
2934 WMI_TX_MODE_DMG = 0x0,
2935 WMI_TX_MODE_EDMG_CB1 = 0x1,
2936 WMI_TX_MODE_EDMG_CB2 = 0x2,
2937 WMI_TX_MODE_EDMG_CB1_LONG_LDPC = 0x3,
2938 WMI_TX_MODE_EDMG_CB2_LONG_LDPC = 0x4,
2939 WMI_TX_MODE_MAX,
2940 };
2941
2942
2943 struct wmi_rs_cfg_ex_common {
2944
2945 u8 mode;
2946
2947 u8 stop_th;
2948
2949 u8 mcs1_fail_th;
2950 u8 max_back_failure_th;
2951
2952
2953
2954 u8 dbg_disable_internal_trigger;
2955 u8 reserved[3];
2956 __le32 back_failure_mask;
2957 } __packed;
2958
2959
2960 struct wmi_rs_cfg_ex_mcs {
2961
2962
2963
2964 u8 per_threshold;
2965
2966
2967
2968
2969 u8 min_frame_cnt;
2970 u8 reserved[2];
2971 } __packed;
2972
2973
2974 struct wmi_rs_cfg_ex_cmd {
2975
2976 struct wmi_rs_cfg_ex_common common_cfg;
2977 u8 each_mcs_cfg_size;
2978 u8 reserved[3];
2979
2980 struct wmi_rs_cfg_ex_mcs each_mcs_cfg[0];
2981 } __packed;
2982
2983
2984 struct wmi_rs_cfg_ex_event {
2985
2986 u8 mode;
2987
2988 u8 status;
2989 u8 reserved[2];
2990 } __packed;
2991
2992
2993 struct wmi_rs_enable_cmd {
2994 u8 cid;
2995
2996 u8 rs_enable;
2997 u8 reserved[2];
2998 __le32 mcs_en_vec;
2999 } __packed;
3000
3001
3002 struct wmi_rs_enable_event {
3003
3004 u8 status;
3005 u8 reserved[3];
3006 } __packed;
3007
3008
3009 enum wmi_sched_scheme_slot_type {
3010 WMI_SCHED_SLOT_SP = 0x0,
3011 WMI_SCHED_SLOT_CBAP = 0x1,
3012 WMI_SCHED_SLOT_IDLE = 0x2,
3013 WMI_SCHED_SLOT_ANNOUNCE_NO_ACK = 0x3,
3014 WMI_SCHED_SLOT_DISCOVERY = 0x4,
3015 };
3016
3017 enum wmi_sched_scheme_slot_flags {
3018 WMI_SCHED_SCHEME_SLOT_PERIODIC = 0x1,
3019 };
3020
3021 struct wmi_sched_scheme_slot {
3022
3023 __le32 tbtt_offset;
3024
3025 u8 flags;
3026
3027 u8 type;
3028
3029 __le16 duration;
3030
3031 __le16 tx_op;
3032
3033
3034
3035 __le16 period;
3036
3037
3038
3039 u8 num_of_blocks;
3040
3041
3042
3043 u8 idle_period;
3044 u8 src_aid;
3045 u8 dest_aid;
3046 __le32 reserved;
3047 } __packed;
3048
3049 enum wmi_sched_scheme_flags {
3050
3051 WMI_SCHED_SCHEME_ENABLE = 0x01,
3052 WMI_SCHED_PROTECTED_SP = 0x02,
3053
3054 WMI_SCHED_FIRST = 0x04,
3055
3056 WMI_SCHED_LAST = 0x08,
3057 WMI_SCHED_IMMEDIATE_START = 0x10,
3058 };
3059
3060 enum wmi_sched_scheme_advertisment {
3061
3062
3063
3064 WMI_ADVERTISE_ESE_DISABLED = 0x0,
3065 WMI_ADVERTISE_ESE_IN_BEACON = 0x1,
3066 WMI_ADVERTISE_ESE_IN_ANNOUNCE_FRAME = 0x2,
3067 };
3068
3069
3070 struct wmi_scheduling_scheme_cmd {
3071 u8 serial_num;
3072
3073 u8 ese_advertisment;
3074
3075 __le16 flags;
3076 u8 num_allocs;
3077 u8 reserved[3];
3078 __le64 start_tbtt;
3079
3080 struct wmi_sched_scheme_slot allocs[WMI_SCHED_MAX_ALLOCS_PER_CMD];
3081 } __packed;
3082
3083 enum wmi_sched_scheme_failure_type {
3084 WMI_SCHED_SCHEME_FAILURE_NO_ERROR = 0x00,
3085 WMI_SCHED_SCHEME_FAILURE_OLD_START_TSF_ERR = 0x01,
3086 };
3087
3088
3089 struct wmi_scheduling_scheme_event {
3090
3091 u8 status;
3092
3093 u8 serial_num;
3094
3095 u8 failure_type;
3096
3097 u8 reserved[1];
3098 } __packed;
3099
3100
3101 struct wmi_rs_cfg_cmd {
3102
3103 u8 cid;
3104
3105 u8 rs_enable;
3106
3107 struct wmi_rs_cfg rs_cfg;
3108 } __packed;
3109
3110
3111 struct wmi_rs_cfg_done_event {
3112 u8 cid;
3113
3114 u8 status;
3115 u8 reserved[2];
3116 } __packed;
3117
3118
3119 struct wmi_get_detailed_rs_res_cmd {
3120
3121 u8 cid;
3122 u8 reserved[3];
3123 } __packed;
3124
3125
3126 enum wmi_rs_results_status {
3127 WMI_RS_RES_VALID = 0x00,
3128 WMI_RS_RES_INVALID = 0x01,
3129 };
3130
3131
3132 struct wmi_rs_results {
3133
3134 u8 num_of_tx_pkt[WMI_NUM_MCS];
3135
3136 u8 num_of_non_acked_pkt[WMI_NUM_MCS];
3137
3138 __le32 tsf;
3139
3140 u8 mcs;
3141 } __packed;
3142
3143
3144 struct wmi_get_detailed_rs_res_event {
3145 u8 cid;
3146
3147 u8 status;
3148
3149 struct wmi_rs_results rs_results;
3150 u8 reserved[3];
3151 } __packed;
3152
3153
3154 struct wmi_get_detailed_rs_res_ex_cmd {
3155 u8 cid;
3156 u8 reserved[3];
3157 } __packed;
3158
3159
3160 struct wmi_rs_results_ex_common {
3161
3162 __le32 tsf;
3163
3164 u8 mcs;
3165
3166 u8 mode;
3167 u8 reserved[2];
3168 } __packed;
3169
3170
3171 struct wmi_rs_results_ex_mcs {
3172
3173 u8 num_of_tx_pkt;
3174
3175 u8 num_of_non_acked_pkt;
3176 u8 reserved[2];
3177 } __packed;
3178
3179
3180 struct wmi_get_detailed_rs_res_ex_event {
3181 u8 cid;
3182
3183 u8 status;
3184 u8 reserved0[2];
3185 struct wmi_rs_results_ex_common common_rs_results;
3186 u8 each_mcs_results_size;
3187 u8 reserved1[3];
3188
3189 struct wmi_rs_results_ex_mcs each_mcs_results[0];
3190 } __packed;
3191
3192
3193 enum wmi_brp_ant_limit_mode {
3194
3195 WMI_BRP_ANT_LIMIT_MODE_DISABLE = 0x00,
3196
3197
3198
3199 WMI_BRP_ANT_LIMIT_MODE_EFFECTIVE = 0x01,
3200
3201 WMI_BRP_ANT_LIMIT_MODE_FORCE = 0x02,
3202
3203 WMI_BRP_ANT_LIMIT_MODES_NUM = 0x03,
3204 };
3205
3206
3207 struct wmi_brp_set_ant_limit_cmd {
3208
3209 u8 cid;
3210
3211 u8 limit_mode;
3212
3213
3214
3215
3216
3217 u8 ant_limit;
3218 u8 reserved;
3219 } __packed;
3220
3221
3222 struct wmi_brp_set_ant_limit_event {
3223
3224 u8 status;
3225 u8 reserved[3];
3226 } __packed;
3227
3228 enum wmi_bf_type {
3229 WMI_BF_TYPE_SLS = 0x00,
3230 WMI_BF_TYPE_BRP_RX = 0x01,
3231 };
3232
3233
3234 struct wmi_bf_trig_cmd {
3235
3236 u8 bf_type;
3237
3238 u8 cid;
3239
3240 u8 dst_mac[WMI_MAC_LEN];
3241 u8 reserved[4];
3242 } __packed;
3243
3244
3245 struct wmi_bf_trig_event {
3246
3247 u8 status;
3248 u8 cid;
3249 u8 reserved[2];
3250 } __packed;
3251
3252
3253 #define WMI_LINK_MAINTAIN_CFG_CID_BROADCAST (0xFFFFFFFF)
3254
3255
3256 enum wmi_link_maintain_cfg_type {
3257
3258 WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_NORMAL_AP = 0x00,
3259
3260 WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_FST_AP = 0x01,
3261
3262 WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_NORMAL_STA = 0x02,
3263
3264 WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_FST_STA = 0x03,
3265
3266 WMI_LINK_MAINTAIN_CFG_TYPE_CUSTOM = 0x04,
3267
3268 WMI_LINK_MAINTAIN_CFG_TYPES_NUM = 0x05,
3269 };
3270
3271
3272 enum wmi_link_maintain_cfg_response_status {
3273
3274
3275 WMI_LINK_MAINTAIN_CFG_RESPONSE_STATUS_OK = 0x00,
3276
3277
3278
3279 WMI_LINK_MAINTAIN_CFG_RESPONSE_STATUS_BAD_ARGUMENT = 0x01,
3280 };
3281
3282
3283 struct wmi_link_maintain_cfg {
3284
3285 __le32 link_loss_enable_detectors_vec;
3286
3287 __le32 check_link_loss_period_usec;
3288
3289 __le32 tx_ageing_threshold_usec;
3290
3291 __le32 keep_alive_period_usec_high_snr;
3292
3293 __le32 keep_alive_period_usec_low_snr;
3294
3295 __le32 keep_alive_snr_threshold_low_db;
3296
3297 __le32 keep_alive_snr_threshold_high_db;
3298
3299 __le32 bad_beacons_num_threshold;
3300
3301 __le32 bad_beacons_snr_threshold_db;
3302
3303 __le32 disconnect_timeout;
3304 } __packed;
3305
3306
3307 struct wmi_link_maintain_cfg_write_cmd {
3308
3309
3310
3311 __le32 cfg_type;
3312
3313 __le32 cid;
3314
3315
3316
3317 struct wmi_link_maintain_cfg lm_cfg;
3318 } __packed;
3319
3320
3321 struct wmi_link_maintain_cfg_read_cmd {
3322
3323 __le32 cid;
3324 } __packed;
3325
3326
3327 struct wmi_link_maintain_cfg_write_done_event {
3328
3329 __le32 cid;
3330
3331 __le32 status;
3332 } __packed;
3333
3334
3335 struct wmi_link_maintain_cfg_read_done_event {
3336
3337 __le32 cid;
3338
3339 __le32 status;
3340
3341 struct wmi_link_maintain_cfg lm_cfg;
3342 } __packed;
3343
3344 enum wmi_traffic_suspend_status {
3345 WMI_TRAFFIC_SUSPEND_APPROVED = 0x0,
3346 WMI_TRAFFIC_SUSPEND_REJECTED_LINK_NOT_IDLE = 0x1,
3347 WMI_TRAFFIC_SUSPEND_REJECTED_DISCONNECT = 0x2,
3348 WMI_TRAFFIC_SUSPEND_REJECTED_OTHER = 0x3,
3349 };
3350
3351
3352 struct wmi_traffic_suspend_event {
3353
3354 u8 status;
3355 } __packed;
3356
3357 enum wmi_traffic_resume_status {
3358 WMI_TRAFFIC_RESUME_SUCCESS = 0x0,
3359 WMI_TRAFFIC_RESUME_FAILED = 0x1,
3360 };
3361
3362 enum wmi_resume_trigger {
3363 WMI_RESUME_TRIGGER_UNKNOWN = 0x0,
3364 WMI_RESUME_TRIGGER_HOST = 0x1,
3365 WMI_RESUME_TRIGGER_UCAST_RX = 0x2,
3366 WMI_RESUME_TRIGGER_BCAST_RX = 0x4,
3367 WMI_RESUME_TRIGGER_WMI_EVT = 0x8,
3368 WMI_RESUME_TRIGGER_DISCONNECT = 0x10,
3369 };
3370
3371
3372 struct wmi_traffic_resume_event {
3373
3374 u8 status;
3375 u8 reserved[3];
3376
3377 __le32 resume_triggers;
3378 } __packed;
3379
3380
3381 enum wmi_ps_cfg_cmd_status {
3382 WMI_PS_CFG_CMD_STATUS_SUCCESS = 0x00,
3383 WMI_PS_CFG_CMD_STATUS_BAD_PARAM = 0x01,
3384
3385 WMI_PS_CFG_CMD_STATUS_ERROR = 0x02,
3386 };
3387
3388
3389 enum wmi_ps_profile_type {
3390 WMI_PS_PROFILE_TYPE_DEFAULT = 0x00,
3391 WMI_PS_PROFILE_TYPE_PS_DISABLED = 0x01,
3392 WMI_PS_PROFILE_TYPE_MAX_PS = 0x02,
3393 WMI_PS_PROFILE_TYPE_LOW_LATENCY_PS = 0x03,
3394 };
3395
3396
3397 struct wmi_ps_dev_profile_cfg_read_cmd {
3398
3399 __le32 reserved;
3400 } __packed;
3401
3402
3403 struct wmi_ps_dev_profile_cfg_read_event {
3404
3405 u8 ps_profile;
3406 u8 reserved[3];
3407 } __packed;
3408
3409
3410
3411
3412
3413
3414
3415
3416 struct wmi_ps_dev_profile_cfg_cmd {
3417
3418 u8 ps_profile;
3419 u8 reserved[3];
3420 } __packed;
3421
3422
3423 struct wmi_ps_dev_profile_cfg_event {
3424
3425 __le32 status;
3426 } __packed;
3427
3428 enum wmi_ps_level {
3429 WMI_PS_LEVEL_DEEP_SLEEP = 0x00,
3430 WMI_PS_LEVEL_SHALLOW_SLEEP = 0x01,
3431
3432 WMI_PS_LEVEL_AWAKE = 0x02,
3433 };
3434
3435 enum wmi_ps_deep_sleep_clk_level {
3436
3437 WMI_PS_DEEP_SLEEP_CLK_LEVEL_RTC = 0x00,
3438
3439 WMI_PS_DEEP_SLEEP_CLK_LEVEL_OSC = 0x01,
3440
3441 WMI_PS_DEEP_SLEEP_CLK_LEVEL_RTC_LT = 0x02,
3442 WMI_PS_DEEP_SLEEP_CLK_LEVEL_XTAL = 0x03,
3443 WMI_PS_DEEP_SLEEP_CLK_LEVEL_SYSCLK = 0x04,
3444
3445 WMI_PS_DEEP_SLEEP_CLK_LEVEL_N_A = 0xFF,
3446 };
3447
3448
3449 enum wmi_ps_d3_resp_policy {
3450 WMI_PS_D3_RESP_POLICY_DEFAULT = 0x00,
3451
3452 WMI_PS_D3_RESP_POLICY_DENIED = 0x01,
3453
3454 WMI_PS_D3_RESP_POLICY_APPROVED = 0x02,
3455 };
3456
3457 #define WMI_AOA_MAX_DATA_SIZE (128)
3458
3459 enum wmi_aoa_meas_status {
3460 WMI_AOA_MEAS_SUCCESS = 0x00,
3461 WMI_AOA_MEAS_PEER_INCAPABLE = 0x01,
3462 WMI_AOA_MEAS_FAILURE = 0x02,
3463 };
3464
3465
3466 struct wmi_aoa_meas_event {
3467 u8 mac_addr[WMI_MAC_LEN];
3468
3469
3470
3471
3472
3473 u8 channel;
3474
3475 u8 aoa_meas_type;
3476
3477 __le32 meas_rf_mask;
3478
3479 u8 meas_status;
3480 u8 reserved;
3481
3482 __le16 length;
3483 u8 meas_data[WMI_AOA_MAX_DATA_SIZE];
3484 } __packed;
3485
3486
3487 struct wmi_set_mgmt_retry_limit_event {
3488
3489 u8 status;
3490
3491 u8 reserved[3];
3492 } __packed;
3493
3494
3495 struct wmi_get_mgmt_retry_limit_event {
3496
3497 u8 mgmt_retry_limit;
3498
3499 u8 reserved[3];
3500 } __packed;
3501
3502
3503 struct wmi_tof_get_capabilities_event {
3504 u8 ftm_capability;
3505
3506 u8 max_num_of_dest;
3507
3508 u8 max_num_of_meas_per_burst;
3509 u8 reserved;
3510
3511 __le16 max_multi_bursts_sessions;
3512
3513 __le16 max_ftm_burst_duration;
3514
3515 __le32 aoa_supported_types;
3516 } __packed;
3517
3518
3519 struct wmi_set_thermal_throttling_cfg_event {
3520
3521 u8 status;
3522 u8 reserved[3];
3523 } __packed;
3524
3525
3526 struct wmi_get_thermal_throttling_cfg_event {
3527
3528 struct wmi_tt_data tt_data;
3529 } __packed;
3530
3531 enum wmi_tof_session_end_status {
3532 WMI_TOF_SESSION_END_NO_ERROR = 0x00,
3533 WMI_TOF_SESSION_END_FAIL = 0x01,
3534 WMI_TOF_SESSION_END_PARAMS_ERROR = 0x02,
3535 WMI_TOF_SESSION_END_ABORTED = 0x03,
3536 WMI_TOF_SESSION_END_BUSY = 0x04,
3537 };
3538
3539
3540 struct wmi_tof_session_end_event {
3541
3542 __le32 session_id;
3543
3544 u8 status;
3545 u8 reserved[3];
3546 } __packed;
3547
3548
3549 struct wmi_tof_set_lci_event {
3550
3551 u8 status;
3552 u8 reserved[3];
3553 } __packed;
3554
3555
3556 struct wmi_tof_set_lcr_event {
3557
3558 u8 status;
3559 u8 reserved[3];
3560 } __packed;
3561
3562
3563 struct wmi_responder_ftm_res {
3564 u8 t1[6];
3565 u8 t2[6];
3566 u8 t3[6];
3567 u8 t4[6];
3568 __le16 tod_err;
3569 __le16 toa_err;
3570 __le16 tod_err_initiator;
3571 __le16 toa_err_initiator;
3572 } __packed;
3573
3574 enum wmi_tof_ftm_per_dest_res_status {
3575 WMI_PER_DEST_RES_NO_ERROR = 0x00,
3576 WMI_PER_DEST_RES_TX_RX_FAIL = 0x01,
3577 WMI_PER_DEST_RES_PARAM_DONT_MATCH = 0x02,
3578 };
3579
3580 enum wmi_tof_ftm_per_dest_res_flags {
3581 WMI_PER_DEST_RES_REQ_START = 0x01,
3582 WMI_PER_DEST_RES_BURST_REPORT_END = 0x02,
3583 WMI_PER_DEST_RES_REQ_END = 0x04,
3584 WMI_PER_DEST_RES_PARAM_UPDATE = 0x08,
3585 };
3586
3587
3588 struct wmi_tof_ftm_per_dest_res_event {
3589
3590 __le32 session_id;
3591
3592 u8 dst_mac[WMI_MAC_LEN];
3593
3594 u8 flags;
3595
3596 u8 status;
3597
3598 u8 responder_asap;
3599
3600 u8 responder_num_ftm_per_burst;
3601
3602 u8 responder_num_ftm_bursts_exp;
3603
3604 u8 responder_burst_duration;
3605
3606
3607
3608 __le16 responder_burst_period;
3609
3610 __le16 bursts_cnt;
3611
3612 __le32 tsf_sync;
3613
3614 u8 actual_ftm_per_burst;
3615
3616 __le32 meas_rf_mask;
3617 u8 reserved0[3];
3618 struct wmi_responder_ftm_res responder_ftm_res[0];
3619 } __packed;
3620
3621
3622 struct wmi_tof_cfg_responder_event {
3623
3624 u8 status;
3625 u8 reserved[3];
3626 } __packed;
3627
3628 enum wmi_tof_channel_info_type {
3629 WMI_TOF_CHANNEL_INFO_AOA = 0x00,
3630 WMI_TOF_CHANNEL_INFO_LCI = 0x01,
3631 WMI_TOF_CHANNEL_INFO_LCR = 0x02,
3632 WMI_TOF_CHANNEL_INFO_VENDOR_SPECIFIC = 0x03,
3633 WMI_TOF_CHANNEL_INFO_CIR = 0x04,
3634 WMI_TOF_CHANNEL_INFO_RSSI = 0x05,
3635 WMI_TOF_CHANNEL_INFO_SNR = 0x06,
3636 WMI_TOF_CHANNEL_INFO_DEBUG = 0x07,
3637 };
3638
3639
3640 struct wmi_tof_channel_info_event {
3641
3642 __le32 session_id;
3643
3644 u8 dst_mac[WMI_MAC_LEN];
3645
3646 u8 type;
3647
3648 u8 len;
3649
3650 u8 report[0];
3651 } __packed;
3652
3653
3654 struct wmi_tof_set_tx_rx_offset_event {
3655
3656 u8 status;
3657 u8 reserved[3];
3658 } __packed;
3659
3660
3661 struct wmi_tof_get_tx_rx_offset_event {
3662
3663 u8 status;
3664
3665 u8 rf_index;
3666 u8 reserved1[2];
3667
3668 __le32 tx_offset;
3669
3670 __le32 rx_offset;
3671
3672 __le32 precursor;
3673 } __packed;
3674
3675
3676 enum wmi_rf_sector_status {
3677 WMI_RF_SECTOR_STATUS_SUCCESS = 0x00,
3678 WMI_RF_SECTOR_STATUS_BAD_PARAMETERS_ERROR = 0x01,
3679 WMI_RF_SECTOR_STATUS_BUSY_ERROR = 0x02,
3680 WMI_RF_SECTOR_STATUS_NOT_SUPPORTED_ERROR = 0x03,
3681 };
3682
3683
3684 enum wmi_rf_sector_type {
3685 WMI_RF_SECTOR_TYPE_RX = 0x00,
3686 WMI_RF_SECTOR_TYPE_TX = 0x01,
3687 };
3688
3689
3690 struct wmi_rf_sector_info {
3691
3692 __le32 psh_hi;
3693
3694 __le32 psh_lo;
3695
3696
3697
3698 __le32 etype0;
3699
3700
3701
3702 __le32 etype1;
3703
3704
3705
3706 __le32 etype2;
3707
3708
3709
3710 __le32 dtype_swch_off;
3711 } __packed;
3712
3713 #define WMI_INVALID_RF_SECTOR_INDEX (0xFFFF)
3714 #define WMI_MAX_RF_MODULES_NUM (8)
3715
3716
3717 struct wmi_get_rf_sector_params_cmd {
3718
3719 __le16 sector_idx;
3720
3721 u8 sector_type;
3722
3723 u8 rf_modules_vec;
3724 } __packed;
3725
3726
3727 struct wmi_get_rf_sector_params_done_event {
3728
3729
3730
3731 u8 status;
3732
3733 u8 reserved[7];
3734
3735 __le64 tsf;
3736
3737 struct wmi_rf_sector_info sectors_info[WMI_MAX_RF_MODULES_NUM];
3738 } __packed;
3739
3740
3741 struct wmi_set_rf_sector_params_cmd {
3742
3743 __le16 sector_idx;
3744
3745 u8 sector_type;
3746
3747 u8 rf_modules_vec;
3748
3749 struct wmi_rf_sector_info sectors_info[WMI_MAX_RF_MODULES_NUM];
3750 } __packed;
3751
3752
3753 struct wmi_set_rf_sector_params_done_event {
3754
3755
3756
3757 u8 status;
3758 } __packed;
3759
3760
3761
3762
3763 struct wmi_get_selected_rf_sector_index_cmd {
3764
3765 u8 cid;
3766
3767 u8 sector_type;
3768
3769 u8 reserved[2];
3770 } __packed;
3771
3772
3773
3774
3775 struct wmi_get_selected_rf_sector_index_done_event {
3776
3777
3778
3779 __le16 sector_idx;
3780
3781
3782
3783 u8 status;
3784
3785 u8 reserved[5];
3786
3787 __le64 tsf;
3788 } __packed;
3789
3790
3791
3792
3793
3794 struct wmi_set_selected_rf_sector_index_cmd {
3795
3796 u8 cid;
3797
3798 u8 sector_type;
3799
3800 __le16 sector_idx;
3801 } __packed;
3802
3803
3804
3805
3806 struct wmi_set_selected_rf_sector_index_done_event {
3807
3808
3809
3810 u8 status;
3811
3812 u8 reserved[3];
3813 } __packed;
3814
3815
3816
3817
3818 struct wmi_set_rf_sector_on_cmd {
3819
3820 __le16 sector_idx;
3821
3822 u8 sector_type;
3823
3824 u8 rf_modules_vec;
3825 } __packed;
3826
3827
3828
3829
3830 struct wmi_set_rf_sector_on_done_event {
3831
3832
3833
3834 u8 status;
3835
3836 u8 reserved[3];
3837 } __packed;
3838
3839 enum wmi_sector_sweep_type {
3840 WMI_SECTOR_SWEEP_TYPE_TXSS = 0x00,
3841 WMI_SECTOR_SWEEP_TYPE_BCON = 0x01,
3842 WMI_SECTOR_SWEEP_TYPE_TXSS_AND_BCON = 0x02,
3843 WMI_SECTOR_SWEEP_TYPE_NUM = 0x03,
3844 };
3845
3846
3847
3848
3849
3850
3851
3852
3853 struct wmi_prio_tx_sectors_order_cmd {
3854
3855 u8 tx_sectors_priority_array[MAX_NUM_OF_SECTORS];
3856
3857 u8 sector_sweep_type;
3858
3859 u8 cid;
3860
3861 u8 reserved[2];
3862 } __packed;
3863
3864
3865 enum wmi_prio_tx_sectors_cmd_status {
3866 WMI_PRIO_TX_SECT_CMD_STATUS_SUCCESS = 0x00,
3867 WMI_PRIO_TX_SECT_CMD_STATUS_BAD_PARAM = 0x01,
3868
3869 WMI_PRIO_TX_SECT_CMD_STATUS_ERROR = 0x02,
3870 };
3871
3872
3873 struct wmi_prio_tx_sectors_order_event {
3874
3875 u8 status;
3876
3877 u8 reserved[3];
3878 } __packed;
3879
3880 struct wmi_prio_tx_sectors_num_cmd {
3881
3882 u8 beacon_number_of_sectors;
3883
3884 u8 txss_number_of_sectors;
3885
3886 u8 cid;
3887 } __packed;
3888
3889
3890
3891
3892
3893
3894
3895
3896 struct wmi_prio_tx_sectors_number_cmd {
3897 struct wmi_prio_tx_sectors_num_cmd active_sectors_num;
3898
3899 u8 reserved;
3900 } __packed;
3901
3902
3903 struct wmi_prio_tx_sectors_number_event {
3904
3905 u8 status;
3906
3907 u8 reserved[3];
3908 } __packed;
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918 struct wmi_prio_tx_sectors_set_default_cfg_cmd {
3919
3920 u8 sector_sweep_type;
3921
3922 u8 cid;
3923
3924 u8 reserved[2];
3925 } __packed;
3926
3927
3928 struct wmi_prio_tx_sectors_set_default_cfg_event {
3929
3930 u8 status;
3931
3932 u8 reserved[3];
3933 } __packed;
3934
3935
3936 struct wmi_set_silent_rssi_table_done_event {
3937
3938 __le32 status;
3939
3940 __le32 table;
3941 } __packed;
3942
3943
3944 struct wmi_vring_switch_timing_config_event {
3945
3946 u8 status;
3947 u8 reserved[3];
3948 } __packed;
3949
3950
3951 struct wmi_assoc_sta_info {
3952 u8 mac[WMI_MAC_LEN];
3953 u8 omni_index_address;
3954 u8 reserved;
3955 } __packed;
3956
3957 #define WMI_GET_ASSOC_LIST_SIZE (8)
3958
3959
3960
3961
3962 struct wmi_get_assoc_list_res_event {
3963 struct wmi_assoc_sta_info assoc_sta_list[WMI_GET_ASSOC_LIST_SIZE];
3964
3965 u8 count;
3966 u8 reserved[3];
3967 } __packed;
3968
3969
3970 struct wmi_bf_control_event {
3971
3972 u8 status;
3973 u8 reserved[3];
3974 } __packed;
3975
3976
3977 struct wmi_bf_control_ex_event {
3978
3979 u8 status;
3980 u8 reserved[3];
3981 } __packed;
3982
3983
3984 struct wmi_command_not_supported_event {
3985
3986 u8 mid;
3987 u8 reserved0;
3988 __le16 command_id;
3989
3990 __le16 command_subtype;
3991 __le16 reserved1;
3992 } __packed;
3993
3994
3995 struct wmi_tsf_sync_cmd {
3996
3997 u8 interval_ms;
3998
3999 u8 mcs;
4000 u8 reserved[6];
4001 } __packed;
4002
4003
4004 enum wmi_tsf_sync_status {
4005 WMI_TSF_SYNC_SUCCESS = 0x00,
4006 WMI_TSF_SYNC_FAILED = 0x01,
4007 WMI_TSF_SYNC_REJECTED = 0x02,
4008 };
4009
4010
4011 struct wmi_tsf_sync_status_event {
4012
4013 u8 status;
4014 u8 reserved[3];
4015 } __packed;
4016
4017
4018 struct wmi_get_cca_indications_event {
4019
4020 u8 status;
4021
4022 u8 cca_ed_percent;
4023
4024 u8 cca_ed_avg_percent;
4025
4026 u8 nav_percent;
4027
4028 u8 nav_avg_percent;
4029 u8 reserved[3];
4030 } __packed;
4031
4032
4033 struct wmi_set_cca_indications_bi_avg_num_cmd {
4034
4035 u8 bi_number;
4036 u8 reserved[3];
4037 } __packed;
4038
4039
4040 struct wmi_set_cca_indications_bi_avg_num_event {
4041
4042 u8 status;
4043 u8 reserved[3];
4044 } __packed;
4045
4046
4047 struct wmi_internal_fw_set_channel_event {
4048 u8 channel_num;
4049 u8 reserved[3];
4050 } __packed;
4051
4052
4053 struct wmi_link_stats_config_done_event {
4054
4055 u8 status;
4056 u8 reserved[3];
4057 } __packed;
4058
4059
4060 struct wmi_link_stats_event {
4061 __le64 tsf;
4062 __le16 payload_size;
4063 u8 has_next;
4064 u8 reserved[5];
4065
4066 u8 payload[0];
4067 } __packed;
4068
4069
4070 struct wmi_link_stats_record {
4071
4072 u8 record_type_id;
4073 u8 reserved;
4074 __le16 record_size;
4075 u8 record[0];
4076 } __packed;
4077
4078
4079 struct wmi_link_stats_basic {
4080 u8 cid;
4081 s8 rssi;
4082 u8 sqi;
4083 u8 bf_mcs;
4084 u8 per_average;
4085 u8 selected_rfc;
4086 u8 rx_effective_ant_num;
4087 u8 my_rx_sector;
4088 u8 my_tx_sector;
4089 u8 other_rx_sector;
4090 u8 other_tx_sector;
4091 u8 reserved[7];
4092
4093 __le16 snr;
4094 __le32 tx_tpt;
4095 __le32 tx_goodput;
4096 __le32 rx_goodput;
4097 __le32 bf_count;
4098 __le32 rx_bcast_frames;
4099 } __packed;
4100
4101
4102 struct wmi_link_stats_global {
4103
4104 __le32 rx_frames;
4105
4106 __le32 tx_frames;
4107 __le32 rx_ba_frames;
4108 __le32 tx_ba_frames;
4109 __le32 tx_beacons;
4110 __le32 rx_mic_errors;
4111 __le32 rx_crc_errors;
4112 __le32 tx_fail_no_ack;
4113 u8 reserved[8];
4114 } __packed;
4115
4116
4117 struct wmi_set_grant_mcs_event {
4118
4119 u8 status;
4120 u8 reserved[3];
4121 } __packed;
4122
4123
4124 struct wmi_set_ap_slot_size_event {
4125
4126 u8 status;
4127 u8 reserved[3];
4128 } __packed;
4129
4130
4131 struct wmi_set_vring_priority_weight_event {
4132
4133 u8 status;
4134 u8 reserved[3];
4135 } __packed;
4136
4137
4138 struct wmi_set_vring_priority_event {
4139
4140 u8 status;
4141 u8 reserved[3];
4142 } __packed;
4143
4144
4145 struct wmi_radar_pci_ctrl_block {
4146
4147 __le32 fw_tail_index;
4148
4149 __le32 sw_head_index;
4150 __le32 last_wr_pulse_tsf_low;
4151 __le32 last_wr_pulse_count;
4152 __le32 last_wr_in_bytes;
4153 __le32 last_wr_pulse_id;
4154 __le32 last_wr_burst_id;
4155
4156 __le32 sw_head_inc;
4157 __le32 reserved[8];
4158 } __packed;
4159
4160
4161 struct wmi_rbufcap_cfg_cmd {
4162 u8 enable;
4163 u8 reserved;
4164
4165
4166
4167
4168 __le16 rx_desc_threshold;
4169 } __packed;
4170
4171
4172 struct wmi_rbufcap_cfg_event {
4173
4174 u8 status;
4175 u8 reserved[3];
4176 } __packed;
4177
4178
4179
4180
4181 struct wmi_temp_sense_all_done_event {
4182
4183 u8 status;
4184
4185 u8 rf_bitmap;
4186 u8 reserved[2];
4187
4188
4189
4190
4191 __le32 rf_t1000[WMI_MAX_XIF_PORTS_NUM];
4192
4193
4194
4195
4196 __le32 baseband_t1000;
4197 } __packed;
4198
4199 #endif