linux/drivers/net/wireless/ath/ath10k/wmi-tlv.h

/* SPDX-License-Identifier: ISC */
/*
 * Copyright (c) 2005-2011 Atheros Communications Inc.
 * Copyright (c) 2011-2017 Qualcomm Atheros, Inc.
 * Copyright (c) 2018-2019, The Linux Foundation. All rights reserved.
 * Copyright (c) 2022, 2024 Qualcomm Innovation Center, Inc. All rights reserved.
 */
#ifndef _WMI_TLV_H
#define _WMI_TLV_H

#include <linux/bitops.h>

#define WMI_TLV_CMD(grp_id)
#define WMI_TLV_EV(grp_id)
#define WMI_TLV_CMD_UNSUPPORTED
#define WMI_TLV_PDEV_PARAM_UNSUPPORTED
#define WMI_TLV_VDEV_PARAM_UNSUPPORTED
#define WMI_TLV_MGMT_TX_FRAME_MAX_LEN

#define WMI_RSRC_CFG_FLAG_TX_ACK_RSSI

enum wmi_tlv_grp_id {};

enum wmi_tlv_cmd_id {};

enum wmi_tlv_event_id {};

enum wmi_tlv_pdev_param {};

enum wmi_tlv_vdev_param {};

enum wmi_tlv_peer_param {};

enum wmi_tlv_peer_flags {};

enum wmi_tlv_tag {};

enum wmi_tlv_service {};

#define WMI_TLV_EXT_SERVICE_IS_ENABLED(wmi_svc_bmap, svc_id, len)

#define SVCMAP

static inline void
wmi_tlv_svc_map(const __le32 *in, unsigned long *out, size_t len)
{}

static inline void
wmi_tlv_svc_map_ext(const __le32 *in, unsigned long *out, size_t len)
{}

#undef SVCMAP

struct wmi_tlv {} __packed;

struct ath10k_mgmt_tx_pkt_addr {};

struct chan_info_params {};

#define WMI_TLV_FLAG_MGMT_BUNDLE_TX_COMPL

struct wmi_tlv_chan_info_event {} __packed;

struct wmi_tlv_mgmt_tx_compl_ev {};

#define WMI_TLV_MGMT_RX_NUM_RSSI

struct wmi_tlv_mgmt_rx_ev {} __packed;

struct wmi_tlv_abi_version {} __packed;

enum wmi_tlv_hw_bd_id {};

struct wmi_tlv_hw_bd_info {} __packed;

struct wmi_tlv_svc_rdy_ev {} __packed;

struct wmi_tlv_rdy_ev {} __packed;

struct wmi_tlv_resource_config {} __packed;

/* structure describing host memory chunk. */
struct host_memory_chunk_tlv {} __packed;

struct wmi_tlv_init_cmd {} __packed;

struct wmi_tlv_pdev_get_temp_cmd {} __packed;

struct wmi_tlv_pdev_temperature_event {} __packed;

struct wmi_tlv_pdev_set_param_cmd {} __packed;

struct wmi_tlv_pdev_set_rd_cmd {} __packed;

struct wmi_tlv_scan_chan_list_cmd {} __packed;

struct wmi_scan_prob_req_oui_cmd {}  __packed;

struct wmi_tlv_start_scan_cmd {} __packed;

enum wmi_tlv_vdev_subtype {};

struct wmi_tlv_vdev_start_cmd {} __packed;

enum {};

struct wmi_tlv_peer_create_cmd {} __packed;

struct wmi_tlv_peer_assoc_cmd {} __packed;

struct wmi_tlv_pdev_suspend {} __packed;

struct wmi_tlv_pdev_set_wmm_cmd {} __packed;

struct wmi_tlv_vdev_wmm_params {} __packed;

struct wmi_tlv_vdev_set_wmm_cmd {} __packed;

struct wmi_tlv_phyerr_ev {} __packed;

enum wmi_tlv_dbglog_param {};

enum wmi_tlv_dbglog_log_level {};

#define WMI_TLV_DBGLOG_BITMAP_MAX_IDS
#define WMI_TLV_DBGLOG_BITMAP_MAX_WORDS
#define WMI_TLV_DBGLOG_ALL_MODULES
#define WMI_TLV_DBGLOG_LOG_LEVEL_VALUE(module_id, log_level)

