blob: d4c1da7e8f33a204671c0cb179366b3bfe616b9f [file] [log] [blame]
Peng Xu291d97d2018-01-31 16:34:03 -08001/*
2 * Qualcomm Atheros OUI and vendor specific assignments
3 * Copyright (c) 2014-2017, Qualcomm Atheros, Inc.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05304 * Copyright (c) 2018-2020, The Linux Foundation
Peng Xu291d97d2018-01-31 16:34:03 -08005 *
6 * This software may be distributed under the terms of the BSD license.
7 * See README for more details.
8 */
9
10#ifndef QCA_VENDOR_H
11#define QCA_VENDOR_H
12
13/*
14 * This file is a registry of identifier assignments from the Qualcomm Atheros
15 * OUI 00:13:74 for purposes other than MAC address assignment. New identifiers
16 * can be assigned through normal review process for changes to the upstream
17 * hostap.git repository.
18 */
19
20#define OUI_QCA 0x001374
21
Jouni Malinenf735abd2020-08-03 11:08:00 +030022#ifndef BIT
23#define BIT(x) (1U << (x))
24#endif
25
Peng Xu291d97d2018-01-31 16:34:03 -080026/**
27 * enum qca_radiotap_vendor_ids - QCA radiotap vendor namespace IDs
28 */
29enum qca_radiotap_vendor_ids {
30 QCA_RADIOTAP_VID_WLANTEST = 0,
31};
32
33/**
34 * enum qca_nl80211_vendor_subcmds - QCA nl80211 vendor command identifiers
35 *
36 * @QCA_NL80211_VENDOR_SUBCMD_UNSPEC: Reserved value 0
37 *
38 * @QCA_NL80211_VENDOR_SUBCMD_TEST: Test command/event
39 *
40 * @QCA_NL80211_VENDOR_SUBCMD_ROAMING: Set roaming policy for drivers that use
41 * internal BSS-selection. This command uses
42 * @QCA_WLAN_VENDOR_ATTR_ROAMING_POLICY to specify the new roaming policy
43 * for the current connection (i.e., changes policy set by the nl80211
44 * Connect command). @QCA_WLAN_VENDOR_ATTR_MAC_ADDR may optionally be
45 * included to indicate which BSS to use in case roaming is disabled.
46 *
47 * @QCA_NL80211_VENDOR_SUBCMD_AVOID_FREQUENCY: Recommendation of frequency
48 * ranges to avoid to reduce issues due to interference or internal
Kiran Kumar Lokere2efd7682018-12-18 18:17:45 -080049 * co-existence information in the driver. These frequencies aim to
50 * minimize the traffic but not to totally avoid the traffic. That said
51 * for a P2P use case, these frequencies are allowed for the P2P
52 * discovery/negotiation but avoid the group to get formed on these
53 * frequencies. The event data structure is defined in
54 * struct qca_avoid_freq_list.
Peng Xu291d97d2018-01-31 16:34:03 -080055 *
56 * @QCA_NL80211_VENDOR_SUBCMD_DFS_CAPABILITY: Command to check driver support
57 * for DFS offloading.
58 *
59 * @QCA_NL80211_VENDOR_SUBCMD_NAN: NAN command/event which is used to pass
60 * NAN Request/Response and NAN Indication messages. These messages are
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -070061 * interpreted between the framework and the firmware component. While
62 * sending the command from userspace to the driver, payload is not
63 * encapsulated inside any attribute. Attribute QCA_WLAN_VENDOR_ATTR_NAN
64 * is used when receiving vendor events in userspace from the driver.
Peng Xu291d97d2018-01-31 16:34:03 -080065 *
66 * @QCA_NL80211_VENDOR_SUBCMD_KEY_MGMT_SET_KEY: Set key operation that can be
67 * used to configure PMK to the driver even when not connected. This can
68 * be used to request offloading of key management operations. Only used
69 * if device supports QCA_WLAN_VENDOR_FEATURE_KEY_MGMT_OFFLOAD.
70 *
71 * @QCA_NL80211_VENDOR_SUBCMD_KEY_MGMT_ROAM_AUTH: An extended version of
72 * NL80211_CMD_ROAM event with optional attributes including information
73 * from offloaded key management operation. Uses
74 * enum qca_wlan_vendor_attr_roam_auth attributes. Only used
75 * if device supports QCA_WLAN_VENDOR_FEATURE_KEY_MGMT_OFFLOAD.
76 *
77 * @QCA_NL80211_VENDOR_SUBCMD_DO_ACS: ACS command/event which is used to
78 * invoke the ACS function in device and pass selected channels to
Jouni Malinenf735abd2020-08-03 11:08:00 +030079 * hostapd. Uses enum qca_wlan_vendor_attr_acs_offload attributes.
Peng Xu291d97d2018-01-31 16:34:03 -080080 *
81 * @QCA_NL80211_VENDOR_SUBCMD_GET_FEATURES: Command to get the features
82 * supported by the driver. enum qca_wlan_vendor_features defines
83 * the possible features.
84 *
85 * @QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_STARTED: Event used by driver,
86 * which supports DFS offloading, to indicate a channel availability check
87 * start.
88 *
89 * @QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_FINISHED: Event used by driver,
90 * which supports DFS offloading, to indicate a channel availability check
91 * completion.
92 *
93 * @QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_ABORTED: Event used by driver,
94 * which supports DFS offloading, to indicate that the channel availability
95 * check aborted, no change to the channel status.
96 *
97 * @QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_NOP_FINISHED: Event used by
98 * driver, which supports DFS offloading, to indicate that the
99 * Non-Occupancy Period for this channel is over, channel becomes usable.
100 *
101 * @QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_RADAR_DETECTED: Event used by driver,
102 * which supports DFS offloading, to indicate a radar pattern has been
103 * detected. The channel is now unusable.
104 *
Jouni Malinenf735abd2020-08-03 11:08:00 +0300105 * @QCA_NL80211_VENDOR_SUBCMD_GET_WIFI_INFO: Get information from the driver.
106 * Attributes defined in enum qca_wlan_vendor_attr_get_wifi_info.
107 *
Peng Xu291d97d2018-01-31 16:34:03 -0800108 * @QCA_NL80211_VENDOR_SUBCMD_GET_LOGGER_FEATURE_SET: Get the feature bitmap
109 * based on enum wifi_logger_supported_features. Attributes defined in
110 * enum qca_wlan_vendor_attr_get_logger_features.
111 *
112 * @QCA_NL80211_VENDOR_SUBCMD_GET_RING_DATA: Get the ring data from a particular
113 * logger ring, QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_RING_ID is passed as the
114 * attribute for this command. Attributes defined in
115 * enum qca_wlan_vendor_attr_wifi_logger_start.
116 *
117 * @QCA_NL80211_VENDOR_SUBCMD_TDLS_GET_CAPABILITIES: Get the supported TDLS
118 * capabilities of the driver, parameters includes the attributes defined
119 * in enum qca_wlan_vendor_attr_tdls_get_capabilities.
120 *
121 * @QCA_NL80211_VENDOR_SUBCMD_OFFLOADED_PACKETS: Vendor command used to offload
122 * sending of certain periodic IP packet to firmware, attributes defined in
123 * enum qca_wlan_vendor_attr_offloaded_packets.
124 *
125 * @QCA_NL80211_VENDOR_SUBCMD_MONITOR_RSSI: Command used to configure RSSI
126 * monitoring, defines min and max RSSI which are configured for RSSI
127 * monitoring. Also used to notify the RSSI breach and provides the BSSID
128 * and RSSI value that was breached. Attributes defined in
129 * enum qca_wlan_vendor_attr_rssi_monitoring.
130 *
131 * @QCA_NL80211_VENDOR_SUBCMD_NDP: Command used for performing various NAN
132 * Data Path (NDP) related operations, attributes defined in
133 * enum qca_wlan_vendor_attr_ndp_params.
134 *
135 * @QCA_NL80211_VENDOR_SUBCMD_ND_OFFLOAD: Command used to enable/disable
136 * Neighbour Discovery offload, attributes defined in
137 * enum qca_wlan_vendor_attr_nd_offload.
138 *
139 * @QCA_NL80211_VENDOR_SUBCMD_PACKET_FILTER: Used to set/get the various
140 * configuration parameter for BPF packet filter, attributes defined in
141 * enum qca_wlan_vendor_attr_packet_filter.
142 *
143 * @QCA_NL80211_VENDOR_SUBCMD_GET_BUS_SIZE: Gets the driver-firmware
144 * maximum supported size, attributes defined in
145 * enum qca_wlan_vendor_drv_info.
146 *
147 * @QCA_NL80211_VENDOR_SUBCMD_GET_WAKE_REASON_STATS: Command to get various
148 * data about wake reasons and datapath IP statistics, attributes defined
149 * in enum qca_wlan_vendor_attr_wake_stats.
150 *
151 * @QCA_NL80211_VENDOR_SUBCMD_OCB_SET_CONFIG: Command used to set configuration
152 * for IEEE 802.11 communicating outside the context of a basic service
153 * set, called OCB command. Uses the attributes defines in
154 * enum qca_wlan_vendor_attr_ocb_set_config.
155 *
156 * @QCA_NL80211_VENDOR_SUBCMD_OCB_SET_UTC_TIME: Command used to set OCB
157 * UTC time. Use the attributes defines in
158 * enum qca_wlan_vendor_attr_ocb_set_utc_time.
159 *
160 * @QCA_NL80211_VENDOR_SUBCMD_OCB_START_TIMING_ADVERT: Command used to start
161 * sending OCB timing advert frames. Uses the attributes defines in
162 * enum qca_wlan_vendor_attr_ocb_start_timing_advert.
163 *
164 * @QCA_NL80211_VENDOR_SUBCMD_OCB_STOP_TIMING_ADVERT: Command used to stop
165 * OCB timing advert. Uses the attributes defines in
166 * enum qca_wlan_vendor_attr_ocb_stop_timing_advert.
167 *
168 * @QCA_NL80211_VENDOR_SUBCMD_OCB_GET_TSF_TIMER: Command used to get TSF
169 * timer value. Uses the attributes defines in
170 * enum qca_wlan_vendor_attr_ocb_get_tsf_resp.
171 *
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -0700172 * @QCA_NL80211_VENDOR_SUBCMD_LINK_PROPERTIES: Command/event to update the
173 * link properties of the respective interface. As an event, is used
174 * to notify the connected station's status. The attributes for this
175 * command are defined in enum qca_wlan_vendor_attr_link_properties.
176 *
Jouni Malinenf735abd2020-08-03 11:08:00 +0300177 * @QCA_NL80211_VENDOR_SUBCMD_SETBAND: Command to configure the enabled band(s)
178 * to the driver. This command sets the band(s) through either the
179 * attribute QCA_WLAN_VENDOR_ATTR_SETBAND_VALUE or
180 * QCA_WLAN_VENDOR_ATTR_SETBAND_MASK (or both).
181 * QCA_WLAN_VENDOR_ATTR_SETBAND_VALUE refers enum qca_set_band as unsigned
182 * integer values and QCA_WLAN_VENDOR_ATTR_SETBAND_MASK refers it as 32
183 * bit unsigned bitmask values. The allowed values for
184 * QCA_WLAN_VENDOR_ATTR_SETBAND_VALUE are limited to QCA_SETBAND_AUTO,
185 * QCA_SETBAND_5G, and QCA_SETBAND_2G. Other values/bitmasks are valid for
186 * QCA_WLAN_VENDOR_ATTR_SETBAND_MASK. The attribute
187 * QCA_WLAN_VENDOR_ATTR_SETBAND_VALUE is deprecated and the recommendation
188 * is to use the QCA_WLAN_VENDOR_ATTR_SETBAND_MASK. If the both attributes
189 * are included for backwards compatibility, the configurations through
190 * QCA_WLAN_VENDOR_ATTR_SETBAND_MASK will take the precedence with drivers
191 * that support both attributes.
192 *
193 * @QCA_NL80211_VENDOR_SUBCMD_ACS_POLICY: This command is used to configure
194 * DFS policy and channel hint for ACS operation. This command uses the
195 * attributes defined in enum qca_wlan_vendor_attr_acs_config and
196 * enum qca_acs_dfs_mode.
197 *
Peng Xu291d97d2018-01-31 16:34:03 -0800198 * @QCA_NL80211_VENDOR_SUBCMD_P2P_LISTEN_OFFLOAD_START: Command used to
199 * start the P2P Listen offload function in device and pass the listen
200 * channel, period, interval, count, device types, and vendor specific
201 * information elements to the device driver and firmware.
202 * Uses the attributes defines in
203 * enum qca_wlan_vendor_attr_p2p_listen_offload.
204 *
205 * @QCA_NL80211_VENDOR_SUBCMD_P2P_LISTEN_OFFLOAD_STOP: Command/event used to
206 * indicate stop request/response of the P2P Listen offload function in
207 * device. As an event, it indicates either the feature stopped after it
208 * was already running or feature has actually failed to start. Uses the
209 * attributes defines in enum qca_wlan_vendor_attr_p2p_listen_offload.
210 *
211 * @QCA_NL80211_VENDOR_SUBCMD_SAP_CONDITIONAL_CHAN_SWITCH: After AP starts
212 * beaconing, this sub command provides the driver, the frequencies on the
213 * 5 GHz band to check for any radar activity. Driver selects one channel
214 * from this priority list provided through
215 * @QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_FREQ_LIST and starts
216 * to check for radar activity on it. If no radar activity is detected
217 * during the channel availability check period, driver internally switches
218 * to the selected frequency of operation. If the frequency is zero, driver
219 * internally selects a channel. The status of this conditional switch is
220 * indicated through an event using the same sub command through
221 * @QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_STATUS. Attributes are
222 * listed in qca_wlan_vendor_attr_sap_conditional_chan_switch.
223 *
224 * @QCA_NL80211_VENDOR_SUBCMD_GPIO_CONFIG_COMMAND: Set GPIO pins. This uses the
225 * attributes defined in enum qca_wlan_gpio_attr.
226 *
227 * @QCA_NL80211_VENDOR_SUBCMD_GET_HW_CAPABILITY: Fetch hardware capabilities.
228 * This uses @QCA_WLAN_VENDOR_ATTR_GET_HW_CAPABILITY to indicate which
229 * capabilities are to be fetched and other
230 * enum qca_wlan_vendor_attr_get_hw_capability attributes to return the
231 * requested capabilities.
232 *
233 * @QCA_NL80211_VENDOR_SUBCMD_LL_STATS_EXT: Link layer statistics extension.
234 * enum qca_wlan_vendor_attr_ll_stats_ext attributes are used with this
235 * command and event.
236 *
237 * @QCA_NL80211_VENDOR_SUBCMD_LOC_GET_CAPA: Get capabilities for
238 * indoor location features. Capabilities are reported in
239 * QCA_WLAN_VENDOR_ATTR_LOC_CAPA.
240 *
241 * @QCA_NL80211_VENDOR_SUBCMD_FTM_START_SESSION: Start an FTM
242 * (fine timing measurement) session with one or more peers.
243 * Specify Session cookie in QCA_WLAN_VENDOR_ATTR_FTM_SESSION_COOKIE and
244 * peer information in QCA_WLAN_VENDOR_ATTR_FTM_MEAS_PEERS.
245 * On success, 0 or more QCA_NL80211_VENDOR_SUBCMD_FTM_MEAS_RESULT
246 * events will be reported, followed by
247 * QCA_NL80211_VENDOR_SUBCMD_FTM_SESSION_DONE event to indicate
248 * end of session.
249 * Refer to IEEE P802.11-REVmc/D7.0, 11.24.6
250 *
251 * @QCA_NL80211_VENDOR_SUBCMD_FTM_ABORT_SESSION: Abort a running session.
252 * A QCA_NL80211_VENDOR_SUBCMD_FTM_SESSION_DONE will be reported with
253 * status code indicating session was aborted.
254 *
255 * @QCA_NL80211_VENDOR_SUBCMD_FTM_MEAS_RESULT: Event with measurement
256 * results for one peer. Results are reported in
257 * QCA_WLAN_VENDOR_ATTR_FTM_MEAS_PEER_RESULTS.
258 *
259 * @QCA_NL80211_VENDOR_SUBCMD_FTM_SESSION_DONE: Event triggered when
260 * FTM session is finished, either successfully or aborted by
261 * request.
262 *
263 * @QCA_NL80211_VENDOR_SUBCMD_FTM_CFG_RESPONDER: Configure FTM responder
264 * mode. QCA_WLAN_VENDOR_ATTR_FTM_RESPONDER_ENABLE specifies whether
265 * to enable or disable the responder. LCI/LCR reports can be
266 * configured with QCA_WLAN_VENDOR_ATTR_FTM_LCI and
267 * QCA_WLAN_VENDOR_ATTR_FTM_LCR. Can be called multiple
268 * times to update the LCI/LCR reports.
269 *
270 * @QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS: Perform a standalone AOA (angle of
271 * arrival) measurement with a single peer. Specify peer MAC address in
272 * QCA_WLAN_VENDOR_ATTR_MAC_ADDR and optionally frequency (MHz) in
273 * QCA_WLAN_VENDOR_ATTR_FREQ (if not specified, locate peer in kernel
274 * scan results cache and use the frequency from there).
275 * Also specify measurement type in QCA_WLAN_VENDOR_ATTR_AOA_TYPE.
276 * Measurement result is reported in
277 * QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS_RESULT event.
278 *
279 * @QCA_NL80211_VENDOR_SUBCMD_AOA_ABORT_MEAS: Abort an AOA measurement. Specify
280 * peer MAC address in QCA_WLAN_VENDOR_ATTR_MAC_ADDR.
281 *
282 * @QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS_RESULT: Event that reports
283 * the AOA measurement result.
284 * Peer MAC address reported in QCA_WLAN_VENDOR_ATTR_MAC_ADDR.
285 * success/failure status is reported in
286 * QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS.
287 * Measurement data is reported in QCA_WLAN_VENDOR_ATTR_AOA_MEAS_RESULT.
288 * The antenna array(s) used in the measurement are reported in
289 * QCA_WLAN_VENDOR_ATTR_LOC_ANTENNA_ARRAY_MASK.
290 *
291 * @QCA_NL80211_VENDOR_SUBCMD_ENCRYPTION_TEST: Encrypt/decrypt the given
292 * data as per the given parameters.
293 *
294 * @QCA_NL80211_VENDOR_SUBCMD_GET_CHAIN_RSSI: Get antenna RSSI value for a
295 * specific chain.
296 *
297 * @QCA_NL80211_VENDOR_SUBCMD_DMG_RF_GET_SECTOR_CFG: Get low level
298 * configuration for a DMG RF sector. Specify sector index in
299 * QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_INDEX, sector type in
300 * QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE and RF modules
301 * to return sector information for in
302 * QCA_WLAN_VENDOR_ATTR_DMG_RF_MODULE_MASK. Returns sector configuration
303 * in QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG. Also return the
304 * exact time where information was captured in
305 * QCA_WLAN_VENDOR_ATTR_TSF.
306 *
307 * @QCA_NL80211_VENDOR_SUBCMD_DMG_RF_SET_SECTOR_CFG: Set low level
308 * configuration for a DMG RF sector. Specify sector index in
309 * QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_INDEX, sector type in
310 * QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE and sector configuration
311 * for one or more DMG RF modules in
312 * QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG.
313 *
314 * @QCA_NL80211_VENDOR_SUBCMD_DMG_RF_GET_SELECTED_SECTOR: Get selected
315 * DMG RF sector for a station. This is the sector that the HW
316 * will use to communicate with the station. Specify the MAC address
317 * of associated station/AP/PCP in QCA_WLAN_VENDOR_ATTR_MAC_ADDR (not
318 * needed for unassociated station). Specify sector type to return in
319 * QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE. Returns the selected
320 * sector index in QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_INDEX.
321 * Also return the exact time where the information was captured
322 * in QCA_WLAN_VENDOR_ATTR_TSF.
323 *
324 * @QCA_NL80211_VENDOR_SUBCMD_DMG_RF_SET_SELECTED_SECTOR: Set the
325 * selected DMG RF sector for a station. This is the sector that
326 * the HW will use to communicate with the station.
327 * Specify the MAC address of associated station/AP/PCP in
328 * QCA_WLAN_VENDOR_ATTR_MAC_ADDR, the sector type to select in
329 * QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE and the sector index
330 * in QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_INDEX.
331 * The selected sector will be locked such that it will not be
332 * modified like it normally does (for example when station
333 * moves around). To unlock the selected sector for a station
334 * pass the special value 0xFFFF in the sector index. To unlock
335 * all connected stations also pass a broadcast MAC address.
336 *
337 * @QCA_NL80211_VENDOR_SUBCMD_CONFIGURE_TDLS: Configure the TDLS behavior
338 * in the host driver. The different TDLS configurations are defined
339 * by the attributes in enum qca_wlan_vendor_attr_tdls_configuration.
340 *
341 * @QCA_NL80211_VENDOR_SUBCMD_GET_HE_CAPABILITIES: Query device IEEE 802.11ax HE
342 * capabilities. The response uses the attributes defined in
343 * enum qca_wlan_vendor_attr_get_he_capabilities.
344 *
345 * @QCA_NL80211_VENDOR_SUBCMD_ABORT_SCAN: Abort an ongoing vendor scan that was
346 * started with QCA_NL80211_VENDOR_SUBCMD_TRIGGER_SCAN. This command
347 * carries the scan cookie of the corresponding scan request. The scan
348 * cookie is represented by QCA_WLAN_VENDOR_ATTR_SCAN_COOKIE.
349 *
350 * @QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS: Set the Specific
351 * Absorption Rate (SAR) power limits. A critical regulation for
352 * FCC compliance, OEMs require methods to set SAR limits on TX
353 * power of WLAN/WWAN. enum qca_vendor_attr_sar_limits
354 * attributes are used with this command.
355 *
356 * @QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS: This command/event is used by the
357 * host driver for offloading the implementation of Auto Channel Selection
358 * (ACS) to an external user space entity. This interface is used as the
359 * event from the host driver to the user space entity and also as the
360 * request from the user space entity to the host driver. The event from
361 * the host driver is used by the user space entity as an indication to
362 * start the ACS functionality. The attributes used by this event are
363 * represented by the enum qca_wlan_vendor_attr_external_acs_event.
364 * User space entity uses the same interface to inform the host driver with
365 * selected channels after the ACS operation using the attributes defined
366 * by enum qca_wlan_vendor_attr_external_acs_channels.
367 *
368 * @QCA_NL80211_VENDOR_SUBCMD_CHIP_PWRSAVE_FAILURE: Vendor event carrying the
369 * requisite information leading to a power save failure. The information
370 * carried as part of this event is represented by the
371 * enum qca_attr_chip_power_save_failure attributes.
372 *
373 * @QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_SET: Start/Stop the NUD statistics
374 * collection. Uses attributes defined in enum qca_attr_nud_stats_set.
375 *
376 * @QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_GET: Get the NUD statistics. These
377 * statistics are represented by the enum qca_attr_nud_stats_get
378 * attributes.
379 *
380 * @QCA_NL80211_VENDOR_SUBCMD_FETCH_BSS_TRANSITION_STATUS: Sub-command to fetch
381 * the BSS transition status, whether accept or reject, for a list of
382 * candidate BSSIDs provided by the userspace. This uses the vendor
383 * attributes QCA_WLAN_VENDOR_ATTR_BTM_MBO_TRANSITION_REASON and
384 * QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO. The userspace shall specify
385 * the attributes QCA_WLAN_VENDOR_ATTR_BTM_MBO_TRANSITION_REASON and an
386 * array of QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_BSSID nested in
387 * QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO in the request. In the response
388 * the driver shall specify array of
389 * QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_BSSID and
390 * QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_STATUS pairs nested in
391 * QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO.
392 *
393 * @QCA_NL80211_VENDOR_SUBCMD_SET_TRACE_LEVEL: Set the trace level for a
394 * specific QCA module. The trace levels are represented by
395 * enum qca_attr_trace_level attributes.
396 *
397 * @QCA_NL80211_VENDOR_SUBCMD_BRP_SET_ANT_LIMIT: Set the Beam Refinement
398 * Protocol antenna limit in different modes. See enum
399 * qca_wlan_vendor_attr_brp_ant_limit_mode.
400 *
401 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_START: Start spectral scan. The scan
402 * parameters are specified by enum qca_wlan_vendor_attr_spectral_scan.
403 * This returns a cookie (%QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_COOKIE)
Jouni Malinenf735abd2020-08-03 11:08:00 +0300404 * identifying the operation in success case. In failure cases an
405 * error code (%QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_ERROR_CODE)
406 * describing the reason for the failure is returned.
Peng Xu291d97d2018-01-31 16:34:03 -0800407 *
408 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_STOP: Stop spectral scan. This uses
409 * a cookie (%QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_COOKIE) from
410 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_START to identify the scan to
411 * be stopped.
412 *
413 * @QCA_NL80211_VENDOR_SUBCMD_ACTIVE_TOS: Set the active Type Of Service on the
414 * specific interface. This can be used to modify some of the low level
415 * scan parameters (off channel dwell time, home channel time) in the
416 * driver/firmware. These parameters are maintained within the host driver.
417 * This command is valid only when the interface is in the connected state.
418 * These scan parameters shall be reset by the driver/firmware once
419 * disconnected. The attributes used with this command are defined in
420 * enum qca_wlan_vendor_attr_active_tos.
421 *
422 * @QCA_NL80211_VENDOR_SUBCMD_HANG: Event indicating to the user space that the
423 * driver has detected an internal failure. This event carries the
424 * information indicating the reason that triggered this detection. The
425 * attributes for this command are defined in
426 * enum qca_wlan_vendor_attr_hang.
427 *
428 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_CONFIG: Get the current values
429 * of spectral parameters used. The spectral scan parameters are specified
430 * by enum qca_wlan_vendor_attr_spectral_scan.
431 *
432 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_DIAG_STATS: Get the debug stats
433 * for spectral scan functionality. The debug stats are specified by
434 * enum qca_wlan_vendor_attr_spectral_diag_stats.
435 *
436 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_CAP_INFO: Get spectral
437 * scan system capabilities. The capabilities are specified
438 * by enum qca_wlan_vendor_attr_spectral_cap.
439 *
440 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_STATUS: Get the current
441 * status of spectral scan. The status values are specified
442 * by enum qca_wlan_vendor_attr_spectral_scan_status.
443 *
444 * @QCA_NL80211_VENDOR_SUBCMD_PEER_FLUSH_PENDING: Sub-command to flush
445 * peer pending packets. Specify the peer MAC address in
446 * QCA_WLAN_VENDOR_ATTR_PEER_ADDR and the access category of the packets
447 * in QCA_WLAN_VENDOR_ATTR_AC. The attributes are listed
448 * in enum qca_wlan_vendor_attr_flush_pending.
449 *
450 * @QCA_NL80211_VENDOR_SUBCMD_GET_RROP_INFO: Get vendor specific Representative
451 * RF Operating Parameter (RROP) information. The attributes for this
452 * information are defined in enum qca_wlan_vendor_attr_rrop_info. This is
453 * intended for use by external Auto Channel Selection applications.
454 *
455 * @QCA_NL80211_VENDOR_SUBCMD_GET_SAR_LIMITS: Get the Specific Absorption Rate
456 * (SAR) power limits. This is a companion to the command
457 * @QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS and is used to retrieve the
458 * settings currently in use. The attributes returned by this command are
459 * defined by enum qca_vendor_attr_sar_limits.
460 *
461 * @QCA_NL80211_VENDOR_SUBCMD_WLAN_MAC_INFO: Provides the current behavior of
462 * the WLAN hardware MAC. Also, provides the WLAN netdev interface
463 * information attached to the respective MAC.
464 * This works both as a query (user space asks the current mode) or event
465 * interface (driver advertising the current mode to the user space).
466 * Driver does not trigger this event for temporary hardware mode changes.
467 * Mode changes w.r.t Wi-Fi connection update (VIZ creation / deletion,
468 * channel change, etc.) are updated with this event. Attributes for this
469 * interface are defined in enum qca_wlan_vendor_attr_mac.
470 *
471 * @QCA_NL80211_VENDOR_SUBCMD_SET_QDEPTH_THRESH: Set MSDU queue depth threshold
472 * per peer per TID. Attributes for this command are define in
473 * enum qca_wlan_set_qdepth_thresh_attr.
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -0800474 * @QCA_NL80211_VENDOR_SUBCMD_THERMAL_CMD: Provides the thermal shutdown action
475 * guide for WLAN driver. Request to suspend of driver and FW if the
476 * temperature is higher than the suspend threshold; resume action is
477 * requested to driver if the temperature is lower than the resume
478 * threshold. In user poll mode, request temperature data by user. For test
479 * purpose, getting thermal shutdown configuration parameters is needed.
480 * Attributes for this interface are defined in
481 * enum qca_wlan_vendor_attr_thermal_cmd.
482 * @QCA_NL80211_VENDOR_SUBCMD_THERMAL_EVENT: Thermal events reported from
483 * driver. Thermal temperature and indication of resume completion are
484 * reported as thermal events. The attributes for this command are defined
485 * in enum qca_wlan_vendor_attr_thermal_event.
486 *
487 * @QCA_NL80211_VENDOR_SUBCMD_WIFI_TEST_CONFIGURATION: Sub command to set WiFi
Arif Hussaine2645c62018-05-24 20:39:04 -0700488 * test configuration. Attributes for this command are defined in
489 * enum qca_wlan_vendor_attr_wifi_test_config.
490 *
491 * @QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER: This command is used to configure an
492 * RX filter to receive frames from stations that are active on the
493 * operating channel, but not associated with the local device (e.g., STAs
494 * associated with other APs). Filtering is done based on a list of BSSIDs
495 * and STA MAC addresses added by the user. This command is also used to
496 * fetch the statistics of unassociated stations. The attributes used with
497 * this command are defined in enum qca_wlan_vendor_attr_bss_filter.
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -0700498 *
499 * @QCA_NL80211_VENDOR_SUBCMD_NAN_EXT: An extendable version of NAN vendor
500 * command. The earlier command for NAN, QCA_NL80211_VENDOR_SUBCMD_NAN,
501 * carried a payload which was a binary blob of data. The command was not
502 * extendable to send more information. The newer version carries the
503 * legacy blob encapsulated within an attribute and can be extended with
504 * additional vendor attributes that can enhance the NAN command interface.
505 * @QCA_NL80211_VENDOR_SUBCMD_ROAM_SCAN_EVENT: Event to indicate scan triggered
506 * or stopped within driver/firmware in order to initiate roaming. The
507 * attributes used with this event are defined in enum
508 * qca_wlan_vendor_attr_roam_scan. Some drivers may not send these events
509 * in few cases, e.g., if the host processor is sleeping when this event
510 * is generated in firmware.
511 *
512 * @QCA_NL80211_VENDOR_SUBCMD_PEER_CFR_CAPTURE_CFG: This command is used to
513 * configure parameters per peer to capture Channel Frequency Response
514 * (CFR) and enable Periodic CFR capture. The attributes for this command
515 * are defined in enum qca_wlan_vendor_peer_cfr_capture_attr.
516 *
517 * @QCA_NL80211_VENDOR_SUBCMD_THROUGHPUT_CHANGE_EVENT: Event to indicate changes
518 * in throughput dynamically. The driver estimates the throughput based on
519 * number of packets being transmitted/received per second and indicates
520 * the changes in throughput to user space. Userspace tools can use this
521 * information to configure kernel's TCP parameters in order to achieve
522 * peak throughput. Optionally, the driver will also send guidance on
523 * modifications to kernel's TCP parameters which can be referred by
524 * userspace tools. The attributes used with this event are defined in enum
525 * qca_wlan_vendor_attr_throughput_change.
526 *
527 * @QCA_NL80211_VENDOR_SUBCMD_COEX_CONFIG: This command is used to set
528 * priorities among different types of traffic during coex scenarios.
529 * Current supported prioritization is among WLAN/BT/ZIGBEE with different
530 * profiles mentioned in enum qca_coex_config_profiles. The associated
531 * attributes used with this command are defined in enum
532 * qca_vendor_attr_coex_config.
533 *
534 * Based on the config provided, FW will boost the weight and prioritize
535 * the traffic for that subsystem (WLAN/BT/Zigbee).
Kiran Kumar Lokere2efd7682018-12-18 18:17:45 -0800536 *
537 * @QCA_NL80211_VENDOR_SUBCMD_GET_SUPPORTED_AKMS: This command is used to query
538 * the supported AKM suite selectorss from the driver. It returns the list
539 * of supported AKMs in the attribute NL80211_ATTR_AKM_SUITES.
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -0800540 * @QCA_NL80211_VENDOR_SUBCMD_GET_FW_STATE: This command is used to get firmware
541 * state from the driver. It returns the firmware state in the attribute
542 * QCA_WLAN_VENDOR_ATTR_FW_STATE.
543 * @QCA_NL80211_VENDOR_SUBCMD_PEER_STATS_CACHE_FLUSH: This vendor subcommand
544 * is used by the driver to flush per-peer cached statistics to user space
545 * application. This interface is used as an event from the driver to
546 * user space application. Attributes for this event are specified in
547 * enum qca_wlan_vendor_attr_peer_stats_cache_params.
548 * QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_DATA attribute is expected to be
549 * sent in the event.
550 * @QCA_NL80211_VENDOR_SUBCMD_MPTA_HELPER_CONFIG: This sub command is used to
551 * improve the success rate of Zigbee joining network.
552 * Due to PTA master limitation, Zigbee joining network success rate is
553 * low while WLAN is working. The WLAN driver needs to configure some
554 * parameters including Zigbee state and specific WLAN periods to enhance
555 * PTA master. All these parameters are delivered by the attributes
556 * defined in enum qca_mpta_helper_vendor_attr.
Jouni Malinenf735abd2020-08-03 11:08:00 +0300557 * @QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING: This sub command is used to
558 * implement Beacon frame reporting feature.
559 *
560 * Userspace can request the driver/firmware to periodically report
561 * received Beacon frames whose BSSID is same as the current connected
562 * BSS's MAC address.
563 *
564 * In case the STA seamlessly (without sending disconnect indication to
565 * userspace) roams to a different BSS, Beacon frame reporting will be
566 * automatically enabled for the Beacon frames whose BSSID is same as the
567 * MAC address of the new BSS. Beacon reporting will be stopped when the
568 * STA is disconnected (when the disconnect indication is sent to
569 * userspace) and need to be explicitly enabled by userspace for next
570 * connection.
571 *
572 * When a Beacon frame matching configured conditions is received, and if
573 * userspace has requested to send asynchronous beacon reports, the
574 * driver/firmware will encapsulate the details of the Beacon frame in an
575 * event and send it to userspace along with updating the BSS information
576 * in cfg80211 scan cache, otherwise driver will only update the cfg80211
577 * scan cache with the information from the received Beacon frame but will
578 * not send any active report to userspace.
579 *
580 * The userspace can request the driver/firmware to stop reporting Beacon
581 * frames. If the driver/firmware is not able to receive Beacon frames due
582 * to other Wi-Fi operations such as off-channel activities, etc., the
583 * driver/firmware will send a pause event to userspace and stop reporting
584 * Beacon frames. Whether the beacon reporting will be automatically
585 * resumed or not by the driver/firmware later will be reported to
586 * userspace using the QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_AUTO_RESUMES
587 * flag. The beacon reporting shall be resumed for all the cases except
588 * either when userspace sets
589 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_DO_NOT_RESUME flag in the command
590 * which triggered the current beacon reporting or during any disconnection
591 * case as indicated by setting
592 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_PAUSE_REASON to
593 * QCA_WLAN_VENDOR_BEACON_REPORTING_PAUSE_REASON_DISCONNECTED by the
594 * driver.
595 *
596 * After QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_PAUSE event is received
597 * by userspace with QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_AUTO_RESUMES
598 * flag not set, the next first
599 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO event from the driver
600 * shall be considered as un-pause event.
601 *
602 * All the attributes used with this command are defined in
603 * enum qca_wlan_vendor_attr_beacon_reporting_params.
604 * @QCA_NL80211_VENDOR_SUBCMD_INTEROP_ISSUES_AP: In practice, some APs have
605 * interop issues with the DUT. This sub command is used to transfer the
606 * AP info between the driver and user space. This works both as a command
607 * and an event. As a command, it configures the stored list of APs from
608 * user space to firmware; as an event, it indicates the AP info detected
609 * by the firmware to user space for persistent storage. The attributes
610 * defined in enum qca_vendor_attr_interop_issues_ap are used to deliver
611 * the parameters.
612 * @QCA_NL80211_VENDOR_SUBCMD_OEM_DATA: This command/event is used to
613 * send/receive OEM data binary blobs to/from application/service to/from
614 * firmware. The attributes defined in enum
615 * qca_wlan_vendor_attr_oem_data_params are used to deliver the
616 * parameters.
617 * @QCA_NL80211_VENDOR_SUBCMD_AVOID_FREQUENCY_EXT: This command/event is used
618 * to send/receive avoid frequency data using
619 * enum qca_wlan_vendor_attr_avoid_frequency_ext.
620 * This new command is alternative to existing command
621 * QCA_NL80211_VENDOR_SUBCMD_AVOID_FREQUENCY since existing command/event
622 * is using stream of bytes instead of structured data using vendor
623 * attributes.
624 *
625 * @QCA_NL80211_VENDOR_SUBCMD_ADD_STA_NODE: This vendor subcommand is used to
626 * add the STA node details in driver/firmware. Attributes for this event
627 * are specified in enum qca_wlan_vendor_attr_add_sta_node_params.
628 * @QCA_NL80211_VENDOR_SUBCMD_BTC_CHAIN_MODE: This command is used to set BT
629 * coex chain mode from application/service.
630 * The attributes defined in enum qca_vendor_attr_btc_chain_mode are used
631 * to deliver the parameters.
632 *
633 * @QCA_NL80211_VENDOR_SUBCMD_GET_STA_INFO: This vendor subcommand is used to
634 * get information of a station from driver to userspace. This command can
635 * be used in both STA and AP modes. For STA mode, it provides information
636 * of the current association when in connected state or the last
637 * association when in disconnected state. For AP mode, only information
638 * of the currently connected stations is available. This command uses
639 * attributes defined in enum qca_wlan_vendor_attr_get_sta_info.
640 *
641 * @QCA_NL80211_VENDOR_SUBCMD_REQUEST_SAR_LIMITS_EVENT: This acts as an event.
642 * Host drivers can request the user space entity to set the SAR power
643 * limits with this event. Accordingly, the user space entity is expected
644 * to set the SAR power limits. Host drivers can retry this event to the
645 * user space for the SAR power limits configuration from user space. If
646 * the driver does not get the SAR power limits from user space for all
647 * the retried attempts, it can configure a default SAR power limit.
648 *
649 * @QCA_NL80211_VENDOR_SUBCMD_UPDATE_STA_INFO: This acts as a vendor event and
650 * is used to update the information about the station from the driver to
651 * userspace. Uses attributes from enum
652 * qca_wlan_vendor_attr_update_sta_info.
653 *
654 * @QCA_NL80211_VENDOR_SUBCMD_DRIVER_DISCONNECT_REASON: This acts as an event.
655 * The host driver initiates the disconnection for scenarios such as beacon
656 * miss, NUD failure, peer kick out, etc. The disconnection indication
657 * through cfg80211_disconnected() expects the reason codes from enum
658 * ieee80211_reasoncode which does not signify these various reasons why
659 * the driver has triggered the disconnection. This event will be used to
660 * send the driver specific reason codes by the host driver to userspace.
661 * Host drivers should trigger this event and pass the respective reason
662 * code immediately prior to triggering cfg80211_disconnected(). The
663 * attributes used with this event are defined in enum
664 * qca_wlan_vendor_attr_driver_disconnect_reason.
665 *
666 * @QCA_NL80211_VENDOR_SUBCMD_CONFIG_TSPEC: This vendor subcommand is used to
667 * add/delete TSPEC for each AC. One command is for one specific AC only.
668 * This command can only be used in STA mode and the STA must be
669 * associated with an AP when the command is issued. Uses attributes
670 * defined in enum qca_wlan_vendor_attr_config_tspec.
671 *
672 * @QCA_NL80211_VENDOR_SUBCMD_CONFIG_TWT: Vendor subcommand to configure TWT.
673 * Uses attributes defined in enum qca_wlan_vendor_attr_config_twt.
674 *
675 * @QCA_NL80211_VENDOR_SUBCMD_GETBAND: Command to get the enabled band(s) from
676 * the driver. The band configurations obtained are referred through
677 * QCA_WLAN_VENDOR_ATTR_SETBAND_MASK.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +0530678 *
679 * @QCA_NL80211_VENDOR_SUBCMD_MEDIUM_ASSESS: Vendor subcommand/event for medium
680 * assessment.
681 * Uses attributes defined in enum qca_wlan_vendor_attr_medium_assess.
682 *
683 * @QCA_NL80211_VENDOR_SUBCMD_UPDATE_SSID: This acts as a vendor event and is
684 * used to update SSID information in hostapd when it is updated in the
685 * driver. Uses the attribute NL80211_ATTR_SSID.
686 *
687 * @QCA_NL80211_VENDOR_SUBCMD_WIFI_FW_STATS: This vendor subcommand is used by
688 * the driver to send opaque data from the firmware to userspace. The
689 * driver sends an event to userspace whenever such data is received from
690 * the firmware.
691 *
692 * QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_DATA is used as the attribute to
693 * send this opaque data for this event.
694 *
695 * The format of the opaque data is specific to the particular firmware
696 * version and there is no guarantee of the format remaining same.
697 *
698 * @QCA_NL80211_VENDOR_SUBCMD_MBSSID_TX_VDEV_STATUS: This acts as an event.
699 * The host driver selects Tx VDEV, and notifies user. The attributes
700 * used with this event are defined in enum
701 * qca_wlan_vendor_attr_mbssid_tx_vdev_status.
702 *
Peng Xu291d97d2018-01-31 16:34:03 -0800703 */
704enum qca_nl80211_vendor_subcmds {
705 QCA_NL80211_VENDOR_SUBCMD_UNSPEC = 0,
706 QCA_NL80211_VENDOR_SUBCMD_TEST = 1,
707 /* subcmds 2..8 not yet allocated */
708 QCA_NL80211_VENDOR_SUBCMD_ROAMING = 9,
709 QCA_NL80211_VENDOR_SUBCMD_AVOID_FREQUENCY = 10,
710 QCA_NL80211_VENDOR_SUBCMD_DFS_CAPABILITY = 11,
711 QCA_NL80211_VENDOR_SUBCMD_NAN = 12,
712 QCA_NL80211_VENDOR_SUBCMD_STATS_EXT = 13,
713 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_SET = 14,
714 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_GET = 15,
715 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_CLR = 16,
716 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_RADIO_RESULTS = 17,
717 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_IFACE_RESULTS = 18,
718 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_PEERS_RESULTS = 19,
719 QCA_NL80211_VENDOR_SUBCMD_GSCAN_START = 20,
720 QCA_NL80211_VENDOR_SUBCMD_GSCAN_STOP = 21,
721 QCA_NL80211_VENDOR_SUBCMD_GSCAN_GET_VALID_CHANNELS = 22,
722 QCA_NL80211_VENDOR_SUBCMD_GSCAN_GET_CAPABILITIES = 23,
723 QCA_NL80211_VENDOR_SUBCMD_GSCAN_GET_CACHED_RESULTS = 24,
724 QCA_NL80211_VENDOR_SUBCMD_GSCAN_SCAN_RESULTS_AVAILABLE = 25,
725 QCA_NL80211_VENDOR_SUBCMD_GSCAN_FULL_SCAN_RESULT = 26,
726 QCA_NL80211_VENDOR_SUBCMD_GSCAN_SCAN_EVENT = 27,
727 QCA_NL80211_VENDOR_SUBCMD_GSCAN_HOTLIST_AP_FOUND = 28,
728 QCA_NL80211_VENDOR_SUBCMD_GSCAN_SET_BSSID_HOTLIST = 29,
729 QCA_NL80211_VENDOR_SUBCMD_GSCAN_RESET_BSSID_HOTLIST = 30,
730 QCA_NL80211_VENDOR_SUBCMD_GSCAN_SIGNIFICANT_CHANGE = 31,
731 QCA_NL80211_VENDOR_SUBCMD_GSCAN_SET_SIGNIFICANT_CHANGE = 32,
732 QCA_NL80211_VENDOR_SUBCMD_GSCAN_RESET_SIGNIFICANT_CHANGE = 33,
733 QCA_NL80211_VENDOR_SUBCMD_TDLS_ENABLE = 34,
734 QCA_NL80211_VENDOR_SUBCMD_TDLS_DISABLE = 35,
735 QCA_NL80211_VENDOR_SUBCMD_TDLS_GET_STATUS = 36,
736 QCA_NL80211_VENDOR_SUBCMD_TDLS_STATE = 37,
737 QCA_NL80211_VENDOR_SUBCMD_GET_SUPPORTED_FEATURES = 38,
738 QCA_NL80211_VENDOR_SUBCMD_SCANNING_MAC_OUI = 39,
739 QCA_NL80211_VENDOR_SUBCMD_NO_DFS_FLAG = 40,
740 QCA_NL80211_VENDOR_SUBCMD_GSCAN_HOTLIST_AP_LOST = 41,
741 QCA_NL80211_VENDOR_SUBCMD_GET_CONCURRENCY_MATRIX = 42,
742 /* 43..49 - reserved for QCA */
743 QCA_NL80211_VENDOR_SUBCMD_KEY_MGMT_SET_KEY = 50,
744 QCA_NL80211_VENDOR_SUBCMD_KEY_MGMT_ROAM_AUTH = 51,
745 QCA_NL80211_VENDOR_SUBCMD_APFIND = 52,
746 /* 53 - reserved - was used by QCA, but not in use anymore */
747 QCA_NL80211_VENDOR_SUBCMD_DO_ACS = 54,
748 QCA_NL80211_VENDOR_SUBCMD_GET_FEATURES = 55,
749 QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_STARTED = 56,
750 QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_FINISHED = 57,
751 QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_ABORTED = 58,
752 QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_CAC_NOP_FINISHED = 59,
753 QCA_NL80211_VENDOR_SUBCMD_DFS_OFFLOAD_RADAR_DETECTED = 60,
754 QCA_NL80211_VENDOR_SUBCMD_GET_WIFI_INFO = 61,
755 QCA_NL80211_VENDOR_SUBCMD_WIFI_LOGGER_START = 62,
756 QCA_NL80211_VENDOR_SUBCMD_WIFI_LOGGER_MEMORY_DUMP = 63,
757 QCA_NL80211_VENDOR_SUBCMD_ROAM = 64,
758 QCA_NL80211_VENDOR_SUBCMD_GSCAN_SET_SSID_HOTLIST = 65,
759 QCA_NL80211_VENDOR_SUBCMD_GSCAN_RESET_SSID_HOTLIST = 66,
760 QCA_NL80211_VENDOR_SUBCMD_GSCAN_HOTLIST_SSID_FOUND = 67,
761 QCA_NL80211_VENDOR_SUBCMD_GSCAN_HOTLIST_SSID_LOST = 68,
762 QCA_NL80211_VENDOR_SUBCMD_PNO_SET_LIST = 69,
763 QCA_NL80211_VENDOR_SUBCMD_PNO_SET_PASSPOINT_LIST = 70,
764 QCA_NL80211_VENDOR_SUBCMD_PNO_RESET_PASSPOINT_LIST = 71,
765 QCA_NL80211_VENDOR_SUBCMD_PNO_NETWORK_FOUND = 72,
766 QCA_NL80211_VENDOR_SUBCMD_PNO_PASSPOINT_NETWORK_FOUND = 73,
767 /* Wi-Fi configuration subcommands */
768 QCA_NL80211_VENDOR_SUBCMD_SET_WIFI_CONFIGURATION = 74,
769 QCA_NL80211_VENDOR_SUBCMD_GET_WIFI_CONFIGURATION = 75,
770 QCA_NL80211_VENDOR_SUBCMD_GET_LOGGER_FEATURE_SET = 76,
771 QCA_NL80211_VENDOR_SUBCMD_GET_RING_DATA = 77,
772 QCA_NL80211_VENDOR_SUBCMD_TDLS_GET_CAPABILITIES = 78,
773 QCA_NL80211_VENDOR_SUBCMD_OFFLOADED_PACKETS = 79,
774 QCA_NL80211_VENDOR_SUBCMD_MONITOR_RSSI = 80,
775 QCA_NL80211_VENDOR_SUBCMD_NDP = 81,
776 QCA_NL80211_VENDOR_SUBCMD_ND_OFFLOAD = 82,
777 QCA_NL80211_VENDOR_SUBCMD_PACKET_FILTER = 83,
778 QCA_NL80211_VENDOR_SUBCMD_GET_BUS_SIZE = 84,
779 QCA_NL80211_VENDOR_SUBCMD_GET_WAKE_REASON_STATS = 85,
780 /* 86-90 - reserved for QCA */
781 QCA_NL80211_VENDOR_SUBCMD_DATA_OFFLOAD = 91,
782 QCA_NL80211_VENDOR_SUBCMD_OCB_SET_CONFIG = 92,
783 QCA_NL80211_VENDOR_SUBCMD_OCB_SET_UTC_TIME = 93,
784 QCA_NL80211_VENDOR_SUBCMD_OCB_START_TIMING_ADVERT = 94,
785 QCA_NL80211_VENDOR_SUBCMD_OCB_STOP_TIMING_ADVERT = 95,
786 QCA_NL80211_VENDOR_SUBCMD_OCB_GET_TSF_TIMER = 96,
787 QCA_NL80211_VENDOR_SUBCMD_DCC_GET_STATS = 97,
788 QCA_NL80211_VENDOR_SUBCMD_DCC_CLEAR_STATS = 98,
789 QCA_NL80211_VENDOR_SUBCMD_DCC_UPDATE_NDL = 99,
790 QCA_NL80211_VENDOR_SUBCMD_DCC_STATS_EVENT = 100,
791 QCA_NL80211_VENDOR_SUBCMD_LINK_PROPERTIES = 101,
792 QCA_NL80211_VENDOR_SUBCMD_GW_PARAM_CONFIG = 102,
793 QCA_NL80211_VENDOR_SUBCMD_GET_PREFERRED_FREQ_LIST = 103,
794 QCA_NL80211_VENDOR_SUBCMD_SET_PROBABLE_OPER_CHANNEL = 104,
795 QCA_NL80211_VENDOR_SUBCMD_SETBAND = 105,
796 QCA_NL80211_VENDOR_SUBCMD_TRIGGER_SCAN = 106,
797 QCA_NL80211_VENDOR_SUBCMD_SCAN_DONE = 107,
798 QCA_NL80211_VENDOR_SUBCMD_OTA_TEST = 108,
799 QCA_NL80211_VENDOR_SUBCMD_SET_TXPOWER_SCALE = 109,
800 /* 110..114 - reserved for QCA */
801 QCA_NL80211_VENDOR_SUBCMD_SET_TXPOWER_DECR_DB = 115,
Jouni Malinenf735abd2020-08-03 11:08:00 +0300802 QCA_NL80211_VENDOR_SUBCMD_ACS_POLICY = 116,
803 /* 117 - reserved for QCA */
Peng Xu291d97d2018-01-31 16:34:03 -0800804 QCA_NL80211_VENDOR_SUBCMD_SET_SAP_CONFIG = 118,
805 QCA_NL80211_VENDOR_SUBCMD_TSF = 119,
806 QCA_NL80211_VENDOR_SUBCMD_WISA = 120,
807 /* 121 - reserved for QCA */
808 QCA_NL80211_VENDOR_SUBCMD_P2P_LISTEN_OFFLOAD_START = 122,
809 QCA_NL80211_VENDOR_SUBCMD_P2P_LISTEN_OFFLOAD_STOP = 123,
810 QCA_NL80211_VENDOR_SUBCMD_SAP_CONDITIONAL_CHAN_SWITCH = 124,
811 QCA_NL80211_VENDOR_SUBCMD_GPIO_CONFIG_COMMAND = 125,
812 QCA_NL80211_VENDOR_SUBCMD_GET_HW_CAPABILITY = 126,
813 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_EXT = 127,
814 /* FTM/indoor location subcommands */
815 QCA_NL80211_VENDOR_SUBCMD_LOC_GET_CAPA = 128,
816 QCA_NL80211_VENDOR_SUBCMD_FTM_START_SESSION = 129,
817 QCA_NL80211_VENDOR_SUBCMD_FTM_ABORT_SESSION = 130,
818 QCA_NL80211_VENDOR_SUBCMD_FTM_MEAS_RESULT = 131,
819 QCA_NL80211_VENDOR_SUBCMD_FTM_SESSION_DONE = 132,
820 QCA_NL80211_VENDOR_SUBCMD_FTM_CFG_RESPONDER = 133,
821 QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS = 134,
822 QCA_NL80211_VENDOR_SUBCMD_AOA_ABORT_MEAS = 135,
823 QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS_RESULT = 136,
824 QCA_NL80211_VENDOR_SUBCMD_ENCRYPTION_TEST = 137,
825 QCA_NL80211_VENDOR_SUBCMD_GET_CHAIN_RSSI = 138,
826 /* DMG low level RF sector operations */
827 QCA_NL80211_VENDOR_SUBCMD_DMG_RF_GET_SECTOR_CFG = 139,
828 QCA_NL80211_VENDOR_SUBCMD_DMG_RF_SET_SECTOR_CFG = 140,
829 QCA_NL80211_VENDOR_SUBCMD_DMG_RF_GET_SELECTED_SECTOR = 141,
830 QCA_NL80211_VENDOR_SUBCMD_DMG_RF_SET_SELECTED_SECTOR = 142,
831 QCA_NL80211_VENDOR_SUBCMD_CONFIGURE_TDLS = 143,
832 QCA_NL80211_VENDOR_SUBCMD_GET_HE_CAPABILITIES = 144,
833 QCA_NL80211_VENDOR_SUBCMD_ABORT_SCAN = 145,
834 QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS = 146,
835 QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS = 147,
836 QCA_NL80211_VENDOR_SUBCMD_CHIP_PWRSAVE_FAILURE = 148,
837 QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_SET = 149,
838 QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_GET = 150,
839 QCA_NL80211_VENDOR_SUBCMD_FETCH_BSS_TRANSITION_STATUS = 151,
840 QCA_NL80211_VENDOR_SUBCMD_SET_TRACE_LEVEL = 152,
841 QCA_NL80211_VENDOR_SUBCMD_BRP_SET_ANT_LIMIT = 153,
842 QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_START = 154,
843 QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_STOP = 155,
844 QCA_NL80211_VENDOR_SUBCMD_ACTIVE_TOS = 156,
845 QCA_NL80211_VENDOR_SUBCMD_HANG = 157,
846 QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_CONFIG = 158,
847 QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_DIAG_STATS = 159,
848 QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_CAP_INFO = 160,
849 QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_STATUS = 161,
850 /* Flush peer pending data */
851 QCA_NL80211_VENDOR_SUBCMD_PEER_FLUSH_PENDING = 162,
852 QCA_NL80211_VENDOR_SUBCMD_GET_RROP_INFO = 163,
853 QCA_NL80211_VENDOR_SUBCMD_GET_SAR_LIMITS = 164,
854 QCA_NL80211_VENDOR_SUBCMD_WLAN_MAC_INFO = 165,
855 QCA_NL80211_VENDOR_SUBCMD_SET_QDEPTH_THRESH = 166,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -0800856 /* Thermal shutdown commands to protect wifi chip */
857 QCA_NL80211_VENDOR_SUBCMD_THERMAL_CMD = 167,
858 QCA_NL80211_VENDOR_SUBCMD_THERMAL_EVENT = 168,
859 /* Wi-Fi test configuration subcommand */
860 QCA_NL80211_VENDOR_SUBCMD_WIFI_TEST_CONFIGURATION = 169,
Arif Hussaine2645c62018-05-24 20:39:04 -0700861 /* Frame filter operations for other BSSs/unassociated STAs */
862 QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER = 170,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -0700863 QCA_NL80211_VENDOR_SUBCMD_NAN_EXT = 171,
864 QCA_NL80211_VENDOR_SUBCMD_ROAM_SCAN_EVENT = 172,
865 QCA_NL80211_VENDOR_SUBCMD_PEER_CFR_CAPTURE_CFG = 173,
866 QCA_NL80211_VENDOR_SUBCMD_THROUGHPUT_CHANGE_EVENT = 174,
867 QCA_NL80211_VENDOR_SUBCMD_COEX_CONFIG = 175,
Kiran Kumar Lokere2efd7682018-12-18 18:17:45 -0800868 QCA_NL80211_VENDOR_SUBCMD_GET_SUPPORTED_AKMS = 176,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -0800869 QCA_NL80211_VENDOR_SUBCMD_GET_FW_STATE = 177,
870 QCA_NL80211_VENDOR_SUBCMD_PEER_STATS_CACHE_FLUSH = 178,
871 QCA_NL80211_VENDOR_SUBCMD_MPTA_HELPER_CONFIG = 179,
Jouni Malinenf735abd2020-08-03 11:08:00 +0300872 QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING = 180,
873 QCA_NL80211_VENDOR_SUBCMD_INTEROP_ISSUES_AP = 181,
874 QCA_NL80211_VENDOR_SUBCMD_OEM_DATA = 182,
875 QCA_NL80211_VENDOR_SUBCMD_AVOID_FREQUENCY_EXT = 183,
876 QCA_NL80211_VENDOR_SUBCMD_ADD_STA_NODE = 184,
877 QCA_NL80211_VENDOR_SUBCMD_BTC_CHAIN_MODE = 185,
878 QCA_NL80211_VENDOR_SUBCMD_GET_STA_INFO = 186,
879 QCA_NL80211_VENDOR_SUBCMD_GET_SAR_LIMITS_EVENT = 187,
880 QCA_NL80211_VENDOR_SUBCMD_UPDATE_STA_INFO = 188,
881 QCA_NL80211_VENDOR_SUBCMD_DRIVER_DISCONNECT_REASON = 189,
882 QCA_NL80211_VENDOR_SUBCMD_CONFIG_TSPEC = 190,
883 QCA_NL80211_VENDOR_SUBCMD_CONFIG_TWT = 191,
884 QCA_NL80211_VENDOR_SUBCMD_GETBAND = 192,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +0530885 QCA_NL80211_VENDOR_SUBCMD_MEDIUM_ASSESS = 193,
886 QCA_NL80211_VENDOR_SUBCMD_UPDATE_SSID = 194,
887 QCA_NL80211_VENDOR_SUBCMD_WIFI_FW_STATS = 195,
888 QCA_NL80211_VENDOR_SUBCMD_MBSSID_TX_VDEV_STATUS = 196,
Peng Xu291d97d2018-01-31 16:34:03 -0800889};
890
Peng Xu291d97d2018-01-31 16:34:03 -0800891enum qca_wlan_vendor_attr {
892 QCA_WLAN_VENDOR_ATTR_INVALID = 0,
893 /* used by QCA_NL80211_VENDOR_SUBCMD_DFS_CAPABILITY */
894 QCA_WLAN_VENDOR_ATTR_DFS = 1,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -0700895 /* Used only when driver sends vendor events to the userspace under the
896 * command QCA_NL80211_VENDOR_SUBCMD_NAN. Not used when userspace sends
897 * commands to the driver.
898 */
Peng Xu291d97d2018-01-31 16:34:03 -0800899 QCA_WLAN_VENDOR_ATTR_NAN = 2,
900 /* used by QCA_NL80211_VENDOR_SUBCMD_STATS_EXT */
901 QCA_WLAN_VENDOR_ATTR_STATS_EXT = 3,
902 /* used by QCA_NL80211_VENDOR_SUBCMD_STATS_EXT */
903 QCA_WLAN_VENDOR_ATTR_IFINDEX = 4,
904 /* used by QCA_NL80211_VENDOR_SUBCMD_ROAMING, u32 with values defined
Arif Hussaine2645c62018-05-24 20:39:04 -0700905 * by enum qca_roaming_policy.
906 */
Peng Xu291d97d2018-01-31 16:34:03 -0800907 QCA_WLAN_VENDOR_ATTR_ROAMING_POLICY = 5,
908 QCA_WLAN_VENDOR_ATTR_MAC_ADDR = 6,
909 /* used by QCA_NL80211_VENDOR_SUBCMD_GET_FEATURES */
910 QCA_WLAN_VENDOR_ATTR_FEATURE_FLAGS = 7,
911 QCA_WLAN_VENDOR_ATTR_TEST = 8,
912 /* used by QCA_NL80211_VENDOR_SUBCMD_GET_FEATURES */
913 /* Unsigned 32-bit value. */
914 QCA_WLAN_VENDOR_ATTR_CONCURRENCY_CAPA = 9,
915 /* Unsigned 32-bit value */
916 QCA_WLAN_VENDOR_ATTR_MAX_CONCURRENT_CHANNELS_2_4_BAND = 10,
917 /* Unsigned 32-bit value */
918 QCA_WLAN_VENDOR_ATTR_MAX_CONCURRENT_CHANNELS_5_0_BAND = 11,
Jouni Malinenf735abd2020-08-03 11:08:00 +0300919 /* Unsigned 32-bit value from enum qca_set_band. The allowed values for
920 * this attribute are limited to QCA_SETBAND_AUTO, QCA_SETBAND_5G, and
921 * QCA_SETBAND_2G. This attribute is deprecated. Recommendation is to
922 * use QCA_WLAN_VENDOR_ATTR_SETBAND_MASK instead.
923 */
Peng Xu291d97d2018-01-31 16:34:03 -0800924 QCA_WLAN_VENDOR_ATTR_SETBAND_VALUE = 12,
925 /* Dummy (NOP) attribute for 64 bit padding */
926 QCA_WLAN_VENDOR_ATTR_PAD = 13,
927 /* Unique FTM session cookie (Unsigned 64 bit). Specified in
928 * QCA_NL80211_VENDOR_SUBCMD_FTM_START_SESSION. Reported in
929 * the session in QCA_NL80211_VENDOR_SUBCMD_FTM_MEAS_RESULT and
930 * QCA_NL80211_VENDOR_SUBCMD_FTM_SESSION_DONE.
931 */
932 QCA_WLAN_VENDOR_ATTR_FTM_SESSION_COOKIE = 14,
933 /* Indoor location capabilities, returned by
934 * QCA_NL80211_VENDOR_SUBCMD_LOC_GET_CAPA.
935 * see enum qca_wlan_vendor_attr_loc_capa.
936 */
937 QCA_WLAN_VENDOR_ATTR_LOC_CAPA = 15,
938 /* Array of nested attributes containing information about each peer
939 * in FTM measurement session. See enum qca_wlan_vendor_attr_peer_info
940 * for supported attributes for each peer.
941 */
942 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_PEERS = 16,
943 /* Array of nested attributes containing measurement results for
944 * one or more peers, reported by the
945 * QCA_NL80211_VENDOR_SUBCMD_FTM_MEAS_RESULT event.
946 * See enum qca_wlan_vendor_attr_peer_result for list of supported
947 * attributes.
948 */
949 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_PEER_RESULTS = 17,
950 /* Flag attribute for enabling or disabling responder functionality. */
951 QCA_WLAN_VENDOR_ATTR_FTM_RESPONDER_ENABLE = 18,
952 /* Used in the QCA_NL80211_VENDOR_SUBCMD_FTM_CFG_RESPONDER
953 * command to specify the LCI report that will be sent by
954 * the responder during a measurement exchange. The format is
955 * defined in IEEE P802.11-REVmc/D7.0, 9.4.2.22.10.
956 */
957 QCA_WLAN_VENDOR_ATTR_FTM_LCI = 19,
958 /* Used in the QCA_NL80211_VENDOR_SUBCMD_FTM_CFG_RESPONDER
959 * command to specify the location civic report that will
960 * be sent by the responder during a measurement exchange.
961 * The format is defined in IEEE P802.11-REVmc/D7.0, 9.4.2.22.13.
962 */
963 QCA_WLAN_VENDOR_ATTR_FTM_LCR = 20,
964 /* Session/measurement completion status code,
965 * reported in QCA_NL80211_VENDOR_SUBCMD_FTM_SESSION_DONE and
966 * QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS_RESULT
967 * see enum qca_vendor_attr_loc_session_status.
968 */
969 QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS = 21,
970 /* Initial dialog token used by responder (0 if not specified),
971 * unsigned 8 bit value.
972 */
973 QCA_WLAN_VENDOR_ATTR_FTM_INITIAL_TOKEN = 22,
974 /* AOA measurement type. Requested in QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS
975 * and optionally in QCA_NL80211_VENDOR_SUBCMD_FTM_START_SESSION if
976 * AOA measurements are needed as part of an FTM session.
977 * Reported by QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS_RESULT. See
978 * enum qca_wlan_vendor_attr_aoa_type.
979 */
980 QCA_WLAN_VENDOR_ATTR_AOA_TYPE = 23,
981 /* A bit mask (unsigned 32 bit value) of antenna arrays used
982 * by indoor location measurements. Refers to the antenna
983 * arrays described by QCA_VENDOR_ATTR_LOC_CAPA_ANTENNA_ARRAYS.
984 */
985 QCA_WLAN_VENDOR_ATTR_LOC_ANTENNA_ARRAY_MASK = 24,
986 /* AOA measurement data. Its contents depends on the AOA measurement
987 * type and antenna array mask:
988 * QCA_WLAN_VENDOR_ATTR_AOA_TYPE_TOP_CIR_PHASE: array of U16 values,
989 * phase of the strongest CIR path for each antenna in the measured
990 * array(s).
991 * QCA_WLAN_VENDOR_ATTR_AOA_TYPE_TOP_CIR_PHASE_AMP: array of 2 U16
992 * values, phase and amplitude of the strongest CIR path for each
993 * antenna in the measured array(s).
994 */
995 QCA_WLAN_VENDOR_ATTR_AOA_MEAS_RESULT = 25,
996 /* Used in QCA_NL80211_VENDOR_SUBCMD_GET_CHAIN_RSSI command
997 * to specify the chain number (unsigned 32 bit value) to inquire
Arif Hussaine2645c62018-05-24 20:39:04 -0700998 * the corresponding antenna RSSI value
999 */
Peng Xu291d97d2018-01-31 16:34:03 -08001000 QCA_WLAN_VENDOR_ATTR_CHAIN_INDEX = 26,
1001 /* Used in QCA_NL80211_VENDOR_SUBCMD_GET_CHAIN_RSSI command
Arif Hussaine2645c62018-05-24 20:39:04 -07001002 * to report the specific antenna RSSI value (unsigned 32 bit value)
1003 */
Peng Xu291d97d2018-01-31 16:34:03 -08001004 QCA_WLAN_VENDOR_ATTR_CHAIN_RSSI = 27,
1005 /* Frequency in MHz, various uses. Unsigned 32 bit value */
1006 QCA_WLAN_VENDOR_ATTR_FREQ = 28,
1007 /* TSF timer value, unsigned 64 bit value.
1008 * May be returned by various commands.
1009 */
1010 QCA_WLAN_VENDOR_ATTR_TSF = 29,
1011 /* DMG RF sector index, unsigned 16 bit number. Valid values are
1012 * 0..127 for sector indices or 65535 as special value used to
1013 * unlock sector selection in
1014 * QCA_NL80211_VENDOR_SUBCMD_DMG_RF_SET_SELECTED_SECTOR.
1015 */
1016 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_INDEX = 30,
1017 /* DMG RF sector type, unsigned 8 bit value. One of the values
1018 * in enum qca_wlan_vendor_attr_dmg_rf_sector_type.
1019 */
1020 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE = 31,
1021 /* Bitmask of DMG RF modules for which information is requested. Each
1022 * bit corresponds to an RF module with the same index as the bit
1023 * number. Unsigned 32 bit number but only low 8 bits can be set since
1024 * all DMG chips currently have up to 8 RF modules.
1025 */
1026 QCA_WLAN_VENDOR_ATTR_DMG_RF_MODULE_MASK = 32,
1027 /* Array of nested attributes where each entry is DMG RF sector
1028 * configuration for a single RF module.
1029 * Attributes for each entry are taken from enum
1030 * qca_wlan_vendor_attr_dmg_rf_sector_cfg.
1031 * Specified in QCA_NL80211_VENDOR_SUBCMD_DMG_RF_SET_SECTOR_CFG
1032 * and returned by QCA_NL80211_VENDOR_SUBCMD_DMG_RF_GET_SECTOR_CFG.
1033 */
1034 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG = 33,
1035 /* Used in QCA_NL80211_VENDOR_SUBCMD_STATS_EXT command
1036 * to report frame aggregation statistics to userspace.
1037 */
1038 QCA_WLAN_VENDOR_ATTR_RX_AGGREGATION_STATS_HOLES_NUM = 34,
1039 QCA_WLAN_VENDOR_ATTR_RX_AGGREGATION_STATS_HOLES_INFO = 35,
1040 /* Unsigned 8-bit value representing MBO transition reason code as
1041 * provided by the AP used by subcommand
1042 * QCA_NL80211_VENDOR_SUBCMD_FETCH_BSS_TRANSITION_STATUS. This is
1043 * specified by the userspace in the request to the driver.
1044 */
1045 QCA_WLAN_VENDOR_ATTR_BTM_MBO_TRANSITION_REASON = 36,
1046 /* Array of nested attributes, BSSID and status code, used by subcommand
1047 * QCA_NL80211_VENDOR_SUBCMD_FETCH_BSS_TRANSITION_STATUS, where each
1048 * entry is taken from enum qca_wlan_vendor_attr_btm_candidate_info.
1049 * The userspace space specifies the list/array of candidate BSSIDs in
1050 * the order of preference in the request. The driver specifies the
1051 * status code, for each BSSID in the list, in the response. The
1052 * acceptable candidates are listed in the order preferred by the
1053 * driver.
1054 */
1055 QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO = 37,
1056 /* Used in QCA_NL80211_VENDOR_SUBCMD_BRP_SET_ANT_LIMIT command
1057 * See enum qca_wlan_vendor_attr_brp_ant_limit_mode.
1058 */
1059 QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE = 38,
1060 /* Used in QCA_NL80211_VENDOR_SUBCMD_BRP_SET_ANT_LIMIT command
1061 * to define the number of antennas to use for BRP.
1062 * different purpose in each ANT_LIMIT_MODE:
1063 * DISABLE - ignored
1064 * EFFECTIVE - upper limit to number of antennas to be used
1065 * FORCE - exact number of antennas to be used
1066 * unsigned 8 bit value
1067 */
1068 QCA_WLAN_VENDOR_ATTR_BRP_ANT_NUM_LIMIT = 39,
1069 /* Used in QCA_NL80211_VENDOR_SUBCMD_GET_CHAIN_RSSI command
Arif Hussaine2645c62018-05-24 20:39:04 -07001070 * to report the corresponding antenna index to the chain RSSI value
1071 */
Peng Xu291d97d2018-01-31 16:34:03 -08001072 QCA_WLAN_VENDOR_ATTR_ANTENNA_INFO = 40,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08001073 /* Used in QCA_NL80211_VENDOR_SUBCMD_GET_CHAIN_RSSI command to report
1074 * the specific antenna EVM value (unsigned 32 bit value). With a
1075 * determinate group of antennas, the driver specifies the EVM value
1076 * for each antenna ID, and application extract them in user space.
1077 */
1078 QCA_WLAN_VENDOR_ATTR_CHAIN_EVM = 41,
1079 /*
1080 * Used in QCA_NL80211_VENDOR_SUBCMD_GET_FW_STATE command to report
1081 * wlan firmware current state. FW state is an unsigned 8 bit value,
1082 * one of the values in enum qca_wlan_vendor_attr_fw_state.
1083 */
1084 QCA_WLAN_VENDOR_ATTR_FW_STATE = 42,
Peng Xu291d97d2018-01-31 16:34:03 -08001085
Jouni Malinenf735abd2020-08-03 11:08:00 +03001086 /* Unsigned 32-bitmask value from enum qca_set_band. Substitutes the
1087 * attribute QCA_WLAN_VENDOR_ATTR_SETBAND_VALUE for which only a subset
1088 * of single values from enum qca_set_band are valid. This attribute
1089 * uses bitmask combinations to define the respective allowed band
1090 * combinations and this attributes takes precedence over
1091 * QCA_WLAN_VENDOR_ATTR_SETBAND_VALUE if both attributes are included.
1092 */
1093 QCA_WLAN_VENDOR_ATTR_SETBAND_MASK = 43,
1094
Peng Xu291d97d2018-01-31 16:34:03 -08001095 /* keep last */
1096 QCA_WLAN_VENDOR_ATTR_AFTER_LAST,
1097 QCA_WLAN_VENDOR_ATTR_MAX = QCA_WLAN_VENDOR_ATTR_AFTER_LAST - 1,
1098};
1099
Peng Xu291d97d2018-01-31 16:34:03 -08001100enum qca_roaming_policy {
1101 QCA_ROAMING_NOT_ALLOWED,
1102 QCA_ROAMING_ALLOWED_WITHIN_ESS,
1103};
1104
Jouni Malinenf735abd2020-08-03 11:08:00 +03001105/**
1106 * enum qca_roam_reason - Represents the reason codes for roaming. Used by
1107 * QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_REASON.
1108 *
1109 * @QCA_ROAM_REASON_UNKNOWN: Any reason that do not classify under the below
1110 * reasons.
1111 *
1112 * @QCA_ROAM_REASON_PER: Roam triggered when packet error rates (PER) breached
1113 * the configured threshold.
1114 *
1115 * @QCA_ROAM_REASON_BEACON_MISS: Roam triggered due to the continuous configured
1116 * beacon misses from the then connected AP.
1117 *
1118 * @QCA_ROAM_REASON_POOR_RSSI: Roam triggered due to the poor RSSI reported
1119 * by the connected AP.
1120 *
1121 * @QCA_ROAM_REASON_BETTER_RSSI: Roam triggered for finding a BSS with a better
1122 * RSSI than the connected BSS. Here the RSSI of the current BSS is not poor.
1123 *
1124 * @QCA_ROAM_REASON_CONGESTION: Roam triggered considering the connected channel
1125 * or environment being very noisy or congested.
1126 *
1127 * @QCA_ROAM_REASON_EXPLICIT_REQUEST: Roam triggered due to an explicit request
1128 * from the user (user space).
1129 *
1130 * @QCA_ROAM_REASON_BTM: Roam triggered due to BTM Request frame received from
1131 * the connected AP.
1132 *
1133 * @QCA_ROAM_REASON_BSS_LOAD: Roam triggered due to the channel utilization
1134 * breaching out the configured threshold.
1135 */
1136enum qca_roam_reason {
1137 QCA_ROAM_REASON_UNKNOWN,
1138 QCA_ROAM_REASON_PER,
1139 QCA_ROAM_REASON_BEACON_MISS,
1140 QCA_ROAM_REASON_POOR_RSSI,
1141 QCA_ROAM_REASON_BETTER_RSSI,
1142 QCA_ROAM_REASON_CONGESTION,
1143 QCA_ROAM_REASON_USER_TRIGGER,
1144 QCA_ROAM_REASON_BTM,
1145 QCA_ROAM_REASON_BSS_LOAD,
1146};
1147
Peng Xu291d97d2018-01-31 16:34:03 -08001148enum qca_wlan_vendor_attr_roam_auth {
1149 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_INVALID = 0,
1150 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_BSSID,
1151 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_REQ_IE,
1152 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_RESP_IE,
1153 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_AUTHORIZED,
1154 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_KEY_REPLAY_CTR,
1155 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_PTK_KCK,
1156 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_PTK_KEK,
1157 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_SUBNET_STATUS,
1158 /* Indicates the status of re-association requested by user space for
1159 * the BSSID specified by QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_BSSID.
1160 * Type u16.
1161 * Represents the status code from AP. Use
1162 * %WLAN_STATUS_UNSPECIFIED_FAILURE if the device cannot give you the
1163 * real status code for failures.
1164 */
1165 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_STATUS,
1166 /* This attribute indicates that the old association was maintained when
1167 * a re-association is requested by user space and that re-association
1168 * attempt fails (i.e., cannot connect to the requested BSS, but can
1169 * remain associated with the BSS with which the association was in
1170 * place when being requested to roam). Used along with
1171 * WLAN_VENDOR_ATTR_ROAM_AUTH_STATUS to indicate the current
1172 * re-association status. Type flag.
1173 * This attribute is applicable only for re-association failure cases.
1174 */
1175 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_RETAIN_CONNECTION,
1176 /* This attribute specifies the PMK if one was newly generated during
1177 * FILS roaming. This is added to the PMKSA cache and is used in
1178 * subsequent connections with PMKSA caching.
1179 */
1180 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_PMK = 11,
1181 /* This attribute specifies the PMKID used/generated for the current
1182 * FILS roam. This is used in subsequent connections with PMKSA caching.
1183 */
1184 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_PMKID = 12,
1185 /* A 16-bit unsigned value specifying the next sequence number to use
1186 * in ERP message in the currently associated realm. This is used in
1187 * doing subsequent ERP based connections in the same realm.
1188 */
1189 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_FILS_ERP_NEXT_SEQ_NUM = 13,
Jouni Malinenf735abd2020-08-03 11:08:00 +03001190 /* A 16-bit unsigned value representing the reasons for the roaming.
1191 * Defined by enum qca_roam_reason.
1192 */
1193 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_REASON = 14,
1194
Peng Xu291d97d2018-01-31 16:34:03 -08001195 /* keep last */
1196 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_AFTER_LAST,
1197 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_MAX =
1198 QCA_WLAN_VENDOR_ATTR_ROAM_AUTH_AFTER_LAST - 1
1199};
1200
1201enum qca_wlan_vendor_attr_p2p_listen_offload {
1202 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_INVALID = 0,
1203 /* A 32-bit unsigned value; the P2P listen frequency (MHz); must be one
1204 * of the social channels.
1205 */
1206 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_CHANNEL,
1207 /* A 32-bit unsigned value; the P2P listen offload period (ms).
1208 */
1209 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_PERIOD,
1210 /* A 32-bit unsigned value; the P2P listen interval duration (ms).
1211 */
1212 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_INTERVAL,
1213 /* A 32-bit unsigned value; number of interval times the firmware needs
1214 * to run the offloaded P2P listen operation before it stops.
1215 */
1216 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_COUNT,
1217 /* An array of arbitrary binary data with one or more 8-byte values.
1218 * The device types include both primary and secondary device types.
1219 */
1220 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_DEVICE_TYPES,
1221 /* An array of unsigned 8-bit characters; vendor information elements.
1222 */
1223 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_VENDOR_IE,
1224 /* A 32-bit unsigned value; a control flag to indicate whether listen
1225 * results need to be flushed to wpa_supplicant.
1226 */
1227 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_CTRL_FLAG,
1228 /* A 8-bit unsigned value; reason code for P2P listen offload stop
1229 * event.
1230 */
1231 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_STOP_REASON,
1232 /* keep last */
1233 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_AFTER_LAST,
1234 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_MAX =
1235 QCA_WLAN_VENDOR_ATTR_P2P_LISTEN_OFFLOAD_AFTER_LAST - 1
1236};
1237
Jouni Malinenf735abd2020-08-03 11:08:00 +03001238/**
1239 * enum qca_wlan_vendor_attr_acs_offload - Defines attributes to be used with
1240 * vendor command/event QCA_NL80211_VENDOR_SUBCMD_DO_ACS.
1241 *
1242 * @QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_CHANNEL: Required (u8).
1243 * Used with event to notify the primary channel number selected in ACS
1244 * operation.
1245 * Note: If both the driver and user-space application supports the 6 GHz band,
1246 * QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_CHANNEL is deprecated; use
1247 * QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_FREQUENCY instead.
1248 * To maintain backward compatibility, QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_CHANNEL
1249 * is still used if either of the driver or user space application doesn't
1250 * support the 6 GHz band.
1251 *
1252 * @QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_CHANNEL: Required (u8).
1253 * Used with event to notify the secondary channel number selected in ACS
1254 * operation.
1255 * Note: If both the driver and user-space application supports the 6 GHz band,
1256 * QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_CHANNEL is deprecated; use
1257 * QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_FREQUENCY instead.
1258 * To maintain backward compatibility,
1259 * QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_CHANNEL is still used if either of
1260 * the driver or user space application doesn't support 6 GHz band.
1261 *
1262 * @QCA_WLAN_VENDOR_ATTR_ACS_HW_MODE: Required (u8).
1263 * (a) Used with command to configure hw_mode from
1264 * enum qca_wlan_vendor_acs_hw_mode for ACS operation.
1265 * (b) Also used with event to notify the hw_mode of selected primary channel
1266 * in ACS operation.
1267 *
1268 * @QCA_WLAN_VENDOR_ATTR_ACS_HT_ENABLED: Flag attribute.
1269 * Used with command to configure ACS operation for HT mode.
1270 * Disable (flag attribute not present) - HT disabled and
1271 * Enable (flag attribute present) - HT enabled.
1272 *
1273 * @QCA_WLAN_VENDOR_ATTR_ACS_HT40_ENABLED: Flag attribute.
1274 * Used with command to configure ACS operation for HT40 mode.
1275 * Disable (flag attribute not present) - HT40 disabled and
1276 * Enable (flag attribute present) - HT40 enabled.
1277 *
1278 * @QCA_WLAN_VENDOR_ATTR_ACS_VHT_ENABLED: Flag attribute.
1279 * Used with command to configure ACS operation for VHT mode.
1280 * Disable (flag attribute not present) - VHT disabled and
1281 * Enable (flag attribute present) - VHT enabled.
1282 *
1283 * @QCA_WLAN_VENDOR_ATTR_ACS_CHWIDTH: Optional (u16) with command and
1284 * mandatory with event.
1285 * If specified in command path, ACS operation is configured with the given
1286 * channel width (in MHz).
1287 * In event path, specifies the channel width of the primary channel selected.
1288 *
1289 * @QCA_WLAN_VENDOR_ATTR_ACS_CH_LIST: Required and type is NLA_UNSPEC.
1290 * Used with command to configure channel list using an array of
1291 * channel numbers (u8).
1292 * Note: If both the driver and user-space application supports the 6 GHz band,
1293 * the driver mandates use of QCA_WLAN_VENDOR_ATTR_ACS_FREQ_LIST whereas
1294 * QCA_WLAN_VENDOR_ATTR_ACS_CH_LIST is optional.
1295 *
1296 * @QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_CHANNEL: Required (u8).
1297 * Used with event to notify the VHT segment 0 center channel number selected in
1298 * ACS operation. The value is the index of the channel center frequency for
1299 * 20 MHz, 40 MHz, and 80 MHz channels. The value is the center frequency index
1300 * of the primary 80 MHz segment for 160 MHz and 80+80 MHz channels.
1301 * Note: If both the driver and user-space application supports the 6 GHz band,
1302 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_CHANNEL is deprecated; use
1303 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_FREQUENCY instead.
1304 * To maintain backward compatibility,
1305 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_CHANNEL is still used if either of
1306 * the driver or user space application doesn't support the 6 GHz band.
1307 *
1308 * @QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_CHANNEL: Required (u8).
1309 * Used with event to notify the VHT segment 1 center channel number selected in
1310 * ACS operation. The value is zero for 20 MHz, 40 MHz, and 80 MHz channels.
1311 * The value is the index of the channel center frequency for 160 MHz channels
1312 * and the center frequency index of the secondary 80 MHz segment for 80+80 MHz
1313 * channels.
1314 * Note: If both the driver and user-space application supports the 6 GHz band,
1315 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_CHANNEL is deprecated; use
1316 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_FREQUENCY instead.
1317 * To maintain backward compatibility,
1318 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_CHANNEL is still used if either of
1319 * the driver or user space application doesn't support the 6 GHz band.
1320 *
1321 * @QCA_WLAN_VENDOR_ATTR_ACS_FREQ_LIST: Required and type is NLA_UNSPEC.
1322 * Used with command to configure the channel list using an array of channel
1323 * center frequencies in MHz (u32).
1324 * Note: If both the driver and user-space application supports the 6 GHz band,
1325 * the driver first parses the frequency list and if it fails to get a frequency
1326 * list, parses the channel list specified using
1327 * QCA_WLAN_VENDOR_ATTR_ACS_CH_LIST (considers only 2 GHz and 5 GHz channels in
1328 * QCA_WLAN_VENDOR_ATTR_ACS_CH_LIST).
1329 *
1330 * @QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_FREQUENCY: Required (u32).
1331 * Used with event to notify the primary channel center frequency (MHz) selected
1332 * in ACS operation.
1333 * Note: If the driver supports the 6 GHz band, the event sent from the driver
1334 * includes this attribute along with QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_CHANNEL.
1335 *
1336 * @QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_FREQUENCY: Required (u32).
1337 * Used with event to notify the secondary channel center frequency (MHz)
1338 * selected in ACS operation.
1339 * Note: If the driver supports the 6 GHz band, the event sent from the driver
1340 * includes this attribute along with
1341 * QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_CHANNEL.
1342 *
1343 * @QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_FREQUENCY: Required (u32).
1344 * Used with event to notify the VHT segment 0 center channel frequency (MHz)
1345 * selected in ACS operation.
1346 * Note: If the driver supports the 6 GHz band, the event sent from the driver
1347 * includes this attribute along with
1348 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_CHANNEL.
1349 *
1350 * @QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_FREQUENCY: Required (u32).
1351 * Used with event to notify the VHT segment 1 center channel frequency (MHz)
1352 * selected in ACS operation.
1353 * Note: If the driver supports the 6 GHz band, the event sent from the driver
1354 * includes this attribute along with
1355 * QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_CHANNEL.
1356 *
1357 * @QCA_WLAN_VENDOR_ATTR_ACS_EDMG_ENABLED: Flag attribute.
1358 * Used with command to notify the driver of EDMG request for ACS
1359 * operation.
1360 *
1361 * @QCA_WLAN_VENDOR_ATTR_ACS_EDMG_CHANNEL: Optional (u8).
1362 * Used with event to notify the EDMG channel number selected in ACS
1363 * operation.
1364 * EDMG primary channel is indicated by QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_CHANNEL
1365 */
Peng Xu291d97d2018-01-31 16:34:03 -08001366enum qca_wlan_vendor_attr_acs_offload {
1367 QCA_WLAN_VENDOR_ATTR_ACS_CHANNEL_INVALID = 0,
Jouni Malinenf735abd2020-08-03 11:08:00 +03001368 QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_CHANNEL = 1,
1369 QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_CHANNEL = 2,
1370 QCA_WLAN_VENDOR_ATTR_ACS_HW_MODE = 3,
1371 QCA_WLAN_VENDOR_ATTR_ACS_HT_ENABLED = 4,
1372 QCA_WLAN_VENDOR_ATTR_ACS_HT40_ENABLED = 5,
1373 QCA_WLAN_VENDOR_ATTR_ACS_VHT_ENABLED = 6,
1374 QCA_WLAN_VENDOR_ATTR_ACS_CHWIDTH = 7,
1375 QCA_WLAN_VENDOR_ATTR_ACS_CH_LIST = 8,
1376 QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_CHANNEL = 9,
1377 QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_CHANNEL = 10,
1378 QCA_WLAN_VENDOR_ATTR_ACS_FREQ_LIST = 11,
1379 QCA_WLAN_VENDOR_ATTR_ACS_PRIMARY_FREQUENCY = 12,
1380 QCA_WLAN_VENDOR_ATTR_ACS_SECONDARY_FREQUENCY = 13,
1381 QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG0_CENTER_FREQUENCY = 14,
1382 QCA_WLAN_VENDOR_ATTR_ACS_VHT_SEG1_CENTER_FREQUENCY = 15,
1383 QCA_WLAN_VENDOR_ATTR_ACS_EDMG_ENABLED = 16,
1384 QCA_WLAN_VENDOR_ATTR_ACS_EDMG_CHANNEL = 17,
1385
Peng Xu291d97d2018-01-31 16:34:03 -08001386 /* keep last */
1387 QCA_WLAN_VENDOR_ATTR_ACS_AFTER_LAST,
1388 QCA_WLAN_VENDOR_ATTR_ACS_MAX =
1389 QCA_WLAN_VENDOR_ATTR_ACS_AFTER_LAST - 1
1390};
1391
Jouni Malinenf735abd2020-08-03 11:08:00 +03001392/**
1393 * enum qca_wlan_vendor_acs_hw_mode - Defines HW mode to be used with the
1394 * vendor command/event QCA_NL80211_VENDOR_SUBCMD_DO_ACS.
1395 *
1396 * @QCA_ACS_MODE_IEEE80211B: 802.11b mode
1397 * @QCA_ACS_MODE_IEEE80211G: 802.11g mode
1398 * @QCA_ACS_MODE_IEEE80211A: 802.11a mode
1399 * @QCA_ACS_MODE_IEEE80211AD: 802.11ad mode
1400 * @QCA_ACS_MODE_IEEE80211ANY: all modes
1401 * @QCA_ACS_MODE_IEEE80211AX: 802.11ax mode
1402 */
Peng Xu291d97d2018-01-31 16:34:03 -08001403enum qca_wlan_vendor_acs_hw_mode {
1404 QCA_ACS_MODE_IEEE80211B,
1405 QCA_ACS_MODE_IEEE80211G,
1406 QCA_ACS_MODE_IEEE80211A,
1407 QCA_ACS_MODE_IEEE80211AD,
1408 QCA_ACS_MODE_IEEE80211ANY,
Jouni Malinenf735abd2020-08-03 11:08:00 +03001409 QCA_ACS_MODE_IEEE80211AX,
Peng Xu291d97d2018-01-31 16:34:03 -08001410};
1411
1412/**
1413 * enum qca_wlan_vendor_features - Vendor device/driver feature flags
1414 *
1415 * @QCA_WLAN_VENDOR_FEATURE_KEY_MGMT_OFFLOAD: Device supports key
1416 * management offload, a mechanism where the station's firmware
1417 * does the exchange with the AP to establish the temporal keys
1418 * after roaming, rather than having the user space wpa_supplicant do it.
1419 * @QCA_WLAN_VENDOR_FEATURE_SUPPORT_HW_MODE_ANY: Device supports automatic
1420 * band selection based on channel selection results.
1421 * @QCA_WLAN_VENDOR_FEATURE_OFFCHANNEL_SIMULTANEOUS: Device supports
Arif Hussaine2645c62018-05-24 20:39:04 -07001422 * simultaneous off-channel operations.
Peng Xu291d97d2018-01-31 16:34:03 -08001423 * @QCA_WLAN_VENDOR_FEATURE_P2P_LISTEN_OFFLOAD: Device supports P2P
1424 * Listen offload; a mechanism where the station's firmware takes care of
1425 * responding to incoming Probe Request frames received from other P2P
1426 * Devices whilst in Listen state, rather than having the user space
1427 * wpa_supplicant do it. Information from received P2P requests are
1428 * forwarded from firmware to host whenever the host processor wakes up.
1429 * @QCA_WLAN_VENDOR_FEATURE_OCE_STA: Device supports all OCE non-AP STA
1430 * specific features.
1431 * @QCA_WLAN_VENDOR_FEATURE_OCE_AP: Device supports all OCE AP specific
1432 * features.
1433 * @QCA_WLAN_VENDOR_FEATURE_OCE_STA_CFON: Device supports OCE STA-CFON
1434 * specific features only. If a Device sets this bit but not the
1435 * %QCA_WLAN_VENDOR_FEATURE_OCE_AP, the userspace shall assume that
1436 * this Device may not support all OCE AP functionalities but can support
1437 * only OCE STA-CFON functionalities.
Arif Hussaine2645c62018-05-24 20:39:04 -07001438 * @QCA_WLAN_VENDOR_FEATURE_SELF_MANAGED_REGULATORY: Device supports self
1439 * managed regulatory.
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08001440 * @QCA_WLAN_VENDOR_FEATURE_TWT: Device supports TWT (Target Wake Time).
Jouni Malinenf735abd2020-08-03 11:08:00 +03001441 * @QCA_WLAN_VENDOR_FEATURE_11AX: Device supports 802.11ax (HE)
1442 * @QCA_WLAN_VENDOR_FEATURE_6GHZ_SUPPORT: Device supports 6 GHz band operation
1443 * @QCA_WLAN_VENDOR_FEATURE_THERMAL_CONFIG: Device is capable of receiving
1444 * and applying thermal configuration through
1445 * %QCA_WLAN_VENDOR_ATTR_THERMAL_LEVEL and
1446 * %QCA_WLAN_VENDOR_ATTR_THERMAL_COMPLETION_WINDOW attributes from
1447 * userspace.
Srinivas Girigowda7673be32020-11-12 12:37:14 -08001448 * @QCA_WLAN_VENDOR_FEATURE_ADAPTIVE_11R: Device supports Adaptive 11r.
1449 * With Adaptive 11r feature, access points advertise the vendor
1450 * specific IEs and MDE but do not include FT AKM in the RSNE.
1451 * The Adaptive 11r supported stations are expected to identify
1452 * such vendor specific IEs and connect to the AP in FT mode though
1453 * the profile is configured in non-FT mode.
1454 * The driver-based SME cases also need to have this support for
1455 * Adaptive 11r to handle the connection and roaming scenarios.
1456 * This flag indicates the support for the same to the user space.
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08001457 * @QCA_WLAN_VENDOR_FEATURE_CONCURRENT_BAND_SESSIONS: Device supports
1458 * concurrent network sessions on different Wi-Fi bands. This feature
1459 * capability is attributed to the hardware's capability to support
1460 * the same (e.g., DBS).
Peng Xu291d97d2018-01-31 16:34:03 -08001461 * @NUM_QCA_WLAN_VENDOR_FEATURES: Number of assigned feature bits
1462 */
1463enum qca_wlan_vendor_features {
1464 QCA_WLAN_VENDOR_FEATURE_KEY_MGMT_OFFLOAD = 0,
1465 QCA_WLAN_VENDOR_FEATURE_SUPPORT_HW_MODE_ANY = 1,
1466 QCA_WLAN_VENDOR_FEATURE_OFFCHANNEL_SIMULTANEOUS = 2,
1467 QCA_WLAN_VENDOR_FEATURE_P2P_LISTEN_OFFLOAD = 3,
1468 QCA_WLAN_VENDOR_FEATURE_OCE_STA = 4,
1469 QCA_WLAN_VENDOR_FEATURE_OCE_AP = 5,
1470 QCA_WLAN_VENDOR_FEATURE_OCE_STA_CFON = 6,
Arif Hussaine2645c62018-05-24 20:39:04 -07001471 QCA_WLAN_VENDOR_FEATURE_SELF_MANAGED_REGULATORY = 7,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08001472 QCA_WLAN_VENDOR_FEATURE_TWT = 8,
Jouni Malinenf735abd2020-08-03 11:08:00 +03001473 QCA_WLAN_VENDOR_FEATURE_11AX = 9,
1474 QCA_WLAN_VENDOR_FEATURE_6GHZ_SUPPORT = 10,
1475 QCA_WLAN_VENDOR_FEATURE_THERMAL_CONFIG = 11,
Srinivas Girigowda7673be32020-11-12 12:37:14 -08001476 QCA_WLAN_VENDOR_FEATURE_ADAPTIVE_11R = 12,
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08001477 QCA_WLAN_VENDOR_FEATURE_CONCURRENT_BAND_SESSIONS = 13,
Peng Xu291d97d2018-01-31 16:34:03 -08001478 NUM_QCA_WLAN_VENDOR_FEATURES /* keep last */
1479};
1480
1481/**
1482 * enum qca_wlan_vendor_attr_data_offload_ind - Vendor Data Offload Indication
1483 *
1484 * @QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_SESSION: Session corresponding to
1485 * the offloaded data.
1486 * @QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_PROTOCOL: Protocol of the offloaded
1487 * data.
1488 * @QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_EVENT: Event type for the data offload
1489 * indication.
1490 */
1491enum qca_wlan_vendor_attr_data_offload_ind {
1492 QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_INVALID = 0,
1493 QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_SESSION,
1494 QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_PROTOCOL,
1495 QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_EVENT,
1496
1497 /* keep last */
1498 QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_AFTER_LAST,
1499 QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_MAX =
1500 QCA_WLAN_VENDOR_ATTR_DATA_OFFLOAD_IND_AFTER_LAST - 1
1501};
1502
1503/**
1504 * enum qca_wlan_vendor_attr_ocb_set_config - Vendor subcmd attributes to set
1505 * OCB config
1506 *
1507 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_CHANNEL_COUNT: Number of channels in the
1508 * configuration
1509 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_SCHEDULE_SIZE: Size of the schedule
1510 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_CHANNEL_ARRAY: Array of channels
1511 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_SCHEDULE_ARRAY: Array of channels to be
1512 * scheduled
1513 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_NDL_CHANNEL_ARRAY: Array of NDL channel
1514 * information
1515 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_NDL_ACTIVE_STATE_ARRAY: Array of NDL
1516 * active state configuration
1517 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_FLAGS: Configuration flags such as
1518 * OCB_CONFIG_FLAG_80211_FRAME_MODE
1519 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_DEF_TX_PARAM: Default TX parameters to
1520 * use in the case that a packet is sent without a TX control header
1521 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_TA_MAX_DURATION: Max duration after the
1522 * last TA received that the local time set by TA is synchronous to other
1523 * communicating OCB STAs.
1524 */
1525enum qca_wlan_vendor_attr_ocb_set_config {
1526 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_INVALID = 0,
1527 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_CHANNEL_COUNT = 1,
1528 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_SCHEDULE_SIZE = 2,
1529 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_CHANNEL_ARRAY = 3,
1530 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_SCHEDULE_ARRAY = 4,
1531 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_NDL_CHANNEL_ARRAY = 5,
1532 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_NDL_ACTIVE_STATE_ARRAY = 6,
1533 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_FLAGS = 7,
1534 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_DEF_TX_PARAM = 8,
1535 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_TA_MAX_DURATION = 9,
1536 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_AFTER_LAST,
1537 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_MAX =
1538 QCA_WLAN_VENDOR_ATTR_OCB_SET_CONFIG_AFTER_LAST - 1
1539};
1540
1541/**
1542 * enum qca_wlan_vendor_attr_ocb_set_utc_time - Vendor subcmd attributes to set
1543 * UTC time
1544 *
1545 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_VALUE: The UTC time as an array of
1546 * 10 bytes
1547 * @QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_ERROR: The time error as an array of
1548 * 5 bytes
1549 */
1550enum qca_wlan_vendor_attr_ocb_set_utc_time {
1551 QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_INVALID = 0,
1552 QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_VALUE = 1,
1553 QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_ERROR = 2,
1554 QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_AFTER_LAST,
1555 QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_MAX =
1556 QCA_WLAN_VENDOR_ATTR_OCB_SET_UTC_TIME_AFTER_LAST - 1
1557};
1558
1559/**
1560 * enum qca_wlan_vendor_attr_ocb_start_timing_advert - Vendor subcmd attributes
1561 * to start sending timing advert frames
1562 *
1563 * @QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_CHANNEL_FREQ: Cannel frequency
1564 * on which to send the frames
1565 * @QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_REPEAT_RATE: Number of times
1566 * the frame is sent in 5 seconds
1567 */
1568enum qca_wlan_vendor_attr_ocb_start_timing_advert {
1569 QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_INVALID = 0,
1570 QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_CHANNEL_FREQ = 1,
1571 QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_REPEAT_RATE = 2,
1572 QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_AFTER_LAST,
1573 QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_MAX =
1574 QCA_WLAN_VENDOR_ATTR_OCB_START_TIMING_ADVERT_AFTER_LAST - 1
1575};
1576
1577/**
1578 * enum qca_wlan_vendor_attr_ocb_stop_timing_advert - Vendor subcmd attributes
1579 * to stop timing advert
1580 *
1581 * @QCA_WLAN_VENDOR_ATTR_OCB_STOP_TIMING_ADVERT_CHANNEL_FREQ: The channel
1582 * frequency on which to stop the timing advert
1583 */
1584enum qca_wlan_vendor_attr_ocb_stop_timing_advert {
1585 QCA_WLAN_VENDOR_ATTR_OCB_STOP_TIMING_ADVERT_INVALID = 0,
1586 QCA_WLAN_VENDOR_ATTR_OCB_STOP_TIMING_ADVERT_CHANNEL_FREQ = 1,
1587 QCA_WLAN_VENDOR_ATTR_OCB_STOP_TIMING_ADVERT_AFTER_LAST,
1588 QCA_WLAN_VENDOR_ATTR_OCB_STOP_TIMING_ADVERT_MAX =
1589 QCA_WLAN_VENDOR_ATTR_OCB_STOP_TIMING_ADVERT_AFTER_LAST - 1
1590};
1591
1592/**
1593 * enum qca_wlan_vendor_attr_ocb_get_tsf_response - Vendor subcmd attributes to
1594 * get TSF timer value
1595 *
1596 * @QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_TIMER_HIGH: Higher 32 bits of the
1597 * timer
1598 * @QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_TIMER_LOW: Lower 32 bits of the timer
1599 */
1600enum qca_wlan_vendor_attr_ocb_get_tsf_resp {
1601 QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_INVALID = 0,
1602 QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_TIMER_HIGH = 1,
1603 QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_TIMER_LOW = 2,
1604 QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_AFTER_LAST,
1605 QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_MAX =
1606 QCA_WLAN_VENDOR_ATTR_OCB_GET_TSF_RESP_AFTER_LAST - 1
1607};
1608
1609enum qca_vendor_attr_get_preferred_freq_list {
1610 QCA_WLAN_VENDOR_ATTR_GET_PREFERRED_FREQ_LIST_INVALID,
1611 /* A 32-unsigned value; the interface type/mode for which the preferred
1612 * frequency list is requested (see enum qca_iface_type for possible
1613 * values); used in GET_PREFERRED_FREQ_LIST command from user-space to
1614 * kernel and in the kernel response back to user-space.
1615 */
1616 QCA_WLAN_VENDOR_ATTR_GET_PREFERRED_FREQ_LIST_IFACE_TYPE,
1617 /* An array of 32-unsigned values; values are frequency (MHz); sent
1618 * from kernel space to user space.
1619 */
1620 QCA_WLAN_VENDOR_ATTR_GET_PREFERRED_FREQ_LIST,
1621 /* An array of nested values as per enum qca_wlan_vendor_attr_pcl
1622 * attribute. Each element contains frequency (MHz), weight, and flag
1623 * bit mask indicating how the frequency should be used in P2P
1624 * negotiation; sent from kernel space to user space.
1625 */
1626 QCA_WLAN_VENDOR_ATTR_GET_PREFERRED_FREQ_LIST_WEIGHED_PCL,
1627 /* keep last */
1628 QCA_WLAN_VENDOR_ATTR_GET_PREFERRED_FREQ_LIST_AFTER_LAST,
1629 QCA_WLAN_VENDOR_ATTR_GET_PREFERRED_FREQ_LIST_MAX =
1630 QCA_WLAN_VENDOR_ATTR_GET_PREFERRED_FREQ_LIST_AFTER_LAST - 1
1631};
1632
1633enum qca_vendor_attr_probable_oper_channel {
1634 QCA_WLAN_VENDOR_ATTR_PROBABLE_OPER_CHANNEL_INVALID,
1635 /* 32-bit unsigned value; indicates the connection/iface type likely to
1636 * come on this channel (see enum qca_iface_type).
1637 */
1638 QCA_WLAN_VENDOR_ATTR_PROBABLE_OPER_CHANNEL_IFACE_TYPE,
1639 /* 32-bit unsigned value; the frequency (MHz) of the probable channel */
1640 QCA_WLAN_VENDOR_ATTR_PROBABLE_OPER_CHANNEL_FREQ,
1641 /* keep last */
1642 QCA_WLAN_VENDOR_ATTR_PROBABLE_OPER_CHANNEL_AFTER_LAST,
1643 QCA_WLAN_VENDOR_ATTR_PROBABLE_OPER_CHANNEL_MAX =
1644 QCA_WLAN_VENDOR_ATTR_PROBABLE_OPER_CHANNEL_AFTER_LAST - 1
1645};
1646
1647enum qca_iface_type {
1648 QCA_IFACE_TYPE_STA,
1649 QCA_IFACE_TYPE_AP,
1650 QCA_IFACE_TYPE_P2P_CLIENT,
1651 QCA_IFACE_TYPE_P2P_GO,
1652 QCA_IFACE_TYPE_IBSS,
1653 QCA_IFACE_TYPE_TDLS,
1654};
1655
1656enum qca_set_band {
Jouni Malinenf735abd2020-08-03 11:08:00 +03001657 QCA_SETBAND_AUTO = 0,
1658 QCA_SETBAND_5G = BIT(0),
1659 QCA_SETBAND_2G = BIT(1),
1660 QCA_SETBAND_6G = BIT(2),
Peng Xu291d97d2018-01-31 16:34:03 -08001661};
1662
1663/**
1664 * enum qca_access_policy - Access control policy
1665 *
1666 * Access control policy is applied on the configured IE
1667 * (QCA_WLAN_VENDOR_ATTR_CONFIG_ACCESS_POLICY_IE).
1668 * To be set with QCA_WLAN_VENDOR_ATTR_CONFIG_ACCESS_POLICY.
1669 *
1670 * @QCA_ACCESS_POLICY_ACCEPT_UNLESS_LISTED: Deny Wi-Fi connections which match
1671 * the specific configuration (IE) set, i.e., allow all the
1672 * connections which do not match the configuration.
1673 * @QCA_ACCESS_POLICY_DENY_UNLESS_LISTED: Accept Wi-Fi connections which match
1674 * the specific configuration (IE) set, i.e., deny all the
1675 * connections which do not match the configuration.
1676 */
1677enum qca_access_policy {
1678 QCA_ACCESS_POLICY_ACCEPT_UNLESS_LISTED,
1679 QCA_ACCESS_POLICY_DENY_UNLESS_LISTED,
1680};
1681
1682/**
1683 * enum qca_vendor_attr_get_tsf: Vendor attributes for TSF capture
1684 * @QCA_WLAN_VENDOR_ATTR_TSF_CMD: enum qca_tsf_operation (u32)
1685 * @QCA_WLAN_VENDOR_ATTR_TSF_TIMER_VALUE: Unsigned 64 bit TSF timer value
1686 * @QCA_WLAN_VENDOR_ATTR_TSF_SOC_TIMER_VALUE: Unsigned 64 bit Synchronized
1687 * SOC timer value at TSF capture
1688 */
1689enum qca_vendor_attr_tsf_cmd {
1690 QCA_WLAN_VENDOR_ATTR_TSF_INVALID = 0,
1691 QCA_WLAN_VENDOR_ATTR_TSF_CMD,
1692 QCA_WLAN_VENDOR_ATTR_TSF_TIMER_VALUE,
1693 QCA_WLAN_VENDOR_ATTR_TSF_SOC_TIMER_VALUE,
1694 QCA_WLAN_VENDOR_ATTR_TSF_AFTER_LAST,
1695 QCA_WLAN_VENDOR_ATTR_TSF_MAX =
1696 QCA_WLAN_VENDOR_ATTR_TSF_AFTER_LAST - 1
1697};
1698
1699/**
1700 * enum qca_tsf_operation: TSF driver commands
1701 * @QCA_TSF_CAPTURE: Initiate TSF Capture
1702 * @QCA_TSF_GET: Get TSF capture value
1703 * @QCA_TSF_SYNC_GET: Initiate TSF capture and return with captured value
1704 */
1705enum qca_tsf_cmd {
1706 QCA_TSF_CAPTURE,
1707 QCA_TSF_GET,
1708 QCA_TSF_SYNC_GET,
1709};
1710
1711/**
1712 * enum qca_vendor_attr_wisa_cmd
1713 * @QCA_WLAN_VENDOR_ATTR_WISA_MODE: WISA mode value (u32)
1714 * WISA setup vendor commands
1715 */
1716enum qca_vendor_attr_wisa_cmd {
1717 QCA_WLAN_VENDOR_ATTR_WISA_INVALID = 0,
1718 QCA_WLAN_VENDOR_ATTR_WISA_MODE,
1719 QCA_WLAN_VENDOR_ATTR_WISA_AFTER_LAST,
1720 QCA_WLAN_VENDOR_ATTR_WISA_MAX =
1721 QCA_WLAN_VENDOR_ATTR_WISA_AFTER_LAST - 1
1722};
1723
1724/* IEEE 802.11 Vendor Specific elements */
1725
1726/**
1727 * enum qca_vendor_element_id - QCA Vendor Specific element types
1728 *
1729 * These values are used to identify QCA Vendor Specific elements. The
1730 * payload of the element starts with the three octet OUI (OUI_QCA) and
1731 * is followed by a single octet type which is defined by this enum.
1732 *
1733 * @QCA_VENDOR_ELEM_P2P_PREF_CHAN_LIST: P2P preferred channel list.
1734 * This element can be used to specify preference order for supported
1735 * channels. The channels in this list are in preference order (the first
1736 * one has the highest preference) and are described as a pair of
1737 * (global) Operating Class and Channel Number (each one octet) fields.
1738 *
1739 * This extends the standard P2P functionality by providing option to have
1740 * more than one preferred operating channel. When this element is present,
1741 * it replaces the preference indicated in the Operating Channel attribute.
1742 * For supporting other implementations, the Operating Channel attribute is
1743 * expected to be used with the highest preference channel. Similarly, all
1744 * the channels included in this Preferred channel list element are
1745 * expected to be included in the Channel List attribute.
1746 *
1747 * This vendor element may be included in GO Negotiation Request, P2P
1748 * Invitation Request, and Provision Discovery Request frames.
1749 *
1750 * @QCA_VENDOR_ELEM_HE_CAPAB: HE Capabilities element.
1751 * This element can be used for pre-standard publication testing of HE
1752 * before P802.11ax draft assigns the element ID. The payload of this
1753 * vendor specific element is defined by the latest P802.11ax draft.
1754 * Please note that the draft is still work in progress and this element
1755 * payload is subject to change.
1756 *
1757 * @QCA_VENDOR_ELEM_HE_OPER: HE Operation element.
1758 * This element can be used for pre-standard publication testing of HE
1759 * before P802.11ax draft assigns the element ID. The payload of this
1760 * vendor specific element is defined by the latest P802.11ax draft.
1761 * Please note that the draft is still work in progress and this element
1762 * payload is subject to change.
1763 *
1764 * @QCA_VENDOR_ELEM_RAPS: RAPS element (OFDMA-based Random Access Parameter Set
1765 * element).
1766 * This element can be used for pre-standard publication testing of HE
1767 * before P802.11ax draft assigns the element ID extension. The payload of
1768 * this vendor specific element is defined by the latest P802.11ax draft
1769 * (not including the Element ID Extension field). Please note that the
1770 * draft is still work in progress and this element payload is subject to
1771 * change.
1772 *
1773 * @QCA_VENDOR_ELEM_MU_EDCA_PARAMS: MU EDCA Parameter Set element.
1774 * This element can be used for pre-standard publication testing of HE
1775 * before P802.11ax draft assigns the element ID extension. The payload of
1776 * this vendor specific element is defined by the latest P802.11ax draft
1777 * (not including the Element ID Extension field). Please note that the
1778 * draft is still work in progress and this element payload is subject to
1779 * change.
1780 *
1781 * @QCA_VENDOR_ELEM_BSS_COLOR_CHANGE: BSS Color Change Announcement element.
1782 * This element can be used for pre-standard publication testing of HE
1783 * before P802.11ax draft assigns the element ID extension. The payload of
1784 * this vendor specific element is defined by the latest P802.11ax draft
1785 * (not including the Element ID Extension field). Please note that the
1786 * draft is still work in progress and this element payload is subject to
1787 * change.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05301788 *
1789 * @QCA_VENDOR_ELEM_ALLPLAY: Allplay element
Peng Xu291d97d2018-01-31 16:34:03 -08001790 */
1791enum qca_vendor_element_id {
1792 QCA_VENDOR_ELEM_P2P_PREF_CHAN_LIST = 0,
1793 QCA_VENDOR_ELEM_HE_CAPAB = 1,
1794 QCA_VENDOR_ELEM_HE_OPER = 2,
1795 QCA_VENDOR_ELEM_RAPS = 3,
1796 QCA_VENDOR_ELEM_MU_EDCA_PARAMS = 4,
1797 QCA_VENDOR_ELEM_BSS_COLOR_CHANGE = 5,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05301798 QCA_VENDOR_ELEM_ALLPLAY = 6,
Peng Xu291d97d2018-01-31 16:34:03 -08001799};
1800
1801/**
1802 * enum qca_wlan_vendor_attr_scan - Specifies vendor scan attributes
1803 *
1804 * @QCA_WLAN_VENDOR_ATTR_SCAN_IE: IEs that should be included as part of scan
1805 * @QCA_WLAN_VENDOR_ATTR_SCAN_FREQUENCIES: Nested unsigned 32-bit attributes
1806 * with frequencies to be scanned (in MHz)
1807 * @QCA_WLAN_VENDOR_ATTR_SCAN_SSIDS: Nested attribute with SSIDs to be scanned
1808 * @QCA_WLAN_VENDOR_ATTR_SCAN_SUPP_RATES: Nested array attribute of supported
1809 * rates to be included
1810 * @QCA_WLAN_VENDOR_ATTR_SCAN_TX_NO_CCK_RATE: flag used to send probe requests
Arif Hussaine2645c62018-05-24 20:39:04 -07001811 * at non CCK rate in 2GHz band
Peng Xu291d97d2018-01-31 16:34:03 -08001812 * @QCA_WLAN_VENDOR_ATTR_SCAN_FLAGS: Unsigned 32-bit scan flags
1813 * @QCA_WLAN_VENDOR_ATTR_SCAN_COOKIE: Unsigned 64-bit cookie provided by the
Arif Hussaine2645c62018-05-24 20:39:04 -07001814 * driver for the specific scan request
Peng Xu291d97d2018-01-31 16:34:03 -08001815 * @QCA_WLAN_VENDOR_ATTR_SCAN_STATUS: Unsigned 8-bit status of the scan
Arif Hussaine2645c62018-05-24 20:39:04 -07001816 * request decoded as in enum scan_status
Peng Xu291d97d2018-01-31 16:34:03 -08001817 * @QCA_WLAN_VENDOR_ATTR_SCAN_MAC: 6-byte MAC address to use when randomisation
Arif Hussaine2645c62018-05-24 20:39:04 -07001818 * scan flag is set
Peng Xu291d97d2018-01-31 16:34:03 -08001819 * @QCA_WLAN_VENDOR_ATTR_SCAN_MAC_MASK: 6-byte MAC address mask to be used with
Arif Hussaine2645c62018-05-24 20:39:04 -07001820 * randomisation
Peng Xu291d97d2018-01-31 16:34:03 -08001821 * @QCA_WLAN_VENDOR_ATTR_SCAN_BSSID: 6-byte MAC address representing the
1822 * specific BSSID to scan for.
Jouni Malinenf735abd2020-08-03 11:08:00 +03001823 * @QCA_WLAN_VENDOR_ATTR_SCAN_DWELL_TIME: Unsigned 64-bit dwell time in
1824 * microseconds. This is a common value which applies across all
1825 * frequencies specified by QCA_WLAN_VENDOR_ATTR_SCAN_FREQUENCIES.
Peng Xu291d97d2018-01-31 16:34:03 -08001826 */
1827enum qca_wlan_vendor_attr_scan {
1828 QCA_WLAN_VENDOR_ATTR_SCAN_INVALID_PARAM = 0,
1829 QCA_WLAN_VENDOR_ATTR_SCAN_IE = 1,
1830 QCA_WLAN_VENDOR_ATTR_SCAN_FREQUENCIES = 2,
1831 QCA_WLAN_VENDOR_ATTR_SCAN_SSIDS = 3,
1832 QCA_WLAN_VENDOR_ATTR_SCAN_SUPP_RATES = 4,
1833 QCA_WLAN_VENDOR_ATTR_SCAN_TX_NO_CCK_RATE = 5,
1834 QCA_WLAN_VENDOR_ATTR_SCAN_FLAGS = 6,
1835 QCA_WLAN_VENDOR_ATTR_SCAN_COOKIE = 7,
1836 QCA_WLAN_VENDOR_ATTR_SCAN_STATUS = 8,
1837 QCA_WLAN_VENDOR_ATTR_SCAN_MAC = 9,
1838 QCA_WLAN_VENDOR_ATTR_SCAN_MAC_MASK = 10,
1839 QCA_WLAN_VENDOR_ATTR_SCAN_BSSID = 11,
Jouni Malinenf735abd2020-08-03 11:08:00 +03001840 QCA_WLAN_VENDOR_ATTR_SCAN_DWELL_TIME = 12,
Peng Xu291d97d2018-01-31 16:34:03 -08001841 QCA_WLAN_VENDOR_ATTR_SCAN_AFTER_LAST,
1842 QCA_WLAN_VENDOR_ATTR_SCAN_MAX =
1843 QCA_WLAN_VENDOR_ATTR_SCAN_AFTER_LAST - 1
1844};
1845
1846/**
1847 * enum scan_status - Specifies the valid values the vendor scan attribute
Arif Hussaine2645c62018-05-24 20:39:04 -07001848 * QCA_WLAN_VENDOR_ATTR_SCAN_STATUS can take
Peng Xu291d97d2018-01-31 16:34:03 -08001849 *
1850 * @VENDOR_SCAN_STATUS_NEW_RESULTS: implies the vendor scan is successful with
Arif Hussaine2645c62018-05-24 20:39:04 -07001851 * new scan results
Peng Xu291d97d2018-01-31 16:34:03 -08001852 * @VENDOR_SCAN_STATUS_ABORTED: implies the vendor scan was aborted in-between
1853 */
1854enum scan_status {
1855 VENDOR_SCAN_STATUS_NEW_RESULTS,
1856 VENDOR_SCAN_STATUS_ABORTED,
1857 VENDOR_SCAN_STATUS_MAX,
1858};
1859
1860/**
1861 * enum qca_vendor_attr_ota_test - Specifies the values for vendor
1862 * command QCA_NL80211_VENDOR_SUBCMD_OTA_TEST
1863 * @QCA_WLAN_VENDOR_ATTR_OTA_TEST_ENABLE: enable ota test
1864 */
1865enum qca_vendor_attr_ota_test {
1866 QCA_WLAN_VENDOR_ATTR_OTA_TEST_INVALID,
1867 /* 8-bit unsigned value to indicate if OTA test is enabled */
1868 QCA_WLAN_VENDOR_ATTR_OTA_TEST_ENABLE,
1869 /* keep last */
1870 QCA_WLAN_VENDOR_ATTR_OTA_TEST_AFTER_LAST,
1871 QCA_WLAN_VENDOR_ATTR_OTA_TEST_MAX =
1872 QCA_WLAN_VENDOR_ATTR_OTA_TEST_AFTER_LAST - 1
1873};
1874
1875/**
1876 * enum qca_vendor_attr_txpower_scale - vendor sub commands index
1877 *
1878 * @QCA_WLAN_VENDOR_ATTR_TXPOWER_SCALE: scaling value
1879 */
1880enum qca_vendor_attr_txpower_scale {
1881 QCA_WLAN_VENDOR_ATTR_TXPOWER_SCALE_INVALID,
1882 /* 8-bit unsigned value to indicate the scaling of tx power */
1883 QCA_WLAN_VENDOR_ATTR_TXPOWER_SCALE,
1884 /* keep last */
1885 QCA_WLAN_VENDOR_ATTR_TXPOWER_SCALE_AFTER_LAST,
1886 QCA_WLAN_VENDOR_ATTR_TXPOWER_SCALE_MAX =
1887 QCA_WLAN_VENDOR_ATTR_TXPOWER_SCALE_AFTER_LAST - 1
1888};
1889
1890/**
1891 * enum qca_vendor_attr_txpower_decr_db - Attributes for TX power decrease
1892 *
1893 * These attributes are used with QCA_NL80211_VENDOR_SUBCMD_SET_TXPOWER_DECR_DB.
1894 */
1895enum qca_vendor_attr_txpower_decr_db {
1896 QCA_WLAN_VENDOR_ATTR_TXPOWER_DECR_DB_INVALID,
1897 /* 8-bit unsigned value to indicate the reduction of TX power in dB for
Arif Hussaine2645c62018-05-24 20:39:04 -07001898 * a virtual interface.
1899 */
Peng Xu291d97d2018-01-31 16:34:03 -08001900 QCA_WLAN_VENDOR_ATTR_TXPOWER_DECR_DB,
1901 /* keep last */
1902 QCA_WLAN_VENDOR_ATTR_TXPOWER_DECR_DB_AFTER_LAST,
1903 QCA_WLAN_VENDOR_ATTR_TXPOWER_DECR_DB_MAX =
1904 QCA_WLAN_VENDOR_ATTR_TXPOWER_DECR_DB_AFTER_LAST - 1
1905};
1906
1907/* Attributes for data used by
1908 * QCA_NL80211_VENDOR_SUBCMD_SET_WIFI_CONFIGURATION and
1909 * QCA_NL80211_VENDOR_SUBCMD_GET_WIFI_CONFIGURATION subcommands.
1910 */
1911enum qca_wlan_vendor_attr_config {
1912 QCA_WLAN_VENDOR_ATTR_CONFIG_INVALID = 0,
1913 /* Unsigned 32-bit value to set the DTIM period.
1914 * Whether the wifi chipset wakes at every dtim beacon or a multiple of
1915 * the DTIM period. If DTIM is set to 3, the STA shall wake up every 3
1916 * DTIM beacons.
1917 */
1918 QCA_WLAN_VENDOR_ATTR_CONFIG_DYNAMIC_DTIM = 1,
1919 /* Unsigned 32-bit value to set the wifi_iface stats averaging factor
1920 * used to calculate statistics like average the TSF offset or average
1921 * number of frame leaked.
1922 * For instance, upon Beacon frame reception:
1923 * current_avg = ((beacon_TSF - TBTT) * factor + previous_avg * (0x10000 - factor) ) / 0x10000
1924 * For instance, when evaluating leaky APs:
1925 * current_avg = ((num frame received within guard time) * factor + previous_avg * (0x10000 - factor)) / 0x10000
1926 */
1927 QCA_WLAN_VENDOR_ATTR_CONFIG_STATS_AVG_FACTOR = 2,
1928 /* Unsigned 32-bit value to configure guard time, i.e., when
1929 * implementing IEEE power management based on frame control PM bit, how
1930 * long the driver waits before shutting down the radio and after
1931 * receiving an ACK frame for a Data frame with PM bit set.
1932 */
1933 QCA_WLAN_VENDOR_ATTR_CONFIG_GUARD_TIME = 3,
1934 /* Unsigned 32-bit value to change the FTM capability dynamically */
1935 QCA_WLAN_VENDOR_ATTR_CONFIG_FINE_TIME_MEASUREMENT = 4,
1936 /* Unsigned 16-bit value to configure maximum TX rate dynamically */
1937 QCA_WLAN_VENDOR_ATTR_CONF_TX_RATE = 5,
1938 /* Unsigned 32-bit value to configure the number of continuous
1939 * Beacon Miss which shall be used by the firmware to penalize
1940 * the RSSI.
1941 */
1942 QCA_WLAN_VENDOR_ATTR_CONFIG_PENALIZE_AFTER_NCONS_BEACON_MISS = 6,
1943 /* Unsigned 8-bit value to configure the channel avoidance indication
1944 * behavior. Firmware to send only one indication and ignore duplicate
1945 * indications when set to avoid multiple Apps wakeups.
1946 */
1947 QCA_WLAN_VENDOR_ATTR_CONFIG_CHANNEL_AVOIDANCE_IND = 7,
1948 /* 8-bit unsigned value to configure the maximum TX MPDU for
Arif Hussaine2645c62018-05-24 20:39:04 -07001949 * aggregation.
1950 */
Peng Xu291d97d2018-01-31 16:34:03 -08001951 QCA_WLAN_VENDOR_ATTR_CONFIG_TX_MPDU_AGGREGATION = 8,
1952 /* 8-bit unsigned value to configure the maximum RX MPDU for
Arif Hussaine2645c62018-05-24 20:39:04 -07001953 * aggregation.
1954 */
Peng Xu291d97d2018-01-31 16:34:03 -08001955 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_MPDU_AGGREGATION = 9,
1956 /* 8-bit unsigned value to configure the Non aggregrate/11g sw
Arif Hussaine2645c62018-05-24 20:39:04 -07001957 * retry threshold (0 disable, 31 max).
1958 */
Peng Xu291d97d2018-01-31 16:34:03 -08001959 QCA_WLAN_VENDOR_ATTR_CONFIG_NON_AGG_RETRY = 10,
1960 /* 8-bit unsigned value to configure the aggregrate sw
Arif Hussaine2645c62018-05-24 20:39:04 -07001961 * retry threshold (0 disable, 31 max).
1962 */
Peng Xu291d97d2018-01-31 16:34:03 -08001963 QCA_WLAN_VENDOR_ATTR_CONFIG_AGG_RETRY = 11,
1964 /* 8-bit unsigned value to configure the MGMT frame
Arif Hussaine2645c62018-05-24 20:39:04 -07001965 * retry threshold (0 disable, 31 max).
1966 */
Peng Xu291d97d2018-01-31 16:34:03 -08001967 QCA_WLAN_VENDOR_ATTR_CONFIG_MGMT_RETRY = 12,
1968 /* 8-bit unsigned value to configure the CTRL frame
Arif Hussaine2645c62018-05-24 20:39:04 -07001969 * retry threshold (0 disable, 31 max).
1970 */
Peng Xu291d97d2018-01-31 16:34:03 -08001971 QCA_WLAN_VENDOR_ATTR_CONFIG_CTRL_RETRY = 13,
1972 /* 8-bit unsigned value to configure the propagation delay for
Arif Hussaine2645c62018-05-24 20:39:04 -07001973 * 2G/5G band (0~63, units in us)
1974 */
Peng Xu291d97d2018-01-31 16:34:03 -08001975 QCA_WLAN_VENDOR_ATTR_CONFIG_PROPAGATION_DELAY = 14,
1976 /* Unsigned 32-bit value to configure the number of unicast TX fail
1977 * packet count. The peer is disconnected once this threshold is
Arif Hussaine2645c62018-05-24 20:39:04 -07001978 * reached.
1979 */
Peng Xu291d97d2018-01-31 16:34:03 -08001980 QCA_WLAN_VENDOR_ATTR_CONFIG_TX_FAIL_COUNT = 15,
1981 /* Attribute used to set scan default IEs to the driver.
1982 *
1983 * These IEs can be used by scan operations that will be initiated by
1984 * the driver/firmware.
1985 *
1986 * For further scan requests coming to the driver, these IEs should be
1987 * merged with the IEs received along with scan request coming to the
1988 * driver. If a particular IE is present in the scan default IEs but not
1989 * present in the scan request, then that IE should be added to the IEs
Arif Hussaine2645c62018-05-24 20:39:04 -07001990 * sent in the Probe Request frames for that scan request.
1991 */
Peng Xu291d97d2018-01-31 16:34:03 -08001992 QCA_WLAN_VENDOR_ATTR_CONFIG_SCAN_DEFAULT_IES = 16,
1993 /* Unsigned 32-bit attribute for generic commands */
1994 QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_COMMAND = 17,
1995 /* Unsigned 32-bit value attribute for generic commands */
1996 QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_VALUE = 18,
1997 /* Unsigned 32-bit data attribute for generic command response */
1998 QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_DATA = 19,
1999 /* Unsigned 32-bit length attribute for
Arif Hussaine2645c62018-05-24 20:39:04 -07002000 * QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_DATA
2001 */
Peng Xu291d97d2018-01-31 16:34:03 -08002002 QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_LENGTH = 20,
2003 /* Unsigned 32-bit flags attribute for
Arif Hussaine2645c62018-05-24 20:39:04 -07002004 * QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_DATA
2005 */
Peng Xu291d97d2018-01-31 16:34:03 -08002006 QCA_WLAN_VENDOR_ATTR_CONFIG_GENERIC_FLAGS = 21,
2007 /* Unsigned 32-bit, defining the access policy.
2008 * See enum qca_access_policy. Used with
Arif Hussaine2645c62018-05-24 20:39:04 -07002009 * QCA_WLAN_VENDOR_ATTR_CONFIG_ACCESS_POLICY_IE_LIST.
2010 */
Peng Xu291d97d2018-01-31 16:34:03 -08002011 QCA_WLAN_VENDOR_ATTR_CONFIG_ACCESS_POLICY = 22,
2012 /* Sets the list of full set of IEs for which a specific access policy
2013 * has to be applied. Used along with
2014 * QCA_WLAN_VENDOR_ATTR_CONFIG_ACCESS_POLICY to control the access.
Arif Hussaine2645c62018-05-24 20:39:04 -07002015 * Zero length payload can be used to clear this access constraint.
2016 */
Peng Xu291d97d2018-01-31 16:34:03 -08002017 QCA_WLAN_VENDOR_ATTR_CONFIG_ACCESS_POLICY_IE_LIST = 23,
2018 /* Unsigned 32-bit, specifies the interface index (netdev) for which the
2019 * corresponding configurations are applied. If the interface index is
2020 * not specified, the configurations are attributed to the respective
Arif Hussaine2645c62018-05-24 20:39:04 -07002021 * wiphy.
2022 */
Peng Xu291d97d2018-01-31 16:34:03 -08002023 QCA_WLAN_VENDOR_ATTR_CONFIG_IFINDEX = 24,
2024 /* 8-bit unsigned value to trigger QPower: 1-Enable, 0-Disable */
2025 QCA_WLAN_VENDOR_ATTR_CONFIG_QPOWER = 25,
2026 /* 8-bit unsigned value to configure the driver and below layers to
2027 * ignore the assoc disallowed set by APs while connecting
Arif Hussaine2645c62018-05-24 20:39:04 -07002028 * 1-Ignore, 0-Don't ignore
2029 */
Peng Xu291d97d2018-01-31 16:34:03 -08002030 QCA_WLAN_VENDOR_ATTR_CONFIG_IGNORE_ASSOC_DISALLOWED = 26,
2031 /* 32-bit unsigned value to trigger antenna diversity features:
Arif Hussaine2645c62018-05-24 20:39:04 -07002032 * 1-Enable, 0-Disable
2033 */
Peng Xu291d97d2018-01-31 16:34:03 -08002034 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_ENA = 27,
2035 /* 32-bit unsigned value to configure specific chain antenna */
2036 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_CHAIN = 28,
2037 /* 32-bit unsigned value to trigger cycle selftest
Arif Hussaine2645c62018-05-24 20:39:04 -07002038 * 1-Enable, 0-Disable
2039 */
Peng Xu291d97d2018-01-31 16:34:03 -08002040 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_SELFTEST = 29,
2041 /* 32-bit unsigned to configure the cycle time of selftest
Arif Hussaine2645c62018-05-24 20:39:04 -07002042 * the unit is micro-second
2043 */
Peng Xu291d97d2018-01-31 16:34:03 -08002044 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_SELFTEST_INTVL = 30,
2045 /* 32-bit unsigned value to set reorder timeout for AC_VO */
2046 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_REORDER_TIMEOUT_VOICE = 31,
2047 /* 32-bit unsigned value to set reorder timeout for AC_VI */
2048 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_REORDER_TIMEOUT_VIDEO = 32,
2049 /* 32-bit unsigned value to set reorder timeout for AC_BE */
2050 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_REORDER_TIMEOUT_BESTEFFORT = 33,
2051 /* 32-bit unsigned value to set reorder timeout for AC_BK */
2052 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_REORDER_TIMEOUT_BACKGROUND = 34,
2053 /* 6-byte MAC address to point out the specific peer */
2054 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_BLOCKSIZE_PEER_MAC = 35,
2055 /* 32-bit unsigned value to set window size for specific peer */
2056 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_BLOCKSIZE_WINLIMIT = 36,
2057 /* 8-bit unsigned value to set the beacon miss threshold in 2.4 GHz */
2058 QCA_WLAN_VENDOR_ATTR_CONFIG_BEACON_MISS_THRESHOLD_24 = 37,
2059 /* 8-bit unsigned value to set the beacon miss threshold in 5 GHz */
2060 QCA_WLAN_VENDOR_ATTR_CONFIG_BEACON_MISS_THRESHOLD_5 = 38,
2061 /* 32-bit unsigned value to configure 5 or 10 MHz channel width for
2062 * station device while in disconnect state. The attribute use the
2063 * value of enum nl80211_chan_width: NL80211_CHAN_WIDTH_5 means 5 MHz,
2064 * NL80211_CHAN_WIDTH_10 means 10 MHz. If set, the device work in 5 or
2065 * 10 MHz channel width, the station will not connect to a BSS using 20
2066 * MHz or higher bandwidth. Set to NL80211_CHAN_WIDTH_20_NOHT to
Arif Hussaine2645c62018-05-24 20:39:04 -07002067 * clear this constraint.
2068 */
Peng Xu291d97d2018-01-31 16:34:03 -08002069 QCA_WLAN_VENDOR_ATTR_CONFIG_SUB20_CHAN_WIDTH = 39,
2070 /* 32-bit unsigned value to configure the propagation absolute delay
Arif Hussaine2645c62018-05-24 20:39:04 -07002071 * for 2G/5G band (units in us)
2072 */
Peng Xu291d97d2018-01-31 16:34:03 -08002073 QCA_WLAN_VENDOR_ATTR_CONFIG_PROPAGATION_ABS_DELAY = 40,
2074 /* 32-bit unsigned value to set probe period */
2075 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_PROBE_PERIOD = 41,
2076 /* 32-bit unsigned value to set stay period */
2077 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_STAY_PERIOD = 42,
2078 /* 32-bit unsigned value to set snr diff */
2079 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_SNR_DIFF = 43,
2080 /* 32-bit unsigned value to set probe dwell time */
2081 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_PROBE_DWELL_TIME = 44,
2082 /* 32-bit unsigned value to set mgmt snr weight */
2083 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_MGMT_SNR_WEIGHT = 45,
2084 /* 32-bit unsigned value to set data snr weight */
2085 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_DATA_SNR_WEIGHT = 46,
2086 /* 32-bit unsigned value to set ack snr weight */
2087 QCA_WLAN_VENDOR_ATTR_CONFIG_ANT_DIV_ACK_SNR_WEIGHT = 47,
2088 /* 32-bit unsigned value to configure the listen interval.
2089 * This is in units of beacon intervals. This configuration alters
2090 * the negotiated listen interval with the AP during the connection.
2091 * It is highly recommended to configure a value less than or equal to
2092 * the one negotiated during the association. Configuring any greater
2093 * value can have adverse effects (frame loss, AP disassociating STA,
2094 * etc.).
2095 */
2096 QCA_WLAN_VENDOR_ATTR_CONFIG_LISTEN_INTERVAL = 48,
2097 /*
2098 * 8 bit unsigned value that is set on an AP/GO virtual interface to
2099 * disable operations that would cause the AP/GO to leave its operating
2100 * channel.
2101 *
2102 * This will restrict the scans to the AP/GO operating channel and the
2103 * channels of the other band, if DBS is supported.A STA/CLI interface
2104 * brought up after this setting is enabled, will be restricted to
2105 * connecting to devices only on the AP/GO interface's operating channel
2106 * or on the other band in DBS case. P2P supported channel list is
2107 * modified, to only include AP interface's operating-channel and the
2108 * channels of the other band if DBS is supported.
2109 *
2110 * These restrictions are only applicable as long as the AP/GO interface
2111 * is alive. If the AP/GO interface is brought down then this
2112 * setting/restriction is forgotten.
2113 *
2114 * If this variable is set on an AP/GO interface while a multi-channel
2115 * concurrent session is active, it has no effect on the operation of
2116 * the current interfaces, other than restricting the scan to the AP/GO
2117 * operating channel and the other band channels if DBS is supported.
2118 * However, if the STA is brought down and restarted then the new STA
2119 * connection will either be formed on the AP/GO channel or on the
2120 * other band in a DBS case. This is because of the scan being
2121 * restricted on these channels as mentioned above.
2122 *
2123 * 1-Restrict / 0-Don't restrict offchannel operations.
2124 */
2125 QCA_WLAN_VENDOR_ATTR_CONFIG_RESTRICT_OFFCHANNEL = 49,
2126 /*
2127 * 8 bit unsigned value to enable/disable LRO (Large Receive Offload)
2128 * on an interface.
2129 * 1 - Enable, 0 - Disable.
2130 */
2131 QCA_WLAN_VENDOR_ATTR_CONFIG_LRO = 50,
2132
2133 /*
2134 * 8 bit unsigned value to globally enable/disable scan
2135 * 1 - Enable, 0 - Disable.
2136 */
2137 QCA_WLAN_VENDOR_ATTR_CONFIG_SCAN_ENABLE = 51,
2138
2139 /* 8-bit unsigned value to set the total beacon miss count
Arif Hussaine2645c62018-05-24 20:39:04 -07002140 * This parameter will set the total beacon miss count.
Peng Xu291d97d2018-01-31 16:34:03 -08002141 */
2142 QCA_WLAN_VENDOR_ATTR_CONFIG_TOTAL_BEACON_MISS_COUNT = 52,
2143
2144 /* Unsigned 32-bit value to configure the number of continuous
2145 * Beacon Miss which shall be used by the firmware to penalize
2146 * the RSSI for BTC.
2147 */
2148 QCA_WLAN_VENDOR_ATTR_CONFIG_PENALIZE_AFTER_NCONS_BEACON_MISS_BTC = 53,
2149
2150 /* 8-bit unsigned value to configure the driver and below layers to
2151 * enable/disable all FILS features.
Arif Hussaine2645c62018-05-24 20:39:04 -07002152 * 0-enable, 1-disable
2153 */
Peng Xu291d97d2018-01-31 16:34:03 -08002154 QCA_WLAN_VENDOR_ATTR_CONFIG_DISABLE_FILS = 54,
2155
2156 /* 16-bit unsigned value to configure the level of WLAN latency
2157 * module. See enum qca_wlan_vendor_attr_config_latency_level.
2158 */
2159 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL = 55,
2160
2161 /* 8-bit unsigned value indicating the driver to use the RSNE as-is from
2162 * the connect interface. Exclusively used for the scenarios where the
2163 * device is used as a test bed device with special functionality and
2164 * not recommended for production. This helps driver to not validate the
2165 * RSNE passed from user space and thus allow arbitrary IE data to be
2166 * used for testing purposes.
2167 * 1-enable, 0-disable.
2168 * Applications set/reset this configuration. If not reset, this
2169 * parameter remains in use until the driver is unloaded.
2170 */
2171 QCA_WLAN_VENDOR_ATTR_CONFIG_RSN_IE = 56,
2172
Arif Hussaine2645c62018-05-24 20:39:04 -07002173 /* 8-bit unsigned value to trigger green Tx power saving.
2174 * 1-Enable, 0-Disable
2175 */
2176 QCA_WLAN_VENDOR_ATTR_CONFIG_GTX = 57,
2177
Jouni Malinenf735abd2020-08-03 11:08:00 +03002178 /* Attribute to configure disconnect IEs to the driver.
2179 * This carries an array of unsigned 8-bit characters.
2180 *
2181 * If this is configured, driver shall fill the IEs in disassoc/deauth
2182 * frame.
2183 * These IEs are expected to be considered only for the next
2184 * immediate disconnection (disassoc/deauth frame) originated by
2185 * the DUT, irrespective of the entity (user space/driver/firmware)
2186 * triggering the disconnection.
2187 * The host drivers are not expected to use the IEs set through
2188 * this interface for further disconnections after the first immediate
2189 * disconnection initiated post the configuration.
2190 * If the IEs are also updated through cfg80211 interface (after the
2191 * enhancement to cfg80211_disconnect), host driver is expected to
2192 * take the union of IEs from both of these interfaces and send in
2193 * further disassoc/deauth frames.
2194 */
2195 QCA_WLAN_VENDOR_ATTR_CONFIG_DISCONNECT_IES = 58,
2196
2197 /* 8-bit unsigned value for ELNA bypass.
2198 * 1-Enable, 0-Disable
2199 */
2200 QCA_WLAN_VENDOR_ATTR_CONFIG_ELNA_BYPASS = 59,
2201
2202 /* 8-bit unsigned value. This attribute enables/disables the host driver
2203 * to send the Beacon Report Response with failure reason for the
2204 * scenarios where STA cannot honor the Beacon Report Request from AP.
2205 * 1-Enable, 0-Disable.
2206 */
2207 QCA_WLAN_VENDOR_ATTR_CONFIG_BEACON_REPORT_FAIL = 60,
2208
2209 /* 8-bit unsigned value. This attribute enables/disables the host driver
2210 * to send roam reason information in the Reassociation Request frame to
2211 * the target AP when roaming within the same ESS.
2212 * 1-Enable, 0-Disable.
2213 */
2214 QCA_WLAN_VENDOR_ATTR_CONFIG_ROAM_REASON = 61,
2215
2216 /* 32-bit unsigned value to configure different PHY modes to the
2217 * driver/firmware. The possible values are defined in
2218 * enum qca_wlan_vendor_phy_mode. The configuration will be reset to
2219 * default value, i.e., QCA_WLAN_VENDOR_PHY_MODE_AUTO upon restarting
2220 * the driver.
2221 */
2222 QCA_WLAN_VENDOR_ATTR_CONFIG_PHY_MODE = 62,
2223
2224 /* 8-bit unsigned value to configure the maximum supported channel width
2225 * for STA mode. If this value is configured when STA is in connected
2226 * state, it should not exceed the negotiated channel width. If it is
2227 * configured when STA is in disconnected state, the configured value
2228 * will take effect for the next immediate connection.
2229 * Possible values are:
2230 * NL80211_CHAN_WIDTH_20
2231 * NL80211_CHAN_WIDTH_40
2232 * NL80211_CHAN_WIDTH_80
2233 * NL80211_CHAN_WIDTH_80P80
2234 * NL80211_CHAN_WIDTH_160
2235 */
2236 QCA_WLAN_VENDOR_ATTR_CONFIG_CHANNEL_WIDTH = 63,
2237
2238 /* 8-bit unsigned value to enable/disable dynamic bandwidth adjustment.
2239 * This attribute is only applicable for STA mode. When dynamic
2240 * bandwidth adjustment is disabled, STA will use static channel width
2241 * the value of which is negotiated during connection.
2242 * 1-enable (default), 0-disable
2243 */
2244 QCA_WLAN_VENDOR_ATTR_CONFIG_DYNAMIC_BW = 64,
2245
2246 /* 8-bit unsigned value to configure the maximum number of subframes of
2247 * TX MSDU for aggregation. Possible values are 0-31. When set to 0,
2248 * it is decided by the hardware.
2249 */
2250 QCA_WLAN_VENDOR_ATTR_CONFIG_TX_MSDU_AGGREGATION = 65,
2251
2252 /* 8-bit unsigned value to configure the maximum number of subframes of
2253 * RX MSDU for aggregation. Possible values are 0-31. When set to 0,
2254 * it is decided by the hardware.
2255 */
2256 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_MSDU_AGGREGATION = 66,
2257
2258 /* 8-bit unsigned value. This attribute is used to dynamically
2259 * enable/disable the LDPC capability of the device. When configured in
2260 * the disconnected state, the updated configuration will be considered
2261 * for the immediately following connection attempt. If this
2262 * configuration is modified while the device is in the connected state,
2263 * the LDPC TX will be updated with this configuration immediately,
2264 * while the LDPC RX configuration update will take place starting from
2265 * the subsequent association attempt.
2266 * 1-Enable, 0-Disable.
2267 */
2268 QCA_WLAN_VENDOR_ATTR_CONFIG_LDPC = 67,
2269
2270 /* 8-bit unsigned value. This attribute is used to dynamically
2271 * enable/disable the TX STBC capability of the device. When configured
2272 * in the disconnected state, the updated configuration will be
2273 * considered for the immediately following connection attempt. If the
2274 * connection is formed with TX STBC enabled and if this configuration
2275 * is disabled during that association, the TX will be impacted
2276 * immediately. Further connection attempts will disable TX STBC.
2277 * However, enabling the TX STBC for a connected session with disabled
2278 * capability is not allowed and will fail.
2279 * 1-Enable, 0-Disable.
2280 */
2281 QCA_WLAN_VENDOR_ATTR_CONFIG_TX_STBC = 68,
2282
2283 /* 8-bit unsigned value. This attribute is used to dynamically
2284 * enable/disable the RX STBC capability of the device. When configured
2285 * in the disconnected state, the updated configuration will be
2286 * considered for the immediately following connection attempt. If the
2287 * configuration is modified in the connected state, there will be no
2288 * impact for the current association, but further connection attempts
2289 * will use the updated configuration.
2290 * 1-Enable, 0-Disable.
2291 */
2292 QCA_WLAN_VENDOR_ATTR_CONFIG_RX_STBC = 69,
2293
2294 /* 8-bit unsigned value. This attribute is used to dynamically configure
2295 * the number of spatial streams. When configured in the disconnected
2296 * state, the updated configuration will be considered for the
2297 * immediately following connection attempt. If the NSS is updated after
2298 * the connection, the updated NSS value is notified to the peer using
2299 * the Operating Mode Notification/Spatial Multiplexing Power Save
2300 * frame. The updated NSS value after the connection shall not be
2301 * greater than the one negotiated during the connection. Any such
2302 * higher value configuration shall be returned with a failure.
2303 */
2304 QCA_WLAN_VENDOR_ATTR_CONFIG_NSS = 70,
2305 /* 8-bit unsigned value to trigger Optimized Power Management:
2306 * 1-Enable, 0-Disable
2307 */
2308 QCA_WLAN_VENDOR_ATTR_CONFIG_OPTIMIZED_POWER_MANAGEMENT = 71,
2309
2310 /* 8-bit unsigned value. This attribute takes the QoS/access category
2311 * value represented by the enum qca_wlan_ac_type and expects the driver
2312 * to upgrade the UDP frames to this access category. The value of
2313 * QCA_WLAN_AC_ALL is invalid for this attribute. This will override the
2314 * DSCP value configured in the frame with the intention to only upgrade
2315 * the access category. That said, it is not intended to downgrade the
2316 * access category for the frames.
2317 * Set the value to QCA_WLAN_AC_BK if the QoS upgrade needs to be
2318 * disabled, as BK is of the lowest priority and an upgrade to it does
2319 * not result in any changes for the frames.
2320 */
2321 QCA_WLAN_VENDOR_ATTR_CONFIG_UDP_QOS_UPGRADE = 72,
2322
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302323 /* 8-bit unsigned value. This attribute is used to dynamically configure
2324 * the number of chains to be used for transmitting data. This
2325 * configuration is allowed only when in connected state and will be
2326 * effective until disconnected. The driver rejects this configuration
2327 * if the number of spatial streams being used in the current connection
2328 * cannot be supported by this configuration.
2329 */
2330 QCA_WLAN_VENDOR_ATTR_CONFIG_NUM_TX_CHAINS = 73,
2331 /* 8-bit unsigned value. This attribute is used to dynamically configure
2332 * the number of chains to be used for receiving data. This
2333 * configuration is allowed only when in connected state and will be
2334 * effective until disconnected. The driver rejects this configuration
2335 * if the number of spatial streams being used in the current connection
2336 * cannot be supported by this configuration.
2337 */
2338 QCA_WLAN_VENDOR_ATTR_CONFIG_NUM_RX_CHAINS = 74,
2339
2340 /* 8-bit unsigned value to configure ANI setting type.
2341 * See &enum qca_wlan_ani_setting for possible values.
2342 */
2343 QCA_WLAN_VENDOR_ATTR_CONFIG_ANI_SETTING = 75,
2344 /* 32-bit signed value to configure ANI level. This is used when
2345 * ANI settings type is &QCA_WLAN_ANI_SETTING_FIXED.
2346 * The set and get of ANI level with &QCA_WLAN_ANI_SETTING_AUTO
2347 * is invalid, the driver will return a failure.
2348 */
2349 QCA_WLAN_VENDOR_ATTR_CONFIG_ANI_LEVEL = 76,
2350
Peng Xu291d97d2018-01-31 16:34:03 -08002351 /* keep last */
2352 QCA_WLAN_VENDOR_ATTR_CONFIG_AFTER_LAST,
2353 QCA_WLAN_VENDOR_ATTR_CONFIG_MAX =
2354 QCA_WLAN_VENDOR_ATTR_CONFIG_AFTER_LAST - 1,
2355};
2356
Jouni Malinenf735abd2020-08-03 11:08:00 +03002357/* Compatibility defines for previously used incorrect enum
2358 * qca_wlan_vendor_attr_config names. These values should not be used in any
2359 * new implementation. */
2360#define QCA_WLAN_VENDOR_ATTR_DISCONNECT_IES \
2361 QCA_WLAN_VENDOR_ATTR_CONFIG_DISCONNECT_IES
2362#define QCA_WLAN_VENDOR_ATTR_BEACON_REPORT_FAIL \
2363 QCA_WLAN_VENDOR_ATTR_CONFIG_BEACON_REPORT_FAIL
2364
Peng Xu291d97d2018-01-31 16:34:03 -08002365/**
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302366 * enum qca_wlan_ani_setting - ANI setting type
2367 * @QCA_WLAN_ANI_SETTING_AUTO: Automatically determine ANI level
2368 * @QCA_WLAN_ANI_SETTING_FIXED: Fix ANI level to the dBm parameter
2369 */
2370enum qca_wlan_ani_setting {
2371 QCA_WLAN_ANI_SETTING_AUTO = 0,
2372 QCA_WLAN_ANI_SETTING_FIXED = 1,
2373};
2374
2375/**
Peng Xu291d97d2018-01-31 16:34:03 -08002376 * enum qca_wlan_vendor_attr_sap_config - Parameters for AP configuration
Jouni Malinenf735abd2020-08-03 11:08:00 +03002377 *
2378 * @QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_CHANNEL: Optional (u8)
2379 * Channel number on which Access Point should restart.
2380 * Note: If both the driver and user space application supports the 6 GHz band,
2381 * this attribute is deprecated and QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_FREQUENCY
2382 * should be used.
2383 * To maintain backward compatibility, QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_CHANNEL
2384 * is still used if either of the driver or user space application doesn't
2385 * support the 6 GHz band.
2386 *
2387 * @QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_FREQUENCY: Optional (u32)
2388 * Channel center frequency (MHz) on which the access point should restart.
Peng Xu291d97d2018-01-31 16:34:03 -08002389 */
2390enum qca_wlan_vendor_attr_sap_config {
2391 QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_INVALID = 0,
Jouni Malinenf735abd2020-08-03 11:08:00 +03002392 QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_CHANNEL = 1,
2393
Peng Xu291d97d2018-01-31 16:34:03 -08002394 /* List of frequencies on which AP is expected to operate.
2395 * This is irrespective of ACS configuration. This list is a priority
2396 * based one and is looked for before the AP is created to ensure the
2397 * best concurrency sessions (avoid MCC and use DBS/SCC) co-exist in
2398 * the system.
2399 */
2400 QCA_WLAN_VENDOR_ATTR_SAP_MANDATORY_FREQUENCY_LIST = 2,
Jouni Malinenf735abd2020-08-03 11:08:00 +03002401 QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_FREQUENCY = 3,
Peng Xu291d97d2018-01-31 16:34:03 -08002402
2403 QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_AFTER_LAST,
2404 QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_MAX =
2405 QCA_WLAN_VENDOR_ATTR_SAP_CONFIG_AFTER_LAST - 1,
2406};
2407
2408/**
2409 * enum qca_wlan_vendor_attr_sap_conditional_chan_switch - Parameters for AP
2410 * conditional channel switch
2411 */
2412enum qca_wlan_vendor_attr_sap_conditional_chan_switch {
2413 QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_INVALID = 0,
2414 /* Priority based frequency list (an array of u32 values in host byte
Arif Hussaine2645c62018-05-24 20:39:04 -07002415 * order)
2416 */
Peng Xu291d97d2018-01-31 16:34:03 -08002417 QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_FREQ_LIST = 1,
2418 /* Status of the conditional switch (u32).
2419 * 0: Success, Non-zero: Failure
2420 */
2421 QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_STATUS = 2,
2422
2423 QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_AFTER_LAST,
2424 QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_MAX =
2425 QCA_WLAN_VENDOR_ATTR_SAP_CONDITIONAL_CHAN_SWITCH_AFTER_LAST - 1,
2426};
2427
2428/**
2429 * enum qca_wlan_gpio_attr - Parameters for GPIO configuration
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302430 *
2431 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND: Required (u32)
2432 * value to specify the GPIO command. Please refer to enum qca_gpio_cmd_type
2433 * for the available values.
2434 *
2435 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_PINNUM: Required (u32)
2436 * value to specify the GPIO number.
2437 * This is required, when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
2438 * %QCA_WLAN_VENDOR_GPIO_CONFIG or %QCA_WLAN_VENDOR_GPIO_OUTPUT.
2439 *
2440 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_VALUE: Required (u32)
2441 * value to specify the GPIO output level. Please refer to enum qca_gpio_value
2442 * for the available values.
2443 * This is required, when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
2444 * %QCA_WLAN_VENDOR_GPIO_OUTPUT.
2445 *
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002446 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_PULL_TYPE: Optional (u32)
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302447 * value to specify the GPIO pull type. Please refer to enum qca_gpio_pull_type
2448 * for the available values.
2449 * This is required, when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002450 * %QCA_WLAN_VENDOR_GPIO_CONFIG and
2451 * %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG attribute is not present.
2452 * Optional when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG
2453 * attribute is present.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302454 *
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002455 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTR_MODE: Optional (u32)
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302456 * value to specify the GPIO interrupt mode. Please refer to enum
2457 * qca_gpio_interrupt_mode for the available values.
2458 * This is required, when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002459 * %QCA_WLAN_VENDOR_GPIO_CONFIG and
2460 * %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG attribute is not present.
2461 * Optional when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG
2462 * attribute is present.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302463 *
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002464 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_DIR: Optional (u32)
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302465 * value to specify the GPIO direction. Please refer to enum qca_gpio_direction
2466 * for the available values.
2467 * This is required, when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002468 * %QCA_WLAN_VENDOR_GPIO_CONFIG and
2469 * %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG attribute is not present.
2470 * Optional when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG
2471 * attribute is present.
2472 *
2473 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_MUX_CONFIG: Optional (u32)
2474 * Value to specify the mux config. Meaning of a given value is dependent
2475 * on the target chipset and GPIO pin. Must be of the range 0-15.
2476 * Optional when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
2477 * %QCA_WLAN_VENDOR_GPIO_CONFIG. Defaults to 0.
2478 *
2479 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_DRIVE: Optional (u32)
2480 * Value to specify the drive, refer to enum qca_gpio_drive.
2481 * Optional when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
2482 * %QCA_WLAN_VENDOR_GPIO_CONFIG. Defaults to QCA_WLAN_GPIO_DRIVE_2MA(0).
2483 *
2484 * @QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG: Optional (flag)
2485 * Optional when %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND is
2486 * %QCA_WLAN_VENDOR_GPIO_CONFIG. When present this attribute signals that all
2487 * other parameters for the given GPIO will be obtained from internal
2488 * configuration. Only %QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_PINNUM must be
2489 * specified to indicate the GPIO pin being configured.
Peng Xu291d97d2018-01-31 16:34:03 -08002490 */
2491enum qca_wlan_gpio_attr {
2492 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INVALID = 0,
2493 /* Unsigned 32-bit attribute for GPIO command */
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302494 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_COMMAND = 1,
Peng Xu291d97d2018-01-31 16:34:03 -08002495 /* Unsigned 32-bit attribute for GPIO PIN number to configure */
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302496 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_PINNUM = 2,
Peng Xu291d97d2018-01-31 16:34:03 -08002497 /* Unsigned 32-bit attribute for GPIO value to configure */
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302498 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_VALUE = 3,
Peng Xu291d97d2018-01-31 16:34:03 -08002499 /* Unsigned 32-bit attribute for GPIO pull type */
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302500 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_PULL_TYPE = 4,
Peng Xu291d97d2018-01-31 16:34:03 -08002501 /* Unsigned 32-bit attribute for GPIO interrupt mode */
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302502 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTR_MODE = 5,
2503 /* Unsigned 32-bit attribute for GPIO direction to configure */
2504 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_DIR = 6,
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002505 /* Unsigned 32-bit attribute for GPIO mux config */
2506 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_MUX_CONFIG = 7,
2507 /* Unsigned 32-bit attribute for GPIO drive */
2508 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_DRIVE = 8,
2509 /* Flag attribute for using internal GPIO configuration */
2510 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_INTERNAL_CONFIG = 9,
Peng Xu291d97d2018-01-31 16:34:03 -08002511
2512 /* keep last */
2513 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_LAST,
2514 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_MAX =
2515 QCA_WLAN_VENDOR_ATTR_GPIO_PARAM_LAST - 1
2516};
2517
2518/**
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05302519 * enum gpio_cmd_type - GPIO configuration command type
2520 * @QCA_WLAN_VENDOR_GPIO_CONFIG: Set GPIO configuration info
2521 * @QCA_WLAN_VENDOR_GPIO_OUTPUT: Set GPIO output level
2522 */
2523enum qca_gpio_cmd_type {
2524 QCA_WLAN_VENDOR_GPIO_CONFIG = 0,
2525 QCA_WLAN_VENDOR_GPIO_OUTPUT = 1,
2526};
2527
2528/**
2529 * enum qca_gpio_pull_type - GPIO pull type
2530 * @QCA_WLAN_GPIO_PULL_NONE: Set GPIO pull type to none
2531 * @QCA_WLAN_GPIO_PULL_UP: Set GPIO pull up
2532 * @QCA_WLAN_GPIO_PULL_DOWN: Set GPIO pull down
2533 */
2534enum qca_gpio_pull_type {
2535 QCA_WLAN_GPIO_PULL_NONE = 0,
2536 QCA_WLAN_GPIO_PULL_UP = 1,
2537 QCA_WLAN_GPIO_PULL_DOWN = 2,
2538 QCA_WLAN_GPIO_PULL_MAX,
2539};
2540
2541/**
2542 * enum qca_gpio_direction - GPIO direction
2543 * @QCA_WLAN_GPIO_INPUT: Set GPIO as input mode
2544 * @QCA_WLAN_GPIO_OUTPUT: Set GPIO as output mode
2545 * @QCA_WLAN_GPIO_VALUE_MAX: Invalid value
2546 */
2547enum qca_gpio_direction {
2548 QCA_WLAN_GPIO_INPUT = 0,
2549 QCA_WLAN_GPIO_OUTPUT = 1,
2550 QCA_WLAN_GPIO_DIR_MAX,
2551};
2552
2553/**
2554 * enum qca_gpio_value - GPIO Value
2555 * @QCA_WLAN_GPIO_LEVEL_LOW: set gpio output level to low
2556 * @QCA_WLAN_GPIO_LEVEL_HIGH: set gpio output level to high
2557 * @QCA_WLAN_GPIO_LEVEL_MAX: Invalid value
2558 */
2559enum qca_gpio_value {
2560 QCA_WLAN_GPIO_LEVEL_LOW = 0,
2561 QCA_WLAN_GPIO_LEVEL_HIGH = 1,
2562 QCA_WLAN_GPIO_LEVEL_MAX,
2563};
2564
2565/**
2566 * enum gpio_interrupt_mode - GPIO interrupt mode
2567 * @QCA_WLAN_GPIO_INTMODE_DISABLE: Disable interrupt trigger
2568 * @QCA_WLAN_GPIO_INTMODE_RISING_EDGE: Interrupt with GPIO rising edge trigger
2569 * @QCA_WLAN_GPIO_INTMODE_FALLING_EDGE: Interrupt with GPIO falling edge trigger
2570 * @QCA_WLAN_GPIO_INTMODE_BOTH_EDGE: Interrupt with GPIO both edge trigger
2571 * @QCA_WLAN_GPIO_INTMODE_LEVEL_LOW: Interrupt with GPIO level low trigger
2572 * @QCA_WLAN_GPIO_INTMODE_LEVEL_HIGH: Interrupt with GPIO level high trigger
2573 * @QCA_WLAN_GPIO_INTMODE_MAX: Invalid value
2574 */
2575enum qca_gpio_interrupt_mode {
2576 QCA_WLAN_GPIO_INTMODE_DISABLE = 0,
2577 QCA_WLAN_GPIO_INTMODE_RISING_EDGE = 1,
2578 QCA_WLAN_GPIO_INTMODE_FALLING_EDGE = 2,
2579 QCA_WLAN_GPIO_INTMODE_BOTH_EDGE = 3,
2580 QCA_WLAN_GPIO_INTMODE_LEVEL_LOW = 4,
2581 QCA_WLAN_GPIO_INTMODE_LEVEL_HIGH = 5,
2582 QCA_WLAN_GPIO_INTMODE_MAX,
2583};
2584
2585/**
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08002586 * enum qca_gpio_drive - GPIO drive
2587 * @QCA_WLAN_GPIO_DRIVE_2MA: drive 2MA
2588 * @QCA_WLAN_GPIO_DRIVE_4MA: drive 4MA
2589 * @QCA_WLAN_GPIO_DRIVE_6MA: drive 6MA
2590 * @QCA_WLAN_GPIO_DRIVE_8MA: drive 8MA
2591 * @QCA_WLAN_GPIO_DRIVE_10MA: drive 10MA
2592 * @QCA_WLAN_GPIO_DRIVE_12MA: drive 12MA
2593 * @QCA_WLAN_GPIO_DRIVE_14MA: drive 14MA
2594 * @QCA_WLAN_GPIO_DRIVE_16MA: drive 16MA
2595 * @QCA_WLAN_GPIO_DRIVE_MAX: invalid GPIO drive
2596 */
2597enum qca_gpio_drive {
2598 QCA_WLAN_GPIO_DRIVE_2MA = 0,
2599 QCA_WLAN_GPIO_DRIVE_4MA = 1,
2600 QCA_WLAN_GPIO_DRIVE_6MA = 2,
2601 QCA_WLAN_GPIO_DRIVE_8MA = 3,
2602 QCA_WLAN_GPIO_DRIVE_10MA = 4,
2603 QCA_WLAN_GPIO_DRIVE_12MA = 5,
2604 QCA_WLAN_GPIO_DRIVE_14MA = 6,
2605 QCA_WLAN_GPIO_DRIVE_16MA = 7,
2606 QCA_WLAN_GPIO_DRIVE_MAX,
2607};
2608
2609/**
Peng Xu291d97d2018-01-31 16:34:03 -08002610 * qca_wlan_set_qdepth_thresh_attr - Parameters for setting
2611 * MSDUQ depth threshold per peer per tid in the target
2612 *
2613 * Associated Vendor Command:
2614 * QCA_NL80211_VENDOR_SUBCMD_SET_QDEPTH_THRESH
2615 */
2616enum qca_wlan_set_qdepth_thresh_attr {
2617 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_INVALID = 0,
2618 /* 6-byte MAC address */
2619 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_MAC_ADDR,
2620 /* Unsigned 32-bit attribute for holding the TID */
2621 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_TID,
2622 /* Unsigned 32-bit attribute for holding the update mask
2623 * bit 0 - Update high priority msdu qdepth threshold
2624 * bit 1 - Update low priority msdu qdepth threshold
2625 * bit 2 - Update UDP msdu qdepth threshold
2626 * bit 3 - Update Non UDP msdu qdepth threshold
2627 * rest of bits are reserved
2628 */
2629 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_UPDATE_MASK,
2630 /* Unsigned 32-bit attribute for holding the threshold value */
2631 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_VALUE,
2632
2633 /* keep last */
2634 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_LAST,
2635 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_MAX =
2636 QCA_WLAN_VENDOR_ATTR_QDEPTH_THRESH_LAST - 1,
2637};
2638
2639/**
Jouni Malinenf735abd2020-08-03 11:08:00 +03002640 * enum qca_acs_dfs_mode - Defines different types of DFS channel
2641 * configurations for ACS operation.
2642 *
2643 * @QCA_ACS_DFS_MODE_NONE: Refer to invalid DFS mode
2644 * @QCA_ACS_DFS_MODE_ENABLE: Consider DFS channels in ACS operation
2645 * @QCA_ACS_DFS_MODE_DISABLE: Do not consider DFS channels in ACS operation
2646 * @QCA_ACS_DFS_MODE_DEPRIORITIZE: Deprioritize DFS channels in ACS operation
2647 */
2648enum qca_acs_dfs_mode {
2649 QCA_ACS_DFS_MODE_NONE = 0,
2650 QCA_ACS_DFS_MODE_ENABLE = 1,
2651 QCA_ACS_DFS_MODE_DISABLE = 2,
2652 QCA_ACS_DFS_MODE_DEPRIORITIZE = 3,
2653};
2654
2655/**
2656 * enum qca_wlan_vendor_attr_acs_config - Defines Configuration attributes
2657 * used by the vendor command QCA_NL80211_VENDOR_SUBCMD_ACS_POLICY.
2658 *
2659 * @QCA_WLAN_VENDOR_ATTR_ACS_DFS_MODE: Required (u8)
2660 * DFS mode for ACS operation from enum qca_acs_dfs_mode.
2661 *
2662 * @QCA_WLAN_VENDOR_ATTR_ACS_CHANNEL_HINT: Required (u8)
2663 * channel number hint for ACS operation, if valid channel is specified then
2664 * ACS operation gives priority to this channel.
2665 * Note: If both the driver and user space application supports the 6 GHz band,
2666 * this attribute is deprecated and QCA_WLAN_VENDOR_ATTR_ACS_FREQUENCY_HINT
2667 * should be used.
2668 * To maintain backward compatibility, QCA_WLAN_VENDOR_ATTR_ACS_CHANNEL_HINT
2669 * is still used if either of the driver or user space application doesn't
2670 * support the 6 GHz band.
2671 *
2672 * @QCA_WLAN_VENDOR_ATTR_ACS_FREQUENCY_HINT: Required (u32).
2673 * Channel center frequency (MHz) hint for ACS operation, if a valid center
2674 * frequency is specified, ACS operation gives priority to this channel.
2675 */
2676enum qca_wlan_vendor_attr_acs_config {
2677 QCA_WLAN_VENDOR_ATTR_ACS_MODE_INVALID = 0,
2678 QCA_WLAN_VENDOR_ATTR_ACS_DFS_MODE = 1,
2679 QCA_WLAN_VENDOR_ATTR_ACS_CHANNEL_HINT = 2,
2680 QCA_WLAN_VENDOR_ATTR_ACS_FREQUENCY_HINT = 3,
2681
2682 QCA_WLAN_VENDOR_ATTR_ACS_DFS_AFTER_LAST,
2683 QCA_WLAN_VENDOR_ATTR_ACS_DFS_MAX =
2684 QCA_WLAN_VENDOR_ATTR_ACS_DFS_AFTER_LAST - 1,
2685};
2686
2687/**
Peng Xu291d97d2018-01-31 16:34:03 -08002688 * enum qca_wlan_vendor_attr_get_hw_capability - Wi-Fi hardware capability
2689 */
2690enum qca_wlan_vendor_attr_get_hw_capability {
2691 QCA_WLAN_VENDOR_ATTR_HW_CAPABILITY_INVALID,
2692 /* Antenna isolation
2693 * An attribute used in the response.
2694 * The content of this attribute is encoded in a byte array. Each byte
2695 * value is an antenna isolation value. The array length is the number
2696 * of antennas.
2697 */
2698 QCA_WLAN_VENDOR_ATTR_ANTENNA_ISOLATION,
2699 /* Request HW capability
2700 * An attribute used in the request.
2701 * The content of this attribute is a u32 array for one or more of
2702 * hardware capabilities (attribute IDs) that are being requested. Each
2703 * u32 value has a value from this
2704 * enum qca_wlan_vendor_attr_get_hw_capability
2705 * identifying which capabilities are requested.
2706 */
2707 QCA_WLAN_VENDOR_ATTR_GET_HW_CAPABILITY,
2708
2709 /* keep last */
2710 QCA_WLAN_VENDOR_ATTR_HW_CAPABILITY_AFTER_LAST,
2711 QCA_WLAN_VENDOR_ATTR_HW_CAPABILITY_MAX =
2712 QCA_WLAN_VENDOR_ATTR_HW_CAPABILITY_AFTER_LAST - 1,
2713};
2714
2715/**
2716 * enum qca_wlan_vendor_attr_ll_stats_ext - Attributes for MAC layer monitoring
2717 * offload which is an extension for LL_STATS.
2718 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_CFG_PERIOD: Monitoring period. Unit in ms.
2719 * If MAC counters do not exceed the threshold, FW will report monitored
2720 * link layer counters periodically as this setting. The first report is
2721 * always triggered by this timer.
2722 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_CFG_THRESHOLD: It is a percentage (1-99).
2723 * For each MAC layer counter, FW holds two copies. One is the current value.
2724 * The other is the last report. Once a current counter's increment is larger
2725 * than the threshold, FW will indicate that counter to host even if the
2726 * monitoring timer does not expire.
2727 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_CHG: Peer STA power state change
2728 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TID: TID of MSDU
2729 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_NUM_MSDU: Count of MSDU with the same
2730 * failure code.
2731 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_STATUS: TX failure code
2732 * 1: TX packet discarded
2733 * 2: No ACK
2734 * 3: Postpone
2735 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_MAC_ADDRESS: peer MAC address
2736 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_STATE: Peer STA current state
2737 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_GLOBAL: Global threshold.
2738 * Threshold for all monitored parameters. If per counter dedicated threshold
2739 * is not enabled, this threshold will take effect.
2740 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_EVENT_MODE: Indicate what triggers this
2741 * event, PERORID_TIMEOUT == 1, THRESH_EXCEED == 0.
2742 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IFACE_ID: interface ID
2743 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_ID: peer ID
2744 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_BITMAP: bitmap for TX counters
2745 * Bit0: TX counter unit in MSDU
2746 * Bit1: TX counter unit in MPDU
2747 * Bit2: TX counter unit in PPDU
2748 * Bit3: TX counter unit in byte
2749 * Bit4: Dropped MSDUs
2750 * Bit5: Dropped Bytes
2751 * Bit6: MPDU retry counter
2752 * Bit7: MPDU failure counter
2753 * Bit8: PPDU failure counter
2754 * Bit9: MPDU aggregation counter
2755 * Bit10: MCS counter for ACKed MPDUs
2756 * Bit11: MCS counter for Failed MPDUs
2757 * Bit12: TX Delay counter
2758 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_BITMAP: bitmap for RX counters
2759 * Bit0: MAC RX counter unit in MPDU
2760 * Bit1: MAC RX counter unit in byte
2761 * Bit2: PHY RX counter unit in PPDU
2762 * Bit3: PHY RX counter unit in byte
2763 * Bit4: Disorder counter
2764 * Bit5: Retry counter
2765 * Bit6: Duplication counter
2766 * Bit7: Discard counter
2767 * Bit8: MPDU aggregation size counter
2768 * Bit9: MCS counter
2769 * Bit10: Peer STA power state change (wake to sleep) counter
2770 * Bit11: Peer STA power save counter, total time in PS mode
2771 * Bit12: Probe request counter
2772 * Bit13: Other management frames counter
2773 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_CCA_BSS_BITMAP: bitmap for CCA
2774 * Bit0: Idle time
2775 * Bit1: TX time
2776 * Bit2: time RX in current bss
2777 * Bit3: Out of current bss time
2778 * Bit4: Wireless medium busy time
2779 * Bit5: RX in bad condition time
2780 * Bit6: TX in bad condition time
2781 * Bit7: time wlan card not available
2782 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_SIGNAL_BITMAP: bitmap for signal
2783 * Bit0: Per channel SNR counter
2784 * Bit1: Per channel noise floor counter
2785 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_NUM: number of peers
2786 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_CHANNEL_NUM: number of channels
2787 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_AC_RX_NUM: number of RX stats
2788 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_CCA_BSS: per channel BSS CCA stats
2789 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER: container for per PEER stats
2790 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_MSDU: Number of total TX MSDUs
2791 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_MPDU: Number of total TX MPDUs
2792 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_PPDU: Number of total TX PPDUs
2793 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_BYTES: bytes of TX data
2794 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_DROP: Number of dropped TX packets
2795 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_DROP_BYTES: Bytes dropped
2796 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_RETRY: waiting time without an ACK
2797 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_NO_ACK: number of MPDU not-ACKed
2798 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_NO_BACK: number of PPDU not-ACKed
2799 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_AGGR_NUM:
2800 * aggregation stats buffer length
2801 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_SUCC_MCS_NUM: length of mcs stats
2802 * buffer for ACKed MPDUs.
2803 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_FAIL_MCS_NUM: length of mcs stats
2804 * buffer for failed MPDUs.
2805 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_DELAY_ARRAY_SIZE:
2806 * length of delay stats array.
2807 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_AGGR: TX aggregation stats
2808 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_SUCC_MCS: MCS stats for ACKed MPDUs
2809 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_FAIL_MCS: MCS stats for failed MPDUs
2810 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_DELAY: tx delay stats
2811 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU: MPDUs received
2812 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_BYTES: bytes received
2813 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_PPDU: PPDU received
2814 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_PPDU_BYTES: PPDU bytes received
2815 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_LOST: packets lost
2816 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_RETRY: number of RX packets
2817 * flagged as retransmissions
2818 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_DUP: number of RX packets
2819 * flagged as duplicated
2820 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_DISCARD: number of RX
2821 * packets discarded
2822 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_AGGR_NUM: length of RX aggregation
2823 * stats buffer.
2824 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MCS_NUM: length of RX mcs
2825 * stats buffer.
2826 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MCS: RX mcs stats buffer
2827 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_AGGR: aggregation stats buffer
2828 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_TIMES: times STAs go to sleep
2829 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_DURATION: STAs' total sleep time
2830 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_PROBE_REQ: number of probe
2831 * requests received
2832 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MGMT: number of other mgmt
2833 * frames received
2834 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IDLE_TIME: Percentage of idle time
2835 * there is no TX, nor RX, nor interference.
2836 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_TIME: percentage of time
2837 * transmitting packets.
2838 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_TIME: percentage of time
2839 * for receiving.
2840 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_BUSY: percentage of time
2841 * interference detected.
2842 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_BAD: percentage of time
2843 * receiving packets with errors.
2844 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_BAD: percentage of time
2845 * TX no-ACK.
2846 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_NO_AVAIL: percentage of time
2847 * the chip is unable to work in normal conditions.
2848 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IN_BSS_TIME: percentage of time
2849 * receiving packets in current BSS.
2850 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_OUT_BSS_TIME: percentage of time
2851 * receiving packets not in current BSS.
2852 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_ANT_NUM: number of antennas
2853 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_SIGNAL:
2854 * This is a container for per antenna signal stats.
2855 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_ANT_SNR: per antenna SNR value
2856 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_ANT_NF: per antenna NF value
2857 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IFACE_RSSI_BEACON: RSSI of beacon
2858 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IFACE_SNR_BEACON: SNR of beacon
2859 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_REPORT_TIME: u64
2860 * Absolute timestamp from 1970/1/1, unit in ms. After receiving the
2861 * message, user layer APP could call gettimeofday to get another
2862 * timestamp and calculate transfer delay for the message.
2863 * @QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_MEASUREMENT_TIME: u32
2864 * Real period for this measurement, unit in us.
2865 */
2866enum qca_wlan_vendor_attr_ll_stats_ext {
2867 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_INVALID = 0,
2868
2869 /* Attributes for configurations */
2870 QCA_WLAN_VENDOR_ATTR_LL_STATS_CFG_PERIOD,
2871 QCA_WLAN_VENDOR_ATTR_LL_STATS_CFG_THRESHOLD,
2872
2873 /* Peer STA power state change */
2874 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_CHG,
2875
2876 /* TX failure event */
2877 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TID,
2878 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_NUM_MSDU,
2879 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_STATUS,
2880
2881 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_STATE,
2882 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_MAC_ADDRESS,
2883
2884 /* MAC counters */
2885 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_GLOBAL,
2886 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_EVENT_MODE,
2887 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IFACE_ID,
2888 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_ID,
2889 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_BITMAP,
2890 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_BITMAP,
2891 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_CCA_BSS_BITMAP,
2892 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_SIGNAL_BITMAP,
2893 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_NUM,
2894 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_CHANNEL_NUM,
2895 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_CCA_BSS,
2896 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER,
2897
2898 /* Sub-attributes for PEER_AC_TX */
2899 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_MSDU,
2900 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_MPDU,
2901 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_PPDU,
2902 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_BYTES,
2903 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_DROP,
2904 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_DROP_BYTES,
2905 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_RETRY,
2906 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_NO_ACK,
2907 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_NO_BACK,
2908 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_AGGR_NUM,
2909 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_SUCC_MCS_NUM,
2910 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_FAIL_MCS_NUM,
2911 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_AGGR,
2912 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_SUCC_MCS,
2913 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_FAIL_MCS,
2914 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_DELAY_ARRAY_SIZE,
2915 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_DELAY,
2916
2917 /* Sub-attributes for PEER_AC_RX */
2918 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU,
2919 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_BYTES,
2920 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_PPDU,
2921 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_PPDU_BYTES,
2922 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_LOST,
2923 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_RETRY,
2924 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_DUP,
2925 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU_DISCARD,
2926 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_AGGR_NUM,
2927 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MCS_NUM,
2928 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MCS,
2929 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_AGGR,
2930 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_TIMES,
2931 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_PS_DURATION,
2932 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_PROBE_REQ,
2933 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MGMT,
2934
2935 /* Sub-attributes for CCA_BSS */
2936 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IDLE_TIME,
2937 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_TIME,
2938 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_TIME,
2939 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_BUSY,
2940 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_BAD,
2941 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_BAD,
2942 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_NO_AVAIL,
2943
2944 /* sub-attribute for BSS_RX_TIME */
2945 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IN_BSS_TIME,
2946 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_OUT_BSS_TIME,
2947
2948 /* Sub-attributes for PEER_SIGNAL */
2949 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_ANT_NUM,
2950 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_SIGNAL,
2951 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_ANT_SNR,
2952 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_ANT_NF,
2953
2954 /* Sub-attributes for IFACE_BSS */
2955 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IFACE_RSSI_BEACON,
2956 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_IFACE_SNR_BEACON,
2957
2958 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_REPORT_TIME,
2959 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_MEASUREMENT_TIME,
2960
2961 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_LAST,
2962 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_MAX =
2963 QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_LAST - 1
2964};
2965
2966/* Attributes for FTM commands and events */
2967
2968/**
2969 * enum qca_wlan_vendor_attr_loc_capa - Indoor location capabilities
2970 *
2971 * @QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAGS: Various flags. See
2972 * enum qca_wlan_vendor_attr_loc_capa_flags.
2973 * @QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_NUM_SESSIONS: Maximum number
2974 * of measurement sessions that can run concurrently.
2975 * Default is one session (no session concurrency).
2976 * @QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_NUM_PEERS: The total number of unique
2977 * peers that are supported in running sessions. For example,
2978 * if the value is 8 and maximum number of sessions is 2, you can
2979 * have one session with 8 unique peers, or 2 sessions with 4 unique
2980 * peers each, and so on.
2981 * @QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_NUM_BURSTS_EXP: Maximum number
2982 * of bursts per peer, as an exponent (2^value). Default is 0,
2983 * meaning no multi-burst support.
2984 * @QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_MEAS_PER_BURST: Maximum number
2985 * of measurement exchanges allowed in a single burst.
2986 * @QCA_WLAN_VENDOR_ATTR_AOA_CAPA_SUPPORTED_TYPES: Supported AOA measurement
2987 * types. A bit mask (unsigned 32 bit value), each bit corresponds
2988 * to an AOA type as defined by enum qca_vendor_attr_aoa_type.
2989 */
2990enum qca_wlan_vendor_attr_loc_capa {
2991 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_INVALID,
2992 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAGS,
2993 QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_NUM_SESSIONS,
2994 QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_NUM_PEERS,
2995 QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_NUM_BURSTS_EXP,
2996 QCA_WLAN_VENDOR_ATTR_FTM_CAPA_MAX_MEAS_PER_BURST,
2997 QCA_WLAN_VENDOR_ATTR_AOA_CAPA_SUPPORTED_TYPES,
2998 /* keep last */
2999 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_AFTER_LAST,
3000 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_MAX =
3001 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_AFTER_LAST - 1,
3002};
3003
3004/**
3005 * enum qca_wlan_vendor_attr_loc_capa_flags: Indoor location capability flags
3006 *
3007 * @QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_FTM_RESPONDER: Set if driver
3008 * can be configured as an FTM responder (for example, an AP that
3009 * services FTM requests). QCA_NL80211_VENDOR_SUBCMD_FTM_CFG_RESPONDER
3010 * will be supported if set.
3011 * @QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_FTM_INITIATOR: Set if driver
3012 * can run FTM sessions. QCA_NL80211_VENDOR_SUBCMD_FTM_START_SESSION
3013 * will be supported if set.
Arif Hussaine2645c62018-05-24 20:39:04 -07003014 * @QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_ASAP: Set if FTM responder
Peng Xu291d97d2018-01-31 16:34:03 -08003015 * supports immediate (ASAP) response.
3016 * @QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_AOA: Set if driver supports standalone
3017 * AOA measurement using QCA_NL80211_VENDOR_SUBCMD_AOA_MEAS.
3018 * @QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_AOA_IN_FTM: Set if driver supports
3019 * requesting AOA measurements as part of an FTM session.
3020 */
3021enum qca_wlan_vendor_attr_loc_capa_flags {
3022 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_FTM_RESPONDER = 1 << 0,
3023 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_FTM_INITIATOR = 1 << 1,
3024 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_ASAP = 1 << 2,
3025 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_AOA = 1 << 3,
3026 QCA_WLAN_VENDOR_ATTR_LOC_CAPA_FLAG_AOA_IN_FTM = 1 << 4,
3027};
3028
3029/**
3030 * enum qca_wlan_vendor_attr_ftm_peer_info: Information about
3031 * a single peer in a measurement session.
3032 *
3033 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_MAC_ADDR: The MAC address of the peer.
3034 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAGS: Various flags related
3035 * to measurement. See enum qca_wlan_vendor_attr_ftm_peer_meas_flags.
3036 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_PARAMS: Nested attribute of
3037 * FTM measurement parameters, as specified by IEEE P802.11-REVmc/D7.0
3038 * 9.4.2.167. See enum qca_wlan_vendor_attr_ftm_meas_param for
3039 * list of supported attributes.
3040 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_SECURE_TOKEN_ID: Initial token ID for
3041 * secure measurement.
3042 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_AOA_BURST_PERIOD: Request AOA
3043 * measurement every <value> bursts. If 0 or not specified,
3044 * AOA measurements will be disabled for this peer.
3045 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_FREQ: Frequency in MHz where
3046 * the measurement frames are exchanged. Optional; if not
3047 * specified, try to locate the peer in the kernel scan
3048 * results cache and use frequency from there.
3049 */
3050enum qca_wlan_vendor_attr_ftm_peer_info {
3051 QCA_WLAN_VENDOR_ATTR_FTM_PEER_INVALID,
3052 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MAC_ADDR,
3053 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAGS,
3054 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_PARAMS,
3055 QCA_WLAN_VENDOR_ATTR_FTM_PEER_SECURE_TOKEN_ID,
3056 QCA_WLAN_VENDOR_ATTR_FTM_PEER_AOA_BURST_PERIOD,
3057 QCA_WLAN_VENDOR_ATTR_FTM_PEER_FREQ,
3058 /* keep last */
3059 QCA_WLAN_VENDOR_ATTR_FTM_PEER_AFTER_LAST,
3060 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MAX =
3061 QCA_WLAN_VENDOR_ATTR_FTM_PEER_AFTER_LAST - 1,
3062};
3063
3064/**
3065 * enum qca_wlan_vendor_attr_ftm_peer_meas_flags: Measurement request flags,
3066 * per-peer
3067 *
3068 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_ASAP: If set, request
3069 * immediate (ASAP) response from peer.
3070 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_LCI: If set, request
3071 * LCI report from peer. The LCI report includes the absolute
3072 * location of the peer in "official" coordinates (similar to GPS).
3073 * See IEEE P802.11-REVmc/D7.0, 11.24.6.7 for more information.
3074 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_LCR: If set, request
3075 * Location civic report from peer. The LCR includes the location
3076 * of the peer in free-form format. See IEEE P802.11-REVmc/D7.0,
3077 * 11.24.6.7 for more information.
3078 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_SECURE: If set,
3079 * request a secure measurement.
3080 * QCA_WLAN_VENDOR_ATTR_FTM_PEER_SECURE_TOKEN_ID must also be provided.
3081 */
3082enum qca_wlan_vendor_attr_ftm_peer_meas_flags {
3083 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_ASAP = 1 << 0,
3084 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_LCI = 1 << 1,
3085 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_LCR = 1 << 2,
3086 QCA_WLAN_VENDOR_ATTR_FTM_PEER_MEAS_FLAG_SECURE = 1 << 3,
3087};
3088
3089/**
3090 * enum qca_wlan_vendor_attr_ftm_meas_param: Measurement parameters
3091 *
3092 * @QCA_WLAN_VENDOR_ATTR_FTM_PARAM_MEAS_PER_BURST: Number of measurements
3093 * to perform in a single burst.
3094 * @QCA_WLAN_VENDOR_ATTR_FTM_PARAM_NUM_BURSTS_EXP: Number of bursts to
3095 * perform, specified as an exponent (2^value).
3096 * @QCA_WLAN_VENDOR_ATTR_FTM_PARAM_BURST_DURATION: Duration of burst
3097 * instance, as specified in IEEE P802.11-REVmc/D7.0, 9.4.2.167.
3098 * @QCA_WLAN_VENDOR_ATTR_FTM_PARAM_BURST_PERIOD: Time between bursts,
3099 * as specified in IEEE P802.11-REVmc/D7.0, 9.4.2.167. Must
3100 * be larger than QCA_WLAN_VENDOR_ATTR_FTM_PARAM_BURST_DURATION.
3101 */
3102enum qca_wlan_vendor_attr_ftm_meas_param {
3103 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_INVALID,
3104 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_MEAS_PER_BURST,
3105 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_NUM_BURSTS_EXP,
3106 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_BURST_DURATION,
3107 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_BURST_PERIOD,
3108 /* keep last */
3109 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_AFTER_LAST,
3110 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_MAX =
3111 QCA_WLAN_VENDOR_ATTR_FTM_PARAM_AFTER_LAST - 1,
3112};
3113
3114/**
3115 * enum qca_wlan_vendor_attr_ftm_peer_result: Per-peer results
3116 *
3117 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MAC_ADDR: MAC address of the reported
3118 * peer.
3119 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS: Status of measurement
3120 * request for this peer.
3121 * See enum qca_wlan_vendor_attr_ftm_peer_result_status.
3122 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_FLAGS: Various flags related
3123 * to measurement results for this peer.
3124 * See enum qca_wlan_vendor_attr_ftm_peer_result_flags.
3125 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_VALUE_SECONDS: Specified when
3126 * request failed and peer requested not to send an additional request
3127 * for this number of seconds.
3128 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_LCI: LCI report when received
3129 * from peer. In the format specified by IEEE P802.11-REVmc/D7.0,
3130 * 9.4.2.22.10.
3131 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_LCR: Location civic report when
3132 * received from peer. In the format specified by IEEE P802.11-REVmc/D7.0,
3133 * 9.4.2.22.13.
3134 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MEAS_PARAMS: Reported when peer
3135 * overridden some measurement request parameters. See
3136 * enum qca_wlan_vendor_attr_ftm_meas_param.
3137 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_AOA_MEAS: AOA measurement
3138 * for this peer. Same contents as @QCA_WLAN_VENDOR_ATTR_AOA_MEAS_RESULT.
3139 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MEAS: Array of measurement
3140 * results. Each entry is a nested attribute defined
3141 * by enum qca_wlan_vendor_attr_ftm_meas.
3142 */
3143enum qca_wlan_vendor_attr_ftm_peer_result {
3144 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_INVALID,
3145 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MAC_ADDR,
3146 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS,
3147 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_FLAGS,
3148 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_VALUE_SECONDS,
3149 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_LCI,
3150 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_LCR,
3151 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MEAS_PARAMS,
3152 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_AOA_MEAS,
3153 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MEAS,
3154 /* keep last */
3155 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_AFTER_LAST,
3156 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MAX =
3157 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_AFTER_LAST - 1,
3158};
3159
3160/**
3161 * enum qca_wlan_vendor_attr_ftm_peer_result_status
3162 *
3163 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_OK: Request sent ok and results
3164 * will be provided. Peer may have overridden some measurement parameters,
3165 * in which case overridden parameters will be report by
3166 * QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_MEAS_PARAM attribute.
3167 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_INCAPABLE: Peer is incapable
3168 * of performing the measurement request. No more results will be sent
3169 * for this peer in this session.
3170 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_FAILED: Peer reported request
3171 * failed, and requested not to send an additional request for number
3172 * of seconds specified by QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_VALUE_SECONDS
3173 * attribute.
3174 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_INVALID: Request validation
3175 * failed. Request was not sent over the air.
3176 */
3177enum qca_wlan_vendor_attr_ftm_peer_result_status {
3178 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_OK,
3179 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_INCAPABLE,
3180 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_FAILED,
3181 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_STATUS_INVALID,
3182};
3183
3184/**
3185 * enum qca_wlan_vendor_attr_ftm_peer_result_flags: Various flags
3186 * for measurement result, per-peer
3187 *
3188 * @QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_FLAG_DONE: If set,
3189 * measurement completed for this peer. No more results will be reported
3190 * for this peer in this session.
3191 */
3192enum qca_wlan_vendor_attr_ftm_peer_result_flags {
3193 QCA_WLAN_VENDOR_ATTR_FTM_PEER_RES_FLAG_DONE = 1 << 0,
3194};
3195
3196/**
3197 * enum qca_vendor_attr_loc_session_status: Session completion status code
3198 *
3199 * @QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_OK: Session completed
3200 * successfully.
3201 * @QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_ABORTED: Session aborted
3202 * by request.
3203 * @QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_INVALID: Session request
3204 * was invalid and was not started.
3205 * @QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_FAILED: Session had an error
3206 * and did not complete normally (for example out of resources).
3207 */
3208enum qca_vendor_attr_loc_session_status {
3209 QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_OK,
3210 QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_ABORTED,
3211 QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_INVALID,
3212 QCA_WLAN_VENDOR_ATTR_LOC_SESSION_STATUS_FAILED,
3213};
3214
3215/**
3216 * enum qca_wlan_vendor_attr_ftm_meas: Single measurement data
3217 *
3218 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T1: Time of departure (TOD) of FTM packet as
3219 * recorded by responder, in picoseconds.
3220 * See IEEE P802.11-REVmc/D7.0, 11.24.6.4 for more information.
3221 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T2: Time of arrival (TOA) of FTM packet at
3222 * initiator, in picoseconds.
3223 * See IEEE P802.11-REVmc/D7.0, 11.24.6.4 for more information.
3224 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T3: TOD of ACK packet as recorded by
3225 * initiator, in picoseconds.
3226 * See IEEE P802.11-REVmc/D7.0, 11.24.6.4 for more information.
3227 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T4: TOA of ACK packet at
3228 * responder, in picoseconds.
3229 * See IEEE P802.11-REVmc/D7.0, 11.24.6.4 for more information.
3230 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_RSSI: RSSI (signal level) as recorded
3231 * during this measurement exchange. Optional and will be provided if
3232 * the hardware can measure it.
3233 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_TOD_ERR: TOD error reported by
3234 * responder. Not always provided.
3235 * See IEEE P802.11-REVmc/D7.0, 9.6.8.33 for more information.
3236 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_TOA_ERR: TOA error reported by
3237 * responder. Not always provided.
3238 * See IEEE P802.11-REVmc/D7.0, 9.6.8.33 for more information.
3239 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_INITIATOR_TOD_ERR: TOD error measured by
3240 * initiator. Not always provided.
3241 * See IEEE P802.11-REVmc/D7.0, 9.6.8.33 for more information.
3242 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_INITIATOR_TOA_ERR: TOA error measured by
3243 * initiator. Not always provided.
3244 * See IEEE P802.11-REVmc/D7.0, 9.6.8.33 for more information.
3245 * @QCA_WLAN_VENDOR_ATTR_FTM_MEAS_PAD: Dummy attribute for padding.
3246 */
3247enum qca_wlan_vendor_attr_ftm_meas {
3248 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_INVALID,
3249 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T1,
3250 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T2,
3251 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T3,
3252 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_T4,
3253 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_RSSI,
3254 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_TOD_ERR,
3255 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_TOA_ERR,
3256 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_INITIATOR_TOD_ERR,
3257 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_INITIATOR_TOA_ERR,
3258 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_PAD,
3259 /* keep last */
3260 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_AFTER_LAST,
3261 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_MAX =
3262 QCA_WLAN_VENDOR_ATTR_FTM_MEAS_AFTER_LAST - 1,
3263};
3264
3265/**
3266 * enum qca_wlan_vendor_attr_aoa_type - AOA measurement type
3267 *
3268 * @QCA_WLAN_VENDOR_ATTR_AOA_TYPE_TOP_CIR_PHASE: Phase of the strongest
3269 * CIR (channel impulse response) path for each antenna.
3270 * @QCA_WLAN_VENDOR_ATTR_AOA_TYPE_TOP_CIR_PHASE_AMP: Phase and amplitude
3271 * of the strongest CIR path for each antenna.
3272 */
3273enum qca_wlan_vendor_attr_aoa_type {
3274 QCA_WLAN_VENDOR_ATTR_AOA_TYPE_TOP_CIR_PHASE,
3275 QCA_WLAN_VENDOR_ATTR_AOA_TYPE_TOP_CIR_PHASE_AMP,
3276 QCA_WLAN_VENDOR_ATTR_AOA_TYPE_MAX
3277};
3278
3279/**
3280 * enum qca_wlan_vendor_attr_encryption_test - Attributes to
3281 * validate encryption engine
3282 *
3283 * @QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_NEEDS_DECRYPTION: Flag attribute.
3284 * This will be included if the request is for decryption; if not included,
3285 * the request is treated as a request for encryption by default.
3286 * @QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_CIPHER: Unsigned 32-bit value
3287 * indicating the key cipher suite. Takes same values as
3288 * NL80211_ATTR_KEY_CIPHER.
3289 * @QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_KEYID: Unsigned 8-bit value
3290 * Key Id to be used for encryption
3291 * @QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_TK: Array of 8-bit values.
3292 * Key (TK) to be used for encryption/decryption
3293 * @QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_PN: Array of 8-bit values.
3294 * Packet number to be specified for encryption/decryption
3295 * 6 bytes for TKIP/CCMP/GCMP.
3296 * @QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_DATA: Array of 8-bit values
3297 * representing the 802.11 packet (header + payload + FCS) that
3298 * needs to be encrypted/decrypted.
3299 * Encrypted/decrypted response from the driver will also be sent
3300 * to userspace with the same attribute.
3301 */
3302enum qca_wlan_vendor_attr_encryption_test {
3303 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_INVALID = 0,
3304 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_NEEDS_DECRYPTION,
3305 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_CIPHER,
3306 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_KEYID,
3307 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_TK,
3308 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_PN,
3309 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_DATA,
3310
3311 /* keep last */
3312 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_AFTER_LAST,
3313 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_MAX =
3314 QCA_WLAN_VENDOR_ATTR_ENCRYPTION_TEST_AFTER_LAST - 1
3315};
3316
3317/**
3318 * enum qca_wlan_vendor_attr_dmg_rf_sector_type - Type of
3319 * sector for DMG RF sector operations.
3320 *
3321 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE_RX: RX sector
3322 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE_TX: TX sector
3323 */
3324enum qca_wlan_vendor_attr_dmg_rf_sector_type {
3325 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE_RX,
3326 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE_TX,
3327 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_TYPE_MAX
3328};
3329
3330/**
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08003331 * enum qca_wlan_vendor_attr_fw_state - State of firmware
3332 *
3333 * @QCA_WLAN_VENDOR_ATTR_FW_STATE_ERROR: FW is in bad state
3334 * @QCA_WLAN_VENDOR_ATTR_FW_STATE_ACTIVE: FW is active
3335 */
3336enum qca_wlan_vendor_attr_fw_state {
3337 QCA_WLAN_VENDOR_ATTR_FW_STATE_ERROR,
3338 QCA_WLAN_VENDOR_ATTR_FW_STATE_ACTIVE,
3339 QCA_WLAN_VENDOR_ATTR_FW_STATE_MAX
3340};
3341
3342/**
Peng Xu291d97d2018-01-31 16:34:03 -08003343 * BRP antenna limit mode
3344 *
3345 * @QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE_DISABLE: Disable BRP force
3346 * antenna limit, BRP will be performed as usual.
3347 * @QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE_EFFECTIVE: Define maximal
3348 * antennas limit. the hardware may use less antennas than the
3349 * maximum limit.
3350 * @QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE_FORCE: The hardware will
3351 * use exactly the specified number of antennas for BRP.
3352 */
3353enum qca_wlan_vendor_attr_brp_ant_limit_mode {
3354 QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE_DISABLE,
3355 QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE_EFFECTIVE,
3356 QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE_FORCE,
3357 QCA_WLAN_VENDOR_ATTR_BRP_ANT_LIMIT_MODE_MAX
3358};
3359
3360/**
3361 * enum qca_wlan_vendor_attr_dmg_rf_sector_cfg - Attributes for
3362 * DMG RF sector configuration for a single RF module.
3363 * The values are defined in a compact way which closely matches
3364 * the way it is stored in HW registers.
3365 * The configuration provides values for 32 antennas and 8 distribution
3366 * amplifiers, and together describes the characteristics of the RF
3367 * sector - such as a beam in some direction with some gain.
3368 *
3369 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_MODULE_INDEX: Index
3370 * of RF module for this configuration.
3371 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_ETYPE0: Bit 0 of edge
3372 * amplifier gain index. Unsigned 32 bit number containing
3373 * bits for all 32 antennas.
3374 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_ETYPE1: Bit 1 of edge
3375 * amplifier gain index. Unsigned 32 bit number containing
3376 * bits for all 32 antennas.
3377 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_ETYPE2: Bit 2 of edge
3378 * amplifier gain index. Unsigned 32 bit number containing
3379 * bits for all 32 antennas.
3380 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_PSH_HI: Phase values
3381 * for first 16 antennas, 2 bits per antenna.
3382 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_PSH_LO: Phase values
3383 * for last 16 antennas, 2 bits per antenna.
3384 * @QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_DTYPE_X16: Contains
3385 * DTYPE values (3 bits) for each distribution amplifier, followed
3386 * by X16 switch bits for each distribution amplifier. There are
3387 * total of 8 distribution amplifiers.
3388 */
3389enum qca_wlan_vendor_attr_dmg_rf_sector_cfg {
3390 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_INVALID = 0,
3391 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_MODULE_INDEX = 1,
3392 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_ETYPE0 = 2,
3393 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_ETYPE1 = 3,
3394 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_ETYPE2 = 4,
3395 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_PSH_HI = 5,
3396 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_PSH_LO = 6,
3397 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_DTYPE_X16 = 7,
3398
3399 /* keep last */
3400 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_AFTER_LAST,
3401 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_MAX =
3402 QCA_WLAN_VENDOR_ATTR_DMG_RF_SECTOR_CFG_AFTER_LAST - 1
3403};
3404
3405enum qca_wlan_vendor_attr_ll_stats_set {
3406 QCA_WLAN_VENDOR_ATTR_LL_STATS_SET_INVALID = 0,
3407 /* Unsigned 32-bit value */
3408 QCA_WLAN_VENDOR_ATTR_LL_STATS_SET_CONFIG_MPDU_SIZE_THRESHOLD = 1,
3409 QCA_WLAN_VENDOR_ATTR_LL_STATS_SET_CONFIG_AGGRESSIVE_STATS_GATHERING = 2,
3410 /* keep last */
3411 QCA_WLAN_VENDOR_ATTR_LL_STATS_SET_AFTER_LAST,
3412 QCA_WLAN_VENDOR_ATTR_LL_STATS_SET_MAX =
3413 QCA_WLAN_VENDOR_ATTR_LL_STATS_SET_AFTER_LAST - 1,
3414};
3415
3416enum qca_wlan_vendor_attr_ll_stats_clr {
3417 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_INVALID = 0,
3418 /* Unsigned 32bit bitmap for clearing statistics
3419 * All radio statistics 0x00000001
3420 * cca_busy_time (within radio statistics) 0x00000002
3421 * All channel stats (within radio statistics) 0x00000004
3422 * All scan statistics (within radio statistics) 0x00000008
3423 * All interface statistics 0x00000010
3424 * All tx rate statistics (within interface statistics) 0x00000020
3425 * All ac statistics (with in interface statistics) 0x00000040
3426 * All contention (min, max, avg) statistics (within ac statisctics)
3427 * 0x00000080.
3428 */
3429 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_CONFIG_REQ_MASK = 1,
3430 /* Unsigned 8 bit value: Request to stop statistics collection */
3431 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_CONFIG_STOP_REQ = 2,
3432
3433 /* Unsigned 32 bit bitmap: Response from the driver
3434 * for the cleared statistics
3435 */
3436 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_CONFIG_RSP_MASK = 3,
3437 /* Unsigned 8 bit value: Response from driver/firmware
3438 * for the stop request
3439 */
3440 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_CONFIG_STOP_RSP = 4,
3441 /* keep last */
3442 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_AFTER_LAST,
3443 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_MAX =
3444 QCA_WLAN_VENDOR_ATTR_LL_STATS_CLR_AFTER_LAST - 1,
3445};
3446
3447enum qca_wlan_vendor_attr_ll_stats_get {
3448 QCA_WLAN_VENDOR_ATTR_LL_STATS_GET_INVALID = 0,
3449 /* Unsigned 32 bit value provided by the caller issuing the GET stats
3450 * command. When reporting the stats results, the driver uses the same
3451 * value to indicate which GET request the results correspond to.
3452 */
3453 QCA_WLAN_VENDOR_ATTR_LL_STATS_GET_CONFIG_REQ_ID = 1,
3454 /* Unsigned 32 bit value - bit mask to identify what statistics are
3455 * requested for retrieval.
3456 * Radio Statistics 0x00000001
3457 * Interface Statistics 0x00000020
3458 * All Peer Statistics 0x00000040
3459 * Peer Statistics 0x00000080
3460 */
3461 QCA_WLAN_VENDOR_ATTR_LL_STATS_GET_CONFIG_REQ_MASK = 2,
3462 /* keep last */
3463 QCA_WLAN_VENDOR_ATTR_LL_STATS_GET_AFTER_LAST,
3464 QCA_WLAN_VENDOR_ATTR_LL_STATS_GET_MAX =
3465 QCA_WLAN_VENDOR_ATTR_LL_STATS_GET_AFTER_LAST - 1,
3466};
3467
3468enum qca_wlan_vendor_attr_ll_stats_results {
3469 QCA_WLAN_VENDOR_ATTR_LL_STATS_INVALID = 0,
3470 /* Unsigned 32bit value. Used by the driver; must match the request id
3471 * provided with the QCA_NL80211_VENDOR_SUBCMD_LL_STATS_GET command.
3472 */
3473 QCA_WLAN_VENDOR_ATTR_LL_STATS_RESULTS_REQ_ID = 1,
3474
3475 /* Unsigned 32 bit value */
3476 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_BEACON_RX = 2,
3477 /* Unsigned 32 bit value */
3478 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_MGMT_RX = 3,
3479 /* Unsigned 32 bit value */
3480 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_MGMT_ACTION_RX = 4,
3481 /* Unsigned 32 bit value */
3482 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_MGMT_ACTION_TX = 5,
3483 /* Signed 32 bit value */
3484 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_RSSI_MGMT = 6,
3485 /* Signed 32 bit value */
3486 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_RSSI_DATA = 7,
3487 /* Signed 32 bit value */
3488 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_RSSI_ACK = 8,
3489
3490 /* Attributes of type QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_* are
3491 * nested within the interface stats.
3492 */
3493
3494 /* Interface mode, e.g., STA, SOFTAP, IBSS, etc.
3495 * Type = enum wifi_interface_mode.
3496 */
3497 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_MODE = 9,
3498 /* Interface MAC address. An array of 6 Unsigned int8 */
3499 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_MAC_ADDR = 10,
3500 /* Type = enum wifi_connection_state, e.g., DISCONNECTED,
3501 * AUTHENTICATING, etc. valid for STA, CLI only.
3502 */
3503 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_STATE = 11,
3504 /* Type = enum wifi_roam_state. Roaming state, e.g., IDLE or ACTIVE
3505 */
3506 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_ROAMING = 12,
3507 /* Unsigned 32 bit value. WIFI_CAPABILITY_XXX */
3508 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_CAPABILITIES = 13,
3509 /* NULL terminated SSID. An array of 33 Unsigned 8bit values */
3510 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_SSID = 14,
3511 /* BSSID. An array of 6 unsigned 8 bit values */
3512 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_BSSID = 15,
3513 /* Country string advertised by AP. An array of 3 unsigned 8 bit
3514 * values.
3515 */
3516 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_AP_COUNTRY_STR = 16,
3517 /* Country string for this association. An array of 3 unsigned 8 bit
3518 * values.
3519 */
3520 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_INFO_COUNTRY_STR = 17,
3521
3522 /* Attributes of type QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_* could
3523 * be nested within the interface stats.
3524 */
3525
3526 /* Type = enum wifi_traffic_ac, e.g., V0, VI, BE and BK */
3527 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_AC = 18,
3528 /* Unsigned int 32 value corresponding to respective AC */
3529 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_TX_MPDU = 19,
3530 /* Unsigned int 32 value corresponding to respective AC */
3531 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_RX_MPDU = 20,
3532 /* Unsigned int 32 value corresponding to respective AC */
3533 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_TX_MCAST = 21,
3534 /* Unsigned int 32 value corresponding to respective AC */
3535 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_RX_MCAST = 22,
3536 /* Unsigned int 32 value corresponding to respective AC */
3537 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_RX_AMPDU = 23,
3538 /* Unsigned int 32 value corresponding to respective AC */
3539 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_TX_AMPDU = 24,
3540 /* Unsigned int 32 value corresponding to respective AC */
3541 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_MPDU_LOST = 25,
3542 /* Unsigned int 32 value corresponding to respective AC */
3543 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_RETRIES = 26,
3544 /* Unsigned int 32 value corresponding to respective AC */
3545 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_RETRIES_SHORT = 27,
3546 /* Unsigned int 32 values corresponding to respective AC */
3547 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_RETRIES_LONG = 28,
3548 /* Unsigned int 32 values corresponding to respective AC */
3549 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_CONTENTION_TIME_MIN = 29,
3550 /* Unsigned int 32 values corresponding to respective AC */
3551 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_CONTENTION_TIME_MAX = 30,
3552 /* Unsigned int 32 values corresponding to respective AC */
3553 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_CONTENTION_TIME_AVG = 31,
3554 /* Unsigned int 32 values corresponding to respective AC */
3555 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_CONTENTION_NUM_SAMPLES = 32,
3556 /* Unsigned 32 bit value. Number of peers */
3557 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_NUM_PEERS = 33,
3558
3559 /* Attributes of type QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO_* are
3560 * nested within the interface stats.
3561 */
3562
3563 /* Type = enum wifi_peer_type. Peer type, e.g., STA, AP, P2P GO etc. */
3564 QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO_TYPE = 34,
3565 /* MAC addr corresponding to respective peer. An array of 6 unsigned
3566 * 8 bit values.
3567 */
3568 QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO_MAC_ADDRESS = 35,
3569 /* Unsigned int 32 bit value representing capabilities corresponding
3570 * to respective peer.
3571 */
3572 QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO_CAPABILITIES = 36,
3573 /* Unsigned 32 bit value. Number of rates */
3574 QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO_NUM_RATES = 37,
3575
3576 /* Attributes of type QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_*
3577 * are nested within the rate stat.
3578 */
3579
3580 /* Wi-Fi Rate - separate attributes defined for individual fields */
3581
3582 /* Unsigned int 8 bit value; 0: OFDM, 1:CCK, 2:HT 3:VHT 4..7 reserved */
3583 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_PREAMBLE = 38,
3584 /* Unsigned int 8 bit value; 0:1x1, 1:2x2, 3:3x3, 4:4x4 */
3585 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_NSS = 39,
3586 /* Unsigned int 8 bit value; 0:20 MHz, 1:40 MHz, 2:80 MHz, 3:160 MHz */
3587 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_BW = 40,
3588 /* Unsigned int 8 bit value; OFDM/CCK rate code would be as per IEEE Std
Arif Hussaine2645c62018-05-24 20:39:04 -07003589 * in the units of 0.5 Mbps HT/VHT it would be MCS index
3590 */
Peng Xu291d97d2018-01-31 16:34:03 -08003591 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_MCS_INDEX = 41,
3592
3593 /* Unsigned 32 bit value. Bit rate in units of 100 kbps */
3594 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_BIT_RATE = 42,
3595
Peng Xu291d97d2018-01-31 16:34:03 -08003596 /* Attributes of type QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_STAT_* could be
3597 * nested within the peer info stats.
3598 */
3599
3600 /* Unsigned int 32 bit value. Number of successfully transmitted data
3601 * packets, i.e., with ACK received corresponding to the respective
3602 * rate.
3603 */
3604 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_TX_MPDU = 43,
3605 /* Unsigned int 32 bit value. Number of received data packets
3606 * corresponding to the respective rate.
3607 */
3608 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_RX_MPDU = 44,
3609 /* Unsigned int 32 bit value. Number of data packet losses, i.e., no ACK
3610 * received corresponding to the respective rate.
3611 */
3612 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_MPDU_LOST = 45,
3613 /* Unsigned int 32 bit value. Total number of data packet retries for
3614 * the respective rate.
3615 */
3616 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_RETRIES = 46,
3617 /* Unsigned int 32 bit value. Total number of short data packet retries
3618 * for the respective rate.
3619 */
3620 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_RETRIES_SHORT = 47,
3621 /* Unsigned int 32 bit value. Total number of long data packet retries
3622 * for the respective rate.
3623 */
3624 QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_RETRIES_LONG = 48,
3625
3626 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ID = 49,
3627 /* Unsigned 32 bit value. Total number of msecs the radio is awake
3628 * accruing over time.
3629 */
3630 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ON_TIME = 50,
3631 /* Unsigned 32 bit value. Total number of msecs the radio is
3632 * transmitting accruing over time.
3633 */
3634 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_TX_TIME = 51,
3635 /* Unsigned 32 bit value. Total number of msecs the radio is in active
3636 * receive accruing over time.
3637 */
3638 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_RX_TIME = 52,
3639 /* Unsigned 32 bit value. Total number of msecs the radio is awake due
3640 * to all scan accruing over time.
3641 */
3642 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ON_TIME_SCAN = 53,
3643 /* Unsigned 32 bit value. Total number of msecs the radio is awake due
3644 * to NAN accruing over time.
3645 */
3646 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ON_TIME_NBD = 54,
3647 /* Unsigned 32 bit value. Total number of msecs the radio is awake due
3648 * to GSCAN accruing over time.
3649 */
3650 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ON_TIME_GSCAN = 55,
3651 /* Unsigned 32 bit value. Total number of msecs the radio is awake due
3652 * to roam scan accruing over time.
3653 */
3654 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ON_TIME_ROAM_SCAN = 56,
3655 /* Unsigned 32 bit value. Total number of msecs the radio is awake due
3656 * to PNO scan accruing over time.
3657 */
3658 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ON_TIME_PNO_SCAN = 57,
3659 /* Unsigned 32 bit value. Total number of msecs the radio is awake due
3660 * to Hotspot 2.0 scans and GAS exchange accruing over time.
3661 */
3662 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_ON_TIME_HS20 = 58,
3663 /* Unsigned 32 bit value. Number of channels. */
3664 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_NUM_CHANNELS = 59,
3665
3666 /* Attributes of type QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_INFO_* could
3667 * be nested within the channel stats.
3668 */
3669
3670 /* Type = enum wifi_channel_width. Channel width, e.g., 20, 40, 80 */
3671 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_INFO_WIDTH = 60,
3672 /* Unsigned 32 bit value. Primary 20 MHz channel. */
3673 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_INFO_CENTER_FREQ = 61,
3674 /* Unsigned 32 bit value. Center frequency (MHz) first segment. */
3675 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_INFO_CENTER_FREQ0 = 62,
3676 /* Unsigned 32 bit value. Center frequency (MHz) second segment. */
3677 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_INFO_CENTER_FREQ1 = 63,
3678
3679 /* Attributes of type QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_* could be
3680 * nested within the radio stats.
3681 */
3682
3683 /* Unsigned int 32 bit value representing total number of msecs the
3684 * radio is awake on that channel accruing over time, corresponding to
3685 * the respective channel.
3686 */
3687 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_ON_TIME = 64,
3688 /* Unsigned int 32 bit value representing total number of msecs the CCA
3689 * register is busy accruing over time corresponding to the respective
3690 * channel.
3691 */
3692 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_CCA_BUSY_TIME = 65,
3693
3694 QCA_WLAN_VENDOR_ATTR_LL_STATS_NUM_RADIOS = 66,
3695
3696 /* Signifies the nested list of channel attributes
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05303697 * QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_*
Peng Xu291d97d2018-01-31 16:34:03 -08003698 */
3699 QCA_WLAN_VENDOR_ATTR_LL_STATS_CH_INFO = 67,
3700
3701 /* Signifies the nested list of peer info attributes
3702 * QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO_*
3703 */
3704 QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO = 68,
3705
3706 /* Signifies the nested list of rate info attributes
3707 * QCA_WLAN_VENDOR_ATTR_LL_STATS_RATE_*
3708 */
3709 QCA_WLAN_VENDOR_ATTR_LL_STATS_PEER_INFO_RATE_INFO = 69,
3710
3711 /* Signifies the nested list of wmm info attributes
3712 * QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_*
3713 */
3714 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_INFO = 70,
3715
3716 /* Unsigned 8 bit value. Used by the driver; if set to 1, it indicates
3717 * that more stats, e.g., peers or radio, are to follow in the next
3718 * QCA_NL80211_VENDOR_SUBCMD_LL_STATS_*_RESULTS event.
3719 * Otherwise, it is set to 0.
3720 */
3721 QCA_WLAN_VENDOR_ATTR_LL_STATS_RESULTS_MORE_DATA = 71,
3722
3723 /* Unsigned 64 bit value */
3724 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_AVERAGE_TSF_OFFSET = 72,
3725
3726 /* Unsigned 32 bit value */
3727 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_LEAKY_AP_DETECTED = 73,
3728
3729 /* Unsigned 32 bit value */
3730 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_LEAKY_AP_AVG_NUM_FRAMES_LEAKED = 74,
3731
3732 /* Unsigned 32 bit value */
3733 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_LEAKY_AP_GUARD_TIME = 75,
3734
3735 /* Unsigned 32 bit value */
3736 QCA_WLAN_VENDOR_ATTR_LL_STATS_TYPE = 76,
3737
3738 /* Unsigned 32 bit value */
3739 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_NUM_TX_LEVELS = 77,
3740
3741 /* Number of msecs the radio spent in transmitting for each power level
3742 */
3743 QCA_WLAN_VENDOR_ATTR_LL_STATS_RADIO_TX_TIME_PER_LEVEL = 78,
3744
3745 /* Unsigned 32 bit value */
3746 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_RTS_SUCC_CNT = 79,
3747 /* Unsigned 32 bit value */
3748 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_RTS_FAIL_CNT = 80,
3749 /* Unsigned 32 bit value */
3750 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_PPDU_SUCC_CNT = 81,
3751 /* Unsigned 32 bit value */
3752 QCA_WLAN_VENDOR_ATTR_LL_STATS_IFACE_PPDU_FAIL_CNT = 82,
3753
3754 /* Unsigned int 32 value.
3755 * Pending MSDUs corresponding to respective AC.
3756 */
3757 QCA_WLAN_VENDOR_ATTR_LL_STATS_WMM_AC_PENDING_MSDU = 83,
3758
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05303759 /* u32 value representing total time in milliseconds for which the radio
3760 * is transmitting on this channel. This attribute will be nested
3761 * within QCA_WLAN_VENDOR_ATTR_LL_STATS_CH_INFO.
3762 */
3763 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_TX_TIME = 84,
3764 /* u32 value representing total time in milliseconds for which the radio
3765 * is receiving all 802.11 frames intended for this device on this
3766 * channel. This attribute will be nested within
3767 * QCA_WLAN_VENDOR_ATTR_LL_STATS_CH_INFO.
3768 */
3769 QCA_WLAN_VENDOR_ATTR_LL_STATS_CHANNEL_RX_TIME = 85,
Peng Xu291d97d2018-01-31 16:34:03 -08003770 /* keep last */
3771 QCA_WLAN_VENDOR_ATTR_LL_STATS_AFTER_LAST,
3772 QCA_WLAN_VENDOR_ATTR_LL_STATS_MAX =
3773 QCA_WLAN_VENDOR_ATTR_LL_STATS_AFTER_LAST - 1,
3774};
3775
Arif Hussaine2645c62018-05-24 20:39:04 -07003776enum qca_wlan_vendor_attr_ll_stats_type {
Peng Xu291d97d2018-01-31 16:34:03 -08003777 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_TYPE_INVALID = 0,
3778 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_TYPE_RADIO = 1,
3779 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_TYPE_IFACE = 2,
3780 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_TYPE_PEERS = 3,
3781
3782 /* keep last */
3783 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_TYPE_AFTER_LAST,
3784 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_TYPE_MAX =
3785 QCA_NL80211_VENDOR_SUBCMD_LL_STATS_TYPE_AFTER_LAST - 1,
3786};
3787
3788/**
3789 * enum qca_wlan_vendor_attr_tdls_configuration - Attributes for
3790 * TDLS configuration to the host driver.
3791 *
3792 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TRIGGER_MODE: Configure the TDLS trigger
3793 * mode in the host driver. enum qca_wlan_vendor_tdls_trigger_mode
3794 * represents the different TDLS trigger modes.
3795 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TX_STATS_PERIOD: Duration (u32) within
3796 * which QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TX_THRESHOLD number
3797 * of packets shall meet the criteria for implicit TDLS setup.
3798 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TX_THRESHOLD: Number (u32) of Tx/Rx packets
3799 * within a duration QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TX_STATS_PERIOD
3800 * to initiate a TDLS setup.
3801 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_DISCOVERY_PERIOD: Time (u32) to initiate
3802 * a TDLS Discovery to the peer.
3803 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_MAX_DISCOVERY_ATTEMPT: Max number (u32) of
3804 * discovery attempts to know the TDLS capability of the peer. A peer is
3805 * marked as TDLS not capable if there is no response for all the attempts.
3806 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_IDLE_TIMEOUT: Represents a duration (u32)
3807 * within which QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_IDLE_PACKET_THRESHOLD
3808 * number of TX / RX frames meet the criteria for TDLS teardown.
3809 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_IDLE_PACKET_THRESHOLD: Minimum number (u32)
3810 * of Tx/Rx packets within a duration
3811 * QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_IDLE_TIMEOUT to tear down a TDLS link.
3812 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_SETUP_RSSI_THRESHOLD: Threshold
3813 * corresponding to the RSSI of the peer below which a TDLS setup is
3814 * triggered.
3815 * @QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TEARDOWN_RSSI_THRESHOLD: Threshold
3816 * corresponding to the RSSI of the peer above which a TDLS teardown is
3817 * triggered.
3818 */
3819enum qca_wlan_vendor_attr_tdls_configuration {
3820 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_INVALID = 0,
3821 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TRIGGER_MODE = 1,
3822
3823 /* Attributes configuring the TDLS Implicit Trigger */
3824 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TX_STATS_PERIOD = 2,
3825 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TX_THRESHOLD = 3,
3826 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_DISCOVERY_PERIOD = 4,
3827 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_MAX_DISCOVERY_ATTEMPT = 5,
3828 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_IDLE_TIMEOUT = 6,
3829 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_IDLE_PACKET_THRESHOLD = 7,
3830 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_SETUP_RSSI_THRESHOLD = 8,
3831 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TEARDOWN_RSSI_THRESHOLD = 9,
3832
3833 /* keep last */
3834 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_AFTER_LAST,
3835 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_MAX =
3836 QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_AFTER_LAST - 1
3837};
3838
3839/**
3840 * enum qca_wlan_vendor_tdls_trigger_mode: Represents the TDLS trigger mode in
3841 * the driver
3842 *
3843 * The following are the different values for
3844 * QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_TRIGGER_MODE.
3845 *
3846 * @QCA_WLAN_VENDOR_TDLS_TRIGGER_MODE_EXPLICIT: The trigger to initiate/teardown
3847 * the TDLS connection to a respective peer comes from the user space.
3848 * wpa_supplicant provides the commands TDLS_SETUP, TDLS_TEARDOWN,
3849 * TDLS_DISCOVER to do this.
3850 * @QCA_WLAN_VENDOR_TDLS_TRIGGER_MODE_IMPLICIT: Host driver triggers this TDLS
3851 * setup/teardown to the eligible peer once the configured criteria
3852 * (such as TX/RX threshold, RSSI) is met. The attributes
3853 * in QCA_WLAN_VENDOR_ATTR_TDLS_CONFIG_IMPLICIT_PARAMS correspond to
3854 * the different configuration criteria for the TDLS trigger from the
3855 * host driver.
3856 * @QCA_WLAN_VENDOR_TDLS_TRIGGER_MODE_EXTERNAL: Enables the driver to trigger
3857 * the TDLS setup / teardown through the implicit mode only to the
3858 * configured MAC addresses (wpa_supplicant, with tdls_external_control=1,
3859 * configures the MAC address through TDLS_SETUP / TDLS_TEARDOWN commands).
3860 * External mode works on top of the implicit mode. Thus the host driver
3861 * is expected to configure in TDLS Implicit mode too to operate in
3862 * External mode.
3863 * Configuring External mode alone without Implicit mode is invalid.
3864 *
3865 * All the above implementations work as expected only when the host driver
3866 * advertises the capability WPA_DRIVER_FLAGS_TDLS_EXTERNAL_SETUP - representing
3867 * that the TDLS message exchange is not internal to the host driver, but
3868 * depends on wpa_supplicant to do the message exchange.
3869 */
3870enum qca_wlan_vendor_tdls_trigger_mode {
3871 QCA_WLAN_VENDOR_TDLS_TRIGGER_MODE_EXPLICIT = 1 << 0,
3872 QCA_WLAN_VENDOR_TDLS_TRIGGER_MODE_IMPLICIT = 1 << 1,
3873 QCA_WLAN_VENDOR_TDLS_TRIGGER_MODE_EXTERNAL = 1 << 2,
3874};
3875
3876/**
3877 * enum qca_vendor_attr_sar_limits_selections - Source of SAR power limits
3878 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF0: Select SAR profile #0
3879 * that is hard-coded in the Board Data File (BDF).
3880 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF1: Select SAR profile #1
3881 * that is hard-coded in the Board Data File (BDF).
3882 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF2: Select SAR profile #2
3883 * that is hard-coded in the Board Data File (BDF).
3884 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF3: Select SAR profile #3
3885 * that is hard-coded in the Board Data File (BDF).
3886 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF4: Select SAR profile #4
3887 * that is hard-coded in the Board Data File (BDF).
3888 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_NONE: Do not select any
3889 * source of SAR power limits, thereby disabling the SAR power
3890 * limit feature.
3891 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_USER: Select the SAR power
3892 * limits configured by %QCA_NL80211_VENDOR_SUBCMD_SET_SAR.
Arif Hussaine2645c62018-05-24 20:39:04 -07003893 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_V2_0: Select the SAR power
3894 * limits version 2.0 configured by %QCA_NL80211_VENDOR_SUBCMD_SET_SAR.
Peng Xu291d97d2018-01-31 16:34:03 -08003895 *
3896 * This enumerates the valid set of values that may be supplied for
3897 * attribute %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT in an instance of
3898 * the %QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS vendor command or in
3899 * the response to an instance of the
3900 * %QCA_NL80211_VENDOR_SUBCMD_GET_SAR_LIMITS vendor command.
3901 */
3902enum qca_vendor_attr_sar_limits_selections {
3903 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF0 = 0,
3904 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF1 = 1,
3905 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF2 = 2,
3906 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF3 = 3,
3907 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_BDF4 = 4,
3908 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_NONE = 5,
3909 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_USER = 6,
Arif Hussaine2645c62018-05-24 20:39:04 -07003910 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_V2_0 = 7,
Peng Xu291d97d2018-01-31 16:34:03 -08003911};
3912
3913/**
3914 * enum qca_vendor_attr_sar_limits_spec_modulations -
3915 * SAR limits specification modulation
3916 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION_CCK -
3917 * CCK modulation
3918 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION_OFDM -
3919 * OFDM modulation
3920 *
3921 * This enumerates the valid set of values that may be supplied for
3922 * attribute %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION in an
3923 * instance of attribute %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC in an
3924 * instance of the %QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS vendor
3925 * command or in the response to an instance of the
3926 * %QCA_NL80211_VENDOR_SUBCMD_GET_SAR_LIMITS vendor command.
3927 */
3928enum qca_vendor_attr_sar_limits_spec_modulations {
3929 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION_CCK = 0,
3930 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION_OFDM = 1,
3931};
3932
3933/**
3934 * enum qca_vendor_attr_sar_limits - Attributes for SAR power limits
3935 *
3936 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SAR_ENABLE: Optional (u32) value to
3937 * select which SAR power limit table should be used. Valid
3938 * values are enumerated in enum
3939 * %qca_vendor_attr_sar_limits_selections. The existing SAR
3940 * power limit selection is unchanged if this attribute is not
3941 * present.
3942 *
3943 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_NUM_SPECS: Optional (u32) value
3944 * which specifies the number of SAR power limit specifications
3945 * which will follow.
3946 *
3947 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC: Nested array of SAR power
3948 * limit specifications. The number of specifications is
3949 * specified by @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_NUM_SPECS. Each
3950 * specification contains a set of
3951 * QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_* attributes. A
3952 * specification is uniquely identified by the attributes
3953 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_BAND,
3954 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_CHAIN, and
3955 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION and always
3956 * contains as a payload the attribute
Arif Hussaine2645c62018-05-24 20:39:04 -07003957 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT,
3958 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT_INDEX.
3959 * Either %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT or
3960 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT_INDEX is
3961 * needed based upon the value of
3962 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SAR_ENABLE.
Peng Xu291d97d2018-01-31 16:34:03 -08003963 *
3964 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_BAND: Optional (u32) value to
3965 * indicate for which band this specification applies. Valid
3966 * values are enumerated in enum %nl80211_band (although not all
3967 * bands may be supported by a given device). If the attribute is
3968 * not supplied then the specification will be applied to all
3969 * supported bands.
3970 *
3971 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_CHAIN: Optional (u32) value
3972 * to indicate for which antenna chain this specification
3973 * applies, i.e. 1 for chain 1, 2 for chain 2, etc. If the
3974 * attribute is not supplied then the specification will be
3975 * applied to all chains.
3976 *
3977 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION: Optional (u32)
3978 * value to indicate for which modulation scheme this
3979 * specification applies. Valid values are enumerated in enum
3980 * %qca_vendor_attr_sar_limits_spec_modulations. If the attribute
3981 * is not supplied then the specification will be applied to all
3982 * modulation schemes.
3983 *
3984 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT: Required (u32)
3985 * value to specify the actual power limit value in units of 0.5
3986 * dBm (i.e., a value of 11 represents 5.5 dBm).
Arif Hussaine2645c62018-05-24 20:39:04 -07003987 * This is required, when %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT is
3988 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_USER.
3989 *
3990 * @QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT_INDEX: Required (u32)
3991 * value to indicate SAR V2 indices (0 - 11) to select SAR V2 profiles.
3992 * This is required, when %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT is
3993 * %QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SELECT_V2_0.
Peng Xu291d97d2018-01-31 16:34:03 -08003994 *
3995 * These attributes are used with %QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS
3996 * and %QCA_NL80211_VENDOR_SUBCMD_GET_SAR_LIMITS.
3997 */
3998enum qca_vendor_attr_sar_limits {
3999 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_INVALID = 0,
4000 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SAR_ENABLE = 1,
4001 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_NUM_SPECS = 2,
4002 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC = 3,
4003 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_BAND = 4,
4004 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_CHAIN = 5,
4005 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_MODULATION = 6,
4006 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT = 7,
Arif Hussaine2645c62018-05-24 20:39:04 -07004007 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_SPEC_POWER_LIMIT_INDEX = 8,
Peng Xu291d97d2018-01-31 16:34:03 -08004008
4009 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_AFTER_LAST,
4010 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_MAX =
4011 QCA_WLAN_VENDOR_ATTR_SAR_LIMITS_AFTER_LAST - 1
4012};
4013
4014/**
4015 * enum qca_wlan_vendor_attr_get_wifi_info: Attributes for data used by
4016 * QCA_NL80211_VENDOR_SUBCMD_GET_WIFI_INFO sub command.
Jouni Malinenf735abd2020-08-03 11:08:00 +03004017 *
4018 * @QCA_WLAN_VENDOR_ATTR_WIFI_INFO_DRIVER_VERSION: In a request this attribute
4019 * should be set to any U8 value to indicate that the driver version
4020 * should be returned. When enabled in this manner, in a response this
4021 * attribute will contain a string representation of the driver version.
4022 *
4023 * @QCA_WLAN_VENDOR_ATTR_WIFI_INFO_FIRMWARE_VERSION: In a request this attribute
4024 * should be set to any U8 value to indicate that the firmware version
4025 * should be returned. When enabled in this manner, in a response this
4026 * attribute will contain a string representation of the firmware version.
4027 *
4028 * @QCA_WLAN_VENDOR_ATTR_WIFI_INFO_RADIO_INDEX: In a request this attribute
4029 * should be set to any U32 value to indicate that the current radio
4030 * index should be returned. When enabled in this manner, in a response
4031 * this attribute will contain a U32 radio index value.
4032 *
Peng Xu291d97d2018-01-31 16:34:03 -08004033 */
4034enum qca_wlan_vendor_attr_get_wifi_info {
4035 QCA_WLAN_VENDOR_ATTR_WIFI_INFO_GET_INVALID = 0,
4036 QCA_WLAN_VENDOR_ATTR_WIFI_INFO_DRIVER_VERSION = 1,
4037 QCA_WLAN_VENDOR_ATTR_WIFI_INFO_FIRMWARE_VERSION = 2,
Jouni Malinenf735abd2020-08-03 11:08:00 +03004038 QCA_WLAN_VENDOR_ATTR_WIFI_INFO_RADIO_INDEX = 3,
Peng Xu291d97d2018-01-31 16:34:03 -08004039
4040 /* keep last */
4041 QCA_WLAN_VENDOR_ATTR_WIFI_INFO_GET_AFTER_LAST,
4042 QCA_WLAN_VENDOR_ATTR_WIFI_INFO_GET_MAX =
4043 QCA_WLAN_VENDOR_ATTR_WIFI_INFO_GET_AFTER_LAST - 1,
4044};
4045
4046/*
4047 * enum qca_wlan_vendor_attr_wifi_logger_start: Attributes for data used by
4048 * QCA_NL80211_VENDOR_SUBCMD_WIFI_LOGGER_START sub command.
4049 */
4050enum qca_wlan_vendor_attr_wifi_logger_start {
4051 QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_START_INVALID = 0,
4052 QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_RING_ID = 1,
4053 QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_VERBOSE_LEVEL = 2,
4054 QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_FLAGS = 3,
4055
4056 /* keep last */
4057 QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_START_AFTER_LAST,
4058 QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_START_GET_MAX =
4059 QCA_WLAN_VENDOR_ATTR_WIFI_LOGGER_START_AFTER_LAST - 1,
4060};
4061
4062enum qca_wlan_vendor_attr_logger_results {
4063 QCA_WLAN_VENDOR_ATTR_LOGGER_RESULTS_INVALID = 0,
4064
4065 /* Unsigned 32-bit value; must match the request Id supplied by
4066 * Wi-Fi HAL in the corresponding subcmd NL msg.
4067 */
4068 QCA_WLAN_VENDOR_ATTR_LOGGER_RESULTS_REQUEST_ID = 1,
4069
4070 /* Unsigned 32-bit value; used to indicate the size of memory
4071 * dump to be allocated.
Arif Hussaine2645c62018-05-24 20:39:04 -07004072 */
Peng Xu291d97d2018-01-31 16:34:03 -08004073 QCA_WLAN_VENDOR_ATTR_LOGGER_RESULTS_MEMDUMP_SIZE = 2,
4074
4075 /* keep last */
4076 QCA_WLAN_VENDOR_ATTR_LOGGER_RESULTS_AFTER_LAST,
4077 QCA_WLAN_VENDOR_ATTR_LOGGER_RESULTS_MAX =
4078 QCA_WLAN_VENDOR_ATTR_LOGGER_RESULTS_AFTER_LAST - 1,
4079};
4080
Jouni Malinenf735abd2020-08-03 11:08:00 +03004081/**
4082 * enum qca_scan_freq_list_type: Frequency list types
4083 *
4084 * @QCA_PREFERRED_SCAN_FREQ_LIST: The driver shall use the scan frequency list
4085 * specified with attribute QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST as
4086 * a preferred frequency list for roaming.
4087 *
4088 * @QCA_SPECIFIC_SCAN_FREQ_LIST: The driver shall use the frequency list
4089 * specified with attribute QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST as
4090 * a specific frequency list for roaming.
4091 */
4092enum qca_scan_freq_list_type {
4093 QCA_PREFERRED_SCAN_FREQ_LIST = 1,
4094 QCA_SPECIFIC_SCAN_FREQ_LIST = 2,
4095};
4096
4097/**
4098 * enum qca_vendor_attr_scan_freq_list_scheme: Frequency list scheme
4099 *
4100 * @QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST: Nested attribute of u32 values
4101 * List of frequencies in MHz to be considered for a roam scan.
4102 *
4103 * @QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST_TYPE: Unsigned 32-bit value.
4104 * Type of frequency list scheme being configured/gotten as defined by the
4105 * enum qca_scan_freq_list_type.
4106 */
4107enum qca_vendor_attr_scan_freq_list_scheme {
4108 QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST = 1,
4109 QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST_TYPE = 2,
4110
4111 /* keep last */
4112 QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST_SCHEME_AFTER_LAST,
4113 QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST_SCHEME_MAX =
4114 QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST_SCHEME_AFTER_LAST - 1,
4115};
4116
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05304117/**
4118 * enum qca_roam_scan_scheme: Scan scheme
4119 *
4120 * @QCA_ROAM_SCAN_SCHEME_NO_SCAN: No frequencies specified to scan.
4121 * Indicates the driver to not scan on a Roam Trigger scenario, but
4122 * disconnect. E.g., on a BTM request from the AP the driver/firmware shall
4123 * disconnect from the current connected AP by notifying a failure
4124 * code in the BTM response.
4125 *
4126 * @QCA_ROAM_SCAN_SCHEME_PARTIAL_SCAN: Indicates the driver/firmware to
4127 * trigger partial frequency scans. These frequencies are the ones learned
4128 * or maintained by the driver based on the probability of finding the
4129 * BSSIDs in the ESS for which the roaming is triggered.
4130 *
4131 * @QCA_ROAM_SCAN_SCHEME_FULL_SCAN: Indicates the driver/firmware to
4132 * trigger the scan on all the valid frequencies to find better
4133 * candidates to roam.
4134 */
4135enum qca_roam_scan_scheme {
4136 QCA_ROAM_SCAN_SCHEME_NO_SCAN = 0,
4137 QCA_ROAM_SCAN_SCHEME_PARTIAL_SCAN = 1,
4138 QCA_ROAM_SCAN_SCHEME_FULL_SCAN = 2,
4139};
4140
Jouni Malinenf735abd2020-08-03 11:08:00 +03004141/*
4142 * enum qca_vendor_roam_triggers: Bitmap of roaming triggers
4143 *
4144 * @QCA_ROAM_TRIGGER_REASON_PER: Set if the roam has to be triggered based on
4145 * a bad packet error rates (PER).
4146 * @QCA_ROAM_TRIGGER_REASON_BEACON_MISS: Set if the roam has to be triggered
4147 * based on beacon misses from the connected AP.
4148 * @QCA_ROAM_TRIGGER_REASON_POOR_RSSI: Set if the roam has to be triggered
4149 * due to poor RSSI of the connected AP.
4150 * @QCA_ROAM_TRIGGER_REASON_BETTER_RSSI: Set if the roam has to be triggered
4151 * upon finding a BSSID with a better RSSI than the connected BSSID.
4152 * Here the RSSI of the current BSSID need not be poor.
4153 * @QCA_ROAM_TRIGGER_REASON_PERIODIC: Set if the roam has to be triggered
4154 * by triggering a periodic scan to find a better AP to roam.
4155 * @QCA_ROAM_TRIGGER_REASON_DENSE: Set if the roam has to be triggered
4156 * when the connected channel environment is too noisy/congested.
4157 * @QCA_ROAM_TRIGGER_REASON_BTM: Set if the roam has to be triggered
4158 * when BTM Request frame is received from the connected AP.
4159 * @QCA_ROAM_TRIGGER_REASON_BSS_LOAD: Set if the roam has to be triggered
4160 * when the channel utilization is goes above the configured threshold.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05304161 * @QCA_ROAM_TRIGGER_REASON_USER_TRIGGER: Set if the roam has to be triggered
4162 * based on the request from the user (space).
4163 * @QCA_ROAM_TRIGGER_REASON_DEAUTH: Set if the roam has to be triggered when
4164 * device receives Deauthentication/Disassociation frame from connected AP.
4165 * @QCA_ROAM_TRIGGER_REASON_IDLE: Set if the roam has to be triggered when the
4166 * device is in idle state (no TX/RX) and suspend mode, if the current RSSI
4167 * is determined to be a poor one.
4168 * @QCA_ROAM_TRIGGER_REASON_TX_FAILURES: Set if the roam has to be triggered
4169 * based on continuous TX Data frame failures to the connected AP.
4170 * @QCA_ROAM_TRIGGER_REASON_EXTERNAL_SCAN: Set if the roam has to be triggered
4171 * based on the scan results obtained from an external scan (not triggered
4172 * to aim roaming).
Jouni Malinenf735abd2020-08-03 11:08:00 +03004173 *
4174 * Set the corresponding roam trigger reason bit to consider it for roam
4175 * trigger.
4176 * Userspace can set multiple bits and send to the driver. The driver shall
4177 * consider all of them to trigger/initiate a roam scan.
4178 */
4179enum qca_vendor_roam_triggers {
4180 QCA_ROAM_TRIGGER_REASON_PER = 1 << 0,
4181 QCA_ROAM_TRIGGER_REASON_BEACON_MISS = 1 << 1,
4182 QCA_ROAM_TRIGGER_REASON_POOR_RSSI = 1 << 2,
4183 QCA_ROAM_TRIGGER_REASON_BETTER_RSSI = 1 << 3,
4184 QCA_ROAM_TRIGGER_REASON_PERIODIC = 1 << 4,
4185 QCA_ROAM_TRIGGER_REASON_DENSE = 1 << 5,
4186 QCA_ROAM_TRIGGER_REASON_BTM = 1 << 6,
4187 QCA_ROAM_TRIGGER_REASON_BSS_LOAD = 1 << 7,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05304188 QCA_ROAM_TRIGGER_REASON_USER_TRIGGER = 1 << 8,
4189 QCA_ROAM_TRIGGER_REASON_DEAUTH = 1 << 9,
4190 QCA_ROAM_TRIGGER_REASON_IDLE = 1 << 10,
4191 QCA_ROAM_TRIGGER_REASON_TX_FAILURES = 1 << 11,
4192 QCA_ROAM_TRIGGER_REASON_EXTERNAL_SCAN = 1 << 12,
Jouni Malinenf735abd2020-08-03 11:08:00 +03004193};
4194
4195/**
4196 * enum qca_vendor_attr_roam_candidate_selection_criteria:
4197 *
4198 * Each attribute carries a weightage in percentage (%).
4199 *
4200 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_RSSI: Unsigned 8-bit value.
4201 * Represents the weightage to be given for the RSSI selection
4202 * criteria among other parameters.
4203 *
4204 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_RATE: Unsigned 8-bit value.
4205 * Represents the weightage to be given for the rate selection
4206 * criteria among other parameters.
4207 *
4208 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_BW: Unsigned 8-bit value.
4209 * Represents the weightage to be given for the band width selection
4210 * criteria among other parameters.
4211 *
4212 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_BAND: Unsigned 8-bit value.
4213 * Represents the weightage to be given for the band selection
4214 * criteria among other parameters.
4215 *
4216 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_NSS: Unsigned 8-bit value.
4217 * Represents the weightage to be given for the NSS selection
4218 * criteria among other parameters.
4219 *
4220 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_CHAN_CONGESTION: Unsigned 8-bit value.
4221 * Represents the weightage to be given for the channel congestion
4222 * selection criteria among other parameters.
4223 *
4224 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_BEAMFORMING: Unsigned 8-bit value.
4225 * Represents the weightage to be given for the beamforming selection
4226 * criteria among other parameters.
4227 *
4228 * @QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_OCE_WAN: Unsigned 8-bit value.
4229 * Represents the weightage to be given for the OCE selection
4230 * criteria among other parameters.
4231 */
4232enum qca_vendor_attr_roam_candidate_selection_criteria {
4233 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_RSSI = 1,
4234 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_RATE = 2,
4235 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_BW = 3,
4236 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_BAND = 4,
4237 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_NSS = 5,
4238 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_CHAN_CONGESTION = 6,
4239 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_BEAMFORMING = 7,
4240 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_SCORE_OCE_WAN = 8,
4241
4242 /* keep last */
4243 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_RATE_AFTER_LAST,
4244 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_RATE_MAX =
4245 QCA_ATTR_ROAM_CAND_SEL_CRITERIA_RATE_AFTER_LAST - 1,
4246};
4247
4248/**
4249 * enum qca_vendor_attr_roam_control - Attributes to carry roam configuration
4250 * The following attributes are used to set/get/clear the respective
4251 * configurations to/from the driver.
4252 * For the get, the attribute for the configuration to be queried shall
4253 * carry any of its acceptable values to the driver. In return, the driver
4254 * shall send the configured values within the same attribute to the user
4255 * space.
4256 *
4257 * @QCA_ATTR_ROAM_CONTROL_ENABLE: Unsigned 8-bit value.
4258 * Signifies to enable/disable roam control in driver.
4259 * 1-enable, 0-disable
4260 * Enable: Mandates the driver to do the further roams using the
4261 * configuration parameters set through
4262 * QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_SET.
4263 * Disable: Disables the driver/firmware roaming triggered through
4264 * QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_SET. Further roaming is
4265 * expected to continue with the default configurations.
4266 *
4267 * @QCA_ATTR_ROAM_CONTROL_STATUS: Unsigned 8-bit value.
4268 * This is used along with QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_GET.
4269 * Roam control status is obtained through this attribute.
4270 *
4271 * @QCA_ATTR_ROAM_CONTROL_CLEAR_ALL: Flag attribute to indicate the
4272 * complete config set through QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_SET
4273 * is to be cleared in the driver.
4274 * This is used along with QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_CLEAR
4275 * and shall be ignored if used with other sub commands.
4276 * If this attribute is specified along with subcmd
4277 * QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_CLEAR, the driver shall ignore
4278 * all other attributes, if there are any.
4279 * If this attribute is not specified when the subcmd
4280 * QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_CLEAR is sent, the driver shall
4281 * clear the data corresponding to the attributes specified.
4282 *
4283 * @QCA_ATTR_ROAM_CONTROL_FREQ_LIST_SCHEME: Nested attribute to carry the
4284 * list of frequencies and its type, represented by
4285 * enum qca_vendor_attr_scan_freq_list_scheme.
4286 * Frequency list and its type are mandatory for this attribute to set
4287 * the frequencies.
4288 * Frequency type is mandatory for this attribute to get the frequencies
4289 * and the frequency list is obtained through
4290 * QCA_ATTR_ROAM_CONTROL_SCAN_FREQ_LIST.
4291 * Frequency list type is mandatory for this attribute to clear the
4292 * frequencies.
4293 *
4294 * @QCA_ATTR_ROAM_CONTROL_SCAN_PERIOD: Unsigned 32-bit value.
4295 * Carries the value of scan period in seconds to set.
4296 * The value of scan period is obtained with the same attribute for get.
4297 * Clears the scan period in the driver when specified with clear command.
4298 * Scan period is the idle time in seconds between each subsequent
4299 * channel scans.
4300 *
4301 * @QCA_ATTR_ROAM_CONTROL_FULL_SCAN_PERIOD: Unsigned 32-bit value.
4302 * Carries the value of full scan period in seconds to set.
4303 * The value of full scan period is obtained with the same attribute for
4304 * get.
4305 * Clears the full scan period in the driver when specified with clear
4306 * command. Full scan period is the idle period in seconds between two
4307 * successive full channel roam scans.
4308 *
4309 * @QCA_ATTR_ROAM_CONTROL_TRIGGERS: Unsigned 32-bit value.
4310 * Carries a bitmap of the roam triggers specified in
4311 * enum qca_vendor_roam_triggers.
4312 * The driver shall enable roaming by enabling corresponding roam triggers
4313 * based on the trigger bits sent with this attribute.
4314 * If this attribute is not configured, the driver shall proceed with
4315 * default behavior.
4316 * The bitmap configured is obtained with the same attribute for get.
4317 * Clears the bitmap configured in driver when specified with clear
4318 * command.
4319 *
4320 * @QCA_ATTR_ROAM_CONTROL_SELECTION_CRITERIA: Nested attribute signifying the
4321 * weightage in percentage (%) to be given for each selection criteria.
4322 * Different roam candidate selection criteria are represented by
4323 * enum qca_vendor_attr_roam_candidate_selection_criteria.
4324 * The driver shall select the roam candidate based on corresponding
4325 * candidate selection scores sent.
4326 *
4327 * An empty nested attribute is used to indicate that no specific
4328 * preference score/criteria is configured (i.e., to disable this mechanism
4329 * in the set case and to show that the mechanism is disabled in the get
4330 * case).
4331 *
4332 * Userspace can send multiple attributes out of this enum to the driver.
4333 * Since this attribute represents the weight/percentage of preference for
4334 * the respective selection criteria, it is preferred to configure 100%
4335 * total weightage. The value in each attribute or cumulative weight of the
4336 * values in all the nested attributes should not exceed 100%. The driver
4337 * shall reject such configuration.
4338 *
4339 * If the weights configured through this attribute are less than 100%,
4340 * the driver shall honor the weights (x%) passed for the corresponding
4341 * selection criteria and choose/distribute rest of the weight (100-x)%
4342 * for the other selection criteria, based on its internal logic.
4343 *
4344 * The selection criteria configured is obtained with the same
4345 * attribute for get.
4346 *
4347 * Clears the selection criteria configured in the driver when specified
4348 * with clear command.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05304349 *
4350 * @QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME: Unsigned 32-bit value.
4351 * Represents value of the scan frequency scheme from enum
4352 * qca_roam_scan_scheme.
4353 * It's an optional attribute. If this attribute is not configured, the
4354 * driver shall proceed with default behavior.
4355 *
4356 * @QCA_ATTR_ROAM_CONTROL_CONNECTED_RSSI_THRESHOLD: Signed 32-bit value in dBm,
4357 * signifying the RSSI threshold of the current connected AP, indicating
4358 * the driver to trigger roam only when the current connected AP's RSSI
4359 * is less than this threshold.
4360 *
4361 * @QCA_ATTR_ROAM_CONTROL_CANDIDATE_RSSI_THRESHOLD: Signed 32-bit value in dBm,
4362 * signifying the RSSI threshold of the candidate AP, indicating
4363 * the driver to trigger roam only to the candidate AP with RSSI
4364 * better than this threshold.
4365 *
4366 * @QCA_ATTR_ROAM_CONTROL_USER_REASON: Unsigned 32-bit value. Represents the
4367 * user defined reason code to be sent to the AP in response to AP's
4368 * request to trigger the roam if the roaming cannot be triggered.
4369 * Applies to all the scenarios of AP assisted roaming (e.g., BTM).
4370 *
4371 * @QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME_TRIGGERS: Unsigned 32-bit value.
4372 * Carries a bitmap of the roam triggers specified in
4373 * enum qca_vendor_roam_triggers.
4374 * Represents the roam triggers for which the specific scan scheme from
4375 * enum qca_roam_scan_scheme has to be applied.
4376 * It's an optional attribute. If this attribute is not configured, but
4377 * QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME is specified, the scan scheme
4378 * specified through QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME is applicable for
4379 * all the roams.
4380 * If both QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME and
4381 * QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME_TRIGGERS are not specified, the
4382 * driver shall proceed with the default behavior.
Jouni Malinenf735abd2020-08-03 11:08:00 +03004383 */
4384enum qca_vendor_attr_roam_control {
4385 QCA_ATTR_ROAM_CONTROL_ENABLE = 1,
4386 QCA_ATTR_ROAM_CONTROL_STATUS = 2,
4387 QCA_ATTR_ROAM_CONTROL_CLEAR_ALL = 3,
4388 QCA_ATTR_ROAM_CONTROL_FREQ_LIST_SCHEME= 4,
4389 QCA_ATTR_ROAM_CONTROL_SCAN_PERIOD = 5,
4390 QCA_ATTR_ROAM_CONTROL_FULL_SCAN_PERIOD = 6,
4391 QCA_ATTR_ROAM_CONTROL_TRIGGERS = 7,
4392 QCA_ATTR_ROAM_CONTROL_SELECTION_CRITERIA = 8,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05304393 QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME = 9,
4394 QCA_ATTR_ROAM_CONTROL_CONNECTED_RSSI_THRESHOLD = 10,
4395 QCA_ATTR_ROAM_CONTROL_CANDIDATE_RSSI_THRESHOLD = 11,
4396 QCA_ATTR_ROAM_CONTROL_USER_REASON = 12,
4397 QCA_ATTR_ROAM_CONTROL_SCAN_SCHEME_TRIGGERS = 13,
Jouni Malinenf735abd2020-08-03 11:08:00 +03004398
4399 /* keep last */
4400 QCA_ATTR_ROAM_CONTROL_AFTER_LAST,
4401 QCA_ATTR_ROAM_CONTROL_MAX =
4402 QCA_ATTR_ROAM_CONTROL_AFTER_LAST - 1,
4403};
4404
4405/*
4406 * enum qca_wlan_vendor_attr_roaming_config_params: Attributes for data used by
4407 * QCA_NL80211_VENDOR_SUBCMD_ROAM sub command.
4408 *
4409 * @QCA_WLAN_VENDOR_ATTR_ROAMING_SUBCMD: Unsigned 32-bit value.
4410 * Represents the different roam sub commands referred by
4411 * enum qca_wlan_vendor_roaming_subcmd.
4412 *
4413 * @QCA_WLAN_VENDOR_ATTR_ROAMING_REQ_ID: Unsigned 32-bit value.
4414 * Represents the Request ID for the specific set of commands.
4415 * This also helps to map specific set of commands to the respective
4416 * ID / client. e.g., helps to identify the user entity configuring the
4417 * ignored BSSIDs and accordingly clear the respective ones with the
4418 * matching ID.
4419 *
4420 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID_NUM_NETWORKS: Unsigned
4421 * 32-bit value.Represents the number of whitelist SSIDs configured.
4422 *
4423 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID_LIST: Nested attribute
4424 * to carry the list of Whitelist SSIDs.
4425 *
4426 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID: SSID (binary attribute,
4427 * 0..32 octets). Represents the white list SSID. Whitelist SSIDs
4428 * represent the list of SSIDs to which the firmware/driver can consider
4429 * to roam to.
4430 *
4431 * The following PARAM_A_BAND_XX attributes are applied to 5GHz BSSIDs when
4432 * comparing with a 2.4GHz BSSID. They are not applied when comparing two
4433 * 5GHz BSSIDs.The following attributes are set through the Roaming SUBCMD -
4434 * QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_GSCAN_ROAM_PARAMS.
4435 *
4436 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_BOOST_THRESHOLD: Signed 32-bit
4437 * value, RSSI threshold above which 5GHz RSSI is favored.
4438 *
4439 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_PENALTY_THRESHOLD: Signed 32-bit
4440 * value, RSSI threshold below which 5GHz RSSI is penalized.
4441 *
4442 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_BOOST_FACTOR: Unsigned 32-bit
4443 * value, factor by which 5GHz RSSI is boosted.
4444 * boost=(RSSI_measured-5GHz_boost_threshold)*5GHz_boost_factor
4445 *
4446 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_PENALTY_FACTOR: Unsigned 32-bit
4447 * value, factor by which 5GHz RSSI is penalized.
4448 * penalty=(5GHz_penalty_threshold-RSSI_measured)*5GHz_penalty_factor
4449 *
4450 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_MAX_BOOST: Unsigned 32-bit
4451 * value, maximum boost that can be applied to a 5GHz RSSI.
4452 *
4453 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_LAZY_ROAM_HISTERESYS: Unsigned 32-bit
4454 * value, boost applied to current BSSID to ensure the currently
4455 * associated BSSID is favored so as to prevent ping-pong situations.
4456 *
4457 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_ALERT_ROAM_RSSI_TRIGGER: Signed 32-bit
4458 * value, RSSI below which "Alert" roam is enabled.
4459 * "Alert" mode roaming - firmware is "urgently" hunting for another BSSID
4460 * because the RSSI is low, or because many successive beacons have been
4461 * lost or other bad link conditions.
4462 *
4463 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_ENABLE: Unsigned 32-bit
4464 * value. 1-Enable, 0-Disable. Represents "Lazy" mode, where
4465 * firmware is hunting for a better BSSID or white listed SSID even though
4466 * the RSSI of the link is good. The parameters enabling the roaming are
4467 * configured through the PARAM_A_BAND_XX attrbutes.
4468 *
4469 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PREFS: Nested attribute,
4470 * represents the BSSIDs preferred over others while evaluating them
4471 * for the roaming.
4472 *
4473 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_NUM_BSSID: Unsigned
4474 * 32-bit value. Represents the number of preferred BSSIDs set.
4475 *
4476 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_BSSID: 6-byte MAC
4477 * address representing the BSSID to be preferred.
4478 *
4479 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_RSSI_MODIFIER: Signed
4480 * 32-bit value, representing the modifier to be applied to the RSSI of
4481 * the BSSID for the purpose of comparing it with other roam candidate.
4482 *
4483 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS: Nested attribute,
4484 * represents the BSSIDs to get ignored for roaming.
4485 *
4486 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS_NUM_BSSID: Unsigned
4487 * 32-bit value, represents the number of ignored BSSIDs.
4488 *
4489 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS_BSSID: 6-byte MAC
4490 * address representing the ignored BSSID.
4491 *
4492 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS_HINT: Flag attribute,
4493 * indicates this request to ignore the BSSID as a hint to the driver. The
4494 * driver can select this BSSID in the worst case (when no other BSSIDs are
4495 * better).
4496 *
4497 * @QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_CONTROL: Nested attribute to
4498 * set/get/clear the roam control config as
4499 * defined @enum qca_vendor_attr_roam_control.
4500 */
Peng Xu291d97d2018-01-31 16:34:03 -08004501enum qca_wlan_vendor_attr_roaming_config_params {
4502 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_INVALID = 0,
4503
4504 QCA_WLAN_VENDOR_ATTR_ROAMING_SUBCMD = 1,
4505 QCA_WLAN_VENDOR_ATTR_ROAMING_REQ_ID = 2,
4506
4507 /* Attributes for wifi_set_ssid_white_list */
4508 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID_NUM_NETWORKS = 3,
4509 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID_LIST = 4,
4510 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID = 5,
4511
4512 /* Attributes for set_roam_params */
4513 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_BOOST_THRESHOLD = 6,
4514 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_PENALTY_THRESHOLD = 7,
4515 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_BOOST_FACTOR = 8,
4516 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_PENALTY_FACTOR = 9,
4517 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_A_BAND_MAX_BOOST = 10,
4518 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_LAZY_ROAM_HISTERESYS = 11,
4519 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_ALERT_ROAM_RSSI_TRIGGER = 12,
4520
4521 /* Attribute for set_lazy_roam */
4522 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_ENABLE = 13,
4523
4524 /* Attribute for set_lazy_roam with preferences */
4525 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PREFS = 14,
4526 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_NUM_BSSID = 15,
4527 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_BSSID = 16,
4528 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_RSSI_MODIFIER = 17,
4529
Jouni Malinenf735abd2020-08-03 11:08:00 +03004530 /* Attribute for setting ignored BSSID parameters */
Peng Xu291d97d2018-01-31 16:34:03 -08004531 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS = 18,
4532 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS_NUM_BSSID = 19,
4533 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS_BSSID = 20,
Jouni Malinenf735abd2020-08-03 11:08:00 +03004534 /* Flag attribute indicates this entry as a hint */
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08004535 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS_HINT = 21,
Peng Xu291d97d2018-01-31 16:34:03 -08004536
Jouni Malinenf735abd2020-08-03 11:08:00 +03004537 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_CONTROL = 22,
4538
Peng Xu291d97d2018-01-31 16:34:03 -08004539 /* keep last */
4540 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_AFTER_LAST,
4541 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_MAX =
4542 QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_AFTER_LAST - 1,
4543};
4544
4545/*
Jouni Malinenf735abd2020-08-03 11:08:00 +03004546 * enum qca_wlan_vendor_roaming_subcmd: Referred by
4547 * QCA_WLAN_VENDOR_ATTR_ROAMING_SUBCMD.
4548 *
4549 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_SSID_WHITE_LIST: Sub command to
4550 * configure the white list SSIDs. These are configured through
4551 * the following attributes.
4552 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID_NUM_NETWORKS,
4553 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID_LIST,
4554 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_WHITE_LIST_SSID
4555 *
4556 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_GSCAN_ROAM_PARAMS: Sub command to
4557 * configure the Roam params. These parameters are evaluated on the GScan
4558 * results. Refers the attributes PARAM_A_BAND_XX above to configure the
4559 * params.
4560 *
4561 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_LAZY_ROAM: Sets the Lazy roam. Uses
4562 * the attribute QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_LAZY_ROAM_ENABLE
4563 * to enable/disable Lazy roam.
4564 *
4565 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_BSSID_PREFS: Sets the BSSID
4566 * preference. Contains the attribute
4567 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PREFS to set the BSSID
4568 * preference.
4569 *
4570 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_BLACKLIST_BSSID: Sets the list of BSSIDs
4571 * to ignore in roaming decision. Uses
4572 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS to set the list.
4573 *
4574 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_SET: Command to set the
4575 * roam control config to the driver with the attribute
4576 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_CONTROL.
4577 *
4578 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_GET: Command to obtain the
4579 * roam control config from driver with the attribute
4580 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_CONTROL.
4581 * For the get, the attribute for the configuration to be queried shall
4582 * carry any of its acceptable value to the driver. In return, the driver
4583 * shall send the configured values within the same attribute to the user
4584 * space.
4585 *
4586 * @QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_CLEAR: Command to clear the
4587 * roam control config in the driver with the attribute
4588 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_CONTROL.
4589 * The driver shall continue with its default roaming behavior when data
4590 * corresponding to an attribute is cleared.
Peng Xu291d97d2018-01-31 16:34:03 -08004591 */
Jouni Malinenf735abd2020-08-03 11:08:00 +03004592enum qca_wlan_vendor_roaming_subcmd {
4593 QCA_WLAN_VENDOR_ROAMING_SUBCMD_INVALID = 0,
4594 QCA_WLAN_VENDOR_ROAMING_SUBCMD_SSID_WHITE_LIST = 1,
4595 QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_GSCAN_ROAM_PARAMS = 2,
4596 QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_LAZY_ROAM = 3,
4597 QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_BSSID_PREFS = 4,
4598 QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_BSSID_PARAMS = 5,
4599 QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_BLACKLIST_BSSID = 6,
4600 QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_SET = 7,
4601 QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_GET = 8,
4602 QCA_WLAN_VENDOR_ROAMING_SUBCMD_CONTROL_CLEAR = 9,
Peng Xu291d97d2018-01-31 16:34:03 -08004603};
4604
4605enum qca_wlan_vendor_attr_gscan_config_params {
4606 QCA_WLAN_VENDOR_ATTR_GSCAN_SUBCMD_CONFIG_PARAM_INVALID = 0,
4607
4608 /* Unsigned 32-bit value */
4609 QCA_WLAN_VENDOR_ATTR_GSCAN_SUBCMD_CONFIG_PARAM_REQUEST_ID = 1,
4610
4611 /* Attributes for data used by
4612 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_GET_VALID_CHANNELS sub command.
4613 */
4614 /* Unsigned 32-bit value */
4615 QCA_WLAN_VENDOR_ATTR_GSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_WIFI_BAND
4616 = 2,
4617 /* Unsigned 32-bit value */
4618 QCA_WLAN_VENDOR_ATTR_GSCAN_GET_VALID_CHANNELS_CONFIG_PARAM_MAX_CHANNELS
4619 = 3,
4620
4621 /* Attributes for input params used by
4622 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_START sub command.
4623 */
4624
4625 /* Unsigned 32-bit value; channel frequency */
4626 QCA_WLAN_VENDOR_ATTR_GSCAN_CHANNEL_SPEC_CHANNEL = 4,
4627 /* Unsigned 32-bit value; dwell time in ms. */
4628 QCA_WLAN_VENDOR_ATTR_GSCAN_CHANNEL_SPEC_DWELL_TIME = 5,
4629 /* Unsigned 8-bit value; 0: active; 1: passive; N/A for DFS */
4630 QCA_WLAN_VENDOR_ATTR_GSCAN_CHANNEL_SPEC_PASSIVE = 6,
4631 /* Unsigned 8-bit value; channel class */
4632 QCA_WLAN_VENDOR_ATTR_GSCAN_CHANNEL_SPEC_CLASS = 7,
4633
4634 /* Unsigned 8-bit value; bucket index, 0 based */
4635 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_INDEX = 8,
4636 /* Unsigned 8-bit value; band. */
4637 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_BAND = 9,
4638 /* Unsigned 32-bit value; desired period, in ms. */
4639 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_PERIOD = 10,
4640 /* Unsigned 8-bit value; report events semantics. */
4641 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_REPORT_EVENTS = 11,
4642 /* Unsigned 32-bit value. Followed by a nested array of
4643 * GSCAN_CHANNEL_SPEC_* attributes.
4644 */
4645 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_NUM_CHANNEL_SPECS = 12,
4646
4647 /* Array of QCA_WLAN_VENDOR_ATTR_GSCAN_CHANNEL_SPEC_* attributes.
4648 * Array size: QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_NUM_CHANNEL_SPECS
4649 */
4650 QCA_WLAN_VENDOR_ATTR_GSCAN_CHANNEL_SPEC = 13,
4651
4652 /* Unsigned 32-bit value; base timer period in ms. */
4653 QCA_WLAN_VENDOR_ATTR_GSCAN_SCAN_CMD_PARAMS_BASE_PERIOD = 14,
4654 /* Unsigned 32-bit value; number of APs to store in each scan in the
4655 * BSSID/RSSI history buffer (keep the highest RSSI APs).
4656 */
4657 QCA_WLAN_VENDOR_ATTR_GSCAN_SCAN_CMD_PARAMS_MAX_AP_PER_SCAN = 15,
4658 /* Unsigned 8-bit value; in %, when scan buffer is this much full, wake
4659 * up AP.
4660 */
4661 QCA_WLAN_VENDOR_ATTR_GSCAN_SCAN_CMD_PARAMS_REPORT_THRESHOLD_PERCENT
4662 = 16,
4663
4664 /* Unsigned 8-bit value; number of scan bucket specs; followed by a
4665 * nested array of_GSCAN_BUCKET_SPEC_* attributes and values. The size
4666 * of the array is determined by NUM_BUCKETS.
4667 */
4668 QCA_WLAN_VENDOR_ATTR_GSCAN_SCAN_CMD_PARAMS_NUM_BUCKETS = 17,
4669
4670 /* Array of QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_* attributes.
4671 * Array size: QCA_WLAN_VENDOR_ATTR_GSCAN_SCAN_CMD_PARAMS_NUM_BUCKETS
4672 */
4673 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC = 18,
4674
4675 /* Unsigned 8-bit value */
4676 QCA_WLAN_VENDOR_ATTR_GSCAN_GET_CACHED_SCAN_RESULTS_CONFIG_PARAM_FLUSH
4677 = 19,
4678 /* Unsigned 32-bit value; maximum number of results to be returned. */
4679 QCA_WLAN_VENDOR_ATTR_GSCAN_GET_CACHED_SCAN_RESULTS_CONFIG_PARAM_MAX
4680 = 20,
4681
4682 /* An array of 6 x unsigned 8-bit value */
4683 QCA_WLAN_VENDOR_ATTR_GSCAN_AP_THRESHOLD_PARAM_BSSID = 21,
4684 /* Signed 32-bit value */
4685 QCA_WLAN_VENDOR_ATTR_GSCAN_AP_THRESHOLD_PARAM_RSSI_LOW = 22,
4686 /* Signed 32-bit value */
4687 QCA_WLAN_VENDOR_ATTR_GSCAN_AP_THRESHOLD_PARAM_RSSI_HIGH = 23,
4688 /* Unsigned 32-bit value */
4689 QCA_WLAN_VENDOR_ATTR_GSCAN_AP_THRESHOLD_PARAM_CHANNEL = 24,
4690
4691 /* Number of hotlist APs as unsigned 32-bit value, followed by a nested
4692 * array of AP_THRESHOLD_PARAM attributes and values. The size of the
4693 * array is determined by NUM_AP.
4694 */
4695 QCA_WLAN_VENDOR_ATTR_GSCAN_BSSID_HOTLIST_PARAMS_NUM_AP = 25,
4696
4697 /* Array of QCA_WLAN_VENDOR_ATTR_GSCAN_AP_THRESHOLD_PARAM_* attributes.
4698 * Array size: QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_NUM_CHANNEL_SPECS
4699 */
4700 QCA_WLAN_VENDOR_ATTR_GSCAN_AP_THRESHOLD_PARAM = 26,
4701
4702 /* Unsigned 32-bit value; number of samples for averaging RSSI. */
4703 QCA_WLAN_VENDOR_ATTR_GSCAN_SIGNIFICANT_CHANGE_PARAMS_RSSI_SAMPLE_SIZE
4704 = 27,
4705 /* Unsigned 32-bit value; number of samples to confirm AP loss. */
4706 QCA_WLAN_VENDOR_ATTR_GSCAN_SIGNIFICANT_CHANGE_PARAMS_LOST_AP_SAMPLE_SIZE
4707 = 28,
4708 /* Unsigned 32-bit value; number of APs breaching threshold. */
4709 QCA_WLAN_VENDOR_ATTR_GSCAN_SIGNIFICANT_CHANGE_PARAMS_MIN_BREACHING = 29,
4710 /* Unsigned 32-bit value; number of APs. Followed by an array of
4711 * AP_THRESHOLD_PARAM attributes. Size of the array is NUM_AP.
4712 */
4713 QCA_WLAN_VENDOR_ATTR_GSCAN_SIGNIFICANT_CHANGE_PARAMS_NUM_AP = 30,
4714 /* Unsigned 32-bit value; number of samples to confirm AP loss. */
4715 QCA_WLAN_VENDOR_ATTR_GSCAN_BSSID_HOTLIST_PARAMS_LOST_AP_SAMPLE_SIZE
4716 = 31,
4717 /* Unsigned 32-bit value. If max_period is non zero or different than
4718 * period, then this bucket is an exponential backoff bucket.
4719 */
4720 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_MAX_PERIOD = 32,
4721 /* Unsigned 32-bit value. */
4722 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_BASE = 33,
4723 /* Unsigned 32-bit value. For exponential back off bucket, number of
4724 * scans to perform for a given period.
4725 */
4726 QCA_WLAN_VENDOR_ATTR_GSCAN_BUCKET_SPEC_STEP_COUNT = 34,
4727 /* Unsigned 8-bit value; in number of scans, wake up AP after these
4728 * many scans.
4729 */
4730 QCA_WLAN_VENDOR_ATTR_GSCAN_SCAN_CMD_PARAMS_REPORT_THRESHOLD_NUM_SCANS
4731 = 35,
4732
4733 /* Attributes for data used by
4734 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_SET_SSID_HOTLIST sub command.
4735 */
4736 /* Unsigned 3-2bit value; number of samples to confirm SSID loss. */
4737 QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_HOTLIST_PARAMS_LOST_SSID_SAMPLE_SIZE
4738 = 36,
4739 /* Number of hotlist SSIDs as unsigned 32-bit value, followed by a
4740 * nested array of SSID_THRESHOLD_PARAM_* attributes and values. The
4741 * size of the array is determined by NUM_SSID.
4742 */
4743 QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_HOTLIST_PARAMS_NUM_SSID = 37,
4744 /* Array of QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_THRESHOLD_PARAM_*
4745 * attributes.
4746 * Array size: QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_HOTLIST_PARAMS_NUM_SSID
4747 */
4748 QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_THRESHOLD_PARAM = 38,
4749
4750 /* An array of 33 x unsigned 8-bit value; NULL terminated SSID */
4751 QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_THRESHOLD_PARAM_SSID = 39,
4752 /* Unsigned 8-bit value */
4753 QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_THRESHOLD_PARAM_BAND = 40,
4754 /* Signed 32-bit value */
4755 QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_THRESHOLD_PARAM_RSSI_LOW = 41,
4756 /* Signed 32-bit value */
4757 QCA_WLAN_VENDOR_ATTR_GSCAN_SSID_THRESHOLD_PARAM_RSSI_HIGH = 42,
4758 /* Unsigned 32-bit value; a bitmask with additional gscan config flag.
4759 */
4760 QCA_WLAN_VENDOR_ATTR_GSCAN_CONFIGURATION_FLAGS = 43,
4761
4762 /* keep last */
4763 QCA_WLAN_VENDOR_ATTR_GSCAN_SUBCMD_CONFIG_PARAM_AFTER_LAST,
4764 QCA_WLAN_VENDOR_ATTR_GSCAN_SUBCMD_CONFIG_PARAM_MAX =
4765 QCA_WLAN_VENDOR_ATTR_GSCAN_SUBCMD_CONFIG_PARAM_AFTER_LAST - 1,
4766};
4767
4768enum qca_wlan_vendor_attr_gscan_results {
4769 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_INVALID = 0,
4770
4771 /* Unsigned 32-bit value; must match the request Id supplied by
4772 * Wi-Fi HAL in the corresponding subcmd NL msg.
4773 */
4774 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_REQUEST_ID = 1,
4775
4776 /* Unsigned 32-bit value; used to indicate the status response from
4777 * firmware/driver for the vendor sub-command.
4778 */
4779 QCA_WLAN_VENDOR_ATTR_GSCAN_STATUS = 2,
4780
4781 /* GSCAN Valid Channels attributes */
4782 /* Unsigned 32bit value; followed by a nested array of CHANNELS. */
4783 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_NUM_CHANNELS = 3,
4784 /* An array of NUM_CHANNELS x unsigned 32-bit value integers
4785 * representing channel numbers.
4786 */
4787 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CHANNELS = 4,
4788
4789 /* GSCAN Capabilities attributes */
4790 /* Unsigned 32-bit value */
4791 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_SCAN_CACHE_SIZE = 5,
4792 /* Unsigned 32-bit value */
4793 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_SCAN_BUCKETS = 6,
4794 /* Unsigned 32-bit value */
4795 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_AP_CACHE_PER_SCAN
4796 = 7,
4797 /* Unsigned 32-bit value */
4798 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_RSSI_SAMPLE_SIZE
4799 = 8,
4800 /* Signed 32-bit value */
4801 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_SCAN_REPORTING_THRESHOLD
4802 = 9,
4803 /* Unsigned 32-bit value */
4804 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_HOTLIST_BSSIDS = 10,
4805 /* Unsigned 32-bit value */
4806 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_SIGNIFICANT_WIFI_CHANGE_APS
4807 = 11,
4808 /* Unsigned 32-bit value */
4809 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_BSSID_HISTORY_ENTRIES
4810 = 12,
4811
4812 /* GSCAN Attributes used with
4813 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_SCAN_RESULTS_AVAILABLE sub-command.
4814 */
4815
4816 /* Unsigned 32-bit value */
4817 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_NUM_RESULTS_AVAILABLE = 13,
4818
4819 /* GSCAN attributes used with
4820 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_FULL_SCAN_RESULT sub-command.
4821 */
4822
4823 /* An array of NUM_RESULTS_AVAILABLE x
4824 * QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_*
4825 */
4826 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_LIST = 14,
4827
4828 /* Unsigned 64-bit value; age of sample at the time of retrieval */
4829 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_TIME_STAMP = 15,
4830 /* 33 x unsigned 8-bit value; NULL terminated SSID */
4831 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_SSID = 16,
4832 /* An array of 6 x unsigned 8-bit value */
4833 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_BSSID = 17,
4834 /* Unsigned 32-bit value; channel frequency in MHz */
4835 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_CHANNEL = 18,
4836 /* Signed 32-bit value */
4837 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_RSSI = 19,
4838 /* Unsigned 32-bit value */
4839 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_RTT = 20,
4840 /* Unsigned 32-bit value */
4841 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_RTT_SD = 21,
4842 /* Unsigned 16-bit value */
4843 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_BEACON_PERIOD = 22,
4844 /* Unsigned 16-bit value */
4845 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_CAPABILITY = 23,
4846 /* Unsigned 32-bit value; size of the IE DATA blob */
4847 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_IE_LENGTH = 24,
4848 /* An array of IE_LENGTH x unsigned 8-bit value; blob of all the
4849 * information elements found in the beacon; this data should be a
4850 * packed list of wifi_information_element objects, one after the
4851 * other.
4852 */
4853 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_IE_DATA = 25,
4854
4855 /* Unsigned 8-bit value; set by driver to indicate more scan results are
4856 * available.
4857 */
4858 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_RESULT_MORE_DATA = 26,
4859
4860 /* GSCAN attributes for
4861 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_SCAN_EVENT sub-command.
4862 */
4863 /* Unsigned 8-bit value */
4864 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_EVENT_TYPE = 27,
4865 /* Unsigned 32-bit value */
4866 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SCAN_EVENT_STATUS = 28,
4867
4868 /* GSCAN attributes for
4869 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_HOTLIST_AP_FOUND sub-command.
4870 */
4871 /* Use attr QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_NUM_RESULTS_AVAILABLE
4872 * to indicate number of results.
4873 * Also, use QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_LIST to indicate the
4874 * list of results.
4875 */
4876
4877 /* GSCAN attributes for
4878 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_SIGNIFICANT_CHANGE sub-command.
4879 */
4880 /* An array of 6 x unsigned 8-bit value */
4881 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SIGNIFICANT_CHANGE_RESULT_BSSID = 29,
4882 /* Unsigned 32-bit value */
4883 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SIGNIFICANT_CHANGE_RESULT_CHANNEL
4884 = 30,
4885 /* Unsigned 32-bit value. */
4886 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SIGNIFICANT_CHANGE_RESULT_NUM_RSSI
4887 = 31,
4888 /* A nested array of signed 32-bit RSSI values. Size of the array is
4889 * determined by (NUM_RSSI of SIGNIFICANT_CHANGE_RESULT_NUM_RSSI.
4890 */
4891 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_SIGNIFICANT_CHANGE_RESULT_RSSI_LIST
4892 = 32,
4893
4894 /* GSCAN attributes used with
4895 * QCA_NL80211_VENDOR_SUBCMD_GSCAN_GET_CACHED_RESULTS sub-command.
4896 */
4897 /* Use attr QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_NUM_RESULTS_AVAILABLE
4898 * to indicate number of gscan cached results returned.
4899 * Also, use QCA_WLAN_VENDOR_ATTR_GSCAN_CACHED_RESULTS_LIST to indicate
4900 * the list of gscan cached results.
4901 */
4902
4903 /* An array of NUM_RESULTS_AVAILABLE x
4904 * QCA_NL80211_VENDOR_ATTR_GSCAN_CACHED_RESULTS_*
4905 */
4906 QCA_WLAN_VENDOR_ATTR_GSCAN_CACHED_RESULTS_LIST = 33,
4907 /* Unsigned 32-bit value; a unique identifier for the scan unit. */
4908 QCA_WLAN_VENDOR_ATTR_GSCAN_CACHED_RESULTS_SCAN_ID = 34,
4909 /* Unsigned 32-bit value; a bitmask w/additional information about scan.
4910 */
4911 QCA_WLAN_VENDOR_ATTR_GSCAN_CACHED_RESULTS_FLAGS = 35,
4912 /* Use attr QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_NUM_RESULTS_AVAILABLE
4913 * to indicate number of wifi scan results/bssids retrieved by the scan.
4914 * Also, use QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_LIST to indicate the
4915 * list of wifi scan results returned for each cached result block.
4916 */
4917
4918 /* GSCAN attributes for
4919 * QCA_NL80211_VENDOR_SUBCMD_PNO_NETWORK_FOUND sub-command.
4920 */
4921 /* Use QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_NUM_RESULTS_AVAILABLE for
4922 * number of results.
4923 * Use QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_LIST to indicate the nested
4924 * list of wifi scan results returned for each
4925 * wifi_passpoint_match_result block.
4926 * Array size: QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_NUM_RESULTS_AVAILABLE.
4927 */
4928
4929 /* GSCAN attributes for
4930 * QCA_NL80211_VENDOR_SUBCMD_PNO_PASSPOINT_NETWORK_FOUND sub-command.
4931 */
4932 /* Unsigned 32-bit value */
4933 QCA_WLAN_VENDOR_ATTR_GSCAN_PNO_RESULTS_PASSPOINT_NETWORK_FOUND_NUM_MATCHES
4934 = 36,
4935 /* A nested array of
4936 * QCA_WLAN_VENDOR_ATTR_GSCAN_PNO_RESULTS_PASSPOINT_MATCH_*
4937 * attributes. Array size =
4938 * *_ATTR_GSCAN_PNO_RESULTS_PASSPOINT_NETWORK_FOUND_NUM_MATCHES.
4939 */
4940 QCA_WLAN_VENDOR_ATTR_GSCAN_PNO_RESULTS_PASSPOINT_MATCH_RESULT_LIST = 37,
4941
4942 /* Unsigned 32-bit value; network block id for the matched network */
4943 QCA_WLAN_VENDOR_ATTR_GSCAN_PNO_RESULTS_PASSPOINT_MATCH_ID = 38,
4944 /* Use QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_LIST to indicate the nested
4945 * list of wifi scan results returned for each
4946 * wifi_passpoint_match_result block.
4947 */
4948 /* Unsigned 32-bit value */
4949 QCA_WLAN_VENDOR_ATTR_GSCAN_PNO_RESULTS_PASSPOINT_MATCH_ANQP_LEN = 39,
4950 /* An array size of PASSPOINT_MATCH_ANQP_LEN of unsigned 8-bit values;
4951 * ANQP data in the information_element format.
4952 */
4953 QCA_WLAN_VENDOR_ATTR_GSCAN_PNO_RESULTS_PASSPOINT_MATCH_ANQP = 40,
4954
4955 /* Unsigned 32-bit value; a GSCAN Capabilities attribute. */
4956 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_HOTLIST_SSIDS = 41,
4957 /* Unsigned 32-bit value; a GSCAN Capabilities attribute. */
4958 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_NUM_EPNO_NETS = 42,
4959 /* Unsigned 32-bit value; a GSCAN Capabilities attribute. */
4960 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_NUM_EPNO_NETS_BY_SSID
4961 = 43,
4962 /* Unsigned 32-bit value; a GSCAN Capabilities attribute. */
4963 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_CAPABILITIES_MAX_NUM_WHITELISTED_SSID
4964 = 44,
4965
4966 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_BUCKETS_SCANNED = 45,
4967
Arif Hussainf89fefa2018-08-30 12:11:01 -07004968 /* Unsigned 32-bit value; a GSCAN Capabilities attribute.
4969 * This is used to limit the maximum number of BSSIDs while sending
Jouni Malinenf735abd2020-08-03 11:08:00 +03004970 * the vendor command QCA_NL80211_VENDOR_SUBCMD_ROAM with subcmd
4971 * QCA_WLAN_VENDOR_ROAMING_SUBCMD_SET_BLACKLIST_BSSID and attribute
Arif Hussainf89fefa2018-08-30 12:11:01 -07004972 * QCA_WLAN_VENDOR_ATTR_ROAMING_PARAM_SET_BSSID_PARAMS_NUM_BSSID.
4973 */
4974 QCA_WLAN_VENDOR_ATTR_GSCAN_MAX_NUM_BLACKLISTED_BSSID = 46,
4975
Peng Xu291d97d2018-01-31 16:34:03 -08004976 /* keep last */
4977 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_AFTER_LAST,
4978 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_MAX =
4979 QCA_WLAN_VENDOR_ATTR_GSCAN_RESULTS_AFTER_LAST - 1,
4980};
4981
4982enum qca_wlan_vendor_attr_pno_config_params {
4983 QCA_WLAN_VENDOR_ATTR_PNO_INVALID = 0,
4984 /* Attributes for data used by
4985 * QCA_NL80211_VENDOR_SUBCMD_PNO_SET_PASSPOINT_LIST sub command.
4986 */
4987 /* Unsigned 32-bit value */
4988 QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_LIST_PARAM_NUM = 1,
4989 /* Array of nested QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_*
4990 * attributes. Array size =
4991 * QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_LIST_PARAM_NUM.
4992 */
4993 QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_LIST_PARAM_NETWORK_ARRAY = 2,
4994
4995 /* Unsigned 32-bit value */
4996 QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ID = 3,
4997 /* An array of 256 x unsigned 8-bit value; NULL terminated UTF-8 encoded
4998 * realm, 0 if unspecified.
4999 */
5000 QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_REALM = 4,
5001 /* An array of 16 x unsigned 32-bit value; roaming consortium ids to
5002 * match, 0 if unspecified.
5003 */
5004 QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ROAM_CNSRTM_ID = 5,
5005 /* An array of 6 x unsigned 8-bit value; MCC/MNC combination, 0s if
5006 * unspecified.
5007 */
5008 QCA_WLAN_VENDOR_ATTR_PNO_PASSPOINT_NETWORK_PARAM_ROAM_PLMN = 6,
5009
5010 /* Attributes for data used by
5011 * QCA_NL80211_VENDOR_SUBCMD_PNO_SET_LIST sub command.
5012 */
5013 /* Unsigned 32-bit value */
5014 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_NUM_NETWORKS = 7,
5015 /* Array of nested
5016 * QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_*
5017 * attributes. Array size =
5018 * QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_NUM_NETWORKS.
5019 */
5020 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORKS_LIST = 8,
5021 /* An array of 33 x unsigned 8-bit value; NULL terminated SSID */
5022 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_SSID = 9,
5023 /* Signed 8-bit value; threshold for considering this SSID as found,
5024 * required granularity for this threshold is 4 dBm to 8 dBm.
5025 */
5026 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_RSSI_THRESHOLD
5027 = 10,
5028 /* Unsigned 8-bit value; WIFI_PNO_FLAG_XXX */
5029 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_FLAGS = 11,
5030 /* Unsigned 8-bit value; auth bit field for matching WPA IE */
5031 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_NETWORK_AUTH_BIT = 12,
5032 /* Unsigned 8-bit to indicate ePNO type;
5033 * It takes values from qca_wlan_epno_type
5034 */
5035 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_TYPE = 13,
5036
5037 /* Nested attribute to send the channel list */
5038 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_CHANNEL_LIST = 14,
5039
5040 /* Unsigned 32-bit value; indicates the interval between PNO scan
5041 * cycles in msec.
5042 */
5043 QCA_WLAN_VENDOR_ATTR_PNO_SET_LIST_PARAM_EPNO_SCAN_INTERVAL = 15,
5044 QCA_WLAN_VENDOR_ATTR_EPNO_MIN5GHZ_RSSI = 16,
5045 QCA_WLAN_VENDOR_ATTR_EPNO_MIN24GHZ_RSSI = 17,
5046 QCA_WLAN_VENDOR_ATTR_EPNO_INITIAL_SCORE_MAX = 18,
5047 QCA_WLAN_VENDOR_ATTR_EPNO_CURRENT_CONNECTION_BONUS = 19,
5048 QCA_WLAN_VENDOR_ATTR_EPNO_SAME_NETWORK_BONUS = 20,
5049 QCA_WLAN_VENDOR_ATTR_EPNO_SECURE_BONUS = 21,
5050 QCA_WLAN_VENDOR_ATTR_EPNO_BAND5GHZ_BONUS = 22,
5051 /* Unsigned 32-bit value, representing the PNO Request ID */
5052 QCA_WLAN_VENDOR_ATTR_PNO_CONFIG_REQUEST_ID = 23,
5053
5054 /* keep last */
5055 QCA_WLAN_VENDOR_ATTR_PNO_AFTER_LAST,
5056 QCA_WLAN_VENDOR_ATTR_PNO_MAX =
5057 QCA_WLAN_VENDOR_ATTR_PNO_AFTER_LAST - 1,
5058};
5059
5060/**
5061 * qca_wlan_vendor_acs_select_reason: This represents the different reasons why
5062 * the ACS has to be triggered. These values are used by
5063 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_REASON and
5064 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_REASON
5065 */
5066enum qca_wlan_vendor_acs_select_reason {
5067 /* Represents the reason that the ACS triggered during the AP start */
5068 QCA_WLAN_VENDOR_ACS_SELECT_REASON_INIT,
5069 /* Represents the reason that DFS found with the current channel */
5070 QCA_WLAN_VENDOR_ACS_SELECT_REASON_DFS,
5071 /* Represents the reason that LTE co-exist in the current band. */
5072 QCA_WLAN_VENDOR_ACS_SELECT_REASON_LTE_COEX,
Jouni Malinenf735abd2020-08-03 11:08:00 +03005073 /* Represents the reason that generic, uncategorized interference has
5074 * been found in the current channel.
5075 */
5076 QCA_WLAN_VENDOR_ACS_SELECT_REASON_GENERIC_INTERFERENCE,
5077 /* Represents the reason that excessive 802.11 interference has been
5078 * found in the current channel.
5079 */
5080 QCA_WLAN_VENDOR_ACS_SELECT_REASON_80211_INTERFERENCE,
5081 /* Represents the reason that generic Continuous Wave (CW) interference
5082 * has been found in the current channel.
5083 */
5084 QCA_WLAN_VENDOR_ACS_SELECT_REASON_CW_INTERFERENCE,
5085 /* Represents the reason that Microwave Oven (MWO) interference has been
5086 * found in the current channel.
5087 */
5088 QCA_WLAN_VENDOR_ACS_SELECT_REASON_MWO_INTERFERENCE,
5089 /* Represents the reason that generic Frequency-Hopping Spread Spectrum
5090 * (FHSS) interference has been found in the current channel. This may
5091 * include 802.11 waveforms.
5092 */
5093 QCA_WLAN_VENDOR_ACS_SELECT_REASON_FHSS_INTERFERENCE,
5094 /* Represents the reason that non-802.11 generic Frequency-Hopping
5095 * Spread Spectrum (FHSS) interference has been found in the current
5096 * channel.
5097 */
5098 QCA_WLAN_VENDOR_ACS_SELECT_REASON_NON_80211_FHSS_INTERFERENCE,
5099 /* Represents the reason that generic Wideband (WB) interference has
5100 * been found in the current channel. This may include 802.11 waveforms.
5101 */
5102 QCA_WLAN_VENDOR_ACS_SELECT_REASON_WB_INTERFERENCE,
5103 /* Represents the reason that non-802.11 generic Wideband (WB)
5104 * interference has been found in the current channel.
5105 */
5106 QCA_WLAN_VENDOR_ACS_SELECT_REASON_NON_80211_WB_INTERFERENCE,
5107 /* Represents the reason that Jammer interference has been found in the
5108 * current channel.
5109 */
5110 QCA_WLAN_VENDOR_ACS_SELECT_REASON_JAMMER_INTERFERENCE,
Peng Xu291d97d2018-01-31 16:34:03 -08005111};
5112
5113/**
5114 * qca_wlan_vendor_attr_external_acs_policy: Attribute values for
5115 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_POLICY to the vendor subcmd
5116 * QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS. This represents the
5117 * external ACS policies to select the channels w.r.t. the PCL weights.
5118 * (QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_PCL represents the channels and
5119 * their PCL weights.)
5120 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_POLICY_PCL_MANDATORY: Mandatory to
5121 * select a channel with non-zero PCL weight.
5122 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_POLICY_PCL_PREFERRED: Prefer a
5123 * channel with non-zero PCL weight.
5124 *
5125 */
5126enum qca_wlan_vendor_attr_external_acs_policy {
5127 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_POLICY_PCL_PREFERRED,
5128 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_POLICY_PCL_MANDATORY,
5129};
5130
5131/**
5132 * qca_wlan_vendor_channel_prop_flags: This represent the flags for a channel.
5133 * This is used by QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FLAGS.
5134 */
5135enum qca_wlan_vendor_channel_prop_flags {
5136 /* Bits 0, 1, 2, and 3 are reserved */
5137
5138 /* Turbo channel */
5139 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_TURBO = 1 << 4,
5140 /* CCK channel */
5141 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_CCK = 1 << 5,
5142 /* OFDM channel */
5143 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_OFDM = 1 << 6,
5144 /* 2.4 GHz spectrum channel. */
5145 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_2GHZ = 1 << 7,
5146 /* 5 GHz spectrum channel */
5147 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_5GHZ = 1 << 8,
5148 /* Only passive scan allowed */
5149 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_PASSIVE = 1 << 9,
5150 /* Dynamic CCK-OFDM channel */
5151 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_DYN = 1 << 10,
5152 /* GFSK channel (FHSS PHY) */
5153 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_GFSK = 1 << 11,
5154 /* Radar found on channel */
5155 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_RADAR = 1 << 12,
5156 /* 11a static turbo channel only */
5157 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_STURBO = 1 << 13,
5158 /* Half rate channel */
5159 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HALF = 1 << 14,
5160 /* Quarter rate channel */
5161 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_QUARTER = 1 << 15,
5162 /* HT 20 channel */
5163 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HT20 = 1 << 16,
5164 /* HT 40 with extension channel above */
5165 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HT40PLUS = 1 << 17,
5166 /* HT 40 with extension channel below */
5167 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HT40MINUS = 1 << 18,
5168 /* HT 40 intolerant */
5169 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HT40INTOL = 1 << 19,
5170 /* VHT 20 channel */
5171 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_VHT20 = 1 << 20,
5172 /* VHT 40 with extension channel above */
5173 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_VHT40PLUS = 1 << 21,
5174 /* VHT 40 with extension channel below */
5175 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_VHT40MINUS = 1 << 22,
5176 /* VHT 80 channel */
5177 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_VHT80 = 1 << 23,
5178 /* HT 40 intolerant mark bit for ACS use */
5179 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HT40INTOLMARK = 1 << 24,
5180 /* Channel temporarily blocked due to noise */
5181 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_BLOCKED = 1 << 25,
5182 /* VHT 160 channel */
5183 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_VHT160 = 1 << 26,
5184 /* VHT 80+80 channel */
5185 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_VHT80_80 = 1 << 27,
5186 /* HE 20 channel */
5187 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE20 = 1 << 28,
5188 /* HE 40 with extension channel above */
5189 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE40PLUS = 1 << 29,
5190 /* HE 40 with extension channel below */
5191 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE40MINUS = 1 << 30,
5192 /* HE 40 intolerant */
5193 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE40INTOL = 1 << 31,
5194};
5195
5196/**
5197 * qca_wlan_vendor_channel_prop_flags_2: This represents the flags for a
5198 * channel, and is a continuation of qca_wlan_vendor_channel_prop_flags. This is
5199 * used by QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FLAGS_2.
5200 */
5201enum qca_wlan_vendor_channel_prop_flags_2 {
5202 /* HE 40 intolerant mark bit for ACS use */
5203 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE40INTOLMARK = 1 << 0,
5204 /* HE 80 channel */
5205 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE80 = 1 << 1,
5206 /* HE 160 channel */
5207 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE160 = 1 << 2,
5208 /* HE 80+80 channel */
5209 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_HE80_80 = 1 << 3,
5210};
5211
5212/**
5213 * qca_wlan_vendor_channel_prop_flags_ext: This represent the extended flags for
5214 * each channel. This is used by
5215 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FLAG_EXT.
5216 */
5217enum qca_wlan_vendor_channel_prop_flags_ext {
5218 /* Radar found on channel */
5219 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_RADAR_FOUND = 1 << 0,
5220 /* DFS required on channel */
5221 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_DFS = 1 << 1,
5222 /* DFS required on channel for 2nd band of 80+80 */
5223 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_DFS_CFREQ2 = 1 << 2,
5224 /* If channel has been checked for DFS */
5225 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_DFS_CLEAR = 1 << 3,
5226 /* Excluded in 802.11d */
5227 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_11D_EXCLUDED = 1 << 4,
5228 /* Channel Switch Announcement received on this channel */
5229 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_CSA_RECEIVED = 1 << 5,
5230 /* Ad-hoc is not allowed */
5231 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_DISALLOW_ADHOC = 1 << 6,
5232 /* Station only channel */
5233 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_DISALLOW_HOSTAP = 1 << 7,
Jouni Malinenf735abd2020-08-03 11:08:00 +03005234 /* DFS radar history for client device (STA mode) */
Peng Xu291d97d2018-01-31 16:34:03 -08005235 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_HISTORY_RADAR = 1 << 8,
Jouni Malinenf735abd2020-08-03 11:08:00 +03005236 /* DFS CAC valid for client device (STA mode) */
Peng Xu291d97d2018-01-31 16:34:03 -08005237 QCA_WLAN_VENDOR_CHANNEL_PROP_FLAG_EXT_CAC_VALID = 1 << 9,
5238};
5239
5240/**
5241 * qca_wlan_vendor_external_acs_event_chan_info_attr: Represents per channel
5242 * information. These attributes are sent as part of
5243 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_CHAN_INFO. Each set of the following
5244 * attributes correspond to a single channel.
5245 */
5246enum qca_wlan_vendor_external_acs_event_chan_info_attr {
5247 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_INVALID = 0,
5248
5249 /* A bitmask (u32) with flags specified in
5250 * enum qca_wlan_vendor_channel_prop_flags.
5251 */
5252 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FLAGS = 1,
5253 /* A bitmask (u32) with flags specified in
5254 * enum qca_wlan_vendor_channel_prop_flags_ext.
5255 */
5256 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FLAG_EXT = 2,
5257 /* frequency in MHz (u32) */
5258 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ = 3,
5259 /* maximum regulatory transmission power (u32) */
5260 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_MAX_REG_POWER = 4,
5261 /* maximum transmission power (u32) */
5262 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_MAX_POWER = 5,
5263 /* minimum transmission power (u32) */
5264 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_MIN_POWER = 6,
5265 /* regulatory class id (u8) */
5266 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_REG_CLASS_ID = 7,
5267 /* maximum antenna gain in (u8) */
5268 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_ANTENNA_GAIN = 8,
5269 /* VHT segment 0 (u8) */
5270 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_VHT_SEG_0 = 9,
5271 /* VHT segment 1 (u8) */
5272 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_VHT_SEG_1 = 10,
5273 /* A bitmask (u32) with flags specified in
5274 * enum qca_wlan_vendor_channel_prop_flags_2.
5275 */
5276 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FLAGS_2 = 11,
5277
Jouni Malinenf735abd2020-08-03 11:08:00 +03005278 /*
5279 * VHT segment 0 in MHz (u32) and the attribute is mandatory.
5280 * Note: Event QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS includes
5281 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_0
5282 * along with
5283 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_VHT_SEG_0.
5284 *
5285 * If both the driver and user-space application supports the 6 GHz
5286 * band, QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_VHT_SEG_0
5287 * is deprecated and
5288 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_0
5289 * should be used.
5290 *
5291 * To maintain backward compatibility,
5292 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_0
5293 * is still used if either of the driver or user space application
5294 * doesn't support the 6 GHz band.
5295 */
5296 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_0 = 12,
5297
5298 /*
5299 * VHT segment 1 in MHz (u32) and the attribute is mandatory.
5300 * Note: Event QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS includes
5301 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_1
5302 * along with
5303 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_VHT_SEG_1.
5304 *
5305 * If both the driver and user-space application supports the 6 GHz
5306 * band, QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_VHT_SEG_1
5307 * is deprecated and
5308 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_1
5309 * should be considered.
5310 *
5311 * To maintain backward compatibility,
5312 * QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_1
5313 * is still used if either of the driver or user space application
5314 * doesn't support the 6 GHz band.
5315 */
5316 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_FREQ_VHT_SEG_1 = 13,
5317
Peng Xu291d97d2018-01-31 16:34:03 -08005318 /* keep last */
5319 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_LAST,
5320 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_MAX =
5321 QCA_WLAN_VENDOR_EXTERNAL_ACS_EVENT_CHAN_INFO_ATTR_LAST - 1,
5322};
5323
5324/**
5325 * qca_wlan_vendor_attr_pcl: Represents attributes for
5326 * preferred channel list (PCL). These attributes are sent as part of
5327 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_PCL and
5328 * QCA_NL80211_VENDOR_SUBCMD_GET_PREFERRED_FREQ_LIST.
5329 */
5330enum qca_wlan_vendor_attr_pcl {
5331 QCA_WLAN_VENDOR_ATTR_PCL_INVALID = 0,
5332
5333 /* Channel number (u8) */
5334 QCA_WLAN_VENDOR_ATTR_PCL_CHANNEL = 1,
5335 /* Channel weightage (u8) */
5336 QCA_WLAN_VENDOR_ATTR_PCL_WEIGHT = 2,
5337 /* Channel frequency (u32) in MHz */
5338 QCA_WLAN_VENDOR_ATTR_PCL_FREQ = 3,
5339 /* Channel flags (u32)
5340 * bit 0 set: channel to be used for GO role,
5341 * bit 1 set: channel to be used on CLI role,
5342 * bit 2 set: channel must be considered for operating channel
5343 * selection & peer chosen operating channel should be
5344 * one of the channels with this flag set,
5345 * bit 3 set: channel should be excluded in GO negotiation
5346 */
5347 QCA_WLAN_VENDOR_ATTR_PCL_FLAG = 4,
5348};
5349
5350/**
5351 * qca_wlan_vendor_attr_external_acs_event: Attribute to vendor sub-command
5352 * QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS. This attribute will be sent by
5353 * host driver.
5354 */
5355enum qca_wlan_vendor_attr_external_acs_event {
5356 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_INVALID = 0,
5357
5358 /* This reason (u8) refers to enum qca_wlan_vendor_acs_select_reason.
5359 * This helps ACS module to understand why ACS needs to be started.
5360 */
5361 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_REASON = 1,
5362 /* Flag attribute to indicate if driver supports spectral scanning */
5363 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_IS_SPECTRAL_SUPPORTED = 2,
5364 /* Flag attribute to indicate if 11ac is offloaded to firmware */
5365 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_IS_OFFLOAD_ENABLED = 3,
5366 /* Flag attribute to indicate if driver provides additional channel
Arif Hussaine2645c62018-05-24 20:39:04 -07005367 * capability as part of scan operation
5368 */
Peng Xu291d97d2018-01-31 16:34:03 -08005369 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_ADD_CHAN_STATS_SUPPORT = 4,
5370 /* Flag attribute to indicate interface status is UP */
5371 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_AP_UP = 5,
5372 /* Operating mode (u8) of interface. Takes one of enum nl80211_iftype
Arif Hussaine2645c62018-05-24 20:39:04 -07005373 * values.
5374 */
Peng Xu291d97d2018-01-31 16:34:03 -08005375 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_SAP_MODE = 6,
5376 /* Channel width (u8). It takes one of enum nl80211_chan_width values.
5377 * This is the upper bound of channel width. ACS logic should try to get
5378 * a channel with the specified width and if not found, look for lower
5379 * values.
5380 */
5381 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_CHAN_WIDTH = 7,
5382 /* This (u8) will hold values of one of enum nl80211_bands */
5383 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_BAND = 8,
5384 /* PHY/HW mode (u8). Takes one of enum qca_wlan_vendor_acs_hw_mode
Arif Hussaine2645c62018-05-24 20:39:04 -07005385 * values
5386 */
Peng Xu291d97d2018-01-31 16:34:03 -08005387 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_PHY_MODE = 9,
5388 /* Array of (u32) supported frequency list among which ACS should choose
5389 * best frequency.
5390 */
5391 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_FREQ_LIST = 10,
5392 /* Preferred channel list by the driver which will have array of nested
5393 * values as per enum qca_wlan_vendor_attr_pcl attribute.
5394 */
5395 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_PCL = 11,
5396 /* Array of nested attribute for each channel. It takes attr as defined
5397 * in enum qca_wlan_vendor_external_acs_event_chan_info_attr.
5398 */
5399 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_CHAN_INFO = 12,
5400 /* External ACS policy such as PCL mandatory, PCL preferred, etc.
5401 * It uses values defined in enum
5402 * qca_wlan_vendor_attr_external_acs_policy.
5403 */
5404 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_POLICY = 13,
5405 /* Reference RF Operating Parameter (RROP) availability information
5406 * (u16). It uses values defined in enum
5407 * qca_wlan_vendor_attr_rropavail_info.
5408 */
5409 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_RROPAVAIL_INFO = 14,
5410
5411 /* keep last */
5412 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_LAST,
5413 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_MAX =
5414 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_EVENT_LAST - 1,
5415};
5416
5417/**
Jouni Malinenf735abd2020-08-03 11:08:00 +03005418 * enum qca_wlan_vendor_attr_external_acs_channels: Attributes to vendor subcmd
Peng Xu291d97d2018-01-31 16:34:03 -08005419 * QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS. This carries a list of channels
5420 * in priority order as decided after ACS operation in userspace.
Jouni Malinenf735abd2020-08-03 11:08:00 +03005421 *
5422 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_REASON: Required (u8).
5423 * One of reason code from enum qca_wlan_vendor_acs_select_reason.
5424 *
5425 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_LIST: Required
5426 * Array of nested values for each channel with following attributes:
5427 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_PRIMARY,
5428 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_SECONDARY,
5429 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG0,
5430 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG1,
5431 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_WIDTH
5432 * Note: If both the driver and user-space application supports the 6 GHz band,
5433 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_LIST is deprecated and use
5434 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_LIST.
5435 * To maintain backward compatibility,
5436 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_LIST
5437 * is still used if either of the driver or user space application doesn't
5438 * support the 6 GHz band.
5439 *
5440 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_PRIMARY: Required (u8).
5441 * Primary channel number
5442 * Note: If both the driver and user-space application supports the 6 GHz band,
5443 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_PRIMARY is deprecated and use
5444 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_PRIMARY.
5445 * To maintain backward compatibility,
5446 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_PRIMARY
5447 * is still used if either of the driver or user space application doesn't
5448 * support the 6 GHz band.
5449 *
5450 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_SECONDARY: Required (u8).
5451 * Secondary channel number, required only for 160 and 80+80 MHz bandwidths.
5452 * Note: If both the driver and user-space application supports the 6 GHz band,
5453 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_SECONDARY is deprecated and use
5454 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_SECONDARY.
5455 * To maintain backward compatibility,
5456 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_SECONDARY
5457 * is still used if either of the driver or user space application
5458 * doesn't support the 6 GHz band.
5459 *
5460 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG0: Required (u8).
5461 * VHT seg0 channel number
5462 * Note: If both the driver and user-space application supports the 6 GHz band,
5463 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG0 is deprecated and use
5464 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG0.
5465 * To maintain backward compatibility,
5466 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG0
5467 * is still used if either of the driver or user space application
5468 * doesn't support the 6 GHz band.
5469 *
5470 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG1: Required (u8).
5471 * VHT seg1 channel number
5472 * Note: If both the driver and user-space application supports the 6 GHz band,
5473 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG1 is deprecated and use
5474 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG1.
5475 * To maintain backward compatibility,
5476 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG1
5477 * is still used if either of the driver or user space application
5478 * doesn't support the 6 GHz band.
5479 *
5480 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_WIDTH: Required (u8).
5481 * Takes one of enum nl80211_chan_width values.
5482 *
5483 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_LIST: Required
5484 * Array of nested values for each channel with following attributes:
5485 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_PRIMARY in MHz (u32),
5486 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_SECONDARY in MHz (u32),
5487 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG0 in MHz (u32),
5488 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG1 in MHz (u32),
5489 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_WIDTH
5490 * Note: If user-space application has no support of the 6 GHz band, this
5491 * attribute is optional.
5492 *
5493 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_PRIMARY: Required (u32)
5494 * Primary channel frequency in MHz
5495 * Note: If user-space application has no support of the 6 GHz band, this
5496 * attribute is optional.
5497 *
5498 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_SECONDARY: Required (u32)
5499 * Secondary channel frequency in MHz used for HT 40 MHz channels.
5500 * Note: If user-space application has no support of the 6 GHz band, this
5501 * attribute is optional.
5502 *
5503 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG0: Required (u32)
5504 * VHT seg0 channel frequency in MHz
5505 * Note: If user-space application has no support of the 6GHz band, this
5506 * attribute is optional.
5507 *
5508 * @QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG1: Required (u32)
5509 * VHT seg1 channel frequency in MHz
5510 * Note: If user-space application has no support of the 6 GHz band, this
5511 * attribute is optional.
Peng Xu291d97d2018-01-31 16:34:03 -08005512 */
5513enum qca_wlan_vendor_attr_external_acs_channels {
5514 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_INVALID = 0,
5515
5516 /* One of reason code (u8) from enum qca_wlan_vendor_acs_select_reason
5517 */
5518 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_REASON = 1,
5519
5520 /* Array of nested values for each channel with following attributes:
5521 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_BAND,
5522 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_PRIMARY,
5523 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_SECONDARY,
5524 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG0,
5525 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG1,
5526 * QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_WIDTH
5527 */
5528 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_LIST = 2,
5529 /* This (u8) will hold values of one of enum nl80211_bands */
5530 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_BAND = 3,
5531 /* Primary channel (u8) */
5532 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_PRIMARY = 4,
5533 /* Secondary channel (u8) used for HT 40 MHz channels */
5534 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_SECONDARY = 5,
5535 /* VHT seg0 channel (u8) */
5536 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG0 = 6,
5537 /* VHT seg1 channel (u8) */
5538 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_CENTER_SEG1 = 7,
5539 /* Channel width (u8). Takes one of enum nl80211_chan_width values. */
5540 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_WIDTH = 8,
5541
Jouni Malinenf735abd2020-08-03 11:08:00 +03005542 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_LIST = 9,
5543 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_PRIMARY = 10,
5544 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_SECONDARY = 11,
5545 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG0 = 12,
5546 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_FREQUENCY_CENTER_SEG1 = 13,
5547
Peng Xu291d97d2018-01-31 16:34:03 -08005548 /* keep last */
5549 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_LAST,
5550 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_MAX =
5551 QCA_WLAN_VENDOR_ATTR_EXTERNAL_ACS_CHANNEL_LAST - 1
5552};
5553
5554enum qca_chip_power_save_failure_reason {
5555 /* Indicates if the reason for the failure is due to a protocol
5556 * layer/module.
5557 */
Arif Hussaine2645c62018-05-24 20:39:04 -07005558 QCA_CHIP_POWER_SAVE_FAILURE_REASON_PROTOCOL = 0,
Peng Xu291d97d2018-01-31 16:34:03 -08005559 /* Indicates if the reason for the failure is due to a hardware issue.
5560 */
Arif Hussaine2645c62018-05-24 20:39:04 -07005561 QCA_CHIP_POWER_SAVE_FAILURE_REASON_HARDWARE = 1,
Peng Xu291d97d2018-01-31 16:34:03 -08005562};
5563
5564/**
5565 * qca_attr_chip_power_save_failure: Attributes to vendor subcmd
5566 * QCA_NL80211_VENDOR_SUBCMD_CHIP_PWRSAVE_FAILURE. This carries the requisite
5567 * information leading to the power save failure.
5568 */
5569enum qca_attr_chip_power_save_failure {
Arif Hussaine2645c62018-05-24 20:39:04 -07005570 QCA_ATTR_CHIP_POWER_SAVE_FAILURE_INVALID = 0,
5571 /* Reason to cause the power save failure.
Peng Xu291d97d2018-01-31 16:34:03 -08005572 * These reasons are represented by
5573 * enum qca_chip_power_save_failure_reason.
5574 */
Arif Hussaine2645c62018-05-24 20:39:04 -07005575 QCA_ATTR_CHIP_POWER_SAVE_FAILURE_REASON = 1,
Peng Xu291d97d2018-01-31 16:34:03 -08005576
Arif Hussaine2645c62018-05-24 20:39:04 -07005577 /* keep last */
5578 QCA_ATTR_CHIP_POWER_SAVE_FAILURE_LAST,
5579 QCA_ATTR_CHIP_POWER_SAVE_FAILURE_MAX =
5580 QCA_ATTR_CHIP_POWER_SAVE_FAILURE_LAST - 1,
Peng Xu291d97d2018-01-31 16:34:03 -08005581};
5582
5583/**
5584 * qca_wlan_vendor_nud_stats_data_pkt_flags: Flag representing the various
5585 * data types for which the stats have to get collected.
5586 */
5587enum qca_wlan_vendor_nud_stats_data_pkt_flags {
5588 QCA_WLAN_VENDOR_NUD_STATS_DATA_ARP = 1 << 0,
5589 QCA_WLAN_VENDOR_NUD_STATS_DATA_DNS = 1 << 1,
5590 QCA_WLAN_VENDOR_NUD_STATS_DATA_TCP_HANDSHAKE = 1 << 2,
5591 QCA_WLAN_VENDOR_NUD_STATS_DATA_ICMPV4 = 1 << 3,
5592 QCA_WLAN_VENDOR_NUD_STATS_DATA_ICMPV6 = 1 << 4,
5593 /* Used by QCA_ATTR_NUD_STATS_PKT_TYPE only in nud stats get
5594 * to represent the stats of respective data type.
5595 */
5596 QCA_WLAN_VENDOR_NUD_STATS_DATA_TCP_SYN = 1 << 5,
5597 QCA_WLAN_VENDOR_NUD_STATS_DATA_TCP_SYN_ACK = 1 << 6,
5598 QCA_WLAN_VENDOR_NUD_STATS_DATA_TCP_ACK = 1 << 7,
5599};
5600
5601enum qca_wlan_vendor_nud_stats_set_data_pkt_info {
5602 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_INVALID = 0,
5603 /* Represents the data packet type to be monitored (u32).
5604 * Host driver tracks the stats corresponding to each data frame
5605 * represented by these flags.
5606 * These data packets are represented by
5607 * enum qca_wlan_vendor_nud_stats_data_pkt_flags
5608 */
5609 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_TYPE = 1,
5610 /* Name corresponding to the DNS frame for which the respective DNS
5611 * stats have to get monitored (string). Max string length 255.
5612 */
5613 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_DNS_DOMAIN_NAME = 2,
5614 /* source port on which the respective proto stats have to get
5615 * collected (u32).
5616 */
5617 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_SRC_PORT = 3,
5618 /* destination port on which the respective proto stats have to get
5619 * collected (u32).
5620 */
5621 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_DEST_PORT = 4,
5622 /* IPv4 address for which the destined data packets have to be
5623 * monitored. (in network byte order), u32.
5624 */
5625 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_DEST_IPV4 = 5,
5626 /* IPv6 address for which the destined data packets have to be
5627 * monitored. (in network byte order), 16 bytes array.
5628 */
5629 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_DEST_IPV6 = 6,
5630
5631 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_LAST,
5632 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_MAX =
5633 QCA_ATTR_NUD_STATS_DATA_PKT_INFO_LAST - 1,
5634};
5635
5636/**
5637 * qca_wlan_vendor_attr_nud_stats_set: Attributes to vendor subcmd
5638 * QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_SET. This carries the requisite
5639 * information to start/stop the NUD statistics collection.
5640 */
5641enum qca_attr_nud_stats_set {
5642 QCA_ATTR_NUD_STATS_SET_INVALID = 0,
5643
5644 /* Flag to start/stop the NUD statistics collection.
5645 * Start - If included, Stop - If not included
5646 */
5647 QCA_ATTR_NUD_STATS_SET_START = 1,
5648 /* IPv4 address of the default gateway (in network byte order), u32 */
5649 QCA_ATTR_NUD_STATS_GW_IPV4 = 2,
5650 /* Represents the list of data packet types to be monitored.
5651 * Host driver tracks the stats corresponding to each data frame
5652 * represented by these flags.
5653 * These data packets are represented by
5654 * enum qca_wlan_vendor_nud_stats_set_data_pkt_info
5655 */
5656 QCA_ATTR_NUD_STATS_SET_DATA_PKT_INFO = 3,
5657
5658 /* keep last */
5659 QCA_ATTR_NUD_STATS_SET_LAST,
5660 QCA_ATTR_NUD_STATS_SET_MAX =
5661 QCA_ATTR_NUD_STATS_SET_LAST - 1,
5662};
5663
5664enum qca_attr_nud_data_stats {
5665 QCA_ATTR_NUD_DATA_STATS_INVALID = 0,
5666 /* Data packet type for which the stats are collected (u32).
5667 * Represented by enum qca_wlan_vendor_nud_stats_data_pkt_flags
5668 */
5669 QCA_ATTR_NUD_STATS_PKT_TYPE = 1,
5670 /* Name corresponding to the DNS frame for which the respective DNS
5671 * stats are monitored (string). Max string length 255.
5672 */
5673 QCA_ATTR_NUD_STATS_PKT_DNS_DOMAIN_NAME = 2,
5674 /* source port on which the respective proto stats are collected (u32).
5675 */
5676 QCA_ATTR_NUD_STATS_PKT_SRC_PORT = 3,
5677 /* destination port on which the respective proto stats are collected
5678 * (u32).
5679 */
5680 QCA_ATTR_NUD_STATS_PKT_DEST_PORT = 4,
5681 /* IPv4 address for which the destined data packets have to be
5682 * monitored. (in network byte order), u32.
5683 */
5684 QCA_ATTR_NUD_STATS_PKT_DEST_IPV4 = 5,
5685 /* IPv6 address for which the destined data packets have to be
5686 * monitored. (in network byte order), 16 bytes array.
5687 */
5688 QCA_ATTR_NUD_STATS_PKT_DEST_IPV6 = 6,
5689 /* Data packet Request count received from netdev (u32). */
5690 QCA_ATTR_NUD_STATS_PKT_REQ_COUNT_FROM_NETDEV = 7,
5691 /* Data packet Request count sent to lower MAC from upper MAC (u32). */
5692 QCA_ATTR_NUD_STATS_PKT_REQ_COUNT_TO_LOWER_MAC = 8,
5693 /* Data packet Request count received by lower MAC from upper MAC
5694 * (u32)
5695 */
5696 QCA_ATTR_NUD_STATS_PKT_REQ_RX_COUNT_BY_LOWER_MAC = 9,
5697 /* Data packet Request count successfully transmitted by the device
5698 * (u32)
5699 */
5700 QCA_ATTR_NUD_STATS_PKT_REQ_COUNT_TX_SUCCESS = 10,
5701 /* Data packet Response count received by lower MAC (u32) */
5702 QCA_ATTR_NUD_STATS_PKT_RSP_RX_COUNT_BY_LOWER_MAC = 11,
5703 /* Data packet Response count received by upper MAC (u32) */
5704 QCA_ATTR_NUD_STATS_PKT_RSP_RX_COUNT_BY_UPPER_MAC = 12,
5705 /* Data packet Response count delivered to netdev (u32) */
5706 QCA_ATTR_NUD_STATS_PKT_RSP_COUNT_TO_NETDEV = 13,
5707 /* Data Packet Response count that are dropped out of order (u32) */
5708 QCA_ATTR_NUD_STATS_PKT_RSP_COUNT_OUT_OF_ORDER_DROP = 14,
5709
5710 /* keep last */
5711 QCA_ATTR_NUD_DATA_STATS_LAST,
5712 QCA_ATTR_NUD_DATA_STATS_MAX =
5713 QCA_ATTR_NUD_DATA_STATS_LAST - 1,
5714};
5715
5716/**
5717 * qca_attr_nud_stats_get: Attributes to vendor subcmd
5718 * QCA_NL80211_VENDOR_SUBCMD_NUD_STATS_GET. This carries the requisite
5719 * NUD statistics collected when queried.
5720 */
5721enum qca_attr_nud_stats_get {
5722 QCA_ATTR_NUD_STATS_GET_INVALID = 0,
5723 /* ARP Request count from netdev (u32) */
5724 QCA_ATTR_NUD_STATS_ARP_REQ_COUNT_FROM_NETDEV = 1,
5725 /* ARP Request count sent to lower MAC from upper MAC (u32) */
5726 QCA_ATTR_NUD_STATS_ARP_REQ_COUNT_TO_LOWER_MAC = 2,
5727 /* ARP Request count received by lower MAC from upper MAC (u32) */
5728 QCA_ATTR_NUD_STATS_ARP_REQ_RX_COUNT_BY_LOWER_MAC = 3,
5729 /* ARP Request count successfully transmitted by the device (u32) */
5730 QCA_ATTR_NUD_STATS_ARP_REQ_COUNT_TX_SUCCESS = 4,
5731 /* ARP Response count received by lower MAC (u32) */
5732 QCA_ATTR_NUD_STATS_ARP_RSP_RX_COUNT_BY_LOWER_MAC = 5,
5733 /* ARP Response count received by upper MAC (u32) */
5734 QCA_ATTR_NUD_STATS_ARP_RSP_RX_COUNT_BY_UPPER_MAC = 6,
5735 /* ARP Response count delivered to netdev (u32) */
5736 QCA_ATTR_NUD_STATS_ARP_RSP_COUNT_TO_NETDEV = 7,
5737 /* ARP Response count dropped due to out of order reception (u32) */
5738 QCA_ATTR_NUD_STATS_ARP_RSP_COUNT_OUT_OF_ORDER_DROP = 8,
5739 /* Flag indicating if the station's link to the AP is active.
5740 * Active Link - If included, Inactive link - If not included
5741 */
5742 QCA_ATTR_NUD_STATS_AP_LINK_ACTIVE = 9,
5743 /* Flag indicating if there is any duplicate address detected (DAD).
5744 * Yes - If detected, No - If not detected.
5745 */
5746 QCA_ATTR_NUD_STATS_IS_DAD = 10,
5747 /* List of Data packet types for which the stats are requested.
5748 * This list does not carry ARP stats as they are done by the
5749 * above attributes. Represented by enum qca_attr_nud_data_stats.
5750 */
5751 QCA_ATTR_NUD_STATS_DATA_PKT_STATS = 11,
5752
5753 /* keep last */
5754 QCA_ATTR_NUD_STATS_GET_LAST,
5755 QCA_ATTR_NUD_STATS_GET_MAX =
5756 QCA_ATTR_NUD_STATS_GET_LAST - 1,
5757};
5758
5759enum qca_wlan_btm_candidate_status {
5760 QCA_STATUS_ACCEPT = 0,
5761 QCA_STATUS_REJECT_EXCESSIVE_FRAME_LOSS_EXPECTED = 1,
5762 QCA_STATUS_REJECT_EXCESSIVE_DELAY_EXPECTED = 2,
5763 QCA_STATUS_REJECT_INSUFFICIENT_QOS_CAPACITY = 3,
5764 QCA_STATUS_REJECT_LOW_RSSI = 4,
5765 QCA_STATUS_REJECT_HIGH_INTERFERENCE = 5,
5766 QCA_STATUS_REJECT_UNKNOWN = 6,
5767};
5768
5769enum qca_wlan_vendor_attr_btm_candidate_info {
5770 QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_INVALID = 0,
5771
5772 /* 6-byte MAC address representing the BSSID of transition candidate */
5773 QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_BSSID = 1,
5774 /* Unsigned 32-bit value from enum qca_wlan_btm_candidate_status
5775 * returned by the driver. It says whether the BSSID provided in
5776 * QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_BSSID is acceptable by
5777 * the driver, if not it specifies the reason for rejection.
5778 * Note that the user-space can overwrite the transition reject reason
5779 * codes provided by driver based on more information.
5780 */
5781 QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_STATUS = 2,
5782
5783 /* keep last */
5784 QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_AFTER_LAST,
5785 QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_MAX =
5786 QCA_WLAN_VENDOR_ATTR_BTM_CANDIDATE_INFO_AFTER_LAST - 1,
5787};
5788
5789enum qca_attr_trace_level {
5790 QCA_ATTR_TRACE_LEVEL_INVALID = 0,
5791 /*
5792 * Nested array of the following attributes:
5793 * QCA_ATTR_TRACE_LEVEL_MODULE,
5794 * QCA_ATTR_TRACE_LEVEL_MASK.
5795 */
5796 QCA_ATTR_TRACE_LEVEL_PARAM = 1,
5797 /*
5798 * Specific QCA host driver module. Please refer to the QCA host
5799 * driver implementation to get the specific module ID.
5800 */
5801 QCA_ATTR_TRACE_LEVEL_MODULE = 2,
5802 /* Different trace level masks represented in the QCA host driver. */
5803 QCA_ATTR_TRACE_LEVEL_MASK = 3,
5804
5805 /* keep last */
5806 QCA_ATTR_TRACE_LEVEL_AFTER_LAST,
5807 QCA_ATTR_TRACE_LEVEL_MAX =
5808 QCA_ATTR_TRACE_LEVEL_AFTER_LAST - 1,
5809};
5810
5811/**
5812 * enum qca_wlan_vendor_attr_get_he_capabilities - IEEE 802.11ax HE capabilities
5813 */
5814enum qca_wlan_vendor_attr_get_he_capabilities {
5815 QCA_WLAN_VENDOR_ATTR_HE_CAPABILITIES_INVALID = 0,
5816 /* Whether HE capabilities is supported
Arif Hussaine2645c62018-05-24 20:39:04 -07005817 * (u8 attribute: 0 = not supported, 1 = supported)
5818 */
Peng Xu291d97d2018-01-31 16:34:03 -08005819 QCA_WLAN_VENDOR_ATTR_HE_SUPPORTED = 1,
5820 /* HE PHY capabilities, array of 3 u32 values */
5821 QCA_WLAN_VENDOR_ATTR_PHY_CAPAB = 2,
5822 /* HE MAC capabilities (u32 attribute) */
5823 QCA_WLAN_VENDOR_ATTR_MAC_CAPAB = 3,
5824 /* HE MCS map (u32 attribute) */
5825 QCA_WLAN_VENDOR_ATTR_HE_MCS = 4,
5826 /* Number of SS (u32 attribute) */
5827 QCA_WLAN_VENDOR_ATTR_NUM_SS = 5,
5828 /* RU count (u32 attribute) */
5829 QCA_WLAN_VENDOR_ATTR_RU_IDX_MASK = 6,
5830 /* PPE threshold data, array of 8 u32 values */
5831 QCA_WLAN_VENDOR_ATTR_PPE_THRESHOLD = 7,
5832
5833 /* keep last */
5834 QCA_WLAN_VENDOR_ATTR_HE_CAPABILITIES_AFTER_LAST,
5835 QCA_WLAN_VENDOR_ATTR_HE_CAPABILITIES_MAX =
5836 QCA_WLAN_VENDOR_ATTR_HE_CAPABILITIES_AFTER_LAST - 1,
5837};
5838
5839/**
5840 * enum qca_wlan_vendor_attr_spectral_scan - Spectral scan config parameters
5841 */
5842enum qca_wlan_vendor_attr_spectral_scan {
5843 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_INVALID = 0,
5844 /* Number of times the chip enters spectral scan mode before
5845 * deactivating spectral scans. When set to 0, chip will enter spectral
5846 * scan mode continuously. u32 attribute.
5847 */
5848 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_SCAN_COUNT = 1,
5849 /* Spectral scan period. Period increment resolution is 256*Tclk,
5850 * where Tclk = 1/44 MHz (Gmode), 1/40 MHz (Amode). u32 attribute.
5851 */
5852 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_SCAN_PERIOD = 2,
5853 /* Spectral scan priority. u32 attribute. */
5854 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_PRIORITY = 3,
5855 /* Number of FFT data points to compute. u32 attribute. */
5856 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_FFT_SIZE = 4,
5857 /* Enable targeted gain change before starting the spectral scan FFT.
5858 * u32 attribute.
5859 */
5860 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_GC_ENA = 5,
5861 /* Restart a queued spectral scan. u32 attribute. */
5862 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_RESTART_ENA = 6,
5863 /* Noise floor reference number for the calculation of bin power.
5864 * u32 attribute.
5865 */
5866 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_NOISE_FLOOR_REF = 7,
5867 /* Disallow spectral scan triggers after TX/RX packets by setting
5868 * this delay value to roughly SIFS time period or greater.
5869 * u32 attribute.
5870 */
5871 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_INIT_DELAY = 8,
5872 /* Number of strong bins (inclusive) per sub-channel, below
5873 * which a signal is declared a narrow band tone. u32 attribute.
5874 */
5875 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_NB_TONE_THR = 9,
5876 /* Specify the threshold over which a bin is declared strong (for
5877 * scan bandwidth analysis). u32 attribute.
5878 */
5879 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_STR_BIN_THR = 10,
5880 /* Spectral scan report mode. u32 attribute. */
5881 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_WB_RPT_MODE = 11,
5882 /* RSSI report mode, if the ADC RSSI is below
5883 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_RSSI_THR,
5884 * then FFTs will not trigger, but timestamps and summaries get
5885 * reported. u32 attribute.
5886 */
5887 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_RSSI_RPT_MODE = 12,
5888 /* ADC RSSI must be greater than or equal to this threshold (signed dB)
5889 * to ensure spectral scan reporting with normal error code.
5890 * u32 attribute.
5891 */
5892 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_RSSI_THR = 13,
5893 /* Format of frequency bin magnitude for spectral scan triggered FFTs:
5894 * 0: linear magnitude, 1: log magnitude (20*log10(lin_mag)).
5895 * u32 attribute.
5896 */
5897 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_PWR_FORMAT = 14,
5898 /* Format of FFT report to software for spectral scan triggered FFTs.
5899 * 0: No FFT report (only spectral scan summary report)
5900 * 1: 2-dword summary of metrics for each completed FFT + spectral scan
5901 * report
5902 * 2: 2-dword summary of metrics for each completed FFT + 1x-oversampled
5903 * bins (in-band) per FFT + spectral scan summary report
5904 * 3: 2-dword summary of metrics for each completed FFT + 2x-oversampled
5905 * bins (all) per FFT + spectral scan summary report
5906 * u32 attribute.
5907 */
5908 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_RPT_MODE = 15,
5909 /* Number of LSBs to shift out in order to scale the FFT bins.
5910 * u32 attribute.
5911 */
5912 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_BIN_SCALE = 16,
5913 /* Set to 1 (with spectral_scan_pwr_format=1), to report bin magnitudes
5914 * in dBm power. u32 attribute.
5915 */
5916 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_DBM_ADJ = 17,
5917 /* Per chain enable mask to select input ADC for search FFT.
5918 * u32 attribute.
5919 */
5920 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_CHN_MASK = 18,
5921 /* An unsigned 64-bit integer provided by host driver to identify the
5922 * spectral scan request. This attribute is included in the scan
5923 * response message for @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_START
5924 * and used as an attribute in
5925 * @QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_STOP to identify the
5926 * specific scan to be stopped.
5927 */
5928 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_COOKIE = 19,
5929 /* Skip interval for FFT reports. u32 attribute */
5930 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_FFT_PERIOD = 20,
5931 /* Set to report only one set of FFT results.
5932 * u32 attribute.
5933 */
5934 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_SHORT_REPORT = 21,
5935 /* Debug level for spectral module in driver.
5936 * 0 : Verbosity level 0
5937 * 1 : Verbosity level 1
5938 * 2 : Verbosity level 2
5939 * 3 : Matched filterID display
5940 * 4 : One time dump of FFT report
5941 * u32 attribute.
5942 */
5943 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_DEBUG_LEVEL = 22,
5944 /* Type of spectral scan request. u32 attribute.
5945 * It uses values defined in enum
5946 * qca_wlan_vendor_attr_spectral_scan_request_type.
5947 */
5948 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE = 23,
Jouni Malinenf735abd2020-08-03 11:08:00 +03005949 /* This specifies the frequency span over which spectral
5950 * scan would be carried out. Its value depends on the
5951 * value of QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_MODE and
5952 * the relation is as follows.
5953 * QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_NORMAL
5954 * Not applicable. Spectral scan would happen in the
5955 * operating span.
5956 * QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_AGILE
5957 * Center frequency (in MHz) of the span of interest or
5958 * for convenience, center frequency (in MHz) of any channel
5959 * in the span of interest. For 80+80 MHz agile spectral scan
5960 * request it represents center frequency (in MHz) of the primary
5961 * 80 MHz span or for convenience, center frequency (in MHz) of any
5962 * channel in the primary 80 MHz span. If agile spectral scan is
5963 * initiated without setting a valid frequency it returns the
5964 * error code
5965 * (QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_PARAM_NOT_INITIALIZED).
5966 * u32 attribute.
5967 */
5968 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_FREQUENCY = 24,
5969 /* Spectral scan mode. u32 attribute.
5970 * It uses values defined in enum qca_wlan_vendor_spectral_scan_mode.
5971 * If this attribute is not present, it is assumed to be
5972 * normal mode (QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_NORMAL).
5973 */
5974 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_MODE = 25,
5975 /* Spectral scan error code. u32 attribute.
5976 * It uses values defined in enum
5977 * qca_wlan_vendor_spectral_scan_error_code.
5978 * This attribute is included only in failure scenarios.
5979 */
5980 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_ERROR_CODE = 26,
5981 /* 8-bit unsigned value to enable/disable debug of the
5982 * Spectral DMA ring.
5983 * 1-enable, 0-disable
5984 */
5985 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_DMA_RING_DEBUG = 27,
5986 /* 8-bit unsigned value to enable/disable debug of the
5987 * Spectral DMA buffers.
5988 * 1-enable, 0-disable
5989 */
5990 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_DMA_BUFFER_DEBUG = 28,
5991 /* This specifies the frequency span over which spectral scan would be
5992 * carried out. Its value depends on the value of
5993 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_MODE and the relation is as
5994 * follows.
5995 * QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_NORMAL
5996 * Not applicable. Spectral scan would happen in the operating span.
5997 * QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_AGILE
5998 * This attribute is applicable only for agile spectral scan
5999 * requests in 80+80 MHz mode. It represents center frequency (in
6000 * MHz) of the secondary 80 MHz span or for convenience, center
6001 * frequency (in MHz) of any channel in the secondary 80 MHz span.
6002 * u32 attribute.
6003 */
6004 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_FREQUENCY_2 = 29,
Peng Xu291d97d2018-01-31 16:34:03 -08006005
6006 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_AFTER_LAST,
6007 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_MAX =
6008 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CONFIG_AFTER_LAST - 1,
6009};
6010
6011/**
6012 * enum qca_wlan_vendor_attr_spectral_diag_stats - Used by the vendor command
6013 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_DIAG_STATS.
6014 */
6015enum qca_wlan_vendor_attr_spectral_diag_stats {
6016 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_INVALID = 0,
6017 /* Number of spectral TLV signature mismatches.
6018 * u64 attribute.
6019 */
6020 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_SIG_MISMATCH = 1,
6021 /* Number of spectral phyerror events with insufficient length when
6022 * parsing for secondary 80 search FFT report. u64 attribute.
6023 */
6024 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_SEC80_SFFT_INSUFFLEN = 2,
6025 /* Number of spectral phyerror events without secondary 80
6026 * search FFT report. u64 attribute.
6027 */
6028 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_NOSEC80_SFFT = 3,
6029 /* Number of spectral phyerror events with vht operation segment 1 id
6030 * mismatches in search fft report. u64 attribute.
6031 */
6032 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_VHTSEG1ID_MISMATCH = 4,
6033 /* Number of spectral phyerror events with vht operation segment 2 id
6034 * mismatches in search fft report. u64 attribute.
6035 */
6036 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_VHTSEG2ID_MISMATCH = 5,
6037
6038 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_AFTER_LAST,
6039 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_MAX =
6040 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_DIAG_AFTER_LAST - 1,
6041};
6042
6043/**
6044 * enum qca_wlan_vendor_attr_spectral_cap - Used by the vendor command
6045 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_CAP_INFO.
6046 */
6047enum qca_wlan_vendor_attr_spectral_cap {
6048 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_INVALID = 0,
6049 /* Flag attribute to indicate phydiag capability */
6050 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_PHYDIAG = 1,
6051 /* Flag attribute to indicate radar detection capability */
6052 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_RADAR = 2,
6053 /* Flag attribute to indicate spectral capability */
6054 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_SPECTRAL = 3,
6055 /* Flag attribute to indicate advanced spectral capability */
6056 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_ADVANCED_SPECTRAL = 4,
Arif Hussaine2645c62018-05-24 20:39:04 -07006057 /* Spectral hardware generation. u32 attribute.
6058 * It uses values defined in enum
6059 * qca_wlan_vendor_spectral_scan_cap_hw_gen.
6060 */
6061 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_HW_GEN = 5,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07006062 /* Spectral bin scaling formula ID. u16 attribute.
6063 * It uses values defined in enum
6064 * qca_wlan_vendor_spectral_scan_cap_formula_id.
6065 */
6066 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_FORMULA_ID = 6,
6067 /* Spectral bin scaling param - low level offset.
6068 * s16 attribute.
6069 */
6070 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_LOW_LEVEL_OFFSET = 7,
6071 /* Spectral bin scaling param - high level offset.
6072 * s16 attribute.
6073 */
6074 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_HIGH_LEVEL_OFFSET = 8,
6075 /* Spectral bin scaling param - RSSI threshold.
6076 * s16 attribute.
6077 */
6078 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_RSSI_THR = 9,
6079 /* Spectral bin scaling param - default AGC max gain.
6080 * u8 attribute.
6081 */
6082 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_DEFAULT_AGC_MAX_GAIN = 10,
Jouni Malinenf735abd2020-08-03 11:08:00 +03006083 /* Flag attribute to indicate agile spectral scan capability
6084 * for 20/40/80 MHz modes.
6085 */
6086 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_AGILE_SPECTRAL = 11,
6087 /* Flag attribute to indicate agile spectral scan capability
6088 * for 160 MHz mode.
6089 */
6090 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_AGILE_SPECTRAL_160 = 12,
6091 /* Flag attribute to indicate agile spectral scan capability
6092 * for 80+80 MHz mode.
6093 */
6094 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_AGILE_SPECTRAL_80_80 = 13,
6095 /* Number of spectral detectors used for scan in 20 MHz.
6096 * u32 attribute.
6097 */
6098 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_NUM_DETECTORS_20_MHZ = 14,
6099 /* Number of spectral detectors used for scan in 40 MHz.
6100 * u32 attribute.
6101 */
6102 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_NUM_DETECTORS_40_MHZ = 15,
6103 /* Number of spectral detectors used for scan in 80 MHz.
6104 * u32 attribute.
6105 */
6106 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_NUM_DETECTORS_80_MHZ = 16,
6107 /* Number of spectral detectors used for scan in 160 MHz.
6108 * u32 attribute.
6109 */
6110 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_NUM_DETECTORS_160_MHZ = 17,
6111 /* Number of spectral detectors used for scan in 80+80 MHz.
6112 * u32 attribute.
6113 */
6114 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_NUM_DETECTORS_80P80_MHZ = 18,
Peng Xu291d97d2018-01-31 16:34:03 -08006115
6116 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_AFTER_LAST,
6117 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_MAX =
6118 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_AFTER_LAST - 1,
6119};
6120
6121/**
6122 * enum qca_wlan_vendor_attr_spectral_scan_status - used by the vendor command
6123 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_STATUS.
6124 */
6125enum qca_wlan_vendor_attr_spectral_scan_status {
6126 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_INVALID = 0,
6127 /* Flag attribute to indicate whether spectral scan is enabled */
6128 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_IS_ENABLED = 1,
6129 /* Flag attribute to indicate whether spectral scan is in progress*/
6130 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_IS_ACTIVE = 2,
Jouni Malinenf735abd2020-08-03 11:08:00 +03006131 /* Spectral scan mode. u32 attribute.
6132 * It uses values defined in enum qca_wlan_vendor_spectral_scan_mode.
6133 * If this attribute is not present, normal mode
6134 * (QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_NORMAL is assumed to be
6135 * requested.
6136 */
6137 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_MODE = 3,
Peng Xu291d97d2018-01-31 16:34:03 -08006138
6139 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_AFTER_LAST,
6140 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_MAX =
6141 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_AFTER_LAST - 1,
6142};
6143
6144/**
6145 * qca_wlan_vendor_attr_spectral_scan_request_type: Attribute values for
6146 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE to the vendor subcmd
6147 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_START. This represents the
6148 * spectral scan request types.
6149 * @QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE_SCAN_AND_CONFIG: Request to
6150 * set the spectral parameters and start scan.
6151 * @QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE_SCAN: Request to
6152 * only set the spectral parameters.
6153 * @QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE_CONFIG: Request to
6154 * only start the spectral scan.
6155 */
6156enum qca_wlan_vendor_attr_spectral_scan_request_type {
6157 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE_SCAN_AND_CONFIG,
6158 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE_SCAN,
6159 QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_REQUEST_TYPE_CONFIG,
6160};
6161
Arif Hussaine2645c62018-05-24 20:39:04 -07006162/**
Jouni Malinenf735abd2020-08-03 11:08:00 +03006163 * qca_wlan_vendor_spectral_scan_mode: Attribute values for
6164 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_MODE in the vendor subcmd
6165 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_START and
6166 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_STATUS_MODE in the vendor subcmd
6167 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_STATUS. This represents the
6168 * spectral scan modes.
6169 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_NORMAL: Normal spectral scan:
6170 * spectral scan in the current operating span.
6171 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_AGILE: Agile spectral scan:
6172 * spectral scan in the configured agile span.
6173 */
6174enum qca_wlan_vendor_spectral_scan_mode {
6175 QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_NORMAL = 0,
6176 QCA_WLAN_VENDOR_SPECTRAL_SCAN_MODE_AGILE = 1,
6177};
6178
6179/**
6180 * qca_wlan_vendor_spectral_scan_error_code: Attribute values for
6181 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_ERROR_CODE in the vendor subcmd
6182 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_START.
6183 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_PARAM_UNSUPPORTED: Changing the value
6184 * of a parameter is not supported.
6185 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_MODE_UNSUPPORTED: Requested spectral scan
6186 * mode is not supported.
6187 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_PARAM_INVALID_VALUE: A parameter
6188 * has invalid value.
6189 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_PARAM_NOT_INITIALIZED: A parameter
6190 * is not initialized.
6191 */
6192enum qca_wlan_vendor_spectral_scan_error_code {
6193 QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_PARAM_UNSUPPORTED = 0,
6194 QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_MODE_UNSUPPORTED = 1,
6195 QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_PARAM_INVALID_VALUE = 2,
6196 QCA_WLAN_VENDOR_SPECTRAL_SCAN_ERR_PARAM_NOT_INITIALIZED = 3,
6197};
6198
6199/**
Arif Hussaine2645c62018-05-24 20:39:04 -07006200 * qca_wlan_vendor_spectral_scan_cap_hw_gen: Attribute values for
6201 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_HW_GEN to the vendor subcmd
6202 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_CAP_INFO. This represents the
6203 * spectral hardware generation.
6204 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_HW_GEN_1: generation 1
6205 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_HW_GEN_2: generation 2
6206 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_HW_GEN_3: generation 3
6207 */
6208enum qca_wlan_vendor_spectral_scan_cap_hw_gen {
6209 QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_HW_GEN_1 = 0,
6210 QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_HW_GEN_2 = 1,
6211 QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_HW_GEN_3 = 2,
6212};
6213
Peng Xu291d97d2018-01-31 16:34:03 -08006214enum qca_wlan_vendor_tos {
6215 QCA_WLAN_VENDOR_TOS_BK = 0,
6216 QCA_WLAN_VENDOR_TOS_BE = 1,
6217 QCA_WLAN_VENDOR_TOS_VI = 2,
6218 QCA_WLAN_VENDOR_TOS_VO = 3,
6219};
6220
6221/**
6222 * enum qca_wlan_vendor_attr_active_tos - Used by the vendor command
6223 * QCA_NL80211_VENDOR_SUBCMD_ACTIVE_TOS.
6224 */
6225enum qca_wlan_vendor_attr_active_tos {
6226 QCA_WLAN_VENDOR_ATTR_ACTIVE_TOS_INVALID = 0,
6227 /* Type Of Service - Represented by qca_wlan_vendor_tos */
6228 QCA_WLAN_VENDOR_ATTR_ACTIVE_TOS = 1,
6229 /* Flag attribute representing the start (attribute included) or stop
6230 * (attribute not included) of the respective TOS.
6231 */
6232 QCA_WLAN_VENDOR_ATTR_ACTIVE_TOS_START = 2,
6233};
6234
6235enum qca_wlan_vendor_hang_reason {
6236 /* Unspecified reason */
6237 QCA_WLAN_HANG_REASON_UNSPECIFIED = 0,
6238 /* No Map for the MAC entry for the received frame */
6239 QCA_WLAN_HANG_RX_HASH_NO_ENTRY_FOUND = 1,
6240 /* Peer deletion timeout happened */
6241 QCA_WLAN_HANG_PEER_DELETION_TIMEDOUT = 2,
6242 /* Peer unmap timeout */
6243 QCA_WLAN_HANG_PEER_UNMAP_TIMEDOUT = 3,
6244 /* Scan request timed out */
6245 QCA_WLAN_HANG_SCAN_REQ_EXPIRED = 4,
6246 /* Consecutive Scan attempt failures */
6247 QCA_WLAN_HANG_SCAN_ATTEMPT_FAILURES = 5,
6248 /* Unable to get the message buffer */
6249 QCA_WLAN_HANG_GET_MSG_BUFF_FAILURE = 6,
6250 /* Current command processing is timedout */
6251 QCA_WLAN_HANG_ACTIVE_LIST_TIMEOUT = 7,
6252 /* Timeout for an ACK from FW for suspend request */
6253 QCA_WLAN_HANG_SUSPEND_TIMEOUT = 8,
6254 /* Timeout for an ACK from FW for resume request */
6255 QCA_WLAN_HANG_RESUME_TIMEOUT = 9,
6256 /* Transmission timeout for consecutive data frames */
6257 QCA_WLAN_HANG_TRANSMISSIONS_TIMEOUT = 10,
6258 /* Timeout for the TX completion status of data frame */
6259 QCA_WLAN_HANG_TX_COMPLETE_TIMEOUT = 11,
6260 /* DXE failure for TX/RX, DXE resource unavailability */
6261 QCA_WLAN_HANG_DXE_FAILURE = 12,
6262 /* WMI pending commands exceed the maximum count */
6263 QCA_WLAN_HANG_WMI_EXCEED_MAX_PENDING_CMDS = 13,
Jouni Malinenf735abd2020-08-03 11:08:00 +03006264 /* Timeout for peer STA connection accept command's response from the
6265 * FW in AP mode. This command is triggered when a STA (peer) connects
6266 * to AP (DUT).
6267 */
6268 QCA_WLAN_HANG_AP_STA_CONNECT_REQ_TIMEOUT = 14,
6269 /* Timeout for the AP connection accept command's response from the FW
6270 * in STA mode. This command is triggered when the STA (DUT) connects
6271 * to an AP (peer).
6272 */
6273 QCA_WLAN_HANG_STA_AP_CONNECT_REQ_TIMEOUT = 15,
6274 /* Timeout waiting for the response to the MAC HW mode change command
6275 * sent to FW as a part of MAC mode switch among DBS (Dual Band
6276 * Simultaneous), SCC (Single Channel Concurrency), and MCC (Multi
6277 * Channel Concurrency) mode.
6278 */
6279 QCA_WLAN_HANG_MAC_HW_MODE_CHANGE_TIMEOUT = 16,
6280 /* Timeout waiting for the response from FW to configure the MAC HW's
6281 * mode. This operation is to configure the single/two MACs in either
6282 * SCC/MCC/DBS mode.
6283 */
6284 QCA_WLAN_HANG_MAC_HW_MODE_CONFIG_TIMEOUT = 17,
6285 /* Timeout waiting for response of VDEV start command from the FW */
6286 QCA_WLAN_HANG_VDEV_START_RESPONSE_TIMED_OUT = 18,
6287 /* Timeout waiting for response of VDEV restart command from the FW */
6288 QCA_WLAN_HANG_VDEV_RESTART_RESPONSE_TIMED_OUT = 19,
6289 /* Timeout waiting for response of VDEV stop command from the FW */
6290 QCA_WLAN_HANG_VDEV_STOP_RESPONSE_TIMED_OUT = 20,
6291 /* Timeout waiting for response of VDEV delete command from the FW */
6292 QCA_WLAN_HANG_VDEV_DELETE_RESPONSE_TIMED_OUT = 21,
6293 /* Timeout waiting for response of peer all delete request command to
6294 * the FW on a specific VDEV.
6295 */
6296 QCA_WLAN_HANG_VDEV_PEER_DELETE_ALL_RESPONSE_TIMED_OUT = 22,
Srinivas Girigowda7673be32020-11-12 12:37:14 -08006297 /* WMI sequence mismatch between WMI command and Tx completion */
6298 QCA_WLAN_HANG_WMI_BUF_SEQUENCE_MISMATCH = 23,
6299 /* Write to Device HAL register failed */
6300 QCA_WLAN_HANG_REG_WRITE_FAILURE = 24,
6301 /* No credit left to send the wow_wakeup_from_sleep to firmware */
6302 QCA_WLAN_HANG_SUSPEND_NO_CREDIT = 25,
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08006303 /* Bus failure */
6304 QCA_WLAN_HANG_BUS_FAILURE = 26,
Peng Xu291d97d2018-01-31 16:34:03 -08006305};
6306
6307/**
6308 * enum qca_wlan_vendor_attr_hang - Used by the vendor command
6309 * QCA_NL80211_VENDOR_SUBCMD_HANG.
6310 */
6311enum qca_wlan_vendor_attr_hang {
6312 QCA_WLAN_VENDOR_ATTR_HANG_INVALID = 0,
6313 /* Reason for the hang - u32 attribute with a value from enum
6314 * qca_wlan_vendor_hang_reason.
6315 */
6316 QCA_WLAN_VENDOR_ATTR_HANG_REASON = 1,
Jouni Malinenf735abd2020-08-03 11:08:00 +03006317 /* The binary blob data associated with the hang reason specified by
6318 * QCA_WLAN_VENDOR_ATTR_HANG_REASON. This binary data is expected to
6319 * contain the required dump to analyze the reason for the hang.
6320 * NLA_BINARY attribute, the max size is 1024 bytes.
6321 */
6322 QCA_WLAN_VENDOR_ATTR_HANG_REASON_DATA = 2,
Peng Xu291d97d2018-01-31 16:34:03 -08006323
6324 QCA_WLAN_VENDOR_ATTR_HANG_AFTER_LAST,
6325 QCA_WLAN_VENDOR_ATTR_HANG_MAX =
6326 QCA_WLAN_VENDOR_ATTR_HANG_AFTER_LAST - 1,
6327};
6328
6329/**
6330 * enum qca_wlan_vendor_attr_flush_pending - Attributes for
6331 * flushing pending traffic in firmware.
6332 *
6333 * @QCA_WLAN_VENDOR_ATTR_PEER_ADDR: Configure peer MAC address.
6334 * @QCA_WLAN_VENDOR_ATTR_AC: Configure access category of the pending
6335 * packets. It is u8 value with bit 0~3 represent AC_BE, AC_BK,
6336 * AC_VI, AC_VO respectively. Set the corresponding bit to 1 to
6337 * flush packets with access category.
6338 */
6339enum qca_wlan_vendor_attr_flush_pending {
6340 QCA_WLAN_VENDOR_ATTR_FLUSH_PENDING_INVALID = 0,
6341 QCA_WLAN_VENDOR_ATTR_PEER_ADDR = 1,
6342 QCA_WLAN_VENDOR_ATTR_AC = 2,
6343
6344 /* keep last */
6345 QCA_WLAN_VENDOR_ATTR_FLUSH_PENDING_AFTER_LAST,
6346 QCA_WLAN_VENDOR_ATTR_FLUSH_PENDING_MAX =
6347 QCA_WLAN_VENDOR_ATTR_FLUSH_PENDING_AFTER_LAST - 1,
6348};
6349
6350/**
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07006351 * qca_wlan_vendor_spectral_scan_cap_formula_id: Attribute values for
6352 * QCA_WLAN_VENDOR_ATTR_SPECTRAL_SCAN_CAP_FORMULA_ID in the vendor subcmd
6353 * QCA_NL80211_VENDOR_SUBCMD_SPECTRAL_SCAN_GET_CAP_INFO. This represents the
6354 * Spectral bin scaling formula ID.
6355 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_NO_SCALING: No scaling
6356 * @QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_AGC_GAIN_RSSI_CORR_BASED: AGC gain
6357 * and RSSI threshold based formula.
6358 */
6359enum qca_wlan_vendor_spectral_scan_cap_formula_id {
6360 QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_NO_SCALING = 0,
6361 QCA_WLAN_VENDOR_SPECTRAL_SCAN_CAP_AGC_GAIN_RSSI_CORR_BASED = 1,
6362};
6363
6364/**
Peng Xu291d97d2018-01-31 16:34:03 -08006365 * enum qca_wlan_vendor_attr_rropavail_info - Specifies whether Representative
6366 * RF Operating Parameter (RROP) information is available, and if so, at which
6367 * point in the application-driver interaction sequence it can be retrieved by
6368 * the application from the driver. This point may vary by architecture and
6369 * other factors. This is a u16 value.
6370 */
6371enum qca_wlan_vendor_attr_rropavail_info {
6372 /* RROP information is unavailable. */
6373 QCA_WLAN_VENDOR_ATTR_RROPAVAIL_INFO_UNAVAILABLE,
6374 /* RROP information is available and the application can retrieve the
6375 * information after receiving an QCA_NL80211_VENDOR_SUBCMD_EXTERNAL_ACS
6376 * event from the driver.
6377 */
6378 QCA_WLAN_VENDOR_ATTR_RROPAVAIL_INFO_EXTERNAL_ACS_START,
6379 /* RROP information is available only after a vendor specific scan
6380 * (requested using QCA_NL80211_VENDOR_SUBCMD_TRIGGER_SCAN) has
6381 * successfully completed. The application can retrieve the information
6382 * after receiving the QCA_NL80211_VENDOR_SUBCMD_SCAN_DONE event from
6383 * the driver.
6384 */
6385 QCA_WLAN_VENDOR_ATTR_RROPAVAIL_INFO_VSCAN_END,
6386};
6387
6388/**
6389 * enum qca_wlan_vendor_attr_rrop_info - Specifies vendor specific
6390 * Representative RF Operating Parameter (RROP) information. It is sent for the
6391 * vendor command QCA_NL80211_VENDOR_SUBCMD_GET_RROP_INFO. This information is
6392 * intended for use by external Auto Channel Selection applications. It provides
6393 * guidance values for some RF parameters that are used by the system during
6394 * operation. These values could vary by channel, band, radio, and so on.
6395 */
6396enum qca_wlan_vendor_attr_rrop_info {
6397 QCA_WLAN_VENDOR_ATTR_RROP_INFO_INVALID = 0,
6398
6399 /* Representative Tx Power List (RTPL) which has an array of nested
6400 * values as per attributes in enum qca_wlan_vendor_attr_rtplinst.
6401 */
6402 QCA_WLAN_VENDOR_ATTR_RROP_INFO_RTPL = 1,
6403
6404 QCA_WLAN_VENDOR_ATTR_RROP_INFO_AFTER_LAST,
6405 QCA_WLAN_VENDOR_ATTR_RROP_INFO_MAX =
6406 QCA_WLAN_VENDOR_ATTR_RROP_INFO_AFTER_LAST - 1
6407};
6408
6409/**
6410 * enum qca_wlan_vendor_attr_rtplinst - Specifies attributes for individual list
6411 * entry instances in the Representative Tx Power List (RTPL). It provides
6412 * simplified power values intended for helping external Auto channel Selection
6413 * applications compare potential Tx power performance between channels, other
6414 * operating conditions remaining identical. These values are not necessarily
6415 * the actual Tx power values that will be used by the system. They are also not
6416 * necessarily the max or average values that will be used. Instead, they are
6417 * relative, summarized keys for algorithmic use computed by the driver or
6418 * underlying firmware considering a number of vendor specific factors.
6419 */
6420enum qca_wlan_vendor_attr_rtplinst {
6421 QCA_WLAN_VENDOR_ATTR_RTPLINST_INVALID = 0,
6422
Jouni Malinenf735abd2020-08-03 11:08:00 +03006423 /* Primary channel number (u8).
6424 * Note: If both the driver and user space application support the
6425 * 6 GHz band, this attribute is deprecated and
6426 * QCA_WLAN_VENDOR_ATTR_RTPLINST_PRIMARY_FREQUENCY should be used. To
6427 * maintain backward compatibility,
6428 * QCA_WLAN_VENDOR_ATTR_RTPLINST_PRIMARY is still used if either the
6429 * driver or user space application or both do not support the 6 GHz
6430 * band.
6431 */
Peng Xu291d97d2018-01-31 16:34:03 -08006432 QCA_WLAN_VENDOR_ATTR_RTPLINST_PRIMARY = 1,
6433 /* Representative Tx power in dBm (s32) with emphasis on throughput. */
6434 QCA_WLAN_VENDOR_ATTR_RTPLINST_TXPOWER_THROUGHPUT = 2,
6435 /* Representative Tx power in dBm (s32) with emphasis on range. */
6436 QCA_WLAN_VENDOR_ATTR_RTPLINST_TXPOWER_RANGE = 3,
Jouni Malinenf735abd2020-08-03 11:08:00 +03006437 /* Primary channel center frequency (u32) in MHz */
6438 QCA_WLAN_VENDOR_ATTR_RTPLINST_PRIMARY_FREQUENCY = 4,
Peng Xu291d97d2018-01-31 16:34:03 -08006439
6440 QCA_WLAN_VENDOR_ATTR_RTPLINST_AFTER_LAST,
6441 QCA_WLAN_VENDOR_ATTR_RTPLINST_MAX =
6442 QCA_WLAN_VENDOR_ATTR_RTPLINST_AFTER_LAST - 1,
6443};
6444
6445/**
6446 * enum qca_wlan_vendor_attr_config_latency_level - Level for
6447 * wlan latency module.
6448 *
6449 * There will be various of Wi-Fi functionality like scan/roaming/adaptive
6450 * power saving which would causing data exchange out of service, this
6451 * would be a big impact on latency. For latency sensitive applications over
6452 * Wi-Fi are intolerant to such operations and thus would configure them
6453 * to meet their respective needs. It is well understood by such applications
6454 * that altering the default behavior would degrade the Wi-Fi functionality
6455 * w.r.t the above pointed WLAN operations.
6456 *
6457 * @QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_NORMAL:
6458 * Default WLAN operation level which throughput orientated.
6459 * @QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_MODERATE:
6460 * Use moderate level to improve latency by limit scan duration.
6461 * @QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_LOW:
6462 * Use low latency level to benifit application like concurrent
6463 * downloading or video streaming via constraint scan/adaptive PS.
6464 * @QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_ULTRALOW:
6465 * Use ultra low latency level to benefit for gaming/voice
6466 * application via constraint scan/roaming/adaptive PS.
6467 */
6468enum qca_wlan_vendor_attr_config_latency_level {
6469 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_INVALID = 0,
6470 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_NORMAL = 1,
6471 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_MODERATE = 2,
6472 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_LOW = 3,
6473 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_ULTRALOW = 4,
6474
6475 /* keep last */
6476 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_AFTER_LAST,
6477 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_MAX =
6478 QCA_WLAN_VENDOR_ATTR_CONFIG_LATENCY_LEVEL_AFTER_LAST - 1,
6479};
6480
6481/**
6482 * enum qca_wlan_vendor_attr_wlan_mac - Used by the vendor command
6483 * QCA_NL80211_VENDOR_SUBCMD_WLAN_MAC_INFO.
6484 */
6485enum qca_wlan_vendor_attr_mac {
6486 QCA_WLAN_VENDOR_ATTR_MAC_INVALID = 0,
6487
6488 /* MAC mode info list which has an array of nested values as
6489 * per attributes in enum qca_wlan_vendor_attr_mac_mode_info.
6490 */
6491 QCA_WLAN_VENDOR_ATTR_MAC_INFO = 1,
6492
6493 /* keep last */
6494 QCA_WLAN_VENDOR_ATTR_MAC_AFTER_LAST,
6495 QCA_WLAN_VENDOR_ATTR_MAC_MAX =
6496 QCA_WLAN_VENDOR_ATTR_MAC_AFTER_LAST - 1,
6497};
6498
6499/**
6500 * enum qca_wlan_vendor_attr_mac_iface_info - Information of the connected
6501 * Wi-Fi netdev interface on a respective MAC.
6502 * Used by the attribute QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO.
6503 */
6504enum qca_wlan_vendor_attr_mac_iface_info {
6505 QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO_INVALID = 0,
6506 /* Wi-Fi netdev's interface index (u32) */
6507 QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO_IFINDEX = 1,
6508 /* Associated frequency in MHz of the connected Wi-Fi interface (u32) */
6509 QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO_FREQ = 2,
6510
6511 /* keep last */
6512 QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO_AFTER_LAST,
6513 QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO_MAX =
6514 QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO_AFTER_LAST - 1,
6515};
6516
6517/**
6518 * enum qca_wlan_vendor_attr_mac_info - Points to MAC the information.
6519 * Used by the attribute QCA_WLAN_VENDOR_ATTR_MAC_INFO of the
6520 * vendor command QCA_NL80211_VENDOR_SUBCMD_WLAN_MAC_INFO.
6521 */
6522enum qca_wlan_vendor_attr_mac_info {
6523 QCA_WLAN_VENDOR_ATTR_MAC_INFO_INVALID = 0,
6524 /* Hardware MAC ID associated for the MAC (u32) */
6525 QCA_WLAN_VENDOR_ATTR_MAC_INFO_MAC_ID = 1,
6526 /* Band supported by the MAC at a given point.
6527 * This is a u32 bitmask of BIT(NL80211_BAND_*) as described in %enum
6528 * nl80211_band.
6529 */
6530 QCA_WLAN_VENDOR_ATTR_MAC_INFO_BAND = 2,
6531 /* Refers to list of WLAN netdev interfaces associated with this MAC.
6532 * Represented by enum qca_wlan_vendor_attr_mac_iface_info.
6533 */
6534 QCA_WLAN_VENDOR_ATTR_MAC_IFACE_INFO = 3,
6535
6536 /* keep last */
6537 QCA_WLAN_VENDOR_ATTR_MAC_INFO_AFTER_LAST,
6538 QCA_WLAN_VENDOR_ATTR_MAC_INFO_MAX =
6539 QCA_WLAN_VENDOR_ATTR_MAC_INFO_AFTER_LAST - 1,
6540};
6541
6542/**
6543 * enum qca_wlan_vendor_attr_get_logger_features - Used by the vendor command
6544 * QCA_NL80211_VENDOR_SUBCMD_GET_LOGGER_FEATURE_SET.
6545 */
6546enum qca_wlan_vendor_attr_get_logger_features {
6547 QCA_WLAN_VENDOR_ATTR_LOGGER_INVALID = 0,
6548 /* Unsigned 32-bit enum value of wifi_logger_supported_features */
6549 QCA_WLAN_VENDOR_ATTR_LOGGER_SUPPORTED = 1,
6550 /* keep last */
6551 QCA_WLAN_VENDOR_ATTR_LOGGER_AFTER_LAST,
6552 QCA_WLAN_VENDOR_ATTR_LOGGER_MAX =
6553 QCA_WLAN_VENDOR_ATTR_LOGGER_AFTER_LAST - 1,
6554};
6555
6556/**
6557 * enum wifi_logger_supported_features - Values for supported logger features
6558 */
6559enum wifi_logger_supported_features {
6560 WIFI_LOGGER_MEMORY_DUMP_FEATURE = (1 << (0)),
6561 WIFI_LOGGER_PER_PACKET_TX_RX_STATUS_FEATURE = (1 << (1)),
6562 WIFI_LOGGER_CONNECT_EVENT_FEATURE = (1 << (2)),
6563 WIFI_LOGGER_POWER_EVENT_FEATURE = (1 << (3)),
6564 WIFI_LOGGER_WAKE_LOCK_FEATURE = (1 << (4)),
6565 WIFI_LOGGER_VERBOSE_FEATURE = (1 << (5)),
6566 WIFI_LOGGER_WATCHDOG_TIMER_FEATURE = (1 << (6)),
6567 WIFI_LOGGER_DRIVER_DUMP_FEATURE = (1 << (7)),
6568 WIFI_LOGGER_PACKET_FATE_FEATURE = (1 << (8)),
6569};
6570
6571/**
6572 * enum qca_wlan_tdls_caps_features_supported - Values for TDLS get
6573 * capabilities features
6574 */
Arif Hussaine2645c62018-05-24 20:39:04 -07006575enum qca_wlan_tdls_caps_features_supported {
Peng Xu291d97d2018-01-31 16:34:03 -08006576 WIFI_TDLS_SUPPORT = (1 << (0)),
6577 WIFI_TDLS_EXTERNAL_CONTROL_SUPPORT = (1 << (1)),
6578 WIFI_TDLS_OFFCHANNEL_SUPPORT = (1 << (2))
6579};
6580
6581/**
6582 * enum qca_wlan_vendor_attr_tdls_get_capabilities - Used by the vendor command
6583 * QCA_NL80211_VENDOR_SUBCMD_TDLS_GET_CAPABILITIES.
6584 */
Arif Hussaine2645c62018-05-24 20:39:04 -07006585enum qca_wlan_vendor_attr_tdls_get_capabilities {
Peng Xu291d97d2018-01-31 16:34:03 -08006586 QCA_WLAN_VENDOR_ATTR_TDLS_GET_CAPS_INVALID = 0,
6587 /* Indicates the max concurrent sessions */
6588 /* Unsigned 32-bit value */
6589 QCA_WLAN_VENDOR_ATTR_TDLS_GET_CAPS_MAX_CONC_SESSIONS,
6590 /* Indicates the support for features */
6591 /* Unsigned 32-bit bitmap qca_wlan_tdls_caps_features_supported
6592 */
6593 QCA_WLAN_VENDOR_ATTR_TDLS_GET_CAPS_FEATURES_SUPPORTED,
6594
6595 /* keep last */
6596 QCA_WLAN_VENDOR_ATTR_TDLS_GET_CAPS_AFTER_LAST,
6597 QCA_WLAN_VENDOR_ATTR_TDLS_GET_CAPS_MAX =
6598 QCA_WLAN_VENDOR_ATTR_TDLS_GET_CAPS_AFTER_LAST - 1,
6599};
6600
6601/**
6602 * enum qca_wlan_offloaded_packets_sending_control - Offload packets control
6603 * command used as value for the attribute
6604 * QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_SENDING_CONTROL.
6605 */
Arif Hussaine2645c62018-05-24 20:39:04 -07006606enum qca_wlan_offloaded_packets_sending_control {
Peng Xu291d97d2018-01-31 16:34:03 -08006607 QCA_WLAN_OFFLOADED_PACKETS_SENDING_CONTROL_INVALID = 0,
6608 QCA_WLAN_OFFLOADED_PACKETS_SENDING_START,
6609 QCA_WLAN_OFFLOADED_PACKETS_SENDING_STOP
6610};
6611
6612/**
6613 * enum qca_wlan_vendor_attr_offloaded_packets - Used by the vendor command
6614 * QCA_NL80211_VENDOR_SUBCMD_OFFLOADED_PACKETS.
6615 */
6616enum qca_wlan_vendor_attr_offloaded_packets {
6617 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_INVALID = 0,
6618 /* Takes valid value from the enum
6619 * qca_wlan_offloaded_packets_sending_control
6620 * Unsigned 32-bit value
6621 */
6622 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_SENDING_CONTROL,
6623 /* Unsigned 32-bit value */
6624 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_REQUEST_ID,
6625 /* array of u8 len: Max packet size */
6626 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_IP_PACKET_DATA,
6627 /* 6-byte MAC address used to represent source MAC address */
6628 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_SRC_MAC_ADDR,
6629 /* 6-byte MAC address used to represent destination MAC address */
6630 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_DST_MAC_ADDR,
6631 /* Unsigned 32-bit value, in milli seconds */
6632 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_PERIOD,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08006633 /* This optional unsigned 16-bit attribute is used for specifying
6634 * ethernet protocol type. If not specified ethertype defaults to IPv4.
6635 */
6636 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_ETHER_PROTO_TYPE,
Peng Xu291d97d2018-01-31 16:34:03 -08006637
6638 /* keep last */
6639 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_AFTER_LAST,
6640 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_MAX =
6641 QCA_WLAN_VENDOR_ATTR_OFFLOADED_PACKETS_AFTER_LAST - 1,
6642};
6643
6644/**
6645 * enum qca_wlan_rssi_monitoring_control - RSSI control commands used as values
6646 * by the attribute QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_CONTROL.
6647 */
6648enum qca_wlan_rssi_monitoring_control {
6649 QCA_WLAN_RSSI_MONITORING_CONTROL_INVALID = 0,
6650 QCA_WLAN_RSSI_MONITORING_START,
6651 QCA_WLAN_RSSI_MONITORING_STOP,
6652};
6653
6654/**
6655 * enum qca_wlan_vendor_attr_rssi_monitoring - Used by the vendor command
6656 * QCA_NL80211_VENDOR_SUBCMD_MONITOR_RSSI.
6657 */
6658enum qca_wlan_vendor_attr_rssi_monitoring {
6659 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_INVALID = 0,
6660 /* Takes valid value from the enum
6661 * qca_wlan_rssi_monitoring_control
6662 * Unsigned 32-bit value enum qca_wlan_rssi_monitoring_control
6663 */
6664 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_CONTROL,
6665 /* Unsigned 32-bit value */
6666 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_REQUEST_ID,
6667 /* Signed 8-bit value in dBm */
6668 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_MAX_RSSI,
6669 /* Signed 8-bit value in dBm */
6670 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_MIN_RSSI,
6671 /* attributes to be used/received in callback */
6672 /* 6-byte MAC address used to represent current BSSID MAC address */
6673 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_CUR_BSSID,
6674 /* Signed 8-bit value indicating the current RSSI */
6675 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_CUR_RSSI,
6676 /* keep last */
6677 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_AFTER_LAST,
6678 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_MAX =
6679 QCA_WLAN_VENDOR_ATTR_RSSI_MONITORING_AFTER_LAST - 1,
6680};
6681
6682/**
6683 * enum qca_wlan_vendor_attr_ndp_params - Used by the vendor command
6684 * QCA_NL80211_VENDOR_SUBCMD_NDP.
6685 */
6686enum qca_wlan_vendor_attr_ndp_params {
6687 QCA_WLAN_VENDOR_ATTR_NDP_PARAM_INVALID = 0,
6688 /* Unsigned 32-bit value
6689 * enum of sub commands values in qca_wlan_ndp_sub_cmd
6690 */
6691 QCA_WLAN_VENDOR_ATTR_NDP_SUBCMD,
6692 /* Unsigned 16-bit value */
6693 QCA_WLAN_VENDOR_ATTR_NDP_TRANSACTION_ID,
6694 /* NL attributes for data used NDP SUB cmds */
6695 /* Unsigned 32-bit value indicating a service info */
6696 QCA_WLAN_VENDOR_ATTR_NDP_SERVICE_INSTANCE_ID,
6697 /* Unsigned 32-bit value; channel frequency in MHz */
6698 QCA_WLAN_VENDOR_ATTR_NDP_CHANNEL,
6699 /* Interface Discovery MAC address. An array of 6 Unsigned int8 */
6700 QCA_WLAN_VENDOR_ATTR_NDP_PEER_DISCOVERY_MAC_ADDR,
6701 /* Interface name on which NDP is being created */
6702 QCA_WLAN_VENDOR_ATTR_NDP_IFACE_STR,
6703 /* Unsigned 32-bit value for security */
6704 /* CONFIG_SECURITY is deprecated, use NCS_SK_TYPE/PMK/SCID instead */
6705 QCA_WLAN_VENDOR_ATTR_NDP_CONFIG_SECURITY,
6706 /* Unsigned 32-bit value for QoS */
6707 QCA_WLAN_VENDOR_ATTR_NDP_CONFIG_QOS,
6708 /* Array of u8: len = QCA_WLAN_VENDOR_ATTR_NAN_DP_APP_INFO_LEN */
6709 QCA_WLAN_VENDOR_ATTR_NDP_APP_INFO,
6710 /* Unsigned 32-bit value for NDP instance Id */
6711 QCA_WLAN_VENDOR_ATTR_NDP_INSTANCE_ID,
6712 /* Array of instance Ids */
6713 QCA_WLAN_VENDOR_ATTR_NDP_INSTANCE_ID_ARRAY,
6714 /* Unsigned 32-bit value for initiator/responder NDP response code
Arif Hussaine2645c62018-05-24 20:39:04 -07006715 * accept/reject
6716 */
Peng Xu291d97d2018-01-31 16:34:03 -08006717 QCA_WLAN_VENDOR_ATTR_NDP_RESPONSE_CODE,
6718 /* NDI MAC address. An array of 6 Unsigned int8 */
6719 QCA_WLAN_VENDOR_ATTR_NDP_NDI_MAC_ADDR,
6720 /* Unsigned 32-bit value errors types returned by driver
6721 * The wifi_nan.h in AOSP project platform/hardware/libhardware_legacy
6722 * NanStatusType includes these values.
6723 */
6724 QCA_WLAN_VENDOR_ATTR_NDP_DRV_RESPONSE_STATUS_TYPE,
6725 /* Unsigned 32-bit value error values returned by driver
6726 * The nan_i.h in AOSP project platform/hardware/qcom/wlan
6727 * NanInternalStatusType includes these values.
6728 */
6729 QCA_WLAN_VENDOR_ATTR_NDP_DRV_RETURN_VALUE,
6730 /* Unsigned 32-bit value for Channel setup configuration
6731 * The wifi_nan.h in AOSP project platform/hardware/libhardware_legacy
6732 * NanDataPathChannelCfg includes these values.
6733 */
6734 QCA_WLAN_VENDOR_ATTR_NDP_CHANNEL_CONFIG,
6735 /* Unsigned 32-bit value for Cipher Suite Shared Key Type */
6736 QCA_WLAN_VENDOR_ATTR_NDP_CSID,
6737 /* Array of u8: len = NAN_PMK_INFO_LEN 32 bytes */
6738 QCA_WLAN_VENDOR_ATTR_NDP_PMK,
6739 /* Security Context Identifier that contains the PMKID
6740 * Array of u8: len = NAN_SCID_BUF_LEN 1024 bytes
6741 */
6742 QCA_WLAN_VENDOR_ATTR_NDP_SCID,
6743 /* Array of u8: len = NAN_SECURITY_MAX_PASSPHRASE_LEN 63 bytes */
6744 QCA_WLAN_VENDOR_ATTR_NDP_PASSPHRASE,
6745 /* Array of u8: len = NAN_MAX_SERVICE_NAME_LEN 255 bytes */
6746 QCA_WLAN_VENDOR_ATTR_NDP_SERVICE_NAME,
6747 /* Unsigned 32-bit bitmap indicating schedule update
6748 * BIT_0: NSS Update
6749 * BIT_1: Channel list update
6750 */
6751 QCA_WLAN_VENDOR_ATTR_NDP_SCHEDULE_UPDATE_REASON,
6752 /* Unsigned 32-bit value for NSS */
6753 QCA_WLAN_VENDOR_ATTR_NDP_NSS,
6754 /* Unsigned 32-bit value for NUMBER NDP CHANNEL */
6755 QCA_WLAN_VENDOR_ATTR_NDP_NUM_CHANNELS,
6756 /* Unsigned 32-bit value for CHANNEL BANDWIDTH
6757 * 0:20 MHz, 1:40 MHz, 2:80 MHz, 3:160 MHz
6758 */
6759 QCA_WLAN_VENDOR_ATTR_NDP_CHANNEL_WIDTH,
6760 /* Array of channel/band width */
6761 QCA_WLAN_VENDOR_ATTR_NDP_CHANNEL_INFO,
Arif Hussaine2645c62018-05-24 20:39:04 -07006762 /* IPv6 address used by NDP (in network byte order), 16 bytes array.
6763 * This attribute is used and optional for ndp request, ndp response,
6764 * ndp indication, and ndp confirm.
6765 */
6766 QCA_WLAN_VENDOR_ATTR_NDP_IPV6_ADDR = 27,
6767 /* Unsigned 16-bit value indicating transport port used by NDP.
6768 * This attribute is used and optional for ndp response, ndp indication,
6769 * and ndp confirm.
6770 */
6771 QCA_WLAN_VENDOR_ATTR_NDP_TRANSPORT_PORT = 28,
6772 /* Unsigned 8-bit value indicating protocol used by NDP and assigned by
6773 * the Internet Assigned Numbers Authority (IANA) as per:
6774 * https://www.iana.org/assignments/protocol-numbers/protocol-numbers.xhtml
6775 * This attribute is used and optional for ndp response, ndp indication,
6776 * and ndp confirm.
6777 */
6778 QCA_WLAN_VENDOR_ATTR_NDP_TRANSPORT_PROTOCOL = 29,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07006779 /* Unsigned 8-bit value indicating if NDP remote peer supports NAN NDPE.
6780 * 1:support 0:not support
6781 */
6782 QCA_WLAN_VENDOR_ATTR_PEER_NDPE_SUPPORT = 30,
Peng Xu291d97d2018-01-31 16:34:03 -08006783
6784 /* keep last */
6785 QCA_WLAN_VENDOR_ATTR_NDP_PARAMS_AFTER_LAST,
6786 QCA_WLAN_VENDOR_ATTR_NDP_PARAMS_MAX =
6787 QCA_WLAN_VENDOR_ATTR_NDP_PARAMS_AFTER_LAST - 1,
6788};
6789
6790enum qca_wlan_ndp_sub_cmd {
6791 QCA_WLAN_VENDOR_ATTR_NDP_INVALID = 0,
6792 /* Command to create a NAN data path interface */
6793 QCA_WLAN_VENDOR_ATTR_NDP_INTERFACE_CREATE = 1,
6794 /* Command to delete a NAN data path interface */
6795 QCA_WLAN_VENDOR_ATTR_NDP_INTERFACE_DELETE = 2,
6796 /* Command to initiate a NAN data path session */
6797 QCA_WLAN_VENDOR_ATTR_NDP_INITIATOR_REQUEST = 3,
6798 /* Command to notify if the NAN data path session was sent */
6799 QCA_WLAN_VENDOR_ATTR_NDP_INITIATOR_RESPONSE = 4,
6800 /* Command to respond to NAN data path session */
6801 QCA_WLAN_VENDOR_ATTR_NDP_RESPONDER_REQUEST = 5,
6802 /* Command to notify on the responder about the response */
6803 QCA_WLAN_VENDOR_ATTR_NDP_RESPONDER_RESPONSE = 6,
6804 /* Command to initiate a NAN data path end */
6805 QCA_WLAN_VENDOR_ATTR_NDP_END_REQUEST = 7,
6806 /* Command to notify the if end request was sent */
6807 QCA_WLAN_VENDOR_ATTR_NDP_END_RESPONSE = 8,
6808 /* Command to notify the peer about the end request */
6809 QCA_WLAN_VENDOR_ATTR_NDP_REQUEST_IND = 9,
6810 /* Command to confirm the NAN data path session is complete */
6811 QCA_WLAN_VENDOR_ATTR_NDP_CONFIRM_IND = 10,
6812 /* Command to indicate the peer about the end request being received */
6813 QCA_WLAN_VENDOR_ATTR_NDP_END_IND = 11,
6814 /* Command to indicate the peer of schedule update */
6815 QCA_WLAN_VENDOR_ATTR_NDP_SCHEDULE_UPDATE_IND = 12
6816};
6817
6818/**
6819 * enum qca_wlan_vendor_attr_nd_offload - Used by the vendor command
6820 * QCA_NL80211_VENDOR_SUBCMD_ND_OFFLOAD.
6821 */
6822enum qca_wlan_vendor_attr_nd_offload {
6823 QCA_WLAN_VENDOR_ATTR_ND_OFFLOAD_INVALID = 0,
6824 /* Flag to set Neighbour Discovery offload */
6825 QCA_WLAN_VENDOR_ATTR_ND_OFFLOAD_FLAG,
6826 /* Keep last */
6827 QCA_WLAN_VENDOR_ATTR_ND_OFFLOAD_AFTER_LAST,
6828 QCA_WLAN_VENDOR_ATTR_ND_OFFLOAD_MAX =
6829 QCA_WLAN_VENDOR_ATTR_ND_OFFLOAD_AFTER_LAST - 1,
6830};
6831
6832/**
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006833 * enum packet_filter_sub_cmd - Packet filter sub commands
Peng Xu291d97d2018-01-31 16:34:03 -08006834 */
6835enum packet_filter_sub_cmd {
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006836 /**
6837 * Write packet filter program and/or data. The driver/firmware should
6838 * disable APF before writing into local buffer and re-enable APF after
6839 * writing is done.
6840 */
Peng Xu291d97d2018-01-31 16:34:03 -08006841 QCA_WLAN_SET_PACKET_FILTER = 1,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006842 /* Get packet filter feature capabilities from driver */
Peng Xu291d97d2018-01-31 16:34:03 -08006843 QCA_WLAN_GET_PACKET_FILTER = 2,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006844 /**
6845 * Write packet filter program and/or data. User space will send the
6846 * %QCA_WLAN_DISABLE_PACKET_FILTER command before issuing this command
6847 * and will send the %QCA_WLAN_ENABLE_PACKET_FILTER afterwards. The key
6848 * difference from that %QCA_WLAN_SET_PACKET_FILTER is the control over
6849 * enable/disable is given to user space with this command. Also,
6850 * user space sends the length of program portion in the buffer within
6851 * %QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_PROG_LENGTH.
6852 */
6853 QCA_WLAN_WRITE_PACKET_FILTER = 3,
6854 /* Read packet filter program and/or data */
6855 QCA_WLAN_READ_PACKET_FILTER = 4,
6856 /* Enable APF feature */
6857 QCA_WLAN_ENABLE_PACKET_FILTER = 5,
6858 /* Disable APF feature */
6859 QCA_WLAN_DISABLE_PACKET_FILTER = 6,
Peng Xu291d97d2018-01-31 16:34:03 -08006860};
6861
6862/**
6863 * enum qca_wlan_vendor_attr_packet_filter - BPF control commands used by
6864 * vendor QCA_NL80211_VENDOR_SUBCMD_PACKET_FILTER.
6865 */
6866enum qca_wlan_vendor_attr_packet_filter {
6867 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_INVALID = 0,
6868 /* Unsigned 32-bit enum passed using packet_filter_sub_cmd */
6869 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_SUB_CMD,
6870 /* Unsigned 32-bit value indicating the packet filter version */
6871 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_VERSION,
6872 /* Unsigned 32-bit value indicating the packet filter id */
6873 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_ID,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006874 /**
6875 * Unsigned 32-bit value indicating the packet filter size including
6876 * program + data.
6877 */
Peng Xu291d97d2018-01-31 16:34:03 -08006878 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_SIZE,
6879 /* Unsigned 32-bit value indicating the packet filter current offset */
6880 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_CURRENT_OFFSET,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006881 /* Program and/or data in bytes */
Peng Xu291d97d2018-01-31 16:34:03 -08006882 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_PROGRAM,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006883 /* Unsigned 32-bit value of the length of the program section in packet
6884 * filter buffer.
6885 */
6886 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_PROG_LENGTH = 7,
6887
Peng Xu291d97d2018-01-31 16:34:03 -08006888 /* keep last */
6889 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_AFTER_LAST,
6890 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_MAX =
6891 QCA_WLAN_VENDOR_ATTR_PACKET_FILTER_AFTER_LAST - 1,
6892};
6893
6894/**
6895 * enum qca_wlan_vendor_drv_info - WLAN driver info used by vendor command
6896 * QCA_NL80211_VENDOR_SUBCMD_GET_BUS_SIZE.
6897 */
6898enum qca_wlan_vendor_drv_info {
6899 QCA_WLAN_VENDOR_ATTR_DRV_INFO_INVALID = 0,
6900 /* Maximum Message size info between firmware & HOST
6901 * Unsigned 32-bit value
6902 */
6903 QCA_WLAN_VENDOR_ATTR_DRV_INFO_BUS_SIZE,
6904 /* keep last */
6905 QCA_WLAN_VENDOR_ATTR_DRV_INFO_AFTER_LAST,
6906 QCA_WLAN_VENDOR_ATTR_DRV_INFO_MAX =
6907 QCA_WLAN_VENDOR_ATTR_DRV_INFO_AFTER_LAST - 1,
6908};
6909
6910/**
6911 * enum qca_wlan_vendor_attr_wake_stats - Wake lock stats used by vendor
6912 * command QCA_NL80211_VENDOR_SUBCMD_GET_WAKE_REASON_STATS.
6913 */
6914enum qca_wlan_vendor_attr_wake_stats {
6915 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_INVALID = 0,
6916 /* Unsigned 32-bit value indicating the total count of wake event */
6917 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_TOTAL_CMD_EVENT_WAKE,
6918 /* Array of individual wake count, each index representing wake reason
6919 */
6920 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_CMD_EVENT_WAKE_CNT_PTR,
6921 /* Unsigned 32-bit value representing wake count array */
6922 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_CMD_EVENT_WAKE_CNT_SZ,
6923 /* Unsigned 32-bit total wake count value of driver/fw */
6924 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_TOTAL_DRIVER_FW_LOCAL_WAKE,
6925 /* Array of wake stats of driver/fw */
6926 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_DRIVER_FW_LOCAL_WAKE_CNT_PTR,
6927 /* Unsigned 32-bit total wake count value of driver/fw */
6928 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_DRIVER_FW_LOCAL_WAKE_CNT_SZ,
6929 /* Unsigned 32-bit total wake count value of packets received */
6930 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_TOTAL_RX_DATA_WAKE,
6931 /* Unsigned 32-bit wake count value unicast packets received */
6932 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_RX_UNICAST_CNT,
6933 /* Unsigned 32-bit wake count value multicast packets received */
6934 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_RX_MULTICAST_CNT,
6935 /* Unsigned 32-bit wake count value broadcast packets received */
6936 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_RX_BROADCAST_CNT,
6937 /* Unsigned 32-bit wake count value of ICMP packets */
6938 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_ICMP_PKT,
6939 /* Unsigned 32-bit wake count value of ICMP6 packets */
6940 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_ICMP6_PKT,
6941 /* Unsigned 32-bit value ICMP6 router advertisement */
6942 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_ICMP6_RA,
6943 /* Unsigned 32-bit value ICMP6 neighbor advertisement */
6944 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_ICMP6_NA,
6945 /* Unsigned 32-bit value ICMP6 neighbor solicitation */
6946 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_ICMP6_NS,
6947 /* Unsigned 32-bit wake count value of receive side ICMP4 multicast */
6948 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_ICMP4_RX_MULTICAST_CNT,
6949 /* Unsigned 32-bit wake count value of receive side ICMP6 multicast */
6950 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_ICMP6_RX_MULTICAST_CNT,
6951 /* Unsigned 32-bit wake count value of receive side multicast */
6952 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_OTHER_RX_MULTICAST_CNT,
6953 /* Unsigned 32-bit wake count value of a given RSSI breach */
6954 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_RSSI_BREACH_CNT,
6955 /* Unsigned 32-bit wake count value of low RSSI */
6956 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_LOW_RSSI_CNT,
6957 /* Unsigned 32-bit value GSCAN count */
6958 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_GSCAN_CNT,
6959 /* Unsigned 32-bit value PNO complete count */
6960 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_PNO_COMPLETE_CNT,
6961 /* Unsigned 32-bit value PNO match count */
6962 QCA_WLAN_VENDOR_ATTR_WAKE_STATS_PNO_MATCH_CNT,
6963 /* keep last */
6964 QCA_WLAN_VENDOR_GET_WAKE_STATS_AFTER_LAST,
6965 QCA_WLAN_VENDOR_GET_WAKE_STATS_MAX =
6966 QCA_WLAN_VENDOR_GET_WAKE_STATS_AFTER_LAST - 1,
6967};
6968
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006969/**
Jouni Malinenf735abd2020-08-03 11:08:00 +03006970 * enum qca_wlan_vendor_thermal_level - Defines various thermal levels
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05306971 * configured by userspace to the driver/firmware.
6972 * The values can be encapsulated in QCA_WLAN_VENDOR_ATTR_THERMAL_LEVEL or
6973 * QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_LEVEL attribute.
Jouni Malinenf735abd2020-08-03 11:08:00 +03006974 * The driver/firmware takes actions requested by userspace such as throttling
6975 * wifi TX etc. in order to mitigate high temperature.
6976 *
6977 * @QCA_WLAN_VENDOR_THERMAL_LEVEL_NONE: Stop/clear all throttling actions.
6978 * @QCA_WLAN_VENDOR_THERMAL_LEVEL_LIGHT: Throttle TX lightly.
6979 * @QCA_WLAN_VENDOR_THERMAL_LEVEL_MODERATE: Throttle TX moderately.
6980 * @QCA_WLAN_VENDOR_THERMAL_LEVEL_SEVERE: Throttle TX severely.
6981 * @QCA_WLAN_VENDOR_THERMAL_LEVEL_CRITICAL: Critical thermal level reached.
6982 * @QCA_WLAN_VENDOR_THERMAL_LEVEL_EMERGENCY: Emergency thermal level reached.
6983 */
6984enum qca_wlan_vendor_thermal_level {
6985 QCA_WLAN_VENDOR_THERMAL_LEVEL_NONE = 0,
6986 QCA_WLAN_VENDOR_THERMAL_LEVEL_LIGHT = 1,
6987 QCA_WLAN_VENDOR_THERMAL_LEVEL_MODERATE = 2,
6988 QCA_WLAN_VENDOR_THERMAL_LEVEL_SEVERE = 3,
6989 QCA_WLAN_VENDOR_THERMAL_LEVEL_CRITICAL = 4,
6990 QCA_WLAN_VENDOR_THERMAL_LEVEL_EMERGENCY = 5,
6991};
6992
6993/**
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08006994 * enum qca_wlan_vendor_attr_thermal_cmd - Vendor subcmd attributes to set
6995 * cmd value. Used for NL attributes for data used by
6996 * QCA_NL80211_VENDOR_SUBCMD_THERMAL_CMD sub command.
6997 */
6998enum qca_wlan_vendor_attr_thermal_cmd {
6999 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_INVALID = 0,
7000 /* The value of command, driver will implement different operations
7001 * according to this value. It uses values defined in
7002 * enum qca_wlan_vendor_attr_thermal_cmd_type.
7003 * u32 attribute.
7004 */
7005 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_VALUE = 1,
Jouni Malinenf735abd2020-08-03 11:08:00 +03007006 /* Userspace uses this attribute to configure thermal level to the
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307007 * driver/firmware, or get thermal level from the driver/firmware.
7008 * Used in request or response, u32 attribute,
7009 * possible values are defined in enum qca_wlan_vendor_thermal_level.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007010 */
7011 QCA_WLAN_VENDOR_ATTR_THERMAL_LEVEL = 2,
7012 /* Userspace uses this attribute to configure the time in which the
7013 * driver/firmware should complete applying settings it received from
7014 * userspace with QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_SET_LEVEL
7015 * command type. Used in request, u32 attribute, value is in
7016 * milliseconds. A value of zero indicates to apply the settings
7017 * immediately. The driver/firmware can delay applying the configured
7018 * thermal settings within the time specified in this attribute if
7019 * there is any critical ongoing operation.
7020 */
7021 QCA_WLAN_VENDOR_ATTR_THERMAL_COMPLETION_WINDOW = 3,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007022
7023 /* keep last */
7024 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_AFTER_LAST,
7025 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_MAX =
7026 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_AFTER_LAST - 1
7027};
7028
7029/**
7030 * qca_wlan_vendor_attr_thermal_cmd_type: Attribute values for
7031 * QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_VALUE to the vendor subcmd
7032 * QCA_NL80211_VENDOR_SUBCMD_THERMAL_CMD. This represents the
7033 * thermal command types sent to driver.
7034 * @QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_PARAMS: Request to
7035 * get thermal shutdown configuration parameters for display. Parameters
7036 * responded from driver are defined in
7037 * enum qca_wlan_vendor_attr_get_thermal_params_rsp.
7038 * @QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_TEMPERATURE: Request to
7039 * get temperature. Host should respond with a temperature data. It is defined
7040 * in enum qca_wlan_vendor_attr_thermal_get_temperature.
7041 * @QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_SUSPEND: Request to execute thermal
7042 * suspend action.
7043 * @QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_RESUME: Request to execute thermal
7044 * resume action.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007045 * @QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_SET_LEVEL: Configure thermal level to
7046 * the driver/firmware.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307047 * @QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_LEVEL: Request to get the current
7048 * thermal level from the driver/firmware. The driver should respond with a
7049 * thermal level defined in enum qca_wlan_vendor_thermal_level.
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007050 */
7051enum qca_wlan_vendor_attr_thermal_cmd_type {
7052 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_PARAMS,
7053 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_TEMPERATURE,
7054 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_SUSPEND,
7055 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_RESUME,
Jouni Malinenf735abd2020-08-03 11:08:00 +03007056 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_SET_LEVEL,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307057 QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_LEVEL,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007058};
7059
7060/**
7061 * enum qca_wlan_vendor_attr_thermal_get_temperature - vendor subcmd attributes
7062 * to get chip temperature by user.
7063 * enum values are used for NL attributes for data used by
7064 * QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_TEMPERATURE command for data used
7065 * by QCA_NL80211_VENDOR_SUBCMD_THERMAL_CMD sub command.
7066 */
7067enum qca_wlan_vendor_attr_thermal_get_temperature {
7068 QCA_WLAN_VENDOR_ATTR_THERMAL_GET_TEMPERATURE_INVALID = 0,
7069 /* Temperature value (degree Celsius) from driver.
7070 * u32 attribute.
7071 */
7072 QCA_WLAN_VENDOR_ATTR_THERMAL_GET_TEMPERATURE_DATA,
7073
7074 /* keep last */
7075 QCA_WLAN_VENDOR_ATTR_THERMAL_GET_TEMPERATURE_AFTER_LAST,
7076 QCA_WLAN_VENDOR_ATTR_THERMAL_GET_TEMPERATURE_MAX =
7077 QCA_WLAN_VENDOR_ATTR_THERMAL_GET_TEMPERATURE_AFTER_LAST - 1,
7078};
7079
7080/**
7081 * enum qca_wlan_vendor_attr_get_thermal_params_rsp - vendor subcmd attributes
7082 * to get configuration parameters of thermal shutdown feature. Enum values are
7083 * used by QCA_WLAN_VENDOR_ATTR_THERMAL_CMD_TYPE_GET_PARAMS command for data
7084 * used by QCA_NL80211_VENDOR_SUBCMD_THERMAL_CMD sub command.
7085 */
7086enum qca_wlan_vendor_attr_get_thermal_params_rsp {
7087 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_INVALID = 0,
7088 /* Indicate if the thermal shutdown feature is enabled.
7089 * NLA_FLAG attribute.
7090 */
7091 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_SHUTDOWN_EN,
7092 /* Indicate if the auto mode is enabled.
7093 * Enable: Driver triggers the suspend/resume action.
7094 * Disable: User space triggers the suspend/resume action.
7095 * NLA_FLAG attribute.
7096 */
7097 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_SHUTDOWN_AUTO_EN,
7098 /* Thermal resume threshold (degree Celsius). Issue the resume command
7099 * if the temperature value is lower than this threshold.
7100 * u16 attribute.
7101 */
7102 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_RESUME_THRESH,
7103 /* Thermal warning threshold (degree Celsius). FW reports temperature
7104 * to driver if it's higher than this threshold.
7105 * u16 attribute.
7106 */
7107 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_WARNING_THRESH,
7108 /* Thermal suspend threshold (degree Celsius). Issue the suspend command
7109 * if the temperature value is higher than this threshold.
7110 * u16 attribute.
7111 */
7112 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_SUSPEND_THRESH,
7113 /* FW reports temperature data periodically at this interval (ms).
7114 * u16 attribute.
7115 */
7116 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_SAMPLE_RATE,
7117
7118 /* keep last */
7119 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_AFTER_LAST,
7120 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_MAX =
7121 QCA_WLAN_VENDOR_ATTR_GET_THERMAL_PARAMS_RSP_AFTER_LAST - 1,
7122};
7123
7124/**
7125 * enum qca_wlan_vendor_attr_thermal_event - vendor subcmd attributes to
7126 * report thermal events from driver to user space.
7127 * enum values are used for NL attributes for data used by
7128 * QCA_NL80211_VENDOR_SUBCMD_THERMAL_EVENT sub command.
7129 */
7130enum qca_wlan_vendor_attr_thermal_event {
7131 QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_INVALID = 0,
7132 /* Temperature value (degree Celsius) from driver.
7133 * u32 attribute.
7134 */
7135 QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_TEMPERATURE,
7136 /* Indication of resume completion from power save mode.
7137 * NLA_FLAG attribute.
7138 */
7139 QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_RESUME_COMPLETE,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307140 /* Thermal level from the driver.
7141 * u32 attribute. Possible values are defined in
7142 * enum qca_wlan_vendor_thermal_level.
7143 */
7144 QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_LEVEL = 3,
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007145
7146 /* keep last */
7147 QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_AFTER_LAST,
7148 QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_MAX =
7149 QCA_WLAN_VENDOR_ATTR_THERMAL_EVENT_AFTER_LAST - 1,
7150};
7151
7152/**
7153 * enum he_fragmentation_val - HE fragmentation support values
7154 * Indicates level of dynamic fragmentation that is supported by
7155 * a STA as a recipient.
7156 * HE fragmentation values are defined in IEEE P802.11ax/D2.0, 9.4.2.237.2
7157 * (HE MAC Capabilities Information field) and are used in HE Capabilities
7158 * element to advertise the support. These values are validated in the driver
7159 * to check the device capability and advertised in the HE Capabilities
7160 * element. These values are used to configure testbed device to allow the
7161 * advertised hardware capabilities to be downgraded for testing purposes.
7162 *
7163 * @HE_FRAG_DISABLE: no support for dynamic fragmentation
7164 * @HE_FRAG_LEVEL1: support for dynamic fragments that are
Arif Hussaine2645c62018-05-24 20:39:04 -07007165 * contained within an MPDU or S-MPDU, no support for dynamic fragments
7166 * within an A-MPDU that is not an S-MPDU.
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007167 * @HE_FRAG_LEVEL2: support for dynamic fragments that are
Arif Hussaine2645c62018-05-24 20:39:04 -07007168 * contained within an MPDU or S-MPDU and support for up to one dynamic
7169 * fragment for each MSDU, each A-MSDU if supported by the recipient, and
7170 * each MMPDU within an A-MPDU or multi-TID A-MPDU that is not an
7171 * MPDU or S-MPDU.
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007172 * @HE_FRAG_LEVEL3: support for dynamic fragments that are
Arif Hussaine2645c62018-05-24 20:39:04 -07007173 * contained within an MPDU or S-MPDU and support for multiple dynamic
7174 * fragments for each MSDU and for each A-MSDU if supported by the
7175 * recipient within an A-MPDU or multi-TID AMPDU and up to one dynamic
7176 * fragment for each MMPDU in a multi-TID A-MPDU that is not an S-MPDU.
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007177 */
7178enum he_fragmentation_val {
7179 HE_FRAG_DISABLE,
7180 HE_FRAG_LEVEL1,
7181 HE_FRAG_LEVEL2,
7182 HE_FRAG_LEVEL3,
7183};
7184
7185/**
7186 * enum he_mcs_config - HE MCS support configuration
7187 *
7188 * Configures the HE Tx/Rx MCS map in HE capability IE for given bandwidth.
7189 * These values are used in driver to configure the HE MCS map to advertise
7190 * Tx/Rx MCS map in HE capability and these values are applied for all the
7191 * streams supported by the device. To configure MCS for different bandwidths,
7192 * vendor command needs to be sent using this attribute with appropriate value.
7193 * For example, to configure HE_80_MCS_0_7, send vendor command using HE MCS
7194 * attribute with HE_80_MCS0_7. And to configure HE MCS for HE_160_MCS0_11
7195 * send this command using HE MCS config attribute with value HE_160_MCS0_11.
7196 * These values are used to configure testbed device to allow the advertised
7197 * hardware capabilities to be downgraded for testing purposes. The enum values
7198 * are defined such that BIT[1:0] indicates the MCS map value. Values 3,7 and
7199 * 11 are not used as BIT[1:0] value is 3 which is used to disable MCS map.
7200 * These values are validated in the driver before setting the MCS map and
7201 * driver returns error if the input is other than these enum values.
7202 *
7203 * @HE_80_MCS0_7: support for HE 80/40/20 MHz MCS 0 to 7
7204 * @HE_80_MCS0_9: support for HE 80/40/20 MHz MCS 0 to 9
7205 * @HE_80_MCS0_11: support for HE 80/40/20 MHz MCS 0 to 11
7206 * @HE_160_MCS0_7: support for HE 160 MHz MCS 0 to 7
7207 * @HE_160_MCS0_9: support for HE 160 MHz MCS 0 to 9
7208 * @HE_160_MCS0_11: support for HE 160 MHz MCS 0 to 11
7209 * @HE_80P80_MCS0_7: support for HE 80p80 MHz MCS 0 to 7
7210 * @HE_80P80_MCS0_9: support for HE 80p80 MHz MCS 0 to 9
7211 * @HE_80P80_MCS0_11: support for HE 80p80 MHz MCS 0 to 11
7212 */
7213enum he_mcs_config {
7214 HE_80_MCS0_7 = 0,
7215 HE_80_MCS0_9 = 1,
7216 HE_80_MCS0_11 = 2,
7217 HE_160_MCS0_7 = 4,
7218 HE_160_MCS0_9 = 5,
7219 HE_160_MCS0_11 = 6,
7220 HE_80P80_MCS0_7 = 8,
7221 HE_80P80_MCS0_9 = 9,
7222 HE_80P80_MCS0_11 = 10,
7223};
7224
Amarnath Hullur Subramanyamfa752712018-02-23 11:32:38 -08007225/**
7226 * enum qca_wlan_ba_session_config - BA session configuration
7227 *
7228 * Indicates the configuration values for BA session configuration attribute.
7229 *
7230 * @QCA_WLAN_ADD_BA: Establish a new BA session with given configuration.
7231 * @QCA_WLAN_DELETE_BA: Delete the existing BA session for given TID.
7232 */
7233enum qca_wlan_ba_session_config {
7234 QCA_WLAN_ADD_BA = 1,
7235 QCA_WLAN_DELETE_BA = 2,
7236};
7237
7238/**
7239 * enum qca_wlan_ac_type - Access category type
7240 *
7241 * Indicates the access category type value.
7242 *
7243 * @QCA_WLAN_AC_BE: BE access category
7244 * @QCA_WLAN_AC_BK: BK access category
7245 * @QCA_WLAN_AC_VI: VI access category
7246 * @QCA_WLAN_AC_VO: VO access category
7247 * @QCA_WLAN_AC_ALL: All ACs
7248 */
7249enum qca_wlan_ac_type {
7250 QCA_WLAN_AC_BE = 0,
7251 QCA_WLAN_AC_BK = 1,
7252 QCA_WLAN_AC_VI = 2,
7253 QCA_WLAN_AC_VO = 3,
7254 QCA_WLAN_AC_ALL = 4,
7255};
7256
Arif Hussaine2645c62018-05-24 20:39:04 -07007257/**
7258 * enum qca_wlan_he_ltf_cfg - HE LTF configuration
7259 *
7260 * Indicates the HE LTF configuration value.
7261 *
7262 * @QCA_WLAN_HE_LTF_AUTO: HE-LTF is automatically set to the mandatory HE-LTF,
7263 * based on the GI setting
7264 * @QCA_WLAN_HE_LTF_1X: 1X HE LTF is 3.2us LTF
7265 * @QCA_WLAN_HE_LTF_2X: 2X HE LTF is 6.4us LTF
7266 * @QCA_WLAN_HE_LTF_4X: 4X HE LTF is 12.8us LTF
7267 */
7268enum qca_wlan_he_ltf_cfg {
7269 QCA_WLAN_HE_LTF_AUTO = 0,
7270 QCA_WLAN_HE_LTF_1X = 1,
7271 QCA_WLAN_HE_LTF_2X = 2,
7272 QCA_WLAN_HE_LTF_4X = 3,
7273};
7274
Arif Hussaine7ae5f62018-08-08 17:28:07 -07007275/**
7276 * enum qca_wlan_he_mac_padding_dur - HE trigger frame MAC padding duration
7277 *
7278 * Indicates the HE trigger frame MAC padding duration value.
7279 *
7280 * @QCA_WLAN_HE_NO_ADDITIONAL_PROCESS_TIME: no additional time required to
7281 * process the trigger frame.
7282 * @QCA_WLAN_HE_8US_OF_PROCESS_TIME: indicates the 8us of processing time for
7283 * trigger frame.
7284 * @QCA_WLAN_HE_16US_OF_PROCESS_TIME: indicates the 16us of processing time for
7285 * trigger frame.
7286 */
7287enum qca_wlan_he_mac_padding_dur {
7288 QCA_WLAN_HE_NO_ADDITIONAL_PROCESS_TIME = 0,
7289 QCA_WLAN_HE_8US_OF_PROCESS_TIME = 1,
7290 QCA_WLAN_HE_16US_OF_PROCESS_TIME = 2,
7291};
7292
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07007293/**
7294 * enum qca_wlan_he_om_ctrl_ch_bw - HE OM control field BW configuration
7295 *
7296 * Indicates the HE Operating mode control channel width setting value.
7297 *
7298 * @QCA_WLAN_HE_OM_CTRL_BW_20M: Primary 20 MHz
7299 * @QCA_WLAN_HE_OM_CTRL_BW_40M: Primary 40 MHz
7300 * @QCA_WLAN_HE_OM_CTRL_BW_80M: Primary 80 MHz
7301 * @QCA_WLAN_HE_OM_CTRL_BW_160M: 160 MHz and 80+80 MHz
7302 */
7303enum qca_wlan_he_om_ctrl_ch_bw {
7304 QCA_WLAN_HE_OM_CTRL_BW_20M = 0,
7305 QCA_WLAN_HE_OM_CTRL_BW_40M = 1,
7306 QCA_WLAN_HE_OM_CTRL_BW_80M = 2,
7307 QCA_WLAN_HE_OM_CTRL_BW_160M = 3,
7308};
7309
Kiran Kumar Lokere2efd7682018-12-18 18:17:45 -08007310/**
7311 * enum qca_wlan_vendor_attr_he_omi_tx: Represents attributes for
7312 * HE operating mode control transmit request. These attributes are
7313 * sent as part of QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_OMI_TX and
7314 * QCA_NL80211_VENDOR_SUBCMD_WIFI_TEST_CONFIGURATION.
7315 *
7316 * @QCA_WLAN_VENDOR_ATTR_HE_OMI_RX_NSS: Mandatory 8-bit unsigned value
7317 * indicates the maximum number of spatial streams, NSS, that the STA
7318 * supports in reception for PPDU bandwidths less than or equal to 80 MHz
7319 * and is set to NSS - 1.
7320 *
7321 * @QCA_WLAN_VENDOR_ATTR_HE_OMI_CH_BW: Mandatory 8-bit unsigned value
7322 * indicates the operating channel width supported by the STA for both
7323 * reception and transmission. Uses enum qca_wlan_he_om_ctrl_ch_bw values.
7324 *
7325 * @QCA_WLAN_VENDOR_ATTR_HE_OMI_ULMU_DISABLE: Mandatory 8-bit unsigned value
7326 * indicates the all trigger based UL MU operations by the STA.
7327 * 0 - UL MU operations are enabled by the STA.
7328 * 1 - All triggered UL MU transmissions are suspended by the STA.
7329 *
7330 * @QCA_WLAN_VENDOR_ATTR_HE_OMI_TX_NSTS: Mandatory 8-bit unsigned value
7331 * indicates the maximum number of space-time streams, NSTS, that
7332 * the STA supports in transmission and is set to NSTS - 1.
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08007333 *
7334 * @QCA_WLAN_VENDOR_ATTR_HE_OMI_ULMU_DATA_DISABLE: 8-bit unsigned value
7335 * combined with the UL MU Disable subfield and the recipient's setting
7336 * of the OM Control UL MU Data Disable RX Support subfield in the HE MAC
7337 * capabilities to determine which HE TB PPDUs are possible by the
7338 * STA to transmit.
7339 * 0 - UL MU data operations are enabled by the STA.
7340 * 1 - Determine which HE TB PPDU types are allowed by the STA if UL MU disable
7341 * bit is not set, else UL MU Tx is suspended.
7342 *
Kiran Kumar Lokere2efd7682018-12-18 18:17:45 -08007343 */
7344enum qca_wlan_vendor_attr_he_omi_tx {
7345 QCA_WLAN_VENDOR_ATTR_HE_OMI_INVALID = 0,
7346 QCA_WLAN_VENDOR_ATTR_HE_OMI_RX_NSS = 1,
7347 QCA_WLAN_VENDOR_ATTR_HE_OMI_CH_BW = 2,
7348 QCA_WLAN_VENDOR_ATTR_HE_OMI_ULMU_DISABLE = 3,
7349 QCA_WLAN_VENDOR_ATTR_HE_OMI_TX_NSTS = 4,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08007350 QCA_WLAN_VENDOR_ATTR_HE_OMI_ULMU_DATA_DISABLE = 5,
Kiran Kumar Lokere2efd7682018-12-18 18:17:45 -08007351
7352 /* keep last */
7353 QCA_WLAN_VENDOR_ATTR_HE_OMI_AFTER_LAST,
7354 QCA_WLAN_VENDOR_ATTR_HE_OMI_MAX =
7355 QCA_WLAN_VENDOR_ATTR_HE_OMI_AFTER_LAST - 1,
7356};
7357
Jouni Malinenf735abd2020-08-03 11:08:00 +03007358 /**
7359 * enum qca_wlan_vendor_phy_mode - Different PHY modes
7360 * These values are used with %QCA_WLAN_VENDOR_ATTR_CONFIG_PHY_MODE.
7361 *
7362 * @QCA_WLAN_VENDOR_PHY_MODE_AUTO: autoselect
7363 * @QCA_WLAN_VENDOR_PHY_MODE_2G_AUTO: 2.4 GHz 802.11b/g/n/ax autoselect
7364 * @QCA_WLAN_VENDOR_PHY_MODE_5G_AUTO: 5 GHz 802.11a/n/ac/ax autoselect
7365 * @QCA_WLAN_VENDOR_PHY_MODE_11A: 5 GHz, OFDM
7366 * @QCA_WLAN_VENDOR_PHY_MODE_11B: 2.4 GHz, CCK
7367 * @QCA_WLAN_VENDOR_PHY_MODE_11G: 2.4 GHz, OFDM
7368 * @QCA_WLAN_VENDOR_PHY_MODE_11AGN: Support 802.11n in both 2.4 GHz and 5 GHz
7369 * @QCA_WLAN_VENDOR_PHY_MODE_11NG_HT20: 2.4 GHz, HT20
7370 * @QCA_WLAN_VENDOR_PHY_MODE_11NG_HT40PLUS: 2.4 GHz, HT40 (ext ch +1)
7371 * @QCA_WLAN_VENDOR_PHY_MODE_11NG_HT40MINUS: 2.4 GHz, HT40 (ext ch -1)
7372 * @QCA_WLAN_VENDOR_PHY_MODE_11NG_HT40: 2.4 GHz, Auto HT40
7373 * @QCA_WLAN_VENDOR_PHY_MODE_11NA_HT20: 5 GHz, HT20
7374 * @QCA_WLAN_VENDOR_PHY_MODE_11NA_HT40PLUS: 5 GHz, HT40 (ext ch +1)
7375 * @QCA_WLAN_VENDOR_PHY_MODE_11NA_HT40MINUS: 5 GHz, HT40 (ext ch -1)
7376 * @QCA_WLAN_VENDOR_PHY_MODE_11NA_HT40: 5 GHz, Auto HT40
7377 * @QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT20: 5 GHz, VHT20
7378 * @QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT40PLUS: 5 GHz, VHT40 (Ext ch +1)
7379 * @QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT40MINUS: 5 GHz VHT40 (Ext ch -1)
7380 * @QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT40: 5 GHz, VHT40
7381 * @QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT80: 5 GHz, VHT80
7382 * @QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT80P80: 5 GHz, VHT80+80
7383 * @QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT160: 5 GHz, VHT160
7384 * @QCA_WLAN_VENDOR_PHY_MODE_11AX_HE20: HE20
7385 * @QCA_WLAN_VENDOR_PHY_MODE_11AX_HE40: HE40
7386 * @QCA_WLAN_VENDOR_PHY_MODE_11AX_HE40PLUS: HE40 (ext ch +1)
7387 * @QCA_WLAN_VENDOR_PHY_MODE_11AX_HE40MINUS: HE40 (ext ch -1)
7388 * @QCA_WLAN_VENDOR_PHY_MODE_11AX_HE80: HE80
7389 * @QCA_WLAN_VENDOR_PHY_MODE_11AX_HE80P80: HE 80P80
7390 * @QCA_WLAN_VENDOR_PHY_MODE_11AX_HE160: HE160
7391 */
7392enum qca_wlan_vendor_phy_mode {
7393 QCA_WLAN_VENDOR_PHY_MODE_AUTO = 0,
7394 QCA_WLAN_VENDOR_PHY_MODE_2G_AUTO = 1,
7395 QCA_WLAN_VENDOR_PHY_MODE_5G_AUTO = 2,
7396 QCA_WLAN_VENDOR_PHY_MODE_11A = 3,
7397 QCA_WLAN_VENDOR_PHY_MODE_11B = 4,
7398 QCA_WLAN_VENDOR_PHY_MODE_11G = 5,
7399 QCA_WLAN_VENDOR_PHY_MODE_11AGN = 6,
7400 QCA_WLAN_VENDOR_PHY_MODE_11NG_HT20 = 7,
7401 QCA_WLAN_VENDOR_PHY_MODE_11NG_HT40PLUS = 8,
7402 QCA_WLAN_VENDOR_PHY_MODE_11NG_HT40MINUS = 9,
7403 QCA_WLAN_VENDOR_PHY_MODE_11NG_HT40 = 10,
7404 QCA_WLAN_VENDOR_PHY_MODE_11NA_HT20 = 11,
7405 QCA_WLAN_VENDOR_PHY_MODE_11NA_HT40PLUS = 12,
7406 QCA_WLAN_VENDOR_PHY_MODE_11NA_HT40MINUS = 13,
7407 QCA_WLAN_VENDOR_PHY_MODE_11NA_HT40 = 14,
7408 QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT20 = 15,
7409 QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT40PLUS = 16,
7410 QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT40MINUS = 17,
7411 QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT40 = 18,
7412 QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT80 = 19,
7413 QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT80P80 = 20,
7414 QCA_WLAN_VENDOR_PHY_MODE_11AC_VHT160 = 21,
7415 QCA_WLAN_VENDOR_PHY_MODE_11AX_HE20 = 22,
7416 QCA_WLAN_VENDOR_PHY_MODE_11AX_HE40 = 23,
7417 QCA_WLAN_VENDOR_PHY_MODE_11AX_HE40PLUS = 24,
7418 QCA_WLAN_VENDOR_PHY_MODE_11AX_HE40MINUS = 25,
7419 QCA_WLAN_VENDOR_PHY_MODE_11AX_HE80 = 26,
7420 QCA_WLAN_VENDOR_PHY_MODE_11AX_HE80P80 = 27,
7421 QCA_WLAN_VENDOR_PHY_MODE_11AX_HE160 = 28,
7422};
7423
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007424/* Attributes for data used by
7425 * QCA_NL80211_VENDOR_SUBCMD_WIFI_TEST_CONFIGURATION
7426 */
7427enum qca_wlan_vendor_attr_wifi_test_config {
7428 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_INVALID = 0,
7429 /* 8-bit unsigned value to configure the driver to enable/disable
7430 * WMM feature. This attribute is used to configure testbed device.
7431 * 1-enable, 0-disable
7432 */
7433 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_WMM_ENABLE = 1,
7434
7435 /* 8-bit unsigned value to configure the driver to accept/reject
7436 * the addba request from peer. This attribute is used to configure
7437 * the testbed device.
7438 * 1-accept addba, 0-reject addba
7439 */
7440 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_ACCEPT_ADDBA_REQ = 2,
7441
7442 /* 8-bit unsigned value to configure the driver to send or not to
7443 * send the addba request to peer.
7444 * This attribute is used to configure the testbed device.
7445 * 1-send addba, 0-do not send addba
7446 */
7447 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_SEND_ADDBA_REQ = 3,
7448
7449 /* 8-bit unsigned value to indicate the HE fragmentation support.
7450 * Uses enum he_fragmentation_val values.
7451 * This attribute is used to configure the testbed device to
7452 * allow the advertised hardware capabilities to be downgraded
7453 * for testing purposes.
7454 */
7455 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_FRAGMENTATION = 4,
7456
7457 /* 8-bit unsigned value to indicate the HE MCS support.
7458 * Uses enum he_mcs_config values.
7459 * This attribute is used to configure the testbed device to
7460 * allow the advertised hardware capabilities to be downgraded
7461 * for testing purposes.
7462 */
7463 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_MCS = 5,
7464
Amarnath Hullur Subramanyamfa752712018-02-23 11:32:38 -08007465 /* 8-bit unsigned value to configure the driver to allow or not to
7466 * allow the connection with WEP/TKIP in HT/VHT/HE modes.
7467 * This attribute is used to configure the testbed device.
7468 * 1-allow WEP/TKIP in HT/VHT/HE, 0-do not allow WEP/TKIP.
7469 */
7470 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_WEP_TKIP_IN_HE = 6,
7471
7472 /* 8-bit unsigned value to configure the driver to add a
7473 * new BA session or delete the existing BA session for
7474 * given TID. ADDBA command uses the buffer size and TID
7475 * configuration if user specifies the values else default
7476 * value for buffer size is used for all TIDs if the TID
7477 * also not specified. For DEL_BA command TID value is
7478 * required to process the command.
7479 * Uses enum qca_wlan_ba_session_config values.
7480 * This attribute is used to configure the testbed device.
7481 */
7482 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_ADD_DEL_BA_SESSION = 7,
7483
Arif Hussainf89fefa2018-08-30 12:11:01 -07007484 /* 16-bit unsigned value to configure the buffer size in addba
Amarnath Hullur Subramanyamfa752712018-02-23 11:32:38 -08007485 * request and response frames.
7486 * This attribute is used to configure the testbed device.
Arif Hussainf89fefa2018-08-30 12:11:01 -07007487 * The range of the value is 0 to 256.
Amarnath Hullur Subramanyamfa752712018-02-23 11:32:38 -08007488 */
7489 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_ADDBA_BUFF_SIZE = 8,
7490
7491 /* 8-bit unsigned value to configure the buffer size in addba
7492 * request and response frames.
7493 * This attribute is used to configure the testbed device.
7494 */
7495 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_BA_TID = 9,
7496
7497 /* 8-bit unsigned value to configure the no ack policy.
7498 * To configure no ack policy, access category value is
7499 * required to process the command.
7500 * This attribute is used to configure the testbed device.
7501 * 1 - enable no ack, 0 - disable no ack.
7502 */
7503 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_ENABLE_NO_ACK = 10,
7504
7505 /* 8-bit unsigned value to configure the AC for no ack policy
7506 * This attribute is used to configure the testbed device.
7507 * Uses the enum qca_wlan_ac_type values.
7508 */
7509 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_NO_ACK_AC = 11,
7510
Arif Hussaine2645c62018-05-24 20:39:04 -07007511 /* 8-bit unsigned value to configure the HE LTF
7512 * This attribute is used to configure the testbed device.
7513 * Uses the enum qca_wlan_he_ltf_cfg values.
7514 */
7515 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_LTF = 12,
7516
7517 /* 8-bit unsigned value to configure the tx beamformee.
7518 * This attribute is used to configure the testbed device.
7519 * 1-enable, 0-disable.
7520 */
7521 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_ENABLE_TX_BEAMFORMEE = 13,
7522
Arif Hussaine7ae5f62018-08-08 17:28:07 -07007523 /* 8-bit unsigned value to configure the tx beamformee number
7524 * of space-time streams.
7525 * This attribute is used to configure the testbed device.
7526 * The range of the value is 0 to 8.
7527 */
7528 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_TX_BEAMFORMEE_NSTS = 14,
7529
7530 /* 8-bit unsigned value to configure the MU EDCA params for given AC
7531 * This attribute is used to configure the testbed device.
7532 * Uses the enum qca_wlan_ac_type values.
7533 */
7534 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_MU_EDCA_AC = 15,
7535
7536 /* 8-bit unsigned value to configure the MU EDCA AIFSN for given AC
7537 * To configure MU EDCA AIFSN value, MU EDCA access category value
7538 * is required to process the command.
7539 * This attribute is used to configure the testbed device.
7540 */
7541 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_MU_EDCA_AIFSN = 16,
7542
7543 /* 8-bit unsigned value to configure the MU EDCA ECW min value for
7544 * given AC.
7545 * To configure MU EDCA ECW min value, MU EDCA access category value
7546 * is required to process the command.
7547 * This attribute is used to configure the testbed device.
7548 */
7549 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_MU_EDCA_ECWMIN = 17,
7550
7551 /* 8-bit unsigned value to configure the MU EDCA ECW max value for
7552 * given AC.
7553 * To configure MU EDCA ECW max value, MU EDCA access category value
7554 * is required to process the command.
7555 * This attribute is used to configure the testbed device.
7556 */
7557 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_MU_EDCA_ECWMAX = 18,
7558
7559 /* 8-bit unsigned value to configure the MU EDCA timer for given AC
7560 * To configure MU EDCA timer value, MU EDCA access category value
7561 * is required to process the command.
7562 * This attribute is used to configure the testbed device.
7563 */
7564 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_MU_EDCA_TIMER = 19,
7565
7566 /* 8-bit unsigned value to configure the HE trigger frame MAC padding
7567 * duration.
7568 * This attribute is used to configure the testbed device.
7569 * Uses the enum qca_wlan_he_mac_padding_dur values.
7570 */
7571 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_MAC_PADDING_DUR = 20,
7572
7573 /* 8-bit unsigned value to override the MU EDCA params to defaults
7574 * regardless of the AP beacon MU EDCA params. If it is enabled use
7575 * the default values else use the MU EDCA params from AP beacon.
7576 * This attribute is used to configure the testbed device.
7577 * 1-enable, 0-disable.
7578 */
7579 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_OVERRIDE_MU_EDCA = 21,
7580
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07007581 /* 8-bit unsigned value to configure the support for receiving
7582 * an MPDU that contains an operating mode control subfield.
7583 * This attribute is used to configure the testbed device.
7584 * 1-enable, 0-disable.
7585 */
7586 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_OM_CTRL_SUPP = 22,
7587
7588 /* Nested attribute values required to setup the TWT session.
7589 * enum qca_wlan_vendor_attr_twt_setup provides the necessary
7590 * information to set up the session. It contains broadcast flags,
7591 * set_up flags, trigger value, flow type, flow ID, wake interval
7592 * exponent, protection, target wake time, wake duration, wake interval
7593 * mantissa. These nested attributes are used to setup a host triggered
7594 * TWT session.
7595 */
7596 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_TWT_SETUP = 23,
7597
7598 /* This nested attribute is used to terminate the current TWT session.
7599 * It does not currently carry any attributes.
7600 */
7601 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_TWT_TERMINATE = 24,
7602
7603 /* This nested attribute is used to suspend the current TWT session.
7604 * It does not currently carry any attributes.
7605 */
7606 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_TWT_SUSPEND = 25,
7607
7608 /* Nested attribute values to indicate the request for resume.
7609 * This attribute is used to resume the TWT session.
7610 * enum qca_wlan_vendor_attr_twt_resume provides the necessary
7611 * parameters required to resume the TWT session.
7612 */
7613 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_TWT_RESUME = 26,
7614
7615 /* 8-bit unsigned value to set the HE operating mode control
7616 * (OM CTRL) Channel Width subfield.
7617 * The Channel Width subfield indicates the operating channel width
7618 * supported by the STA for both reception and transmission.
7619 * Uses the enum qca_wlan_he_om_ctrl_ch_bw values.
7620 * This setting is cleared with the
7621 * QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_CLEAR_HE_OM_CTRL_CONFIG
7622 * flag attribute to reset defaults.
7623 * This attribute is used to configure the testbed device.
7624 */
7625 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_OM_CTRL_BW = 27,
7626
7627 /* 8-bit unsigned value to configure the number of spatial
7628 * streams in HE operating mode control field.
7629 * This setting is cleared with the
7630 * QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_CLEAR_HE_OM_CTRL_CONFIG
7631 * flag attribute to reset defaults.
7632 * This attribute is used to configure the testbed device.
7633 */
7634 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_OM_CTRL_NSS = 28,
7635
7636 /* Flag attribute to configure the UL MU disable bit in
7637 * HE operating mode control field.
7638 * This setting is cleared with the
7639 * QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_CLEAR_HE_OM_CTRL_CONFIG
7640 * flag attribute to reset defaults.
7641 * This attribute is used to configure the testbed device.
7642 */
7643 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_OM_CTRL_UL_MU_DISABLE = 29,
7644
7645 /* Flag attribute to clear the previously set HE operating mode
7646 * control field configuration.
7647 * This attribute is used to configure the testbed device to reset
7648 * defaults to clear any previously set HE operating mode control
7649 * field configuration.
7650 */
7651 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_CLEAR_HE_OM_CTRL_CONFIG = 30,
7652
7653 /* 8-bit unsigned value to configure HE single user PPDU
7654 * transmission. By default this setting is disabled and it
7655 * is disabled in the reset defaults of the device configuration.
7656 * This attribute is used to configure the testbed device.
7657 * 1-enable, 0-disable
7658 */
7659 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_TX_SUPPDU = 31,
7660
7661 /* 8-bit unsigned value to configure action frame transmission
7662 * in HE trigger based PPDU transmission.
7663 * By default this setting is disabled and it is disabled in
7664 * the reset defaults of the device configuration.
7665 * This attribute is used to configure the testbed device.
7666 * 1-enable, 0-disable
7667 */
7668 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_ACTION_TX_TB_PPDU = 32,
7669
Kiran Kumar Lokere2efd7682018-12-18 18:17:45 -08007670 /* Nested attribute to indicate HE operating mode control field
7671 * transmission. It contains operating mode control field Nss,
7672 * channel bandwidth, Tx Nsts and UL MU disable attributes.
7673 * These nested attributes are used to send HE operating mode control
7674 * with configured values.
7675 * Uses the enum qca_wlan_vendor_attr_he_omi_tx attributes.
7676 * This attribute is used to configure the testbed device.
7677 */
7678 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_OMI_TX = 33,
7679
7680 /* 8-bit unsigned value to configure +HTC_HE support to indicate the
7681 * support for the reception of a frame that carries an HE variant
7682 * HT Control field.
7683 * This attribute is used to configure the testbed device.
7684 * 1-enable, 0-disable
7685 */
7686 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_HTC_HE_SUPP = 34,
7687
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08007688 /* 8-bit unsigned value to configure VHT support in 2.4G band.
7689 * This attribute is used to configure the testbed device.
7690 * 1-enable, 0-disable
7691 */
7692 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_ENABLE_2G_VHT = 35,
7693
7694 /* 8-bit unsigned value to configure HE testbed defaults.
7695 * This attribute is used to configure the testbed device.
7696 * 1-set the device HE capabilities to testbed defaults.
7697 * 0-reset the device HE capabilities to supported config.
7698 */
7699 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_SET_HE_TESTBED_DEFAULTS = 36,
7700
7701 /* 8-bit unsigned value to configure TWT request support.
7702 * This attribute is used to configure the testbed device.
7703 * 1-enable, 0-disable.
7704 */
7705 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_HE_TWT_REQ_SUPPORT = 37,
7706
Jouni Malinenf735abd2020-08-03 11:08:00 +03007707 /* 8-bit unsigned value to configure protection for Management
7708 * frames when PMF is enabled for the association.
7709 * This attribute is used to configure the testbed device.
7710 * 0-use the correct key, 1-use an incorrect key, 2-disable protection.
7711 */
7712 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_PMF_PROTECTION = 38,
7713
7714 /* Flag attribute to inject Disassociation frame to the connected AP.
7715 * This attribute is used to configure the testbed device.
7716 */
7717 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_DISASSOC_TX = 39,
7718
7719 /* 8-bit unsigned value to configure an override for the RSNXE Used
7720 * subfield in the MIC control field of the FTE in FT Reassociation
7721 * Request frame.
7722 * 0 - Default behavior, 1 - override with 1, 2 - override with 0.
7723 * This attribute is used to configure the testbed device.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307724 * This attribute can be configured only when STA is in associated state
7725 * and the configuration is valid until the disconnection.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007726 */
7727 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_FT_REASSOCREQ_RSNXE_USED = 40,
7728
7729 /* 8-bit unsigned value to configure the driver to ignore CSA (Channel
7730 * Switch Announcement) when STA is in connected state.
7731 * 0 - Default behavior, 1 - Ignore CSA.
7732 * This attribute is used to configure the testbed device.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307733 * This attribute can be configured only when STA is in associated state
7734 * and the configuration is valid until the disconnection.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007735 */
7736 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_IGNORE_CSA = 41,
7737
7738 /* Nested attribute values required to configure OCI (Operating Channel
7739 * Information). Attributes defined in enum
7740 * qca_wlan_vendor_attr_oci_override are nested within this attribute.
7741 * This attribute is used to configure the testbed device.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307742 * This attribute can be configured only when STA is in associated state
7743 * and the configuration is valid until the disconnection.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007744 */
7745 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_OCI_OVERRIDE = 42,
7746
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307747 /* 8-bit unsigned value to configure the driver/firmware to ignore SA
7748 * Query timeout. If this configuration is enabled STA shall not send
7749 * Deauthentication frmae when SA Query times out (mainly, after a
7750 * channel switch when OCV is enabled).
7751 * 0 - Default behavior, 1 - Ignore SA Query timeout.
7752 * This attribute is used to configure the testbed device.
7753 * This attribute can be configured only when STA is in associated state
7754 * and the configuration is valid until the disconnection.
7755 */
7756 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_IGNORE_SA_QUERY_TIMEOUT = 43,
7757
7758 /* 8-bit unsigned value to configure the driver/firmware to start or
7759 * stop transmitting FILS discovery frames.
7760 * 0 - Stop transmitting FILS discovery frames
7761 * 1 - Start transmitting FILS discovery frames
7762 * This attribute is used to configure the testbed device.
7763 * This attribute can be configured only in AP mode and the
7764 * configuration is valid until AP restart.
7765 */
7766 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_FILS_DISCOVERY_FRAMES_TX = 44,
7767
Srinivas Girigowda7673be32020-11-12 12:37:14 -08007768 /* 8-bit unsigned value to configure the driver/firmware to enable or
7769 * disable full bandwidth UL MU-MIMO subfield in the HE PHY capabilities
7770 * information field.
7771 * 0 - Disable full bandwidth UL MU-MIMO subfield
7772 * 1 - Enable full bandwidth UL MU-MIMO subfield
7773 * This attribute is used to configure the testbed device.
7774 */
7775 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_FULL_BW_UL_MU_MIMO = 45,
7776
Amarnath Hullur Subramanyam19558522018-02-02 10:52:26 -08007777 /* keep last */
7778 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_AFTER_LAST,
7779 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_MAX =
7780 QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_AFTER_LAST - 1,
7781};
7782
Arif Hussaine2645c62018-05-24 20:39:04 -07007783/**
Jouni Malinenf735abd2020-08-03 11:08:00 +03007784 * enum qca_wlan_twt_operation - Operation of the config TWT request
7785 * Values for %QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_OPERATION.
7786 *
7787 * @QCA_WLAN_TWT_SET: Setup a TWT session. Required parameters are configured
7788 * through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the enum
7789 * qca_wlan_vendor_attr_twt_setup.
7790 *
7791 * @QCA_WLAN_TWT_GET: Get the configured TWT parameters. Required parameters are
7792 * obtained through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the enum
7793 * qca_wlan_vendor_attr_twt_setup.
7794 *
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307795 * @QCA_WLAN_TWT_TERMINATE: Terminate the TWT session. Required parameters are
7796 * obtained through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the enum
7797 * qca_wlan_vendor_attr_twt_setup. Valid only after the TWT session is setup.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007798 *
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307799 * @QCA_WLAN_TWT_SUSPEND: Suspend the TWT session. Required parameters are
7800 * obtained through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the enum
7801 * qca_wlan_vendor_attr_twt_setup. Valid only after the TWT session is setup.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007802 *
7803 * @QCA_WLAN_TWT_RESUME: Resume the TWT session. Required parameters are
7804 * configured through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the enum
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05307805 * qca_wlan_vendor_attr_twt_resume. Valid only after the TWT session is setup.
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08007806 *
7807 * @QCA_WLAN_TWT_NUDGE: Suspend and resume the TWT session. TWT nudge is a
7808 * combination of suspend and resume in a single request. Required parameters
7809 * are configured through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS. Refers the
7810 * enum qca_wlan_vendor_attr_twt_nudge. Valid only after the TWT session is
7811 * setup.
Jouni Malinenf735abd2020-08-03 11:08:00 +03007812 */
7813enum qca_wlan_twt_operation {
7814 QCA_WLAN_TWT_SET = 0,
7815 QCA_WLAN_TWT_GET = 1,
7816 QCA_WLAN_TWT_TERMINATE = 2,
7817 QCA_WLAN_TWT_SUSPEND = 3,
7818 QCA_WLAN_TWT_RESUME = 4,
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08007819 QCA_WLAN_TWT_NUDGE = 5,
Jouni Malinenf735abd2020-08-03 11:08:00 +03007820};
7821
7822/**
7823 * enum qca_wlan_vendor_attr_config_twt: Defines attributes used by
7824 * %QCA_NL80211_VENDOR_SUBCMD_CONFIG_TWT.
7825 *
7826 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_OPERATION: u8 attribute. Specify the TWT
7827 * operation of this request. Possible values are defined in enum
7828 * qca_wlan_twt_operation. The parameters for the respective operation is
7829 * specified through QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS.
7830 *
7831 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS: Nested attribute representing the
7832 * parameters configured for TWT. These parameters are represented by
7833 * enum qca_wlan_vendor_attr_twt_setup or enum qca_wlan_vendor_attr_twt_resume
7834 * based on the operation.
7835 */
7836enum qca_wlan_vendor_attr_config_twt {
7837 QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_INVALID = 0,
7838 QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_OPERATION = 1,
7839 QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_PARAMS = 2,
7840
7841 /* keep last */
7842 QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_AFTER_LAST,
7843 QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_MAX =
7844 QCA_WLAN_VENDOR_ATTR_CONFIG_TWT_AFTER_LAST - 1,
7845};
7846
7847/**
Arif Hussaine2645c62018-05-24 20:39:04 -07007848 * enum qca_wlan_vendor_attr_bss_filter - Used by the vendor command
7849 * QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER.
7850 * The user can add/delete the filter by specifying the BSSID/STA MAC address in
7851 * QCA_WLAN_VENDOR_ATTR_BSS_FILTER_MAC_ADDR, filter type in
7852 * QCA_WLAN_VENDOR_ATTR_BSS_FILTER_TYPE, add/delete action in
7853 * QCA_WLAN_VENDOR_ATTR_BSS_FILTER_ACTION in the request. The user can get the
7854 * statistics of an unassociated station by specifying the MAC address in
7855 * QCA_WLAN_VENDOR_ATTR_BSS_FILTER_MAC_ADDR, station type in
7856 * QCA_WLAN_VENDOR_ATTR_BSS_FILTER_TYPE, GET action in
7857 * QCA_WLAN_VENDOR_ATTR_BSS_FILTER_ACTION in the request. The user also can get
7858 * the statistics of all unassociated stations by specifying the Broadcast MAC
7859 * address (ff:ff:ff:ff:ff:ff) in QCA_WLAN_VENDOR_ATTR_BSS_FILTER_MAC_ADDR with
7860 * above procedure. In the response, driver shall specify statistics
7861 * information nested in QCA_WLAN_VENDOR_ATTR_BSS_FILTER_STA_STATS.
7862 */
7863enum qca_wlan_vendor_attr_bss_filter {
7864 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_INVALID = 0,
7865 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_MAC_ADDR = 1,
7866 /* Other BSS filter type, unsigned 8 bit value. One of the values
7867 * in enum qca_wlan_vendor_bss_filter_type.
7868 */
7869 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_TYPE = 2,
7870 /* Other BSS filter action, unsigned 8 bit value. One of the values
7871 * in enum qca_wlan_vendor_bss_filter_action.
7872 */
7873 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_ACTION = 3,
7874 /* Array of nested attributes where each entry is the statistics
7875 * information of the specified station that belong to another BSS.
7876 * Attributes for each entry are taken from enum
7877 * qca_wlan_vendor_bss_filter_sta_stats.
7878 * Other BSS station configured in
7879 * QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER with filter type
7880 * QCA_WLAN_VENDOR_BSS_FILTER_TYPE_STA.
7881 * Statistics returned by QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER
7882 * with filter action QCA_WLAN_VENDOR_BSS_FILTER_ACTION_GET.
7883 */
7884 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_STA_STATS = 4,
7885
7886 /* keep last */
7887 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_AFTER_LAST,
7888 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_MAX =
7889 QCA_WLAN_VENDOR_ATTR_BSS_FILTER_AFTER_LAST - 1,
7890};
7891
7892/**
7893 * enum qca_wlan_vendor_bss_filter_type - Type of
7894 * filter used in other BSS filter operations. Used by the vendor command
7895 * QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER.
7896 *
7897 * @QCA_WLAN_VENDOR_BSS_FILTER_TYPE_BSSID: BSSID filter
7898 * @QCA_WLAN_VENDOR_BSS_FILTER_TYPE_STA: Station MAC address filter
7899 */
7900enum qca_wlan_vendor_bss_filter_type {
7901 QCA_WLAN_VENDOR_BSS_FILTER_TYPE_BSSID,
7902 QCA_WLAN_VENDOR_BSS_FILTER_TYPE_STA,
7903};
7904
7905/**
7906 * enum qca_wlan_vendor_bss_filter_action - Type of
7907 * action in other BSS filter operations. Used by the vendor command
7908 * QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER.
7909 *
7910 * @QCA_WLAN_VENDOR_BSS_FILTER_ACTION_ADD: Add filter
7911 * @QCA_WLAN_VENDOR_BSS_FILTER_ACTION_DEL: Delete filter
7912 * @QCA_WLAN_VENDOR_BSS_FILTER_ACTION_GET: Get the statistics
7913 */
7914enum qca_wlan_vendor_bss_filter_action {
7915 QCA_WLAN_VENDOR_BSS_FILTER_ACTION_ADD,
7916 QCA_WLAN_VENDOR_BSS_FILTER_ACTION_DEL,
7917 QCA_WLAN_VENDOR_BSS_FILTER_ACTION_GET,
7918};
7919
7920/**
7921 * enum qca_wlan_vendor_bss_filter_sta_stats - Attributes for
7922 * the statistics of a specific unassociated station belonging to another BSS.
7923 * The statistics provides information of the unassociated station
7924 * filtered by other BSS operation - such as MAC, signal value.
7925 * Used by the vendor command QCA_NL80211_VENDOR_SUBCMD_BSS_FILTER.
7926 *
7927 * @QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_MAC: MAC address of the station.
7928 * @QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_RSSI: Last received signal strength
7929 * of the station. Unsigned 8 bit number containing RSSI.
7930 * @QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_RSSI_TS: Time stamp of the host
7931 * driver for the last received RSSI. Unsigned 64 bit number containing
7932 * nanoseconds from the boottime.
7933 */
7934enum qca_wlan_vendor_bss_filter_sta_stats {
7935 QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_INVALID = 0,
7936 QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_MAC = 1,
7937 QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_RSSI = 2,
7938 QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_RSSI_TS = 3,
7939
7940 /* keep last */
7941 QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_AFTER_LAST,
7942 QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_MAX =
7943 QCA_WLAN_VENDOR_BSS_FILTER_STA_STATS_AFTER_LAST - 1
7944};
7945
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07007946/* enum qca_wlan_nan_subcmd_type - Type of NAN command used by attribute
7947 * QCA_WLAN_VENDOR_ATTR_NAN_SUBCMD_TYPE as a part of vendor command
7948 * QCA_NL80211_VENDOR_SUBCMD_NAN_EXT.
7949 */
7950enum qca_wlan_nan_ext_subcmd_type {
7951 /* Subcmd of type NAN Enable Request */
7952 QCA_WLAN_NAN_EXT_SUBCMD_TYPE_ENABLE_REQ = 1,
7953 /* Subcmd of type NAN Disable Request */
7954 QCA_WLAN_NAN_EXT_SUBCMD_TYPE_DISABLE_REQ = 2,
7955};
7956
7957/**
7958 * enum qca_wlan_vendor_attr_nan_params - Used by the vendor command
7959 * QCA_NL80211_VENDOR_SUBCMD_NAN_EXT.
7960 */
7961enum qca_wlan_vendor_attr_nan_params {
7962 QCA_WLAN_VENDOR_ATTR_NAN_INVALID = 0,
7963 /* Carries NAN command for firmware component. Every vendor command
7964 * QCA_NL80211_VENDOR_SUBCMD_NAN_EXT must contain this attribute with a
7965 * payload containing the NAN command. NLA_BINARY attribute.
7966 */
7967 QCA_WLAN_VENDOR_ATTR_NAN_CMD_DATA = 1,
7968 /* Indicates the type of NAN command sent with
7969 * QCA_NL80211_VENDOR_SUBCMD_NAN_EXT. enum qca_wlan_nan_ext_subcmd_type
7970 * describes the possible range of values. This attribute is mandatory
7971 * if the command being issued is either
7972 * QCA_WLAN_NAN_EXT_SUBCMD_TYPE_ENABLE_REQ or
7973 * QCA_WLAN_NAN_EXT_SUBCMD_TYPE_DISABLE_REQ. NLA_U32 attribute.
7974 */
7975 QCA_WLAN_VENDOR_ATTR_NAN_SUBCMD_TYPE = 2,
7976 /* Frequency (in MHz) of primary NAN discovery social channel in 2.4 GHz
7977 * band. This attribute is mandatory when command type is
7978 * QCA_WLAN_NAN_EXT_SUBCMD_TYPE_ENABLE_REQ. NLA_U32 attribute.
7979 */
7980 QCA_WLAN_VENDOR_ATTR_NAN_DISC_24GHZ_BAND_FREQ = 3,
7981 /* Frequency (in MHz) of secondary NAN discovery social channel in 5 GHz
7982 * band. This attribute is optional and should be included when command
7983 * type is QCA_WLAN_NAN_EXT_SUBCMD_TYPE_ENABLE_REQ and NAN discovery
7984 * has to be started on 5GHz along with 2.4GHz. NLA_U32 attribute.
7985 */
7986 QCA_WLAN_VENDOR_ATTR_NAN_DISC_5GHZ_BAND_FREQ = 4,
7987
7988 /* keep last */
7989 QCA_WLAN_VENDOR_ATTR_NAN_PARAMS_AFTER_LAST,
7990 QCA_WLAN_VENDOR_ATTR_NAN_PARAMS_MAX =
7991 QCA_WLAN_VENDOR_ATTR_NAN_PARAMS_AFTER_LAST - 1
7992};
7993
7994/**
7995 * enum qca_wlan_vendor_attr_twt_setup: Represents attributes for
7996 * TWT (Target Wake Time) setup request. These attributes are sent as part of
7997 * %QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_TWT_SETUP and
Jouni Malinenf735abd2020-08-03 11:08:00 +03007998 * %QCA_NL80211_VENDOR_SUBCMD_WIFI_TEST_CONFIGURATION. Also used by
7999 * attributes through %QCA_NL80211_VENDOR_SUBCMD_CONFIG_TWT.
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008000 *
8001 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_BCAST: Flag attribute.
8002 * Disable (flag attribute not present) - Individual TWT
8003 * Enable (flag attribute present) - Broadcast TWT.
8004 * Individual means the session is between the STA and the AP.
8005 * This session is established using a separate negotiation between
8006 * STA and AP.
8007 * Broadcast means the session is across multiple STAs and an AP. The
8008 * configuration parameters are announced in Beacon frames by the AP.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308009 * This is used in
8010 * 1. TWT SET Request and Response
8011 * 2. TWT GET Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008012 *
8013 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_REQ_TYPE: Required (u8).
8014 * Unsigned 8-bit qca_wlan_vendor_twt_setup_req_type to
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308015 * specify the TWT request type. This is used in TWT SET operation.
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008016 *
8017 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_TRIGGER: Flag attribute
8018 * Enable (flag attribute present) - TWT with trigger support.
8019 * Disable (flag attribute not present) - TWT without trigger support.
8020 * Trigger means the AP will send the trigger frame to allow STA to send data.
8021 * Without trigger, the STA will wait for the MU EDCA timer before
8022 * transmitting the data.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308023 * This is used in
8024 * 1. TWT SET Request and Response
8025 * 2. TWT GET Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008026 *
8027 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_FLOW_TYPE: Required (u8)
8028 * 0 - Announced TWT - In this mode, STA may skip few service periods to
8029 * save more power. If STA wants to wake up, it will send a PS-POLL/QoS
8030 * NULL frame to AP.
8031 * 1 - Unannounced TWT - The STA will wakeup during every SP.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308032 * This is a required parameter for
8033 * 1. TWT SET Request and Response
8034 * 2. TWT GET Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008035 *
8036 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_FLOW_ID: Optional (u8)
8037 * Flow ID is the unique identifier for each TWT session.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308038 * If not provided then dialog ID will be set to zero.
8039 * This is an optional parameter for
8040 * 1. TWT SET Request and Response
8041 * 2. TWT GET Request and Response
8042 * 3. TWT TERMINATE Request and Response
8043 * 4. TWT SUSPEND Request and Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008044 *
8045 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_INTVL_EXP: Required (u8)
8046 * This attribute (exp) is used along with the mantissa to derive the
8047 * wake interval using the following formula:
8048 * pow(2,exp) = wake_intvl_us/wake_intvl_mantis
8049 * Wake interval is the interval between 2 successive SP.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308050 * This is a required parameter for
8051 * 1. TWT SET Request and Response
8052 * 2. TWT GET Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008053 *
8054 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_PROTECTION: Flag attribute
8055 * Enable (flag attribute present) - Protection required.
8056 * Disable (flag attribute not present) - Protection not required.
8057 * If protection is enabled, then the AP will use protection
8058 * mechanism using RTS/CTS to self to reserve the airtime.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308059 * This is used in
8060 * 1. TWT SET Request and Response
8061 * 2. TWT GET Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008062 *
8063 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_TIME: Optional (u32)
8064 * This attribute is used as the SP offset which is the offset from
8065 * TSF after which the wake happens. The units are in microseconds. If
8066 * this attribute is not provided, then the value will be set to zero.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308067 * This is an optional parameter for
8068 * 1. TWT SET Request and Response
8069 * 2. TWT GET Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008070 *
8071 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_DURATION: Required (u32)
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308072 * This is the duration of the service period. This is specified as
8073 * multiples of 256 microseconds. Valid values are 0x1 to 0xFF.
8074 * This is a required parameter for
8075 * 1. TWT SET Request and Response
8076 * 2. TWT GET Response
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008077 *
8078 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_INTVL_MANTISSA: Required (u32)
8079 * This attribute is used to configure wake interval mantissa.
8080 * The units are in TU.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308081 * This is a required parameter for
8082 * 1. TWT SET Request and Response
8083 * 2. TWT GET Response
8084 *
8085 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_STATUS: Required (u8)
8086 * This field is applicable for TWT response only.
8087 * This contains status values in enum qca_wlan_vendor_twt_status
8088 * and is passed to the userspace. This is used in TWT SET operation.
8089 * This is a required parameter for
8090 * 1. TWT SET Response
8091 * 2. TWT TERMINATE Response
8092 * 3. TWT SUSPEND Response
8093 * 4. TWT RESUME Response
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08008094 * 5. TWT NUDGE Response
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308095 *
8096 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_RESP_TYPE: Required (u8)
8097 * This field is applicable for TWT response only.
8098 * This field contains response type from the TWT responder and is
8099 * passed to the userspace. The values for this field are defined in
8100 * enum qca_wlan_vendor_twt_setup_resp_type. This is used in TWT SET
8101 * response.
8102 *
8103 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_TIME_TSF: Required (u64)
8104 * This field is applicable for TWT response only.
8105 * This field contains absolute TSF value of the wake time received
8106 * from the TWT responder and is passed to the userspace.
8107 * This is a required parameter for
8108 * 1. TWT SET Response
8109 * 2. TWT GET Response
8110 *
8111 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_TWT_INFO_ENABLED: Flag attribute.
8112 * Enable (flag attribute present) - Indicates that the TWT responder
8113 * supports reception of TWT information frame from the TWT requestor.
8114 * Disable (flag attribute not present) - Indicates that the responder
8115 * doesn't support reception of TWT information frame from requestor.
8116 * This is used in
8117 * 1. TWT SET Response
8118 * 2. TWT GET Response
8119 *
8120 * @QCA_WLAN_VENDOR_ATTR_TWT_SETUP_MAC_ADDR: 6-byte MAC address
8121 * Represents the MAC address of the peer for which the TWT session
8122 * is being configured. This is used in AP mode to represent the respective
8123 * client. In AP mode, this is an optional parameter for response and is
8124 * a required parameter for
8125 * 1. TWT SET Request
8126 * 2. TWT GET Request
8127 * 3. TWT TERMINATE Request
8128 * 4. TWT SUSPEND Request
8129 * In STA mode, this is an optional parameter in request and response for
8130 * the above four TWT operations.
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008131 */
8132enum qca_wlan_vendor_attr_twt_setup {
8133 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_INVALID = 0,
8134 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_BCAST = 1,
8135 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_REQ_TYPE = 2,
8136 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_TRIGGER = 3,
8137 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_FLOW_TYPE = 4,
8138 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_FLOW_ID = 5,
8139 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_INTVL_EXP = 6,
8140 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_PROTECTION = 7,
8141 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_TIME = 8,
8142 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_DURATION = 9,
8143 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_INTVL_MANTISSA = 10,
8144
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308145 /* TWT Response only attributes */
8146 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_STATUS = 11,
8147 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_RESP_TYPE = 12,
8148 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_WAKE_TIME_TSF = 13,
8149 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_TWT_INFO_ENABLED = 14,
8150
8151 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_MAC_ADDR = 15,
8152
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008153 /* keep last */
8154 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_AFTER_LAST,
8155 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_MAX =
8156 QCA_WLAN_VENDOR_ATTR_TWT_SETUP_AFTER_LAST - 1,
8157};
8158
8159/**
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308160 * enum qca_wlan_vendor_twt_status - Represents the status of the requested
8161 * TWT operation
8162 *
8163 * @QCA_WLAN_VENDOR_TWT_STATUS_OK: TWT request successfully completed
8164 * @QCA_WLAN_VENDOR_TWT_STATUS_TWT_NOT_ENABLED: TWT not enabled
8165 * @QCA_WLAN_VENDOR_TWT_STATUS_USED_DIALOG_ID: TWT dialog ID is already used
8166 * @QCA_WLAN_VENDOR_TWT_STATUS_SESSION_BUSY: TWT session is busy
8167 * @QCA_WLAN_VENDOR_TWT_STATUS_SESSION_NOT_EXIST: TWT session does not exist
8168 * @QCA_WLAN_VENDOR_TWT_STATUS_NOT_SUSPENDED: TWT session not in suspend state
8169 * @QCA_WLAN_VENDOR_TWT_STATUS_INVALID_PARAM: Invalid parameters
8170 * @QCA_WLAN_VENDOR_TWT_STATUS_NOT_READY: FW not ready
8171 * @QCA_WLAN_VENDOR_TWT_STATUS_NO_RESOURCE: FW resource exhausted
8172 * @QCA_WLAN_VENDOR_TWT_STATUS_NO_ACK: Peer AP/STA did not ACK the
8173 * request/response frame
8174 * @QCA_WLAN_VENDOR_TWT_STATUS_NO_RESPONSE: Peer AP did not send the response
8175 * frame
8176 * @QCA_WLAN_VENDOR_TWT_STATUS_DENIED: AP did not accept the request
8177 * @QCA_WLAN_VENDOR_TWT_STATUS_UNKNOWN_ERROR: Adding TWT dialog failed due to an
8178 * unknown reason
8179 * @QCA_WLAN_VENDOR_TWT_STATUS_ALREADY_SUSPENDED: TWT session already in
8180 * suspend state
8181 */
8182enum qca_wlan_vendor_twt_status {
8183 QCA_WLAN_VENDOR_TWT_STATUS_OK = 0,
8184 QCA_WLAN_VENDOR_TWT_STATUS_TWT_NOT_ENABLED = 1,
8185 QCA_WLAN_VENDOR_TWT_STATUS_USED_DIALOG_ID = 2,
8186 QCA_WLAN_VENDOR_TWT_STATUS_SESSION_BUSY = 3,
8187 QCA_WLAN_VENDOR_TWT_STATUS_SESSION_NOT_EXIST = 4,
8188 QCA_WLAN_VENDOR_TWT_STATUS_NOT_SUSPENDED = 5,
8189 QCA_WLAN_VENDOR_TWT_STATUS_INVALID_PARAM = 6,
8190 QCA_WLAN_VENDOR_TWT_STATUS_NOT_READY = 7,
8191 QCA_WLAN_VENDOR_TWT_STATUS_NO_RESOURCE = 8,
8192 QCA_WLAN_VENDOR_TWT_STATUS_NO_ACK = 9,
8193 QCA_WLAN_VENDOR_TWT_STATUS_NO_RESPONSE = 10,
8194 QCA_WLAN_VENDOR_TWT_STATUS_DENIED = 11,
8195 QCA_WLAN_VENDOR_TWT_STATUS_UNKNOWN_ERROR = 12,
8196 QCA_WLAN_VENDOR_TWT_STATUS_ALREADY_SUSPENDED = 13,
8197};
8198
8199/**
8200 * enum qca_wlan_vendor_attr_twt_resume - Represents attributes for
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008201 * TWT (Target Wake Time) resume request. These attributes are sent as part of
8202 * %QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_TWT_RESUME and
Jouni Malinenf735abd2020-08-03 11:08:00 +03008203 * %QCA_NL80211_VENDOR_SUBCMD_WIFI_TEST_CONFIGURATION. Also used by
8204 * attributes through %QCA_NL80211_VENDOR_SUBCMD_CONFIG_TWT.
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008205 *
8206 * @QCA_WLAN_VENDOR_ATTR_TWT_RESUME_NEXT_TWT: Optional (u8)
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308207 * @QCA_WLAN_VENDOR_ATTR_TWT_RESUME_NEXT2_TWT: Optional (u32)
8208 * These attributes are used as the SP offset which is the offset from TSF after
8209 * which the wake happens. The units are in microseconds. Please note that
8210 * _NEXT_TWT is limited to u8 whereas _NEXT2_TWT takes the u32 data.
8211 * _NEXT2_TWT takes the precedence over _NEXT_TWT and thus the recommendation
8212 * is to use _NEXT2_TWT. If neither of these attributes is provided, the value
8213 * will be set to zero.
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008214 *
8215 * @QCA_WLAN_VENDOR_ATTR_TWT_RESUME_NEXT_TWT_SIZE: Required (u32)
8216 * This attribute represents the next TWT subfield size.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308217 * Value 0 represents 0 bits, 1 represents 32 bits, 2 for 48 bits,
8218 * and 4 for 64 bits.
8219 *
8220 * @QCA_WLAN_VENDOR_ATTR_TWT_RESUME_FLOW_ID: Required (u8).
8221 * Flow ID is the unique identifier for each TWT session. This attribute
8222 * represents the respective TWT session to resume.
8223 *
8224 * @QCA_WLAN_VENDOR_ATTR_TWT_RESUME_MAC_ADDR: 6-byte MAC address
8225 * Represents the MAC address of the peer to which TWT Resume is
8226 * being sent. This is used in AP mode to represent the respective
8227 * client and is a required parameter. In STA mode, this is an optional
8228 * parameter
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008229 */
8230enum qca_wlan_vendor_attr_twt_resume {
8231 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_INVALID = 0,
8232 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_NEXT_TWT = 1,
8233 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_NEXT_TWT_SIZE = 2,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308234 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_FLOW_ID = 3,
8235 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_NEXT2_TWT = 4,
8236 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_MAC_ADDR = 5,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008237
8238 /* keep last */
8239 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_AFTER_LAST,
8240 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_MAX =
8241 QCA_WLAN_VENDOR_ATTR_TWT_RESUME_AFTER_LAST - 1,
8242};
8243
8244/**
Srinivas Girigowda0cd77fa2020-11-17 17:14:21 -08008245 * enum qca_wlan_vendor_attr_twt_nudge - Represents attributes for
8246 * TWT (Target Wake Time) nudge request. TWT nudge is a combination of suspend
8247 * and resume in a single request. These attributes are sent as part of
8248 * %QCA_NL80211_VENDOR_SUBCMD_CONFIG_TWT.
8249 *
8250 * @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_FLOW_ID: Required (u8)
8251 * Flow ID is the unique identifier for each TWT session. This attribute
8252 * represents the respective TWT session to suspend and resume.
8253 *
8254 * @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_WAKE_TIME: Required (u32)
8255 * This attribute is used as the SP offset which is the offset from
8256 * TSF after which the wake happens. The units are in microseconds.
8257 *
8258 * @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_NEXT_TWT_SIZE: Required (u32)
8259 * This attribute represents the next TWT subfield size.
8260 * Value 0 represents 0 bits, 1 represents 32 bits, 2 for 48 bits,
8261 * and 4 for 64 bits.
8262 *
8263 * @QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_MAC_ADDR: 6-byte MAC address
8264 * Represents the MAC address of the peer to which TWT Suspend and Resume is
8265 * being sent. This is used in AP mode to represent the respective
8266 * client and is a required parameter. In STA mode, this is an optional
8267 * parameter.
8268 */
8269enum qca_wlan_vendor_attr_twt_nudge {
8270 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_INVALID = 0,
8271 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_FLOW_ID = 1,
8272 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_WAKE_TIME = 2,
8273 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_NEXT_TWT_SIZE = 3,
8274 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_MAC_ADDR = 4,
8275
8276 /* keep last */
8277 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_AFTER_LAST,
8278 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_MAX =
8279 QCA_WLAN_VENDOR_ATTR_TWT_NUDGE_AFTER_LAST - 1,
8280};
8281
8282/**
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05308283 * enum qca_wlan_vendor_twt_setup_resp_type - Represents the response type by
8284 * the TWT responder
8285 *
8286 * @QCA_WLAN_VENDOR_TWT_RESP_ALTERNATE: TWT responder suggests TWT
8287 * parameters that are different from TWT requesting STA suggested
8288 * or demanded TWT parameters
8289 * @QCA_WLAN_VENDOR_TWT_RESP_DICTATE: TWT responder demands TWT
8290 * parameters that are different from TWT requesting STA TWT suggested
8291 * or demanded parameters
8292 * @QCA_WLAN_VENDOR_TWT_RESP_REJECT: TWT responder rejects TWT
8293 * setup
8294 * @QCA_WLAN_VENDOR_TWT_RESP_ACCEPT: TWT responder accepts the TWT
8295 * setup.
8296 */
8297enum qca_wlan_vendor_twt_setup_resp_type {
8298 QCA_WLAN_VENDOR_TWT_RESP_ALTERNATE = 1,
8299 QCA_WLAN_VENDOR_TWT_RESP_DICTATE = 2,
8300 QCA_WLAN_VENDOR_TWT_RESP_REJECT = 3,
8301 QCA_WLAN_VENDOR_TWT_RESP_ACCEPT = 4,
8302};
8303
8304/**
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008305 * enum qca_wlan_vendor_twt_setup_req_type - Required (u8)
8306 * Represents the setup type being requested for TWT.
8307 * @QCA_WLAN_VENDOR_TWT_SETUP_REQUEST: STA is not specifying all the TWT
8308 * parameters but relying on AP to fill the parameters during the negotiation.
8309 * @QCA_WLAN_VENDOR_TWT_SETUP_SUGGEST: STA will provide all the suggested
8310 * values which the AP may accept or AP may provide alternative parameters
8311 * which the STA may accept.
8312 * @QCA_WLAN_VENDOR_TWT_SETUP_DEMAND: STA is not willing to accept any
8313 * alternate parameters than the requested ones.
8314 */
8315enum qca_wlan_vendor_twt_setup_req_type {
8316 QCA_WLAN_VENDOR_TWT_SETUP_REQUEST = 1,
8317 QCA_WLAN_VENDOR_TWT_SETUP_SUGGEST = 2,
8318 QCA_WLAN_VENDOR_TWT_SETUP_DEMAND = 3,
8319};
8320
8321/**
8322 * enum qca_wlan_roam_scan_event_type - Type of roam scan event
8323 *
8324 * Indicates the type of roam scan event sent by firmware/driver.
8325 *
8326 * @QCA_WLAN_ROAM_SCAN_TRIGGER_EVENT: Roam scan trigger event type.
8327 * @QCA_WLAN_ROAM_SCAN_STOP_EVENT: Roam scan stopped event type.
8328 */
8329enum qca_wlan_roam_scan_event_type {
8330 QCA_WLAN_ROAM_SCAN_TRIGGER_EVENT = 0,
8331 QCA_WLAN_ROAM_SCAN_STOP_EVENT = 1,
8332};
8333
8334/**
8335 * enum qca_wlan_roam_scan_trigger_reason - Roam scan trigger reason
8336 *
8337 * Indicates the reason for triggering roam scan by firmware/driver.
8338 *
8339 * @QCA_WLAN_ROAM_SCAN_TRIGGER_REASON_LOW_RSSI: Due to low RSSI of current AP.
8340 * @QCA_WLAN_ROAM_SCAN_TRIGGER_REASON_HIGH_PER: Due to high packet error rate.
8341 */
8342enum qca_wlan_roam_scan_trigger_reason {
8343 QCA_WLAN_ROAM_SCAN_TRIGGER_REASON_LOW_RSSI = 0,
8344 QCA_WLAN_ROAM_SCAN_TRIGGER_REASON_HIGH_PER = 1,
8345};
8346
8347/**
8348 * enum qca_wlan_vendor_attr_roam_scan - Vendor subcmd attributes to report
8349 * roam scan related details from driver/firmware to user space. enum values
8350 * are used for NL attributes sent with
8351 * %QCA_NL80211_VENDOR_SUBCMD_ROAM_SCAN_EVENT sub command.
8352 */
8353enum qca_wlan_vendor_attr_roam_scan {
8354 QCA_WLAN_VENDOR_ATTR_ROAM_SCAN_INVALID = 0,
8355 /* Encapsulates type of roam scan event being reported. enum
8356 * qca_wlan_roam_scan_event_type describes the possible range of
8357 * values. u32 attribute.
8358 */
8359 QCA_WLAN_VENDOR_ATTR_ROAM_SCAN_EVENT_TYPE = 1,
8360 /* Encapsulates reason for triggering roam scan. enum
8361 * qca_wlan_roam_scan_trigger_reason describes the possible range of
8362 * values. u32 attribute.
8363 */
8364 QCA_WLAN_VENDOR_ATTR_ROAM_SCAN_TRIGGER_REASON = 2,
8365
8366 /* keep last */
8367 QCA_WLAN_VENDOR_ATTR_ROAM_SCAN_AFTER_LAST,
8368 QCA_WLAN_VENDOR_ATTR_ROAM_SCAN_MAX =
8369 QCA_WLAN_VENDOR_ATTR_ROAM_SCAN_AFTER_LAST - 1,
8370};
8371
8372/**
8373 * enum qca_wlan_vendor_cfr_method - QCA vendor CFR methods used by
8374 * attribute QCA_WLAN_VENDOR_ATTR_PEER_CFR_METHOD as part of vendor
8375 * command QCA_NL80211_VENDOR_SUBCMD_PEER_CFR_CAPTURE_CFG.
Jouni Malinenf735abd2020-08-03 11:08:00 +03008376 * @QCA_WLAN_VENDOR_CFR_METHOD_QOS_NULL: CFR method using QoS Null frame
8377 * @QCA_WLAN_VENDOR_CFR_QOS_NULL_WITH_PHASE: CFR method using QoS Null frame
8378 * with phase
8379 * @QCA_WLAN_VENDOR_CFR_PROBE_RESPONSE: CFR method using Probe Response frame
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008380 */
8381enum qca_wlan_vendor_cfr_method {
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008382 QCA_WLAN_VENDOR_CFR_METHOD_QOS_NULL = 0,
Jouni Malinenf735abd2020-08-03 11:08:00 +03008383 QCA_WLAN_VENDOR_CFR_QOS_NULL_WITH_PHASE = 1,
8384 QCA_WLAN_VENDOR_CFR_PROBE_RESPONSE = 2,
8385};
8386
8387/**
8388 * enum qca_wlan_vendor_cfr_capture_type - QCA vendor CFR capture type used by
8389 * attribute QCA_WLAN_VENDOR_ATTR_PEER_CFR_CAPTURE_TYPE.
8390 * @QCA_WLAN_VENDOR_CFR_DIRECT_FTM: Filter directed FTM ACK frames.
8391 * @QCA_WLAN_VENDOR_CFR_ALL_FTM_ACK: Filter all FTM ACK frames.
8392 * @QCA_WLAN_VENDOR_CFR_DIRECT_NDPA_NDP: Filter NDPA NDP directed frames.
8393 * @QCA_WLAN_VENDOR_CFR_TA_RA: Filter frames based on TA/RA/Subtype which
8394 * is provided by one or more of below attributes:
8395 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA
8396 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA
8397 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA_MASK
8398 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA_MASK
8399 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_MGMT_FILTER
8400 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_CTRL_FILTER
8401 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_DATA_FILTER
8402 * @QCA_WLAN_CFR_ALL_PACKET: Filter all packets.
8403 * @QCA_WLAN_VENDOR_CFR_NDPA_NDP_ALL: Filter all NDPA NDP frames.
8404 */
8405enum qca_wlan_vendor_cfr_capture_type {
8406 QCA_WLAN_VENDOR_CFR_DIRECT_FTM = 0,
8407 QCA_WLAN_VENDOR_CFR_ALL_FTM_ACK = 1,
8408 QCA_WLAN_VENDOR_CFR_DIRECT_NDPA_NDP = 2,
8409 QCA_WLAN_VENDOR_CFR_TA_RA = 3,
8410 QCA_WLAN_VENDOR_CFR_ALL_PACKET = 4,
8411 QCA_WLAN_VENDOR_CFR_NDPA_NDP_ALL = 5,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008412};
8413
8414/**
8415 * enum qca_wlan_vendor_peer_cfr_capture_attr - Used by the vendor command
8416 * QCA_NL80211_VENDOR_SUBCMD_PEER_CFR_CAPTURE_CFG to configure peer
8417 * Channel Frequency Response capture parameters and enable periodic CFR
8418 * capture.
Jouni Malinenf735abd2020-08-03 11:08:00 +03008419 *
8420 * @QCA_WLAN_VENDOR_ATTR_CFR_PEER_MAC_ADDR: Optional (6-byte MAC address)
8421 * MAC address of peer. This is for CFR version 1 only.
8422 *
8423 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_ENABLE: Required (flag)
8424 * Enable peer CFR capture. This attribute is mandatory to enable peer CFR
8425 * capture. If this attribute is not present, peer CFR capture is disabled.
8426 *
8427 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_BANDWIDTH: Optional (u8)
8428 * BW of measurement, attribute uses the values in enum nl80211_chan_width
8429 * Supported values: 20, 40, 80, 80+80, 160.
8430 * Note that all targets may not support all bandwidths.
8431 * This attribute is mandatory for version 1 if attribute
8432 * QCA_WLAN_VENDOR_ATTR_PEER_CFR_ENABLE is used.
8433 *
8434 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_PERIODICITY: Optional (u32)
8435 * Periodicity of CFR measurement in milliseconds.
8436 * Periodicity should be a multiple of Base timer.
8437 * Current Base timer value supported is 10 milliseconds (default).
8438 * 0 for one shot capture.
8439 * This attribute is mandatory for version 1 if attribute
8440 * QCA_WLAN_VENDOR_ATTR_PEER_CFR_ENABLE is used.
8441 *
8442 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_METHOD: Optional (u8)
8443 * Method used to capture Channel Frequency Response.
8444 * Attribute uses the values defined in enum qca_wlan_vendor_cfr_method.
8445 * This attribute is mandatory for version 1 if attribute
8446 * QCA_WLAN_VENDOR_ATTR_PEER_CFR_ENABLE is used.
8447 *
8448 * @QCA_WLAN_VENDOR_ATTR_PERIODIC_CFR_CAPTURE_ENABLE: Optional (flag)
8449 * Enable periodic CFR capture.
8450 * This attribute is mandatory for version 1 to enable Periodic CFR capture.
8451 * If this attribute is not present, periodic CFR capture is disabled.
8452 *
8453 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_VERSION: Optional (u8)
8454 * Value is 1 or 2 since there are two versions of CFR capture. Two versions
8455 * can't be enabled at same time. This attribute is mandatory if target
8456 * support both versions and use one of them.
8457 *
8458 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_ENABLE_GROUP_BITMAP: Optional (u32)
8459 * This attribute is mandatory for version 2 if
8460 * QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_ENTRY is used.
8461 * Bits 15:0 bitfield indicates which group is to be enabled.
8462 * Bits 31:16 Reserved for future use.
8463 *
8464 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_DURATION: Optional (u32)
8465 * CFR capture duration in microsecond. This attribute is mandatory for
8466 * version 2 if attribute QCA_WLAN_VENDOR_ATTR_PEER_CFR_INTERVAL is used.
8467 *
8468 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_INTERVAL: Optional (u32)
8469 * CFR capture interval in microsecond. This attribute is mandatory for
8470 * version 2 if attribute QCA_WLAN_VENDOR_ATTR_PEER_CFR_DURATION is used.
8471 *
8472 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_CAPTURE_TYPE: Optional (u32)
8473 * CFR capture type is defined in enum qca_wlan_vendor_cfr_capture_type.
8474 * This attribute is mandatory for version 2.
8475 *
8476 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_UL_MU_MASK: Optional (u64)
8477 * Bitfield indicating which user in the current UL MU transmissions are
8478 * enabled for CFR capture. Bits 36 to 0 indicate user indexes for 37 users in
8479 * a UL MU transmission. If bit 0 is set, the CFR capture will happen for user
8480 * index 0 in the current UL MU transmission. If bits 0 and 2 are set, CFR
8481 * capture for UL MU TX corresponds to user indices 0 and 2. Bits 63:37 are
8482 * reserved for future use. This is for CFR version 2 only.
8483 *
8484 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_FREEZE_TLV_DELAY_COUNT: Optional (u32)
8485 * Indicates the number of consecutive RX frames to be skipped before CFR
8486 * capture is enabled again. This is for CFR version 2 only.
8487 *
8488 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TABLE: Nested attribute containing
8489 * one or more %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_ENTRY attributes.
8490 *
8491 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_ENTRY: Nested attribute containing
8492 * the following group attributes:
8493 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_NUMBER,
8494 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA,
8495 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA,
8496 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA_MASK,
8497 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA_MASK,
8498 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_NSS,
8499 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_BW,
8500 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_MGMT_FILTER,
8501 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_CTRL_FILTER,
8502 * %QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_DATA_FILTER
8503 *
8504 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_NUMBER: Optional (u32)
8505 * Target supports multiple groups for some configurations. The group number
8506 * can be any value between 0 and 15. This is for CFR version 2 only.
8507 *
8508 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA: Optional (6-byte MAC address)
8509 * Transmitter address which is used to filter frames. This MAC address takes
8510 * effect with QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA_MASK. This is for CFR
8511 * version 2 only.
8512 *
8513 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA: Optional (6-byte MAC address)
8514 * Receiver address which is used to filter frames. This MAC address takes
8515 * effect with QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA_MASK. This is for CFR
8516 * version 2 only.
8517 *
8518 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA_MASK: Optional (6-byte MAC address)
8519 * Mask of transmitter address which is used to filter frames. This is for CFR
8520 * version 2 only.
8521 *
8522 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA_MASK: Optional (6-byte MAC address)
8523 * Mask of receiver address which is used to filter frames. This is for CFR
8524 * version 2 only.
8525 *
8526 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_NSS: Optional (u32)
8527 * Indicates frames with a specific NSS will be filtered for CFR capture.
8528 * This is for CFR version 2 only. This is a bitmask. Bits 7:0 request CFR
8529 * capture to be done for frames matching the NSS specified within this bitmask.
8530 * Bits 31:8 are reserved for future use. Bits 7:0 map to NSS:
8531 * bit 0 : NSS 1
8532 * bit 1 : NSS 2
8533 * ...
8534 * bit 7 : NSS 8
8535 *
8536 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_BW: Optional (u32)
8537 * Indicates frames with a specific bandwidth will be filtered for CFR capture.
8538 * This is for CFR version 2 only. This is a bitmask. Bits 4:0 request CFR
8539 * capture to be done for frames matching the bandwidths specified within this
8540 * bitmask. Bits 31:5 are reserved for future use. Bits 4:0 map to bandwidth
8541 * numerated in enum nl80211_band (although not all bands may be supported
8542 * by a given device).
8543 *
8544 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_MGMT_FILTER: Optional (u32)
8545 * Management frames matching the subtype filter categories will be filtered in
8546 * by MAC for CFR capture. This is a bitmask in which each bit represents the
8547 * corresponding Management frame subtype value per IEEE Std 802.11-2016,
8548 * 9.2.4.1.3 Type and Subtype subfields. For example, Beacon frame control type
8549 * is 8 and its value is 1 << 8 = 0x100. This is for CFR version 2 only.
8550 *
8551 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_CTRL_FILTER: Optional (u32)
8552 * Control frames matching the subtype filter categories will be filtered in by
8553 * MAC for CFR capture. This is a bitmask in which each bit represents the
8554 * corresponding Control frame subtype value per IEEE Std 802.11-2016,
8555 * 9.2.4.1.3 Type and Subtype subfields. This is for CFR version 2 only.
8556 *
8557 * @QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_DATA_FILTER: Optional (u32)
8558 * Data frames matching the subtype filter categories will be filtered in by
8559 * MAC for CFR capture. This is a bitmask in which each bit represents the
8560 * corresponding Data frame subtype value per IEEE Std 802.11-2016,
8561 * 9.2.4.1.3 Type and Subtype subfields. This is for CFR version 2 only.
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008562 */
8563enum qca_wlan_vendor_peer_cfr_capture_attr {
8564 QCA_WLAN_VENDOR_ATTR_PEER_CFR_CAPTURE_INVALID = 0,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008565 QCA_WLAN_VENDOR_ATTR_CFR_PEER_MAC_ADDR = 1,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008566 QCA_WLAN_VENDOR_ATTR_PEER_CFR_ENABLE = 2,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008567 QCA_WLAN_VENDOR_ATTR_PEER_CFR_BANDWIDTH = 3,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008568 QCA_WLAN_VENDOR_ATTR_PEER_CFR_PERIODICITY = 4,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008569 QCA_WLAN_VENDOR_ATTR_PEER_CFR_METHOD = 5,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008570 QCA_WLAN_VENDOR_ATTR_PERIODIC_CFR_CAPTURE_ENABLE = 6,
Jouni Malinenf735abd2020-08-03 11:08:00 +03008571 QCA_WLAN_VENDOR_ATTR_PEER_CFR_VERSION = 7,
8572 QCA_WLAN_VENDOR_ATTR_PEER_CFR_ENABLE_GROUP_BITMAP = 8,
8573 QCA_WLAN_VENDOR_ATTR_PEER_CFR_DURATION = 9,
8574 QCA_WLAN_VENDOR_ATTR_PEER_CFR_INTERVAL = 10,
8575 QCA_WLAN_VENDOR_ATTR_PEER_CFR_CAPTURE_TYPE = 11,
8576 QCA_WLAN_VENDOR_ATTR_PEER_CFR_UL_MU_MASK = 12,
8577 QCA_WLAN_VENDOR_ATTR_PEER_CFR_FREEZE_TLV_DELAY_COUNT = 13,
8578 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TABLE = 14,
8579 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_ENTRY = 15,
8580 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_NUMBER = 16,
8581 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA = 17,
8582 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA = 18,
8583 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_TA_MASK = 19,
8584 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_RA_MASK = 20,
8585 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_NSS = 21,
8586 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_BW = 22,
8587 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_MGMT_FILTER = 23,
8588 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_CTRL_FILTER = 24,
8589 QCA_WLAN_VENDOR_ATTR_PEER_CFR_GROUP_DATA_FILTER = 25,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008590
8591 /* Keep last */
8592 QCA_WLAN_VENDOR_ATTR_PEER_CFR_AFTER_LAST,
8593 QCA_WLAN_VENDOR_ATTR_PEER_CFR_MAX =
8594 QCA_WLAN_VENDOR_ATTR_PEER_CFR_AFTER_LAST - 1,
8595};
8596
8597/**
8598 * enum qca_wlan_throughput_level - Current throughput level
8599 *
8600 * Indicates the current level of throughput calculated by the driver. The
8601 * driver may choose different thresholds to decide whether the throughput level
8602 * is low or medium or high based on variety of parameters like physical link
8603 * capacity of the current connection, the number of packets being dispatched
8604 * per second, etc. The throughput level events might not be consistent with the
8605 * actual current throughput value being observed.
8606 *
8607 * @QCA_WLAN_THROUGHPUT_LEVEL_LOW: Low level of throughput
8608 * @QCA_WLAN_THROUGHPUT_LEVEL_MEDIUM: Medium level of throughput
8609 * @QCA_WLAN_THROUGHPUT_LEVEL_HIGH: High level of throughput
8610 */
8611enum qca_wlan_throughput_level {
8612 QCA_WLAN_THROUGHPUT_LEVEL_LOW = 0,
8613 QCA_WLAN_THROUGHPUT_LEVEL_MEDIUM = 1,
8614 QCA_WLAN_THROUGHPUT_LEVEL_HIGH = 2,
8615};
8616
8617/**
8618 * enum qca_wlan_vendor_attr_throughput_change - Vendor subcmd attributes to
8619 * report throughput changes from the driver to user space. enum values are used
8620 * for netlink attributes sent with
8621 * %QCA_NL80211_VENDOR_SUBCMD_THROUGHPUT_CHANGE_EVENT sub command.
8622 */
8623enum qca_wlan_vendor_attr_throughput_change {
8624 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_INVALID = 0,
8625 /* Indicates the direction of throughput in which the change is being
8626 * reported. u8 attribute. Value is 0 for TX and 1 for RX.
8627 */
8628 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_DIRECTION = 1,
8629 /* Indicates the newly observed throughput level. enum
8630 * qca_wlan_throughput_level describes the possible range of values.
8631 * u8 attribute.
8632 */
8633 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_THROUGHPUT_LEVEL = 2,
8634 /* Indicates the driver's guidance on the new value to be set to
8635 * kernel's TCP parameter tcp_limit_output_bytes. u32 attribute. The
8636 * driver may optionally include this attribute.
8637 */
8638 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_TCP_LIMIT_OUTPUT_BYTES = 3,
8639 /* Indicates the driver's guidance on the new value to be set to
8640 * kernel's TCP parameter tcp_adv_win_scale. s8 attribute. Possible
8641 * values are from -31 to 31. The driver may optionally include this
8642 * attribute.
8643 */
8644 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_TCP_ADV_WIN_SCALE = 4,
8645 /* Indicates the driver's guidance on the new value to be set to
8646 * kernel's TCP parameter tcp_delack_seg. u32 attribute. The driver may
8647 * optionally include this attribute.
8648 */
8649 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_TCP_DELACK_SEG = 5,
8650
8651 /* keep last */
8652 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_AFTER_LAST,
8653 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_MAX =
8654 QCA_WLAN_VENDOR_ATTR_THROUGHPUT_CHANGE_AFTER_LAST - 1,
8655};
8656
8657/**
8658 * enum qca_coex_config_profiles - This enum defines different types of
8659 * traffic streams that can be prioritized one over the other during coex
8660 * scenarios.
8661 * The types defined in this enum are categorized in the below manner.
8662 * 0 - 31 values corresponds to WLAN
8663 * 32 - 63 values corresponds to BT
8664 * 64 - 95 values corresponds to Zigbee
8665 * @QCA_WIFI_STA_DISCOVERY: Prioritize discovery frames for WLAN STA
8666 * @QCA_WIFI_STA_CONNECTION: Prioritize connection frames for WLAN STA
8667 * @QCA_WIFI_STA_CLASS_3_MGMT: Prioritize class 3 mgmt frames for WLAN STA
8668 * @QCA_WIFI_STA_DATA : Prioritize data frames for WLAN STA
8669 * @QCA_WIFI_STA_ALL: Priritize all frames for WLAN STA
8670 * @QCA_WIFI_SAP_DISCOVERY: Prioritize discovery frames for WLAN SAP
8671 * @QCA_WIFI_SAP_CONNECTION: Prioritize connection frames for WLAN SAP
8672 * @QCA_WIFI_SAP_CLASS_3_MGMT: Prioritize class 3 mgmt frames for WLAN SAP
8673 * @QCA_WIFI_SAP_DATA: Prioritize data frames for WLAN SAP
8674 * @QCA_WIFI_SAP_ALL: Prioritize all frames for WLAN SAP
8675 * @QCA_BT_A2DP: Prioritize BT A2DP
8676 * @QCA_BT_BLE: Prioritize BT BLE
8677 * @QCA_BT_SCO: Prioritize BT SCO
8678 * @QCA_ZB_LOW: Prioritize Zigbee Low
8679 * @QCA_ZB_HIGH: Prioritize Zigbee High
8680 */
8681enum qca_coex_config_profiles {
8682 /* 0 - 31 corresponds to WLAN */
8683 QCA_WIFI_STA_DISCOVERY = 0,
8684 QCA_WIFI_STA_CONNECTION = 1,
8685 QCA_WIFI_STA_CLASS_3_MGMT = 2,
8686 QCA_WIFI_STA_DATA = 3,
8687 QCA_WIFI_STA_ALL = 4,
8688 QCA_WIFI_SAP_DISCOVERY = 5,
8689 QCA_WIFI_SAP_CONNECTION = 6,
8690 QCA_WIFI_SAP_CLASS_3_MGMT = 7,
8691 QCA_WIFI_SAP_DATA = 8,
8692 QCA_WIFI_SAP_ALL = 9,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08008693 QCA_WIFI_CASE_MAX = 31,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008694 /* 32 - 63 corresponds to BT */
8695 QCA_BT_A2DP = 32,
8696 QCA_BT_BLE = 33,
8697 QCA_BT_SCO = 34,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08008698 QCA_BT_CASE_MAX = 63,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008699 /* 64 - 95 corresponds to Zigbee */
8700 QCA_ZB_LOW = 64,
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08008701 QCA_ZB_HIGH = 65,
8702 QCA_ZB_CASE_MAX = 95,
8703 /* 0xff is default value if the u8 profile value is not set. */
8704 QCA_COEX_CONFIG_PROFILE_DEFAULT_VALUE = 255
8705};
8706
8707/**
8708 * enum qca_vendor_attr_coex_config_types - Coex configurations types.
8709 * This enum defines the valid set of values of coex configuration types. These
8710 * values may used by attribute
8711 * %QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_CONFIG_TYPE.
8712 *
8713 * @QCA_WLAN_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_COEX_RESET: Reset all the
8714 * weights to default values.
8715 * @QCA_WLAN_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_COEX_START: Start to config
8716 * weights with configurability value.
8717 */
8718enum qca_vendor_attr_coex_config_types {
8719 QCA_WLAN_VENDOR_ATTR_COEX_CONFIG_INVALID = 0,
8720 QCA_WLAN_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_COEX_RESET = 1,
8721 QCA_WLAN_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_COEX_START = 2,
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008722};
8723
8724/**
8725 * enum qca_vendor_attr_coex_config - Specifies vendor coex config attributes
8726 *
8727 * @QCA_VENDOR_ATTR_COEX_CONFIG_PROFILES: This attribute contains variable
8728 * length array of 8-bit values from enum qca_coex_config_profiles.
8729 * FW will prioritize the profiles in the order given in the array encapsulated
8730 * in this attribute.
8731 * For example:
8732 * -----------------------------------------------------------------------
8733 * | 1 | 34 | 32 | 65 |
8734 * -----------------------------------------------------------------------
8735 * If the attribute contains the values defined in above array then it means
8736 * 1) Wifi STA connection has priority over BT_SCO, BT_A2DP and ZIGBEE HIGH.
8737 * 2) BT_SCO has priority over BT_A2DP.
8738 * 3) BT_A2DP has priority over ZIGBEE HIGH.
8739 * Profiles which are not listed in this array shall not be preferred over the
8740 * profiles which are listed in the array as a part of this attribute.
8741 */
8742enum qca_vendor_attr_coex_config {
8743 QCA_VENDOR_ATTR_COEX_CONFIG_INVALID = 0,
8744 QCA_VENDOR_ATTR_COEX_CONFIG_PROFILES = 1,
8745
8746 /* Keep last */
8747 QCA_VENDOR_ATTR_COEX_CONFIG_AFTER_LAST,
8748 QCA_VENDOR_ATTR_COEX_CONFIG_MAX =
8749 QCA_VENDOR_ATTR_COEX_CONFIG_AFTER_LAST - 1,
8750};
8751
8752/**
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08008753 * enum qca_vendor_attr_coex_config_three_way - Specifies vendor coex config
8754 * attributes
8755 * Attributes for data used by QCA_NL80211_VENDOR_SUBCMD_COEX_CONFIG
8756 *
8757 * QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_CONFIG_TYPE: u32 attribute.
8758 * Indicate config type.
8759 * The config types are 32-bit values from qca_vendor_attr_coex_config_types
8760 *
8761 * @QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_1: u32 attribute.
8762 * Indicate the Priority 1 profiles.
8763 * The profiles are 8-bit values from enum qca_coex_config_profiles.
8764 * In same priority level, maximum to 4 profiles can be set here.
8765 * @QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_2: u32 attribute.
8766 * Indicate the Priority 2 profiles.
8767 * The profiles are 8-bit values from enum qca_coex_config_profiles.
8768 * In same priority level, maximum to 4 profiles can be set here.
8769 * @QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_3: u32 attribute.
8770 * Indicate the Priority 3 profiles.
8771 * The profiles are 8-bit values from enum qca_coex_config_profiles.
8772 * In same priority level, maximum to 4 profiles can be set here.
8773 * @QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_4: u32 attribute.
8774 * Indicate the Priority 4 profiles.
8775 * The profiles are 8-bit values from enum qca_coex_config_profiles.
8776 * In same priority level, maximum to 4 profiles can be set here.
8777 * NOTE:
8778 * Limitations for QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_x priority
8779 * arrangement:
8780 * 1: In the same u32 attribute (priority x), the profiles enum values own
8781 * same priority level.
8782 * 2: 0xff is default value if the u8 profile value is not set.
8783 * 3: max to 4 rules/profiles in same priority level.
8784 * 4: max to 4 priority level (priority 1 - priority 4)
8785 * 5: one priority level only supports one scenario from WLAN/BT/ZB,
8786 * hybrid rules not support.
8787 * 6: if WMI_COEX_CONFIG_THREE_WAY_COEX_RESET called, priority x will
8788 * remain blank to reset all parameters.
8789 * For example:
8790 *
8791 * If the attributes as follow:
8792 * priority 1:
8793 * ------------------------------------
8794 * | 0xff | 0 | 1 | 2 |
8795 * ------------------------------------
8796 * priority 2:
8797 * -------------------------------------
8798 * | 0xff | 0xff | 0xff | 32 |
8799 * -------------------------------------
8800 * priority 3:
8801 * -------------------------------------
8802 * | 0xff | 0xff | 0xff | 65 |
8803 * -------------------------------------
8804 * then it means:
8805 * 1: WIFI_STA_DISCOVERY, WIFI_STA_CLASS_3_MGMT and WIFI_STA_CONNECTION
8806 * owns same priority level.
8807 * 2: WIFI_STA_DISCOVERY, WIFI_STA_CLASS_3_MGMT and WIFI_STA_CONNECTION
8808 * has priority over BT_A2DP and ZB_HIGH.
8809 * 3: BT_A2DP has priority over ZB_HIGH.
8810 */
8811
8812enum qca_vendor_attr_coex_config_three_way {
8813 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_INVALID = 0,
8814 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_CONFIG_TYPE = 1,
8815 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_1 = 2,
8816 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_2 = 3,
8817 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_3 = 4,
8818 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_PRIORITY_4 = 5,
8819
8820 /* Keep last */
8821 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_AFTER_LAST,
8822 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_MAX =
8823 QCA_VENDOR_ATTR_COEX_CONFIG_THREE_WAY_AFTER_LAST - 1,
8824};
8825
8826/**
Kiran Kumar Lokeref1a47592018-08-29 15:38:33 -07008827 * enum qca_wlan_vendor_attr_link_properties - Represent the link properties.
8828 *
8829 * @QCA_WLAN_VENDOR_ATTR_LINK_PROPERTIES_MAC_ADDR: MAC address of the peer
8830 * (STA/AP) for the connected link.
8831 * @QCA_WLAN_VENDOR_ATTR_LINK_PROPERTIES_STA_FLAGS: Attribute containing a
8832 * &struct nl80211_sta_flag_update for the respective connected link. MAC
8833 * address of the peer represented by
8834 * QCA_WLAN_VENDOR_ATTR_LINK_PROPERTIES_MAC_ADDR.
8835 */
8836enum qca_wlan_vendor_attr_link_properties {
8837 QCA_WLAN_VENDOR_ATTR_LINK_PROPERTIES_INVALID = 0,
8838 /* 1 - 3 are reserved */
8839 QCA_WLAN_VENDOR_ATTR_LINK_PROPERTIES_MAC_ADDR = 4,
8840 QCA_WLAN_VENDOR_ATTR_LINK_PROPERTIES_STA_FLAGS = 5,
8841
8842 /* Keep last */
8843 QCA_VENDOR_ATTR_LINK_PROPERTIES_AFTER_LAST,
8844 QCA_VENDOR_ATTR_LINK_PROPERTIES_MAX =
8845 QCA_VENDOR_ATTR_LINK_PROPERTIES_AFTER_LAST - 1,
8846};
8847
Kiran Kumar Lokere22c7b5c2019-02-06 17:11:23 -08008848/**
8849 * enum qca_vendor_attr_peer_stats_cache_type - Represents peer stats cache type
8850 * This enum defines the valid set of values of peer stats cache types. These
8851 * values are used by attribute
8852 * %QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_TYPE.
8853 *
8854 * @QCA_WLAN_VENDOR_ATTR_PEER_TX_RATE_STATS: Represents peer TX rate statistics
8855 * @QCA_WLAN_VENDOR_ATTR_PEER_RX_RATE_STATS: Represents peer RX rate statistics
8856 * @QCA_WLAN_VENDOR_ATTR_PEER_TX_SOJOURN_STATS: Represents peer TX sojourn
8857 * statistics
8858 */
8859enum qca_vendor_attr_peer_stats_cache_type {
8860 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_TYPE_INVALID = 0,
8861
8862 QCA_WLAN_VENDOR_ATTR_PEER_TX_RATE_STATS,
8863 QCA_WLAN_VENDOR_ATTR_PEER_RX_RATE_STATS,
8864 QCA_WLAN_VENDOR_ATTR_PEER_TX_SOJOURN_STATS,
8865};
8866
8867/**
8868 * enum qca_wlan_vendor_attr_peer_stats_cache_params - This enum defines
8869 * attributes required for QCA_NL80211_VENDOR_SUBCMD_PEER_STATS_CACHE_FLUSH
8870 * Information in these attributes is used to flush peer rate statistics from
8871 * the driver to user application.
8872 *
8873 * @QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_TYPE: Unsigned 32-bit attribute
8874 * Indicate peer statistics cache type.
8875 * The statistics types are 32-bit values from
8876 * enum qca_vendor_attr_peer_stats_cache_type.
8877 * @QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_PEER_MAC: Unsigned 8-bit array
8878 * of size 6 octets, representing the peer MAC address.
8879 * @QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_DATA: Opaque data attribute
8880 * containing buffer of statistics to send to application layer entity.
8881 * @QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_PEER_COOKIE: Unsigned 64-bit attribute
8882 * representing a cookie for peer unique session.
8883 */
8884enum qca_wlan_vendor_attr_peer_stats_cache_params {
8885 QCA_WLAN_VENDOR_ATTR_PEER_STATS_INVALID = 0,
8886
8887 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_TYPE = 1,
8888 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_PEER_MAC = 2,
8889 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_DATA = 3,
8890 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_PEER_COOKIE = 4,
8891
8892 /* Keep last */
8893 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_LAST,
8894 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_MAX =
8895 QCA_WLAN_VENDOR_ATTR_PEER_STATS_CACHE_LAST - 1
8896};
8897
8898/**
8899 * enum qca_mpta_helper_attr_zigbee_state - Current Zigbee state
8900 * This enum defines all the possible states of Zigbee, which can be
8901 * delivered in the QCA_MPTA_HELPER_VENDOR_ATTR_ZIGBEE_STATE attribute.
8902 *
8903 * @ZIGBEE_IDLE: Zigbee in idle state
8904 * @ZIGBEE_FORM_NETWORK: Zigbee forming network
8905 * @ZIGBEE_WAIT_JOIN: Zigbee waiting for joining network
8906 * @ZIGBEE_JOIN: Zigbee joining network
8907 * @ZIGBEE_NETWORK_UP: Zigbee network is up
8908 * @ZIGBEE_HMI: Zigbee in HMI mode
8909 */
8910enum qca_mpta_helper_attr_zigbee_state {
8911 ZIGBEE_IDLE = 0,
8912 ZIGBEE_FORM_NETWORK = 1,
8913 ZIGBEE_WAIT_JOIN = 2,
8914 ZIGBEE_JOIN = 3,
8915 ZIGBEE_NETWORK_UP = 4,
8916 ZIGBEE_HMI = 5,
8917};
8918
8919/*
8920 * enum qca_mpta_helper_vendor_attr - Attributes used in vendor sub-command
8921 * QCA_NL80211_VENDOR_SUBCMD_MPTA_HELPER_CONFIG.
8922 */
8923enum qca_mpta_helper_vendor_attr {
8924 QCA_MPTA_HELPER_VENDOR_ATTR_INVALID = 0,
8925 /* Optional attribute used to update Zigbee state.
8926 * enum qca_mpta_helper_attr_zigbee_state.
8927 * NLA_U32 attribute.
8928 */
8929 QCA_MPTA_HELPER_VENDOR_ATTR_ZIGBEE_STATE = 1,
8930 /* Optional attribute used to configure WLAN duration for Shape-OCS
8931 * during interrupt.
8932 * Set in pair with QCA_MPTA_HELPER_VENDOR_ATTR_INT_NON_WLAN_DURATION.
8933 * Value range 0 ~ 300 (ms).
8934 * NLA_U32 attribute.
8935 */
8936 QCA_MPTA_HELPER_VENDOR_ATTR_INT_WLAN_DURATION = 2,
8937 /* Optional attribute used to configure non-WLAN duration for Shape-OCS
8938 * during interrupt.
8939 * Set in pair with QCA_MPTA_HELPER_VENDOR_ATTR_INT_WLAN_DURATION.
8940 * Value range 0 ~ 300 (ms).
8941 * NLA_U32 attribute.
8942 */
8943 QCA_MPTA_HELPER_VENDOR_ATTR_INT_NON_WLAN_DURATION = 3,
8944 /* Optional attribute used to configure WLAN duration for Shape-OCS
8945 * monitor period.
8946 * Set in pair with QCA_MPTA_HELPER_VENDOR_ATTR_MON_NON_WLAN_DURATION.
8947 * Value range 0 ~ 300 (ms)
8948 * NLA_U32 attribute
8949 */
8950 QCA_MPTA_HELPER_VENDOR_ATTR_MON_WLAN_DURATION = 4,
8951 /* Optional attribute used to configure non-WLAN duration for Shape-OCS
8952 * monitor period.
8953 * Set in pair with QCA_MPTA_HELPER_VENDOR_ATTR_MON_WLAN_DURATION.
8954 * Value range 0 ~ 300 (ms)
8955 * NLA_U32 attribute
8956 */
8957 QCA_MPTA_HELPER_VENDOR_ATTR_MON_NON_WLAN_DURATION = 5,
8958 /* Optional attribute used to configure OCS interrupt duration.
8959 * Set in pair with QCA_MPTA_HELPER_VENDOR_ATTR_MON_OCS_DURATION.
8960 * Value range 1000 ~ 20000 (ms)
8961 * NLA_U32 attribute
8962 */
8963 QCA_MPTA_HELPER_VENDOR_ATTR_INT_OCS_DURATION = 6,
8964 /* Optional attribute used to configure OCS monitor duration.
8965 * Set in pair with QCA_MPTA_HELPER_VENDOR_ATTR_INT_OCS_DURATION.
8966 * Value range 1000 ~ 20000 (ms)
8967 * NLA_U32 attribute
8968 */
8969 QCA_MPTA_HELPER_VENDOR_ATTR_MON_OCS_DURATION = 7,
8970 /* Optional attribute used to notify WLAN firmware the current Zigbee
8971 * channel.
8972 * Value range 11 ~ 26
8973 * NLA_U32 attribute
8974 */
8975 QCA_MPTA_HELPER_VENDOR_ATTR_ZIGBEE_CHAN = 8,
8976 /* Optional attribute used to configure WLAN mute duration.
8977 * Value range 0 ~ 400 (ms)
8978 * NLA_U32 attribute
8979 */
8980 QCA_MPTA_HELPER_VENDOR_ATTR_WLAN_MUTE_DURATION = 9,
8981
8982 /* keep last */
8983 QCA_MPTA_HELPER_VENDOR_ATTR_AFTER_LAST,
8984 QCA_MPTA_HELPER_VENDOR_ATTR_MAX =
8985 QCA_MPTA_HELPER_VENDOR_ATTR_AFTER_LAST - 1
8986};
8987
Jouni Malinenf735abd2020-08-03 11:08:00 +03008988/**
8989 * enum qca_wlan_vendor_beacon_reporting_op_types - Defines different types of
8990 * operations for which %QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING can be used.
8991 * Will be used by %QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE.
8992 *
8993 * @QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START: Sent by userspace to the driver
8994 * to request the driver to start reporting Beacon frames.
8995 * @QCA_WLAN_VENDOR_BEACON_REPORTING_OP_STOP: Sent by userspace to the driver to
8996 * request the driver to stop reporting Beacon frames.
8997 * @QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO: Sent by the driver to
8998 * userspace to report received Beacon frames.
8999 * @QCA_WLAN_VENDOR_BEACON_REPORTING_OP_PAUSE: Sent by the driver to userspace
9000 * to indicate that the driver is going to pause reporting Beacon frames.
9001 */
9002enum qca_wlan_vendor_beacon_reporting_op_types {
9003 QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START = 0,
9004 QCA_WLAN_VENDOR_BEACON_REPORTING_OP_STOP = 1,
9005 QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO = 2,
9006 QCA_WLAN_VENDOR_BEACON_REPORTING_OP_PAUSE = 3,
9007};
9008
9009/**
9010 * enum qca_wlan_vendor_beacon_reporting_pause_reasons - Defines different types
9011 * of reasons for which the driver is pausing reporting Beacon frames. Will be
9012 * used by %QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_PAUSE_REASON.
9013 *
9014 * @QCA_WLAN_VENDOR_BEACON_REPORTING_PAUSE_REASON_UNSPECIFIED: For unspecified
9015 * reasons.
9016 * @QCA_WLAN_VENDOR_BEACON_REPORTING_PAUSE_REASON_SCAN_STARTED: When the
9017 * driver/firmware is starting a scan.
9018 * @QCA_WLAN_VENDOR_BEACON_REPORTING_PAUSE_REASON_DISCONNECTED: When the
9019 * driver/firmware disconnects from the ESS and indicates the disconnection to
9020 * userspace (non-seamless roaming case). This reason code will be used by the
9021 * driver/firmware to indicate stopping of beacon report events. Userspace will
9022 * need to start beacon reporting again (if desired) by sending vendor command
9023 * QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING with
9024 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE set to
9025 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START after the next connection is
9026 * completed.
9027 */
9028enum qca_wlan_vendor_beacon_reporting_pause_reasons {
9029 QCA_WLAN_VENDOR_BEACON_REPORTING_PAUSE_REASON_UNSPECIFIED = 0,
9030 QCA_WLAN_VENDOR_BEACON_REPORTING_PAUSE_REASON_SCAN_STARTED = 1,
9031 QCA_WLAN_VENDOR_BEACON_REPORTING_PAUSE_REASON_DISCONNECTED = 2,
9032};
9033
9034/*
9035 * enum qca_wlan_vendor_attr_beacon_reporting_params - List of attributes used
9036 * in vendor sub-command QCA_NL80211_VENDOR_SUBCMD_BEACON_REPORTING.
9037 */
9038enum qca_wlan_vendor_attr_beacon_reporting_params {
9039 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_INVALID = 0,
9040 /* Specifies the type of operation that the vendor command/event is
9041 * intended for. Possible values for this attribute are defined in
9042 * enum qca_wlan_vendor_beacon_reporting_op_types. u32 attribute.
9043 */
9044 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE = 1,
9045 /* Optionally set by userspace to request the driver to report Beacon
9046 * frames using asynchronous vendor events when the
9047 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9048 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START. NLA_FLAG attribute.
9049 * If this flag is not set, the driver will only update Beacon frames in
9050 * cfg80211 scan cache but not send any vendor events.
9051 */
9052 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_ACTIVE_REPORTING = 2,
9053 /* Optionally used by userspace to request the driver/firmware to report
9054 * Beacon frames periodically when the
9055 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9056 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START.
9057 * u32 attribute, indicates the period of Beacon frames to be reported
9058 * and in the units of beacon interval.
9059 * If this attribute is missing in the command, then the default value
9060 * of 1 will be assumed by driver, i.e., to report every Beacon frame.
9061 * Zero is an invalid value.
9062 * If a valid value is received for this attribute, the driver will
9063 * update the cfg80211 scan cache periodically as per the value received
9064 * in this attribute in addition to updating the cfg80211 scan cache
9065 * when there is significant change in Beacon frame IEs.
9066 */
9067 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_PERIOD = 3,
9068 /* Used by the driver to encapsulate the SSID when the
9069 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9070 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO.
9071 * u8 array with a maximum size of 32.
9072 *
9073 * When generating beacon report from non-MBSSID Beacon frame, the SSID
9074 * will be taken from the SSID element of the received Beacon frame.
9075 *
9076 * When generating beacon report from Multiple BSSID Beacon frame and if
9077 * the BSSID of the current connected BSS matches the BSSID of the
9078 * transmitting BSS, the SSID will be taken from the SSID element of the
9079 * received Beacon frame.
9080 *
9081 * When generating beacon report from Multiple BSSID Beacon frame and if
9082 * the BSSID of the current connected BSS matches the BSSID of one of
9083 * the* nontransmitting BSSs, the SSID will be taken from the SSID field
9084 * included in the nontransmitted BSS profile whose derived BSSID is
9085 * same as the BSSID of the current connected BSS. When there is no
9086 * nontransmitted BSS profile whose derived BSSID is same as the BSSID
9087 * of current connected* BSS, this attribute will not be present.
9088 */
9089 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_SSID = 4,
9090 /* Used by the driver to encapsulate the BSSID of the AP to which STA is
9091 * currently connected to when the
9092 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9093 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO. u8 array with a
9094 * fixed size of 6 bytes.
9095 *
9096 * When generating beacon report from a Multiple BSSID beacon and the
9097 * current connected BSSID matches one of the nontransmitted BSSIDs in a
9098 * Multiple BSSID set, this BSSID will be that particular nontransmitted
9099 * BSSID and not the transmitted BSSID (i.e., the transmitting address
9100 * of the Beacon frame).
9101 */
9102 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_BSSID = 5,
9103 /* Used by the driver to encapsulate the frequency in MHz on which
9104 * the Beacon frame was received when the
9105 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is
9106 * set to QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO.
9107 * u32 attribute.
9108 */
9109 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_FREQ = 6,
9110 /* Used by the driver to encapsulate the Beacon interval
9111 * when the QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9112 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO.
9113 * u16 attribute. The value will be copied from the Beacon frame and the
9114 * units are TUs.
9115 */
9116 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_BI = 7,
9117 /* Used by the driver to encapsulate the Timestamp field from the Beacon
9118 * frame when the QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set
9119 * to QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO.
9120 * u64 attribute.
9121 */
9122 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_TSF = 8,
9123 /* Used by the driver to encapsulate the CLOCK_BOOTTIME when this
9124 * Beacon frame is received in the driver when the
9125 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9126 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO. u64 attribute, in
9127 * the units of nanoseconds. This value is expected to have accuracy of
9128 * about 10 ms.
9129 */
9130 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_BOOTTIME_WHEN_RECEIVED = 9,
9131 /* Used by the driver to encapsulate the IEs of the Beacon frame from
9132 * which this event is generated when the
9133 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9134 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_BEACON_INFO. u8 array.
9135 */
9136 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_IES = 10,
9137 /* Used by the driver to specify the reason for the driver/firmware to
9138 * pause sending beacons to userspace when the
9139 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9140 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_PAUSE. Possible values are
9141 * defined in enum qca_wlan_vendor_beacon_reporting_pause_reasons, u32
9142 * attribute.
9143 */
9144 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_PAUSE_REASON = 11,
9145 /* Used by the driver to specify whether the driver will automatically
9146 * resume reporting beacon events to userspace later (for example after
9147 * the ongoing off-channel activity is completed etc.) when the
9148 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9149 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_PAUSE. NLA_FLAG attribute.
9150 */
9151 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_AUTO_RESUMES = 12,
9152 /* Optionally set by userspace to request the driver not to resume
9153 * beacon reporting after a pause is completed, when the
9154 * QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_OP_TYPE is set to
9155 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START. NLA_FLAG attribute.
9156 * If this flag is set, the driver will not resume beacon reporting
9157 * after any pause in beacon reporting is completed. Userspace has to
9158 * send QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START command again in order
9159 * to initiate beacon reporting again. If this flag is set in the recent
9160 * QCA_WLAN_VENDOR_BEACON_REPORTING_OP_START command, then in the
9161 * subsequent QCA_WLAN_VENDOR_BEACON_REPORTING_OP_PAUSE event (if any)
9162 * the QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_AUTO_RESUMES shall not be
9163 * set by the driver. Setting this flag until and unless there is a
9164 * specific need is not recommended as there is a chance of some beacons
9165 * received after pause command and next start command being not
9166 * reported.
9167 */
9168 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_DO_NOT_RESUME = 13,
9169
9170 /* Keep last */
9171 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_LAST,
9172 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_MAX =
9173 QCA_WLAN_VENDOR_ATTR_BEACON_REPORTING_LAST - 1
9174};
9175
9176/**
9177 * enum qca_vendor_interop_issues_ap_type - Interop issue types
9178 * This enum defines the valid set of values of interop issue types. These
9179 * values are used by attribute %QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_TYPE.
9180 *
9181 * @QCA_VENDOR_INTEROP_ISSUES_AP_ON_STA_PS: The AP has power save interop issue
9182 * when the STA's Qpower feature is enabled.
9183 */
9184enum qca_vendor_interop_issues_ap_type {
9185 QCA_VENDOR_INTEROP_ISSUES_AP_INVALID = 0,
9186 QCA_VENDOR_INTEROP_ISSUES_AP_ON_STA_PS = 1,
9187};
9188
9189/**
9190 * enum qca_vendor_attr_interop_issues_ap - attribute for AP with interop issues
9191 * Values are used by %QCA_NL80211_VENDOR_SUBCMD_INTEROP_ISSUES_AP.
9192 *
9193 * @QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_INVALID: Invalid value
9194 * @QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_TYPE: Interop issue type
9195 * 32-bit unsigned value. The values defined in enum
9196 * qca_vendor_interop_issues_ap_type are used.
9197 * @QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_LIST: APs' BSSID container
9198 * array of nested QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_BSSID attributes.
9199 * It is present and mandatory for the command but is not used for the event
9200 * since only a single BSSID is reported in an event.
9201 * @QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_BSSID: AP's BSSID 6-byte MAC address.
9202 * It is used within the nested QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_LIST
9203 * attribute in command case and without such encapsulation in the event case.
9204 * @QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_AFTER_LAST: last value
9205 * @QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_MAX: max value
9206 */
9207enum qca_vendor_attr_interop_issues_ap {
9208 QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_INVALID,
9209 QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_TYPE,
9210 QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_LIST,
9211 QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_BSSID,
9212 /* keep last */
9213 QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_AFTER_LAST,
9214 QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_MAX =
9215 QCA_WLAN_VENDOR_ATTR_INTEROP_ISSUES_AP_AFTER_LAST - 1
9216};
9217
9218/**
9219 * enum qca_vendor_oem_device_type - Represents the target device in firmware.
9220 * It is used by QCA_WLAN_VENDOR_ATTR_OEM_DEVICE_INFO.
9221 *
9222 * @QCA_VENDOR_OEM_DEVICE_VIRTUAL: The command is intended for
9223 * a virtual device.
9224 *
9225 * @QCA_VENDOR_OEM_DEVICE_PHYSICAL: The command is intended for
9226 * a physical device.
9227 */
9228enum qca_vendor_oem_device_type {
9229 QCA_VENDOR_OEM_DEVICE_VIRTUAL = 0,
9230 QCA_VENDOR_OEM_DEVICE_PHYSICAL = 1,
9231};
9232
9233/**
9234 * enum qca_wlan_vendor_attr_oem_data_params - Used by the vendor command/event
9235 * QCA_NL80211_VENDOR_SUBCMD_OEM_DATA.
9236 *
9237 * @QCA_WLAN_VENDOR_ATTR_OEM_DATA_CMD_DATA: This NLA_BINARY attribute is
9238 * used to set/query the data to/from the firmware. On query, the same
9239 * attribute is used to carry the respective data in the reply sent by the
9240 * driver to userspace. The request to set/query the data and the format of the
9241 * respective data from the firmware are embedded in the attribute. The
9242 * maximum size of the attribute payload is 1024 bytes.
9243 * Userspace has to set the QCA_WLAN_VENDOR_ATTR_OEM_DATA_RESPONSE_EXPECTED
9244 * attribute when the data is queried from the firmware.
9245 *
9246 * @QCA_WLAN_VENDOR_ATTR_OEM_DEVICE_INFO: The binary blob will be routed
9247 * based on this field. This optional attribute is included to specify whether
9248 * the device type is a virtual device or a physical device for the
9249 * command/event. This attribute can be omitted for a virtual device (default)
9250 * command/event.
9251 * This u8 attribute is used to carry information for the device type using
9252 * values defined by enum qca_vendor_oem_device_type.
9253 *
9254 * @QCA_WLAN_VENDOR_ATTR_OEM_DATA_RESPONSE_EXPECTED: This NLA_FLAG attribute
9255 * is set when the userspace queries data from the firmware. This attribute
9256 * should not be set when userspace sets the OEM data to the firmware.
9257 */
9258enum qca_wlan_vendor_attr_oem_data_params {
9259 QCA_WLAN_VENDOR_ATTR_OEM_DATA_INVALID = 0,
9260 QCA_WLAN_VENDOR_ATTR_OEM_DATA_CMD_DATA = 1,
9261 QCA_WLAN_VENDOR_ATTR_OEM_DEVICE_INFO = 2,
9262 QCA_WLAN_VENDOR_ATTR_OEM_DATA_RESPONSE_EXPECTED = 3,
9263
9264 /* keep last */
9265 QCA_WLAN_VENDOR_ATTR_OEM_DATA_PARAMS_AFTER_LAST,
9266 QCA_WLAN_VENDOR_ATTR_OEM_DATA_PARAMS_MAX =
9267 QCA_WLAN_VENDOR_ATTR_OEM_DATA_PARAMS_AFTER_LAST - 1
9268};
9269
9270/**
9271 * enum qca_wlan_vendor_attr_avoid_frequency_ext - Defines attributes to be
9272 * used with vendor command/event QCA_NL80211_VENDOR_SUBCMD_AVOID_FREQUENCY_EXT.
9273 *
9274 * @QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_RANGE: Required
9275 * Nested attribute containing multiple ranges with following attributes:
9276 * QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_START and
9277 * QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_END.
9278 *
9279 * @QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_START: Required (u32)
9280 * Starting center frequency in MHz.
9281 *
9282 * @QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_END: Required (u32)
9283 * Ending center frequency in MHz.
9284 */
9285enum qca_wlan_vendor_attr_avoid_frequency_ext {
9286 QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_INVALID = 0,
9287 QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_RANGE = 1,
9288 QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_START = 2,
9289 QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_END = 3,
9290
9291 QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_AFTER_LAST,
9292 QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_MAX =
9293 QCA_WLAN_VENDOR_ATTR_AVOID_FREQUENCY_AFTER_LAST - 1
9294};
9295
9296/*
9297 * enum qca_wlan_vendor_attr_add_sta_node_params - Used by the vendor command
9298 * QCA_NL80211_VENDOR_SUBCMD_ADD_STA_NODE.
9299 */
9300enum qca_wlan_vendor_attr_add_sta_node_params {
9301 QCA_WLAN_VENDOR_ATTR_ADD_STA_NODE_INVALID = 0,
9302 /* 6 byte MAC address of STA */
9303 QCA_WLAN_VENDOR_ATTR_ADD_STA_NODE_MAC_ADDR = 1,
9304 /* Authentication algorithm used by the station of size u16;
9305 * defined in enum nl80211_auth_type.
9306 */
9307 QCA_WLAN_VENDOR_ATTR_ADD_STA_NODE_AUTH_ALGO = 2,
9308
9309 /* keep last */
9310 QCA_WLAN_VENDOR_ATTR_ADD_STA_NODE_PARAM_AFTER_LAST,
9311 QCA_WLAN_VENDOR_ATTR_ADD_STA_NODE_PARAM_MAX =
9312 QCA_WLAN_VENDOR_ATTR_ADD_STA_NODE_PARAM_AFTER_LAST - 1
9313};
9314
9315/**
9316 * enum qca_btc_chain_mode - Specifies BT coex chain mode.
9317 * This enum defines the valid set of values of BT coex chain mode.
9318 * These values are used by attribute %QCA_VENDOR_ATTR_BTC_CHAIN_MODE of
9319 * %QCA_NL80211_VENDOR_SUBCMD_BTC_CHAIN_MODE.
9320 *
9321 * @QCA_BTC_CHAIN_SHARED: chains of BT and WLAN 2.4G are shared.
9322 * @QCA_BTC_CHAIN_SEPARATED: chains of BT and WLAN 2.4G are separated.
9323 */
9324enum qca_btc_chain_mode {
9325 QCA_BTC_CHAIN_SHARED = 0,
9326 QCA_BTC_CHAIN_SEPARATED = 1,
9327};
9328
9329/**
9330 * enum qca_vendor_attr_btc_chain_mode - Specifies attributes for BT coex
9331 * chain mode.
9332 * Attributes for data used by QCA_NL80211_VENDOR_SUBCMD_BTC_CHAIN_MODE.
9333 *
9334 * @QCA_VENDOR_ATTR_COEX_BTC_CHAIN_MODE: u32 attribute.
9335 * Indicates the BT coex chain mode, are 32-bit values from
9336 * enum qca_btc_chain_mode. This attribute is mandatory.
9337 *
9338 * @QCA_VENDOR_ATTR_COEX_BTC_CHAIN_MODE_RESTART: flag attribute.
9339 * If set, vdev should be restarted when BT coex chain mode is updated.
9340 * This attribute is optional.
9341 */
9342enum qca_vendor_attr_btc_chain_mode {
9343 QCA_VENDOR_ATTR_BTC_CHAIN_MODE_INVALID = 0,
9344 QCA_VENDOR_ATTR_BTC_CHAIN_MODE = 1,
9345 QCA_VENDOR_ATTR_BTC_CHAIN_MODE_RESTART = 2,
9346
9347 /* Keep last */
9348 QCA_VENDOR_ATTR_BTC_CHAIN_MODE_LAST,
9349 QCA_VENDOR_ATTR_BTC_CHAIN_MODE_MAX =
9350 QCA_VENDOR_ATTR_BTC_CHAIN_MODE_LAST - 1,
9351};
9352
9353/**
9354 * enum qca_vendor_wlan_sta_flags - Station feature flags
9355 * Bits will be set to 1 if the corresponding features are enabled.
9356 * @QCA_VENDOR_WLAN_STA_FLAG_AMPDU: AMPDU is enabled for the station
9357 * @QCA_VENDOR_WLAN_STA_FLAG_TX_STBC: TX Space-time block coding is enabled
9358 for the station
9359 * @QCA_VENDOR_WLAN_STA_FLAG_RX_STBC: RX Space-time block coding is enabled
9360 for the station
9361 */
9362enum qca_vendor_wlan_sta_flags {
9363 QCA_VENDOR_WLAN_STA_FLAG_AMPDU = BIT(0),
9364 QCA_VENDOR_WLAN_STA_FLAG_TX_STBC = BIT(1),
9365 QCA_VENDOR_WLAN_STA_FLAG_RX_STBC = BIT(2),
9366};
9367
9368/**
9369 * enum qca_vendor_wlan_sta_guard_interval - Station guard interval
9370 * @QCA_VENDOR_WLAN_STA_GI_800_NS: Legacy normal guard interval
9371 * @QCA_VENDOR_WLAN_STA_GI_400_NS: Legacy short guard interval
9372 * @QCA_VENDOR_WLAN_STA_GI_1600_NS: Guard interval used by HE
9373 * @QCA_VENDOR_WLAN_STA_GI_3200_NS: Guard interval used by HE
9374 */
9375enum qca_vendor_wlan_sta_guard_interval {
9376 QCA_VENDOR_WLAN_STA_GI_800_NS = 0,
9377 QCA_VENDOR_WLAN_STA_GI_400_NS = 1,
9378 QCA_VENDOR_WLAN_STA_GI_1600_NS = 2,
9379 QCA_VENDOR_WLAN_STA_GI_3200_NS = 3,
9380};
9381
9382/**
9383 * enum qca_wlan_vendor_attr_get_sta_info - Defines attributes
9384 * used by QCA_NL80211_VENDOR_SUBCMD_GET_STA_INFO vendor command.
9385 *
9386 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_MAC:
9387 * Required attribute in request for AP mode only, 6-byte MAC address,
9388 * corresponding to the station's MAC address for which information is
9389 * requested. For STA mode this is not required as the info always correspond
9390 * to the self STA and the current/last association.
9391 *
9392 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_FLAGS:
9393 * Optionally used in response, u32 attribute, contains a bitmap of different
9394 * fields defined in enum qca_vendor_wlan_sta_flags, used in AP mode only.
9395 *
9396 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_GUARD_INTERVAL:
9397 * Optionally used in response, u32 attribute, possible values are defined in
9398 * enum qca_vendor_wlan_sta_guard_interval, used in AP mode only.
9399 * Guard interval used by the station.
9400 *
9401 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_RETRY_COUNT:
9402 * Optionally used in response, u32 attribute, used in AP mode only.
9403 * Value indicates the number of data frames received from station with retry
9404 * bit set to 1 in FC.
9405 *
9406 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_BC_MC_COUNT:
9407 * Optionally used in response, u32 attribute, used in AP mode only.
9408 * Counter for number of data frames with broadcast or multicast address in
9409 * the destination address received from the station.
9410 *
9411 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RETRY_SUCCEED:
9412 * Optionally used in response, u32 attribute, used in both STA and AP modes.
9413 * Value indicates the number of data frames successfully transmitted only
9414 * after retrying the packets and for which the TX status has been updated
9415 * back to host from target.
9416 *
9417 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RETRY_EXHAUSTED:
9418 * Optionally used in response, u32 attribute, used in both STA and AP mode.
9419 * Value indicates the number of data frames not transmitted successfully even
9420 * after retrying the packets for the number of times equal to the total number
9421 * of retries allowed for that packet and for which the TX status has been
9422 * updated back to host from target.
9423 *
9424 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_TOTAL:
9425 * Optionally used in response, u32 attribute, used in AP mode only.
9426 * Counter in the target for the number of data frames successfully transmitted
9427 * to the station.
9428 *
9429 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_RETRY:
9430 * Optionally used in response, u32 attribute, used in AP mode only.
9431 * Value indicates the number of data frames successfully transmitted only
9432 * after retrying the packets.
9433 *
9434 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_RETRY_EXHAUSTED:
9435 * Optionally used in response, u32 attribute, used in both STA & AP mode.
9436 * Value indicates the number of data frames not transmitted successfully even
9437 * after retrying the packets for the number of times equal to the total number
9438 * of retries allowed for that packet.
9439 *
9440 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_PROBE_REQ_BMISS_COUNT: u32, used in
9441 * the STA mode only. Represent the number of probe requests sent by the STA
9442 * while attempting to roam on missing certain number of beacons from the
9443 * connected AP. If queried in the disconnected state, this represents the
9444 * count for the last connected state.
9445 *
9446 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_PROBE_RESP_BMISS_COUNT: u32, used in
9447 * the STA mode. Represent the number of probe responses received by the station
9448 * while attempting to roam on missing certain number of beacons from the
9449 * connected AP. When queried in the disconnected state, this represents the
9450 * count when in last connected state.
9451 *
9452 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_ALL_COUNT: u32, used in the
9453 * STA mode only. Represents the total number of frames sent out by STA
9454 * including Data, ACK, RTS, CTS, Control Management. This data is maintained
9455 * only for the connect session. Represents the count of last connected session,
9456 * when queried in the disconnected state.
9457 *
9458 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RTS_COUNT: u32, used in the STA mode.
9459 * Total number of RTS sent out by the STA. This data is maintained per connect
9460 * session. Represents the count of last connected session, when queried in the
9461 * disconnected state.
9462 *
9463 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RTS_RETRY_FAIL_COUNT: u32, used in the
9464 * STA mode.Represent the number of RTS transmission failure that reach retry
9465 * limit. This data is maintained per connect session. Represents the count of
9466 * last connected session, when queried in the disconnected state.
9467 *
9468 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_DATA_NON_AGGREGATED_COUNT: u32, used in
9469 * the STA mode. Represent the total number of non aggregated frames transmitted
9470 * by the STA. This data is maintained per connect session. Represents the count
9471 * of last connected session, when queried in the disconnected state.
9472 *
9473 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_DATA_AGGREGATED_COUNT: u32, used in the
9474 * STA mode. Represent the total number of aggregated frames transmitted by the
9475 * STA. This data is maintained per connect session. Represents the count of
9476 * last connected session, when queried in the disconnected state.
9477 *
9478 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_FRAMES_GOOD_PLCP_COUNT: u32, used in
9479 * the STA mode. Represents the number of received frames with a good PLCP. This
9480 * data is maintained per connect session. Represents the count of last
9481 * connected session, when queried in the disconnected state.
9482 *
9483 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_FRAMES_INVALID_DELIMITER_COUNT: u32,
9484 * used in the STA mode. Represents the number of occasions that no valid
9485 * delimiter is detected by A-MPDU parser. This data is maintained per connect
9486 * session. Represents the count of last connected session, when queried in the
9487 * disconnected state.
9488 *
9489 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_FRAMES_CRC_FAIL_COUNT: u32, used in the
9490 * STA mode. Represents the number of frames for which CRC check failed in the
9491 * MAC. This data is maintained per connect session. Represents the count of
9492 * last connected session, when queried in the disconnected state.
9493 *
9494 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_ACKS_GOOD_FCS_COUNT: u32, used in the
9495 * STA mode. Represents the number of unicast ACKs received with good FCS. This
9496 * data is maintained per connect session. Represents the count of last
9497 * connected session, when queried in the disconnected state.
9498 *
9499 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_BLOCKACK_COUNT: u32, used in the STA
9500 * mode. Represents the number of received Block Acks. This data is maintained
9501 * per connect session. Represents the count of last connected session, when
9502 * queried in the disconnected state.
9503 *
9504 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_BEACON_COUNT: u32, used in the STA
9505 * mode. Represents the number of beacons received from the connected BSS. This
9506 * data is maintained per connect session. Represents the count of last
9507 * connected session, when queried in the disconnected state.
9508 *
9509 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_OTHER_BEACON_COUNT: u32, used in the
9510 * STA mode. Represents the number of beacons received by the other BSS when in
9511 * connected state (through the probes done by the STA). This data is maintained
9512 * per connect session. Represents the count of last connected session, when
9513 * queried in the disconnected state.
9514 *
9515 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_UCAST_DATA_GOOD_FCS_COUNT: u64, used in
9516 * the STA mode. Represents the number of received DATA frames with good FCS and
9517 * matching Receiver Address when in connected state. This data is maintained
9518 * per connect session. Represents the count of last connected session, when
9519 * queried in the disconnected state.
9520 *
9521 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_DATA_BC_MC_DROP_COUNT: u32, used in the
9522 * STA mode. Represents the number of RX Data multicast frames dropped by the HW
9523 * when in the connected state. This data is maintained per connect session.
9524 * Represents the count of last connected session, when queried in the
9525 * disconnected state.
9526 *
9527 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_24G_1MBPS: u32, used in the
9528 * STA mode. This represents the target power in dBm for the transmissions done
9529 * to the AP in 2.4 GHz at 1 Mbps (DSSS) rate. This data is maintained per
9530 * connect session. Represents the count of last connected session, when
9531 * queried in the disconnected state.
9532 *
9533 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_24G_6MBPS: u32, used in the
9534 * STA mode. This represents the Target power in dBm for transmissions done to
9535 * the AP in 2.4 GHz at 6 Mbps (OFDM) rate. This data is maintained per connect
9536 * session. Represents the count of last connected session, when queried in the
9537 * disconnected state.
9538 *
9539 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_24G_MCS0: u32, used in the
9540 * STA mode. This represents the Target power in dBm for transmissions done to
9541 * the AP in 2.4 GHz at MCS0 rate. This data is maintained per connect session.
9542 * Represents the count of last connected session, when queried in the
9543 * disconnected state.
9544 *
9545 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_5G_6MBPS: u32, used in the
9546 * STA mode. This represents the Target power in dBm for transmissions done to
9547 * the AP in 5 GHz at 6 Mbps (OFDM) rate. This data is maintained per connect
9548 * session. Represents the count of last connected session, when queried in
9549 * the disconnected state.
9550 *
9551 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_5G_MCS0: u32, used in the
9552 * STA mode. This represents the Target power in dBm for for transmissions done
9553 * to the AP in 5 GHz at MCS0 rate. This data is maintained per connect session.
9554 * Represents the count of last connected session, when queried in the
9555 * disconnected state.
9556 *
9557 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_HW_BUFFERS_OVERFLOW_COUNT: u32, used
9558 * in the STA mode. This represents the Nested attribute representing the
9559 * overflow counts of each receive buffer allocated to the hardware during the
9560 * STA's connection. The number of hw buffers might vary for each WLAN
9561 * solution and hence this attribute represents the nested array of all such
9562 * HW buffer count. This data is maintained per connect session. Represents
9563 * the count of last connected session, when queried in the disconnected state.
9564 *
9565 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_MAX_TX_POWER: u32, Max TX power (dBm)
9566 * allowed as per the regulatory requirements for the current or last connected
9567 * session. Used in the STA mode.
9568 *
9569 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_LATEST_TX_POWER: u32, Latest TX power
9570 * (dBm) used by the station in its latest unicast frame while communicating
9571 * to the AP in the connected state. When queried in the disconnected state,
9572 * this represents the TX power used by the STA with last AP communication
9573 * when in connected state.
9574 *
9575 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_ANI_LEVEL: u32, Adaptive noise immunity
9576 * level used to adjust the RX sensitivity. Represents the current ANI level
9577 * when queried in the connected state. When queried in the disconnected
9578 * state, this corresponds to the latest ANI level at the instance of
9579 * disconnection.
9580 *
9581 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BEACON_IES: Binary attribute containing
9582 * the raw information elements from Beacon frames. Represents the Beacon frames
9583 * of the current BSS in the connected state. When queried in the disconnected
9584 * state, these IEs correspond to the last connected BSSID.
9585 *
9586 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_PROBE_RESP_IES: Binary attribute
9587 * containing the raw information elements from Probe Response frames.
9588 * Represents the Probe Response frames of the current BSS in the connected
9589 * state. When queried in the disconnected state, these IEs correspond to the
9590 * last connected BSSID.
9591 *
9592 * @QCA_WLAN_VENDOR_ATTR_GET_STA_DRIVER_DISCONNECT_REASON: u32, Driver
9593 * disconnect reason for the last disconnection if the disconnection is
9594 * triggered from the host driver. The values are referred from
9595 * enum qca_disconnect_reason_codes.
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05309596 *
9597 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BIP_MIC_ERROR_COUNT: u32, used in STA mode
9598 * only. This represents the number of group addressed robust management frames
9599 * received from this station with an invalid MIC or a missing MME when PMF is
9600 * enabled.
9601 *
9602 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BIP_REPLAY_COUNT: u32, used in STA mode
9603 * only. This represents the number of group addressed robust management frames
9604 * received from this station with the packet number less than or equal to the
9605 * last received packet number when PMF is enabled.
9606 *
9607 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BEACON_MIC_ERROR_COUNT: u32, used in STA
9608 * mode only. This represents the number of Beacon frames received from this
9609 * station with an invalid MIC or a missing MME when beacon protection is
9610 * enabled.
9611 *
9612 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BEACON_REPLAY_COUNT: u32, used in STA mode
9613 * only. This represents number of Beacon frames received from this station with
9614 * the packet number less than or equal to the last received packet number when
9615 * beacon protection is enabled.
Srinivas Girigowda7673be32020-11-12 12:37:14 -08009616 *
9617 * @QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_CONNECT_FAIL_REASON_CODE: u32, used in
9618 * STA mode only. The driver uses this attribute to populate the connection
9619 * failure reason codes and the values are defined in
9620 * enum qca_sta_connect_fail_reason_codes. Userspace applications can send
9621 * QCA_NL80211_VENDOR_SUBCMD_GET_STA_INFO vendor command after receiving
9622 * a connection failure indication from the driver. The driver shall not
9623 * include this attribute in response to the
9624 * QCA_NL80211_VENDOR_SUBCMD_GET_STA_INFO command if there is no connection
9625 * failure observed in the last attempted connection.
Jouni Malinenf735abd2020-08-03 11:08:00 +03009626 */
9627enum qca_wlan_vendor_attr_get_sta_info {
9628 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_INVALID = 0,
9629 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_MAC = 1,
9630 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_FLAGS = 2,
9631 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_GUARD_INTERVAL = 3,
9632 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_RETRY_COUNT = 4,
9633 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_BC_MC_COUNT = 5,
9634 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RETRY_SUCCEED = 6,
9635 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RETRY_EXHAUSTED = 7,
9636 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_TOTAL = 8,
9637 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_RETRY = 9,
9638 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_RETRY_EXHAUSTED = 10,
9639 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_PROBE_REQ_BMISS_COUNT = 11,
9640 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_PROBE_RESP_BMISS_COUNT = 12,
9641 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_TX_ALL_COUNT = 13,
9642 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RTS_COUNT = 14,
9643 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_RTS_RETRY_FAIL_COUNT = 15,
9644 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_DATA_NON_AGGREGATED_COUNT = 16,
9645 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TX_DATA_AGGREGATED_COUNT = 17,
9646 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_FRAMES_GOOD_PLCP_COUNT = 18,
9647 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_FRAMES_INVALID_DELIMITER_COUNT = 19,
9648 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_FRAMES_CRC_FAIL_COUNT = 20,
9649 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_ACKS_GOOD_FCS_COUNT = 21,
9650 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_BLOCKACK_COUNT = 22,
9651 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_BEACON_COUNT = 23,
9652 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_OTHER_BEACON_COUNT = 24,
9653 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_UCAST_DATA_GOOD_FCS_COUNT = 25,
9654 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_DATA_BC_MC_DROP_COUNT = 26,
9655 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_24G_1MBPS = 27,
9656 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_24G_6MBPS = 28,
9657 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_24G_MCS0 = 29,
9658 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_5G_6MBPS = 30,
9659 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_TARGET_POWER_5G_MCS0 = 31,
9660 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_RX_HW_BUFFERS_OVERFLOW_COUNT = 32,
9661 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_MAX_TX_POWER = 33,
9662 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_LATEST_TX_POWER = 34,
9663 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_ANI_LEVEL = 35,
9664 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BEACON_IES = 36,
9665 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_PROBE_RESP_IES = 37,
9666 QCA_WLAN_VENDOR_ATTR_GET_STA_DRIVER_DISCONNECT_REASON = 38,
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +05309667 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BIP_MIC_ERROR_COUNT = 39,
9668 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BIP_REPLAY_COUNT = 40,
9669 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BEACON_MIC_ERROR_COUNT = 41,
9670 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_BEACON_REPLAY_COUNT = 42,
Srinivas Girigowda7673be32020-11-12 12:37:14 -08009671 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_CONNECT_FAIL_REASON_CODE = 43,
Jouni Malinenf735abd2020-08-03 11:08:00 +03009672
9673 /* keep last */
9674 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_AFTER_LAST,
9675 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_MAX =
9676 QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_AFTER_LAST - 1,
9677};
9678
9679/**
9680 * enum qca_wlan_vendor_attr_update_sta_info - Defines attributes
9681 * used by QCA_NL80211_VENDOR_SUBCMD_UPDATE_STA_INFO vendor command.
9682 *
9683 * @QCA_WLAN_VENDOR_ATTR_UPDATE_STA_INFO_CONNECT_CHANNELS: Type is NLA_UNSPEC.
9684 * Used in STA mode. This attribute represents the list of channel center
9685 * frequencies in MHz (u32) the station has learnt during the last connection
9686 * or roaming attempt. This information shall not signify the channels for
9687 * an explicit scan request from the user space. Host drivers can update this
9688 * information to the user space in both connected and disconnected state.
9689 * In the disconnected state this information shall signify the channels
9690 * scanned in the last connection/roam attempt that lead to the disconnection.
9691 */
9692enum qca_wlan_vendor_attr_update_sta_info {
9693 QCA_WLAN_VENDOR_ATTR_UPDATE_STA_INFO_INVALID = 0,
9694 QCA_WLAN_VENDOR_ATTR_UPDATE_STA_INFO_CONNECT_CHANNELS = 1,
9695
9696 /* keep last */
9697 QCA_WLAN_VENDOR_ATTR_UPDATE_STA_INFO_AFTER_LAST,
9698 QCA_WLAN_VENDOR_ATTR_UPDATE_STA_INFO_MAX =
9699 QCA_WLAN_VENDOR_ATTR_UPDATE_STA_INFO_AFTER_LAST - 1,
9700};
9701
9702/**
9703 * enum qca_disconnect_reason_codes - Specifies driver disconnect reason codes.
9704 * Used when the driver triggers the STA to disconnect from the AP.
9705 *
9706 * @QCA_DISCONNECT_REASON_UNSPECIFIED: The host driver triggered the
9707 * disconnection with the AP due to unspecified reasons.
9708 *
9709 * @QCA_DISCONNECT_REASON_INTERNAL_ROAM_FAILURE: The host driver triggered the
9710 * disconnection with the AP due to a roaming failure. This roaming is triggered
9711 * internally (host driver/firmware).
9712 *
9713 * @QCA_DISCONNECT_REASON_EXTERNAL_ROAM_FAILURE: The driver disconnected from
9714 * the AP when the user/external triggered roaming fails.
9715 *
9716 * @QCA_DISCONNECT_REASON_GATEWAY_REACHABILITY_FAILURE: This reason code is used
9717 * by the host driver whenever gateway reachability failure is detected and the
9718 * driver disconnects with AP.
9719 *
9720 * @QCA_DISCONNECT_REASON_UNSUPPORTED_CHANNEL_CSA: The driver disconnected from
9721 * the AP on a channel switch announcement from it with an unsupported channel.
9722 *
9723 * @QCA_DISCONNECT_REASON_OPER_CHANNEL_DISABLED_INDOOR: On a concurrent AP start
9724 * with indoor channels disabled and if the STA is connected on one of these
9725 * disabled channels, the host driver disconnected the STA with this reason
9726 * code.
9727 *
9728 * @QCA_DISCONNECT_REASON_OPER_CHANNEL_USER_DISABLED: Disconnection due to an
9729 * explicit request from the user to disable the current operating channel.
9730 *
9731 * @QCA_DISCONNECT_REASON_DEVICE_RECOVERY: STA disconnected from the AP due to
9732 * the internal host driver/firmware recovery.
9733 *
9734 * @QCA_DISCONNECT_REASON_KEY_TIMEOUT: The driver triggered the disconnection on
9735 * a timeout for the key installations from the user space.
9736 *
9737 * @QCA_DISCONNECT_REASON_OPER_CHANNEL_BAND_CHANGE: The dDriver disconnected the
9738 * STA on a band change request from the user space to a different band from the
9739 * current operation channel/band.
9740 *
9741 * @QCA_DISCONNECT_REASON_IFACE_DOWN: The STA disconnected from the AP on an
9742 * interface down trigger from the user space.
9743 *
9744 * @QCA_DISCONNECT_REASON_PEER_XRETRY_FAIL: The host driver disconnected the
9745 * STA on getting continuous transmission failures for multiple Data frames.
9746 *
9747 * @QCA_DISCONNECT_REASON_PEER_INACTIVITY: The STA does a keep alive
9748 * notification to the AP by transmitting NULL/G-ARP frames. This disconnection
9749 * represents inactivity from AP on such transmissions.
9750
9751 * @QCA_DISCONNECT_REASON_SA_QUERY_TIMEOUT: This reason code is used on
9752 * disconnection when SA Query times out (AP does not respond to SA Query).
9753 *
9754 * @QCA_DISCONNECT_REASON_BEACON_MISS_FAILURE: The host driver disconnected the
9755 * STA on missing the beacons continuously from the AP.
9756 *
9757 * @QCA_DISCONNECT_REASON_CHANNEL_SWITCH_FAILURE: Disconnection due to STA not
9758 * able to move to the channel mentioned by the AP in CSA.
9759 *
9760 * @QCA_DISCONNECT_REASON_USER_TRIGGERED: User triggered disconnection.
9761 */
9762enum qca_disconnect_reason_codes {
9763 QCA_DISCONNECT_REASON_UNSPECIFIED = 0,
9764 QCA_DISCONNECT_REASON_INTERNAL_ROAM_FAILURE = 1,
9765 QCA_DISCONNECT_REASON_EXTERNAL_ROAM_FAILURE = 2,
9766 QCA_DISCONNECT_REASON_GATEWAY_REACHABILITY_FAILURE = 3,
9767 QCA_DISCONNECT_REASON_UNSUPPORTED_CHANNEL_CSA = 4,
9768 QCA_DISCONNECT_REASON_OPER_CHANNEL_DISABLED_INDOOR = 5,
9769 QCA_DISCONNECT_REASON_OPER_CHANNEL_USER_DISABLED = 6,
9770 QCA_DISCONNECT_REASON_DEVICE_RECOVERY = 7,
9771 QCA_DISCONNECT_REASON_KEY_TIMEOUT = 8,
9772 QCA_DISCONNECT_REASON_OPER_CHANNEL_BAND_CHANGE = 9,
9773 QCA_DISCONNECT_REASON_IFACE_DOWN = 10,
9774 QCA_DISCONNECT_REASON_PEER_XRETRY_FAIL = 11,
9775 QCA_DISCONNECT_REASON_PEER_INACTIVITY = 12,
9776 QCA_DISCONNECT_REASON_SA_QUERY_TIMEOUT = 13,
9777 QCA_DISCONNECT_REASON_BEACON_MISS_FAILURE = 14,
9778 QCA_DISCONNECT_REASON_CHANNEL_SWITCH_FAILURE = 15,
9779 QCA_DISCONNECT_REASON_USER_TRIGGERED = 16,
9780};
9781
9782/**
9783 * enum qca_wlan_vendor_attr_driver_disconnect_reason - Defines attributes
9784 * used by %QCA_NL80211_VENDOR_SUBCMD_DRIVER_DISCONNECT_REASON vendor command.
9785 *
9786 * @QCA_WLAN_VENDOR_ATTR_DRIVER_DISCONNECT_REASCON_CODE: u32 attribute.
9787 * This attribute represents the driver specific reason codes (local
9788 * driver/firmware initiated reasons for disconnection) defined
9789 * in enum qca_disconnect_reason_codes.
9790 */
9791enum qca_wlan_vendor_attr_driver_disconnect_reason {
9792 QCA_WLAN_VENDOR_ATTR_DRIVER_DISCONNECT_REASON_INVALID = 0,
9793 QCA_WLAN_VENDOR_ATTR_DRIVER_DISCONNECT_REASCON_CODE = 1,
9794
9795 /* keep last */
9796 QCA_WLAN_VENDOR_ATTR_DRIVER_DISCONNECT_REASON_AFTER_LAST,
9797 QCA_WLAN_VENDOR_ATTR_DRIVER_DISCONNECT_REASON_MAX =
9798 QCA_WLAN_VENDOR_ATTR_DRIVER_DISCONNECT_REASON_AFTER_LAST - 1,
9799};
9800
9801/**
9802 * enum qca_wlan_tspec_operation - Operation of the config TSPEC request
9803 *
9804 * Values for %QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_OPERATION.
9805 */
9806enum qca_wlan_tspec_operation {
9807 QCA_WLAN_TSPEC_ADD = 0,
9808 QCA_WLAN_TSPEC_DEL = 1,
9809 QCA_WLAN_TSPEC_GET = 2,
9810};
9811
9812/**
9813 * enum qca_wlan_tspec_direction - Direction in TSPEC
9814 * As what is defined in IEEE Std 802.11-2016, Table 9-139.
9815 *
9816 * Values for %QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_DIRECTION.
9817 */
9818enum qca_wlan_tspec_direction {
9819 QCA_WLAN_TSPEC_DIRECTION_UPLINK = 0,
9820 QCA_WLAN_TSPEC_DIRECTION_DOWNLINK = 1,
9821 QCA_WLAN_TSPEC_DIRECTION_DIRECT = 2,
9822 QCA_WLAN_TSPEC_DIRECTION_BOTH = 3,
9823};
9824
9825/**
9826 * enum qca_wlan_tspec_ack_policy - MAC acknowledgement policy in TSPEC
9827 * As what is defined in IEEE Std 802.11-2016, Table 9-141.
9828 *
9829 * Values for %QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_ACK_POLICY.
9830 */
9831enum qca_wlan_tspec_ack_policy {
9832 QCA_WLAN_TSPEC_NORMAL_ACK = 0,
9833 QCA_WLAN_TSPEC_NO_ACK = 1,
9834 /* Reserved */
9835 QCA_WLAN_TSPEC_BLOCK_ACK = 3,
9836};
9837
9838/**
9839 * enum qca_wlan_vendor_attr_config_tspec - Defines attributes
9840 * used by %QCA_NL80211_VENDOR_SUBCMD_CONFIG_TSPEC vendor command.
9841 *
9842 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_OPERATION:
9843 * u8 attribute. Specify the TSPEC operation of this request. Possible values
9844 * are defined in enum qca_wlan_tspec_operation.
9845 * Mandatory attribute for all kinds of config TSPEC requests.
9846 *
9847 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_TSID:
9848 * u8 attribute. TS ID. Possible values are 0-7.
9849 * Applicable for operation: QCA_WLAN_TSPEC_ADD, QCA_WLAN_TSPEC_DEL,
9850 * QCA_WLAN_TSPEC_GET. A mandatory attribute.
9851 *
9852 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_DIRECTION:
9853 * u8 attribute. Direction of data carried by the TS. Possible values are
9854 * defined in enum qca_wlan_tspec_direction.
9855 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9856 *
9857 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_APSD:
9858 * Flag attribute. Indicate whether APSD is enabled for the traffic associated
9859 * with the TS. set - enabled, not set - disabled.
9860 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9861 *
9862 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_USER_PRIORITY:
9863 * u8 attribute. User priority to be used for the transport of MSDUs/A-MSDUs
9864 * belonging to this TS. Possible values are 0-7.
9865 * Applicable for operation: QCA_WLAN_TSPEC_ADD. An optional attribute.
9866 *
9867 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_ACK_POLICY:
9868 * u8 attribute. Indicate whether MAC acknowledgements are required for
9869 * MPDUs/A-MSDUs belonging to this TS and the form of those acknowledgements.
9870 * Possible values are defined in enum qca_wlan_tspec_ack_policy.
9871 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9872 *
9873 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_NOMINAL_MSDU_SIZE:
9874 * u16 attribute. Specify the nominal size in bytes of MSDUs/A-MSDUs
9875 * belonging to this TS.
9876 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9877 *
9878 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MAXIMUM_MSDU_SIZE:
9879 * u16 attribute. Specify the maximum size in bytes of MSDUs/A-MSDUs
9880 * belonging to this TS.
9881 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9882 *
9883 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MIN_SERVICE_INTERVAL:
9884 * u32 attribute. Specify the minimum interval in microseconds between the
9885 * start of two successive SPs.
9886 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9887 *
9888 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MAX_SERVICE_INTERVAL:
9889 * u32 attribute. Specify the maximum interval in microseconds between the
9890 * start of two successive SPs.
9891 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9892 *
9893 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_INACTIVITY_INTERVAL:
9894 * u32 attribute. Specify the minimum interval in microseconds that can elapse
9895 * without arrival or transfer of an MPDU belonging to the TS before this TS
9896 * is deleted by the MAC entity at the HC.
9897 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9898 *
9899 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_SUSPENSION_INTERVAL:
9900 * u32 attribute. Specify the minimum interval in microseconds that can elapse
9901 * without arrival or transfer of an MSDU belonging to the TS before the
9902 * generation of successive QoS(+)CF-Poll is stopped for this TS. A value of
9903 * 0xFFFFFFFF disables the suspension interval. The value of the suspension
9904 * interval is always less than or equal to the inactivity interval.
9905 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9906 *
9907 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MINIMUM_DATA_RATE:
9908 * u32 attribute. Indicate the lowest data rate in bps specified at the MAC
9909 * SAP for transport of MSDUs or A-MSDUs belonging to this TS within the
9910 * bounds of this TSPEC.
9911 * Applicable for operation: QCA_WLAN_TSPEC_ADD. An optional attribute.
9912 *
9913 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MEAN_DATA_RATE:
9914 * u32 attribute. Indicate the average data rate in bps specified at the MAC
9915 * SAP for transport of MSDUs or A-MSDUs belonging to this TS within the
9916 * bounds of this TSPEC.
9917 * Applicable for operation: QCA_WLAN_TSPEC_ADD. An optional attribute.
9918 *
9919 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_PEAK_DATA_RATE:
9920 * u32 attribute. Indicate the maximum allowable data rate in bps specified at
9921 * the MAC SAP for transport of MSDUs or A-MSDUs belonging to this TS within
9922 * the bounds of this TSPEC.
9923 * Applicable for operation: QCA_WLAN_TSPEC_ADD. An optional attribute.
9924 *
9925 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_BURST_SIZE:
9926 * u32 attribute. Specify the maximum burst size in bytes of the MSDUs/A-MSDUs
9927 * belonging to this TS that arrive at the MAC SAP at the peak data rate. A
9928 * value of 0 indicates that there are no bursts.
9929 * Applicable for operation: QCA_WLAN_TSPEC_ADD. An optional attribute.
9930 *
9931 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MINIMUM_PHY_RATE:
9932 * u32 attribute. Indicate the minimum PHY rate in bps for transport of
9933 * MSDUs/A-MSDUs belonging to this TS within the bounds of this TSPEC.
9934 * Applicable for operation: QCA_WLAN_TSPEC_ADD. An optional attribute.
9935 *
9936 * @QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_SURPLUS_BANDWIDTH_ALLOWANCE:
9937 * u16 attribute. Specify the excess allocation of time (and bandwidth) over
9938 * and above the stated application rates required to transport an MSDU/A-MSDU
9939 * belonging to the TS in this TSPEC.
9940 * Applicable for operation: QCA_WLAN_TSPEC_ADD. A mandatory attribute.
9941 */
9942enum qca_wlan_vendor_attr_config_tspec {
9943 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_INVALID = 0,
9944 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_OPERATION = 1,
9945 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_TSID = 2,
9946 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_DIRECTION = 3,
9947 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_APSD = 4,
9948 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_USER_PRIORITY = 5,
9949 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_ACK_POLICY = 6,
9950 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_NOMINAL_MSDU_SIZE = 7,
9951 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MAXIMUM_MSDU_SIZE = 8,
9952 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MIN_SERVICE_INTERVAL = 9,
9953 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MAX_SERVICE_INTERVAL = 10,
9954 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_INACTIVITY_INTERVAL = 11,
9955 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_SUSPENSION_INTERVAL = 12,
9956 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MINIMUM_DATA_RATE = 13,
9957 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MEAN_DATA_RATE = 14,
9958 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_PEAK_DATA_RATE = 15,
9959 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_BURST_SIZE = 16,
9960 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MINIMUM_PHY_RATE = 17,
9961 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_SURPLUS_BANDWIDTH_ALLOWANCE = 18,
9962
9963 /* keep last */
9964 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_AFTER_LAST,
9965 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_MAX =
9966 QCA_WLAN_VENDOR_ATTR_CONFIG_TSPEC_AFTER_LAST - 1,
9967};
9968
9969/**
9970 * enum qca_wlan_vendor_oci_override_frame_type - OCI override frame type
9971 * @QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_SA_QUERY_REQ: SA Query Request frame
9972 * @QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_SA_QUERY_RESP: SA Query Response frame
9973 * @QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_FT_REASSOC_REQ: FT Reassociation Request
9974 * frame
9975 * @QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_FILS_REASSOC_REQ: FILS Reassociation
9976 * Request frame.
9977 */
9978enum qca_wlan_vendor_oci_override_frame_type {
9979 QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_SA_QUERY_REQ = 1,
9980 QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_SA_QUERY_RESP = 2,
9981 QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_FT_REASSOC_REQ = 3,
9982 QCA_WLAN_VENDOR_OCI_OVERRIDE_FRAME_FILS_REASSOC_REQ = 4,
9983};
9984
9985/**
9986 * enum qca_wlan_vendor_attr_oci_override: Represents attributes for
9987 * OCI override request. These attributes are used inside nested attribute
9988 * %QCA_WLAN_VENDOR_ATTR_WIFI_TEST_CONFIG_OCI_OVERRIDE in QCA vendor command
9989 * %QCA_NL80211_VENDOR_SUBCMD_WIFI_TEST_CONFIGURATION.
9990 *
9991 * @QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_FRAME_TYPE: Required attribute, u8.
9992 * Values from enum qca_wlan_vendor_oci_override_frame_type used in this
9993 * attribute to specify the frame type in which the OCI is to be overridden.
9994 *
9995 * @QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_FREQUENCY: Required (u32)
9996 * OCI frequency (in MHz) to override in the specified frame type.
9997 */
9998enum qca_wlan_vendor_attr_oci_override {
9999 QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_INVALID = 0,
10000 QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_FRAME_TYPE = 1,
10001 QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_FREQUENCY = 2,
10002
10003 /* keep last */
10004 QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_AFTER_LAST,
10005 QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_MAX =
10006 QCA_WLAN_VENDOR_ATTR_OCI_OVERRIDE_AFTER_LAST - 1,
10007};
10008
Veerendranath Jakkam58aa0442020-09-10 06:56:51 +053010009/**
10010 * enum qca_wlan_medium_assess_type - Type of medium assess request
10011 *
10012 * Values for %QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_TYPE.
10013 */
10014enum qca_wlan_medium_assess_type {
10015 QCA_WLAN_MEDIUM_ASSESS_CCA = 0,
10016 QCA_WLAN_MEDIUM_ASSESS_CONGESTION_REPORT = 1,
10017};
10018
10019/**
10020 * enum qca_wlan_vendor_attr_medium_assess - Attributes used by
10021 * %QCA_NL80211_VENDOR_SUBCMD_MEDIUM_ASSESS vendor command.
10022 *
10023 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_TYPE:
10024 * u8 attribute. Mandatory in all kinds of medium assess requests/responses.
10025 * Specify the type of medium assess request and indicate its type in response.
10026 * Possible values are defined in enum qca_wlan_medium_assess_type.
10027 *
10028 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_PERIOD:
10029 * u32 attribute. Mandatory in CCA request.
10030 * Specify the assessment period in terms of seconds. Assessment result will be
10031 * sent as the response to the CCA request after the assessment period.
10032 *
10033 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_TOTAL_CYCLE_COUNT:
10034 * u32 attribute. Mandatory in response to CCA request.
10035 * Total timer tick count of the assessment cycle.
10036 *
10037 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_IDLE_COUNT:
10038 * u32 attribute. Mandatory in response to CCA request.
10039 * Timer tick count of idle time in the assessment cycle.
10040 *
10041 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_IBSS_RX_COUNT:
10042 * u32 attribute. Mandatory in response to CCA request.
10043 * Timer tick count of Intra BSS traffic RX time in the assessment cycle.
10044 *
10045 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_OBSS_RX_COUNT:
10046 * u32 attribute. Mandatory in response to CCA request.
10047 * Timer tick count of Overlapping BSS traffic RX time in the assessment cycle.
10048 *
10049 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_MAX_IBSS_RSSI:
10050 * s32 attribute. Mandatory in response to CCA request.
10051 * Maximum RSSI of Intra BSS traffic in the assessment cycle.
10052 *
10053 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_MIN_IBSS_RSSI:
10054 * s32 attribute. Mandatory in response to CCA request.
10055 * Minimum RSSI of Intra BSS traffic in the assessment cycle.
10056 *
10057 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_REPORT_ENABLE:
10058 * u8 attribute. Mandatory in congestion report request.
10059 * 1-enable 0-disable.
10060 *
10061 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_REPORT_THRESHOLD:
10062 * u8 attribute. Mandatory in congestion report enable request and will be
10063 * ignored if present in congestion report disable request. Possible values are
10064 * 0-100. A vendor event QCA_NL80211_VENDOR_SUBCMD_MEDIUM_ASSESS with the type
10065 * QCA_WLAN_MEDIUM_ASSESS_CONGESTION_REPORT will be sent to userspace if
10066 * congestion percentage reaches the configured threshold.
10067 *
10068 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_REPORT_INTERVAL:
10069 * u8 attribute. Optional in congestion report enable request and will be
10070 * ignored if present in congestion report disable request.
10071 * Specify the interval of congestion report event in terms of seconds. Possible
10072 * values are 1-255. Default value 1 will be used if this attribute is omitted
10073 * or using invalid values.
10074 *
10075 * @QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_PERCENTAGE:
10076 * u8 attribute. Mandatory in congestion report event.
10077 * Indicate the actual congestion percentage. Possible values are 0-100.
10078 */
10079enum qca_wlan_vendor_attr_medium_assess {
10080 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_INVALID = 0,
10081 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_TYPE = 1,
10082
10083 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_PERIOD = 2,
10084 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_TOTAL_CYCLE_COUNT = 3,
10085 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_IDLE_COUNT = 4,
10086 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_IBSS_RX_COUNT = 5,
10087 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_OBSS_RX_COUNT = 6,
10088 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_MAX_IBSS_RSSI = 7,
10089 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_MIN_IBSS_RSSI = 8,
10090
10091 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_REPORT_ENABLE = 9,
10092 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_REPORT_THRESHOLD = 10,
10093 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_REPORT_INTERVAL = 11,
10094 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_CONGESTION_PERCENTAGE = 12,
10095
10096 /* keep last */
10097 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_AFTER_LAST,
10098 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_MAX =
10099 QCA_WLAN_VENDOR_ATTR_MEDIUM_ASSESS_AFTER_LAST - 1,
10100};
10101
10102/**
10103 * enum qca_wlan_vendor_attr_mbssid_tx_vdev_status - Defines attributes
10104 * used by QCA_NL80211_VENDOR_SUBCMD_MBSSID_TX_VDEV_STATUS vendor command.
10105 *
10106 * @QCA_WLAN_VENDOR_ATTR_MBSSID_TX_VDEV_STATUS_VAL:
10107 * u8 attribute. Notify the TX VDEV status. Possible values 0, 1
10108 * belonging to MBSSID/EMA_AP configuration. 0 means Non-Tx VDEV,
10109 * 1 means Tx VDEV. Mandatory attribute for all MBSSID VDEV status events.
10110 */
10111enum qca_wlan_vendor_attr_mbssid_tx_vdev_status {
10112 QCA_WLAN_VENDOR_ATTR_MBSSID_TX_VDEV_STATUS_INVALID = 0,
10113 QCA_WLAN_VENDOR_ATTR_MBSSID_TX_VDEV_STATUS_VAL = 1,
10114
10115 /* keep last */
10116 QCA_WLAN_VENDOR_ATTR_MBSSID_TX_VDEV_STATUS_AFTER_LAST,
10117 QCA_WLAN_VENDOR_ATTR_MBSSID_TX_VDEV_STATUS_MAX =
10118 QCA_WLAN_VENDOR_ATTR_MBSSID_TX_VDEV_STATUS_AFTER_LAST - 1,
10119};
10120
Srinivas Girigowda7673be32020-11-12 12:37:14 -080010121/**
10122 * enum qca_sta_connect_fail_reason_codes - Defines values carried
10123 * by QCA_WLAN_VENDOR_ATTR_GET_STA_INFO_CONNECT_FAIL_REASON_CODE vendor
10124 * attribute.
10125 * @QCA_STA_CONNECT_FAIL_REASON_NO_BSS_FOUND: No Probe Response frame received
10126 * for unicast Probe Request frame.
10127 * @QCA_STA_CONNECT_FAIL_REASON_AUTH_TX_FAIL: STA failed to send auth request.
10128 * @QCA_STA_CONNECT_FAIL_REASON_AUTH_NO_ACK_RECEIVED: AP didn't send ACK for
10129 * auth request.
10130 * @QCA_STA_CONNECT_FAIL_REASON_AUTH_NO_RESP_RECEIVED: Auth response is not
10131 * received from AP.
10132 * @QCA_STA_CONNECT_FAIL_REASON_ASSOC_REQ_TX_FAIL: STA failed to send
10133 * Association Request frame.
10134 * @QCA_STA_CONNECT_FAIL_REASON_ASSOC_NO_ACK_RECEIVED: AP didn't send ACK for
10135 * Association Request frame.
10136 * @QCA_STA_CONNECT_FAIL_REASON_ASSOC_NO_RESP_RECEIVED: Association Response
10137 * frame is not received from AP.
10138 */
10139enum qca_sta_connect_fail_reason_codes {
10140 QCA_STA_CONNECT_FAIL_REASON_NO_BSS_FOUND = 1,
10141 QCA_STA_CONNECT_FAIL_REASON_AUTH_TX_FAIL = 2,
10142 QCA_STA_CONNECT_FAIL_REASON_AUTH_NO_ACK_RECEIVED = 3,
10143 QCA_STA_CONNECT_FAIL_REASON_AUTH_NO_RESP_RECEIVED = 4,
10144 QCA_STA_CONNECT_FAIL_REASON_ASSOC_REQ_TX_FAIL = 5,
10145 QCA_STA_CONNECT_FAIL_REASON_ASSOC_NO_ACK_RECEIVED = 6,
10146 QCA_STA_CONNECT_FAIL_REASON_ASSOC_NO_RESP_RECEIVED = 7,
10147};
10148
Peng Xu291d97d2018-01-31 16:34:03 -080010149#endif /* QCA_VENDOR_H */