2 * Copyright (c) 2012-2015 Qualcomm Atheros, Inc.
3 * Copyright (c) 2006-2012 Wilocity .
5 * Permission to use, copy, modify, and/or distribute this software for any
6 * purpose with or without fee is hereby granted, provided that the above
7 * copyright notice and this permission notice appear in all copies.
9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
19 * This file contains the definitions of the WMI protocol specified in the
20 * Wireless Module Interface (WMI) for the Wilocity
21 * MARLON 60 Gigabit wireless solution.
22 * It includes definitions of all the commands and events.
23 * Commands are messages from the host to the WM.
24 * Events are messages from the WM to the host.
27 #ifndef __WILOCITY_WMI_H__
28 #define __WILOCITY_WMI_H__
31 #define WILOCITY_MAX_ASSOC_STA (8)
32 #define WILOCITY_DEFAULT_ASSOC_STA (1)
33 #define WMI_MAC_LEN (6)
34 #define WMI_PROX_RANGE_NUM (3)
35 #define WMI_MAX_LOSS_DMG_BEACONS (32)
37 /* List of Commands */
39 WMI_CONNECT_CMDID
= 0x0001,
40 WMI_DISCONNECT_CMDID
= 0x0003,
41 WMI_DISCONNECT_STA_CMDID
= 0x0004,
42 WMI_START_SCAN_CMDID
= 0x0007,
43 WMI_SET_BSS_FILTER_CMDID
= 0x0009,
44 WMI_SET_PROBED_SSID_CMDID
= 0x000a,
45 WMI_SET_LISTEN_INT_CMDID
= 0x000b,
46 WMI_BCON_CTRL_CMDID
= 0x000f,
47 WMI_ADD_CIPHER_KEY_CMDID
= 0x0016,
48 WMI_DELETE_CIPHER_KEY_CMDID
= 0x0017,
49 WMI_SET_APPIE_CMDID
= 0x003f,
50 WMI_SET_WSC_STATUS_CMDID
= 0x0041,
51 WMI_PXMT_RANGE_CFG_CMDID
= 0x0042,
52 WMI_PXMT_SNR2_RANGE_CFG_CMDID
= 0x0043,
53 /* WMI_FAST_MEM_ACC_MODE_CMDID = 0x0300, */
54 WMI_MEM_READ_CMDID
= 0x0800,
55 WMI_MEM_WR_CMDID
= 0x0801,
56 WMI_ECHO_CMDID
= 0x0803,
57 WMI_DEEP_ECHO_CMDID
= 0x0804,
58 WMI_CONFIG_MAC_CMDID
= 0x0805,
59 WMI_CONFIG_PHY_DEBUG_CMDID
= 0x0806,
60 WMI_ADD_DEBUG_TX_PCKT_CMDID
= 0x0808,
61 WMI_PHY_GET_STATISTICS_CMDID
= 0x0809,
62 WMI_FS_TUNE_CMDID
= 0x080a,
63 WMI_CORR_MEASURE_CMDID
= 0x080b,
64 WMI_READ_RSSI_CMDID
= 0x080c,
65 WMI_TEMP_SENSE_CMDID
= 0x080e,
66 WMI_DC_CALIB_CMDID
= 0x080f,
67 WMI_SEND_TONE_CMDID
= 0x0810,
68 WMI_IQ_TX_CALIB_CMDID
= 0x0811,
69 WMI_IQ_RX_CALIB_CMDID
= 0x0812,
70 WMI_SET_UCODE_IDLE_CMDID
= 0x0813,
71 WMI_SET_WORK_MODE_CMDID
= 0x0815,
72 WMI_LO_LEAKAGE_CALIB_CMDID
= 0x0816,
73 WMI_MARLON_R_READ_CMDID
= 0x0818,
74 WMI_MARLON_R_WRITE_CMDID
= 0x0819,
75 WMI_MARLON_R_TXRX_SEL_CMDID
= 0x081a,
76 MAC_IO_STATIC_PARAMS_CMDID
= 0x081b,
77 MAC_IO_DYNAMIC_PARAMS_CMDID
= 0x081c,
78 WMI_SILENT_RSSI_CALIB_CMDID
= 0x081d,
79 WMI_RF_RX_TEST_CMDID
= 0x081e,
80 WMI_CFG_RX_CHAIN_CMDID
= 0x0820,
81 WMI_VRING_CFG_CMDID
= 0x0821,
82 WMI_BCAST_VRING_CFG_CMDID
= 0x0822,
83 WMI_VRING_BA_EN_CMDID
= 0x0823,
84 WMI_VRING_BA_DIS_CMDID
= 0x0824,
85 WMI_RCP_ADDBA_RESP_CMDID
= 0x0825,
86 WMI_RCP_DELBA_CMDID
= 0x0826,
87 WMI_SET_SSID_CMDID
= 0x0827,
88 WMI_GET_SSID_CMDID
= 0x0828,
89 WMI_SET_PCP_CHANNEL_CMDID
= 0x0829,
90 WMI_GET_PCP_CHANNEL_CMDID
= 0x082a,
91 WMI_SW_TX_REQ_CMDID
= 0x082b,
92 WMI_READ_MAC_RXQ_CMDID
= 0x0830,
93 WMI_READ_MAC_TXQ_CMDID
= 0x0831,
94 WMI_WRITE_MAC_RXQ_CMDID
= 0x0832,
95 WMI_WRITE_MAC_TXQ_CMDID
= 0x0833,
96 WMI_WRITE_MAC_XQ_FIELD_CMDID
= 0x0834,
97 WMI_MLME_PUSH_CMDID
= 0x0835,
98 WMI_BEAMFORMING_MGMT_CMDID
= 0x0836,
99 WMI_BF_TXSS_MGMT_CMDID
= 0x0837,
100 WMI_BF_SM_MGMT_CMDID
= 0x0838,
101 WMI_BF_RXSS_MGMT_CMDID
= 0x0839,
102 WMI_BF_TRIG_CMDID
= 0x083A,
103 WMI_SET_SECTORS_CMDID
= 0x0849,
104 WMI_MAINTAIN_PAUSE_CMDID
= 0x0850,
105 WMI_MAINTAIN_RESUME_CMDID
= 0x0851,
106 WMI_RS_MGMT_CMDID
= 0x0852,
107 WMI_RF_MGMT_CMDID
= 0x0853,
108 WMI_THERMAL_THROTTLING_CTRL_CMDID
= 0x0854,
109 WMI_THERMAL_THROTTLING_GET_STATUS_CMDID
= 0x0855,
110 /* Performance monitoring commands */
111 WMI_BF_CTRL_CMDID
= 0x0862,
112 WMI_NOTIFY_REQ_CMDID
= 0x0863,
113 WMI_GET_STATUS_CMDID
= 0x0864,
114 WMI_UNIT_TEST_CMDID
= 0x0900,
115 WMI_HICCUP_CMDID
= 0x0901,
116 WMI_FLASH_READ_CMDID
= 0x0902,
117 WMI_FLASH_WRITE_CMDID
= 0x0903,
118 WMI_SECURITY_UNIT_TEST_CMDID
= 0x0904,
120 WMI_P2P_CFG_CMDID
= 0x0910,
121 WMI_PORT_ALLOCATE_CMDID
= 0x0911,
122 WMI_PORT_DELETE_CMDID
= 0x0912,
123 WMI_POWER_MGMT_CFG_CMDID
= 0x0913,
124 WMI_START_LISTEN_CMDID
= 0x0914,
125 WMI_START_SEARCH_CMDID
= 0x0915,
126 WMI_DISCOVERY_START_CMDID
= 0x0916,
127 WMI_DISCOVERY_STOP_CMDID
= 0x0917,
128 WMI_PCP_START_CMDID
= 0x0918,
129 WMI_PCP_STOP_CMDID
= 0x0919,
130 WMI_GET_PCP_FACTOR_CMDID
= 0x091b,
132 WMI_SET_MAC_ADDRESS_CMDID
= 0xf003,
133 WMI_ABORT_SCAN_CMDID
= 0xf007,
134 WMI_SET_PMK_CMDID
= 0xf028,
136 WMI_SET_PROMISCUOUS_MODE_CMDID
= 0xf041,
137 WMI_GET_PMK_CMDID
= 0xf048,
138 WMI_SET_PASSPHRASE_CMDID
= 0xf049,
139 WMI_SEND_ASSOC_RES_CMDID
= 0xf04a,
140 WMI_SET_ASSOC_REQ_RELAY_CMDID
= 0xf04b,
141 WMI_EAPOL_TX_CMDID
= 0xf04c,
142 WMI_MAC_ADDR_REQ_CMDID
= 0xf04d,
143 WMI_FW_VER_CMDID
= 0xf04e,
144 WMI_PMC_CMDID
= 0xf04f,
148 * Commands data structures
154 enum wmi_network_type
{
155 WMI_NETTYPE_INFRA
= 0x01,
156 WMI_NETTYPE_ADHOC
= 0x02,
157 WMI_NETTYPE_ADHOC_CREATOR
= 0x04,
158 WMI_NETTYPE_AP
= 0x10,
159 WMI_NETTYPE_P2P
= 0x20,
160 WMI_NETTYPE_WBE
= 0x40, /* PCIE over 60g */
163 enum wmi_dot11_auth_mode
{
164 WMI_AUTH11_OPEN
= 0x01,
165 WMI_AUTH11_SHARED
= 0x02,
166 WMI_AUTH11_LEAP
= 0x04,
167 WMI_AUTH11_WSC
= 0x08,
171 WMI_AUTH_NONE
= 0x01,
173 WMI_AUTH_WPA2
= 0x04,
174 WMI_AUTH_WPA_PSK
= 0x08,
175 WMI_AUTH_WPA2_PSK
= 0x10,
176 WMI_AUTH_WPA_CCKM
= 0x20,
177 WMI_AUTH_WPA2_CCKM
= 0x40,
180 enum wmi_crypto_type
{
181 WMI_CRYPT_NONE
= 0x01,
182 WMI_CRYPT_WEP
= 0x02,
183 WMI_CRYPT_TKIP
= 0x04,
184 WMI_CRYPT_AES
= 0x08,
185 WMI_CRYPT_AES_GCMP
= 0x20,
188 enum wmi_connect_ctrl_flag_bits
{
189 WMI_CONNECT_ASSOC_POLICY_USER
= 0x0001,
190 WMI_CONNECT_SEND_REASSOC
= 0x0002,
191 WMI_CONNECT_IGNORE_WPA_GROUP_CIPHER
= 0x0004,
192 WMI_CONNECT_PROFILE_MATCH_DONE
= 0x0008,
193 WMI_CONNECT_IGNORE_AAC_BEACON
= 0x0010,
194 WMI_CONNECT_CSA_FOLLOW_BSS
= 0x0020,
195 WMI_CONNECT_DO_WPA_OFFLOAD
= 0x0040,
196 WMI_CONNECT_DO_NOT_DEAUTH
= 0x0080,
199 #define WMI_MAX_SSID_LEN (32)
201 struct wmi_connect_cmd
{
205 u8 pairwise_crypto_type
;
206 u8 pairwise_crypto_len
;
207 u8 group_crypto_type
;
210 u8 ssid
[WMI_MAX_SSID_LEN
];
213 u8 bssid
[WMI_MAC_LEN
];
215 u8 dst_mac
[WMI_MAC_LEN
];
220 * WMI_DISCONNECT_STA_CMDID
222 struct wmi_disconnect_sta_cmd
{
223 u8 dst_mac
[WMI_MAC_LEN
];
224 __le16 disconnect_reason
;
231 #define WMI_MIN_KEY_INDEX (0)
232 #define WMI_MAX_KEY_INDEX (3)
233 #define WMI_MAX_KEY_LEN (32)
234 #define WMI_PASSPHRASE_LEN (64)
235 #define WMI_PMK_LEN (32)
237 struct wmi_set_pmk_cmd
{
242 * WMI_SET_PASSPHRASE_CMDID
244 struct wmi_set_passphrase_cmd
{
245 u8 ssid
[WMI_MAX_SSID_LEN
];
246 u8 passphrase
[WMI_PASSPHRASE_LEN
];
252 * WMI_ADD_CIPHER_KEY_CMDID
255 WMI_KEY_USE_PAIRWISE
= 0,
256 WMI_KEY_USE_RX_GROUP
= 1,
257 WMI_KEY_USE_TX_GROUP
= 2,
260 struct wmi_add_cipher_key_cmd
{
263 u8 key_usage
; /* enum wmi_key_usage */
265 u8 key_rsc
[8]; /* key replay sequence counter */
266 u8 key
[WMI_MAX_KEY_LEN
];
267 u8 key_op_ctrl
; /* Additional Key Control information */
272 * WMI_DELETE_CIPHER_KEY_CMDID
274 struct wmi_delete_cipher_key_cmd
{
280 * WMI_START_SCAN_CMDID
282 * Start L1 scan operation
285 * - WMI_RX_MGMT_PACKET_EVENTID - for every probe resp.
286 * - WMI_SCAN_COMPLETE_EVENTID
296 struct wmi_start_scan_cmd
{
297 u8 direct_scan_mac_addr
[6];
299 __le32 home_dwell_time
; /* Max duration in the home channel(ms) */
300 __le32 force_scan_interval
; /* Time interval between scans (ms)*/
301 u8 scan_type
; /* wmi_scan_type */
302 u8 num_channels
; /* how many channels follow */
306 } channel_list
[0]; /* channels ID's */
313 * WMI_SET_PROBED_SSID_CMDID
315 #define MAX_PROBED_SSID_INDEX (3)
318 WMI_SSID_FLAG_DISABLE
= 0, /* disables entry */
319 WMI_SSID_FLAG_SPECIFIC
= 1, /* probes specified ssid */
320 WMI_SSID_FLAG_ANY
= 2, /* probes for any ssid */
323 struct wmi_probed_ssid_cmd
{
324 u8 entry_index
; /* 0 to MAX_PROBED_SSID_INDEX */
325 u8 flag
; /* enum wmi_ssid_flag */
327 u8 ssid
[WMI_MAX_SSID_LEN
];
331 * WMI_SET_APPIE_CMDID
332 * Add Application specified IE to a management frame
334 #define WMI_MAX_IE_LEN (1024)
339 enum wmi_mgmt_frame_type
{
340 WMI_FRAME_BEACON
= 0,
341 WMI_FRAME_PROBE_REQ
= 1,
342 WMI_FRAME_PROBE_RESP
= 2,
343 WMI_FRAME_ASSOC_REQ
= 3,
344 WMI_FRAME_ASSOC_RESP
= 4,
348 struct wmi_set_appie_cmd
{
349 u8 mgmt_frm_type
; /* enum wmi_mgmt_frame_type */
351 __le16 ie_len
; /* Length of the IE to be added to MGMT frame */
356 * WMI_PXMT_RANGE_CFG_CMDID
358 struct wmi_pxmt_range_cfg_cmd
{
359 u8 dst_mac
[WMI_MAC_LEN
];
364 * WMI_PXMT_SNR2_RANGE_CFG_CMDID
366 struct wmi_pxmt_snr2_range_cfg_cmd
{
367 s8 snr2range_arr
[WMI_PROX_RANGE_NUM
-1];
373 enum wmi_rf_mgmt_type
{
374 WMI_RF_MGMT_W_DISABLE
= 0,
375 WMI_RF_MGMT_W_ENABLE
= 1,
376 WMI_RF_MGMT_GET_STATUS
= 2,
379 struct wmi_rf_mgmt_cmd
{
384 * WMI_THERMAL_THROTTLING_CTRL_CMDID
386 #define THERMAL_THROTTLING_USE_DEFAULT_MAX_TXOP_LENGTH (0xFFFFFFFF)
388 struct wmi_thermal_throttling_ctrl_cmd
{
390 __le32 time_off_usec
;
391 __le32 max_txop_length_usec
;
395 * WMI_RF_RX_TEST_CMDID
397 struct wmi_rf_rx_test_cmd
{
402 * WMI_CORR_MEASURE_CMDID
404 struct wmi_corr_measure_cmd
{
406 __le32 length_samples
;
413 struct wmi_set_ssid_cmd
{
415 u8 ssid
[WMI_MAX_SSID_LEN
];
419 * WMI_SET_PCP_CHANNEL_CMDID
421 struct wmi_set_pcp_channel_cmd
{
427 * WMI_BCON_CTRL_CMDID
429 struct wmi_bcon_ctrl_cmd
{
430 __le16 bcon_interval
;
434 u8 pcp_max_assoc_sta
;
435 u8 disable_sec_offload
;
439 /******* P2P ***********/
442 * WMI_PORT_ALLOCATE_CMDID
448 WMI_PORT_P2P_DEV
= 3,
449 WMI_PORT_P2P_CLIENT
= 4,
453 struct wmi_port_allocate_cmd
{
460 * WMI_PORT_DELETE_CMDID
462 struct wmi_delete_port_cmd
{
470 enum wmi_discovery_mode
{
471 WMI_DISCOVERY_MODE_NON_OFFLOAD
= 0,
472 WMI_DISCOVERY_MODE_OFFLOAD
= 1,
473 WMI_DISCOVERY_MODE_PEER2PEER
= 2,
476 struct wmi_p2p_cfg_cmd
{
477 u8 discovery_mode
; /* wmi_discovery_mode */
479 __le16 bcon_interval
; /* base to listen/search duration calculation */
483 * WMI_POWER_MGMT_CFG_CMDID
485 enum wmi_power_source_type
{
486 WMI_POWER_SOURCE_BATTERY
= 0,
487 WMI_POWER_SOURCE_OTHER
= 1,
490 struct wmi_power_mgmt_cfg_cmd
{
491 u8 power_source
; /* wmi_power_source_type */
496 * WMI_PCP_START_CMDID
499 enum wmi_hidden_ssid
{
500 WMI_HIDDEN_SSID_DISABLED
= 0,
501 WMI_HIDDEN_SSID_SEND_EMPTY
= 1,
502 WMI_HIDDEN_SSID_CLEAR
= 2,
505 struct wmi_pcp_start_cmd
{
506 __le16 bcon_interval
;
507 u8 pcp_max_assoc_sta
;
512 u8 disable_sec_offload
;
517 * WMI_SW_TX_REQ_CMDID
519 struct wmi_sw_tx_req_cmd
{
520 u8 dst_mac
[WMI_MAC_LEN
];
526 * WMI_VRING_CFG_CMDID
529 struct wmi_sw_ring_cfg
{
530 __le64 ring_mem_base
;
532 __le16 max_mpdu_size
;
535 struct wmi_vring_cfg_schd
{
540 enum wmi_vring_cfg_encap_trans_type
{
541 WMI_VRING_ENC_TYPE_802_3
= 0,
542 WMI_VRING_ENC_TYPE_NATIVE_WIFI
= 1,
545 enum wmi_vring_cfg_ds_cfg
{
546 WMI_VRING_DS_PBSS
= 0,
547 WMI_VRING_DS_STATION
= 1,
549 WMI_VRING_DS_ADDR4
= 3,
552 enum wmi_vring_cfg_nwifi_ds_trans_type
{
553 WMI_NWIFI_TX_TRANS_MODE_NO
= 0,
554 WMI_NWIFI_TX_TRANS_MODE_AP2PBSS
= 1,
555 WMI_NWIFI_TX_TRANS_MODE_STA2PBSS
= 2,
558 enum wmi_vring_cfg_schd_params_priority
{
559 WMI_SCH_PRIO_REGULAR
= 0,
560 WMI_SCH_PRIO_HIGH
= 1,
563 #define CIDXTID_CID_POS (0)
564 #define CIDXTID_CID_LEN (4)
565 #define CIDXTID_CID_MSK (0xF)
566 #define CIDXTID_TID_POS (4)
567 #define CIDXTID_TID_LEN (4)
568 #define CIDXTID_TID_MSK (0xF0)
570 struct wmi_vring_cfg
{
571 struct wmi_sw_ring_cfg tx_sw_ring
;
572 u8 ringid
; /* 0-23 vrings */
577 u8 ds_cfg
; /* 802.3 DS cfg */
578 u8 nwifi_ds_trans_type
;
580 #define VRING_CFG_MAC_CTRL_LIFETIME_EN_POS (0)
581 #define VRING_CFG_MAC_CTRL_LIFETIME_EN_LEN (1)
582 #define VRING_CFG_MAC_CTRL_LIFETIME_EN_MSK (0x1)
583 #define VRING_CFG_MAC_CTRL_AGGR_EN_POS (1)
584 #define VRING_CFG_MAC_CTRL_AGGR_EN_LEN (1)
585 #define VRING_CFG_MAC_CTRL_AGGR_EN_MSK (0x2)
588 #define VRING_CFG_TO_RESOLUTION_VALUE_POS (0)
589 #define VRING_CFG_TO_RESOLUTION_VALUE_LEN (6)
590 #define VRING_CFG_TO_RESOLUTION_VALUE_MSK (0x3F)
593 struct wmi_vring_cfg_schd schd_params
;
596 enum wmi_vring_cfg_cmd_action
{
597 WMI_VRING_CMD_ADD
= 0,
598 WMI_VRING_CMD_MODIFY
= 1,
599 WMI_VRING_CMD_DELETE
= 2,
602 struct wmi_vring_cfg_cmd
{
604 struct wmi_vring_cfg vring_cfg
;
608 * WMI_BCAST_VRING_CFG_CMDID
610 struct wmi_bcast_vring_cfg
{
611 struct wmi_sw_ring_cfg tx_sw_ring
;
612 u8 ringid
; /* 0-23 vrings */
614 u8 ds_cfg
; /* 802.3 DS cfg */
615 u8 nwifi_ds_trans_type
;
618 struct wmi_bcast_vring_cfg_cmd
{
620 struct wmi_bcast_vring_cfg vring_cfg
;
624 * WMI_VRING_BA_EN_CMDID
626 struct wmi_vring_ba_en_cmd
{
634 * WMI_VRING_BA_DIS_CMDID
636 struct wmi_vring_ba_dis_cmd
{
643 * WMI_NOTIFY_REQ_CMDID
645 struct wmi_notify_req_cmd
{
650 __le32 interval_usec
;
658 * WMI_CFG_RX_CHAIN_CMDID
660 enum wmi_sniffer_cfg_mode
{
665 enum wmi_sniffer_cfg_phy_info_mode
{
666 WMI_SNIFFER_PHY_INFO_DISABLED
= 0,
667 WMI_SNIFFER_PHY_INFO_ENABLED
= 1,
670 enum wmi_sniffer_cfg_phy_support
{
673 WMI_SNIFFER_BOTH_PHYS
= 2,
676 struct wmi_sniffer_cfg
{
677 __le32 mode
; /* enum wmi_sniffer_cfg_mode */
678 __le32 phy_info_mode
; /* enum wmi_sniffer_cfg_phy_info_mode */
679 __le32 phy_support
; /* enum wmi_sniffer_cfg_phy_support */
684 enum wmi_cfg_rx_chain_cmd_action
{
685 WMI_RX_CHAIN_ADD
= 0,
686 WMI_RX_CHAIN_DEL
= 1,
689 enum wmi_cfg_rx_chain_cmd_decap_trans_type
{
690 WMI_DECAP_TYPE_802_3
= 0,
691 WMI_DECAP_TYPE_NATIVE_WIFI
= 1,
692 WMI_DECAP_TYPE_NONE
= 2,
695 enum wmi_cfg_rx_chain_cmd_nwifi_ds_trans_type
{
696 WMI_NWIFI_RX_TRANS_MODE_NO
= 0,
697 WMI_NWIFI_RX_TRANS_MODE_PBSS2AP
= 1,
698 WMI_NWIFI_RX_TRANS_MODE_PBSS2STA
= 2,
701 enum wmi_cfg_rx_chain_cmd_reorder_type
{
702 WMI_RX_HW_REORDER
= 0,
703 WMI_RX_SW_REORDER
= 1,
706 struct wmi_cfg_rx_chain_cmd
{
708 struct wmi_sw_ring_cfg rx_sw_ring
;
712 #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_POS (0)
713 #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_LEN (1)
714 #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_MSK (0x1)
715 #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_POS (1)
716 #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_LEN (1)
717 #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_MSK (0x2)
718 u8 l2_802_3_offload_ctrl
;
720 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_POS (0)
721 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_LEN (1)
722 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_MSK (0x1)
723 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_POS (1)
724 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_LEN (1)
725 #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_MSK (0x2)
726 u8 l2_nwifi_offload_ctrl
;
729 u8 nwifi_ds_trans_type
;
731 #define L3_L4_CTRL_IPV4_CHECKSUM_EN_POS (0)
732 #define L3_L4_CTRL_IPV4_CHECKSUM_EN_LEN (1)
733 #define L3_L4_CTRL_IPV4_CHECKSUM_EN_MSK (0x1)
734 #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_POS (1)
735 #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_LEN (1)
736 #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_MSK (0x2)
739 #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_POS (0)
740 #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_LEN (1)
741 #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_MSK (0x1)
742 #define RING_CTRL_OVERRIDE_WB_THRSH_POS (1)
743 #define RING_CTRL_OVERRIDE_WB_THRSH_LEN (1)
744 #define RING_CTRL_OVERRIDE_WB_THRSH_MSK (0x2)
745 #define RING_CTRL_OVERRIDE_ITR_THRSH_POS (2)
746 #define RING_CTRL_OVERRIDE_ITR_THRSH_LEN (1)
747 #define RING_CTRL_OVERRIDE_ITR_THRSH_MSK (0x4)
748 #define RING_CTRL_OVERRIDE_HOST_THRSH_POS (3)
749 #define RING_CTRL_OVERRIDE_HOST_THRSH_LEN (1)
750 #define RING_CTRL_OVERRIDE_HOST_THRSH_MSK (0x8)
753 __le16 prefetch_thrsh
;
759 struct wmi_sniffer_cfg sniffer_cfg
;
763 * WMI_RCP_ADDBA_RESP_CMDID
765 struct wmi_rcp_addba_resp_cmd
{
769 __le16 ba_param_set
; /* ieee80211_ba_parameterset field to send */
774 * WMI_RCP_DELBA_CMDID
776 struct wmi_rcp_delba_cmd
{
783 * WMI_RCP_ADDBA_REQ_CMDID
785 struct wmi_rcp_addba_req_cmd
{
788 /* ieee80211_ba_parameterset field as it received */
791 /* ieee80211_ba_seqstrl field as it received */
796 * WMI_SET_MAC_ADDRESS_CMDID
798 struct wmi_set_mac_address_cmd
{
806 struct wmi_eapol_tx_cmd
{
807 u8 dst_mac
[WMI_MAC_LEN
];
817 * WMI_DEEP_ECHO_CMDID
819 * Check FW and ucode are alive
821 * Returned event: WMI_ECHO_RSP_EVENTID
822 * same event for both commands
824 struct wmi_echo_cmd
{
829 * WMI_TEMP_SENSE_CMDID
831 * Measure MAC and radio temperatures
834 /* Possible modes for temperature measurement */
835 enum wmi_temperature_measure_mode
{
836 TEMPERATURE_USE_OLD_VALUE
= 0x1,
837 TEMPERATURE_MEASURE_NOW
= 0x2,
840 struct wmi_temp_sense_cmd
{
841 __le32 measure_baseband_en
;
842 __le32 measure_rf_en
;
850 WMI_PMC_ALLOCATE
= 0,
855 u8 op
; /* enum wmi_pmc_cmd_op_type */
866 * List of Events (target to host)
869 WMI_READY_EVENTID
= 0x1001,
870 WMI_CONNECT_EVENTID
= 0x1002,
871 WMI_DISCONNECT_EVENTID
= 0x1003,
872 WMI_SCAN_COMPLETE_EVENTID
= 0x100a,
873 WMI_REPORT_STATISTICS_EVENTID
= 0x100b,
874 WMI_RD_MEM_RSP_EVENTID
= 0x1800,
875 WMI_FW_READY_EVENTID
= 0x1801,
876 WMI_EXIT_FAST_MEM_ACC_MODE_EVENTID
= 0x0200,
877 WMI_ECHO_RSP_EVENTID
= 0x1803,
878 WMI_FS_TUNE_DONE_EVENTID
= 0x180a,
879 WMI_CORR_MEASURE_EVENTID
= 0x180b,
880 WMI_READ_RSSI_EVENTID
= 0x180c,
881 WMI_TEMP_SENSE_DONE_EVENTID
= 0x180e,
882 WMI_DC_CALIB_DONE_EVENTID
= 0x180f,
883 WMI_IQ_TX_CALIB_DONE_EVENTID
= 0x1811,
884 WMI_IQ_RX_CALIB_DONE_EVENTID
= 0x1812,
885 WMI_SET_WORK_MODE_DONE_EVENTID
= 0x1815,
886 WMI_LO_LEAKAGE_CALIB_DONE_EVENTID
= 0x1816,
887 WMI_MARLON_R_READ_DONE_EVENTID
= 0x1818,
888 WMI_MARLON_R_WRITE_DONE_EVENTID
= 0x1819,
889 WMI_MARLON_R_TXRX_SEL_DONE_EVENTID
= 0x181a,
890 WMI_SILENT_RSSI_CALIB_DONE_EVENTID
= 0x181d,
891 WMI_RF_RX_TEST_DONE_EVENTID
= 0x181e,
892 WMI_CFG_RX_CHAIN_DONE_EVENTID
= 0x1820,
893 WMI_VRING_CFG_DONE_EVENTID
= 0x1821,
894 WMI_BA_STATUS_EVENTID
= 0x1823,
895 WMI_RCP_ADDBA_REQ_EVENTID
= 0x1824,
896 WMI_RCP_ADDBA_RESP_SENT_EVENTID
= 0x1825,
897 WMI_DELBA_EVENTID
= 0x1826,
898 WMI_GET_SSID_EVENTID
= 0x1828,
899 WMI_GET_PCP_CHANNEL_EVENTID
= 0x182a,
900 WMI_SW_TX_COMPLETE_EVENTID
= 0x182b,
902 WMI_READ_MAC_RXQ_EVENTID
= 0x1830,
903 WMI_READ_MAC_TXQ_EVENTID
= 0x1831,
904 WMI_WRITE_MAC_RXQ_EVENTID
= 0x1832,
905 WMI_WRITE_MAC_TXQ_EVENTID
= 0x1833,
906 WMI_WRITE_MAC_XQ_FIELD_EVENTID
= 0x1834,
908 WMI_BEAMFORMING_MGMT_DONE_EVENTID
= 0x1836,
909 WMI_BF_TXSS_MGMT_DONE_EVENTID
= 0x1837,
910 WMI_BF_RXSS_MGMT_DONE_EVENTID
= 0x1839,
911 WMI_RS_MGMT_DONE_EVENTID
= 0x1852,
912 WMI_RF_MGMT_STATUS_EVENTID
= 0x1853,
913 WMI_THERMAL_THROTTLING_STATUS_EVENTID
= 0x1855,
914 WMI_BF_SM_MGMT_DONE_EVENTID
= 0x1838,
915 WMI_RX_MGMT_PACKET_EVENTID
= 0x1840,
916 WMI_TX_MGMT_PACKET_EVENTID
= 0x1841,
918 /* Performance monitoring events */
919 WMI_DATA_PORT_OPEN_EVENTID
= 0x1860,
920 WMI_WBE_LINK_DOWN_EVENTID
= 0x1861,
922 WMI_BF_CTRL_DONE_EVENTID
= 0x1862,
923 WMI_NOTIFY_REQ_DONE_EVENTID
= 0x1863,
924 WMI_GET_STATUS_DONE_EVENTID
= 0x1864,
925 WMI_VRING_EN_EVENTID
= 0x1865,
927 WMI_UNIT_TEST_EVENTID
= 0x1900,
928 WMI_FLASH_READ_DONE_EVENTID
= 0x1902,
929 WMI_FLASH_WRITE_DONE_EVENTID
= 0x1903,
931 WMI_P2P_CFG_DONE_EVENTID
= 0x1910,
932 WMI_PORT_ALLOCATED_EVENTID
= 0x1911,
933 WMI_PORT_DELETED_EVENTID
= 0x1912,
934 WMI_LISTEN_STARTED_EVENTID
= 0x1914,
935 WMI_SEARCH_STARTED_EVENTID
= 0x1915,
936 WMI_DISCOVERY_STARTED_EVENTID
= 0x1916,
937 WMI_DISCOVERY_STOPPED_EVENTID
= 0x1917,
938 WMI_PCP_STARTED_EVENTID
= 0x1918,
939 WMI_PCP_STOPPED_EVENTID
= 0x1919,
940 WMI_PCP_FACTOR_EVENTID
= 0x191a,
941 WMI_SET_CHANNEL_EVENTID
= 0x9000,
942 WMI_ASSOC_REQ_EVENTID
= 0x9001,
943 WMI_EAPOL_RX_EVENTID
= 0x9002,
944 WMI_MAC_ADDR_RESP_EVENTID
= 0x9003,
945 WMI_FW_VER_EVENTID
= 0x9004,
949 * Events data structures
953 WMI_FW_STATUS_SUCCESS
,
954 WMI_FW_STATUS_FAILURE
,
958 * WMI_RF_MGMT_STATUS_EVENTID
962 WMI_RF_DISABLED_HW
= 1,
963 WMI_RF_DISABLED_SW
= 2,
964 WMI_RF_DISABLED_HW_SW
= 3,
967 struct wmi_rf_mgmt_status_event
{
972 * WMI_THERMAL_THROTTLING_STATUS_EVENTID
974 struct wmi_thermal_throttling_status_event
{
976 __le32 time_off_usec
;
977 __le32 max_txop_length_usec
;
981 * WMI_GET_STATUS_DONE_EVENTID
983 struct wmi_get_status_done_event
{
984 __le32 is_associated
;
987 u8 bssid
[WMI_MAC_LEN
];
993 u8 ssid
[WMI_MAX_SSID_LEN
];
1001 struct wmi_fw_ver_event
{
1009 * WMI_MAC_ADDR_RESP_EVENTID
1011 struct wmi_mac_addr_resp_event
{
1012 u8 mac
[WMI_MAC_LEN
];
1015 __le32 offload_mode
;
1019 * WMI_EAPOL_RX_EVENTID
1021 struct wmi_eapol_rx_event
{
1022 u8 src_mac
[WMI_MAC_LEN
];
1030 enum wmi_phy_capability
{
1031 WMI_11A_CAPABILITY
= 1,
1032 WMI_11G_CAPABILITY
= 2,
1033 WMI_11AG_CAPABILITY
= 3,
1034 WMI_11NA_CAPABILITY
= 4,
1035 WMI_11NG_CAPABILITY
= 5,
1036 WMI_11NAG_CAPABILITY
= 6,
1037 WMI_11AD_CAPABILITY
= 7,
1038 WMI_11N_CAPABILITY_OFFSET
= WMI_11NA_CAPABILITY
- WMI_11A_CAPABILITY
,
1041 struct wmi_ready_event
{
1044 u8 mac
[WMI_MAC_LEN
];
1045 u8 phy_capability
; /* enum wmi_phy_capability */
1046 u8 numof_additional_mids
;
1050 * WMI_NOTIFY_REQ_DONE_EVENTID
1052 struct wmi_notify_req_done_event
{
1053 __le32 status
; /* beamforming status, 0: fail; 1: OK; 2: retrying */
1060 __le16 my_rx_sector
;
1061 __le16 my_tx_sector
;
1062 __le16 other_rx_sector
;
1063 __le16 other_tx_sector
;
1070 * WMI_CONNECT_EVENTID
1072 struct wmi_connect_event
{
1075 u8 bssid
[WMI_MAC_LEN
];
1076 __le16 listen_interval
;
1077 __le16 beacon_interval
;
1089 * WMI_DISCONNECT_EVENTID
1091 enum wmi_disconnect_reason
{
1092 WMI_DIS_REASON_NO_NETWORK_AVAIL
= 1,
1093 WMI_DIS_REASON_LOST_LINK
= 2, /* bmiss */
1094 WMI_DIS_REASON_DISCONNECT_CMD
= 3,
1095 WMI_DIS_REASON_BSS_DISCONNECTED
= 4,
1096 WMI_DIS_REASON_AUTH_FAILED
= 5,
1097 WMI_DIS_REASON_ASSOC_FAILED
= 6,
1098 WMI_DIS_REASON_NO_RESOURCES_AVAIL
= 7,
1099 WMI_DIS_REASON_CSERV_DISCONNECT
= 8,
1100 WMI_DIS_REASON_INVALID_PROFILE
= 10,
1101 WMI_DIS_REASON_DOT11H_CHANNEL_SWITCH
= 11,
1102 WMI_DIS_REASON_PROFILE_MISMATCH
= 12,
1103 WMI_DIS_REASON_CONNECTION_EVICTED
= 13,
1104 WMI_DIS_REASON_IBSS_MERGE
= 14,
1107 struct wmi_disconnect_event
{
1108 __le16 protocol_reason_status
; /* reason code, see 802.11 spec. */
1109 u8 bssid
[WMI_MAC_LEN
]; /* set if known */
1110 u8 disconnect_reason
; /* see wmi_disconnect_reason */
1111 u8 assoc_resp_len
; /* not used */
1112 u8 assoc_info
[0]; /* not used */
1116 * WMI_SCAN_COMPLETE_EVENTID
1119 WMI_SCAN_SUCCESS
= 0,
1120 WMI_SCAN_FAILED
= 1,
1121 WMI_SCAN_ABORTED
= 2,
1122 WMI_SCAN_REJECTED
= 3,
1125 struct wmi_scan_complete_event
{
1126 __le32 status
; /* scan_status */
1130 * WMI_BA_STATUS_EVENTID
1132 enum wmi_vring_ba_status
{
1134 WMI_BA_NON_AGREED
= 1,
1135 /* BA_EN in middle of teardown flow */
1137 /* BA_DIS or BA_EN in middle of BA SETUP flow */
1138 WMI_BA_SETUP_WIP
= 3,
1139 /* BA_EN when the BA session is already active */
1140 WMI_BA_SESSION_ACTIVE
= 4,
1141 /* BA_DIS when the BA session is not active */
1142 WMI_BA_SESSION_NOT_ACTIVE
= 5,
1145 struct wmi_vring_ba_status_event
{
1146 __le16 status
; /* enum wmi_vring_ba_status */
1157 struct wmi_delba_event
{
1164 * WMI_VRING_CFG_DONE_EVENTID
1166 struct wmi_vring_cfg_done_event
{
1170 __le32 tx_vring_tail_ptr
;
1174 * WMI_RCP_ADDBA_RESP_SENT_EVENTID
1176 struct wmi_rcp_addba_resp_sent_event
{
1183 * WMI_RCP_ADDBA_REQ_EVENTID
1185 struct wmi_rcp_addba_req_event
{
1188 __le16 ba_param_set
; /* ieee80211_ba_parameterset as it received */
1190 __le16 ba_seq_ctrl
; /* ieee80211_ba_seqstrl field as it received */
1194 * WMI_CFG_RX_CHAIN_DONE_EVENTID
1196 enum wmi_cfg_rx_chain_done_event_status
{
1197 WMI_CFG_RX_CHAIN_SUCCESS
= 1,
1200 struct wmi_cfg_rx_chain_done_event
{
1201 __le32 rx_ring_tail_ptr
; /* Rx V-Ring Tail pointer */
1206 * WMI_WBE_LINK_DOWN_EVENTID
1208 enum wmi_wbe_link_down_event_reason
{
1209 WMI_WBE_REASON_USER_REQUEST
= 0,
1210 WMI_WBE_REASON_RX_DISASSOC
= 1,
1211 WMI_WBE_REASON_BAD_PHY_LINK
= 2,
1214 struct wmi_wbe_link_down_event
{
1221 * WMI_DATA_PORT_OPEN_EVENTID
1223 struct wmi_data_port_open_event
{
1229 * WMI_VRING_EN_EVENTID
1231 struct wmi_vring_en_event
{
1237 * WMI_GET_PCP_CHANNEL_EVENTID
1239 struct wmi_get_pcp_channel_event
{
1245 * WMI_P2P_CFG_DONE_EVENTID
1247 struct wmi_p2p_cfg_done_event
{
1248 u8 status
; /* wmi_fw_status */
1253 * WMI_PORT_ALLOCATED_EVENTID
1255 struct wmi_port_allocated_event
{
1256 u8 status
; /* wmi_fw_status */
1261 * WMI_PORT_DELETED_EVENTID
1263 struct wmi_port_deleted_event
{
1264 u8 status
; /* wmi_fw_status */
1269 * WMI_LISTEN_STARTED_EVENTID
1271 struct wmi_listen_started_event
{
1272 u8 status
; /* wmi_fw_status */
1277 * WMI_SEARCH_STARTED_EVENTID
1279 struct wmi_search_started_event
{
1280 u8 status
; /* wmi_fw_status */
1285 * WMI_PCP_STARTED_EVENTID
1287 struct wmi_pcp_started_event
{
1288 u8 status
; /* wmi_fw_status */
1293 * WMI_PCP_FACTOR_EVENTID
1295 struct wmi_pcp_factor_event
{
1300 * WMI_SW_TX_COMPLETE_EVENTID
1302 enum wmi_sw_tx_status
{
1303 WMI_TX_SW_STATUS_SUCCESS
= 0,
1304 WMI_TX_SW_STATUS_FAILED_NO_RESOURCES
= 1,
1305 WMI_TX_SW_STATUS_FAILED_TX
= 2,
1308 struct wmi_sw_tx_complete_event
{
1309 u8 status
; /* enum wmi_sw_tx_status */
1314 * WMI_CORR_MEASURE_EVENTID
1316 struct wmi_corr_measure_event
{
1324 * WMI_READ_RSSI_EVENTID
1326 struct wmi_read_rssi_event
{
1327 __le32 ina_rssi_adc_dbm
;
1331 * WMI_GET_SSID_EVENTID
1333 struct wmi_get_ssid_event
{
1335 u8 ssid
[WMI_MAX_SSID_LEN
];
1339 * WMI_RX_MGMT_PACKET_EVENTID
1341 struct wmi_rx_mgmt_info
{
1352 u8 channel
; /* From Radio MNGR */
1356 * WMI_TX_MGMT_PACKET_EVENTID
1358 struct wmi_tx_mgmt_packet_event
{
1362 struct wmi_rx_mgmt_packet_event
{
1363 struct wmi_rx_mgmt_info info
;
1368 * WMI_ECHO_RSP_EVENTID
1370 struct wmi_echo_event
{
1371 __le32 echoed_value
;
1375 * WMI_TEMP_SENSE_DONE_EVENTID
1377 * Measure MAC and radio temperatures
1379 struct wmi_temp_sense_done_event
{
1380 __le32 baseband_t1000
;
1384 #endif /* __WILOCITY_WMI_H__ */