struct wmi_tlv_dbglog_cmd {} __packed;

struct wmi_tlv_resume_cmd {} __packed;

struct wmi_tlv_req_stats_cmd {} __packed;

#define WMI_TLV_PEER_RX_DURATION_HIGH_VALID_BIT
#define WMI_TLV_PEER_RX_DURATION_HIGH_MASK
#define WMI_TLV_PEER_RX_DURATION_SHIFT

struct wmi_tlv_peer_stats_extd {} __packed;

struct wmi_tlv_vdev_stats {} __packed;

struct wmi_tlv_pktlog_enable {} __packed;

struct wmi_tlv_pktlog_disable {} __packed;

enum wmi_tlv_bcn_tx_status {};

struct wmi_tlv_bcn_tx_status_ev {} __packed;

struct wmi_tlv_bcn_prb_info {} __packed;

struct wmi_tlv_bcn_tmpl_cmd {} __packed;

struct wmi_tlv_prb_tmpl_cmd {} __packed;

struct wmi_tlv_p2p_go_bcn_ie {} __packed;

enum wmi_tlv_diag_item_type {};

struct wmi_tlv_diag_item {} __packed;

struct wmi_tlv_diag_data_ev {} __packed;

struct wmi_tlv_sta_keepalive_cmd {} __packed;

struct wmi_tlv_stats_ev {} __packed;

struct wmi_tlv_peer_stats_info_ev {} __packed;

#define WMI_TLV_MAX_CHAINS

struct wmi_tlv_peer_stats_info {} __packed;

#define HW_RATECODE_PREAM_V1_MASK
#define WMI_TLV_GET_HW_RC_PREAM_V1(rc)

#define HW_RATECODE_NSS_V1_MASK
#define WMI_TLV_GET_HW_RC_NSS_V1(rc)

#define HW_RATECODE_RATE_V1_MASK
#define WMI_TLV_GET_HW_RC_RATE_V1(rc)

struct wmi_tlv_p2p_noa_ev {} __packed;

struct wmi_tlv_roam_ev {} __packed;

struct wmi_tlv_wow_add_del_event_cmd {} __packed;

struct wmi_tlv_request_peer_stats_info {} __packed;

/* Command to set/unset chip in quiet mode */
struct wmi_tlv_set_quiet_cmd {} __packed;

enum wmi_tlv_wow_interface_cfg {};

struct wmi_tlv_wow_enable_cmd {} __packed;

struct wmi_tlv_wow_host_wakeup_ind {} __packed;

struct wmi_tlv_wow_event_info {} __packed;

enum wmi_tlv_pattern_type {};

#define WOW_DEFAULT_BITMAP_PATTERN_SIZE
#define WOW_DEFAULT_BITMASK_SIZE

struct wmi_tlv_wow_bitmap_pattern {} __packed;

struct wmi_tlv_wow_add_pattern_cmd {} __packed;

struct wmi_tlv_wow_del_pattern_cmd {} __packed;

/* TDLS Options */
enum wmi_tlv_tdls_options {};

struct wmi_tdls_set_state_cmd {} __packed;

struct wmi_tdls_peer_update_cmd {} __packed;

enum {};

#define WMI_TLV_TDLS_PEER_SP_MASK
#define WMI_TLV_TDLS_PEER_SP_LSB

struct wmi_tdls_peer_capab {} __packed;

struct wmi_tlv_adaptive_qcs {} __packed;

/**
 * enum wmi_tlv_tx_pause_id - firmware tx queue pause reason types
 *
 * @WMI_TLV_TX_PAUSE_ID_MCC: used for by multi-channel firmware scheduler.
 *		Only vdev_map is valid.
 * @WMI_TLV_TX_PAUSE_ID_AP_PEER_PS: peer in AP mode is asleep.
 *		Only peer_id is valid.
 * @WMI_TLV_TX_PAUSE_ID_AP_PEER_UAPSD: Only peer_id and tid_map are valid.
 * @WMI_TLV_TX_PAUSE_ID_P2P_CLI_NOA: Only vdev_map is valid.
 * @WMI_TLV_TX_PAUSE_ID_P2P_GO_PS: Only vdev_map is valid.
 * @WMI_TLV_TX_PAUSE_ID_STA_ADD_BA: Only peer_id and tid_map are valid.
 * @WMI_TLV_TX_PAUSE_ID_AP_PS: When all peers are asleep in AP mode. Only
 *		vdev_map is valid.
 * @WMI_TLV_TX_PAUSE_ID_IBSS_PS: When all peers are asleep in IBSS mode. Only
 *		vdev_map is valid.
 * @WMI_TLV_TX_PAUSE_ID_HOST: Host itself requested tx pause.
 */
enum wmi_tlv_tx_pause_id {};

enum wmi_tlv_tx_pause_action {};

struct wmi_tlv_tx_pause_ev {} __packed;

struct wmi_tlv_tdls_peer_event {} __packed;

enum wmi_tlv_sys_cap_info_flags {};

#define WMI_TLV_RFKILL_CFG_GPIO_PIN_NUM
#define WMI_TLV_RFKILL_CFG_RADIO_LEVEL
#define WMI_TLV_RFKILL_CFG_PIN_AS_GPIO

enum wmi_tlv_rfkill_enable_radio {};

enum wmi_tlv_rfkill_radio_state {};

struct wmi_tlv_rfkill_state_change_ev {};

void ath10k_wmi_tlv_attach(struct ath10k *ar);

enum wmi_nlo_auth_algorithm {};

enum wmi_nlo_cipher_algorithm {};

/* SSID broadcast  type passed in NLO params */
enum wmi_nlo_ssid_bcastnwtype {};

#define WMI_NLO_MAX_SSIDS
#define WMI_NLO_MAX_CHAN

#define WMI_NLO_CONFIG_STOP
#define WMI_NLO_CONFIG_START
#define WMI_NLO_CONFIG_RESET
#define WMI_NLO_CONFIG_SLOW_SCAN
#define WMI_NLO_CONFIG_FAST_SCAN
#define WMI_NLO_CONFIG_SSID_HIDE_EN

/* This bit is used to indicate if EPNO or supplicant PNO is enabled.
 * Only one of them can be enabled at a given time
 */
#define WMI_NLO_CONFIG_ENLO
#define WMI_NLO_CONFIG_SCAN_PASSIVE
#define WMI_NLO_CONFIG_ENLO_RESET
#define WMI_NLO_CONFIG_SPOOFED_MAC_IN_PROBE_REQ
#define WMI_NLO_CONFIG_RANDOM_SEQ_NO_IN_PROBE_REQ
#define WMI_NLO_CONFIG_ENABLE_IE_WHITELIST_IN_PROBE_REQ
#define WMI_NLO_CONFIG_ENABLE_CNLO_RSSI_CONFIG

/* Whether directed scan needs to be performed (for hidden SSIDs) */
#define WMI_ENLO_FLAG_DIRECTED_SCAN

/* Whether PNO event shall be triggered if the network is found on A band */
#define WMI_ENLO_FLAG_A_BAND

/* Whether PNO event shall be triggered if the network is found on G band */
#define WMI_ENLO_FLAG_G_BAND

/* Whether strict matching is required (i.e. firmware shall not
 * match on the entire SSID)
 */
#define WMI_ENLO_FLAG_STRICT_MATCH

/* Code for matching the beacon AUTH IE - additional codes TBD */
/* open */
#define WMI_ENLO_AUTH_CODE_OPEN

/* WPA_PSK or WPA2PSK */
#define WMI_ENLO_AUTH_CODE_PSK

/* any EAPOL */
#define WMI_ENLO_AUTH_CODE_EAPOL

struct wmi_nlo_ssid_param {} __packed;

struct wmi_nlo_enc_param {} __packed;

struct wmi_nlo_auth_param {} __packed;

struct wmi_nlo_bcast_nw_param {} __packed;

struct wmi_nlo_rssi_param {} __packed;

struct nlo_configured_parameters {} __packed;

/* Support channel prediction for PNO scan after scanning top_k_num channels
 * if stationary_threshold is met.
 */
struct nlo_channel_prediction_cfg {} __packed;

struct enlo_candidate_score_params_t {} __packed;

struct connected_nlo_bss_band_rssi_pref_t {} __packed;

struct connected_nlo_rssi_params_t {} __packed;

struct wmi_tlv_wow_nlo_config_cmd {} __packed;

struct wmi_tlv_mgmt_tx_cmd {} __packed;
#endif