185630469SLior David /* SPDX-License-Identifier: ISC */ 22be7d22fSVladimir Kondratiev /* 373a7d1e3SAlexei Avshalom Lazar * Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. 4849a564bSDedy Lansky * Copyright (c) 2012-2017 Qualcomm Atheros, Inc. 5b874ddecSLior David * Copyright (c) 2006-2012 Wilocity 62be7d22fSVladimir Kondratiev */ 72be7d22fSVladimir Kondratiev 82be7d22fSVladimir Kondratiev /* 92be7d22fSVladimir Kondratiev * This file contains the definitions of the WMI protocol specified in the 10b874ddecSLior David * Wireless Module Interface (WMI) for the Qualcomm 11b874ddecSLior David * 60 GHz wireless solution. 122be7d22fSVladimir Kondratiev * It includes definitions of all the commands and events. 132be7d22fSVladimir Kondratiev * Commands are messages from the host to the WM. 142be7d22fSVladimir Kondratiev * Events are messages from the WM to the host. 15b874ddecSLior David * 16b874ddecSLior David * This is an automatically generated file. 172be7d22fSVladimir Kondratiev */ 182be7d22fSVladimir Kondratiev 192be7d22fSVladimir Kondratiev #ifndef __WILOCITY_WMI_H__ 202be7d22fSVladimir Kondratiev #define __WILOCITY_WMI_H__ 212be7d22fSVladimir Kondratiev 22b874ddecSLior David #define WMI_DEFAULT_ASSOC_STA (1) 232be7d22fSVladimir Kondratiev #define WMI_MAC_LEN (6) 242be7d22fSVladimir Kondratiev #define WMI_PROX_RANGE_NUM (3) 25b874ddecSLior David #define WMI_MAX_LOSS_DMG_BEACONS (20) 268ae5d62cSLior David #define MAX_NUM_OF_SECTORS (128) 279b586118STzahi Sabo #define WMI_INVALID_TEMPERATURE (0xFFFFFFFF) 28761f8e4dSLazar Alexei #define WMI_SCHED_MAX_ALLOCS_PER_CMD (4) 29761f8e4dSLazar Alexei #define WMI_RF_DTYPE_LENGTH (3) 30761f8e4dSLazar Alexei #define WMI_RF_ETYPE_LENGTH (3) 31761f8e4dSLazar Alexei #define WMI_RF_RX2TX_LENGTH (3) 32761f8e4dSLazar Alexei #define WMI_RF_ETYPE_VAL_PER_RANGE (5) 338a4fa214SAhmad Masri /* DTYPE configuration array size 348a4fa214SAhmad Masri * must always be kept equal to (WMI_RF_DTYPE_LENGTH+1) 358a4fa214SAhmad Masri */ 368a4fa214SAhmad Masri #define WMI_RF_DTYPE_CONF_LENGTH (4) 378a4fa214SAhmad Masri /* ETYPE configuration array size 388a4fa214SAhmad Masri * must always be kept equal to 398a4fa214SAhmad Masri * (WMI_RF_ETYPE_LENGTH+WMI_RF_ETYPE_VAL_PER_RANGE) 408a4fa214SAhmad Masri */ 418a4fa214SAhmad Masri #define WMI_RF_ETYPE_CONF_LENGTH (8) 428a4fa214SAhmad Masri /* RX2TX configuration array size 438a4fa214SAhmad Masri * must always be kept equal to (WMI_RF_RX2TX_LENGTH+1) 448a4fa214SAhmad Masri */ 458a4fa214SAhmad Masri #define WMI_RF_RX2TX_CONF_LENGTH (4) 46b5aeff16SDedy Lansky /* Qos configuration */ 47b5aeff16SDedy Lansky #define WMI_QOS_NUM_OF_PRIORITY (4) 48b5aeff16SDedy Lansky #define WMI_QOS_MIN_DEFAULT_WEIGHT (10) 49b5aeff16SDedy Lansky #define WMI_QOS_VRING_SLOT_MIN_MS (2) 50b5aeff16SDedy Lansky #define WMI_QOS_VRING_SLOT_MAX_MS (10) 51b5aeff16SDedy Lansky /* (WMI_QOS_MIN_DEFAULT_WEIGHT * WMI_QOS_VRING_SLOT_MAX_MS / 52b5aeff16SDedy Lansky * WMI_QOS_VRING_SLOT_MIN_MS) 53b5aeff16SDedy Lansky */ 54b5aeff16SDedy Lansky #define WMI_QOS_MAX_WEIGHT 50 55b5aeff16SDedy Lansky #define WMI_QOS_SET_VIF_PRIORITY (0xFF) 56b5aeff16SDedy Lansky #define WMI_QOS_DEFAULT_PRIORITY (WMI_QOS_NUM_OF_PRIORITY) 579b586118STzahi Sabo #define WMI_MAX_XIF_PORTS_NUM (8) 58b874ddecSLior David 59b874ddecSLior David /* Mailbox interface 60b874ddecSLior David * used for commands and events 61b874ddecSLior David */ 62b874ddecSLior David enum wmi_mid { 63b874ddecSLior David MID_DEFAULT = 0x00, 64b874ddecSLior David FIRST_DBG_MID_ID = 0x10, 65b874ddecSLior David LAST_DBG_MID_ID = 0xFE, 66b874ddecSLior David MID_BROADCAST = 0xFF, 67b874ddecSLior David }; 68b874ddecSLior David 6908989f96SLior David /* FW capability IDs 7008989f96SLior David * Each ID maps to a bit in a 32-bit bitmask value provided by the FW to 7108989f96SLior David * the host 7208989f96SLior David */ 7308989f96SLior David enum wmi_fw_capability { 7408989f96SLior David WMI_FW_CAPABILITY_FTM = 0, 7508989f96SLior David WMI_FW_CAPABILITY_PS_CONFIG = 1, 76cbf795c1SLior David WMI_FW_CAPABILITY_RF_SECTORS = 2, 77cbf795c1SLior David WMI_FW_CAPABILITY_MGMT_RETRY_LIMIT = 3, 788a4fa214SAhmad Masri WMI_FW_CAPABILITY_AP_SME_OFFLOAD_PARTIAL = 4, 790d2370e9SDedy Lansky WMI_FW_CAPABILITY_WMI_ONLY = 5, 8090ffabb0SDedy Lansky WMI_FW_CAPABILITY_THERMAL_THROTTLING = 7, 81fe9ee51eSMaya Erez WMI_FW_CAPABILITY_D3_SUSPEND = 8, 82761f8e4dSLazar Alexei WMI_FW_CAPABILITY_LONG_RANGE = 9, 83761f8e4dSLazar Alexei WMI_FW_CAPABILITY_FIXED_SCHEDULING = 10, 84761f8e4dSLazar Alexei WMI_FW_CAPABILITY_MULTI_DIRECTED_OMNIS = 11, 8530868f5dSDedy Lansky WMI_FW_CAPABILITY_RSSI_REPORTING = 12, 86761f8e4dSLazar Alexei WMI_FW_CAPABILITY_SET_SILENT_RSSI_TABLE = 13, 87761f8e4dSLazar Alexei WMI_FW_CAPABILITY_LO_POWER_CALIB_FROM_OTP = 14, 88a5dc6883SDedy Lansky WMI_FW_CAPABILITY_PNO = 15, 899abe3e30SAlexei Avshalom Lazar WMI_FW_CAPABILITY_CHANNEL_BONDING = 17, 90594b59ecSMaya Erez WMI_FW_CAPABILITY_REF_CLOCK_CONTROL = 18, 918a4fa214SAhmad Masri WMI_FW_CAPABILITY_AP_SME_OFFLOAD_NONE = 19, 92b5aeff16SDedy Lansky WMI_FW_CAPABILITY_MULTI_VIFS = 20, 93b5aeff16SDedy Lansky WMI_FW_CAPABILITY_FT_ROAMING = 21, 941b99197dSMaya Erez WMI_FW_CAPABILITY_BACK_WIN_SIZE_64 = 22, 957be13fc3SGidon Studinski WMI_FW_CAPABILITY_AMSDU = 23, 966a363e8aSAhmad Masri WMI_FW_CAPABILITY_RAW_MODE = 24, 976a363e8aSAhmad Masri WMI_FW_CAPABILITY_TX_REQ_EXT = 25, 9822b9610eSAlexei Avshalom Lazar WMI_FW_CAPABILITY_CHANNEL_4 = 26, 9973a7d1e3SAlexei Avshalom Lazar WMI_FW_CAPABILITY_IPA = 27, 1009b586118STzahi Sabo WMI_FW_CAPABILITY_TEMPERATURE_ALL_RF = 30, 10142fe1e51SAhmad Masri WMI_FW_CAPABILITY_SPLIT_REKEY = 31, 10208989f96SLior David WMI_FW_CAPABILITY_MAX, 10308989f96SLior David }; 10408989f96SLior David 105b874ddecSLior David /* WMI_CMD_HDR */ 106b874ddecSLior David struct wmi_cmd_hdr { 107b874ddecSLior David u8 mid; 108b874ddecSLior David u8 reserved; 109b874ddecSLior David __le16 command_id; 110b874ddecSLior David __le32 fw_timestamp; 111b874ddecSLior David } __packed; 1122be7d22fSVladimir Kondratiev 1132be7d22fSVladimir Kondratiev /* List of Commands */ 1142be7d22fSVladimir Kondratiev enum wmi_command_id { 115b874ddecSLior David WMI_CONNECT_CMDID = 0x01, 116b874ddecSLior David WMI_DISCONNECT_CMDID = 0x03, 117b874ddecSLior David WMI_DISCONNECT_STA_CMDID = 0x04, 118a5dc6883SDedy Lansky WMI_START_SCHED_SCAN_CMDID = 0x05, 119a5dc6883SDedy Lansky WMI_STOP_SCHED_SCAN_CMDID = 0x06, 120b874ddecSLior David WMI_START_SCAN_CMDID = 0x07, 121b874ddecSLior David WMI_SET_BSS_FILTER_CMDID = 0x09, 122b874ddecSLior David WMI_SET_PROBED_SSID_CMDID = 0x0A, 123761f8e4dSLazar Alexei /* deprecated */ 124b874ddecSLior David WMI_SET_LISTEN_INT_CMDID = 0x0B, 125b5aeff16SDedy Lansky WMI_FT_AUTH_CMDID = 0x0C, 126b5aeff16SDedy Lansky WMI_FT_REASSOC_CMDID = 0x0D, 127b5aeff16SDedy Lansky WMI_UPDATE_FT_IES_CMDID = 0x0E, 128b874ddecSLior David WMI_BCON_CTRL_CMDID = 0x0F, 129b874ddecSLior David WMI_ADD_CIPHER_KEY_CMDID = 0x16, 130b874ddecSLior David WMI_DELETE_CIPHER_KEY_CMDID = 0x17, 131b874ddecSLior David WMI_PCP_CONF_CMDID = 0x18, 132b874ddecSLior David WMI_SET_APPIE_CMDID = 0x3F, 133b874ddecSLior David WMI_SET_WSC_STATUS_CMDID = 0x41, 134b874ddecSLior David WMI_PXMT_RANGE_CFG_CMDID = 0x42, 135b874ddecSLior David WMI_PXMT_SNR2_RANGE_CFG_CMDID = 0x43, 1366a363e8aSAhmad Masri WMI_RADAR_GENERAL_CONFIG_CMDID = 0x100, 1376a363e8aSAhmad Masri WMI_RADAR_CONFIG_SELECT_CMDID = 0x101, 1386a363e8aSAhmad Masri WMI_RADAR_PARAMS_CONFIG_CMDID = 0x102, 1396a363e8aSAhmad Masri WMI_RADAR_SET_MODE_CMDID = 0x103, 1406a363e8aSAhmad Masri WMI_RADAR_CONTROL_CMDID = 0x104, 1416a363e8aSAhmad Masri WMI_RADAR_PCI_CONTROL_CMDID = 0x105, 142b874ddecSLior David WMI_MEM_READ_CMDID = 0x800, 143b874ddecSLior David WMI_MEM_WR_CMDID = 0x801, 144b874ddecSLior David WMI_ECHO_CMDID = 0x803, 145b874ddecSLior David WMI_DEEP_ECHO_CMDID = 0x804, 146b874ddecSLior David WMI_CONFIG_MAC_CMDID = 0x805, 147761f8e4dSLazar Alexei /* deprecated */ 148b874ddecSLior David WMI_CONFIG_PHY_DEBUG_CMDID = 0x806, 149b874ddecSLior David WMI_ADD_DEBUG_TX_PCKT_CMDID = 0x808, 150b874ddecSLior David WMI_PHY_GET_STATISTICS_CMDID = 0x809, 151761f8e4dSLazar Alexei /* deprecated */ 152b874ddecSLior David WMI_FS_TUNE_CMDID = 0x80A, 153761f8e4dSLazar Alexei /* deprecated */ 154b874ddecSLior David WMI_CORR_MEASURE_CMDID = 0x80B, 155b874ddecSLior David WMI_READ_RSSI_CMDID = 0x80C, 156b874ddecSLior David WMI_TEMP_SENSE_CMDID = 0x80E, 157b874ddecSLior David WMI_DC_CALIB_CMDID = 0x80F, 158761f8e4dSLazar Alexei /* deprecated */ 159b874ddecSLior David WMI_SEND_TONE_CMDID = 0x810, 160761f8e4dSLazar Alexei /* deprecated */ 161b874ddecSLior David WMI_IQ_TX_CALIB_CMDID = 0x811, 162761f8e4dSLazar Alexei /* deprecated */ 163b874ddecSLior David WMI_IQ_RX_CALIB_CMDID = 0x812, 164b874ddecSLior David WMI_SET_WORK_MODE_CMDID = 0x815, 165b874ddecSLior David WMI_LO_LEAKAGE_CALIB_CMDID = 0x816, 166761f8e4dSLazar Alexei WMI_LO_POWER_CALIB_FROM_OTP_CMDID = 0x817, 167b874ddecSLior David WMI_SILENT_RSSI_CALIB_CMDID = 0x81D, 168761f8e4dSLazar Alexei /* deprecated */ 169b874ddecSLior David WMI_RF_RX_TEST_CMDID = 0x81E, 170b874ddecSLior David WMI_CFG_RX_CHAIN_CMDID = 0x820, 171b874ddecSLior David WMI_VRING_CFG_CMDID = 0x821, 172b874ddecSLior David WMI_BCAST_VRING_CFG_CMDID = 0x822, 17396c93589SGidon Studinski WMI_RING_BA_EN_CMDID = 0x823, 17496c93589SGidon Studinski WMI_RING_BA_DIS_CMDID = 0x824, 175b874ddecSLior David WMI_RCP_ADDBA_RESP_CMDID = 0x825, 176b874ddecSLior David WMI_RCP_DELBA_CMDID = 0x826, 177b874ddecSLior David WMI_SET_SSID_CMDID = 0x827, 178b874ddecSLior David WMI_GET_SSID_CMDID = 0x828, 179b874ddecSLior David WMI_SET_PCP_CHANNEL_CMDID = 0x829, 180b874ddecSLior David WMI_GET_PCP_CHANNEL_CMDID = 0x82A, 181b874ddecSLior David WMI_SW_TX_REQ_CMDID = 0x82B, 1826a363e8aSAhmad Masri /* Event is shared between WMI_SW_TX_REQ_CMDID and 1836a363e8aSAhmad Masri * WMI_SW_TX_REQ_EXT_CMDID 1846a363e8aSAhmad Masri */ 1856a363e8aSAhmad Masri WMI_SW_TX_REQ_EXT_CMDID = 0x82C, 186b874ddecSLior David WMI_MLME_PUSH_CMDID = 0x835, 187b874ddecSLior David WMI_BEAMFORMING_MGMT_CMDID = 0x836, 188b874ddecSLior David WMI_BF_TXSS_MGMT_CMDID = 0x837, 189b874ddecSLior David WMI_BF_SM_MGMT_CMDID = 0x838, 190b874ddecSLior David WMI_BF_RXSS_MGMT_CMDID = 0x839, 191b874ddecSLior David WMI_BF_TRIG_CMDID = 0x83A, 19296c93589SGidon Studinski WMI_RCP_ADDBA_RESP_EDMA_CMDID = 0x83B, 1930163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_WRITE_CMDID = 0x842, 1940163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_READ_CMDID = 0x843, 1954315a74aSDedy Lansky WMI_SET_LINK_MONITOR_CMDID = 0x845, 196b874ddecSLior David WMI_SET_SECTORS_CMDID = 0x849, 197b874ddecSLior David WMI_MAINTAIN_PAUSE_CMDID = 0x850, 198b874ddecSLior David WMI_MAINTAIN_RESUME_CMDID = 0x851, 199b874ddecSLior David WMI_RS_MGMT_CMDID = 0x852, 200b874ddecSLior David WMI_RF_MGMT_CMDID = 0x853, 201761f8e4dSLazar Alexei WMI_RF_XPM_READ_CMDID = 0x856, 202761f8e4dSLazar Alexei WMI_RF_XPM_WRITE_CMDID = 0x857, 20310d599adSMaya Erez WMI_LED_CFG_CMDID = 0x858, 204761f8e4dSLazar Alexei WMI_SET_CONNECT_SNR_THR_CMDID = 0x85B, 205761f8e4dSLazar Alexei WMI_SET_ACTIVE_SILENT_RSSI_TABLE_CMDID = 0x85C, 206761f8e4dSLazar Alexei WMI_RF_PWR_ON_DELAY_CMDID = 0x85D, 207761f8e4dSLazar Alexei WMI_SET_HIGH_POWER_TABLE_PARAMS_CMDID = 0x85E, 2088a4fa214SAhmad Masri WMI_FIXED_SCHEDULING_UL_CONFIG_CMDID = 0x85F, 2092be7d22fSVladimir Kondratiev /* Performance monitoring commands */ 210b874ddecSLior David WMI_BF_CTRL_CMDID = 0x862, 211b874ddecSLior David WMI_NOTIFY_REQ_CMDID = 0x863, 212b874ddecSLior David WMI_GET_STATUS_CMDID = 0x864, 2130163b031SMaya Erez WMI_GET_RF_STATUS_CMDID = 0x866, 2140163b031SMaya Erez WMI_GET_BASEBAND_TYPE_CMDID = 0x867, 2158a4fa214SAhmad Masri WMI_VRING_SWITCH_TIMING_CONFIG_CMDID = 0x868, 216b874ddecSLior David WMI_UNIT_TEST_CMDID = 0x900, 217b874ddecSLior David WMI_FLASH_READ_CMDID = 0x902, 218b874ddecSLior David WMI_FLASH_WRITE_CMDID = 0x903, 2190163b031SMaya Erez /* Power management */ 220fe9ee51eSMaya Erez WMI_TRAFFIC_SUSPEND_CMDID = 0x904, 2210163b031SMaya Erez WMI_TRAFFIC_RESUME_CMDID = 0x905, 222b8023177SVladimir Kondratiev /* P2P */ 223b874ddecSLior David WMI_P2P_CFG_CMDID = 0x910, 224b874ddecSLior David WMI_PORT_ALLOCATE_CMDID = 0x911, 225b874ddecSLior David WMI_PORT_DELETE_CMDID = 0x912, 226b874ddecSLior David WMI_POWER_MGMT_CFG_CMDID = 0x913, 227b874ddecSLior David WMI_START_LISTEN_CMDID = 0x914, 228b874ddecSLior David WMI_START_SEARCH_CMDID = 0x915, 229b874ddecSLior David WMI_DISCOVERY_START_CMDID = 0x916, 230b874ddecSLior David WMI_DISCOVERY_STOP_CMDID = 0x917, 231b874ddecSLior David WMI_PCP_START_CMDID = 0x918, 232b874ddecSLior David WMI_PCP_STOP_CMDID = 0x919, 233b874ddecSLior David WMI_GET_PCP_FACTOR_CMDID = 0x91B, 2340163b031SMaya Erez /* Power Save Configuration Commands */ 2350163b031SMaya Erez WMI_PS_DEV_PROFILE_CFG_CMDID = 0x91C, 236b5aeff16SDedy Lansky WMI_RS_ENABLE_CMDID = 0x91E, 237b5aeff16SDedy Lansky WMI_RS_CFG_EX_CMDID = 0x91F, 238b5aeff16SDedy Lansky WMI_GET_DETAILED_RS_RES_EX_CMDID = 0x920, 239b5aeff16SDedy Lansky /* deprecated */ 2400163b031SMaya Erez WMI_RS_CFG_CMDID = 0x921, 241b5aeff16SDedy Lansky /* deprecated */ 24208989f96SLior David WMI_GET_DETAILED_RS_RES_CMDID = 0x922, 24308989f96SLior David WMI_AOA_MEAS_CMDID = 0x923, 244a52fb913SLior David WMI_BRP_SET_ANT_LIMIT_CMDID = 0x924, 245cbf795c1SLior David WMI_SET_MGMT_RETRY_LIMIT_CMDID = 0x930, 246cbf795c1SLior David WMI_GET_MGMT_RETRY_LIMIT_CMDID = 0x931, 247849a564bSDedy Lansky WMI_NEW_STA_CMDID = 0x935, 248849a564bSDedy Lansky WMI_DEL_STA_CMDID = 0x936, 24990ffabb0SDedy Lansky WMI_SET_THERMAL_THROTTLING_CFG_CMDID = 0x940, 25090ffabb0SDedy Lansky WMI_GET_THERMAL_THROTTLING_CFG_CMDID = 0x941, 251761f8e4dSLazar Alexei /* Read Power Save profile type */ 252761f8e4dSLazar Alexei WMI_PS_DEV_PROFILE_CFG_READ_CMDID = 0x942, 2538a4fa214SAhmad Masri WMI_TSF_SYNC_CMDID = 0x973, 25408989f96SLior David WMI_TOF_SESSION_START_CMDID = 0x991, 25508989f96SLior David WMI_TOF_GET_CAPABILITIES_CMDID = 0x992, 25608989f96SLior David WMI_TOF_SET_LCR_CMDID = 0x993, 25708989f96SLior David WMI_TOF_SET_LCI_CMDID = 0x994, 258761f8e4dSLazar Alexei WMI_TOF_CFG_RESPONDER_CMDID = 0x996, 2598ae5d62cSLior David WMI_TOF_SET_TX_RX_OFFSET_CMDID = 0x997, 2608ae5d62cSLior David WMI_TOF_GET_TX_RX_OFFSET_CMDID = 0x998, 261761f8e4dSLazar Alexei WMI_TOF_CHANNEL_INFO_CMDID = 0x999, 262cbf795c1SLior David WMI_GET_RF_SECTOR_PARAMS_CMDID = 0x9A0, 263cbf795c1SLior David WMI_SET_RF_SECTOR_PARAMS_CMDID = 0x9A1, 264cbf795c1SLior David WMI_GET_SELECTED_RF_SECTOR_INDEX_CMDID = 0x9A2, 265cbf795c1SLior David WMI_SET_SELECTED_RF_SECTOR_INDEX_CMDID = 0x9A3, 266cbf795c1SLior David WMI_SET_RF_SECTOR_ON_CMDID = 0x9A4, 2678ae5d62cSLior David WMI_PRIO_TX_SECTORS_ORDER_CMDID = 0x9A5, 2688ae5d62cSLior David WMI_PRIO_TX_SECTORS_NUMBER_CMDID = 0x9A6, 2698ae5d62cSLior David WMI_PRIO_TX_SECTORS_SET_DEFAULT_CFG_CMDID = 0x9A7, 270b5aeff16SDedy Lansky /* deprecated */ 2718a4fa214SAhmad Masri WMI_BF_CONTROL_CMDID = 0x9AA, 272b5aeff16SDedy Lansky WMI_BF_CONTROL_EX_CMDID = 0x9AB, 27396c93589SGidon Studinski WMI_TX_STATUS_RING_ADD_CMDID = 0x9C0, 27496c93589SGidon Studinski WMI_RX_STATUS_RING_ADD_CMDID = 0x9C1, 27596c93589SGidon Studinski WMI_TX_DESC_RING_ADD_CMDID = 0x9C2, 27696c93589SGidon Studinski WMI_RX_DESC_RING_ADD_CMDID = 0x9C3, 27796c93589SGidon Studinski WMI_BCAST_DESC_RING_ADD_CMDID = 0x9C4, 27896c93589SGidon Studinski WMI_CFG_DEF_RX_OFFLOAD_CMDID = 0x9C5, 279761f8e4dSLazar Alexei WMI_SCHEDULING_SCHEME_CMDID = 0xA01, 280761f8e4dSLazar Alexei WMI_FIXED_SCHEDULING_CONFIG_CMDID = 0xA02, 281761f8e4dSLazar Alexei WMI_ENABLE_FIXED_SCHEDULING_CMDID = 0xA03, 282761f8e4dSLazar Alexei WMI_SET_MULTI_DIRECTED_OMNIS_CONFIG_CMDID = 0xA04, 283761f8e4dSLazar Alexei WMI_SET_LONG_RANGE_CONFIG_CMDID = 0xA05, 2848a4fa214SAhmad Masri WMI_GET_ASSOC_LIST_CMDID = 0xA06, 2858a4fa214SAhmad Masri WMI_GET_CCA_INDICATIONS_CMDID = 0xA07, 2868a4fa214SAhmad Masri WMI_SET_CCA_INDICATIONS_BI_AVG_NUM_CMDID = 0xA08, 2878a4fa214SAhmad Masri WMI_INTERNAL_FW_IOCTL_CMDID = 0xA0B, 288b5aeff16SDedy Lansky WMI_LINK_STATS_CMDID = 0xA0C, 289b5aeff16SDedy Lansky WMI_SET_GRANT_MCS_CMDID = 0xA0E, 290b5aeff16SDedy Lansky WMI_SET_AP_SLOT_SIZE_CMDID = 0xA0F, 291b5aeff16SDedy Lansky WMI_SET_VRING_PRIORITY_WEIGHT_CMDID = 0xA10, 292b5aeff16SDedy Lansky WMI_SET_VRING_PRIORITY_CMDID = 0xA11, 29373a7d1e3SAlexei Avshalom Lazar WMI_RBUFCAP_CFG_CMDID = 0xA12, 2949b586118STzahi Sabo WMI_TEMP_SENSE_ALL_CMDID = 0xA13, 295b874ddecSLior David WMI_SET_MAC_ADDRESS_CMDID = 0xF003, 296b874ddecSLior David WMI_ABORT_SCAN_CMDID = 0xF007, 297b874ddecSLior David WMI_SET_PROMISCUOUS_MODE_CMDID = 0xF041, 298761f8e4dSLazar Alexei /* deprecated */ 299b874ddecSLior David WMI_GET_PMK_CMDID = 0xF048, 300b874ddecSLior David WMI_SET_PASSPHRASE_CMDID = 0xF049, 301761f8e4dSLazar Alexei /* deprecated */ 302b874ddecSLior David WMI_SEND_ASSOC_RES_CMDID = 0xF04A, 303761f8e4dSLazar Alexei /* deprecated */ 304b874ddecSLior David WMI_SET_ASSOC_REQ_RELAY_CMDID = 0xF04B, 305b874ddecSLior David WMI_MAC_ADDR_REQ_CMDID = 0xF04D, 306b874ddecSLior David WMI_FW_VER_CMDID = 0xF04E, 307b874ddecSLior David WMI_PMC_CMDID = 0xF04F, 3082be7d22fSVladimir Kondratiev }; 3092be7d22fSVladimir Kondratiev 310b874ddecSLior David /* WMI_CONNECT_CMDID */ 3112be7d22fSVladimir Kondratiev enum wmi_network_type { 3122be7d22fSVladimir Kondratiev WMI_NETTYPE_INFRA = 0x01, 3132be7d22fSVladimir Kondratiev WMI_NETTYPE_ADHOC = 0x02, 3142be7d22fSVladimir Kondratiev WMI_NETTYPE_ADHOC_CREATOR = 0x04, 3152be7d22fSVladimir Kondratiev WMI_NETTYPE_AP = 0x10, 3162be7d22fSVladimir Kondratiev WMI_NETTYPE_P2P = 0x20, 317b874ddecSLior David /* PCIE over 60g */ 318b874ddecSLior David WMI_NETTYPE_WBE = 0x40, 3192be7d22fSVladimir Kondratiev }; 3202be7d22fSVladimir Kondratiev 3212be7d22fSVladimir Kondratiev enum wmi_dot11_auth_mode { 3222be7d22fSVladimir Kondratiev WMI_AUTH11_OPEN = 0x01, 3232be7d22fSVladimir Kondratiev WMI_AUTH11_SHARED = 0x02, 3242be7d22fSVladimir Kondratiev WMI_AUTH11_LEAP = 0x04, 3252be7d22fSVladimir Kondratiev WMI_AUTH11_WSC = 0x08, 3262be7d22fSVladimir Kondratiev }; 3272be7d22fSVladimir Kondratiev 3282be7d22fSVladimir Kondratiev enum wmi_auth_mode { 3292be7d22fSVladimir Kondratiev WMI_AUTH_NONE = 0x01, 3302be7d22fSVladimir Kondratiev WMI_AUTH_WPA = 0x02, 3312be7d22fSVladimir Kondratiev WMI_AUTH_WPA2 = 0x04, 3322be7d22fSVladimir Kondratiev WMI_AUTH_WPA_PSK = 0x08, 3332be7d22fSVladimir Kondratiev WMI_AUTH_WPA2_PSK = 0x10, 3342be7d22fSVladimir Kondratiev WMI_AUTH_WPA_CCKM = 0x20, 3352be7d22fSVladimir Kondratiev WMI_AUTH_WPA2_CCKM = 0x40, 3362be7d22fSVladimir Kondratiev }; 3372be7d22fSVladimir Kondratiev 3382be7d22fSVladimir Kondratiev enum wmi_crypto_type { 3392be7d22fSVladimir Kondratiev WMI_CRYPT_NONE = 0x01, 3402be7d22fSVladimir Kondratiev WMI_CRYPT_AES_GCMP = 0x20, 3412be7d22fSVladimir Kondratiev }; 3422be7d22fSVladimir Kondratiev 3432be7d22fSVladimir Kondratiev enum wmi_connect_ctrl_flag_bits { 344b874ddecSLior David WMI_CONNECT_ASSOC_POLICY_USER = 0x01, 345b874ddecSLior David WMI_CONNECT_SEND_REASSOC = 0x02, 346b874ddecSLior David WMI_CONNECT_IGNORE_WPA_GROUP_CIPHER = 0x04, 347b874ddecSLior David WMI_CONNECT_PROFILE_MATCH_DONE = 0x08, 348b874ddecSLior David WMI_CONNECT_IGNORE_AAC_BEACON = 0x10, 349b874ddecSLior David WMI_CONNECT_CSA_FOLLOW_BSS = 0x20, 350b874ddecSLior David WMI_CONNECT_DO_WPA_OFFLOAD = 0x40, 351b874ddecSLior David WMI_CONNECT_DO_NOT_DEAUTH = 0x80, 3522be7d22fSVladimir Kondratiev }; 3532be7d22fSVladimir Kondratiev 3542be7d22fSVladimir Kondratiev #define WMI_MAX_SSID_LEN (32) 3552be7d22fSVladimir Kondratiev 3569abe3e30SAlexei Avshalom Lazar enum wmi_channel { 3579abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_1 = 0x00, 3589abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_2 = 0x01, 3599abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_3 = 0x02, 3609abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_4 = 0x03, 3619abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_5 = 0x04, 3629abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_6 = 0x05, 3639abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_9 = 0x06, 3649abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_10 = 0x07, 3659abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_11 = 0x08, 3669abe3e30SAlexei Avshalom Lazar WMI_CHANNEL_12 = 0x09, 3679abe3e30SAlexei Avshalom Lazar }; 3689abe3e30SAlexei Avshalom Lazar 369b874ddecSLior David /* WMI_CONNECT_CMDID */ 3702be7d22fSVladimir Kondratiev struct wmi_connect_cmd { 3712be7d22fSVladimir Kondratiev u8 network_type; 3722be7d22fSVladimir Kondratiev u8 dot11_auth_mode; 3732be7d22fSVladimir Kondratiev u8 auth_mode; 3742be7d22fSVladimir Kondratiev u8 pairwise_crypto_type; 3752be7d22fSVladimir Kondratiev u8 pairwise_crypto_len; 3762be7d22fSVladimir Kondratiev u8 group_crypto_type; 3772be7d22fSVladimir Kondratiev u8 group_crypto_len; 3782be7d22fSVladimir Kondratiev u8 ssid_len; 3792be7d22fSVladimir Kondratiev u8 ssid[WMI_MAX_SSID_LEN]; 3809abe3e30SAlexei Avshalom Lazar /* enum wmi_channel WMI_CHANNEL_1..WMI_CHANNEL_6; for EDMG this is 3819abe3e30SAlexei Avshalom Lazar * the primary channel number 3829abe3e30SAlexei Avshalom Lazar */ 3832be7d22fSVladimir Kondratiev u8 channel; 3849abe3e30SAlexei Avshalom Lazar /* enum wmi_channel WMI_CHANNEL_9..WMI_CHANNEL_12 */ 3859abe3e30SAlexei Avshalom Lazar u8 edmg_channel; 3862be7d22fSVladimir Kondratiev u8 bssid[WMI_MAC_LEN]; 3872be7d22fSVladimir Kondratiev __le32 ctrl_flags; 3882be7d22fSVladimir Kondratiev u8 dst_mac[WMI_MAC_LEN]; 3892be7d22fSVladimir Kondratiev u8 reserved1[2]; 3902be7d22fSVladimir Kondratiev } __packed; 3912be7d22fSVladimir Kondratiev 392b874ddecSLior David /* WMI_DISCONNECT_STA_CMDID */ 393b8023177SVladimir Kondratiev struct wmi_disconnect_sta_cmd { 394b8023177SVladimir Kondratiev u8 dst_mac[WMI_MAC_LEN]; 395b8023177SVladimir Kondratiev __le16 disconnect_reason; 396b8023177SVladimir Kondratiev } __packed; 3972be7d22fSVladimir Kondratiev 3982be7d22fSVladimir Kondratiev #define WMI_MAX_KEY_INDEX (3) 3992be7d22fSVladimir Kondratiev #define WMI_MAX_KEY_LEN (32) 4002be7d22fSVladimir Kondratiev #define WMI_PASSPHRASE_LEN (64) 4012be7d22fSVladimir Kondratiev 402b874ddecSLior David /* WMI_SET_PASSPHRASE_CMDID */ 4032be7d22fSVladimir Kondratiev struct wmi_set_passphrase_cmd { 4042be7d22fSVladimir Kondratiev u8 ssid[WMI_MAX_SSID_LEN]; 4052be7d22fSVladimir Kondratiev u8 passphrase[WMI_PASSPHRASE_LEN]; 4062be7d22fSVladimir Kondratiev u8 ssid_len; 4072be7d22fSVladimir Kondratiev u8 passphrase_len; 4082be7d22fSVladimir Kondratiev } __packed; 4092be7d22fSVladimir Kondratiev 410b874ddecSLior David /* WMI_ADD_CIPHER_KEY_CMDID */ 4112be7d22fSVladimir Kondratiev enum wmi_key_usage { 412b874ddecSLior David WMI_KEY_USE_PAIRWISE = 0x00, 413b874ddecSLior David WMI_KEY_USE_RX_GROUP = 0x01, 414b874ddecSLior David WMI_KEY_USE_TX_GROUP = 0x02, 41542fe1e51SAhmad Masri WMI_KEY_USE_STORE_PTK = 0x03, 41642fe1e51SAhmad Masri WMI_KEY_USE_APPLY_PTK = 0x04, 4172be7d22fSVladimir Kondratiev }; 4182be7d22fSVladimir Kondratiev 4192be7d22fSVladimir Kondratiev struct wmi_add_cipher_key_cmd { 4202be7d22fSVladimir Kondratiev u8 key_index; 4212be7d22fSVladimir Kondratiev u8 key_type; 422b874ddecSLior David /* enum wmi_key_usage */ 423b874ddecSLior David u8 key_usage; 4242be7d22fSVladimir Kondratiev u8 key_len; 425b874ddecSLior David /* key replay sequence counter */ 426b874ddecSLior David u8 key_rsc[8]; 4272be7d22fSVladimir Kondratiev u8 key[WMI_MAX_KEY_LEN]; 428b874ddecSLior David /* Additional Key Control information */ 429b874ddecSLior David u8 key_op_ctrl; 4302be7d22fSVladimir Kondratiev u8 mac[WMI_MAC_LEN]; 4312be7d22fSVladimir Kondratiev } __packed; 4322be7d22fSVladimir Kondratiev 433b874ddecSLior David /* WMI_DELETE_CIPHER_KEY_CMDID */ 4342be7d22fSVladimir Kondratiev struct wmi_delete_cipher_key_cmd { 4352be7d22fSVladimir Kondratiev u8 key_index; 4362be7d22fSVladimir Kondratiev u8 mac[WMI_MAC_LEN]; 4372be7d22fSVladimir Kondratiev } __packed; 4382be7d22fSVladimir Kondratiev 439b874ddecSLior David /* WMI_START_SCAN_CMDID 4402be7d22fSVladimir Kondratiev * 4412be7d22fSVladimir Kondratiev * Start L1 scan operation 4422be7d22fSVladimir Kondratiev * 4432be7d22fSVladimir Kondratiev * Returned events: 4442be7d22fSVladimir Kondratiev * - WMI_RX_MGMT_PACKET_EVENTID - for every probe resp. 4452be7d22fSVladimir Kondratiev * - WMI_SCAN_COMPLETE_EVENTID 4462be7d22fSVladimir Kondratiev */ 4472be7d22fSVladimir Kondratiev enum wmi_scan_type { 448b874ddecSLior David WMI_ACTIVE_SCAN = 0x00, 449b874ddecSLior David WMI_SHORT_SCAN = 0x01, 450b874ddecSLior David WMI_PASSIVE_SCAN = 0x02, 451b874ddecSLior David WMI_DIRECT_SCAN = 0x03, 452b874ddecSLior David WMI_LONG_SCAN = 0x04, 4532be7d22fSVladimir Kondratiev }; 4542be7d22fSVladimir Kondratiev 455b874ddecSLior David /* WMI_START_SCAN_CMDID */ 4562be7d22fSVladimir Kondratiev struct wmi_start_scan_cmd { 457b874ddecSLior David u8 direct_scan_mac_addr[WMI_MAC_LEN]; 4580163b031SMaya Erez /* run scan with discovery beacon. Relevant for ACTIVE scan only. */ 45974997a53SLior David u8 discovery_mode; 46074997a53SLior David u8 reserved; 461b874ddecSLior David /* Max duration in the home channel(ms) */ 462b874ddecSLior David __le32 dwell_time; 463b874ddecSLior David /* Time interval between scans (ms) */ 464b874ddecSLior David __le32 force_scan_interval; 465b874ddecSLior David /* enum wmi_scan_type */ 466b874ddecSLior David u8 scan_type; 467b874ddecSLior David /* how many channels follow */ 468b874ddecSLior David u8 num_channels; 469b874ddecSLior David /* channels ID's: 470b874ddecSLior David * 0 - 58320 MHz 471b874ddecSLior David * 1 - 60480 MHz 472b874ddecSLior David * 2 - 62640 MHz 473b874ddecSLior David */ 4742be7d22fSVladimir Kondratiev struct { 4752be7d22fSVladimir Kondratiev u8 channel; 4762be7d22fSVladimir Kondratiev u8 reserved; 47704a4d341SArnd Bergmann } channel_list[]; 4782be7d22fSVladimir Kondratiev } __packed; 4792be7d22fSVladimir Kondratiev 480a5dc6883SDedy Lansky #define WMI_MAX_PNO_SSID_NUM (16) 481a5dc6883SDedy Lansky #define WMI_MAX_CHANNEL_NUM (6) 482a5dc6883SDedy Lansky #define WMI_MAX_PLANS_NUM (2) 483a5dc6883SDedy Lansky 484a5dc6883SDedy Lansky /* WMI_START_SCHED_SCAN_CMDID */ 485a5dc6883SDedy Lansky struct wmi_sched_scan_ssid_match { 486a5dc6883SDedy Lansky u8 ssid_len; 487a5dc6883SDedy Lansky u8 ssid[WMI_MAX_SSID_LEN]; 488a5dc6883SDedy Lansky s8 rssi_threshold; 489a5dc6883SDedy Lansky /* boolean */ 490a5dc6883SDedy Lansky u8 add_ssid_to_probe; 491a5dc6883SDedy Lansky u8 reserved; 492a5dc6883SDedy Lansky } __packed; 493a5dc6883SDedy Lansky 494a5dc6883SDedy Lansky /* WMI_START_SCHED_SCAN_CMDID */ 495a5dc6883SDedy Lansky struct wmi_sched_scan_plan { 496a5dc6883SDedy Lansky __le16 interval_sec; 497a5dc6883SDedy Lansky __le16 num_of_iterations; 498a5dc6883SDedy Lansky } __packed; 499a5dc6883SDedy Lansky 500a5dc6883SDedy Lansky /* WMI_START_SCHED_SCAN_CMDID */ 501a5dc6883SDedy Lansky struct wmi_start_sched_scan_cmd { 502a5dc6883SDedy Lansky struct wmi_sched_scan_ssid_match ssid_for_match[WMI_MAX_PNO_SSID_NUM]; 503a5dc6883SDedy Lansky u8 num_of_ssids; 504a5dc6883SDedy Lansky s8 min_rssi_threshold; 505a5dc6883SDedy Lansky u8 channel_list[WMI_MAX_CHANNEL_NUM]; 506a5dc6883SDedy Lansky u8 num_of_channels; 507a5dc6883SDedy Lansky u8 reserved; 508a5dc6883SDedy Lansky __le16 initial_delay_sec; 509a5dc6883SDedy Lansky struct wmi_sched_scan_plan scan_plans[WMI_MAX_PLANS_NUM]; 510a5dc6883SDedy Lansky } __packed; 511a5dc6883SDedy Lansky 512b5aeff16SDedy Lansky /* WMI_FT_AUTH_CMDID */ 513b5aeff16SDedy Lansky struct wmi_ft_auth_cmd { 514b5aeff16SDedy Lansky u8 bssid[WMI_MAC_LEN]; 515b5aeff16SDedy Lansky /* enum wmi_channel */ 516b5aeff16SDedy Lansky u8 channel; 517b5aeff16SDedy Lansky /* enum wmi_channel */ 518b5aeff16SDedy Lansky u8 edmg_channel; 519b5aeff16SDedy Lansky u8 reserved[4]; 520b5aeff16SDedy Lansky } __packed; 521b5aeff16SDedy Lansky 522b5aeff16SDedy Lansky /* WMI_FT_REASSOC_CMDID */ 523b5aeff16SDedy Lansky struct wmi_ft_reassoc_cmd { 524b5aeff16SDedy Lansky u8 bssid[WMI_MAC_LEN]; 525b5aeff16SDedy Lansky u8 reserved[2]; 526b5aeff16SDedy Lansky } __packed; 527b5aeff16SDedy Lansky 528b5aeff16SDedy Lansky /* WMI_UPDATE_FT_IES_CMDID */ 529b5aeff16SDedy Lansky struct wmi_update_ft_ies_cmd { 530b5aeff16SDedy Lansky /* Length of the FT IEs */ 531b5aeff16SDedy Lansky __le16 ie_len; 532b5aeff16SDedy Lansky u8 reserved[2]; 533104f3d95SGustavo A. R. Silva u8 ie_info[]; 534b5aeff16SDedy Lansky } __packed; 535b5aeff16SDedy Lansky 536b874ddecSLior David /* WMI_SET_PROBED_SSID_CMDID */ 537b8023177SVladimir Kondratiev #define MAX_PROBED_SSID_INDEX (3) 5382be7d22fSVladimir Kondratiev 5392be7d22fSVladimir Kondratiev enum wmi_ssid_flag { 540b874ddecSLior David /* disables entry */ 541b874ddecSLior David WMI_SSID_FLAG_DISABLE = 0x00, 542b874ddecSLior David /* probes specified ssid */ 543b874ddecSLior David WMI_SSID_FLAG_SPECIFIC = 0x01, 544b874ddecSLior David /* probes for any ssid */ 545b874ddecSLior David WMI_SSID_FLAG_ANY = 0x02, 5462be7d22fSVladimir Kondratiev }; 5472be7d22fSVladimir Kondratiev 5482be7d22fSVladimir Kondratiev struct wmi_probed_ssid_cmd { 549b874ddecSLior David /* 0 to MAX_PROBED_SSID_INDEX */ 550b874ddecSLior David u8 entry_index; 551b874ddecSLior David /* enum wmi_ssid_flag */ 552b874ddecSLior David u8 flag; 5532be7d22fSVladimir Kondratiev u8 ssid_len; 5542be7d22fSVladimir Kondratiev u8 ssid[WMI_MAX_SSID_LEN]; 5552be7d22fSVladimir Kondratiev } __packed; 5562be7d22fSVladimir Kondratiev 557b874ddecSLior David /* WMI_SET_APPIE_CMDID 5582be7d22fSVladimir Kondratiev * Add Application specified IE to a management frame 5592be7d22fSVladimir Kondratiev */ 560b8023177SVladimir Kondratiev #define WMI_MAX_IE_LEN (1024) 561b8023177SVladimir Kondratiev 562b874ddecSLior David /* Frame Types */ 563b8023177SVladimir Kondratiev enum wmi_mgmt_frame_type { 564b874ddecSLior David WMI_FRAME_BEACON = 0x00, 565b874ddecSLior David WMI_FRAME_PROBE_REQ = 0x01, 566b874ddecSLior David WMI_FRAME_PROBE_RESP = 0x02, 567b874ddecSLior David WMI_FRAME_ASSOC_REQ = 0x03, 568b874ddecSLior David WMI_FRAME_ASSOC_RESP = 0x04, 569b874ddecSLior David WMI_NUM_MGMT_FRAME = 0x05, 570b8023177SVladimir Kondratiev }; 571b8023177SVladimir Kondratiev 5722be7d22fSVladimir Kondratiev struct wmi_set_appie_cmd { 573b874ddecSLior David /* enum wmi_mgmt_frame_type */ 574b874ddecSLior David u8 mgmt_frm_type; 5752be7d22fSVladimir Kondratiev u8 reserved; 576b874ddecSLior David /* Length of the IE to be added to MGMT frame */ 577b874ddecSLior David __le16 ie_len; 578104f3d95SGustavo A. R. Silva u8 ie_info[]; 5792be7d22fSVladimir Kondratiev } __packed; 5802be7d22fSVladimir Kondratiev 581b874ddecSLior David /* WMI_PXMT_RANGE_CFG_CMDID */ 5822be7d22fSVladimir Kondratiev struct wmi_pxmt_range_cfg_cmd { 5832be7d22fSVladimir Kondratiev u8 dst_mac[WMI_MAC_LEN]; 5842be7d22fSVladimir Kondratiev __le16 range; 5852be7d22fSVladimir Kondratiev } __packed; 5862be7d22fSVladimir Kondratiev 587b874ddecSLior David /* WMI_PXMT_SNR2_RANGE_CFG_CMDID */ 5882be7d22fSVladimir Kondratiev struct wmi_pxmt_snr2_range_cfg_cmd { 589b874ddecSLior David s8 snr2range_arr[2]; 5902be7d22fSVladimir Kondratiev } __packed; 5912be7d22fSVladimir Kondratiev 5926a363e8aSAhmad Masri /* WMI_RADAR_GENERAL_CONFIG_CMDID */ 5936a363e8aSAhmad Masri struct wmi_radar_general_config_cmd { 5946a363e8aSAhmad Masri /* Number of pulses (CIRs) in FW FIFO to initiate pulses transfer 5956a363e8aSAhmad Masri * from FW to Host 5966a363e8aSAhmad Masri */ 5976a363e8aSAhmad Masri __le32 fifo_watermark; 5986a363e8aSAhmad Masri /* In unit of us, in the range [100, 1000000] */ 5996a363e8aSAhmad Masri __le32 t_burst; 6006a363e8aSAhmad Masri /* Valid in the range [1, 32768], 0xFFFF means infinite */ 6016a363e8aSAhmad Masri __le32 n_bursts; 6026a363e8aSAhmad Masri /* In unit of 330Mhz clk, in the range [4, 2000]*330 */ 6036a363e8aSAhmad Masri __le32 t_pulse; 6046a363e8aSAhmad Masri /* In the range of [1,4096] */ 6056a363e8aSAhmad Masri __le16 n_pulses; 6066a363e8aSAhmad Masri /* Number of taps after cTap per CIR */ 6076a363e8aSAhmad Masri __le16 n_samples; 6086a363e8aSAhmad Masri /* Offset from the main tap (0 = zero-distance). In the range of [0, 6096a363e8aSAhmad Masri * 255] 6106a363e8aSAhmad Masri */ 6116a363e8aSAhmad Masri u8 first_sample_offset; 6126a363e8aSAhmad Masri /* Number of Pulses to average, 1, 2, 4, 8 */ 6136a363e8aSAhmad Masri u8 pulses_to_avg; 6146a363e8aSAhmad Masri /* Number of adjacent taps to average, 1, 2, 4, 8 */ 6156a363e8aSAhmad Masri u8 samples_to_avg; 6166a363e8aSAhmad Masri /* The index to config general params */ 6176a363e8aSAhmad Masri u8 general_index; 6186a363e8aSAhmad Masri u8 reserved[4]; 6196a363e8aSAhmad Masri } __packed; 6206a363e8aSAhmad Masri 6216a363e8aSAhmad Masri /* WMI_RADAR_CONFIG_SELECT_CMDID */ 6226a363e8aSAhmad Masri struct wmi_radar_config_select_cmd { 6236a363e8aSAhmad Masri /* Select the general params index to use */ 6246a363e8aSAhmad Masri u8 general_index; 6256a363e8aSAhmad Masri u8 reserved[3]; 6266a363e8aSAhmad Masri /* 0 means don't update burst_active_vector */ 6276a363e8aSAhmad Masri __le32 burst_active_vector; 6286a363e8aSAhmad Masri /* 0 means don't update pulse_active_vector */ 6296a363e8aSAhmad Masri __le32 pulse_active_vector; 6306a363e8aSAhmad Masri } __packed; 6316a363e8aSAhmad Masri 6326a363e8aSAhmad Masri /* WMI_RADAR_PARAMS_CONFIG_CMDID */ 6336a363e8aSAhmad Masri struct wmi_radar_params_config_cmd { 6346a363e8aSAhmad Masri /* The burst index selected to config */ 6356a363e8aSAhmad Masri u8 burst_index; 6366a363e8aSAhmad Masri /* 0-not active, 1-active */ 6376a363e8aSAhmad Masri u8 burst_en; 6386a363e8aSAhmad Masri /* The pulse index selected to config */ 6396a363e8aSAhmad Masri u8 pulse_index; 6406a363e8aSAhmad Masri /* 0-not active, 1-active */ 6416a363e8aSAhmad Masri u8 pulse_en; 6426a363e8aSAhmad Masri /* TX RF to use on current pulse */ 6436a363e8aSAhmad Masri u8 tx_rfc_idx; 6446a363e8aSAhmad Masri u8 tx_sector; 6456a363e8aSAhmad Masri /* Offset from calibrated value.(expected to be 0)(value is row in 6466a363e8aSAhmad Masri * Gain-LUT, not dB) 6476a363e8aSAhmad Masri */ 6486a363e8aSAhmad Masri s8 tx_rf_gain_comp; 6496a363e8aSAhmad Masri /* expected to be 0 */ 6506a363e8aSAhmad Masri s8 tx_bb_gain_comp; 6516a363e8aSAhmad Masri /* RX RF to use on current pulse */ 6526a363e8aSAhmad Masri u8 rx_rfc_idx; 6536a363e8aSAhmad Masri u8 rx_sector; 6546a363e8aSAhmad Masri /* Offset from calibrated value.(expected to be 0)(value is row in 6556a363e8aSAhmad Masri * Gain-LUT, not dB) 6566a363e8aSAhmad Masri */ 6576a363e8aSAhmad Masri s8 rx_rf_gain_comp; 6586a363e8aSAhmad Masri /* Value in dB.(expected to be 0) */ 6596a363e8aSAhmad Masri s8 rx_bb_gain_comp; 6606a363e8aSAhmad Masri /* Offset from calibrated value.(expected to be 0) */ 6616a363e8aSAhmad Masri s8 rx_timing_offset; 6626a363e8aSAhmad Masri u8 reserved[3]; 6636a363e8aSAhmad Masri } __packed; 6646a363e8aSAhmad Masri 6656a363e8aSAhmad Masri /* WMI_RADAR_SET_MODE_CMDID */ 6666a363e8aSAhmad Masri struct wmi_radar_set_mode_cmd { 6676a363e8aSAhmad Masri /* 0-disable/1-enable */ 6686a363e8aSAhmad Masri u8 enable; 6696a363e8aSAhmad Masri /* enum wmi_channel */ 6706a363e8aSAhmad Masri u8 channel; 6716a363e8aSAhmad Masri /* In the range of [0,7], 0xff means use default */ 6726a363e8aSAhmad Masri u8 tx_rfc_idx; 6736a363e8aSAhmad Masri /* In the range of [0,7], 0xff means use default */ 6746a363e8aSAhmad Masri u8 rx_rfc_idx; 6756a363e8aSAhmad Masri } __packed; 6766a363e8aSAhmad Masri 6776a363e8aSAhmad Masri /* WMI_RADAR_CONTROL_CMDID */ 6786a363e8aSAhmad Masri struct wmi_radar_control_cmd { 6796a363e8aSAhmad Masri /* 0-stop/1-start */ 6806a363e8aSAhmad Masri u8 start; 6816a363e8aSAhmad Masri u8 reserved[3]; 6826a363e8aSAhmad Masri } __packed; 6836a363e8aSAhmad Masri 6846a363e8aSAhmad Masri /* WMI_RADAR_PCI_CONTROL_CMDID */ 6856a363e8aSAhmad Masri struct wmi_radar_pci_control_cmd { 6866a363e8aSAhmad Masri /* pcie host buffer start address */ 6876a363e8aSAhmad Masri __le64 base_addr; 6886a363e8aSAhmad Masri /* pcie host control block address */ 6896a363e8aSAhmad Masri __le64 control_block_addr; 6906a363e8aSAhmad Masri /* pcie host buffer size */ 6916a363e8aSAhmad Masri __le32 buffer_size; 6926a363e8aSAhmad Masri __le32 reserved; 6936a363e8aSAhmad Masri } __packed; 6946a363e8aSAhmad Masri 695b874ddecSLior David /* WMI_RF_MGMT_CMDID */ 6962be7d22fSVladimir Kondratiev enum wmi_rf_mgmt_type { 697b874ddecSLior David WMI_RF_MGMT_W_DISABLE = 0x00, 698b874ddecSLior David WMI_RF_MGMT_W_ENABLE = 0x01, 699b874ddecSLior David WMI_RF_MGMT_GET_STATUS = 0x02, 7002be7d22fSVladimir Kondratiev }; 7012be7d22fSVladimir Kondratiev 7028a4fa214SAhmad Masri /* WMI_BF_CONTROL_CMDID */ 7038a4fa214SAhmad Masri enum wmi_bf_triggers { 7048a4fa214SAhmad Masri WMI_BF_TRIGGER_RS_MCS1_TH_FAILURE = 0x01, 7058a4fa214SAhmad Masri WMI_BF_TRIGGER_RS_MCS1_NO_BACK_FAILURE = 0x02, 7068a4fa214SAhmad Masri WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_TXOP = 0x04, 7078a4fa214SAhmad Masri WMI_BF_TRIGGER_MAX_BACK_FAILURE = 0x08, 7088a4fa214SAhmad Masri WMI_BF_TRIGGER_FW = 0x10, 7098a4fa214SAhmad Masri WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_KEEP_ALIVE = 0x20, 7108a4fa214SAhmad Masri WMI_BF_TRIGGER_AOA = 0x40, 7118a4fa214SAhmad Masri WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_UPM = 0x80, 7128a4fa214SAhmad Masri }; 7138a4fa214SAhmad Masri 714b874ddecSLior David /* WMI_RF_MGMT_CMDID */ 7152be7d22fSVladimir Kondratiev struct wmi_rf_mgmt_cmd { 7162be7d22fSVladimir Kondratiev __le32 rf_mgmt_type; 7172be7d22fSVladimir Kondratiev } __packed; 7182be7d22fSVladimir Kondratiev 719b874ddecSLior David /* WMI_CORR_MEASURE_CMDID */ 720b8023177SVladimir Kondratiev struct wmi_corr_measure_cmd { 721b874ddecSLior David __le32 freq_mhz; 722b8023177SVladimir Kondratiev __le32 length_samples; 723b8023177SVladimir Kondratiev __le32 iterations; 724b8023177SVladimir Kondratiev } __packed; 725b8023177SVladimir Kondratiev 726b874ddecSLior David /* WMI_SET_SSID_CMDID */ 7272be7d22fSVladimir Kondratiev struct wmi_set_ssid_cmd { 7282be7d22fSVladimir Kondratiev __le32 ssid_len; 7292be7d22fSVladimir Kondratiev u8 ssid[WMI_MAX_SSID_LEN]; 7302be7d22fSVladimir Kondratiev } __packed; 7312be7d22fSVladimir Kondratiev 732b874ddecSLior David /* WMI_SET_PCP_CHANNEL_CMDID */ 7332be7d22fSVladimir Kondratiev struct wmi_set_pcp_channel_cmd { 7342be7d22fSVladimir Kondratiev u8 channel; 7352be7d22fSVladimir Kondratiev u8 reserved[3]; 7362be7d22fSVladimir Kondratiev } __packed; 7372be7d22fSVladimir Kondratiev 738b874ddecSLior David /* WMI_BCON_CTRL_CMDID */ 7392be7d22fSVladimir Kondratiev struct wmi_bcon_ctrl_cmd { 7402be7d22fSVladimir Kondratiev __le16 bcon_interval; 7412be7d22fSVladimir Kondratiev __le16 frag_num; 7422be7d22fSVladimir Kondratiev __le64 ss_mask; 7432be7d22fSVladimir Kondratiev u8 network_type; 7446c2faf09SVladimir Kondratiev u8 pcp_max_assoc_sta; 7452be7d22fSVladimir Kondratiev u8 disable_sec_offload; 7462be7d22fSVladimir Kondratiev u8 disable_sec; 747b874ddecSLior David u8 hidden_ssid; 748b874ddecSLior David u8 is_go; 7498a4fa214SAhmad Masri /* A-BFT length override if non-0 */ 7508a4fa214SAhmad Masri u8 abft_len; 7518a4fa214SAhmad Masri u8 reserved; 7522be7d22fSVladimir Kondratiev } __packed; 7532be7d22fSVladimir Kondratiev 754b874ddecSLior David /* WMI_PORT_ALLOCATE_CMDID */ 755b8023177SVladimir Kondratiev enum wmi_port_role { 756b874ddecSLior David WMI_PORT_STA = 0x00, 757b874ddecSLior David WMI_PORT_PCP = 0x01, 758b874ddecSLior David WMI_PORT_AP = 0x02, 759b874ddecSLior David WMI_PORT_P2P_DEV = 0x03, 760b874ddecSLior David WMI_PORT_P2P_CLIENT = 0x04, 761b874ddecSLior David WMI_PORT_P2P_GO = 0x05, 762b8023177SVladimir Kondratiev }; 763b8023177SVladimir Kondratiev 764b874ddecSLior David /* WMI_PORT_ALLOCATE_CMDID */ 765b8023177SVladimir Kondratiev struct wmi_port_allocate_cmd { 766b8023177SVladimir Kondratiev u8 mac[WMI_MAC_LEN]; 767b8023177SVladimir Kondratiev u8 port_role; 7686c2faf09SVladimir Kondratiev u8 mid; 769b8023177SVladimir Kondratiev } __packed; 770b8023177SVladimir Kondratiev 771b874ddecSLior David /* WMI_PORT_DELETE_CMDID */ 772b874ddecSLior David struct wmi_port_delete_cmd { 773b8023177SVladimir Kondratiev u8 mid; 774b8023177SVladimir Kondratiev u8 reserved[3]; 775b8023177SVladimir Kondratiev } __packed; 776b8023177SVladimir Kondratiev 777fe9ee51eSMaya Erez /* WMI_TRAFFIC_SUSPEND_CMD wakeup trigger bit mask values */ 778fe9ee51eSMaya Erez enum wmi_wakeup_trigger { 779fe9ee51eSMaya Erez WMI_WAKEUP_TRIGGER_UCAST = 0x01, 780fe9ee51eSMaya Erez WMI_WAKEUP_TRIGGER_BCAST = 0x02, 781fe9ee51eSMaya Erez }; 782fe9ee51eSMaya Erez 783fe9ee51eSMaya Erez /* WMI_TRAFFIC_SUSPEND_CMDID */ 784fe9ee51eSMaya Erez struct wmi_traffic_suspend_cmd { 7850163b031SMaya Erez /* Bit vector: bit[0] - wake on Unicast, bit[1] - wake on Broadcast */ 7860163b031SMaya Erez u8 wakeup_trigger; 7870163b031SMaya Erez } __packed; 7880163b031SMaya Erez 789b874ddecSLior David /* WMI_P2P_CFG_CMDID */ 790b8023177SVladimir Kondratiev enum wmi_discovery_mode { 791b874ddecSLior David WMI_DISCOVERY_MODE_NON_OFFLOAD = 0x00, 792b874ddecSLior David WMI_DISCOVERY_MODE_OFFLOAD = 0x01, 793b874ddecSLior David WMI_DISCOVERY_MODE_PEER2PEER = 0x02, 794b8023177SVladimir Kondratiev }; 795b8023177SVladimir Kondratiev 796b8023177SVladimir Kondratiev struct wmi_p2p_cfg_cmd { 797b874ddecSLior David /* enum wmi_discovery_mode */ 798b874ddecSLior David u8 discovery_mode; 799b8023177SVladimir Kondratiev u8 channel; 800b874ddecSLior David /* base to listen/search duration calculation */ 801b874ddecSLior David __le16 bcon_interval; 802b8023177SVladimir Kondratiev } __packed; 803b8023177SVladimir Kondratiev 804b874ddecSLior David /* WMI_POWER_MGMT_CFG_CMDID */ 805b8023177SVladimir Kondratiev enum wmi_power_source_type { 806b874ddecSLior David WMI_POWER_SOURCE_BATTERY = 0x00, 807b874ddecSLior David WMI_POWER_SOURCE_OTHER = 0x01, 808b8023177SVladimir Kondratiev }; 809b8023177SVladimir Kondratiev 810b8023177SVladimir Kondratiev struct wmi_power_mgmt_cfg_cmd { 811b874ddecSLior David /* enum wmi_power_source_type */ 812b874ddecSLior David u8 power_source; 813b8023177SVladimir Kondratiev u8 reserved[3]; 814b8023177SVladimir Kondratiev } __packed; 815b8023177SVladimir Kondratiev 816b874ddecSLior David /* WMI_PCP_START_CMDID */ 8178a4fa214SAhmad Masri enum wmi_ap_sme_offload_mode { 8188a4fa214SAhmad Masri /* Full AP SME in FW */ 8198a4fa214SAhmad Masri WMI_AP_SME_OFFLOAD_FULL = 0x00, 8208a4fa214SAhmad Masri /* Probe AP SME in FW */ 8218a4fa214SAhmad Masri WMI_AP_SME_OFFLOAD_PARTIAL = 0x01, 8228a4fa214SAhmad Masri /* AP SME in host */ 8238a4fa214SAhmad Masri WMI_AP_SME_OFFLOAD_NONE = 0x02, 8248a4fa214SAhmad Masri }; 8258a4fa214SAhmad Masri 8268a4fa214SAhmad Masri /* WMI_PCP_START_CMDID */ 827b8023177SVladimir Kondratiev struct wmi_pcp_start_cmd { 828b8023177SVladimir Kondratiev __le16 bcon_interval; 8296c2faf09SVladimir Kondratiev u8 pcp_max_assoc_sta; 8308e52fe30SHamad Kadmany u8 hidden_ssid; 831b874ddecSLior David u8 is_go; 8326a363e8aSAhmad Masri /* enum wmi_channel WMI_CHANNEL_9..WMI_CHANNEL_12 */ 8336a363e8aSAhmad Masri u8 edmg_channel; 8346a363e8aSAhmad Masri u8 raw_mode; 8356a363e8aSAhmad Masri u8 reserved[3]; 83690ffabb0SDedy Lansky /* A-BFT length override if non-0 */ 837a52fb913SLior David u8 abft_len; 8388a4fa214SAhmad Masri /* enum wmi_ap_sme_offload_mode_e */ 8398a4fa214SAhmad Masri u8 ap_sme_offload_mode; 840b8023177SVladimir Kondratiev u8 network_type; 8416a363e8aSAhmad Masri /* enum wmi_channel WMI_CHANNEL_1..WMI_CHANNEL_6; for EDMG this is 8426a363e8aSAhmad Masri * the primary channel number 8436a363e8aSAhmad Masri */ 844b8023177SVladimir Kondratiev u8 channel; 845b8023177SVladimir Kondratiev u8 disable_sec_offload; 846b8023177SVladimir Kondratiev u8 disable_sec; 847b8023177SVladimir Kondratiev } __packed; 848b8023177SVladimir Kondratiev 849b874ddecSLior David /* WMI_SW_TX_REQ_CMDID */ 8502be7d22fSVladimir Kondratiev struct wmi_sw_tx_req_cmd { 8512be7d22fSVladimir Kondratiev u8 dst_mac[WMI_MAC_LEN]; 8522be7d22fSVladimir Kondratiev __le16 len; 853104f3d95SGustavo A. R. Silva u8 payload[]; 8542be7d22fSVladimir Kondratiev } __packed; 8552be7d22fSVladimir Kondratiev 8566a363e8aSAhmad Masri /* WMI_SW_TX_REQ_EXT_CMDID */ 8576a363e8aSAhmad Masri struct wmi_sw_tx_req_ext_cmd { 8586a363e8aSAhmad Masri u8 dst_mac[WMI_MAC_LEN]; 8596a363e8aSAhmad Masri __le16 len; 8606a363e8aSAhmad Masri __le16 duration_ms; 8616a363e8aSAhmad Masri /* Channel to use, 0xFF for currently active channel */ 8626a363e8aSAhmad Masri u8 channel; 8636a363e8aSAhmad Masri u8 reserved[5]; 864104f3d95SGustavo A. R. Silva u8 payload[]; 8656a363e8aSAhmad Masri } __packed; 8666a363e8aSAhmad Masri 8678a4fa214SAhmad Masri /* WMI_VRING_SWITCH_TIMING_CONFIG_CMDID */ 8688a4fa214SAhmad Masri struct wmi_vring_switch_timing_config_cmd { 8698a4fa214SAhmad Masri /* Set vring timing configuration: 8708a4fa214SAhmad Masri * 8718a4fa214SAhmad Masri * defined interval for vring switch 8728a4fa214SAhmad Masri */ 8738a4fa214SAhmad Masri __le32 interval_usec; 8748a4fa214SAhmad Masri /* vring inactivity threshold */ 8758a4fa214SAhmad Masri __le32 idle_th_usec; 8768a4fa214SAhmad Masri } __packed; 8778a4fa214SAhmad Masri 8782be7d22fSVladimir Kondratiev struct wmi_sw_ring_cfg { 8792be7d22fSVladimir Kondratiev __le64 ring_mem_base; 8802be7d22fSVladimir Kondratiev __le16 ring_size; 8812be7d22fSVladimir Kondratiev __le16 max_mpdu_size; 8822be7d22fSVladimir Kondratiev } __packed; 8832be7d22fSVladimir Kondratiev 884b874ddecSLior David /* wmi_vring_cfg_schd */ 8852be7d22fSVladimir Kondratiev struct wmi_vring_cfg_schd { 8862be7d22fSVladimir Kondratiev __le16 priority; 8872be7d22fSVladimir Kondratiev __le16 timeslot_us; 8882be7d22fSVladimir Kondratiev } __packed; 8892be7d22fSVladimir Kondratiev 8902be7d22fSVladimir Kondratiev enum wmi_vring_cfg_encap_trans_type { 891b874ddecSLior David WMI_VRING_ENC_TYPE_802_3 = 0x00, 892b874ddecSLior David WMI_VRING_ENC_TYPE_NATIVE_WIFI = 0x01, 8936a363e8aSAhmad Masri WMI_VRING_ENC_TYPE_NONE = 0x02, 8942be7d22fSVladimir Kondratiev }; 8952be7d22fSVladimir Kondratiev 8962be7d22fSVladimir Kondratiev enum wmi_vring_cfg_ds_cfg { 897b874ddecSLior David WMI_VRING_DS_PBSS = 0x00, 898b874ddecSLior David WMI_VRING_DS_STATION = 0x01, 899b874ddecSLior David WMI_VRING_DS_AP = 0x02, 900b874ddecSLior David WMI_VRING_DS_ADDR4 = 0x03, 9012be7d22fSVladimir Kondratiev }; 9022be7d22fSVladimir Kondratiev 9032be7d22fSVladimir Kondratiev enum wmi_vring_cfg_nwifi_ds_trans_type { 904b874ddecSLior David WMI_NWIFI_TX_TRANS_MODE_NO = 0x00, 905b874ddecSLior David WMI_NWIFI_TX_TRANS_MODE_AP2PBSS = 0x01, 906b874ddecSLior David WMI_NWIFI_TX_TRANS_MODE_STA2PBSS = 0x02, 9072be7d22fSVladimir Kondratiev }; 9082be7d22fSVladimir Kondratiev 9092be7d22fSVladimir Kondratiev enum wmi_vring_cfg_schd_params_priority { 910b874ddecSLior David WMI_SCH_PRIO_REGULAR = 0x00, 911b874ddecSLior David WMI_SCH_PRIO_HIGH = 0x01, 9122be7d22fSVladimir Kondratiev }; 9132be7d22fSVladimir Kondratiev 9148a4fa214SAhmad Masri #define CIDXTID_EXTENDED_CID_TID (0xFF) 9152be7d22fSVladimir Kondratiev #define CIDXTID_CID_POS (0) 9162be7d22fSVladimir Kondratiev #define CIDXTID_CID_LEN (4) 9172be7d22fSVladimir Kondratiev #define CIDXTID_CID_MSK (0xF) 9182be7d22fSVladimir Kondratiev #define CIDXTID_TID_POS (4) 9192be7d22fSVladimir Kondratiev #define CIDXTID_TID_LEN (4) 9202be7d22fSVladimir Kondratiev #define CIDXTID_TID_MSK (0xF0) 9212be7d22fSVladimir Kondratiev #define VRING_CFG_MAC_CTRL_LIFETIME_EN_POS (0) 9222be7d22fSVladimir Kondratiev #define VRING_CFG_MAC_CTRL_LIFETIME_EN_LEN (1) 9232be7d22fSVladimir Kondratiev #define VRING_CFG_MAC_CTRL_LIFETIME_EN_MSK (0x1) 9242be7d22fSVladimir Kondratiev #define VRING_CFG_MAC_CTRL_AGGR_EN_POS (1) 9252be7d22fSVladimir Kondratiev #define VRING_CFG_MAC_CTRL_AGGR_EN_LEN (1) 9262be7d22fSVladimir Kondratiev #define VRING_CFG_MAC_CTRL_AGGR_EN_MSK (0x2) 9272be7d22fSVladimir Kondratiev #define VRING_CFG_TO_RESOLUTION_VALUE_POS (0) 9282be7d22fSVladimir Kondratiev #define VRING_CFG_TO_RESOLUTION_VALUE_LEN (6) 9292be7d22fSVladimir Kondratiev #define VRING_CFG_TO_RESOLUTION_VALUE_MSK (0x3F) 930b874ddecSLior David 931b874ddecSLior David struct wmi_vring_cfg { 932b874ddecSLior David struct wmi_sw_ring_cfg tx_sw_ring; 933b874ddecSLior David /* 0-23 vrings */ 934b874ddecSLior David u8 ringid; 9358a4fa214SAhmad Masri /* Used for cid less than 8. For higher cid set 9368a4fa214SAhmad Masri * CIDXTID_EXTENDED_CID_TID here and use cid and tid members instead 9378a4fa214SAhmad Masri */ 938b874ddecSLior David u8 cidxtid; 939b874ddecSLior David u8 encap_trans_type; 940b874ddecSLior David /* 802.3 DS cfg */ 941b874ddecSLior David u8 ds_cfg; 942b874ddecSLior David u8 nwifi_ds_trans_type; 943b874ddecSLior David u8 mac_ctrl; 9442be7d22fSVladimir Kondratiev u8 to_resolution; 9452be7d22fSVladimir Kondratiev u8 agg_max_wsize; 9462be7d22fSVladimir Kondratiev struct wmi_vring_cfg_schd schd_params; 9478a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 9488a4fa214SAhmad Masri u8 cid; 9498a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 9508a4fa214SAhmad Masri u8 tid; 951b5aeff16SDedy Lansky /* Update the vring's priority for Qos purpose. Set to 952b5aeff16SDedy Lansky * WMI_QOS_DEFAULT_PRIORITY to use MID's QoS priority 953b5aeff16SDedy Lansky */ 954b5aeff16SDedy Lansky u8 qos_priority; 955b5aeff16SDedy Lansky u8 reserved; 9562be7d22fSVladimir Kondratiev } __packed; 9572be7d22fSVladimir Kondratiev 9582be7d22fSVladimir Kondratiev enum wmi_vring_cfg_cmd_action { 959b874ddecSLior David WMI_VRING_CMD_ADD = 0x00, 960b874ddecSLior David WMI_VRING_CMD_MODIFY = 0x01, 961b874ddecSLior David WMI_VRING_CMD_DELETE = 0x02, 9622be7d22fSVladimir Kondratiev }; 9632be7d22fSVladimir Kondratiev 964b874ddecSLior David /* WMI_VRING_CFG_CMDID */ 9652be7d22fSVladimir Kondratiev struct wmi_vring_cfg_cmd { 9662be7d22fSVladimir Kondratiev __le32 action; 9672be7d22fSVladimir Kondratiev struct wmi_vring_cfg vring_cfg; 9682be7d22fSVladimir Kondratiev } __packed; 9692be7d22fSVladimir Kondratiev 97062bfd300SVladimir Kondratiev struct wmi_bcast_vring_cfg { 97162bfd300SVladimir Kondratiev struct wmi_sw_ring_cfg tx_sw_ring; 972b874ddecSLior David /* 0-23 vrings */ 973b874ddecSLior David u8 ringid; 97462bfd300SVladimir Kondratiev u8 encap_trans_type; 975b874ddecSLior David /* 802.3 DS cfg */ 976b874ddecSLior David u8 ds_cfg; 97762bfd300SVladimir Kondratiev u8 nwifi_ds_trans_type; 97862bfd300SVladimir Kondratiev } __packed; 97962bfd300SVladimir Kondratiev 980b874ddecSLior David /* WMI_BCAST_VRING_CFG_CMDID */ 98162bfd300SVladimir Kondratiev struct wmi_bcast_vring_cfg_cmd { 98262bfd300SVladimir Kondratiev __le32 action; 98362bfd300SVladimir Kondratiev struct wmi_bcast_vring_cfg vring_cfg; 98462bfd300SVladimir Kondratiev } __packed; 98562bfd300SVladimir Kondratiev 98696c93589SGidon Studinski struct wmi_edma_ring_cfg { 98796c93589SGidon Studinski __le64 ring_mem_base; 98896c93589SGidon Studinski /* size in number of items */ 98996c93589SGidon Studinski __le16 ring_size; 99096c93589SGidon Studinski u8 ring_id; 99196c93589SGidon Studinski u8 reserved; 99296c93589SGidon Studinski } __packed; 99396c93589SGidon Studinski 99496c93589SGidon Studinski enum wmi_rx_msg_type { 99596c93589SGidon Studinski WMI_RX_MSG_TYPE_COMPRESSED = 0x00, 99696c93589SGidon Studinski WMI_RX_MSG_TYPE_EXTENDED = 0x01, 99796c93589SGidon Studinski }; 99896c93589SGidon Studinski 99973a7d1e3SAlexei Avshalom Lazar enum wmi_ring_add_irq_mode { 100073a7d1e3SAlexei Avshalom Lazar /* Backwards compatibility 100173a7d1e3SAlexei Avshalom Lazar * for DESC ring - interrupt disabled 100273a7d1e3SAlexei Avshalom Lazar * for STATUS ring - interrupt enabled 100373a7d1e3SAlexei Avshalom Lazar */ 100473a7d1e3SAlexei Avshalom Lazar WMI_RING_ADD_IRQ_MODE_BWC = 0x00, 100573a7d1e3SAlexei Avshalom Lazar WMI_RING_ADD_IRQ_MODE_DISABLE = 0x01, 100673a7d1e3SAlexei Avshalom Lazar WMI_RING_ADD_IRQ_MODE_ENABLE = 0x02, 100773a7d1e3SAlexei Avshalom Lazar }; 100873a7d1e3SAlexei Avshalom Lazar 100996c93589SGidon Studinski struct wmi_tx_status_ring_add_cmd { 101096c93589SGidon Studinski struct wmi_edma_ring_cfg ring_cfg; 101196c93589SGidon Studinski u8 irq_index; 101273a7d1e3SAlexei Avshalom Lazar /* wmi_ring_add_irq_mode */ 101373a7d1e3SAlexei Avshalom Lazar u8 irq_mode; 101473a7d1e3SAlexei Avshalom Lazar u8 reserved[2]; 101596c93589SGidon Studinski } __packed; 101696c93589SGidon Studinski 101796c93589SGidon Studinski struct wmi_rx_status_ring_add_cmd { 101896c93589SGidon Studinski struct wmi_edma_ring_cfg ring_cfg; 101996c93589SGidon Studinski u8 irq_index; 102096c93589SGidon Studinski /* wmi_rx_msg_type */ 102196c93589SGidon Studinski u8 rx_msg_type; 102296c93589SGidon Studinski u8 reserved[2]; 102396c93589SGidon Studinski } __packed; 102496c93589SGidon Studinski 102596c93589SGidon Studinski struct wmi_cfg_def_rx_offload_cmd { 102696c93589SGidon Studinski __le16 max_msdu_size; 102796c93589SGidon Studinski __le16 max_rx_pl_per_desc; 102896c93589SGidon Studinski u8 decap_trans_type; 102996c93589SGidon Studinski u8 l2_802_3_offload_ctrl; 103096c93589SGidon Studinski u8 l2_nwifi_offload_ctrl; 103196c93589SGidon Studinski u8 vlan_id; 103296c93589SGidon Studinski u8 nwifi_ds_trans_type; 103396c93589SGidon Studinski u8 l3_l4_ctrl; 103496c93589SGidon Studinski u8 reserved[6]; 103596c93589SGidon Studinski } __packed; 103696c93589SGidon Studinski 103796c93589SGidon Studinski struct wmi_tx_desc_ring_add_cmd { 103896c93589SGidon Studinski struct wmi_edma_ring_cfg ring_cfg; 103996c93589SGidon Studinski __le16 max_msdu_size; 104096c93589SGidon Studinski /* Correlated status ring (0-63) */ 104196c93589SGidon Studinski u8 status_ring_id; 104296c93589SGidon Studinski u8 cid; 104396c93589SGidon Studinski u8 tid; 104496c93589SGidon Studinski u8 encap_trans_type; 104596c93589SGidon Studinski u8 mac_ctrl; 104696c93589SGidon Studinski u8 to_resolution; 104796c93589SGidon Studinski u8 agg_max_wsize; 104873a7d1e3SAlexei Avshalom Lazar u8 irq_index; 104973a7d1e3SAlexei Avshalom Lazar /* wmi_ring_add_irq_mode */ 105073a7d1e3SAlexei Avshalom Lazar u8 irq_mode; 105173a7d1e3SAlexei Avshalom Lazar u8 reserved; 105296c93589SGidon Studinski struct wmi_vring_cfg_schd schd_params; 105396c93589SGidon Studinski } __packed; 105496c93589SGidon Studinski 105596c93589SGidon Studinski struct wmi_rx_desc_ring_add_cmd { 105696c93589SGidon Studinski struct wmi_edma_ring_cfg ring_cfg; 105796c93589SGidon Studinski u8 irq_index; 105896c93589SGidon Studinski /* 0-63 status rings */ 105996c93589SGidon Studinski u8 status_ring_id; 106096c93589SGidon Studinski u8 reserved[2]; 106196c93589SGidon Studinski __le64 sw_tail_host_addr; 106296c93589SGidon Studinski } __packed; 106396c93589SGidon Studinski 106496c93589SGidon Studinski struct wmi_bcast_desc_ring_add_cmd { 106596c93589SGidon Studinski struct wmi_edma_ring_cfg ring_cfg; 106696c93589SGidon Studinski __le16 max_msdu_size; 106796c93589SGidon Studinski /* Correlated status ring (0-63) */ 106896c93589SGidon Studinski u8 status_ring_id; 106996c93589SGidon Studinski u8 encap_trans_type; 107096c93589SGidon Studinski u8 reserved[4]; 107196c93589SGidon Studinski } __packed; 107296c93589SGidon Studinski 1073b5aeff16SDedy Lansky /* WMI_LO_POWER_CALIB_FROM_OTP_CMDID */ 1074b5aeff16SDedy Lansky struct wmi_lo_power_calib_from_otp_cmd { 1075b5aeff16SDedy Lansky /* index to read from OTP. zero based */ 1076b5aeff16SDedy Lansky u8 index; 1077b5aeff16SDedy Lansky u8 reserved[3]; 1078b5aeff16SDedy Lansky } __packed; 1079b5aeff16SDedy Lansky 1080b5aeff16SDedy Lansky /* WMI_LO_POWER_CALIB_FROM_OTP_EVENTID */ 1081b5aeff16SDedy Lansky struct wmi_lo_power_calib_from_otp_event { 1082b5aeff16SDedy Lansky /* wmi_fw_status */ 1083b5aeff16SDedy Lansky u8 status; 1084b5aeff16SDedy Lansky u8 reserved[3]; 1085b5aeff16SDedy Lansky } __packed; 1086b5aeff16SDedy Lansky 108796c93589SGidon Studinski /* WMI_RING_BA_EN_CMDID */ 108896c93589SGidon Studinski struct wmi_ring_ba_en_cmd { 108996c93589SGidon Studinski u8 ring_id; 10902be7d22fSVladimir Kondratiev u8 agg_max_wsize; 10912be7d22fSVladimir Kondratiev __le16 ba_timeout; 1092cbcf5866SVladimir Kondratiev u8 amsdu; 1093b874ddecSLior David u8 reserved[3]; 10942be7d22fSVladimir Kondratiev } __packed; 10952be7d22fSVladimir Kondratiev 109696c93589SGidon Studinski /* WMI_RING_BA_DIS_CMDID */ 109796c93589SGidon Studinski struct wmi_ring_ba_dis_cmd { 109896c93589SGidon Studinski u8 ring_id; 10992be7d22fSVladimir Kondratiev u8 reserved; 11002be7d22fSVladimir Kondratiev __le16 reason; 11012be7d22fSVladimir Kondratiev } __packed; 11022be7d22fSVladimir Kondratiev 1103b874ddecSLior David /* WMI_NOTIFY_REQ_CMDID */ 11042be7d22fSVladimir Kondratiev struct wmi_notify_req_cmd { 11052be7d22fSVladimir Kondratiev u8 cid; 1106b8023177SVladimir Kondratiev u8 year; 1107b8023177SVladimir Kondratiev u8 month; 1108b8023177SVladimir Kondratiev u8 day; 11092be7d22fSVladimir Kondratiev __le32 interval_usec; 1110b8023177SVladimir Kondratiev u8 hour; 1111b8023177SVladimir Kondratiev u8 minute; 1112b8023177SVladimir Kondratiev u8 second; 1113b8023177SVladimir Kondratiev u8 miliseconds; 11142be7d22fSVladimir Kondratiev } __packed; 11152be7d22fSVladimir Kondratiev 1116b874ddecSLior David /* WMI_CFG_RX_CHAIN_CMDID */ 11172be7d22fSVladimir Kondratiev enum wmi_sniffer_cfg_mode { 1118b874ddecSLior David WMI_SNIFFER_OFF = 0x00, 1119b874ddecSLior David WMI_SNIFFER_ON = 0x01, 11202be7d22fSVladimir Kondratiev }; 11212be7d22fSVladimir Kondratiev 1122761f8e4dSLazar Alexei /* WMI_SILENT_RSSI_TABLE */ 1123761f8e4dSLazar Alexei enum wmi_silent_rssi_table { 1124761f8e4dSLazar Alexei RF_TEMPERATURE_CALIB_DEFAULT_DB = 0x00, 1125761f8e4dSLazar Alexei RF_TEMPERATURE_CALIB_HIGH_POWER_DB = 0x01, 1126761f8e4dSLazar Alexei }; 1127761f8e4dSLazar Alexei 1128761f8e4dSLazar Alexei /* WMI_SILENT_RSSI_STATUS */ 1129761f8e4dSLazar Alexei enum wmi_silent_rssi_status { 1130761f8e4dSLazar Alexei SILENT_RSSI_SUCCESS = 0x00, 1131761f8e4dSLazar Alexei SILENT_RSSI_FAILURE = 0x01, 1132761f8e4dSLazar Alexei }; 1133761f8e4dSLazar Alexei 1134761f8e4dSLazar Alexei /* WMI_SET_ACTIVE_SILENT_RSSI_TABLE_CMDID */ 1135761f8e4dSLazar Alexei struct wmi_set_active_silent_rssi_table_cmd { 1136761f8e4dSLazar Alexei /* enum wmi_silent_rssi_table */ 1137761f8e4dSLazar Alexei __le32 table; 1138761f8e4dSLazar Alexei } __packed; 1139761f8e4dSLazar Alexei 11402be7d22fSVladimir Kondratiev enum wmi_sniffer_cfg_phy_info_mode { 1141b874ddecSLior David WMI_SNIFFER_PHY_INFO_DISABLED = 0x00, 1142b874ddecSLior David WMI_SNIFFER_PHY_INFO_ENABLED = 0x01, 11432be7d22fSVladimir Kondratiev }; 11442be7d22fSVladimir Kondratiev 11452be7d22fSVladimir Kondratiev enum wmi_sniffer_cfg_phy_support { 1146b874ddecSLior David WMI_SNIFFER_CP = 0x00, 1147b874ddecSLior David WMI_SNIFFER_DP = 0x01, 1148b874ddecSLior David WMI_SNIFFER_BOTH_PHYS = 0x02, 11492be7d22fSVladimir Kondratiev }; 11502be7d22fSVladimir Kondratiev 1151b874ddecSLior David /* wmi_sniffer_cfg */ 11522be7d22fSVladimir Kondratiev struct wmi_sniffer_cfg { 1153b874ddecSLior David /* enum wmi_sniffer_cfg_mode */ 1154b874ddecSLior David __le32 mode; 1155b874ddecSLior David /* enum wmi_sniffer_cfg_phy_info_mode */ 1156b874ddecSLior David __le32 phy_info_mode; 1157b874ddecSLior David /* enum wmi_sniffer_cfg_phy_support */ 1158b874ddecSLior David __le32 phy_support; 11592be7d22fSVladimir Kondratiev u8 channel; 11602be7d22fSVladimir Kondratiev u8 reserved[3]; 11612be7d22fSVladimir Kondratiev } __packed; 11622be7d22fSVladimir Kondratiev 11632be7d22fSVladimir Kondratiev enum wmi_cfg_rx_chain_cmd_action { 1164b874ddecSLior David WMI_RX_CHAIN_ADD = 0x00, 1165b874ddecSLior David WMI_RX_CHAIN_DEL = 0x01, 11662be7d22fSVladimir Kondratiev }; 11672be7d22fSVladimir Kondratiev 11682be7d22fSVladimir Kondratiev enum wmi_cfg_rx_chain_cmd_decap_trans_type { 1169b874ddecSLior David WMI_DECAP_TYPE_802_3 = 0x00, 1170b874ddecSLior David WMI_DECAP_TYPE_NATIVE_WIFI = 0x01, 1171b874ddecSLior David WMI_DECAP_TYPE_NONE = 0x02, 11722be7d22fSVladimir Kondratiev }; 11732be7d22fSVladimir Kondratiev 11742be7d22fSVladimir Kondratiev enum wmi_cfg_rx_chain_cmd_nwifi_ds_trans_type { 1175b874ddecSLior David WMI_NWIFI_RX_TRANS_MODE_NO = 0x00, 1176b874ddecSLior David WMI_NWIFI_RX_TRANS_MODE_PBSS2AP = 0x01, 1177b874ddecSLior David WMI_NWIFI_RX_TRANS_MODE_PBSS2STA = 0x02, 11782be7d22fSVladimir Kondratiev }; 11792be7d22fSVladimir Kondratiev 1180b8023177SVladimir Kondratiev enum wmi_cfg_rx_chain_cmd_reorder_type { 1181b874ddecSLior David WMI_RX_HW_REORDER = 0x00, 1182b874ddecSLior David WMI_RX_SW_REORDER = 0x01, 1183b8023177SVladimir Kondratiev }; 1184b8023177SVladimir Kondratiev 11852be7d22fSVladimir Kondratiev #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_POS (0) 11862be7d22fSVladimir Kondratiev #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_LEN (1) 11872be7d22fSVladimir Kondratiev #define L2_802_3_OFFLOAD_CTRL_VLAN_TAG_INSERTION_MSK (0x1) 1188c406ea7cSVladimir Kondratiev #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_POS (1) 1189c406ea7cSVladimir Kondratiev #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_LEN (1) 1190c406ea7cSVladimir Kondratiev #define L2_802_3_OFFLOAD_CTRL_SNAP_KEEP_MSK (0x2) 11912be7d22fSVladimir Kondratiev #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_POS (0) 11922be7d22fSVladimir Kondratiev #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_LEN (1) 11932be7d22fSVladimir Kondratiev #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_QOS_MSK (0x1) 11942be7d22fSVladimir Kondratiev #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_POS (1) 11952be7d22fSVladimir Kondratiev #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_LEN (1) 11962be7d22fSVladimir Kondratiev #define L2_NWIFI_OFFLOAD_CTRL_REMOVE_PN_MSK (0x2) 11972be7d22fSVladimir Kondratiev #define L3_L4_CTRL_IPV4_CHECKSUM_EN_POS (0) 11982be7d22fSVladimir Kondratiev #define L3_L4_CTRL_IPV4_CHECKSUM_EN_LEN (1) 11992be7d22fSVladimir Kondratiev #define L3_L4_CTRL_IPV4_CHECKSUM_EN_MSK (0x1) 12002be7d22fSVladimir Kondratiev #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_POS (1) 12012be7d22fSVladimir Kondratiev #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_LEN (1) 12022be7d22fSVladimir Kondratiev #define L3_L4_CTRL_TCPIP_CHECKSUM_EN_MSK (0x2) 12032be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_POS (0) 12042be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_LEN (1) 12052be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_PREFETCH_THRSH_MSK (0x1) 12062be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_WB_THRSH_POS (1) 12072be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_WB_THRSH_LEN (1) 12082be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_WB_THRSH_MSK (0x2) 12092be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_ITR_THRSH_POS (2) 12102be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_ITR_THRSH_LEN (1) 12112be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_ITR_THRSH_MSK (0x4) 12122be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_HOST_THRSH_POS (3) 12132be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_HOST_THRSH_LEN (1) 12142be7d22fSVladimir Kondratiev #define RING_CTRL_OVERRIDE_HOST_THRSH_MSK (0x8) 12152be7d22fSVladimir Kondratiev 1216b874ddecSLior David /* WMI_CFG_RX_CHAIN_CMDID */ 1217b874ddecSLior David struct wmi_cfg_rx_chain_cmd { 1218b874ddecSLior David __le32 action; 1219b874ddecSLior David struct wmi_sw_ring_cfg rx_sw_ring; 1220b874ddecSLior David u8 mid; 1221b874ddecSLior David u8 decap_trans_type; 1222b874ddecSLior David u8 l2_802_3_offload_ctrl; 1223b874ddecSLior David u8 l2_nwifi_offload_ctrl; 1224b874ddecSLior David u8 vlan_id; 1225b874ddecSLior David u8 nwifi_ds_trans_type; 1226b874ddecSLior David u8 l3_l4_ctrl; 1227b874ddecSLior David u8 ring_ctrl; 12282be7d22fSVladimir Kondratiev __le16 prefetch_thrsh; 12292be7d22fSVladimir Kondratiev __le16 wb_thrsh; 12302be7d22fSVladimir Kondratiev __le32 itr_value; 12312be7d22fSVladimir Kondratiev __le16 host_thrsh; 1232b8023177SVladimir Kondratiev u8 reorder_type; 1233b8023177SVladimir Kondratiev u8 reserved; 12342be7d22fSVladimir Kondratiev struct wmi_sniffer_cfg sniffer_cfg; 1235b874ddecSLior David __le16 max_rx_pl_per_desc; 12362be7d22fSVladimir Kondratiev } __packed; 12372be7d22fSVladimir Kondratiev 1238b874ddecSLior David /* WMI_RCP_ADDBA_RESP_CMDID */ 12392be7d22fSVladimir Kondratiev struct wmi_rcp_addba_resp_cmd { 12408a4fa214SAhmad Masri /* Used for cid less than 8. For higher cid set 12418a4fa214SAhmad Masri * CIDXTID_EXTENDED_CID_TID here and use cid and tid members instead 12428a4fa214SAhmad Masri */ 12432be7d22fSVladimir Kondratiev u8 cidxtid; 12442be7d22fSVladimir Kondratiev u8 dialog_token; 12452be7d22fSVladimir Kondratiev __le16 status_code; 1246b874ddecSLior David /* ieee80211_ba_parameterset field to send */ 1247b874ddecSLior David __le16 ba_param_set; 12482be7d22fSVladimir Kondratiev __le16 ba_timeout; 12498a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 12508a4fa214SAhmad Masri u8 cid; 12518a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 12528a4fa214SAhmad Masri u8 tid; 12538a4fa214SAhmad Masri u8 reserved[2]; 12542be7d22fSVladimir Kondratiev } __packed; 12552be7d22fSVladimir Kondratiev 125696c93589SGidon Studinski /* WMI_RCP_ADDBA_RESP_EDMA_CMDID */ 125796c93589SGidon Studinski struct wmi_rcp_addba_resp_edma_cmd { 125896c93589SGidon Studinski u8 cid; 125996c93589SGidon Studinski u8 tid; 126096c93589SGidon Studinski u8 dialog_token; 126196c93589SGidon Studinski u8 reserved; 126296c93589SGidon Studinski __le16 status_code; 126396c93589SGidon Studinski /* ieee80211_ba_parameterset field to send */ 126496c93589SGidon Studinski __le16 ba_param_set; 126596c93589SGidon Studinski __le16 ba_timeout; 126696c93589SGidon Studinski u8 status_ring_id; 126796c93589SGidon Studinski /* wmi_cfg_rx_chain_cmd_reorder_type */ 126896c93589SGidon Studinski u8 reorder_type; 126996c93589SGidon Studinski } __packed; 127096c93589SGidon Studinski 1271b874ddecSLior David /* WMI_RCP_DELBA_CMDID */ 12722be7d22fSVladimir Kondratiev struct wmi_rcp_delba_cmd { 12738a4fa214SAhmad Masri /* Used for cid less than 8. For higher cid set 12748a4fa214SAhmad Masri * CIDXTID_EXTENDED_CID_TID here and use cid and tid members instead 12758a4fa214SAhmad Masri */ 12762be7d22fSVladimir Kondratiev u8 cidxtid; 12772be7d22fSVladimir Kondratiev u8 reserved; 12782be7d22fSVladimir Kondratiev __le16 reason; 12798a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 12808a4fa214SAhmad Masri u8 cid; 12818a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 12828a4fa214SAhmad Masri u8 tid; 12838a4fa214SAhmad Masri u8 reserved2[2]; 12842be7d22fSVladimir Kondratiev } __packed; 12852be7d22fSVladimir Kondratiev 1286b874ddecSLior David /* WMI_RCP_ADDBA_REQ_CMDID */ 12872be7d22fSVladimir Kondratiev struct wmi_rcp_addba_req_cmd { 12888a4fa214SAhmad Masri /* Used for cid less than 8. For higher cid set 12898a4fa214SAhmad Masri * CIDXTID_EXTENDED_CID_TID here and use cid and tid members instead 12908a4fa214SAhmad Masri */ 12912be7d22fSVladimir Kondratiev u8 cidxtid; 12922be7d22fSVladimir Kondratiev u8 dialog_token; 12932be7d22fSVladimir Kondratiev /* ieee80211_ba_parameterset field as it received */ 12942be7d22fSVladimir Kondratiev __le16 ba_param_set; 12952be7d22fSVladimir Kondratiev __le16 ba_timeout; 12962be7d22fSVladimir Kondratiev /* ieee80211_ba_seqstrl field as it received */ 12972be7d22fSVladimir Kondratiev __le16 ba_seq_ctrl; 12988a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 12998a4fa214SAhmad Masri u8 cid; 13008a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 13018a4fa214SAhmad Masri u8 tid; 13028a4fa214SAhmad Masri u8 reserved[2]; 13032be7d22fSVladimir Kondratiev } __packed; 13042be7d22fSVladimir Kondratiev 1305b874ddecSLior David /* WMI_SET_MAC_ADDRESS_CMDID */ 13062be7d22fSVladimir Kondratiev struct wmi_set_mac_address_cmd { 13072be7d22fSVladimir Kondratiev u8 mac[WMI_MAC_LEN]; 13082be7d22fSVladimir Kondratiev u8 reserved[2]; 13092be7d22fSVladimir Kondratiev } __packed; 13102be7d22fSVladimir Kondratiev 1311b874ddecSLior David /* WMI_ECHO_CMDID 13122be7d22fSVladimir Kondratiev * Check FW is alive 13132be7d22fSVladimir Kondratiev * Returned event: WMI_ECHO_RSP_EVENTID 13142be7d22fSVladimir Kondratiev */ 13152be7d22fSVladimir Kondratiev struct wmi_echo_cmd { 13162be7d22fSVladimir Kondratiev __le32 value; 13172be7d22fSVladimir Kondratiev } __packed; 13182be7d22fSVladimir Kondratiev 13198a4fa214SAhmad Masri /* WMI_DEEP_ECHO_CMDID 13206a363e8aSAhmad Masri * Check FW and uCode is alive 13216a363e8aSAhmad Masri * Returned event: WMI_DEEP_ECHO_RSP_EVENTID 13228a4fa214SAhmad Masri */ 13238a4fa214SAhmad Masri struct wmi_deep_echo_cmd { 13248a4fa214SAhmad Masri __le32 value; 13258a4fa214SAhmad Masri } __packed; 13268a4fa214SAhmad Masri 1327761f8e4dSLazar Alexei /* WMI_RF_PWR_ON_DELAY_CMDID 1328761f8e4dSLazar Alexei * set FW time parameters used through RF resetting 1329761f8e4dSLazar Alexei * RF reset consists of bringing its power down for a period of time, then 1330761f8e4dSLazar Alexei * bringing the power up 1331761f8e4dSLazar Alexei * Returned event: WMI_RF_PWR_ON_DELAY_RSP_EVENTID 1332761f8e4dSLazar Alexei */ 1333761f8e4dSLazar Alexei struct wmi_rf_pwr_on_delay_cmd { 1334761f8e4dSLazar Alexei /* time in usec the FW waits after bringing the RF PWR down, 1335761f8e4dSLazar Alexei * set 0 for default 1336761f8e4dSLazar Alexei */ 1337761f8e4dSLazar Alexei __le16 down_delay_usec; 1338761f8e4dSLazar Alexei /* time in usec the FW waits after bringing the RF PWR up, 1339761f8e4dSLazar Alexei * set 0 for default 1340761f8e4dSLazar Alexei */ 1341761f8e4dSLazar Alexei __le16 up_delay_usec; 1342b874ddecSLior David } __packed; 1343b874ddecSLior David 13448a4fa214SAhmad Masri /* WMI_SET_HIGH_POWER_TABLE_PARAMS_CMDID 1345761f8e4dSLazar Alexei * This API controls the Tx and Rx gain over temperature. 1346761f8e4dSLazar Alexei * It controls the Tx D-type, Rx D-type and Rx E-type amplifiers. 1347761f8e4dSLazar Alexei * It also controls the Tx gain index, by controlling the Rx to Tx gain index 1348761f8e4dSLazar Alexei * offset. 1349761f8e4dSLazar Alexei * The control is divided by 3 temperature values to 4 temperature ranges. 1350761f8e4dSLazar Alexei * Each parameter uses its own temperature values. 1351761f8e4dSLazar Alexei * Returned event: WMI_SET_HIGH_POWER_TABLE_PARAMS_EVENTID 1352761f8e4dSLazar Alexei */ 1353761f8e4dSLazar Alexei struct wmi_set_high_power_table_params_cmd { 1354761f8e4dSLazar Alexei /* Temperature range for Tx D-type parameters */ 1355761f8e4dSLazar Alexei u8 tx_dtype_temp[WMI_RF_DTYPE_LENGTH]; 1356761f8e4dSLazar Alexei u8 reserved0; 1357761f8e4dSLazar Alexei /* Tx D-type values to be used for each temperature range */ 13588a4fa214SAhmad Masri __le32 tx_dtype_conf[WMI_RF_DTYPE_CONF_LENGTH]; 13598a4fa214SAhmad Masri /* Temperature range for Tx E-type parameters */ 13608a4fa214SAhmad Masri u8 tx_etype_temp[WMI_RF_ETYPE_LENGTH]; 13618a4fa214SAhmad Masri u8 reserved1; 13628a4fa214SAhmad Masri /* Tx E-type values to be used for each temperature range. 13638a4fa214SAhmad Masri * The last 4 values of any range are the first 4 values of the next 13648a4fa214SAhmad Masri * range and so on 13658a4fa214SAhmad Masri */ 13668a4fa214SAhmad Masri __le32 tx_etype_conf[WMI_RF_ETYPE_CONF_LENGTH]; 1367761f8e4dSLazar Alexei /* Temperature range for Rx D-type parameters */ 1368761f8e4dSLazar Alexei u8 rx_dtype_temp[WMI_RF_DTYPE_LENGTH]; 13698a4fa214SAhmad Masri u8 reserved2; 1370761f8e4dSLazar Alexei /* Rx D-type values to be used for each temperature range */ 13718a4fa214SAhmad Masri __le32 rx_dtype_conf[WMI_RF_DTYPE_CONF_LENGTH]; 1372761f8e4dSLazar Alexei /* Temperature range for Rx E-type parameters */ 1373761f8e4dSLazar Alexei u8 rx_etype_temp[WMI_RF_ETYPE_LENGTH]; 13748a4fa214SAhmad Masri u8 reserved3; 1375761f8e4dSLazar Alexei /* Rx E-type values to be used for each temperature range. 1376761f8e4dSLazar Alexei * The last 4 values of any range are the first 4 values of the next 1377761f8e4dSLazar Alexei * range and so on 1378761f8e4dSLazar Alexei */ 13798a4fa214SAhmad Masri __le32 rx_etype_conf[WMI_RF_ETYPE_CONF_LENGTH]; 1380761f8e4dSLazar Alexei /* Temperature range for rx_2_tx_offs parameters */ 1381761f8e4dSLazar Alexei u8 rx_2_tx_temp[WMI_RF_RX2TX_LENGTH]; 13828a4fa214SAhmad Masri u8 reserved4; 1383761f8e4dSLazar Alexei /* Rx to Tx gain index offset */ 13848a4fa214SAhmad Masri s8 rx_2_tx_offs[WMI_RF_RX2TX_CONF_LENGTH]; 13858a4fa214SAhmad Masri } __packed; 13868a4fa214SAhmad Masri 13878a4fa214SAhmad Masri /* WMI_FIXED_SCHEDULING_UL_CONFIG_CMDID 13888a4fa214SAhmad Masri * This API sets rd parameter per mcs. 13898a4fa214SAhmad Masri * Relevant only in Fixed Scheduling mode. 13908a4fa214SAhmad Masri * Returned event: WMI_FIXED_SCHEDULING_UL_CONFIG_EVENTID 13918a4fa214SAhmad Masri */ 13928a4fa214SAhmad Masri struct wmi_fixed_scheduling_ul_config_cmd { 13938a4fa214SAhmad Masri /* Use mcs -1 to set for every mcs */ 13948a4fa214SAhmad Masri s8 mcs; 13958a4fa214SAhmad Masri /* Number of frames with rd bit set in a single virtual slot */ 13968a4fa214SAhmad Masri u8 rd_count_per_slot; 13978a4fa214SAhmad Masri u8 reserved[2]; 1398761f8e4dSLazar Alexei } __packed; 1399761f8e4dSLazar Alexei 1400761f8e4dSLazar Alexei /* CMD: WMI_RF_XPM_READ_CMDID */ 1401761f8e4dSLazar Alexei struct wmi_rf_xpm_read_cmd { 1402761f8e4dSLazar Alexei u8 rf_id; 1403761f8e4dSLazar Alexei u8 reserved[3]; 1404761f8e4dSLazar Alexei /* XPM bit start address in range [0,8191]bits - rounded by FW to 1405761f8e4dSLazar Alexei * multiple of 8bits 1406761f8e4dSLazar Alexei */ 1407761f8e4dSLazar Alexei __le32 xpm_bit_address; 1408761f8e4dSLazar Alexei __le32 num_bytes; 1409761f8e4dSLazar Alexei } __packed; 1410761f8e4dSLazar Alexei 1411761f8e4dSLazar Alexei /* CMD: WMI_RF_XPM_WRITE_CMDID */ 1412761f8e4dSLazar Alexei struct wmi_rf_xpm_write_cmd { 1413761f8e4dSLazar Alexei u8 rf_id; 1414761f8e4dSLazar Alexei u8 reserved0[3]; 1415761f8e4dSLazar Alexei /* XPM bit start address in range [0,8191]bits - rounded by FW to 1416761f8e4dSLazar Alexei * multiple of 8bits 1417761f8e4dSLazar Alexei */ 1418761f8e4dSLazar Alexei __le32 xpm_bit_address; 1419761f8e4dSLazar Alexei __le32 num_bytes; 1420761f8e4dSLazar Alexei /* boolean flag indicating whether FW should verify the write 1421761f8e4dSLazar Alexei * operation 1422761f8e4dSLazar Alexei */ 1423761f8e4dSLazar Alexei u8 verify; 1424761f8e4dSLazar Alexei u8 reserved1[3]; 1425761f8e4dSLazar Alexei /* actual size=num_bytes */ 1426104f3d95SGustavo A. R. Silva u8 data_bytes[]; 1427b874ddecSLior David } __packed; 1428b874ddecSLior David 14299b586118STzahi Sabo /* Possible modes for temperature measurement */ 14308c679675SVladimir Kondratiev enum wmi_temperature_measure_mode { 1431b874ddecSLior David TEMPERATURE_USE_OLD_VALUE = 0x01, 1432b874ddecSLior David TEMPERATURE_MEASURE_NOW = 0x02, 14338c679675SVladimir Kondratiev }; 14348c679675SVladimir Kondratiev 1435b874ddecSLior David /* WMI_TEMP_SENSE_CMDID */ 1436b8023177SVladimir Kondratiev struct wmi_temp_sense_cmd { 14378c679675SVladimir Kondratiev __le32 measure_baseband_en; 14388c679675SVladimir Kondratiev __le32 measure_rf_en; 14398c679675SVladimir Kondratiev __le32 measure_mode; 1440b8023177SVladimir Kondratiev } __packed; 1441b8023177SVladimir Kondratiev 1442b874ddecSLior David enum wmi_pmc_op { 1443b874ddecSLior David WMI_PMC_ALLOCATE = 0x00, 1444b874ddecSLior David WMI_PMC_RELEASE = 0x01, 1445dc16427bSVladimir Kondratiev }; 1446dc16427bSVladimir Kondratiev 1447b874ddecSLior David /* WMI_PMC_CMDID */ 1448dc16427bSVladimir Kondratiev struct wmi_pmc_cmd { 1449b874ddecSLior David /* enum wmi_pmc_cmd_op_type */ 1450b874ddecSLior David u8 op; 1451dc16427bSVladimir Kondratiev u8 reserved; 1452dc16427bSVladimir Kondratiev __le16 ring_size; 1453dc16427bSVladimir Kondratiev __le64 mem_base; 1454dc16427bSVladimir Kondratiev } __packed; 1455dc16427bSVladimir Kondratiev 145608989f96SLior David enum wmi_aoa_meas_type { 145708989f96SLior David WMI_AOA_PHASE_MEAS = 0x00, 145808989f96SLior David WMI_AOA_PHASE_AMP_MEAS = 0x01, 145908989f96SLior David }; 146008989f96SLior David 146108989f96SLior David /* WMI_AOA_MEAS_CMDID */ 146208989f96SLior David struct wmi_aoa_meas_cmd { 146308989f96SLior David u8 mac_addr[WMI_MAC_LEN]; 146408989f96SLior David /* channels IDs: 146508989f96SLior David * 0 - 58320 MHz 146608989f96SLior David * 1 - 60480 MHz 146708989f96SLior David * 2 - 62640 MHz 146808989f96SLior David */ 146908989f96SLior David u8 channel; 147008989f96SLior David /* enum wmi_aoa_meas_type */ 147108989f96SLior David u8 aoa_meas_type; 147208989f96SLior David __le32 meas_rf_mask; 147308989f96SLior David } __packed; 147408989f96SLior David 1475cbf795c1SLior David /* WMI_SET_MGMT_RETRY_LIMIT_CMDID */ 1476cbf795c1SLior David struct wmi_set_mgmt_retry_limit_cmd { 1477cbf795c1SLior David /* MAC retransmit limit for mgmt frames */ 1478cbf795c1SLior David u8 mgmt_retry_limit; 1479cbf795c1SLior David /* alignment to 32b */ 1480cbf795c1SLior David u8 reserved[3]; 1481cbf795c1SLior David } __packed; 1482cbf795c1SLior David 148390ffabb0SDedy Lansky /* Zones: HIGH, MAX, CRITICAL */ 148490ffabb0SDedy Lansky #define WMI_NUM_OF_TT_ZONES (3) 148590ffabb0SDedy Lansky 148690ffabb0SDedy Lansky struct wmi_tt_zone_limits { 148790ffabb0SDedy Lansky /* Above this temperature this zone is active */ 148890ffabb0SDedy Lansky u8 temperature_high; 148990ffabb0SDedy Lansky /* Below this temperature the adjacent lower zone is active */ 149090ffabb0SDedy Lansky u8 temperature_low; 149190ffabb0SDedy Lansky u8 reserved[2]; 149290ffabb0SDedy Lansky } __packed; 149390ffabb0SDedy Lansky 149490ffabb0SDedy Lansky /* Struct used for both configuration and status commands of thermal 149590ffabb0SDedy Lansky * throttling 149690ffabb0SDedy Lansky */ 149790ffabb0SDedy Lansky struct wmi_tt_data { 149890ffabb0SDedy Lansky /* Enable/Disable TT algorithm for baseband */ 149990ffabb0SDedy Lansky u8 bb_enabled; 150090ffabb0SDedy Lansky u8 reserved0[3]; 150190ffabb0SDedy Lansky /* Define zones for baseband */ 150290ffabb0SDedy Lansky struct wmi_tt_zone_limits bb_zones[WMI_NUM_OF_TT_ZONES]; 150390ffabb0SDedy Lansky /* Enable/Disable TT algorithm for radio */ 150490ffabb0SDedy Lansky u8 rf_enabled; 150590ffabb0SDedy Lansky u8 reserved1[3]; 150690ffabb0SDedy Lansky /* Define zones for all radio chips */ 150790ffabb0SDedy Lansky struct wmi_tt_zone_limits rf_zones[WMI_NUM_OF_TT_ZONES]; 150890ffabb0SDedy Lansky } __packed; 150990ffabb0SDedy Lansky 151090ffabb0SDedy Lansky /* WMI_SET_THERMAL_THROTTLING_CFG_CMDID */ 151190ffabb0SDedy Lansky struct wmi_set_thermal_throttling_cfg_cmd { 151290ffabb0SDedy Lansky /* Command data */ 151390ffabb0SDedy Lansky struct wmi_tt_data tt_data; 151490ffabb0SDedy Lansky } __packed; 151590ffabb0SDedy Lansky 1516849a564bSDedy Lansky /* WMI_NEW_STA_CMDID */ 1517849a564bSDedy Lansky struct wmi_new_sta_cmd { 1518849a564bSDedy Lansky u8 dst_mac[WMI_MAC_LEN]; 1519849a564bSDedy Lansky u8 aid; 1520849a564bSDedy Lansky } __packed; 1521849a564bSDedy Lansky 1522849a564bSDedy Lansky /* WMI_DEL_STA_CMDID */ 1523849a564bSDedy Lansky struct wmi_del_sta_cmd { 1524849a564bSDedy Lansky u8 dst_mac[WMI_MAC_LEN]; 1525849a564bSDedy Lansky __le16 disconnect_reason; 1526849a564bSDedy Lansky } __packed; 1527849a564bSDedy Lansky 152808989f96SLior David enum wmi_tof_burst_duration { 152908989f96SLior David WMI_TOF_BURST_DURATION_250_USEC = 2, 153008989f96SLior David WMI_TOF_BURST_DURATION_500_USEC = 3, 153108989f96SLior David WMI_TOF_BURST_DURATION_1_MSEC = 4, 153208989f96SLior David WMI_TOF_BURST_DURATION_2_MSEC = 5, 153308989f96SLior David WMI_TOF_BURST_DURATION_4_MSEC = 6, 153408989f96SLior David WMI_TOF_BURST_DURATION_8_MSEC = 7, 153508989f96SLior David WMI_TOF_BURST_DURATION_16_MSEC = 8, 153608989f96SLior David WMI_TOF_BURST_DURATION_32_MSEC = 9, 153708989f96SLior David WMI_TOF_BURST_DURATION_64_MSEC = 10, 153808989f96SLior David WMI_TOF_BURST_DURATION_128_MSEC = 11, 153908989f96SLior David WMI_TOF_BURST_DURATION_NO_PREFERENCES = 15, 154008989f96SLior David }; 154108989f96SLior David 154208989f96SLior David enum wmi_tof_session_start_flags { 154308989f96SLior David WMI_TOF_SESSION_START_FLAG_SECURED = 0x1, 154408989f96SLior David WMI_TOF_SESSION_START_FLAG_ASAP = 0x2, 154508989f96SLior David WMI_TOF_SESSION_START_FLAG_LCI_REQ = 0x4, 154608989f96SLior David WMI_TOF_SESSION_START_FLAG_LCR_REQ = 0x8, 154708989f96SLior David }; 154808989f96SLior David 154908989f96SLior David /* WMI_TOF_SESSION_START_CMDID */ 155008989f96SLior David struct wmi_ftm_dest_info { 155108989f96SLior David u8 channel; 155208989f96SLior David /* wmi_tof_session_start_flags_e */ 155308989f96SLior David u8 flags; 155408989f96SLior David u8 initial_token; 155508989f96SLior David u8 num_of_ftm_per_burst; 155608989f96SLior David u8 num_of_bursts_exp; 155708989f96SLior David /* wmi_tof_burst_duration_e */ 155808989f96SLior David u8 burst_duration; 155908989f96SLior David /* Burst Period indicate interval between two consecutive burst 156008989f96SLior David * instances, in units of 100 ms 156108989f96SLior David */ 156208989f96SLior David __le16 burst_period; 156308989f96SLior David u8 dst_mac[WMI_MAC_LEN]; 1564761f8e4dSLazar Alexei u8 reserved; 1565761f8e4dSLazar Alexei u8 num_burst_per_aoa_meas; 156608989f96SLior David } __packed; 156708989f96SLior David 156808989f96SLior David /* WMI_TOF_SESSION_START_CMDID */ 156908989f96SLior David struct wmi_tof_session_start_cmd { 157008989f96SLior David __le32 session_id; 1571761f8e4dSLazar Alexei u8 reserved1; 157208989f96SLior David u8 aoa_type; 157308989f96SLior David __le16 num_of_dest; 157408989f96SLior David u8 reserved[4]; 1575104f3d95SGustavo A. R. Silva struct wmi_ftm_dest_info ftm_dest_info[]; 157608989f96SLior David } __packed; 157708989f96SLior David 1578761f8e4dSLazar Alexei /* WMI_TOF_CFG_RESPONDER_CMDID */ 1579761f8e4dSLazar Alexei struct wmi_tof_cfg_responder_cmd { 1580761f8e4dSLazar Alexei u8 enable; 1581761f8e4dSLazar Alexei u8 reserved[3]; 1582761f8e4dSLazar Alexei } __packed; 1583761f8e4dSLazar Alexei 158408989f96SLior David enum wmi_tof_channel_info_report_type { 158508989f96SLior David WMI_TOF_CHANNEL_INFO_TYPE_CIR = 0x1, 158608989f96SLior David WMI_TOF_CHANNEL_INFO_TYPE_RSSI = 0x2, 158708989f96SLior David WMI_TOF_CHANNEL_INFO_TYPE_SNR = 0x4, 158808989f96SLior David WMI_TOF_CHANNEL_INFO_TYPE_DEBUG_DATA = 0x8, 158908989f96SLior David WMI_TOF_CHANNEL_INFO_TYPE_VENDOR_SPECIFIC = 0x10, 159008989f96SLior David }; 159108989f96SLior David 159208989f96SLior David /* WMI_TOF_CHANNEL_INFO_CMDID */ 159308989f96SLior David struct wmi_tof_channel_info_cmd { 159408989f96SLior David /* wmi_tof_channel_info_report_type_e */ 159508989f96SLior David __le32 channel_info_report_request; 159608989f96SLior David } __packed; 159708989f96SLior David 15988ae5d62cSLior David /* WMI_TOF_SET_TX_RX_OFFSET_CMDID */ 15998ae5d62cSLior David struct wmi_tof_set_tx_rx_offset_cmd { 16008ae5d62cSLior David /* TX delay offset */ 16018ae5d62cSLior David __le32 tx_offset; 16028ae5d62cSLior David /* RX delay offset */ 16038ae5d62cSLior David __le32 rx_offset; 1604761f8e4dSLazar Alexei /* Mask to define which RFs to configure. 0 means all RFs */ 1605761f8e4dSLazar Alexei __le32 rf_mask; 1606761f8e4dSLazar Alexei /* Offset to strongest tap of CIR */ 1607761f8e4dSLazar Alexei __le32 precursor; 1608761f8e4dSLazar Alexei } __packed; 1609761f8e4dSLazar Alexei 1610761f8e4dSLazar Alexei /* WMI_TOF_GET_TX_RX_OFFSET_CMDID */ 1611761f8e4dSLazar Alexei struct wmi_tof_get_tx_rx_offset_cmd { 1612761f8e4dSLazar Alexei /* rf index to read offsets from */ 1613761f8e4dSLazar Alexei u8 rf_index; 1614761f8e4dSLazar Alexei u8 reserved[3]; 1615761f8e4dSLazar Alexei } __packed; 1616761f8e4dSLazar Alexei 1617761f8e4dSLazar Alexei /* WMI_FIXED_SCHEDULING_CONFIG_CMDID */ 1618761f8e4dSLazar Alexei struct wmi_map_mcs_to_schd_params { 1619761f8e4dSLazar Alexei u8 mcs; 1620761f8e4dSLazar Alexei /* time in usec from start slot to start tx flow - default 15 */ 1621761f8e4dSLazar Alexei u8 time_in_usec_before_initiate_tx; 1622761f8e4dSLazar Alexei /* RD enable - if yes consider RD according to STA mcs */ 1623761f8e4dSLazar Alexei u8 rd_enabled; 1624761f8e4dSLazar Alexei u8 reserved; 1625761f8e4dSLazar Alexei /* time in usec from start slot to stop vring */ 1626761f8e4dSLazar Alexei __le16 time_in_usec_to_stop_vring; 1627761f8e4dSLazar Alexei /* timeout to force flush from start of slot */ 1628761f8e4dSLazar Alexei __le16 flush_to_in_usec; 1629761f8e4dSLazar Alexei /* per mcs the mac buffer limit size in bytes */ 1630761f8e4dSLazar Alexei __le32 mac_buff_size_in_bytes; 1631761f8e4dSLazar Alexei } __packed; 1632761f8e4dSLazar Alexei 1633761f8e4dSLazar Alexei /* WMI_FIXED_SCHEDULING_CONFIG_COMPLETE_EVENTID */ 1634761f8e4dSLazar Alexei struct wmi_fixed_scheduling_config_complete_event { 1635761f8e4dSLazar Alexei /* wmi_fw_status */ 1636761f8e4dSLazar Alexei u8 status; 1637761f8e4dSLazar Alexei u8 reserved[3]; 1638761f8e4dSLazar Alexei } __packed; 1639761f8e4dSLazar Alexei 1640b5aeff16SDedy Lansky /* This value exists for backwards compatibility only. 1641b5aeff16SDedy Lansky * Do not use it in new commands. 1642b5aeff16SDedy Lansky * Use dynamic arrays where possible. 1643b5aeff16SDedy Lansky */ 1644761f8e4dSLazar Alexei #define WMI_NUM_MCS (13) 1645761f8e4dSLazar Alexei 1646761f8e4dSLazar Alexei /* WMI_FIXED_SCHEDULING_CONFIG_CMDID */ 1647761f8e4dSLazar Alexei struct wmi_fixed_scheduling_config_cmd { 1648761f8e4dSLazar Alexei /* defaults in the SAS table */ 1649761f8e4dSLazar Alexei struct wmi_map_mcs_to_schd_params mcs_to_schd_params_map[WMI_NUM_MCS]; 1650761f8e4dSLazar Alexei /* default 150 uSec */ 1651761f8e4dSLazar Alexei __le16 max_sta_rd_ppdu_duration_in_usec; 1652761f8e4dSLazar Alexei /* default 300 uSec */ 1653761f8e4dSLazar Alexei __le16 max_sta_grant_ppdu_duration_in_usec; 1654761f8e4dSLazar Alexei /* default 1000 uSec */ 1655761f8e4dSLazar Alexei __le16 assoc_slot_duration_in_usec; 1656761f8e4dSLazar Alexei /* default 360 uSec */ 1657761f8e4dSLazar Alexei __le16 virtual_slot_duration_in_usec; 1658761f8e4dSLazar Alexei /* each this field value slots start with grant frame to the station 1659761f8e4dSLazar Alexei * - default 2 1660761f8e4dSLazar Alexei */ 1661761f8e4dSLazar Alexei u8 number_of_ap_slots_for_initiate_grant; 1662761f8e4dSLazar Alexei u8 reserved[3]; 1663761f8e4dSLazar Alexei } __packed; 1664761f8e4dSLazar Alexei 1665761f8e4dSLazar Alexei /* WMI_ENABLE_FIXED_SCHEDULING_CMDID */ 1666761f8e4dSLazar Alexei struct wmi_enable_fixed_scheduling_cmd { 1667761f8e4dSLazar Alexei __le32 reserved; 1668761f8e4dSLazar Alexei } __packed; 1669761f8e4dSLazar Alexei 1670761f8e4dSLazar Alexei /* WMI_ENABLE_FIXED_SCHEDULING_COMPLETE_EVENTID */ 1671761f8e4dSLazar Alexei struct wmi_enable_fixed_scheduling_complete_event { 1672761f8e4dSLazar Alexei /* wmi_fw_status */ 1673761f8e4dSLazar Alexei u8 status; 1674761f8e4dSLazar Alexei u8 reserved[3]; 1675761f8e4dSLazar Alexei } __packed; 1676761f8e4dSLazar Alexei 1677761f8e4dSLazar Alexei /* WMI_SET_MULTI_DIRECTED_OMNIS_CONFIG_CMDID */ 1678761f8e4dSLazar Alexei struct wmi_set_multi_directed_omnis_config_cmd { 1679761f8e4dSLazar Alexei /* number of directed omnis at destination AP */ 1680761f8e4dSLazar Alexei u8 dest_ap_num_directed_omnis; 1681761f8e4dSLazar Alexei u8 reserved[3]; 1682761f8e4dSLazar Alexei } __packed; 1683761f8e4dSLazar Alexei 1684761f8e4dSLazar Alexei /* WMI_SET_MULTI_DIRECTED_OMNIS_CONFIG_EVENTID */ 1685761f8e4dSLazar Alexei struct wmi_set_multi_directed_omnis_config_event { 1686761f8e4dSLazar Alexei /* wmi_fw_status */ 1687761f8e4dSLazar Alexei u8 status; 1688761f8e4dSLazar Alexei u8 reserved[3]; 1689761f8e4dSLazar Alexei } __packed; 1690761f8e4dSLazar Alexei 16916a363e8aSAhmad Masri /* WMI_RADAR_GENERAL_CONFIG_EVENTID */ 16926a363e8aSAhmad Masri struct wmi_radar_general_config_event { 16936a363e8aSAhmad Masri /* wmi_fw_status */ 16946a363e8aSAhmad Masri u8 status; 16956a363e8aSAhmad Masri u8 reserved[3]; 16966a363e8aSAhmad Masri } __packed; 16976a363e8aSAhmad Masri 16986a363e8aSAhmad Masri /* WMI_RADAR_CONFIG_SELECT_EVENTID */ 16996a363e8aSAhmad Masri struct wmi_radar_config_select_event { 17006a363e8aSAhmad Masri /* wmi_fw_status */ 17016a363e8aSAhmad Masri u8 status; 17026a363e8aSAhmad Masri u8 reserved[3]; 17036a363e8aSAhmad Masri /* In unit of bytes */ 17046a363e8aSAhmad Masri __le32 fifo_size; 17056a363e8aSAhmad Masri /* In unit of bytes */ 17066a363e8aSAhmad Masri __le32 pulse_size; 17076a363e8aSAhmad Masri } __packed; 17086a363e8aSAhmad Masri 17096a363e8aSAhmad Masri /* WMI_RADAR_PARAMS_CONFIG_EVENTID */ 17106a363e8aSAhmad Masri struct wmi_radar_params_config_event { 17116a363e8aSAhmad Masri /* wmi_fw_status */ 17126a363e8aSAhmad Masri u8 status; 17136a363e8aSAhmad Masri u8 reserved[3]; 17146a363e8aSAhmad Masri } __packed; 17156a363e8aSAhmad Masri 17166a363e8aSAhmad Masri /* WMI_RADAR_SET_MODE_EVENTID */ 17176a363e8aSAhmad Masri struct wmi_radar_set_mode_event { 17186a363e8aSAhmad Masri /* wmi_fw_status */ 17196a363e8aSAhmad Masri u8 status; 17206a363e8aSAhmad Masri u8 reserved[3]; 17216a363e8aSAhmad Masri } __packed; 17226a363e8aSAhmad Masri 17236a363e8aSAhmad Masri /* WMI_RADAR_CONTROL_EVENTID */ 17246a363e8aSAhmad Masri struct wmi_radar_control_event { 17256a363e8aSAhmad Masri /* wmi_fw_status */ 17266a363e8aSAhmad Masri u8 status; 17276a363e8aSAhmad Masri u8 reserved[3]; 17286a363e8aSAhmad Masri } __packed; 17296a363e8aSAhmad Masri 17306a363e8aSAhmad Masri /* WMI_RADAR_PCI_CONTROL_EVENTID */ 17316a363e8aSAhmad Masri struct wmi_radar_pci_control_event { 17326a363e8aSAhmad Masri /* wmi_fw_status */ 17336a363e8aSAhmad Masri u8 status; 17346a363e8aSAhmad Masri u8 reserved[3]; 17356a363e8aSAhmad Masri } __packed; 17366a363e8aSAhmad Masri 1737761f8e4dSLazar Alexei /* WMI_SET_LONG_RANGE_CONFIG_CMDID */ 1738761f8e4dSLazar Alexei struct wmi_set_long_range_config_cmd { 1739761f8e4dSLazar Alexei __le32 reserved; 1740761f8e4dSLazar Alexei } __packed; 1741761f8e4dSLazar Alexei 1742761f8e4dSLazar Alexei /* WMI_SET_LONG_RANGE_CONFIG_COMPLETE_EVENTID */ 1743761f8e4dSLazar Alexei struct wmi_set_long_range_config_complete_event { 1744761f8e4dSLazar Alexei /* wmi_fw_status */ 1745761f8e4dSLazar Alexei u8 status; 1746761f8e4dSLazar Alexei u8 reserved[3]; 17478ae5d62cSLior David } __packed; 17488ae5d62cSLior David 1749b5aeff16SDedy Lansky /* payload max size is 1024 bytes: max event buffer size (1044) - WMI headers 17508a4fa214SAhmad Masri * (16) - prev struct field size (4) 17518a4fa214SAhmad Masri */ 1752b5aeff16SDedy Lansky #define WMI_MAX_IOCTL_PAYLOAD_SIZE (1024) 1753b5aeff16SDedy Lansky #define WMI_MAX_IOCTL_REPLY_PAYLOAD_SIZE (1024) 1754b5aeff16SDedy Lansky #define WMI_MAX_INTERNAL_EVENT_PAYLOAD_SIZE (1024) 17558a4fa214SAhmad Masri 17568a4fa214SAhmad Masri enum wmi_internal_fw_ioctl_code { 17578a4fa214SAhmad Masri WMI_INTERNAL_FW_CODE_NONE = 0x0, 17588a4fa214SAhmad Masri WMI_INTERNAL_FW_CODE_QCOM = 0x1, 17598a4fa214SAhmad Masri }; 17608a4fa214SAhmad Masri 17618a4fa214SAhmad Masri /* WMI_INTERNAL_FW_IOCTL_CMDID */ 17628a4fa214SAhmad Masri struct wmi_internal_fw_ioctl_cmd { 17638a4fa214SAhmad Masri /* enum wmi_internal_fw_ioctl_code */ 17648a4fa214SAhmad Masri __le16 code; 17658a4fa214SAhmad Masri __le16 length; 17668a4fa214SAhmad Masri /* payload max size is WMI_MAX_IOCTL_PAYLOAD_SIZE 17678a4fa214SAhmad Masri * Must be the last member of the struct 17688a4fa214SAhmad Masri */ 1769104f3d95SGustavo A. R. Silva __le32 payload[]; 17708a4fa214SAhmad Masri } __packed; 17718a4fa214SAhmad Masri 17728a4fa214SAhmad Masri /* WMI_INTERNAL_FW_IOCTL_EVENTID */ 17738a4fa214SAhmad Masri struct wmi_internal_fw_ioctl_event { 17748a4fa214SAhmad Masri /* wmi_fw_status */ 17758a4fa214SAhmad Masri u8 status; 17768a4fa214SAhmad Masri u8 reserved; 17778a4fa214SAhmad Masri __le16 length; 17788a4fa214SAhmad Masri /* payload max size is WMI_MAX_IOCTL_REPLY_PAYLOAD_SIZE 17798a4fa214SAhmad Masri * Must be the last member of the struct 17808a4fa214SAhmad Masri */ 1781104f3d95SGustavo A. R. Silva __le32 payload[]; 17828a4fa214SAhmad Masri } __packed; 17838a4fa214SAhmad Masri 17848a4fa214SAhmad Masri /* WMI_INTERNAL_FW_EVENT_EVENTID */ 17858a4fa214SAhmad Masri struct wmi_internal_fw_event_event { 17868a4fa214SAhmad Masri __le16 id; 17878a4fa214SAhmad Masri __le16 length; 17888a4fa214SAhmad Masri /* payload max size is WMI_MAX_INTERNAL_EVENT_PAYLOAD_SIZE 17898a4fa214SAhmad Masri * Must be the last member of the struct 17908a4fa214SAhmad Masri */ 1791104f3d95SGustavo A. R. Silva __le32 payload[]; 17928a4fa214SAhmad Masri } __packed; 17938a4fa214SAhmad Masri 1794b5aeff16SDedy Lansky /* WMI_SET_VRING_PRIORITY_WEIGHT_CMDID */ 1795b5aeff16SDedy Lansky struct wmi_set_vring_priority_weight_cmd { 1796b5aeff16SDedy Lansky /* Array of weights. Valid values are 1797b5aeff16SDedy Lansky * WMI_QOS_MIN_DEFAULT_WEIGHT...WMI_QOS_MAX_WEIGHT. Weight #0 is 1798b5aeff16SDedy Lansky * hard-coded WMI_QOS_MIN_WEIGHT. This array provide the weights 1799b5aeff16SDedy Lansky * #1..#3 1800b5aeff16SDedy Lansky */ 1801b5aeff16SDedy Lansky u8 weight[3]; 1802b5aeff16SDedy Lansky u8 reserved; 1803b5aeff16SDedy Lansky } __packed; 1804b5aeff16SDedy Lansky 1805b5aeff16SDedy Lansky /* WMI_SET_VRING_PRIORITY_CMDID */ 1806b5aeff16SDedy Lansky struct wmi_vring_priority { 1807b5aeff16SDedy Lansky u8 vring_idx; 1808b5aeff16SDedy Lansky /* Weight index. Valid value is 0-3 */ 1809b5aeff16SDedy Lansky u8 priority; 1810b5aeff16SDedy Lansky u8 reserved[2]; 1811b5aeff16SDedy Lansky } __packed; 1812b5aeff16SDedy Lansky 1813b5aeff16SDedy Lansky /* WMI_SET_VRING_PRIORITY_CMDID */ 1814b5aeff16SDedy Lansky struct wmi_set_vring_priority_cmd { 1815b5aeff16SDedy Lansky /* number of entries in vring_priority. Set to 1816b5aeff16SDedy Lansky * WMI_QOS_SET_VIF_PRIORITY to update the VIF's priority, and there 1817b5aeff16SDedy Lansky * will be only one entry in vring_priority 1818b5aeff16SDedy Lansky */ 1819b5aeff16SDedy Lansky u8 num_of_vrings; 1820b5aeff16SDedy Lansky u8 reserved[3]; 1821104f3d95SGustavo A. R. Silva struct wmi_vring_priority vring_priority[]; 1822b5aeff16SDedy Lansky } __packed; 1823b5aeff16SDedy Lansky 1824b5aeff16SDedy Lansky /* WMI_BF_CONTROL_CMDID - deprecated */ 18258a4fa214SAhmad Masri struct wmi_bf_control_cmd { 18268a4fa214SAhmad Masri /* wmi_bf_triggers */ 18278a4fa214SAhmad Masri __le32 triggers; 18288a4fa214SAhmad Masri u8 cid; 18298a4fa214SAhmad Masri /* DISABLED = 0, ENABLED = 1 , DRY_RUN = 2 */ 18308a4fa214SAhmad Masri u8 txss_mode; 18318a4fa214SAhmad Masri /* DISABLED = 0, ENABLED = 1, DRY_RUN = 2 */ 18328a4fa214SAhmad Masri u8 brp_mode; 18338a4fa214SAhmad Masri /* Max cts threshold (correspond to 18348a4fa214SAhmad Masri * WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_TXOP) 18358a4fa214SAhmad Masri */ 18368a4fa214SAhmad Masri u8 bf_trigger_max_cts_failure_thr; 18378a4fa214SAhmad Masri /* Max cts threshold in dense (correspond to 18388a4fa214SAhmad Masri * WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_TXOP) 18398a4fa214SAhmad Masri */ 18408a4fa214SAhmad Masri u8 bf_trigger_max_cts_failure_dense_thr; 18418a4fa214SAhmad Masri /* Max b-ack threshold (correspond to 18428a4fa214SAhmad Masri * WMI_BF_TRIGGER_MAX_BACK_FAILURE) 18438a4fa214SAhmad Masri */ 18448a4fa214SAhmad Masri u8 bf_trigger_max_back_failure_thr; 18458a4fa214SAhmad Masri /* Max b-ack threshold in dense (correspond to 18468a4fa214SAhmad Masri * WMI_BF_TRIGGER_MAX_BACK_FAILURE) 18478a4fa214SAhmad Masri */ 18488a4fa214SAhmad Masri u8 bf_trigger_max_back_failure_dense_thr; 18498a4fa214SAhmad Masri u8 reserved0; 18508a4fa214SAhmad Masri /* Wrong sectors threshold */ 18518a4fa214SAhmad Masri __le32 wrong_sector_bis_thr; 18528a4fa214SAhmad Masri /* BOOL to enable/disable long term trigger */ 18538a4fa214SAhmad Masri u8 long_term_enable; 18548a4fa214SAhmad Masri /* 1 = Update long term thresholds from the long_term_mbps_th_tbl and 18558a4fa214SAhmad Masri * long_term_trig_timeout_per_mcs arrays, 0 = Ignore 18568a4fa214SAhmad Masri */ 18578a4fa214SAhmad Masri u8 long_term_update_thr; 18588a4fa214SAhmad Masri /* Long term throughput threshold [Mbps] */ 18598a4fa214SAhmad Masri u8 long_term_mbps_th_tbl[WMI_NUM_MCS]; 18608a4fa214SAhmad Masri u8 reserved1; 18618a4fa214SAhmad Masri /* Long term timeout threshold table [msec] */ 18628a4fa214SAhmad Masri __le16 long_term_trig_timeout_per_mcs[WMI_NUM_MCS]; 18638a4fa214SAhmad Masri u8 reserved2[2]; 18648a4fa214SAhmad Masri } __packed; 18658a4fa214SAhmad Masri 1866b5aeff16SDedy Lansky /* BF configuration for each MCS */ 1867b5aeff16SDedy Lansky struct wmi_bf_control_ex_mcs { 1868b5aeff16SDedy Lansky /* Long term throughput threshold [Mbps] */ 1869b5aeff16SDedy Lansky u8 long_term_mbps_th_tbl; 1870b5aeff16SDedy Lansky u8 reserved; 1871b5aeff16SDedy Lansky /* Long term timeout threshold table [msec] */ 1872b5aeff16SDedy Lansky __le16 long_term_trig_timeout_per_mcs; 1873b5aeff16SDedy Lansky } __packed; 1874b5aeff16SDedy Lansky 1875b5aeff16SDedy Lansky /* WMI_BF_CONTROL_EX_CMDID */ 1876b5aeff16SDedy Lansky struct wmi_bf_control_ex_cmd { 1877b5aeff16SDedy Lansky /* wmi_bf_triggers */ 1878b5aeff16SDedy Lansky __le32 triggers; 1879b5aeff16SDedy Lansky /* enum wmi_edmg_tx_mode */ 1880b5aeff16SDedy Lansky u8 tx_mode; 1881b5aeff16SDedy Lansky /* DISABLED = 0, ENABLED = 1 , DRY_RUN = 2 */ 1882b5aeff16SDedy Lansky u8 txss_mode; 1883b5aeff16SDedy Lansky /* DISABLED = 0, ENABLED = 1, DRY_RUN = 2 */ 1884b5aeff16SDedy Lansky u8 brp_mode; 1885b5aeff16SDedy Lansky /* Max cts threshold (correspond to 1886b5aeff16SDedy Lansky * WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_TXOP) 1887b5aeff16SDedy Lansky */ 1888b5aeff16SDedy Lansky u8 bf_trigger_max_cts_failure_thr; 1889b5aeff16SDedy Lansky /* Max cts threshold in dense (correspond to 1890b5aeff16SDedy Lansky * WMI_BF_TRIGGER_MAX_CTS_FAILURE_IN_TXOP) 1891b5aeff16SDedy Lansky */ 1892b5aeff16SDedy Lansky u8 bf_trigger_max_cts_failure_dense_thr; 1893b5aeff16SDedy Lansky /* Max b-ack threshold (correspond to 1894b5aeff16SDedy Lansky * WMI_BF_TRIGGER_MAX_BACK_FAILURE) 1895b5aeff16SDedy Lansky */ 1896b5aeff16SDedy Lansky u8 bf_trigger_max_back_failure_thr; 1897b5aeff16SDedy Lansky /* Max b-ack threshold in dense (correspond to 1898b5aeff16SDedy Lansky * WMI_BF_TRIGGER_MAX_BACK_FAILURE) 1899b5aeff16SDedy Lansky */ 1900b5aeff16SDedy Lansky u8 bf_trigger_max_back_failure_dense_thr; 1901b5aeff16SDedy Lansky u8 reserved0; 1902b5aeff16SDedy Lansky /* Wrong sectors threshold */ 1903b5aeff16SDedy Lansky __le32 wrong_sector_bis_thr; 1904b5aeff16SDedy Lansky /* BOOL to enable/disable long term trigger */ 1905b5aeff16SDedy Lansky u8 long_term_enable; 1906b5aeff16SDedy Lansky /* 1 = Update long term thresholds from the long_term_mbps_th_tbl and 1907b5aeff16SDedy Lansky * long_term_trig_timeout_per_mcs arrays, 0 = Ignore 1908b5aeff16SDedy Lansky */ 1909b5aeff16SDedy Lansky u8 long_term_update_thr; 1910b5aeff16SDedy Lansky u8 each_mcs_cfg_size; 1911b5aeff16SDedy Lansky u8 reserved1; 1912b5aeff16SDedy Lansky /* Configuration for each MCS */ 1913104f3d95SGustavo A. R. Silva struct wmi_bf_control_ex_mcs each_mcs_cfg[]; 1914b5aeff16SDedy Lansky } __packed; 1915b5aeff16SDedy Lansky 1916b5aeff16SDedy Lansky /* WMI_LINK_STATS_CMD */ 1917b5aeff16SDedy Lansky enum wmi_link_stats_action { 1918b5aeff16SDedy Lansky WMI_LINK_STATS_SNAPSHOT = 0x00, 1919b5aeff16SDedy Lansky WMI_LINK_STATS_PERIODIC = 0x01, 1920b5aeff16SDedy Lansky WMI_LINK_STATS_STOP_PERIODIC = 0x02, 1921b5aeff16SDedy Lansky }; 1922b5aeff16SDedy Lansky 1923b5aeff16SDedy Lansky /* WMI_LINK_STATS_EVENT record identifiers */ 1924b5aeff16SDedy Lansky enum wmi_link_stats_record_type { 1925b5aeff16SDedy Lansky WMI_LINK_STATS_TYPE_BASIC = 0x01, 19260c936b3cSDedy Lansky WMI_LINK_STATS_TYPE_GLOBAL = 0x02, 1927b5aeff16SDedy Lansky }; 1928b5aeff16SDedy Lansky 1929b5aeff16SDedy Lansky /* WMI_LINK_STATS_CMDID */ 1930b5aeff16SDedy Lansky struct wmi_link_stats_cmd { 1931b5aeff16SDedy Lansky /* bitmask of required record types 1932b5aeff16SDedy Lansky * (wmi_link_stats_record_type_e) 1933b5aeff16SDedy Lansky */ 1934b5aeff16SDedy Lansky __le32 record_type_mask; 1935b5aeff16SDedy Lansky /* 0xff for all cids */ 1936b5aeff16SDedy Lansky u8 cid; 1937b5aeff16SDedy Lansky /* wmi_link_stats_action_e */ 1938b5aeff16SDedy Lansky u8 action; 1939b5aeff16SDedy Lansky u8 reserved[6]; 19400c936b3cSDedy Lansky /* range = 100 - 10000 */ 1941b5aeff16SDedy Lansky __le32 interval_msec; 1942b5aeff16SDedy Lansky } __packed; 1943b5aeff16SDedy Lansky 1944b5aeff16SDedy Lansky /* WMI_SET_GRANT_MCS_CMDID */ 1945b5aeff16SDedy Lansky struct wmi_set_grant_mcs_cmd { 1946b5aeff16SDedy Lansky u8 mcs; 1947b5aeff16SDedy Lansky u8 reserved[3]; 1948b5aeff16SDedy Lansky } __packed; 1949b5aeff16SDedy Lansky 1950b5aeff16SDedy Lansky /* WMI_SET_AP_SLOT_SIZE_CMDID */ 1951b5aeff16SDedy Lansky struct wmi_set_ap_slot_size_cmd { 1952b5aeff16SDedy Lansky __le32 slot_size; 1953b5aeff16SDedy Lansky } __packed; 1954b5aeff16SDedy Lansky 19559b586118STzahi Sabo /* WMI_TEMP_SENSE_ALL_CMDID */ 19569b586118STzahi Sabo struct wmi_temp_sense_all_cmd { 19579b586118STzahi Sabo u8 measure_baseband_en; 19589b586118STzahi Sabo u8 measure_rf_en; 19599b586118STzahi Sabo u8 measure_mode; 19609b586118STzahi Sabo u8 reserved; 19619b586118STzahi Sabo } __packed; 19629b586118STzahi Sabo 1963b874ddecSLior David /* WMI Events 19642be7d22fSVladimir Kondratiev * List of Events (target to host) 19652be7d22fSVladimir Kondratiev */ 19662be7d22fSVladimir Kondratiev enum wmi_event_id { 19672be7d22fSVladimir Kondratiev WMI_READY_EVENTID = 0x1001, 19682be7d22fSVladimir Kondratiev WMI_CONNECT_EVENTID = 0x1002, 19692be7d22fSVladimir Kondratiev WMI_DISCONNECT_EVENTID = 0x1003, 1970a5dc6883SDedy Lansky WMI_START_SCHED_SCAN_EVENTID = 0x1005, 1971a5dc6883SDedy Lansky WMI_STOP_SCHED_SCAN_EVENTID = 0x1006, 1972a5dc6883SDedy Lansky WMI_SCHED_SCAN_RESULT_EVENTID = 0x1007, 1973b874ddecSLior David WMI_SCAN_COMPLETE_EVENTID = 0x100A, 1974b874ddecSLior David WMI_REPORT_STATISTICS_EVENTID = 0x100B, 1975b5aeff16SDedy Lansky WMI_FT_AUTH_STATUS_EVENTID = 0x100C, 1976b5aeff16SDedy Lansky WMI_FT_REASSOC_STATUS_EVENTID = 0x100D, 19774315a74aSDedy Lansky WMI_LINK_MONITOR_EVENTID = 0x100E, 19786a363e8aSAhmad Masri WMI_RADAR_GENERAL_CONFIG_EVENTID = 0x1100, 19796a363e8aSAhmad Masri WMI_RADAR_CONFIG_SELECT_EVENTID = 0x1101, 19806a363e8aSAhmad Masri WMI_RADAR_PARAMS_CONFIG_EVENTID = 0x1102, 19816a363e8aSAhmad Masri WMI_RADAR_SET_MODE_EVENTID = 0x1103, 19826a363e8aSAhmad Masri WMI_RADAR_CONTROL_EVENTID = 0x1104, 19836a363e8aSAhmad Masri WMI_RADAR_PCI_CONTROL_EVENTID = 0x1105, 19842be7d22fSVladimir Kondratiev WMI_RD_MEM_RSP_EVENTID = 0x1800, 19852be7d22fSVladimir Kondratiev WMI_FW_READY_EVENTID = 0x1801, 1986b874ddecSLior David WMI_EXIT_FAST_MEM_ACC_MODE_EVENTID = 0x200, 19872be7d22fSVladimir Kondratiev WMI_ECHO_RSP_EVENTID = 0x1803, 19886a363e8aSAhmad Masri WMI_DEEP_ECHO_RSP_EVENTID = 0x1804, 1989761f8e4dSLazar Alexei /* deprecated */ 1990b874ddecSLior David WMI_FS_TUNE_DONE_EVENTID = 0x180A, 1991761f8e4dSLazar Alexei /* deprecated */ 1992b874ddecSLior David WMI_CORR_MEASURE_EVENTID = 0x180B, 1993b874ddecSLior David WMI_READ_RSSI_EVENTID = 0x180C, 1994b874ddecSLior David WMI_TEMP_SENSE_DONE_EVENTID = 0x180E, 1995b874ddecSLior David WMI_DC_CALIB_DONE_EVENTID = 0x180F, 1996761f8e4dSLazar Alexei /* deprecated */ 19972be7d22fSVladimir Kondratiev WMI_IQ_TX_CALIB_DONE_EVENTID = 0x1811, 1998761f8e4dSLazar Alexei /* deprecated */ 19992be7d22fSVladimir Kondratiev WMI_IQ_RX_CALIB_DONE_EVENTID = 0x1812, 20002be7d22fSVladimir Kondratiev WMI_SET_WORK_MODE_DONE_EVENTID = 0x1815, 20012be7d22fSVladimir Kondratiev WMI_LO_LEAKAGE_CALIB_DONE_EVENTID = 0x1816, 2002761f8e4dSLazar Alexei WMI_LO_POWER_CALIB_FROM_OTP_EVENTID = 0x1817, 2003b874ddecSLior David WMI_SILENT_RSSI_CALIB_DONE_EVENTID = 0x181D, 2004761f8e4dSLazar Alexei /* deprecated */ 2005b874ddecSLior David WMI_RF_RX_TEST_DONE_EVENTID = 0x181E, 20062be7d22fSVladimir Kondratiev WMI_CFG_RX_CHAIN_DONE_EVENTID = 0x1820, 20072be7d22fSVladimir Kondratiev WMI_VRING_CFG_DONE_EVENTID = 0x1821, 20082be7d22fSVladimir Kondratiev WMI_BA_STATUS_EVENTID = 0x1823, 20092be7d22fSVladimir Kondratiev WMI_RCP_ADDBA_REQ_EVENTID = 0x1824, 2010230d8442SVladimir Kondratiev WMI_RCP_ADDBA_RESP_SENT_EVENTID = 0x1825, 20112be7d22fSVladimir Kondratiev WMI_DELBA_EVENTID = 0x1826, 20122be7d22fSVladimir Kondratiev WMI_GET_SSID_EVENTID = 0x1828, 2013b874ddecSLior David WMI_GET_PCP_CHANNEL_EVENTID = 0x182A, 20146a363e8aSAhmad Masri /* Event is shared between WMI_SW_TX_REQ_CMDID and 20156a363e8aSAhmad Masri * WMI_SW_TX_REQ_EXT_CMDID 20166a363e8aSAhmad Masri */ 2017b874ddecSLior David WMI_SW_TX_COMPLETE_EVENTID = 0x182B, 2018230d8442SVladimir Kondratiev WMI_BEAMFORMING_MGMT_DONE_EVENTID = 0x1836, 20192be7d22fSVladimir Kondratiev WMI_BF_TXSS_MGMT_DONE_EVENTID = 0x1837, 20202be7d22fSVladimir Kondratiev WMI_BF_RXSS_MGMT_DONE_EVENTID = 0x1839, 202173a7d1e3SAlexei Avshalom Lazar WMI_BF_TRIG_EVENTID = 0x183A, 20222be7d22fSVladimir Kondratiev WMI_RS_MGMT_DONE_EVENTID = 0x1852, 20232be7d22fSVladimir Kondratiev WMI_RF_MGMT_STATUS_EVENTID = 0x1853, 20242be7d22fSVladimir Kondratiev WMI_BF_SM_MGMT_DONE_EVENTID = 0x1838, 20252be7d22fSVladimir Kondratiev WMI_RX_MGMT_PACKET_EVENTID = 0x1840, 20266c2faf09SVladimir Kondratiev WMI_TX_MGMT_PACKET_EVENTID = 0x1841, 20270163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_WRITE_DONE_EVENTID = 0x1842, 20280163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_READ_DONE_EVENTID = 0x1843, 20294315a74aSDedy Lansky WMI_SET_LINK_MONITOR_EVENTID = 0x1845, 2030761f8e4dSLazar Alexei WMI_RF_XPM_READ_RESULT_EVENTID = 0x1856, 2031761f8e4dSLazar Alexei WMI_RF_XPM_WRITE_RESULT_EVENTID = 0x1857, 203210d599adSMaya Erez WMI_LED_CFG_DONE_EVENTID = 0x1858, 2033761f8e4dSLazar Alexei WMI_SET_SILENT_RSSI_TABLE_DONE_EVENTID = 0x185C, 2034761f8e4dSLazar Alexei WMI_RF_PWR_ON_DELAY_RSP_EVENTID = 0x185D, 2035761f8e4dSLazar Alexei WMI_SET_HIGH_POWER_TABLE_PARAMS_EVENTID = 0x185E, 20368a4fa214SAhmad Masri WMI_FIXED_SCHEDULING_UL_CONFIG_EVENTID = 0x185F, 20372be7d22fSVladimir Kondratiev /* Performance monitoring events */ 20382be7d22fSVladimir Kondratiev WMI_DATA_PORT_OPEN_EVENTID = 0x1860, 2039230d8442SVladimir Kondratiev WMI_WBE_LINK_DOWN_EVENTID = 0x1861, 20402be7d22fSVladimir Kondratiev WMI_BF_CTRL_DONE_EVENTID = 0x1862, 20412be7d22fSVladimir Kondratiev WMI_NOTIFY_REQ_DONE_EVENTID = 0x1863, 20422be7d22fSVladimir Kondratiev WMI_GET_STATUS_DONE_EVENTID = 0x1864, 204396c93589SGidon Studinski WMI_RING_EN_EVENTID = 0x1865, 20440163b031SMaya Erez WMI_GET_RF_STATUS_EVENTID = 0x1866, 20450163b031SMaya Erez WMI_GET_BASEBAND_TYPE_EVENTID = 0x1867, 20468a4fa214SAhmad Masri WMI_VRING_SWITCH_TIMING_CONFIG_EVENTID = 0x1868, 20472be7d22fSVladimir Kondratiev WMI_UNIT_TEST_EVENTID = 0x1900, 20482be7d22fSVladimir Kondratiev WMI_FLASH_READ_DONE_EVENTID = 0x1902, 20492be7d22fSVladimir Kondratiev WMI_FLASH_WRITE_DONE_EVENTID = 0x1903, 20500163b031SMaya Erez /* Power management */ 2051fe9ee51eSMaya Erez WMI_TRAFFIC_SUSPEND_EVENTID = 0x1904, 20520163b031SMaya Erez WMI_TRAFFIC_RESUME_EVENTID = 0x1905, 2053b8023177SVladimir Kondratiev /* P2P */ 20548c679675SVladimir Kondratiev WMI_P2P_CFG_DONE_EVENTID = 0x1910, 2055b8023177SVladimir Kondratiev WMI_PORT_ALLOCATED_EVENTID = 0x1911, 2056b8023177SVladimir Kondratiev WMI_PORT_DELETED_EVENTID = 0x1912, 2057b8023177SVladimir Kondratiev WMI_LISTEN_STARTED_EVENTID = 0x1914, 2058b8023177SVladimir Kondratiev WMI_SEARCH_STARTED_EVENTID = 0x1915, 2059b8023177SVladimir Kondratiev WMI_DISCOVERY_STARTED_EVENTID = 0x1916, 2060b8023177SVladimir Kondratiev WMI_DISCOVERY_STOPPED_EVENTID = 0x1917, 2061b8023177SVladimir Kondratiev WMI_PCP_STARTED_EVENTID = 0x1918, 2062b8023177SVladimir Kondratiev WMI_PCP_STOPPED_EVENTID = 0x1919, 2063b874ddecSLior David WMI_PCP_FACTOR_EVENTID = 0x191A, 20640163b031SMaya Erez /* Power Save Configuration Events */ 20650163b031SMaya Erez WMI_PS_DEV_PROFILE_CFG_EVENTID = 0x191C, 2066b5aeff16SDedy Lansky WMI_RS_ENABLE_EVENTID = 0x191E, 2067b5aeff16SDedy Lansky WMI_RS_CFG_EX_EVENTID = 0x191F, 2068b5aeff16SDedy Lansky WMI_GET_DETAILED_RS_RES_EX_EVENTID = 0x1920, 2069b5aeff16SDedy Lansky /* deprecated */ 20700163b031SMaya Erez WMI_RS_CFG_DONE_EVENTID = 0x1921, 2071b5aeff16SDedy Lansky /* deprecated */ 207208989f96SLior David WMI_GET_DETAILED_RS_RES_EVENTID = 0x1922, 207308989f96SLior David WMI_AOA_MEAS_EVENTID = 0x1923, 2074a52fb913SLior David WMI_BRP_SET_ANT_LIMIT_EVENTID = 0x1924, 2075cbf795c1SLior David WMI_SET_MGMT_RETRY_LIMIT_EVENTID = 0x1930, 2076cbf795c1SLior David WMI_GET_MGMT_RETRY_LIMIT_EVENTID = 0x1931, 207790ffabb0SDedy Lansky WMI_SET_THERMAL_THROTTLING_CFG_EVENTID = 0x1940, 207890ffabb0SDedy Lansky WMI_GET_THERMAL_THROTTLING_CFG_EVENTID = 0x1941, 2079761f8e4dSLazar Alexei /* return the Power Save profile */ 2080761f8e4dSLazar Alexei WMI_PS_DEV_PROFILE_CFG_READ_EVENTID = 0x1942, 20818a4fa214SAhmad Masri WMI_TSF_SYNC_STATUS_EVENTID = 0x1973, 208208989f96SLior David WMI_TOF_SESSION_END_EVENTID = 0x1991, 208308989f96SLior David WMI_TOF_GET_CAPABILITIES_EVENTID = 0x1992, 208408989f96SLior David WMI_TOF_SET_LCR_EVENTID = 0x1993, 208508989f96SLior David WMI_TOF_SET_LCI_EVENTID = 0x1994, 208608989f96SLior David WMI_TOF_FTM_PER_DEST_RES_EVENTID = 0x1995, 2087761f8e4dSLazar Alexei WMI_TOF_CFG_RESPONDER_EVENTID = 0x1996, 20888ae5d62cSLior David WMI_TOF_SET_TX_RX_OFFSET_EVENTID = 0x1997, 20898ae5d62cSLior David WMI_TOF_GET_TX_RX_OFFSET_EVENTID = 0x1998, 2090761f8e4dSLazar Alexei WMI_TOF_CHANNEL_INFO_EVENTID = 0x1999, 2091cbf795c1SLior David WMI_GET_RF_SECTOR_PARAMS_DONE_EVENTID = 0x19A0, 2092cbf795c1SLior David WMI_SET_RF_SECTOR_PARAMS_DONE_EVENTID = 0x19A1, 2093cbf795c1SLior David WMI_GET_SELECTED_RF_SECTOR_INDEX_DONE_EVENTID = 0x19A2, 2094cbf795c1SLior David WMI_SET_SELECTED_RF_SECTOR_INDEX_DONE_EVENTID = 0x19A3, 2095cbf795c1SLior David WMI_SET_RF_SECTOR_ON_DONE_EVENTID = 0x19A4, 20968ae5d62cSLior David WMI_PRIO_TX_SECTORS_ORDER_EVENTID = 0x19A5, 20978ae5d62cSLior David WMI_PRIO_TX_SECTORS_NUMBER_EVENTID = 0x19A6, 20988ae5d62cSLior David WMI_PRIO_TX_SECTORS_SET_DEFAULT_CFG_EVENTID = 0x19A7, 2099b5aeff16SDedy Lansky /* deprecated */ 21008a4fa214SAhmad Masri WMI_BF_CONTROL_EVENTID = 0x19AA, 2101b5aeff16SDedy Lansky WMI_BF_CONTROL_EX_EVENTID = 0x19AB, 210296c93589SGidon Studinski WMI_TX_STATUS_RING_CFG_DONE_EVENTID = 0x19C0, 210396c93589SGidon Studinski WMI_RX_STATUS_RING_CFG_DONE_EVENTID = 0x19C1, 210496c93589SGidon Studinski WMI_TX_DESC_RING_CFG_DONE_EVENTID = 0x19C2, 210596c93589SGidon Studinski WMI_RX_DESC_RING_CFG_DONE_EVENTID = 0x19C3, 210696c93589SGidon Studinski WMI_CFG_DEF_RX_OFFLOAD_DONE_EVENTID = 0x19C5, 2107761f8e4dSLazar Alexei WMI_SCHEDULING_SCHEME_EVENTID = 0x1A01, 2108761f8e4dSLazar Alexei WMI_FIXED_SCHEDULING_CONFIG_COMPLETE_EVENTID = 0x1A02, 2109761f8e4dSLazar Alexei WMI_ENABLE_FIXED_SCHEDULING_COMPLETE_EVENTID = 0x1A03, 2110761f8e4dSLazar Alexei WMI_SET_MULTI_DIRECTED_OMNIS_CONFIG_EVENTID = 0x1A04, 2111761f8e4dSLazar Alexei WMI_SET_LONG_RANGE_CONFIG_COMPLETE_EVENTID = 0x1A05, 21128a4fa214SAhmad Masri WMI_GET_ASSOC_LIST_RES_EVENTID = 0x1A06, 21138a4fa214SAhmad Masri WMI_GET_CCA_INDICATIONS_EVENTID = 0x1A07, 21148a4fa214SAhmad Masri WMI_SET_CCA_INDICATIONS_BI_AVG_NUM_EVENTID = 0x1A08, 21158a4fa214SAhmad Masri WMI_INTERNAL_FW_EVENT_EVENTID = 0x1A0A, 21168a4fa214SAhmad Masri WMI_INTERNAL_FW_IOCTL_EVENTID = 0x1A0B, 2117b5aeff16SDedy Lansky WMI_LINK_STATS_CONFIG_DONE_EVENTID = 0x1A0C, 2118b5aeff16SDedy Lansky WMI_LINK_STATS_EVENTID = 0x1A0D, 2119b5aeff16SDedy Lansky WMI_SET_GRANT_MCS_EVENTID = 0x1A0E, 2120b5aeff16SDedy Lansky WMI_SET_AP_SLOT_SIZE_EVENTID = 0x1A0F, 2121b5aeff16SDedy Lansky WMI_SET_VRING_PRIORITY_WEIGHT_EVENTID = 0x1A10, 2122b5aeff16SDedy Lansky WMI_SET_VRING_PRIORITY_EVENTID = 0x1A11, 212373a7d1e3SAlexei Avshalom Lazar WMI_RBUFCAP_CFG_EVENTID = 0x1A12, 21249b586118STzahi Sabo WMI_TEMP_SENSE_ALL_DONE_EVENTID = 0x1A13, 21252be7d22fSVladimir Kondratiev WMI_SET_CHANNEL_EVENTID = 0x9000, 21262be7d22fSVladimir Kondratiev WMI_ASSOC_REQ_EVENTID = 0x9001, 21272be7d22fSVladimir Kondratiev WMI_EAPOL_RX_EVENTID = 0x9002, 21282be7d22fSVladimir Kondratiev WMI_MAC_ADDR_RESP_EVENTID = 0x9003, 21292be7d22fSVladimir Kondratiev WMI_FW_VER_EVENTID = 0x9004, 2130b874ddecSLior David WMI_ACS_PASSIVE_SCAN_COMPLETE_EVENTID = 0x9005, 21318a4fa214SAhmad Masri WMI_INTERNAL_FW_SET_CHANNEL = 0x9006, 2132761f8e4dSLazar Alexei WMI_COMMAND_NOT_SUPPORTED_EVENTID = 0xFFFF, 21332be7d22fSVladimir Kondratiev }; 21342be7d22fSVladimir Kondratiev 2135b874ddecSLior David /* Events data structures */ 2136b8023177SVladimir Kondratiev enum wmi_fw_status { 2137b874ddecSLior David WMI_FW_STATUS_SUCCESS = 0x00, 2138b874ddecSLior David WMI_FW_STATUS_FAILURE = 0x01, 2139b8023177SVladimir Kondratiev }; 2140b8023177SVladimir Kondratiev 2141b874ddecSLior David /* WMI_RF_MGMT_STATUS_EVENTID */ 21422be7d22fSVladimir Kondratiev enum wmi_rf_status { 2143b874ddecSLior David WMI_RF_ENABLED = 0x00, 2144b874ddecSLior David WMI_RF_DISABLED_HW = 0x01, 2145b874ddecSLior David WMI_RF_DISABLED_SW = 0x02, 2146b874ddecSLior David WMI_RF_DISABLED_HW_SW = 0x03, 21472be7d22fSVladimir Kondratiev }; 21482be7d22fSVladimir Kondratiev 2149b874ddecSLior David /* WMI_RF_MGMT_STATUS_EVENTID */ 21502be7d22fSVladimir Kondratiev struct wmi_rf_mgmt_status_event { 21512be7d22fSVladimir Kondratiev __le32 rf_status; 21522be7d22fSVladimir Kondratiev } __packed; 21532be7d22fSVladimir Kondratiev 2154b874ddecSLior David /* WMI_GET_STATUS_DONE_EVENTID */ 21552be7d22fSVladimir Kondratiev struct wmi_get_status_done_event { 21562be7d22fSVladimir Kondratiev __le32 is_associated; 21572be7d22fSVladimir Kondratiev u8 cid; 21582be7d22fSVladimir Kondratiev u8 reserved0[3]; 21592be7d22fSVladimir Kondratiev u8 bssid[WMI_MAC_LEN]; 21602be7d22fSVladimir Kondratiev u8 channel; 21612be7d22fSVladimir Kondratiev u8 reserved1; 21622be7d22fSVladimir Kondratiev u8 network_type; 21632be7d22fSVladimir Kondratiev u8 reserved2[3]; 21642be7d22fSVladimir Kondratiev __le32 ssid_len; 21652be7d22fSVladimir Kondratiev u8 ssid[WMI_MAX_SSID_LEN]; 21662be7d22fSVladimir Kondratiev __le32 rf_status; 21672be7d22fSVladimir Kondratiev __le32 is_secured; 21682be7d22fSVladimir Kondratiev } __packed; 21692be7d22fSVladimir Kondratiev 2170b874ddecSLior David /* WMI_FW_VER_EVENTID */ 21712be7d22fSVladimir Kondratiev struct wmi_fw_ver_event { 21720163b031SMaya Erez /* FW image version */ 21730163b031SMaya Erez __le32 fw_major; 21740163b031SMaya Erez __le32 fw_minor; 21750163b031SMaya Erez __le32 fw_subminor; 21760163b031SMaya Erez __le32 fw_build; 21770163b031SMaya Erez /* FW image build time stamp */ 21780163b031SMaya Erez __le32 hour; 21790163b031SMaya Erez __le32 minute; 21800163b031SMaya Erez __le32 second; 21810163b031SMaya Erez __le32 day; 21820163b031SMaya Erez __le32 month; 21830163b031SMaya Erez __le32 year; 21840163b031SMaya Erez /* Boot Loader image version */ 21850163b031SMaya Erez __le32 bl_major; 21860163b031SMaya Erez __le32 bl_minor; 21870163b031SMaya Erez __le32 bl_subminor; 21880163b031SMaya Erez __le32 bl_build; 2189761f8e4dSLazar Alexei /* The number of entries in the FW capabilities array */ 219008989f96SLior David u8 fw_capabilities_len; 219108989f96SLior David u8 reserved[3]; 219208989f96SLior David /* FW capabilities info 219308989f96SLior David * Must be the last member of the struct 219408989f96SLior David */ 2195104f3d95SGustavo A. R. Silva __le32 fw_capabilities[]; 21960163b031SMaya Erez } __packed; 21970163b031SMaya Erez 21980163b031SMaya Erez /* WMI_GET_RF_STATUS_EVENTID */ 21990163b031SMaya Erez enum rf_type { 22000163b031SMaya Erez RF_UNKNOWN = 0x00, 22010163b031SMaya Erez RF_MARLON = 0x01, 22020163b031SMaya Erez RF_SPARROW = 0x02, 22038a4fa214SAhmad Masri RF_TALYNA1 = 0x03, 22048a4fa214SAhmad Masri RF_TALYNA2 = 0x04, 22050163b031SMaya Erez }; 22060163b031SMaya Erez 22070163b031SMaya Erez /* WMI_GET_RF_STATUS_EVENTID */ 22080163b031SMaya Erez enum board_file_rf_type { 22090163b031SMaya Erez BF_RF_MARLON = 0x00, 22100163b031SMaya Erez BF_RF_SPARROW = 0x01, 22118a4fa214SAhmad Masri BF_RF_TALYNA1 = 0x02, 22128a4fa214SAhmad Masri BF_RF_TALYNA2 = 0x03, 22130163b031SMaya Erez }; 22140163b031SMaya Erez 22150163b031SMaya Erez /* WMI_GET_RF_STATUS_EVENTID */ 22160163b031SMaya Erez enum rf_status { 22170163b031SMaya Erez RF_OK = 0x00, 22180163b031SMaya Erez RF_NO_COMM = 0x01, 22190163b031SMaya Erez RF_WRONG_BOARD_FILE = 0x02, 22200163b031SMaya Erez }; 22210163b031SMaya Erez 22220163b031SMaya Erez /* WMI_GET_RF_STATUS_EVENTID */ 22230163b031SMaya Erez struct wmi_get_rf_status_event { 22240163b031SMaya Erez /* enum rf_type */ 22250163b031SMaya Erez __le32 rf_type; 22260163b031SMaya Erez /* attached RFs bit vector */ 22270163b031SMaya Erez __le32 attached_rf_vector; 22280163b031SMaya Erez /* enabled RFs bit vector */ 22290163b031SMaya Erez __le32 enabled_rf_vector; 22300163b031SMaya Erez /* enum rf_status, refers to enabled RFs */ 22310163b031SMaya Erez u8 rf_status[32]; 22320163b031SMaya Erez /* enum board file RF type */ 22330163b031SMaya Erez __le32 board_file_rf_type; 22340163b031SMaya Erez /* board file platform type */ 22350163b031SMaya Erez __le32 board_file_platform_type; 22360163b031SMaya Erez /* board file version */ 22370163b031SMaya Erez __le32 board_file_version; 2238761f8e4dSLazar Alexei /* enabled XIFs bit vector */ 2239761f8e4dSLazar Alexei __le32 enabled_xif_vector; 2240761f8e4dSLazar Alexei __le32 reserved; 22410163b031SMaya Erez } __packed; 22420163b031SMaya Erez 22430163b031SMaya Erez /* WMI_GET_BASEBAND_TYPE_EVENTID */ 22440163b031SMaya Erez enum baseband_type { 22450163b031SMaya Erez BASEBAND_UNKNOWN = 0x00, 22460163b031SMaya Erez BASEBAND_SPARROW_M_A0 = 0x03, 22470163b031SMaya Erez BASEBAND_SPARROW_M_A1 = 0x04, 22480163b031SMaya Erez BASEBAND_SPARROW_M_B0 = 0x05, 22490163b031SMaya Erez BASEBAND_SPARROW_M_C0 = 0x06, 22500163b031SMaya Erez BASEBAND_SPARROW_M_D0 = 0x07, 22518ae5d62cSLior David BASEBAND_TALYN_M_A0 = 0x08, 22528a4fa214SAhmad Masri BASEBAND_TALYN_M_B0 = 0x09, 22530163b031SMaya Erez }; 22540163b031SMaya Erez 22550163b031SMaya Erez /* WMI_GET_BASEBAND_TYPE_EVENTID */ 22560163b031SMaya Erez struct wmi_get_baseband_type_event { 22570163b031SMaya Erez /* enum baseband_type */ 22580163b031SMaya Erez __le32 baseband_type; 22592be7d22fSVladimir Kondratiev } __packed; 22602be7d22fSVladimir Kondratiev 2261b874ddecSLior David /* WMI_MAC_ADDR_RESP_EVENTID */ 22622be7d22fSVladimir Kondratiev struct wmi_mac_addr_resp_event { 22632be7d22fSVladimir Kondratiev u8 mac[WMI_MAC_LEN]; 22642be7d22fSVladimir Kondratiev u8 auth_mode; 22652be7d22fSVladimir Kondratiev u8 crypt_mode; 22662be7d22fSVladimir Kondratiev __le32 offload_mode; 22672be7d22fSVladimir Kondratiev } __packed; 22682be7d22fSVladimir Kondratiev 2269b874ddecSLior David /* WMI_EAPOL_RX_EVENTID */ 22702be7d22fSVladimir Kondratiev struct wmi_eapol_rx_event { 22712be7d22fSVladimir Kondratiev u8 src_mac[WMI_MAC_LEN]; 22722be7d22fSVladimir Kondratiev __le16 eapol_len; 2273104f3d95SGustavo A. R. Silva u8 eapol[]; 22742be7d22fSVladimir Kondratiev } __packed; 22752be7d22fSVladimir Kondratiev 2276b874ddecSLior David /* WMI_READY_EVENTID */ 22772be7d22fSVladimir Kondratiev enum wmi_phy_capability { 2278b874ddecSLior David WMI_11A_CAPABILITY = 0x01, 2279b874ddecSLior David WMI_11G_CAPABILITY = 0x02, 2280b874ddecSLior David WMI_11AG_CAPABILITY = 0x03, 2281b874ddecSLior David WMI_11NA_CAPABILITY = 0x04, 2282b874ddecSLior David WMI_11NG_CAPABILITY = 0x05, 2283b874ddecSLior David WMI_11NAG_CAPABILITY = 0x06, 2284b874ddecSLior David WMI_11AD_CAPABILITY = 0x07, 2285b874ddecSLior David WMI_11N_CAPABILITY_OFFSET = 0x03, 22862be7d22fSVladimir Kondratiev }; 22872be7d22fSVladimir Kondratiev 22882be7d22fSVladimir Kondratiev struct wmi_ready_event { 22892be7d22fSVladimir Kondratiev __le32 sw_version; 22902be7d22fSVladimir Kondratiev __le32 abi_version; 22912be7d22fSVladimir Kondratiev u8 mac[WMI_MAC_LEN]; 2292b874ddecSLior David /* enum wmi_phy_capability */ 2293b874ddecSLior David u8 phy_capability; 2294b8023177SVladimir Kondratiev u8 numof_additional_mids; 2295761f8e4dSLazar Alexei /* rfc read calibration result. 5..15 */ 2296eb4c0215SDedy Lansky u8 rfc_read_calib_result; 22978a4fa214SAhmad Masri /* Max associated STAs supported by FW in AP mode (default 0 means 8 22988a4fa214SAhmad Masri * STA) 22998a4fa214SAhmad Masri */ 23008a4fa214SAhmad Masri u8 max_assoc_sta; 23018a4fa214SAhmad Masri u8 reserved[2]; 23022be7d22fSVladimir Kondratiev } __packed; 23032be7d22fSVladimir Kondratiev 2304b874ddecSLior David /* WMI_NOTIFY_REQ_DONE_EVENTID */ 23052be7d22fSVladimir Kondratiev struct wmi_notify_req_done_event { 2306b874ddecSLior David /* beamforming status, 0: fail; 1: OK; 2: retrying */ 2307b874ddecSLior David __le32 status; 23082be7d22fSVladimir Kondratiev __le64 tsf; 230930868f5dSDedy Lansky s8 rssi; 231073a7d1e3SAlexei Avshalom Lazar /* enum wmi_edmg_tx_mode */ 231173a7d1e3SAlexei Avshalom Lazar u8 tx_mode; 231273a7d1e3SAlexei Avshalom Lazar u8 reserved0[2]; 23132be7d22fSVladimir Kondratiev __le32 tx_tpt; 23142be7d22fSVladimir Kondratiev __le32 tx_goodput; 23152be7d22fSVladimir Kondratiev __le32 rx_goodput; 23162be7d22fSVladimir Kondratiev __le16 bf_mcs; 23172be7d22fSVladimir Kondratiev __le16 my_rx_sector; 23182be7d22fSVladimir Kondratiev __le16 my_tx_sector; 23192be7d22fSVladimir Kondratiev __le16 other_rx_sector; 23202be7d22fSVladimir Kondratiev __le16 other_tx_sector; 23212be7d22fSVladimir Kondratiev __le16 range; 2322b8023177SVladimir Kondratiev u8 sqi; 2323b8023177SVladimir Kondratiev u8 reserved[3]; 23242be7d22fSVladimir Kondratiev } __packed; 23252be7d22fSVladimir Kondratiev 2326b874ddecSLior David /* WMI_CONNECT_EVENTID */ 23272be7d22fSVladimir Kondratiev struct wmi_connect_event { 23289abe3e30SAlexei Avshalom Lazar /* enum wmi_channel WMI_CHANNEL_1..WMI_CHANNEL_6; for EDMG this is 23299abe3e30SAlexei Avshalom Lazar * the primary channel number 23309abe3e30SAlexei Avshalom Lazar */ 23312be7d22fSVladimir Kondratiev u8 channel; 23329abe3e30SAlexei Avshalom Lazar /* enum wmi_channel WMI_CHANNEL_9..WMI_CHANNEL_12 */ 23339abe3e30SAlexei Avshalom Lazar u8 edmg_channel; 23342be7d22fSVladimir Kondratiev u8 bssid[WMI_MAC_LEN]; 23352be7d22fSVladimir Kondratiev __le16 listen_interval; 23362be7d22fSVladimir Kondratiev __le16 beacon_interval; 23372be7d22fSVladimir Kondratiev u8 network_type; 23382be7d22fSVladimir Kondratiev u8 reserved1[3]; 23392be7d22fSVladimir Kondratiev u8 beacon_ie_len; 23402be7d22fSVladimir Kondratiev u8 assoc_req_len; 23412be7d22fSVladimir Kondratiev u8 assoc_resp_len; 23422be7d22fSVladimir Kondratiev u8 cid; 2343a52fb913SLior David u8 aid; 2344a52fb913SLior David u8 reserved2[2]; 2345b874ddecSLior David /* not in use */ 2346104f3d95SGustavo A. R. Silva u8 assoc_info[]; 23472be7d22fSVladimir Kondratiev } __packed; 23482be7d22fSVladimir Kondratiev 2349849a564bSDedy Lansky /* disconnect_reason */ 23502be7d22fSVladimir Kondratiev enum wmi_disconnect_reason { 2351b874ddecSLior David WMI_DIS_REASON_NO_NETWORK_AVAIL = 0x01, 2352b874ddecSLior David /* bmiss */ 2353b874ddecSLior David WMI_DIS_REASON_LOST_LINK = 0x02, 2354b874ddecSLior David WMI_DIS_REASON_DISCONNECT_CMD = 0x03, 2355b874ddecSLior David WMI_DIS_REASON_BSS_DISCONNECTED = 0x04, 2356b874ddecSLior David WMI_DIS_REASON_AUTH_FAILED = 0x05, 2357b874ddecSLior David WMI_DIS_REASON_ASSOC_FAILED = 0x06, 2358b874ddecSLior David WMI_DIS_REASON_NO_RESOURCES_AVAIL = 0x07, 2359b874ddecSLior David WMI_DIS_REASON_CSERV_DISCONNECT = 0x08, 2360b874ddecSLior David WMI_DIS_REASON_INVALID_PROFILE = 0x0A, 2361b874ddecSLior David WMI_DIS_REASON_DOT11H_CHANNEL_SWITCH = 0x0B, 2362b874ddecSLior David WMI_DIS_REASON_PROFILE_MISMATCH = 0x0C, 2363b874ddecSLior David WMI_DIS_REASON_CONNECTION_EVICTED = 0x0D, 2364b874ddecSLior David WMI_DIS_REASON_IBSS_MERGE = 0x0E, 236573a7d1e3SAlexei Avshalom Lazar WMI_DIS_REASON_HIGH_TEMPERATURE = 0x0F, 23662be7d22fSVladimir Kondratiev }; 23672be7d22fSVladimir Kondratiev 2368849a564bSDedy Lansky /* WMI_DISCONNECT_EVENTID */ 23692be7d22fSVladimir Kondratiev struct wmi_disconnect_event { 2370b874ddecSLior David /* reason code, see 802.11 spec. */ 2371b874ddecSLior David __le16 protocol_reason_status; 2372b874ddecSLior David /* set if known */ 2373b874ddecSLior David u8 bssid[WMI_MAC_LEN]; 2374b874ddecSLior David /* see enum wmi_disconnect_reason */ 2375b874ddecSLior David u8 disconnect_reason; 2376b874ddecSLior David /* last assoc req may passed to host - not in used */ 2377b874ddecSLior David u8 assoc_resp_len; 2378b874ddecSLior David /* last assoc req may passed to host - not in used */ 2379104f3d95SGustavo A. R. Silva u8 assoc_info[]; 23802be7d22fSVladimir Kondratiev } __packed; 23812be7d22fSVladimir Kondratiev 2382b874ddecSLior David /* WMI_SCAN_COMPLETE_EVENTID */ 23836c2faf09SVladimir Kondratiev enum scan_status { 2384b874ddecSLior David WMI_SCAN_SUCCESS = 0x00, 2385b874ddecSLior David WMI_SCAN_FAILED = 0x01, 2386b874ddecSLior David WMI_SCAN_ABORTED = 0x02, 2387b874ddecSLior David WMI_SCAN_REJECTED = 0x03, 2388b874ddecSLior David WMI_SCAN_ABORT_REJECTED = 0x04, 23896c2faf09SVladimir Kondratiev }; 23906c2faf09SVladimir Kondratiev 23912be7d22fSVladimir Kondratiev struct wmi_scan_complete_event { 2392b874ddecSLior David /* enum scan_status */ 2393b874ddecSLior David __le32 status; 23942be7d22fSVladimir Kondratiev } __packed; 23952be7d22fSVladimir Kondratiev 2396b5aeff16SDedy Lansky /* WMI_FT_AUTH_STATUS_EVENTID */ 2397b5aeff16SDedy Lansky struct wmi_ft_auth_status_event { 2398b5aeff16SDedy Lansky /* enum wmi_fw_status */ 2399b5aeff16SDedy Lansky u8 status; 2400b5aeff16SDedy Lansky u8 reserved[3]; 2401b5aeff16SDedy Lansky u8 mac_addr[WMI_MAC_LEN]; 2402b5aeff16SDedy Lansky __le16 ie_len; 2403104f3d95SGustavo A. R. Silva u8 ie_info[]; 2404b5aeff16SDedy Lansky } __packed; 2405b5aeff16SDedy Lansky 2406b5aeff16SDedy Lansky /* WMI_FT_REASSOC_STATUS_EVENTID */ 2407b5aeff16SDedy Lansky struct wmi_ft_reassoc_status_event { 2408b5aeff16SDedy Lansky /* enum wmi_fw_status */ 2409b5aeff16SDedy Lansky u8 status; 2410b5aeff16SDedy Lansky /* association id received from new AP */ 2411b5aeff16SDedy Lansky u8 aid; 2412b5aeff16SDedy Lansky /* enum wmi_channel */ 2413b5aeff16SDedy Lansky u8 channel; 2414b5aeff16SDedy Lansky /* enum wmi_channel */ 2415b5aeff16SDedy Lansky u8 edmg_channel; 2416b5aeff16SDedy Lansky u8 mac_addr[WMI_MAC_LEN]; 2417b5aeff16SDedy Lansky __le16 beacon_ie_len; 2418b5aeff16SDedy Lansky __le16 reassoc_req_ie_len; 2419b5aeff16SDedy Lansky __le16 reassoc_resp_ie_len; 2420b9010f10SAhmad Masri u8 reserved[4]; 2421104f3d95SGustavo A. R. Silva u8 ie_info[]; 2422b5aeff16SDedy Lansky } __packed; 2423b5aeff16SDedy Lansky 2424a5dc6883SDedy Lansky /* wmi_rx_mgmt_info */ 2425a5dc6883SDedy Lansky struct wmi_rx_mgmt_info { 2426a5dc6883SDedy Lansky u8 mcs; 2427a5dc6883SDedy Lansky s8 rssi; 2428a5dc6883SDedy Lansky u8 range; 2429a5dc6883SDedy Lansky u8 sqi; 2430a5dc6883SDedy Lansky __le16 stype; 2431a5dc6883SDedy Lansky __le16 status; 2432a5dc6883SDedy Lansky __le32 len; 2433a5dc6883SDedy Lansky /* Not resolved when == 0xFFFFFFFF == > Broadcast to all MIDS */ 2434a5dc6883SDedy Lansky u8 qid; 2435a5dc6883SDedy Lansky /* Not resolved when == 0xFFFFFFFF == > Broadcast to all MIDS */ 2436a5dc6883SDedy Lansky u8 mid; 2437a5dc6883SDedy Lansky u8 cid; 2438a5dc6883SDedy Lansky /* From Radio MNGR */ 2439a5dc6883SDedy Lansky u8 channel; 2440a5dc6883SDedy Lansky } __packed; 2441a5dc6883SDedy Lansky 2442a5dc6883SDedy Lansky /* WMI_START_SCHED_SCAN_EVENTID */ 2443a5dc6883SDedy Lansky enum wmi_pno_result { 2444a5dc6883SDedy Lansky WMI_PNO_SUCCESS = 0x00, 2445a5dc6883SDedy Lansky WMI_PNO_REJECT = 0x01, 2446a5dc6883SDedy Lansky WMI_PNO_INVALID_PARAMETERS = 0x02, 2447a5dc6883SDedy Lansky WMI_PNO_NOT_ENABLED = 0x03, 2448a5dc6883SDedy Lansky }; 2449a5dc6883SDedy Lansky 2450a5dc6883SDedy Lansky struct wmi_start_sched_scan_event { 24518a4fa214SAhmad Masri /* wmi_pno_result */ 2452a5dc6883SDedy Lansky u8 result; 2453a5dc6883SDedy Lansky u8 reserved[3]; 2454a5dc6883SDedy Lansky } __packed; 2455a5dc6883SDedy Lansky 2456a5dc6883SDedy Lansky struct wmi_stop_sched_scan_event { 24578a4fa214SAhmad Masri /* wmi_pno_result */ 2458a5dc6883SDedy Lansky u8 result; 2459a5dc6883SDedy Lansky u8 reserved[3]; 2460a5dc6883SDedy Lansky } __packed; 2461a5dc6883SDedy Lansky 2462a5dc6883SDedy Lansky struct wmi_sched_scan_result_event { 2463a5dc6883SDedy Lansky struct wmi_rx_mgmt_info info; 2464104f3d95SGustavo A. R. Silva u8 payload[]; 2465a5dc6883SDedy Lansky } __packed; 2466a5dc6883SDedy Lansky 2467b874ddecSLior David /* WMI_ACS_PASSIVE_SCAN_COMPLETE_EVENT */ 2468b874ddecSLior David enum wmi_acs_info_bitmask { 2469b874ddecSLior David WMI_ACS_INFO_BITMASK_BEACON_FOUND = 0x01, 2470b874ddecSLior David WMI_ACS_INFO_BITMASK_BUSY_TIME = 0x02, 2471b874ddecSLior David WMI_ACS_INFO_BITMASK_TX_TIME = 0x04, 2472b874ddecSLior David WMI_ACS_INFO_BITMASK_RX_TIME = 0x08, 2473b874ddecSLior David WMI_ACS_INFO_BITMASK_NOISE = 0x10, 24742be7d22fSVladimir Kondratiev }; 24752be7d22fSVladimir Kondratiev 2476b874ddecSLior David struct scan_acs_info { 2477b874ddecSLior David u8 channel; 2478b874ddecSLior David u8 beacon_found; 2479b874ddecSLior David /* msec */ 2480b874ddecSLior David __le16 busy_time; 2481b874ddecSLior David __le16 tx_time; 2482b874ddecSLior David __le16 rx_time; 2483b874ddecSLior David u8 noise; 2484b874ddecSLior David u8 reserved[3]; 2485b874ddecSLior David } __packed; 2486b874ddecSLior David 2487b874ddecSLior David struct wmi_acs_passive_scan_complete_event { 2488b874ddecSLior David __le32 dwell_time; 2489b874ddecSLior David /* valid fields within channel info according to 2490b874ddecSLior David * their appearance in struct order 2491b874ddecSLior David */ 2492b874ddecSLior David __le16 filled; 2493b874ddecSLior David u8 num_scanned_channels; 2494b874ddecSLior David u8 reserved; 2495104f3d95SGustavo A. R. Silva struct scan_acs_info scan_info_list[]; 2496b874ddecSLior David } __packed; 2497b874ddecSLior David 2498b874ddecSLior David /* WMI_BA_STATUS_EVENTID */ 2499b874ddecSLior David enum wmi_vring_ba_status { 2500b874ddecSLior David WMI_BA_AGREED = 0x00, 2501b874ddecSLior David WMI_BA_NON_AGREED = 0x01, 2502b874ddecSLior David /* BA_EN in middle of teardown flow */ 2503b874ddecSLior David WMI_BA_TD_WIP = 0x02, 2504b874ddecSLior David /* BA_DIS or BA_EN in middle of BA SETUP flow */ 2505b874ddecSLior David WMI_BA_SETUP_WIP = 0x03, 2506b874ddecSLior David /* BA_EN when the BA session is already active */ 2507b874ddecSLior David WMI_BA_SESSION_ACTIVE = 0x04, 2508b874ddecSLior David /* BA_DIS when the BA session is not active */ 2509b874ddecSLior David WMI_BA_SESSION_NOT_ACTIVE = 0x05, 2510b874ddecSLior David }; 2511b874ddecSLior David 2512b874ddecSLior David struct wmi_ba_status_event { 2513b874ddecSLior David /* enum wmi_vring_ba_status */ 2514b874ddecSLior David __le16 status; 25152be7d22fSVladimir Kondratiev u8 reserved[2]; 25162be7d22fSVladimir Kondratiev u8 ringid; 25172be7d22fSVladimir Kondratiev u8 agg_wsize; 25182be7d22fSVladimir Kondratiev __le16 ba_timeout; 2519cbcf5866SVladimir Kondratiev u8 amsdu; 25202be7d22fSVladimir Kondratiev } __packed; 25212be7d22fSVladimir Kondratiev 2522b874ddecSLior David /* WMI_DELBA_EVENTID */ 25232be7d22fSVladimir Kondratiev struct wmi_delba_event { 25248a4fa214SAhmad Masri /* Used for cid less than 8. For higher cid set 25258a4fa214SAhmad Masri * CIDXTID_EXTENDED_CID_TID here and use cid and tid members instead 25268a4fa214SAhmad Masri */ 25272be7d22fSVladimir Kondratiev u8 cidxtid; 25282be7d22fSVladimir Kondratiev u8 from_initiator; 25292be7d22fSVladimir Kondratiev __le16 reason; 25308a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 25318a4fa214SAhmad Masri u8 cid; 25328a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 25338a4fa214SAhmad Masri u8 tid; 25348a4fa214SAhmad Masri u8 reserved[2]; 25352be7d22fSVladimir Kondratiev } __packed; 25362be7d22fSVladimir Kondratiev 2537b874ddecSLior David /* WMI_VRING_CFG_DONE_EVENTID */ 25382be7d22fSVladimir Kondratiev struct wmi_vring_cfg_done_event { 25392be7d22fSVladimir Kondratiev u8 ringid; 25402be7d22fSVladimir Kondratiev u8 status; 25412be7d22fSVladimir Kondratiev u8 reserved[2]; 25422be7d22fSVladimir Kondratiev __le32 tx_vring_tail_ptr; 25432be7d22fSVladimir Kondratiev } __packed; 25442be7d22fSVladimir Kondratiev 2545b874ddecSLior David /* WMI_RCP_ADDBA_RESP_SENT_EVENTID */ 25462be7d22fSVladimir Kondratiev struct wmi_rcp_addba_resp_sent_event { 25478a4fa214SAhmad Masri /* Used for cid less than 8. For higher cid set 25488a4fa214SAhmad Masri * CIDXTID_EXTENDED_CID_TID here and use cid and tid members instead 25498a4fa214SAhmad Masri */ 25502be7d22fSVladimir Kondratiev u8 cidxtid; 25512be7d22fSVladimir Kondratiev u8 reserved; 25522be7d22fSVladimir Kondratiev __le16 status; 25538a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 25548a4fa214SAhmad Masri u8 cid; 25558a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 25568a4fa214SAhmad Masri u8 tid; 25578a4fa214SAhmad Masri u8 reserved2[2]; 25582be7d22fSVladimir Kondratiev } __packed; 25592be7d22fSVladimir Kondratiev 256096c93589SGidon Studinski /* WMI_TX_STATUS_RING_CFG_DONE_EVENTID */ 256196c93589SGidon Studinski struct wmi_tx_status_ring_cfg_done_event { 256296c93589SGidon Studinski u8 ring_id; 256396c93589SGidon Studinski /* wmi_fw_status */ 256496c93589SGidon Studinski u8 status; 256596c93589SGidon Studinski u8 reserved[2]; 256696c93589SGidon Studinski __le32 ring_tail_ptr; 256796c93589SGidon Studinski } __packed; 256896c93589SGidon Studinski 256996c93589SGidon Studinski /* WMI_RX_STATUS_RING_CFG_DONE_EVENTID */ 257096c93589SGidon Studinski struct wmi_rx_status_ring_cfg_done_event { 257196c93589SGidon Studinski u8 ring_id; 257296c93589SGidon Studinski /* wmi_fw_status */ 257396c93589SGidon Studinski u8 status; 257496c93589SGidon Studinski u8 reserved[2]; 257596c93589SGidon Studinski __le32 ring_tail_ptr; 257696c93589SGidon Studinski } __packed; 257796c93589SGidon Studinski 257896c93589SGidon Studinski /* WMI_CFG_DEF_RX_OFFLOAD_DONE_EVENTID */ 257996c93589SGidon Studinski struct wmi_cfg_def_rx_offload_done_event { 258096c93589SGidon Studinski /* wmi_fw_status */ 258196c93589SGidon Studinski u8 status; 258296c93589SGidon Studinski u8 reserved[3]; 258396c93589SGidon Studinski } __packed; 258496c93589SGidon Studinski 258596c93589SGidon Studinski /* WMI_TX_DESC_RING_CFG_DONE_EVENTID */ 258696c93589SGidon Studinski struct wmi_tx_desc_ring_cfg_done_event { 258796c93589SGidon Studinski u8 ring_id; 258896c93589SGidon Studinski /* wmi_fw_status */ 258996c93589SGidon Studinski u8 status; 259096c93589SGidon Studinski u8 reserved[2]; 259196c93589SGidon Studinski __le32 ring_tail_ptr; 259296c93589SGidon Studinski } __packed; 259396c93589SGidon Studinski 259496c93589SGidon Studinski /* WMI_RX_DESC_RING_CFG_DONE_EVENTID */ 259596c93589SGidon Studinski struct wmi_rx_desc_ring_cfg_done_event { 259696c93589SGidon Studinski u8 ring_id; 259796c93589SGidon Studinski /* wmi_fw_status */ 259896c93589SGidon Studinski u8 status; 259996c93589SGidon Studinski u8 reserved[2]; 260096c93589SGidon Studinski __le32 ring_tail_ptr; 260196c93589SGidon Studinski } __packed; 260296c93589SGidon Studinski 2603b874ddecSLior David /* WMI_RCP_ADDBA_REQ_EVENTID */ 26042be7d22fSVladimir Kondratiev struct wmi_rcp_addba_req_event { 26058a4fa214SAhmad Masri /* Used for cid less than 8. For higher cid set 26068a4fa214SAhmad Masri * CIDXTID_EXTENDED_CID_TID here and use cid and tid members instead 26078a4fa214SAhmad Masri */ 26082be7d22fSVladimir Kondratiev u8 cidxtid; 26092be7d22fSVladimir Kondratiev u8 dialog_token; 2610b874ddecSLior David /* ieee80211_ba_parameterset as it received */ 2611b874ddecSLior David __le16 ba_param_set; 26122be7d22fSVladimir Kondratiev __le16 ba_timeout; 2613b874ddecSLior David /* ieee80211_ba_seqstrl field as it received */ 2614b874ddecSLior David __le16 ba_seq_ctrl; 26158a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 26168a4fa214SAhmad Masri u8 cid; 26178a4fa214SAhmad Masri /* Used when cidxtid = CIDXTID_EXTENDED_CID_TID */ 26188a4fa214SAhmad Masri u8 tid; 26198a4fa214SAhmad Masri u8 reserved[2]; 26202be7d22fSVladimir Kondratiev } __packed; 26212be7d22fSVladimir Kondratiev 2622b874ddecSLior David /* WMI_CFG_RX_CHAIN_DONE_EVENTID */ 26232be7d22fSVladimir Kondratiev enum wmi_cfg_rx_chain_done_event_status { 2624b874ddecSLior David WMI_CFG_RX_CHAIN_SUCCESS = 0x01, 26252be7d22fSVladimir Kondratiev }; 26262be7d22fSVladimir Kondratiev 26272be7d22fSVladimir Kondratiev struct wmi_cfg_rx_chain_done_event { 2628b874ddecSLior David /* V-Ring Tail pointer */ 2629b874ddecSLior David __le32 rx_ring_tail_ptr; 26302be7d22fSVladimir Kondratiev __le32 status; 26312be7d22fSVladimir Kondratiev } __packed; 26322be7d22fSVladimir Kondratiev 2633b874ddecSLior David /* WMI_WBE_LINK_DOWN_EVENTID */ 26342be7d22fSVladimir Kondratiev enum wmi_wbe_link_down_event_reason { 2635b874ddecSLior David WMI_WBE_REASON_USER_REQUEST = 0x00, 2636b874ddecSLior David WMI_WBE_REASON_RX_DISASSOC = 0x01, 2637b874ddecSLior David WMI_WBE_REASON_BAD_PHY_LINK = 0x02, 26382be7d22fSVladimir Kondratiev }; 26392be7d22fSVladimir Kondratiev 2640b874ddecSLior David /* WMI_WBE_LINK_DOWN_EVENTID */ 26412be7d22fSVladimir Kondratiev struct wmi_wbe_link_down_event { 26422be7d22fSVladimir Kondratiev u8 cid; 26432be7d22fSVladimir Kondratiev u8 reserved[3]; 26442be7d22fSVladimir Kondratiev __le32 reason; 26452be7d22fSVladimir Kondratiev } __packed; 26462be7d22fSVladimir Kondratiev 2647b874ddecSLior David /* WMI_DATA_PORT_OPEN_EVENTID */ 26482be7d22fSVladimir Kondratiev struct wmi_data_port_open_event { 26492be7d22fSVladimir Kondratiev u8 cid; 26502be7d22fSVladimir Kondratiev u8 reserved[3]; 26512be7d22fSVladimir Kondratiev } __packed; 26522be7d22fSVladimir Kondratiev 265396c93589SGidon Studinski /* WMI_RING_EN_EVENTID */ 265496c93589SGidon Studinski struct wmi_ring_en_event { 265596c93589SGidon Studinski u8 ring_index; 2656230d8442SVladimir Kondratiev u8 reserved[3]; 2657230d8442SVladimir Kondratiev } __packed; 2658230d8442SVladimir Kondratiev 2659b874ddecSLior David /* WMI_GET_PCP_CHANNEL_EVENTID */ 26602be7d22fSVladimir Kondratiev struct wmi_get_pcp_channel_event { 26612be7d22fSVladimir Kondratiev u8 channel; 26622be7d22fSVladimir Kondratiev u8 reserved[3]; 26632be7d22fSVladimir Kondratiev } __packed; 26642be7d22fSVladimir Kondratiev 2665b874ddecSLior David /* WMI_P2P_CFG_DONE_EVENTID */ 26668c679675SVladimir Kondratiev struct wmi_p2p_cfg_done_event { 2667b874ddecSLior David /* wmi_fw_status */ 2668b874ddecSLior David u8 status; 26698c679675SVladimir Kondratiev u8 reserved[3]; 26708c679675SVladimir Kondratiev } __packed; 26718c679675SVladimir Kondratiev 2672b874ddecSLior David /* WMI_PORT_ALLOCATED_EVENTID */ 2673b8023177SVladimir Kondratiev struct wmi_port_allocated_event { 2674b874ddecSLior David /* wmi_fw_status */ 2675b874ddecSLior David u8 status; 2676b8023177SVladimir Kondratiev u8 reserved[3]; 2677b8023177SVladimir Kondratiev } __packed; 2678b8023177SVladimir Kondratiev 2679b874ddecSLior David /* WMI_PORT_DELETED_EVENTID */ 2680b8023177SVladimir Kondratiev struct wmi_port_deleted_event { 2681b874ddecSLior David /* wmi_fw_status */ 2682b874ddecSLior David u8 status; 2683b8023177SVladimir Kondratiev u8 reserved[3]; 2684b8023177SVladimir Kondratiev } __packed; 2685b8023177SVladimir Kondratiev 2686b874ddecSLior David /* WMI_LISTEN_STARTED_EVENTID */ 2687b8023177SVladimir Kondratiev struct wmi_listen_started_event { 2688b874ddecSLior David /* wmi_fw_status */ 2689b874ddecSLior David u8 status; 2690b8023177SVladimir Kondratiev u8 reserved[3]; 2691b8023177SVladimir Kondratiev } __packed; 2692b8023177SVladimir Kondratiev 2693b874ddecSLior David /* WMI_SEARCH_STARTED_EVENTID */ 2694b8023177SVladimir Kondratiev struct wmi_search_started_event { 2695b874ddecSLior David /* wmi_fw_status */ 2696b874ddecSLior David u8 status; 2697b8023177SVladimir Kondratiev u8 reserved[3]; 2698b8023177SVladimir Kondratiev } __packed; 2699b8023177SVladimir Kondratiev 2700b874ddecSLior David /* WMI_PCP_STARTED_EVENTID */ 2701b8023177SVladimir Kondratiev struct wmi_pcp_started_event { 2702b874ddecSLior David /* wmi_fw_status */ 2703b874ddecSLior David u8 status; 2704b8023177SVladimir Kondratiev u8 reserved[3]; 2705b8023177SVladimir Kondratiev } __packed; 2706b8023177SVladimir Kondratiev 2707b874ddecSLior David /* WMI_PCP_FACTOR_EVENTID */ 2708b8023177SVladimir Kondratiev struct wmi_pcp_factor_event { 2709b8023177SVladimir Kondratiev __le32 pcp_factor; 2710b8023177SVladimir Kondratiev } __packed; 2711b8023177SVladimir Kondratiev 27122be7d22fSVladimir Kondratiev enum wmi_sw_tx_status { 2713b874ddecSLior David WMI_TX_SW_STATUS_SUCCESS = 0x00, 2714b874ddecSLior David WMI_TX_SW_STATUS_FAILED_NO_RESOURCES = 0x01, 2715b874ddecSLior David WMI_TX_SW_STATUS_FAILED_TX = 0x02, 27162be7d22fSVladimir Kondratiev }; 27172be7d22fSVladimir Kondratiev 2718b874ddecSLior David /* WMI_SW_TX_COMPLETE_EVENTID */ 27192be7d22fSVladimir Kondratiev struct wmi_sw_tx_complete_event { 2720b874ddecSLior David /* enum wmi_sw_tx_status */ 2721b874ddecSLior David u8 status; 27222be7d22fSVladimir Kondratiev u8 reserved[3]; 27232be7d22fSVladimir Kondratiev } __packed; 27242be7d22fSVladimir Kondratiev 2725761f8e4dSLazar Alexei /* WMI_CORR_MEASURE_EVENTID - deprecated */ 2726b8023177SVladimir Kondratiev struct wmi_corr_measure_event { 2727b874ddecSLior David /* signed */ 2728b874ddecSLior David __le32 i; 2729b874ddecSLior David /* signed */ 2730b874ddecSLior David __le32 q; 2731b874ddecSLior David /* signed */ 2732b874ddecSLior David __le32 image_i; 2733b874ddecSLior David /* signed */ 2734b874ddecSLior David __le32 image_q; 2735b8023177SVladimir Kondratiev } __packed; 2736b8023177SVladimir Kondratiev 2737b874ddecSLior David /* WMI_READ_RSSI_EVENTID */ 2738b8023177SVladimir Kondratiev struct wmi_read_rssi_event { 2739b8023177SVladimir Kondratiev __le32 ina_rssi_adc_dbm; 2740b8023177SVladimir Kondratiev } __packed; 2741b8023177SVladimir Kondratiev 2742b874ddecSLior David /* WMI_GET_SSID_EVENTID */ 27432be7d22fSVladimir Kondratiev struct wmi_get_ssid_event { 27442be7d22fSVladimir Kondratiev __le32 ssid_len; 27452be7d22fSVladimir Kondratiev u8 ssid[WMI_MAX_SSID_LEN]; 27462be7d22fSVladimir Kondratiev } __packed; 27472be7d22fSVladimir Kondratiev 2748761f8e4dSLazar Alexei /* EVENT: WMI_RF_XPM_READ_RESULT_EVENTID */ 2749761f8e4dSLazar Alexei struct wmi_rf_xpm_read_result_event { 2750761f8e4dSLazar Alexei /* enum wmi_fw_status_e - success=0 or fail=1 */ 2751761f8e4dSLazar Alexei u8 status; 2752761f8e4dSLazar Alexei u8 reserved[3]; 2753761f8e4dSLazar Alexei /* requested num_bytes of data */ 2754104f3d95SGustavo A. R. Silva u8 data_bytes[]; 2755b874ddecSLior David } __packed; 2756b874ddecSLior David 2757761f8e4dSLazar Alexei /* EVENT: WMI_RF_XPM_WRITE_RESULT_EVENTID */ 2758761f8e4dSLazar Alexei struct wmi_rf_xpm_write_result_event { 2759761f8e4dSLazar Alexei /* enum wmi_fw_status_e - success=0 or fail=1 */ 2760761f8e4dSLazar Alexei u8 status; 2761761f8e4dSLazar Alexei u8 reserved[3]; 2762b874ddecSLior David } __packed; 2763b874ddecSLior David 2764b874ddecSLior David /* WMI_TX_MGMT_PACKET_EVENTID */ 27656c2faf09SVladimir Kondratiev struct wmi_tx_mgmt_packet_event { 2766*27044b57SGustavo A. R. Silva DECLARE_FLEX_ARRAY(u8, payload); 27676c2faf09SVladimir Kondratiev } __packed; 27686c2faf09SVladimir Kondratiev 2769b874ddecSLior David /* WMI_RX_MGMT_PACKET_EVENTID */ 27702be7d22fSVladimir Kondratiev struct wmi_rx_mgmt_packet_event { 27712be7d22fSVladimir Kondratiev struct wmi_rx_mgmt_info info; 2772104f3d95SGustavo A. R. Silva u8 payload[]; 27732be7d22fSVladimir Kondratiev } __packed; 27742be7d22fSVladimir Kondratiev 2775b874ddecSLior David /* WMI_ECHO_RSP_EVENTID */ 2776b874ddecSLior David struct wmi_echo_rsp_event { 27772be7d22fSVladimir Kondratiev __le32 echoed_value; 27782be7d22fSVladimir Kondratiev } __packed; 27792be7d22fSVladimir Kondratiev 27806a363e8aSAhmad Masri /* WMI_DEEP_ECHO_RSP_EVENTID */ 27816a363e8aSAhmad Masri struct wmi_deep_echo_rsp_event { 27826a363e8aSAhmad Masri __le32 echoed_value; 27836a363e8aSAhmad Masri } __packed; 27846a363e8aSAhmad Masri 2785761f8e4dSLazar Alexei /* WMI_RF_PWR_ON_DELAY_RSP_EVENTID */ 2786761f8e4dSLazar Alexei struct wmi_rf_pwr_on_delay_rsp_event { 2787761f8e4dSLazar Alexei /* wmi_fw_status */ 2788761f8e4dSLazar Alexei u8 status; 2789761f8e4dSLazar Alexei u8 reserved[3]; 2790761f8e4dSLazar Alexei } __packed; 2791761f8e4dSLazar Alexei 2792761f8e4dSLazar Alexei /* WMI_SET_HIGH_POWER_TABLE_PARAMS_EVENTID */ 2793761f8e4dSLazar Alexei struct wmi_set_high_power_table_params_event { 2794761f8e4dSLazar Alexei /* wmi_fw_status */ 2795761f8e4dSLazar Alexei u8 status; 2796761f8e4dSLazar Alexei u8 reserved[3]; 2797761f8e4dSLazar Alexei } __packed; 2798761f8e4dSLazar Alexei 27998a4fa214SAhmad Masri /* WMI_FIXED_SCHEDULING_UL_CONFIG_EVENTID */ 28008a4fa214SAhmad Masri struct wmi_fixed_scheduling_ul_config_event { 28018a4fa214SAhmad Masri /* wmi_fw_status */ 28028a4fa214SAhmad Masri u8 status; 28038a4fa214SAhmad Masri u8 reserved[3]; 28048a4fa214SAhmad Masri } __packed; 28058a4fa214SAhmad Masri 2806b874ddecSLior David /* WMI_TEMP_SENSE_DONE_EVENTID 2807b8023177SVladimir Kondratiev * 2808b8023177SVladimir Kondratiev * Measure MAC and radio temperatures 2809b8023177SVladimir Kondratiev */ 2810b8023177SVladimir Kondratiev struct wmi_temp_sense_done_event { 2811b874ddecSLior David /* Temperature times 1000 (actual temperature will be achieved by 28129b586118STzahi Sabo * dividing the value by 1000). When temperature cannot be read from 28139b586118STzahi Sabo * device return WMI_INVALID_TEMPERATURE 2814b874ddecSLior David */ 28158c679675SVladimir Kondratiev __le32 baseband_t1000; 2816b874ddecSLior David /* Temperature times 1000 (actual temperature will be achieved by 28179b586118STzahi Sabo * dividing the value by 1000). When temperature cannot be read from 28189b586118STzahi Sabo * device return WMI_INVALID_TEMPERATURE 2819b874ddecSLior David */ 28208c679675SVladimir Kondratiev __le32 rf_t1000; 2821b8023177SVladimir Kondratiev } __packed; 2822b8023177SVladimir Kondratiev 2823b874ddecSLior David #define WMI_SCAN_DWELL_TIME_MS (100) 2824b874ddecSLior David #define WMI_SURVEY_TIMEOUT_MS (10000) 2825b874ddecSLior David 2826b874ddecSLior David enum wmi_hidden_ssid { 2827b874ddecSLior David WMI_HIDDEN_SSID_DISABLED = 0x00, 2828b874ddecSLior David WMI_HIDDEN_SSID_SEND_EMPTY = 0x10, 2829b874ddecSLior David WMI_HIDDEN_SSID_CLEAR = 0xFE, 2830b874ddecSLior David }; 2831b874ddecSLior David 283210d599adSMaya Erez /* WMI_LED_CFG_CMDID 283310d599adSMaya Erez * 283410d599adSMaya Erez * Configure LED On\Off\Blinking operation 283510d599adSMaya Erez * 283610d599adSMaya Erez * Returned events: 283710d599adSMaya Erez * - WMI_LED_CFG_DONE_EVENTID 283810d599adSMaya Erez */ 283910d599adSMaya Erez enum led_mode { 284010d599adSMaya Erez LED_DISABLE = 0x00, 284110d599adSMaya Erez LED_ENABLE = 0x01, 284210d599adSMaya Erez }; 284310d599adSMaya Erez 284410d599adSMaya Erez /* The names of the led as 284510d599adSMaya Erez * described on HW schemes. 284610d599adSMaya Erez */ 284710d599adSMaya Erez enum wmi_led_id { 284810d599adSMaya Erez WMI_LED_WLAN = 0x00, 284910d599adSMaya Erez WMI_LED_WPAN = 0x01, 285010d599adSMaya Erez WMI_LED_WWAN = 0x02, 285110d599adSMaya Erez }; 285210d599adSMaya Erez 285310d599adSMaya Erez /* Led polarity mode. */ 285410d599adSMaya Erez enum wmi_led_polarity { 285510d599adSMaya Erez LED_POLARITY_HIGH_ACTIVE = 0x00, 285610d599adSMaya Erez LED_POLARITY_LOW_ACTIVE = 0x01, 285710d599adSMaya Erez }; 285810d599adSMaya Erez 285910d599adSMaya Erez /* Combination of on and off 286010d599adSMaya Erez * creates the blinking period 286110d599adSMaya Erez */ 286210d599adSMaya Erez struct wmi_led_blink_mode { 286310d599adSMaya Erez __le32 blink_on; 286410d599adSMaya Erez __le32 blink_off; 286510d599adSMaya Erez } __packed; 286610d599adSMaya Erez 286710d599adSMaya Erez /* WMI_LED_CFG_CMDID */ 286810d599adSMaya Erez struct wmi_led_cfg_cmd { 286910d599adSMaya Erez /* enum led_mode_e */ 287010d599adSMaya Erez u8 led_mode; 287110d599adSMaya Erez /* enum wmi_led_id_e */ 287210d599adSMaya Erez u8 id; 287310d599adSMaya Erez /* slow speed blinking combination */ 287410d599adSMaya Erez struct wmi_led_blink_mode slow_blink_cfg; 287510d599adSMaya Erez /* medium speed blinking combination */ 287610d599adSMaya Erez struct wmi_led_blink_mode medium_blink_cfg; 287710d599adSMaya Erez /* high speed blinking combination */ 287810d599adSMaya Erez struct wmi_led_blink_mode fast_blink_cfg; 287910d599adSMaya Erez /* polarity of the led */ 288010d599adSMaya Erez u8 led_polarity; 288110d599adSMaya Erez /* reserved */ 288210d599adSMaya Erez u8 reserved; 288310d599adSMaya Erez } __packed; 288410d599adSMaya Erez 2885761f8e4dSLazar Alexei /* \WMI_SET_CONNECT_SNR_THR_CMDID */ 2886761f8e4dSLazar Alexei struct wmi_set_connect_snr_thr_cmd { 2887761f8e4dSLazar Alexei u8 enable; 2888761f8e4dSLazar Alexei u8 reserved; 2889761f8e4dSLazar Alexei /* 1/4 Db units */ 2890761f8e4dSLazar Alexei __le16 omni_snr_thr; 2891761f8e4dSLazar Alexei /* 1/4 Db units */ 2892761f8e4dSLazar Alexei __le16 direct_snr_thr; 2893761f8e4dSLazar Alexei } __packed; 2894761f8e4dSLazar Alexei 289510d599adSMaya Erez /* WMI_LED_CFG_DONE_EVENTID */ 289610d599adSMaya Erez struct wmi_led_cfg_done_event { 289710d599adSMaya Erez /* led config status */ 289810d599adSMaya Erez __le32 status; 289910d599adSMaya Erez } __packed; 290010d599adSMaya Erez 29010163b031SMaya Erez /* Rate search parameters configuration per connection */ 29020163b031SMaya Erez struct wmi_rs_cfg { 29030163b031SMaya Erez /* The maximal allowed PER for each MCS 29040163b031SMaya Erez * MCS will be considered as failed if PER during RS is higher 29050163b031SMaya Erez */ 29060163b031SMaya Erez u8 per_threshold[WMI_NUM_MCS]; 29070163b031SMaya Erez /* Number of MPDUs for each MCS 29080163b031SMaya Erez * this is the minimal statistic required to make an educated 29090163b031SMaya Erez * decision 29100163b031SMaya Erez */ 29110163b031SMaya Erez u8 min_frame_cnt[WMI_NUM_MCS]; 29120163b031SMaya Erez /* stop threshold [0-100] */ 29130163b031SMaya Erez u8 stop_th; 29140163b031SMaya Erez /* MCS1 stop threshold [0-100] */ 29150163b031SMaya Erez u8 mcs1_fail_th; 29160163b031SMaya Erez u8 max_back_failure_th; 29170163b031SMaya Erez /* Debug feature for disabling internal RS trigger (which is 29180163b031SMaya Erez * currently triggered by BF Done) 29190163b031SMaya Erez */ 29200163b031SMaya Erez u8 dbg_disable_internal_trigger; 29210163b031SMaya Erez __le32 back_failure_mask; 29220163b031SMaya Erez __le32 mcs_en_vec; 29230163b031SMaya Erez } __packed; 29240163b031SMaya Erez 2925b5aeff16SDedy Lansky enum wmi_edmg_tx_mode { 2926b5aeff16SDedy Lansky WMI_TX_MODE_DMG = 0x0, 2927b5aeff16SDedy Lansky WMI_TX_MODE_EDMG_CB1 = 0x1, 2928b5aeff16SDedy Lansky WMI_TX_MODE_EDMG_CB2 = 0x2, 2929b5aeff16SDedy Lansky WMI_TX_MODE_EDMG_CB1_LONG_LDPC = 0x3, 2930b5aeff16SDedy Lansky WMI_TX_MODE_EDMG_CB2_LONG_LDPC = 0x4, 2931b5aeff16SDedy Lansky WMI_TX_MODE_MAX, 2932b5aeff16SDedy Lansky }; 2933b5aeff16SDedy Lansky 2934b5aeff16SDedy Lansky /* Rate search parameters common configuration */ 2935b5aeff16SDedy Lansky struct wmi_rs_cfg_ex_common { 2936b5aeff16SDedy Lansky /* enum wmi_edmg_tx_mode */ 2937b5aeff16SDedy Lansky u8 mode; 2938b5aeff16SDedy Lansky /* stop threshold [0-100] */ 2939b5aeff16SDedy Lansky u8 stop_th; 2940b5aeff16SDedy Lansky /* MCS1 stop threshold [0-100] */ 2941b5aeff16SDedy Lansky u8 mcs1_fail_th; 2942b5aeff16SDedy Lansky u8 max_back_failure_th; 2943b5aeff16SDedy Lansky /* Debug feature for disabling internal RS trigger (which is 2944b5aeff16SDedy Lansky * currently triggered by BF Done) 2945b5aeff16SDedy Lansky */ 2946b5aeff16SDedy Lansky u8 dbg_disable_internal_trigger; 2947b5aeff16SDedy Lansky u8 reserved[3]; 2948b5aeff16SDedy Lansky __le32 back_failure_mask; 2949b5aeff16SDedy Lansky } __packed; 2950b5aeff16SDedy Lansky 2951b5aeff16SDedy Lansky /* Rate search parameters configuration per MCS */ 2952b5aeff16SDedy Lansky struct wmi_rs_cfg_ex_mcs { 2953b5aeff16SDedy Lansky /* The maximal allowed PER for each MCS 2954b5aeff16SDedy Lansky * MCS will be considered as failed if PER during RS is higher 2955b5aeff16SDedy Lansky */ 2956b5aeff16SDedy Lansky u8 per_threshold; 2957b5aeff16SDedy Lansky /* Number of MPDUs for each MCS 2958b5aeff16SDedy Lansky * this is the minimal statistic required to make an educated 2959b5aeff16SDedy Lansky * decision 2960b5aeff16SDedy Lansky */ 2961b5aeff16SDedy Lansky u8 min_frame_cnt; 2962b5aeff16SDedy Lansky u8 reserved[2]; 2963b5aeff16SDedy Lansky } __packed; 2964b5aeff16SDedy Lansky 2965b5aeff16SDedy Lansky /* WMI_RS_CFG_EX_CMDID */ 2966b5aeff16SDedy Lansky struct wmi_rs_cfg_ex_cmd { 2967b5aeff16SDedy Lansky /* Configuration for all MCSs */ 2968b5aeff16SDedy Lansky struct wmi_rs_cfg_ex_common common_cfg; 2969b5aeff16SDedy Lansky u8 each_mcs_cfg_size; 2970b5aeff16SDedy Lansky u8 reserved[3]; 2971b5aeff16SDedy Lansky /* Configuration for each MCS */ 2972104f3d95SGustavo A. R. Silva struct wmi_rs_cfg_ex_mcs each_mcs_cfg[]; 2973b5aeff16SDedy Lansky } __packed; 2974b5aeff16SDedy Lansky 2975b5aeff16SDedy Lansky /* WMI_RS_CFG_EX_EVENTID */ 2976b5aeff16SDedy Lansky struct wmi_rs_cfg_ex_event { 2977b5aeff16SDedy Lansky /* enum wmi_edmg_tx_mode */ 2978b5aeff16SDedy Lansky u8 mode; 2979b5aeff16SDedy Lansky /* enum wmi_fw_status */ 2980b5aeff16SDedy Lansky u8 status; 2981b5aeff16SDedy Lansky u8 reserved[2]; 2982b5aeff16SDedy Lansky } __packed; 2983b5aeff16SDedy Lansky 2984b5aeff16SDedy Lansky /* WMI_RS_ENABLE_CMDID */ 2985b5aeff16SDedy Lansky struct wmi_rs_enable_cmd { 2986b5aeff16SDedy Lansky u8 cid; 2987b5aeff16SDedy Lansky /* enable or disable rate search */ 2988b5aeff16SDedy Lansky u8 rs_enable; 2989b5aeff16SDedy Lansky u8 reserved[2]; 2990b5aeff16SDedy Lansky __le32 mcs_en_vec; 2991b5aeff16SDedy Lansky } __packed; 2992b5aeff16SDedy Lansky 2993b5aeff16SDedy Lansky /* WMI_RS_ENABLE_EVENTID */ 2994b5aeff16SDedy Lansky struct wmi_rs_enable_event { 2995b5aeff16SDedy Lansky /* enum wmi_fw_status */ 2996b5aeff16SDedy Lansky u8 status; 2997b5aeff16SDedy Lansky u8 reserved[3]; 2998b5aeff16SDedy Lansky } __packed; 2999b5aeff16SDedy Lansky 3000761f8e4dSLazar Alexei /* Slot types */ 3001761f8e4dSLazar Alexei enum wmi_sched_scheme_slot_type { 3002761f8e4dSLazar Alexei WMI_SCHED_SLOT_SP = 0x0, 3003761f8e4dSLazar Alexei WMI_SCHED_SLOT_CBAP = 0x1, 3004761f8e4dSLazar Alexei WMI_SCHED_SLOT_IDLE = 0x2, 3005761f8e4dSLazar Alexei WMI_SCHED_SLOT_ANNOUNCE_NO_ACK = 0x3, 3006761f8e4dSLazar Alexei WMI_SCHED_SLOT_DISCOVERY = 0x4, 3007761f8e4dSLazar Alexei }; 3008761f8e4dSLazar Alexei 3009761f8e4dSLazar Alexei enum wmi_sched_scheme_slot_flags { 3010761f8e4dSLazar Alexei WMI_SCHED_SCHEME_SLOT_PERIODIC = 0x1, 3011761f8e4dSLazar Alexei }; 3012761f8e4dSLazar Alexei 3013761f8e4dSLazar Alexei struct wmi_sched_scheme_slot { 3014761f8e4dSLazar Alexei /* in microsecond */ 3015761f8e4dSLazar Alexei __le32 tbtt_offset; 3016761f8e4dSLazar Alexei /* wmi_sched_scheme_slot_flags */ 3017761f8e4dSLazar Alexei u8 flags; 3018761f8e4dSLazar Alexei /* wmi_sched_scheme_slot_type */ 3019761f8e4dSLazar Alexei u8 type; 3020761f8e4dSLazar Alexei /* in microsecond */ 3021761f8e4dSLazar Alexei __le16 duration; 3022761f8e4dSLazar Alexei /* frame_exchange_sequence_duration */ 3023761f8e4dSLazar Alexei __le16 tx_op; 3024761f8e4dSLazar Alexei /* time in microseconds between two consecutive slots 3025761f8e4dSLazar Alexei * relevant only if flag WMI_SCHED_SCHEME_SLOT_PERIODIC set 3026761f8e4dSLazar Alexei */ 3027761f8e4dSLazar Alexei __le16 period; 3028761f8e4dSLazar Alexei /* relevant only if flag WMI_SCHED_SCHEME_SLOT_PERIODIC set 3029761f8e4dSLazar Alexei * number of times to repeat allocation 3030761f8e4dSLazar Alexei */ 3031761f8e4dSLazar Alexei u8 num_of_blocks; 3032761f8e4dSLazar Alexei /* relevant only if flag WMI_SCHED_SCHEME_SLOT_PERIODIC set 3033761f8e4dSLazar Alexei * every idle_period allocation will be idle 3034761f8e4dSLazar Alexei */ 3035761f8e4dSLazar Alexei u8 idle_period; 3036761f8e4dSLazar Alexei u8 src_aid; 3037761f8e4dSLazar Alexei u8 dest_aid; 3038761f8e4dSLazar Alexei __le32 reserved; 3039761f8e4dSLazar Alexei } __packed; 3040761f8e4dSLazar Alexei 3041761f8e4dSLazar Alexei enum wmi_sched_scheme_flags { 3042761f8e4dSLazar Alexei /* should not be set when clearing scheduling scheme */ 3043761f8e4dSLazar Alexei WMI_SCHED_SCHEME_ENABLE = 0x01, 3044761f8e4dSLazar Alexei WMI_SCHED_PROTECTED_SP = 0x02, 3045761f8e4dSLazar Alexei /* should be set only on first WMI fragment of scheme */ 3046761f8e4dSLazar Alexei WMI_SCHED_FIRST = 0x04, 3047761f8e4dSLazar Alexei /* should be set only on last WMI fragment of scheme */ 3048761f8e4dSLazar Alexei WMI_SCHED_LAST = 0x08, 3049761f8e4dSLazar Alexei WMI_SCHED_IMMEDIATE_START = 0x10, 3050761f8e4dSLazar Alexei }; 3051761f8e4dSLazar Alexei 3052761f8e4dSLazar Alexei enum wmi_sched_scheme_advertisment { 3053761f8e4dSLazar Alexei /* ESE is not advertised at all, STA has to be configured with WMI 3054761f8e4dSLazar Alexei * also 3055761f8e4dSLazar Alexei */ 3056761f8e4dSLazar Alexei WMI_ADVERTISE_ESE_DISABLED = 0x0, 3057761f8e4dSLazar Alexei WMI_ADVERTISE_ESE_IN_BEACON = 0x1, 3058761f8e4dSLazar Alexei WMI_ADVERTISE_ESE_IN_ANNOUNCE_FRAME = 0x2, 3059761f8e4dSLazar Alexei }; 3060761f8e4dSLazar Alexei 3061761f8e4dSLazar Alexei /* WMI_SCHEDULING_SCHEME_CMD */ 3062761f8e4dSLazar Alexei struct wmi_scheduling_scheme_cmd { 3063761f8e4dSLazar Alexei u8 serial_num; 3064761f8e4dSLazar Alexei /* wmi_sched_scheme_advertisment */ 3065761f8e4dSLazar Alexei u8 ese_advertisment; 3066761f8e4dSLazar Alexei /* wmi_sched_scheme_flags */ 3067761f8e4dSLazar Alexei __le16 flags; 3068761f8e4dSLazar Alexei u8 num_allocs; 3069761f8e4dSLazar Alexei u8 reserved[3]; 3070761f8e4dSLazar Alexei __le64 start_tbtt; 3071761f8e4dSLazar Alexei /* allocations list */ 3072761f8e4dSLazar Alexei struct wmi_sched_scheme_slot allocs[WMI_SCHED_MAX_ALLOCS_PER_CMD]; 3073761f8e4dSLazar Alexei } __packed; 3074761f8e4dSLazar Alexei 3075761f8e4dSLazar Alexei enum wmi_sched_scheme_failure_type { 3076761f8e4dSLazar Alexei WMI_SCHED_SCHEME_FAILURE_NO_ERROR = 0x00, 3077761f8e4dSLazar Alexei WMI_SCHED_SCHEME_FAILURE_OLD_START_TSF_ERR = 0x01, 3078761f8e4dSLazar Alexei }; 3079761f8e4dSLazar Alexei 3080761f8e4dSLazar Alexei /* WMI_SCHEDULING_SCHEME_EVENTID */ 3081761f8e4dSLazar Alexei struct wmi_scheduling_scheme_event { 3082761f8e4dSLazar Alexei /* wmi_fw_status_e */ 3083761f8e4dSLazar Alexei u8 status; 3084761f8e4dSLazar Alexei /* serial number given in command */ 3085761f8e4dSLazar Alexei u8 serial_num; 3086761f8e4dSLazar Alexei /* wmi_sched_scheme_failure_type */ 3087761f8e4dSLazar Alexei u8 failure_type; 3088761f8e4dSLazar Alexei /* alignment to 32b */ 3089761f8e4dSLazar Alexei u8 reserved[1]; 3090761f8e4dSLazar Alexei } __packed; 3091761f8e4dSLazar Alexei 3092b5aeff16SDedy Lansky /* WMI_RS_CFG_CMDID - deprecated */ 30930163b031SMaya Erez struct wmi_rs_cfg_cmd { 30940163b031SMaya Erez /* connection id */ 30950163b031SMaya Erez u8 cid; 30960163b031SMaya Erez /* enable or disable rate search */ 30970163b031SMaya Erez u8 rs_enable; 30980163b031SMaya Erez /* rate search configuration */ 30990163b031SMaya Erez struct wmi_rs_cfg rs_cfg; 31000163b031SMaya Erez } __packed; 31010163b031SMaya Erez 3102b5aeff16SDedy Lansky /* WMI_RS_CFG_DONE_EVENTID - deprecated */ 31030163b031SMaya Erez struct wmi_rs_cfg_done_event { 31040163b031SMaya Erez u8 cid; 31050163b031SMaya Erez /* enum wmi_fw_status */ 31060163b031SMaya Erez u8 status; 31070163b031SMaya Erez u8 reserved[2]; 31080163b031SMaya Erez } __packed; 31090163b031SMaya Erez 3110b5aeff16SDedy Lansky /* WMI_GET_DETAILED_RS_RES_CMDID - deprecated */ 311108989f96SLior David struct wmi_get_detailed_rs_res_cmd { 311208989f96SLior David /* connection id */ 311308989f96SLior David u8 cid; 311408989f96SLior David u8 reserved[3]; 311508989f96SLior David } __packed; 311608989f96SLior David 311708989f96SLior David /* RS results status */ 311808989f96SLior David enum wmi_rs_results_status { 311908989f96SLior David WMI_RS_RES_VALID = 0x00, 312008989f96SLior David WMI_RS_RES_INVALID = 0x01, 312108989f96SLior David }; 312208989f96SLior David 312308989f96SLior David /* Rate search results */ 312408989f96SLior David struct wmi_rs_results { 312508989f96SLior David /* number of sent MPDUs */ 312608989f96SLior David u8 num_of_tx_pkt[WMI_NUM_MCS]; 312708989f96SLior David /* number of non-acked MPDUs */ 312808989f96SLior David u8 num_of_non_acked_pkt[WMI_NUM_MCS]; 312908989f96SLior David /* RS timestamp */ 313008989f96SLior David __le32 tsf; 313108989f96SLior David /* RS selected MCS */ 313208989f96SLior David u8 mcs; 313308989f96SLior David } __packed; 313408989f96SLior David 3135b5aeff16SDedy Lansky /* WMI_GET_DETAILED_RS_RES_EVENTID - deprecated */ 313608989f96SLior David struct wmi_get_detailed_rs_res_event { 313708989f96SLior David u8 cid; 313808989f96SLior David /* enum wmi_rs_results_status */ 313908989f96SLior David u8 status; 314008989f96SLior David /* detailed rs results */ 314108989f96SLior David struct wmi_rs_results rs_results; 314208989f96SLior David u8 reserved[3]; 314308989f96SLior David } __packed; 314408989f96SLior David 3145b5aeff16SDedy Lansky /* WMI_GET_DETAILED_RS_RES_EX_CMDID */ 3146b5aeff16SDedy Lansky struct wmi_get_detailed_rs_res_ex_cmd { 3147b5aeff16SDedy Lansky u8 cid; 3148b5aeff16SDedy Lansky u8 reserved[3]; 3149b5aeff16SDedy Lansky } __packed; 3150b5aeff16SDedy Lansky 3151b5aeff16SDedy Lansky /* Rate search results */ 3152b5aeff16SDedy Lansky struct wmi_rs_results_ex_common { 3153b5aeff16SDedy Lansky /* RS timestamp */ 3154b5aeff16SDedy Lansky __le32 tsf; 3155b5aeff16SDedy Lansky /* RS selected MCS */ 3156b5aeff16SDedy Lansky u8 mcs; 3157b5aeff16SDedy Lansky /* enum wmi_edmg_tx_mode */ 3158b5aeff16SDedy Lansky u8 mode; 3159b5aeff16SDedy Lansky u8 reserved[2]; 3160b5aeff16SDedy Lansky } __packed; 3161b5aeff16SDedy Lansky 3162b5aeff16SDedy Lansky /* Rate search results */ 3163b5aeff16SDedy Lansky struct wmi_rs_results_ex_mcs { 3164b5aeff16SDedy Lansky /* number of sent MPDUs */ 3165b5aeff16SDedy Lansky u8 num_of_tx_pkt; 3166b5aeff16SDedy Lansky /* number of non-acked MPDUs */ 3167b5aeff16SDedy Lansky u8 num_of_non_acked_pkt; 3168b5aeff16SDedy Lansky u8 reserved[2]; 3169b5aeff16SDedy Lansky } __packed; 3170b5aeff16SDedy Lansky 3171b5aeff16SDedy Lansky /* WMI_GET_DETAILED_RS_RES_EX_EVENTID */ 3172b5aeff16SDedy Lansky struct wmi_get_detailed_rs_res_ex_event { 3173b5aeff16SDedy Lansky u8 cid; 3174b5aeff16SDedy Lansky /* enum wmi_rs_results_status */ 3175b5aeff16SDedy Lansky u8 status; 3176b5aeff16SDedy Lansky u8 reserved0[2]; 3177b5aeff16SDedy Lansky struct wmi_rs_results_ex_common common_rs_results; 3178b5aeff16SDedy Lansky u8 each_mcs_results_size; 3179b5aeff16SDedy Lansky u8 reserved1[3]; 3180b5aeff16SDedy Lansky /* Results for each MCS */ 3181104f3d95SGustavo A. R. Silva struct wmi_rs_results_ex_mcs each_mcs_results[]; 3182b5aeff16SDedy Lansky } __packed; 3183b5aeff16SDedy Lansky 3184a52fb913SLior David /* BRP antenna limit mode */ 3185a52fb913SLior David enum wmi_brp_ant_limit_mode { 3186a52fb913SLior David /* Disable BRP force antenna limit */ 3187a52fb913SLior David WMI_BRP_ANT_LIMIT_MODE_DISABLE = 0x00, 3188a52fb913SLior David /* Define maximal antennas limit. Only effective antennas will be 3189a52fb913SLior David * actually used 3190a52fb913SLior David */ 3191a52fb913SLior David WMI_BRP_ANT_LIMIT_MODE_EFFECTIVE = 0x01, 3192a52fb913SLior David /* Force a specific number of antennas */ 3193a52fb913SLior David WMI_BRP_ANT_LIMIT_MODE_FORCE = 0x02, 3194a52fb913SLior David /* number of BRP antenna limit modes */ 3195a52fb913SLior David WMI_BRP_ANT_LIMIT_MODES_NUM = 0x03, 3196a52fb913SLior David }; 3197a52fb913SLior David 3198a52fb913SLior David /* WMI_BRP_SET_ANT_LIMIT_CMDID */ 3199a52fb913SLior David struct wmi_brp_set_ant_limit_cmd { 3200a52fb913SLior David /* connection id */ 3201a52fb913SLior David u8 cid; 3202a52fb913SLior David /* enum wmi_brp_ant_limit_mode */ 3203a52fb913SLior David u8 limit_mode; 3204a52fb913SLior David /* antenna limit count, 1-27 3205a52fb913SLior David * disable_mode - ignored 3206a52fb913SLior David * effective_mode - upper limit to number of antennas to be used 3207a52fb913SLior David * force_mode - exact number of antennas to be used 3208a52fb913SLior David */ 3209a52fb913SLior David u8 ant_limit; 3210a52fb913SLior David u8 reserved; 3211a52fb913SLior David } __packed; 3212a52fb913SLior David 3213a52fb913SLior David /* WMI_BRP_SET_ANT_LIMIT_EVENTID */ 3214a52fb913SLior David struct wmi_brp_set_ant_limit_event { 3215a52fb913SLior David /* wmi_fw_status */ 3216a52fb913SLior David u8 status; 3217a52fb913SLior David u8 reserved[3]; 3218a52fb913SLior David } __packed; 3219a52fb913SLior David 322073a7d1e3SAlexei Avshalom Lazar enum wmi_bf_type { 322173a7d1e3SAlexei Avshalom Lazar WMI_BF_TYPE_SLS = 0x00, 322273a7d1e3SAlexei Avshalom Lazar WMI_BF_TYPE_BRP_RX = 0x01, 322373a7d1e3SAlexei Avshalom Lazar }; 322473a7d1e3SAlexei Avshalom Lazar 322573a7d1e3SAlexei Avshalom Lazar /* WMI_BF_TRIG_CMDID */ 322673a7d1e3SAlexei Avshalom Lazar struct wmi_bf_trig_cmd { 322773a7d1e3SAlexei Avshalom Lazar /* enum wmi_bf_type - type of requested beamforming */ 322873a7d1e3SAlexei Avshalom Lazar u8 bf_type; 322973a7d1e3SAlexei Avshalom Lazar /* used only for WMI_BF_TYPE_BRP_RX */ 323073a7d1e3SAlexei Avshalom Lazar u8 cid; 323173a7d1e3SAlexei Avshalom Lazar /* used only for WMI_BF_TYPE_SLS */ 323273a7d1e3SAlexei Avshalom Lazar u8 dst_mac[WMI_MAC_LEN]; 323373a7d1e3SAlexei Avshalom Lazar u8 reserved[4]; 323473a7d1e3SAlexei Avshalom Lazar } __packed; 323573a7d1e3SAlexei Avshalom Lazar 323673a7d1e3SAlexei Avshalom Lazar /* WMI_BF_TRIG_EVENTID */ 323773a7d1e3SAlexei Avshalom Lazar struct wmi_bf_trig_event { 323873a7d1e3SAlexei Avshalom Lazar /* enum wmi_fw_status */ 323973a7d1e3SAlexei Avshalom Lazar u8 status; 324073a7d1e3SAlexei Avshalom Lazar u8 cid; 324173a7d1e3SAlexei Avshalom Lazar u8 reserved[2]; 324273a7d1e3SAlexei Avshalom Lazar } __packed; 324373a7d1e3SAlexei Avshalom Lazar 32440163b031SMaya Erez /* broadcast connection ID */ 32450163b031SMaya Erez #define WMI_LINK_MAINTAIN_CFG_CID_BROADCAST (0xFFFFFFFF) 32460163b031SMaya Erez 32470163b031SMaya Erez /* Types wmi_link_maintain_cfg presets for WMI_LINK_MAINTAIN_CFG_WRITE_CMD */ 32480163b031SMaya Erez enum wmi_link_maintain_cfg_type { 32490163b031SMaya Erez /* AP/PCP default normal (non-FST) configuration settings */ 32500163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_NORMAL_AP = 0x00, 32510163b031SMaya Erez /* AP/PCP default FST configuration settings */ 32520163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_FST_AP = 0x01, 32530163b031SMaya Erez /* STA default normal (non-FST) configuration settings */ 32540163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_NORMAL_STA = 0x02, 32550163b031SMaya Erez /* STA default FST configuration settings */ 32560163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_TYPE_DEFAULT_FST_STA = 0x03, 32570163b031SMaya Erez /* custom configuration settings */ 32580163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_TYPE_CUSTOM = 0x04, 32590163b031SMaya Erez /* number of defined configuration types */ 32600163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_TYPES_NUM = 0x05, 32610163b031SMaya Erez }; 32620163b031SMaya Erez 32630163b031SMaya Erez /* Response status codes for WMI_LINK_MAINTAIN_CFG_WRITE/READ commands */ 32640163b031SMaya Erez enum wmi_link_maintain_cfg_response_status { 32650163b031SMaya Erez /* WMI_LINK_MAINTAIN_CFG_WRITE/READ command successfully accomplished 32660163b031SMaya Erez */ 32670163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_RESPONSE_STATUS_OK = 0x00, 32680163b031SMaya Erez /* ERROR due to bad argument in WMI_LINK_MAINTAIN_CFG_WRITE/READ 32690163b031SMaya Erez * command request 32700163b031SMaya Erez */ 32710163b031SMaya Erez WMI_LINK_MAINTAIN_CFG_RESPONSE_STATUS_BAD_ARGUMENT = 0x01, 32720163b031SMaya Erez }; 32730163b031SMaya Erez 32740163b031SMaya Erez /* Link Loss and Keep Alive configuration */ 32750163b031SMaya Erez struct wmi_link_maintain_cfg { 32760163b031SMaya Erez /* link_loss_enable_detectors_vec */ 32770163b031SMaya Erez __le32 link_loss_enable_detectors_vec; 32780163b031SMaya Erez /* detectors check period usec */ 32790163b031SMaya Erez __le32 check_link_loss_period_usec; 32800163b031SMaya Erez /* max allowed tx ageing */ 32810163b031SMaya Erez __le32 tx_ageing_threshold_usec; 32820163b031SMaya Erez /* keep alive period for high SNR */ 32830163b031SMaya Erez __le32 keep_alive_period_usec_high_snr; 32840163b031SMaya Erez /* keep alive period for low SNR */ 32850163b031SMaya Erez __le32 keep_alive_period_usec_low_snr; 32860163b031SMaya Erez /* lower snr limit for keep alive period update */ 32870163b031SMaya Erez __le32 keep_alive_snr_threshold_low_db; 32880163b031SMaya Erez /* upper snr limit for keep alive period update */ 32890163b031SMaya Erez __le32 keep_alive_snr_threshold_high_db; 32900163b031SMaya Erez /* num of successive bad bcons causing link-loss */ 32910163b031SMaya Erez __le32 bad_beacons_num_threshold; 32920163b031SMaya Erez /* SNR limit for bad_beacons_detector */ 32930163b031SMaya Erez __le32 bad_beacons_snr_threshold_db; 32948a4fa214SAhmad Masri /* timeout for disassoc response frame in uSec */ 32958a4fa214SAhmad Masri __le32 disconnect_timeout; 32960163b031SMaya Erez } __packed; 32970163b031SMaya Erez 32980163b031SMaya Erez /* WMI_LINK_MAINTAIN_CFG_WRITE_CMDID */ 32990163b031SMaya Erez struct wmi_link_maintain_cfg_write_cmd { 33000163b031SMaya Erez /* enum wmi_link_maintain_cfg_type_e - type of requested default 33010163b031SMaya Erez * configuration to be applied 33020163b031SMaya Erez */ 33030163b031SMaya Erez __le32 cfg_type; 33040163b031SMaya Erez /* requested connection ID or WMI_LINK_MAINTAIN_CFG_CID_BROADCAST */ 33050163b031SMaya Erez __le32 cid; 33060163b031SMaya Erez /* custom configuration settings to be applied (relevant only if 33070163b031SMaya Erez * cfg_type==WMI_LINK_MAINTAIN_CFG_TYPE_CUSTOM) 33080163b031SMaya Erez */ 33090163b031SMaya Erez struct wmi_link_maintain_cfg lm_cfg; 33100163b031SMaya Erez } __packed; 33110163b031SMaya Erez 33120163b031SMaya Erez /* WMI_LINK_MAINTAIN_CFG_READ_CMDID */ 33130163b031SMaya Erez struct wmi_link_maintain_cfg_read_cmd { 33140163b031SMaya Erez /* connection ID which configuration settings are requested */ 33150163b031SMaya Erez __le32 cid; 33160163b031SMaya Erez } __packed; 33170163b031SMaya Erez 33184315a74aSDedy Lansky /* WMI_SET_LINK_MONITOR_CMDID */ 33194315a74aSDedy Lansky struct wmi_set_link_monitor_cmd { 33204315a74aSDedy Lansky u8 rssi_hyst; 33214315a74aSDedy Lansky u8 reserved[12]; 33224315a74aSDedy Lansky u8 rssi_thresholds_list_size; 3323104f3d95SGustavo A. R. Silva s8 rssi_thresholds_list[]; 33244315a74aSDedy Lansky } __packed; 33254315a74aSDedy Lansky 33264315a74aSDedy Lansky /* wmi_link_monitor_event_type */ 33274315a74aSDedy Lansky enum wmi_link_monitor_event_type { 33284315a74aSDedy Lansky WMI_LINK_MONITOR_NOTIF_RSSI_THRESHOLD_EVT = 0x00, 33294315a74aSDedy Lansky WMI_LINK_MONITOR_NOTIF_TX_ERR_EVT = 0x01, 33304315a74aSDedy Lansky WMI_LINK_MONITOR_NOTIF_THERMAL_EVT = 0x02, 33314315a74aSDedy Lansky }; 33324315a74aSDedy Lansky 33334315a74aSDedy Lansky /* WMI_SET_LINK_MONITOR_EVENTID */ 33344315a74aSDedy Lansky struct wmi_set_link_monitor_event { 33354315a74aSDedy Lansky /* wmi_fw_status */ 33364315a74aSDedy Lansky u8 status; 33374315a74aSDedy Lansky u8 reserved[3]; 33384315a74aSDedy Lansky } __packed; 33394315a74aSDedy Lansky 33404315a74aSDedy Lansky /* WMI_LINK_MONITOR_EVENTID */ 33414315a74aSDedy Lansky struct wmi_link_monitor_event { 33424315a74aSDedy Lansky /* link_monitor_event_type */ 33434315a74aSDedy Lansky u8 type; 33444315a74aSDedy Lansky s8 rssi_level; 33454315a74aSDedy Lansky u8 reserved[2]; 33464315a74aSDedy Lansky } __packed; 33474315a74aSDedy Lansky 33480163b031SMaya Erez /* WMI_LINK_MAINTAIN_CFG_WRITE_DONE_EVENTID */ 33490163b031SMaya Erez struct wmi_link_maintain_cfg_write_done_event { 33500163b031SMaya Erez /* requested connection ID */ 33510163b031SMaya Erez __le32 cid; 33520163b031SMaya Erez /* wmi_link_maintain_cfg_response_status_e - write status */ 33530163b031SMaya Erez __le32 status; 33540163b031SMaya Erez } __packed; 33550163b031SMaya Erez 33560163b031SMaya Erez /* \WMI_LINK_MAINTAIN_CFG_READ_DONE_EVENT */ 33570163b031SMaya Erez struct wmi_link_maintain_cfg_read_done_event { 33580163b031SMaya Erez /* requested connection ID */ 33590163b031SMaya Erez __le32 cid; 33600163b031SMaya Erez /* wmi_link_maintain_cfg_response_status_e - read status */ 33610163b031SMaya Erez __le32 status; 33620163b031SMaya Erez /* Retrieved configuration settings */ 33630163b031SMaya Erez struct wmi_link_maintain_cfg lm_cfg; 33640163b031SMaya Erez } __packed; 33650163b031SMaya Erez 3366fe9ee51eSMaya Erez enum wmi_traffic_suspend_status { 3367fe9ee51eSMaya Erez WMI_TRAFFIC_SUSPEND_APPROVED = 0x0, 33686804cd10SLazar Alexei WMI_TRAFFIC_SUSPEND_REJECTED_LINK_NOT_IDLE = 0x1, 336973a7d1e3SAlexei Avshalom Lazar WMI_TRAFFIC_SUSPEND_REJECTED_DISCONNECT = 0x2, 337073a7d1e3SAlexei Avshalom Lazar WMI_TRAFFIC_SUSPEND_REJECTED_OTHER = 0x3, 33710163b031SMaya Erez }; 33720163b031SMaya Erez 3373fe9ee51eSMaya Erez /* WMI_TRAFFIC_SUSPEND_EVENTID */ 3374fe9ee51eSMaya Erez struct wmi_traffic_suspend_event { 3375fe9ee51eSMaya Erez /* enum wmi_traffic_suspend_status_e */ 33760163b031SMaya Erez u8 status; 33770163b031SMaya Erez } __packed; 33780163b031SMaya Erez 33790163b031SMaya Erez enum wmi_traffic_resume_status { 33800163b031SMaya Erez WMI_TRAFFIC_RESUME_SUCCESS = 0x0, 33810163b031SMaya Erez WMI_TRAFFIC_RESUME_FAILED = 0x1, 33820163b031SMaya Erez }; 33830163b031SMaya Erez 33846804cd10SLazar Alexei enum wmi_resume_trigger { 33856804cd10SLazar Alexei WMI_RESUME_TRIGGER_UNKNOWN = 0x0, 33866804cd10SLazar Alexei WMI_RESUME_TRIGGER_HOST = 0x1, 33876804cd10SLazar Alexei WMI_RESUME_TRIGGER_UCAST_RX = 0x2, 33886804cd10SLazar Alexei WMI_RESUME_TRIGGER_BCAST_RX = 0x4, 33896804cd10SLazar Alexei WMI_RESUME_TRIGGER_WMI_EVT = 0x8, 339073a7d1e3SAlexei Avshalom Lazar WMI_RESUME_TRIGGER_DISCONNECT = 0x10, 33916804cd10SLazar Alexei }; 33926804cd10SLazar Alexei 33930163b031SMaya Erez /* WMI_TRAFFIC_RESUME_EVENTID */ 33940163b031SMaya Erez struct wmi_traffic_resume_event { 33956804cd10SLazar Alexei /* enum wmi_traffic_resume_status */ 33960163b031SMaya Erez u8 status; 33976804cd10SLazar Alexei u8 reserved[3]; 33986804cd10SLazar Alexei /* enum wmi_resume_trigger bitmap */ 33996804cd10SLazar Alexei __le32 resume_triggers; 34000163b031SMaya Erez } __packed; 34010163b031SMaya Erez 34020163b031SMaya Erez /* Power Save command completion status codes */ 34030163b031SMaya Erez enum wmi_ps_cfg_cmd_status { 34040163b031SMaya Erez WMI_PS_CFG_CMD_STATUS_SUCCESS = 0x00, 34050163b031SMaya Erez WMI_PS_CFG_CMD_STATUS_BAD_PARAM = 0x01, 34060163b031SMaya Erez /* other error */ 34070163b031SMaya Erez WMI_PS_CFG_CMD_STATUS_ERROR = 0x02, 34080163b031SMaya Erez }; 34090163b031SMaya Erez 34100163b031SMaya Erez /* Device Power Save Profiles */ 34110163b031SMaya Erez enum wmi_ps_profile_type { 34120163b031SMaya Erez WMI_PS_PROFILE_TYPE_DEFAULT = 0x00, 34130163b031SMaya Erez WMI_PS_PROFILE_TYPE_PS_DISABLED = 0x01, 34140163b031SMaya Erez WMI_PS_PROFILE_TYPE_MAX_PS = 0x02, 34150163b031SMaya Erez WMI_PS_PROFILE_TYPE_LOW_LATENCY_PS = 0x03, 34160163b031SMaya Erez }; 34170163b031SMaya Erez 3418761f8e4dSLazar Alexei /* WMI_PS_DEV_PROFILE_CFG_READ_CMDID */ 3419761f8e4dSLazar Alexei struct wmi_ps_dev_profile_cfg_read_cmd { 3420761f8e4dSLazar Alexei /* reserved */ 3421761f8e4dSLazar Alexei __le32 reserved; 3422761f8e4dSLazar Alexei } __packed; 3423761f8e4dSLazar Alexei 3424761f8e4dSLazar Alexei /* WMI_PS_DEV_PROFILE_CFG_READ_EVENTID */ 3425761f8e4dSLazar Alexei struct wmi_ps_dev_profile_cfg_read_event { 3426761f8e4dSLazar Alexei /* wmi_ps_profile_type_e */ 3427761f8e4dSLazar Alexei u8 ps_profile; 3428761f8e4dSLazar Alexei u8 reserved[3]; 3429761f8e4dSLazar Alexei } __packed; 3430761f8e4dSLazar Alexei 34310163b031SMaya Erez /* WMI_PS_DEV_PROFILE_CFG_CMDID 34320163b031SMaya Erez * 34330163b031SMaya Erez * Power save profile to be used by the device 34340163b031SMaya Erez * 34350163b031SMaya Erez * Returned event: 34360163b031SMaya Erez * - WMI_PS_DEV_PROFILE_CFG_EVENTID 34370163b031SMaya Erez */ 34380163b031SMaya Erez struct wmi_ps_dev_profile_cfg_cmd { 34390163b031SMaya Erez /* wmi_ps_profile_type_e */ 34400163b031SMaya Erez u8 ps_profile; 34410163b031SMaya Erez u8 reserved[3]; 34420163b031SMaya Erez } __packed; 34430163b031SMaya Erez 34440163b031SMaya Erez /* WMI_PS_DEV_PROFILE_CFG_EVENTID */ 34450163b031SMaya Erez struct wmi_ps_dev_profile_cfg_event { 34460163b031SMaya Erez /* wmi_ps_cfg_cmd_status_e */ 34470163b031SMaya Erez __le32 status; 34480163b031SMaya Erez } __packed; 34490163b031SMaya Erez 34500163b031SMaya Erez enum wmi_ps_level { 34510163b031SMaya Erez WMI_PS_LEVEL_DEEP_SLEEP = 0x00, 34520163b031SMaya Erez WMI_PS_LEVEL_SHALLOW_SLEEP = 0x01, 34530163b031SMaya Erez /* awake = all PS mechanisms are disabled */ 34540163b031SMaya Erez WMI_PS_LEVEL_AWAKE = 0x02, 34550163b031SMaya Erez }; 34560163b031SMaya Erez 34570163b031SMaya Erez enum wmi_ps_deep_sleep_clk_level { 34580163b031SMaya Erez /* 33k */ 34590163b031SMaya Erez WMI_PS_DEEP_SLEEP_CLK_LEVEL_RTC = 0x00, 34600163b031SMaya Erez /* 10k */ 34610163b031SMaya Erez WMI_PS_DEEP_SLEEP_CLK_LEVEL_OSC = 0x01, 34620163b031SMaya Erez /* @RTC Low latency */ 34630163b031SMaya Erez WMI_PS_DEEP_SLEEP_CLK_LEVEL_RTC_LT = 0x02, 34640163b031SMaya Erez WMI_PS_DEEP_SLEEP_CLK_LEVEL_XTAL = 0x03, 34650163b031SMaya Erez WMI_PS_DEEP_SLEEP_CLK_LEVEL_SYSCLK = 0x04, 34660163b031SMaya Erez /* Not Applicable */ 34670163b031SMaya Erez WMI_PS_DEEP_SLEEP_CLK_LEVEL_N_A = 0xFF, 34680163b031SMaya Erez }; 34690163b031SMaya Erez 34700163b031SMaya Erez /* Response by the FW to a D3 entry request */ 34710163b031SMaya Erez enum wmi_ps_d3_resp_policy { 34720163b031SMaya Erez WMI_PS_D3_RESP_POLICY_DEFAULT = 0x00, 34730163b031SMaya Erez /* debug -D3 req is always denied */ 34740163b031SMaya Erez WMI_PS_D3_RESP_POLICY_DENIED = 0x01, 34750163b031SMaya Erez /* debug -D3 req is always approved */ 34760163b031SMaya Erez WMI_PS_D3_RESP_POLICY_APPROVED = 0x02, 34770163b031SMaya Erez }; 34780163b031SMaya Erez 347908989f96SLior David #define WMI_AOA_MAX_DATA_SIZE (128) 348008989f96SLior David 348108989f96SLior David enum wmi_aoa_meas_status { 348208989f96SLior David WMI_AOA_MEAS_SUCCESS = 0x00, 348308989f96SLior David WMI_AOA_MEAS_PEER_INCAPABLE = 0x01, 348408989f96SLior David WMI_AOA_MEAS_FAILURE = 0x02, 348508989f96SLior David }; 348608989f96SLior David 348708989f96SLior David /* WMI_AOA_MEAS_EVENTID */ 348808989f96SLior David struct wmi_aoa_meas_event { 348908989f96SLior David u8 mac_addr[WMI_MAC_LEN]; 349008989f96SLior David /* channels IDs: 349108989f96SLior David * 0 - 58320 MHz 349208989f96SLior David * 1 - 60480 MHz 349308989f96SLior David * 2 - 62640 MHz 349408989f96SLior David */ 349508989f96SLior David u8 channel; 349608989f96SLior David /* enum wmi_aoa_meas_type */ 349708989f96SLior David u8 aoa_meas_type; 349808989f96SLior David /* Measurments are from RFs, defined by the mask */ 349908989f96SLior David __le32 meas_rf_mask; 350008989f96SLior David /* enum wmi_aoa_meas_status */ 350108989f96SLior David u8 meas_status; 350208989f96SLior David u8 reserved; 350308989f96SLior David /* Length of meas_data in bytes */ 350408989f96SLior David __le16 length; 350508989f96SLior David u8 meas_data[WMI_AOA_MAX_DATA_SIZE]; 350608989f96SLior David } __packed; 350708989f96SLior David 3508cbf795c1SLior David /* WMI_SET_MGMT_RETRY_LIMIT_EVENTID */ 3509cbf795c1SLior David struct wmi_set_mgmt_retry_limit_event { 3510cbf795c1SLior David /* enum wmi_fw_status */ 3511cbf795c1SLior David u8 status; 3512cbf795c1SLior David /* alignment to 32b */ 3513cbf795c1SLior David u8 reserved[3]; 3514cbf795c1SLior David } __packed; 3515cbf795c1SLior David 3516cbf795c1SLior David /* WMI_GET_MGMT_RETRY_LIMIT_EVENTID */ 3517cbf795c1SLior David struct wmi_get_mgmt_retry_limit_event { 3518cbf795c1SLior David /* MAC retransmit limit for mgmt frames */ 3519cbf795c1SLior David u8 mgmt_retry_limit; 3520cbf795c1SLior David /* alignment to 32b */ 3521cbf795c1SLior David u8 reserved[3]; 3522cbf795c1SLior David } __packed; 3523cbf795c1SLior David 352408989f96SLior David /* WMI_TOF_GET_CAPABILITIES_EVENTID */ 352508989f96SLior David struct wmi_tof_get_capabilities_event { 352608989f96SLior David u8 ftm_capability; 352708989f96SLior David /* maximum supported number of destination to start TOF */ 352808989f96SLior David u8 max_num_of_dest; 352908989f96SLior David /* maximum supported number of measurements per burst */ 353008989f96SLior David u8 max_num_of_meas_per_burst; 353108989f96SLior David u8 reserved; 353208989f96SLior David /* maximum supported multi bursts */ 353308989f96SLior David __le16 max_multi_bursts_sessions; 353408989f96SLior David /* maximum supported FTM burst duration , wmi_tof_burst_duration_e */ 353508989f96SLior David __le16 max_ftm_burst_duration; 353608989f96SLior David /* AOA supported types */ 353708989f96SLior David __le32 aoa_supported_types; 353808989f96SLior David } __packed; 353908989f96SLior David 354090ffabb0SDedy Lansky /* WMI_SET_THERMAL_THROTTLING_CFG_EVENTID */ 354190ffabb0SDedy Lansky struct wmi_set_thermal_throttling_cfg_event { 354290ffabb0SDedy Lansky /* wmi_fw_status */ 354390ffabb0SDedy Lansky u8 status; 354490ffabb0SDedy Lansky u8 reserved[3]; 354590ffabb0SDedy Lansky } __packed; 354690ffabb0SDedy Lansky 354790ffabb0SDedy Lansky /* WMI_GET_THERMAL_THROTTLING_CFG_EVENTID */ 354890ffabb0SDedy Lansky struct wmi_get_thermal_throttling_cfg_event { 354990ffabb0SDedy Lansky /* Status data */ 355090ffabb0SDedy Lansky struct wmi_tt_data tt_data; 355190ffabb0SDedy Lansky } __packed; 355290ffabb0SDedy Lansky 355308989f96SLior David enum wmi_tof_session_end_status { 355408989f96SLior David WMI_TOF_SESSION_END_NO_ERROR = 0x00, 355508989f96SLior David WMI_TOF_SESSION_END_FAIL = 0x01, 355608989f96SLior David WMI_TOF_SESSION_END_PARAMS_ERROR = 0x02, 355708989f96SLior David WMI_TOF_SESSION_END_ABORTED = 0x03, 35588a4fa214SAhmad Masri WMI_TOF_SESSION_END_BUSY = 0x04, 355908989f96SLior David }; 356008989f96SLior David 356108989f96SLior David /* WMI_TOF_SESSION_END_EVENTID */ 356208989f96SLior David struct wmi_tof_session_end_event { 356308989f96SLior David /* FTM session ID */ 356408989f96SLior David __le32 session_id; 356508989f96SLior David /* wmi_tof_session_end_status_e */ 356608989f96SLior David u8 status; 356708989f96SLior David u8 reserved[3]; 356808989f96SLior David } __packed; 356908989f96SLior David 3570761f8e4dSLazar Alexei /* WMI_TOF_SET_LCI_EVENTID */ 3571761f8e4dSLazar Alexei struct wmi_tof_set_lci_event { 3572761f8e4dSLazar Alexei /* enum wmi_fw_status */ 3573761f8e4dSLazar Alexei u8 status; 3574761f8e4dSLazar Alexei u8 reserved[3]; 3575761f8e4dSLazar Alexei } __packed; 3576761f8e4dSLazar Alexei 3577761f8e4dSLazar Alexei /* WMI_TOF_SET_LCR_EVENTID */ 3578761f8e4dSLazar Alexei struct wmi_tof_set_lcr_event { 3579761f8e4dSLazar Alexei /* enum wmi_fw_status */ 3580761f8e4dSLazar Alexei u8 status; 3581761f8e4dSLazar Alexei u8 reserved[3]; 3582761f8e4dSLazar Alexei } __packed; 3583761f8e4dSLazar Alexei 358408989f96SLior David /* Responder FTM Results */ 358508989f96SLior David struct wmi_responder_ftm_res { 358608989f96SLior David u8 t1[6]; 358708989f96SLior David u8 t2[6]; 358808989f96SLior David u8 t3[6]; 358908989f96SLior David u8 t4[6]; 359008989f96SLior David __le16 tod_err; 359108989f96SLior David __le16 toa_err; 359208989f96SLior David __le16 tod_err_initiator; 359308989f96SLior David __le16 toa_err_initiator; 359408989f96SLior David } __packed; 359508989f96SLior David 359608989f96SLior David enum wmi_tof_ftm_per_dest_res_status { 359708989f96SLior David WMI_PER_DEST_RES_NO_ERROR = 0x00, 359808989f96SLior David WMI_PER_DEST_RES_TX_RX_FAIL = 0x01, 359908989f96SLior David WMI_PER_DEST_RES_PARAM_DONT_MATCH = 0x02, 360008989f96SLior David }; 360108989f96SLior David 360208989f96SLior David enum wmi_tof_ftm_per_dest_res_flags { 360308989f96SLior David WMI_PER_DEST_RES_REQ_START = 0x01, 360408989f96SLior David WMI_PER_DEST_RES_BURST_REPORT_END = 0x02, 360508989f96SLior David WMI_PER_DEST_RES_REQ_END = 0x04, 360608989f96SLior David WMI_PER_DEST_RES_PARAM_UPDATE = 0x08, 360708989f96SLior David }; 360808989f96SLior David 360908989f96SLior David /* WMI_TOF_FTM_PER_DEST_RES_EVENTID */ 361008989f96SLior David struct wmi_tof_ftm_per_dest_res_event { 361108989f96SLior David /* FTM session ID */ 361208989f96SLior David __le32 session_id; 361308989f96SLior David /* destination MAC address */ 361408989f96SLior David u8 dst_mac[WMI_MAC_LEN]; 361508989f96SLior David /* wmi_tof_ftm_per_dest_res_flags_e */ 361608989f96SLior David u8 flags; 361708989f96SLior David /* wmi_tof_ftm_per_dest_res_status_e */ 361808989f96SLior David u8 status; 361908989f96SLior David /* responder ASAP */ 362008989f96SLior David u8 responder_asap; 362108989f96SLior David /* responder number of FTM per burst */ 362208989f96SLior David u8 responder_num_ftm_per_burst; 362308989f96SLior David /* responder number of FTM burst exponent */ 362408989f96SLior David u8 responder_num_ftm_bursts_exp; 362508989f96SLior David /* responder burst duration ,wmi_tof_burst_duration_e */ 362608989f96SLior David u8 responder_burst_duration; 362708989f96SLior David /* responder burst period, indicate interval between two consecutive 362808989f96SLior David * burst instances, in units of 100 ms 362908989f96SLior David */ 363008989f96SLior David __le16 responder_burst_period; 363108989f96SLior David /* receive burst counter */ 363208989f96SLior David __le16 bursts_cnt; 363308989f96SLior David /* tsf of responder start burst */ 363408989f96SLior David __le32 tsf_sync; 363508989f96SLior David /* actual received ftm per burst */ 363608989f96SLior David u8 actual_ftm_per_burst; 3637761f8e4dSLazar Alexei /* Measurments are from RFs, defined by the mask */ 3638761f8e4dSLazar Alexei __le32 meas_rf_mask; 3639761f8e4dSLazar Alexei u8 reserved0[3]; 3640104f3d95SGustavo A. R. Silva struct wmi_responder_ftm_res responder_ftm_res[]; 364108989f96SLior David } __packed; 364208989f96SLior David 3643761f8e4dSLazar Alexei /* WMI_TOF_CFG_RESPONDER_EVENTID */ 3644761f8e4dSLazar Alexei struct wmi_tof_cfg_responder_event { 3645761f8e4dSLazar Alexei /* enum wmi_fw_status */ 3646761f8e4dSLazar Alexei u8 status; 3647761f8e4dSLazar Alexei u8 reserved[3]; 3648761f8e4dSLazar Alexei } __packed; 3649761f8e4dSLazar Alexei 365008989f96SLior David enum wmi_tof_channel_info_type { 365108989f96SLior David WMI_TOF_CHANNEL_INFO_AOA = 0x00, 365208989f96SLior David WMI_TOF_CHANNEL_INFO_LCI = 0x01, 365308989f96SLior David WMI_TOF_CHANNEL_INFO_LCR = 0x02, 365408989f96SLior David WMI_TOF_CHANNEL_INFO_VENDOR_SPECIFIC = 0x03, 365508989f96SLior David WMI_TOF_CHANNEL_INFO_CIR = 0x04, 365608989f96SLior David WMI_TOF_CHANNEL_INFO_RSSI = 0x05, 365708989f96SLior David WMI_TOF_CHANNEL_INFO_SNR = 0x06, 365808989f96SLior David WMI_TOF_CHANNEL_INFO_DEBUG = 0x07, 365908989f96SLior David }; 366008989f96SLior David 366108989f96SLior David /* WMI_TOF_CHANNEL_INFO_EVENTID */ 366208989f96SLior David struct wmi_tof_channel_info_event { 366308989f96SLior David /* FTM session ID */ 366408989f96SLior David __le32 session_id; 366508989f96SLior David /* destination MAC address */ 366608989f96SLior David u8 dst_mac[WMI_MAC_LEN]; 366708989f96SLior David /* wmi_tof_channel_info_type_e */ 366808989f96SLior David u8 type; 366908989f96SLior David /* data report length */ 367008989f96SLior David u8 len; 367108989f96SLior David /* data report payload */ 3672104f3d95SGustavo A. R. Silva u8 report[]; 367308989f96SLior David } __packed; 367408989f96SLior David 36758ae5d62cSLior David /* WMI_TOF_SET_TX_RX_OFFSET_EVENTID */ 36768ae5d62cSLior David struct wmi_tof_set_tx_rx_offset_event { 36778ae5d62cSLior David /* enum wmi_fw_status */ 36788ae5d62cSLior David u8 status; 36798ae5d62cSLior David u8 reserved[3]; 36808ae5d62cSLior David } __packed; 36818ae5d62cSLior David 36828ae5d62cSLior David /* WMI_TOF_GET_TX_RX_OFFSET_EVENTID */ 36838ae5d62cSLior David struct wmi_tof_get_tx_rx_offset_event { 36848ae5d62cSLior David /* enum wmi_fw_status */ 36858ae5d62cSLior David u8 status; 3686761f8e4dSLazar Alexei /* RF index used to read the offsets */ 3687761f8e4dSLazar Alexei u8 rf_index; 3688761f8e4dSLazar Alexei u8 reserved1[2]; 36898ae5d62cSLior David /* TX delay offset */ 36908ae5d62cSLior David __le32 tx_offset; 36918ae5d62cSLior David /* RX delay offset */ 36928ae5d62cSLior David __le32 rx_offset; 3693761f8e4dSLazar Alexei /* Offset to strongest tap of CIR */ 3694761f8e4dSLazar Alexei __le32 precursor; 36958ae5d62cSLior David } __packed; 36968ae5d62cSLior David 3697cbf795c1SLior David /* Result status codes for WMI commands */ 3698cbf795c1SLior David enum wmi_rf_sector_status { 3699cbf795c1SLior David WMI_RF_SECTOR_STATUS_SUCCESS = 0x00, 3700cbf795c1SLior David WMI_RF_SECTOR_STATUS_BAD_PARAMETERS_ERROR = 0x01, 3701cbf795c1SLior David WMI_RF_SECTOR_STATUS_BUSY_ERROR = 0x02, 3702cbf795c1SLior David WMI_RF_SECTOR_STATUS_NOT_SUPPORTED_ERROR = 0x03, 3703cbf795c1SLior David }; 3704cbf795c1SLior David 3705cbf795c1SLior David /* Types of the RF sector (TX,RX) */ 3706cbf795c1SLior David enum wmi_rf_sector_type { 3707cbf795c1SLior David WMI_RF_SECTOR_TYPE_RX = 0x00, 3708cbf795c1SLior David WMI_RF_SECTOR_TYPE_TX = 0x01, 3709cbf795c1SLior David }; 3710cbf795c1SLior David 3711cbf795c1SLior David /* Content of RF Sector (six 32-bits registers) */ 3712cbf795c1SLior David struct wmi_rf_sector_info { 3713cbf795c1SLior David /* Phase values for RF Chains[15-0] (2bits per RF chain) */ 3714cbf795c1SLior David __le32 psh_hi; 3715cbf795c1SLior David /* Phase values for RF Chains[31-16] (2bits per RF chain) */ 3716cbf795c1SLior David __le32 psh_lo; 3717cbf795c1SLior David /* ETYPE Bit0 for all RF chains[31-0] - bit0 of Edge amplifier gain 3718cbf795c1SLior David * index 3719cbf795c1SLior David */ 3720cbf795c1SLior David __le32 etype0; 3721cbf795c1SLior David /* ETYPE Bit1 for all RF chains[31-0] - bit1 of Edge amplifier gain 3722cbf795c1SLior David * index 3723cbf795c1SLior David */ 3724cbf795c1SLior David __le32 etype1; 3725cbf795c1SLior David /* ETYPE Bit2 for all RF chains[31-0] - bit2 of Edge amplifier gain 3726cbf795c1SLior David * index 3727cbf795c1SLior David */ 3728cbf795c1SLior David __le32 etype2; 3729cbf795c1SLior David /* D-Type values (3bits each) for 8 Distribution amplifiers + X16 3730cbf795c1SLior David * switch bits 3731cbf795c1SLior David */ 3732cbf795c1SLior David __le32 dtype_swch_off; 3733cbf795c1SLior David } __packed; 3734cbf795c1SLior David 3735cbf795c1SLior David #define WMI_INVALID_RF_SECTOR_INDEX (0xFFFF) 3736cbf795c1SLior David #define WMI_MAX_RF_MODULES_NUM (8) 3737cbf795c1SLior David 3738cbf795c1SLior David /* WMI_GET_RF_SECTOR_PARAMS_CMD */ 3739cbf795c1SLior David struct wmi_get_rf_sector_params_cmd { 3740cbf795c1SLior David /* Sector number to be retrieved */ 3741cbf795c1SLior David __le16 sector_idx; 3742cbf795c1SLior David /* enum wmi_rf_sector_type - type of requested RF sector */ 3743cbf795c1SLior David u8 sector_type; 3744cbf795c1SLior David /* bitmask vector specifying destination RF modules */ 3745cbf795c1SLior David u8 rf_modules_vec; 3746cbf795c1SLior David } __packed; 3747cbf795c1SLior David 3748cbf795c1SLior David /* \WMI_GET_RF_SECTOR_PARAMS_DONE_EVENT */ 3749cbf795c1SLior David struct wmi_get_rf_sector_params_done_event { 3750cbf795c1SLior David /* result status of WMI_GET_RF_SECTOR_PARAMS_CMD (enum 3751cbf795c1SLior David * wmi_rf_sector_status) 3752cbf795c1SLior David */ 3753cbf795c1SLior David u8 status; 3754cbf795c1SLior David /* align next field to U64 boundary */ 3755cbf795c1SLior David u8 reserved[7]; 3756cbf795c1SLior David /* TSF timestamp when RF sectors where retrieved */ 3757cbf795c1SLior David __le64 tsf; 3758cbf795c1SLior David /* Content of RF sector retrieved from each RF module */ 3759cbf795c1SLior David struct wmi_rf_sector_info sectors_info[WMI_MAX_RF_MODULES_NUM]; 3760cbf795c1SLior David } __packed; 3761cbf795c1SLior David 3762cbf795c1SLior David /* WMI_SET_RF_SECTOR_PARAMS_CMD */ 3763cbf795c1SLior David struct wmi_set_rf_sector_params_cmd { 3764cbf795c1SLior David /* Sector number to be retrieved */ 3765cbf795c1SLior David __le16 sector_idx; 3766cbf795c1SLior David /* enum wmi_rf_sector_type - type of requested RF sector */ 3767cbf795c1SLior David u8 sector_type; 3768cbf795c1SLior David /* bitmask vector specifying destination RF modules */ 3769cbf795c1SLior David u8 rf_modules_vec; 3770cbf795c1SLior David /* Content of RF sector to be written to each RF module */ 3771cbf795c1SLior David struct wmi_rf_sector_info sectors_info[WMI_MAX_RF_MODULES_NUM]; 3772cbf795c1SLior David } __packed; 3773cbf795c1SLior David 3774cbf795c1SLior David /* \WMI_SET_RF_SECTOR_PARAMS_DONE_EVENT */ 3775cbf795c1SLior David struct wmi_set_rf_sector_params_done_event { 3776cbf795c1SLior David /* result status of WMI_SET_RF_SECTOR_PARAMS_CMD (enum 3777cbf795c1SLior David * wmi_rf_sector_status) 3778cbf795c1SLior David */ 3779cbf795c1SLior David u8 status; 3780cbf795c1SLior David } __packed; 3781cbf795c1SLior David 3782cbf795c1SLior David /* WMI_GET_SELECTED_RF_SECTOR_INDEX_CMD - Get RF sector index selected by 3783cbf795c1SLior David * TXSS/BRP for communication with specified CID 3784cbf795c1SLior David */ 3785cbf795c1SLior David struct wmi_get_selected_rf_sector_index_cmd { 3786cbf795c1SLior David /* Connection/Station ID in [0:7] range */ 3787cbf795c1SLior David u8 cid; 3788cbf795c1SLior David /* type of requested RF sector (enum wmi_rf_sector_type) */ 3789cbf795c1SLior David u8 sector_type; 3790cbf795c1SLior David /* align to U32 boundary */ 3791cbf795c1SLior David u8 reserved[2]; 3792cbf795c1SLior David } __packed; 3793cbf795c1SLior David 3794cbf795c1SLior David /* \WMI_GET_SELECTED_RF_SECTOR_INDEX_DONE_EVENT - Returns retrieved RF sector 3795cbf795c1SLior David * index selected by TXSS/BRP for communication with specified CID 3796cbf795c1SLior David */ 3797cbf795c1SLior David struct wmi_get_selected_rf_sector_index_done_event { 3798cbf795c1SLior David /* Retrieved sector index selected in TXSS (for TX sector request) or 3799cbf795c1SLior David * BRP (for RX sector request) 3800cbf795c1SLior David */ 3801cbf795c1SLior David __le16 sector_idx; 3802cbf795c1SLior David /* result status of WMI_GET_SELECTED_RF_SECTOR_INDEX_CMD (enum 3803cbf795c1SLior David * wmi_rf_sector_status) 3804cbf795c1SLior David */ 3805cbf795c1SLior David u8 status; 3806cbf795c1SLior David /* align next field to U64 boundary */ 3807cbf795c1SLior David u8 reserved[5]; 3808cbf795c1SLior David /* TSF timestamp when result was retrieved */ 3809cbf795c1SLior David __le64 tsf; 3810cbf795c1SLior David } __packed; 3811cbf795c1SLior David 3812cbf795c1SLior David /* WMI_SET_SELECTED_RF_SECTOR_INDEX_CMD - Force RF sector index for 3813cbf795c1SLior David * communication with specified CID. Assumes that TXSS/BRP is disabled by 3814cbf795c1SLior David * other command 3815cbf795c1SLior David */ 3816cbf795c1SLior David struct wmi_set_selected_rf_sector_index_cmd { 3817cbf795c1SLior David /* Connection/Station ID in [0:7] range */ 3818cbf795c1SLior David u8 cid; 3819cbf795c1SLior David /* type of requested RF sector (enum wmi_rf_sector_type) */ 3820cbf795c1SLior David u8 sector_type; 3821cbf795c1SLior David /* Forced sector index */ 3822cbf795c1SLior David __le16 sector_idx; 3823cbf795c1SLior David } __packed; 3824cbf795c1SLior David 3825cbf795c1SLior David /* \WMI_SET_SELECTED_RF_SECTOR_INDEX_DONE_EVENT - Success/Fail status for 3826cbf795c1SLior David * WMI_SET_SELECTED_RF_SECTOR_INDEX_CMD 3827cbf795c1SLior David */ 3828cbf795c1SLior David struct wmi_set_selected_rf_sector_index_done_event { 3829cbf795c1SLior David /* result status of WMI_SET_SELECTED_RF_SECTOR_INDEX_CMD (enum 3830cbf795c1SLior David * wmi_rf_sector_status) 3831cbf795c1SLior David */ 3832cbf795c1SLior David u8 status; 3833cbf795c1SLior David /* align to U32 boundary */ 3834cbf795c1SLior David u8 reserved[3]; 3835cbf795c1SLior David } __packed; 3836cbf795c1SLior David 3837cbf795c1SLior David /* WMI_SET_RF_SECTOR_ON_CMD - Activates specified sector for specified rf 3838cbf795c1SLior David * modules 3839cbf795c1SLior David */ 3840cbf795c1SLior David struct wmi_set_rf_sector_on_cmd { 3841cbf795c1SLior David /* Sector index to be activated */ 3842cbf795c1SLior David __le16 sector_idx; 3843cbf795c1SLior David /* type of requested RF sector (enum wmi_rf_sector_type) */ 3844cbf795c1SLior David u8 sector_type; 3845cbf795c1SLior David /* bitmask vector specifying destination RF modules */ 3846cbf795c1SLior David u8 rf_modules_vec; 3847cbf795c1SLior David } __packed; 3848cbf795c1SLior David 3849cbf795c1SLior David /* \WMI_SET_RF_SECTOR_ON_DONE_EVENT - Success/Fail status for 3850cbf795c1SLior David * WMI_SET_RF_SECTOR_ON_CMD 3851cbf795c1SLior David */ 3852cbf795c1SLior David struct wmi_set_rf_sector_on_done_event { 3853cbf795c1SLior David /* result status of WMI_SET_RF_SECTOR_ON_CMD (enum 3854cbf795c1SLior David * wmi_rf_sector_status) 3855cbf795c1SLior David */ 3856cbf795c1SLior David u8 status; 3857cbf795c1SLior David /* align to U32 boundary */ 3858cbf795c1SLior David u8 reserved[3]; 3859cbf795c1SLior David } __packed; 3860cbf795c1SLior David 38618ae5d62cSLior David enum wmi_sector_sweep_type { 38628ae5d62cSLior David WMI_SECTOR_SWEEP_TYPE_TXSS = 0x00, 38638ae5d62cSLior David WMI_SECTOR_SWEEP_TYPE_BCON = 0x01, 38648ae5d62cSLior David WMI_SECTOR_SWEEP_TYPE_TXSS_AND_BCON = 0x02, 38658ae5d62cSLior David WMI_SECTOR_SWEEP_TYPE_NUM = 0x03, 38668ae5d62cSLior David }; 38678ae5d62cSLior David 38688ae5d62cSLior David /* WMI_PRIO_TX_SECTORS_ORDER_CMDID 38698ae5d62cSLior David * 38708ae5d62cSLior David * Set the order of TX sectors in TXSS and/or Beacon(AP). 38718ae5d62cSLior David * 38728ae5d62cSLior David * Returned event: 38738ae5d62cSLior David * - WMI_PRIO_TX_SECTORS_ORDER_EVENTID 38748ae5d62cSLior David */ 38758ae5d62cSLior David struct wmi_prio_tx_sectors_order_cmd { 38768ae5d62cSLior David /* tx sectors order to be applied, 0xFF for end of array */ 38778ae5d62cSLior David u8 tx_sectors_priority_array[MAX_NUM_OF_SECTORS]; 38788ae5d62cSLior David /* enum wmi_sector_sweep_type, TXSS and/or Beacon */ 38798ae5d62cSLior David u8 sector_sweep_type; 38808ae5d62cSLior David /* needed only for TXSS configuration */ 38818ae5d62cSLior David u8 cid; 38828ae5d62cSLior David /* alignment to 32b */ 38838ae5d62cSLior David u8 reserved[2]; 38848ae5d62cSLior David } __packed; 38858ae5d62cSLior David 38868ae5d62cSLior David /* completion status codes */ 38878ae5d62cSLior David enum wmi_prio_tx_sectors_cmd_status { 38888ae5d62cSLior David WMI_PRIO_TX_SECT_CMD_STATUS_SUCCESS = 0x00, 38898ae5d62cSLior David WMI_PRIO_TX_SECT_CMD_STATUS_BAD_PARAM = 0x01, 38908ae5d62cSLior David /* other error */ 38918ae5d62cSLior David WMI_PRIO_TX_SECT_CMD_STATUS_ERROR = 0x02, 38928ae5d62cSLior David }; 38938ae5d62cSLior David 38948ae5d62cSLior David /* WMI_PRIO_TX_SECTORS_ORDER_EVENTID */ 38958ae5d62cSLior David struct wmi_prio_tx_sectors_order_event { 38968ae5d62cSLior David /* enum wmi_prio_tx_sectors_cmd_status */ 38978ae5d62cSLior David u8 status; 38988ae5d62cSLior David /* alignment to 32b */ 38998ae5d62cSLior David u8 reserved[3]; 39008ae5d62cSLior David } __packed; 39018ae5d62cSLior David 39028ae5d62cSLior David struct wmi_prio_tx_sectors_num_cmd { 39038ae5d62cSLior David /* [0-128], 0 = No changes */ 39048ae5d62cSLior David u8 beacon_number_of_sectors; 39058ae5d62cSLior David /* [0-128], 0 = No changes */ 39068ae5d62cSLior David u8 txss_number_of_sectors; 39078ae5d62cSLior David /* [0-8] needed only for TXSS configuration */ 39088ae5d62cSLior David u8 cid; 39098ae5d62cSLior David } __packed; 39108ae5d62cSLior David 39118ae5d62cSLior David /* WMI_PRIO_TX_SECTORS_NUMBER_CMDID 39128ae5d62cSLior David * 39138ae5d62cSLior David * Set the number of active sectors in TXSS and/or Beacon. 39148ae5d62cSLior David * 39158ae5d62cSLior David * Returned event: 39168ae5d62cSLior David * - WMI_PRIO_TX_SECTORS_NUMBER_EVENTID 39178ae5d62cSLior David */ 39188ae5d62cSLior David struct wmi_prio_tx_sectors_number_cmd { 39198ae5d62cSLior David struct wmi_prio_tx_sectors_num_cmd active_sectors_num; 39208ae5d62cSLior David /* alignment to 32b */ 39218ae5d62cSLior David u8 reserved; 39228ae5d62cSLior David } __packed; 39238ae5d62cSLior David 39248ae5d62cSLior David /* WMI_PRIO_TX_SECTORS_NUMBER_EVENTID */ 39258ae5d62cSLior David struct wmi_prio_tx_sectors_number_event { 39268ae5d62cSLior David /* enum wmi_prio_tx_sectors_cmd_status */ 39278ae5d62cSLior David u8 status; 39288ae5d62cSLior David /* alignment to 32b */ 39298ae5d62cSLior David u8 reserved[3]; 39308ae5d62cSLior David } __packed; 39318ae5d62cSLior David 39328ae5d62cSLior David /* WMI_PRIO_TX_SECTORS_SET_DEFAULT_CFG_CMDID 39338ae5d62cSLior David * 39348ae5d62cSLior David * Set default sectors order and number (hard coded in board file) 39358ae5d62cSLior David * in TXSS and/or Beacon. 39368ae5d62cSLior David * 39378ae5d62cSLior David * Returned event: 39388ae5d62cSLior David * - WMI_PRIO_TX_SECTORS_SET_DEFAULT_CFG_EVENTID 39398ae5d62cSLior David */ 39408ae5d62cSLior David struct wmi_prio_tx_sectors_set_default_cfg_cmd { 39418ae5d62cSLior David /* enum wmi_sector_sweep_type, TXSS and/or Beacon */ 39428ae5d62cSLior David u8 sector_sweep_type; 39438ae5d62cSLior David /* needed only for TXSS configuration */ 39448ae5d62cSLior David u8 cid; 39458ae5d62cSLior David /* alignment to 32b */ 39468ae5d62cSLior David u8 reserved[2]; 39478ae5d62cSLior David } __packed; 39488ae5d62cSLior David 39498ae5d62cSLior David /* WMI_PRIO_TX_SECTORS_SET_DEFAULT_CFG_EVENTID */ 39508ae5d62cSLior David struct wmi_prio_tx_sectors_set_default_cfg_event { 39518ae5d62cSLior David /* enum wmi_prio_tx_sectors_cmd_status */ 39528ae5d62cSLior David u8 status; 39538ae5d62cSLior David /* alignment to 32b */ 39548ae5d62cSLior David u8 reserved[3]; 39558ae5d62cSLior David } __packed; 39568ae5d62cSLior David 3957761f8e4dSLazar Alexei /* WMI_SET_SILENT_RSSI_TABLE_DONE_EVENTID */ 3958761f8e4dSLazar Alexei struct wmi_set_silent_rssi_table_done_event { 3959761f8e4dSLazar Alexei /* enum wmi_silent_rssi_status */ 3960761f8e4dSLazar Alexei __le32 status; 3961761f8e4dSLazar Alexei /* enum wmi_silent_rssi_table */ 3962761f8e4dSLazar Alexei __le32 table; 3963761f8e4dSLazar Alexei } __packed; 3964761f8e4dSLazar Alexei 39658a4fa214SAhmad Masri /* WMI_VRING_SWITCH_TIMING_CONFIG_EVENTID */ 39668a4fa214SAhmad Masri struct wmi_vring_switch_timing_config_event { 39678a4fa214SAhmad Masri /* enum wmi_fw_status */ 39688a4fa214SAhmad Masri u8 status; 39698a4fa214SAhmad Masri u8 reserved[3]; 39708a4fa214SAhmad Masri } __packed; 39718a4fa214SAhmad Masri 39728a4fa214SAhmad Masri /* WMI_GET_ASSOC_LIST_RES_EVENTID */ 39738a4fa214SAhmad Masri struct wmi_assoc_sta_info { 39748a4fa214SAhmad Masri u8 mac[WMI_MAC_LEN]; 39758a4fa214SAhmad Masri u8 omni_index_address; 39768a4fa214SAhmad Masri u8 reserved; 39778a4fa214SAhmad Masri } __packed; 39788a4fa214SAhmad Masri 39798a4fa214SAhmad Masri #define WMI_GET_ASSOC_LIST_SIZE (8) 39808a4fa214SAhmad Masri 39818a4fa214SAhmad Masri /* WMI_GET_ASSOC_LIST_RES_EVENTID 39828a4fa214SAhmad Masri * Returns up to MAX_ASSOC_STA_LIST_SIZE associated STAs 39838a4fa214SAhmad Masri */ 39848a4fa214SAhmad Masri struct wmi_get_assoc_list_res_event { 39858a4fa214SAhmad Masri struct wmi_assoc_sta_info assoc_sta_list[WMI_GET_ASSOC_LIST_SIZE]; 39868a4fa214SAhmad Masri /* STA count */ 39878a4fa214SAhmad Masri u8 count; 39888a4fa214SAhmad Masri u8 reserved[3]; 39898a4fa214SAhmad Masri } __packed; 39908a4fa214SAhmad Masri 3991b5aeff16SDedy Lansky /* WMI_BF_CONTROL_EVENTID - deprecated */ 39928a4fa214SAhmad Masri struct wmi_bf_control_event { 39938a4fa214SAhmad Masri /* wmi_fw_status */ 39948a4fa214SAhmad Masri u8 status; 39958a4fa214SAhmad Masri u8 reserved[3]; 39968a4fa214SAhmad Masri } __packed; 39978a4fa214SAhmad Masri 3998b5aeff16SDedy Lansky /* WMI_BF_CONTROL_EX_EVENTID */ 3999b5aeff16SDedy Lansky struct wmi_bf_control_ex_event { 4000b5aeff16SDedy Lansky /* wmi_fw_status */ 4001b5aeff16SDedy Lansky u8 status; 4002b5aeff16SDedy Lansky u8 reserved[3]; 4003b5aeff16SDedy Lansky } __packed; 4004b5aeff16SDedy Lansky 40058a4fa214SAhmad Masri /* WMI_COMMAND_NOT_SUPPORTED_EVENTID */ 4006761f8e4dSLazar Alexei struct wmi_command_not_supported_event { 4007761f8e4dSLazar Alexei /* device id */ 4008761f8e4dSLazar Alexei u8 mid; 4009761f8e4dSLazar Alexei u8 reserved0; 4010761f8e4dSLazar Alexei __le16 command_id; 4011761f8e4dSLazar Alexei /* for UT command only, otherwise reserved */ 4012761f8e4dSLazar Alexei __le16 command_subtype; 4013761f8e4dSLazar Alexei __le16 reserved1; 4014761f8e4dSLazar Alexei } __packed; 4015761f8e4dSLazar Alexei 40168a4fa214SAhmad Masri /* WMI_TSF_SYNC_CMDID */ 40178a4fa214SAhmad Masri struct wmi_tsf_sync_cmd { 40188a4fa214SAhmad Masri /* The time interval to send announce frame in one BI */ 40198a4fa214SAhmad Masri u8 interval_ms; 40208a4fa214SAhmad Masri /* The mcs to send announce frame */ 40218a4fa214SAhmad Masri u8 mcs; 40228a4fa214SAhmad Masri u8 reserved[6]; 40238a4fa214SAhmad Masri } __packed; 40248a4fa214SAhmad Masri 40258a4fa214SAhmad Masri /* WMI_TSF_SYNC_STATUS_EVENTID */ 40268a4fa214SAhmad Masri enum wmi_tsf_sync_status { 40278a4fa214SAhmad Masri WMI_TSF_SYNC_SUCCESS = 0x00, 40288a4fa214SAhmad Masri WMI_TSF_SYNC_FAILED = 0x01, 40298a4fa214SAhmad Masri WMI_TSF_SYNC_REJECTED = 0x02, 40308a4fa214SAhmad Masri }; 40318a4fa214SAhmad Masri 40328a4fa214SAhmad Masri /* WMI_TSF_SYNC_STATUS_EVENTID */ 40338a4fa214SAhmad Masri struct wmi_tsf_sync_status_event { 40348a4fa214SAhmad Masri /* enum wmi_tsf_sync_status */ 40358a4fa214SAhmad Masri u8 status; 40368a4fa214SAhmad Masri u8 reserved[3]; 40378a4fa214SAhmad Masri } __packed; 40388a4fa214SAhmad Masri 40398a4fa214SAhmad Masri /* WMI_GET_CCA_INDICATIONS_EVENTID */ 40408a4fa214SAhmad Masri struct wmi_get_cca_indications_event { 40418a4fa214SAhmad Masri /* wmi_fw_status */ 40428a4fa214SAhmad Masri u8 status; 40438a4fa214SAhmad Masri /* CCA-Energy Detect in percentage over last BI (0..100) */ 40448a4fa214SAhmad Masri u8 cca_ed_percent; 40458a4fa214SAhmad Masri /* Averaged CCA-Energy Detect in percent over number of BIs (0..100) */ 40468a4fa214SAhmad Masri u8 cca_ed_avg_percent; 40478a4fa214SAhmad Masri /* NAV percent over last BI (0..100) */ 40488a4fa214SAhmad Masri u8 nav_percent; 40498a4fa214SAhmad Masri /* Averaged NAV percent over number of BIs (0..100) */ 40508a4fa214SAhmad Masri u8 nav_avg_percent; 40518a4fa214SAhmad Masri u8 reserved[3]; 40528a4fa214SAhmad Masri } __packed; 40538a4fa214SAhmad Masri 40548a4fa214SAhmad Masri /* WMI_SET_CCA_INDICATIONS_BI_AVG_NUM_CMDID */ 40558a4fa214SAhmad Masri struct wmi_set_cca_indications_bi_avg_num_cmd { 40568a4fa214SAhmad Masri /* set the number of bis to average cca_ed (0..255) */ 40578a4fa214SAhmad Masri u8 bi_number; 40588a4fa214SAhmad Masri u8 reserved[3]; 40598a4fa214SAhmad Masri } __packed; 40608a4fa214SAhmad Masri 40618a4fa214SAhmad Masri /* WMI_SET_CCA_INDICATIONS_BI_AVG_NUM_EVENTID */ 40628a4fa214SAhmad Masri struct wmi_set_cca_indications_bi_avg_num_event { 40638a4fa214SAhmad Masri /* wmi_fw_status */ 40648a4fa214SAhmad Masri u8 status; 40658a4fa214SAhmad Masri u8 reserved[3]; 40668a4fa214SAhmad Masri } __packed; 40678a4fa214SAhmad Masri 40688a4fa214SAhmad Masri /* WMI_INTERNAL_FW_SET_CHANNEL */ 40698a4fa214SAhmad Masri struct wmi_internal_fw_set_channel_event { 40708a4fa214SAhmad Masri u8 channel_num; 40718a4fa214SAhmad Masri u8 reserved[3]; 40728a4fa214SAhmad Masri } __packed; 40738a4fa214SAhmad Masri 4074b5aeff16SDedy Lansky /* WMI_LINK_STATS_CONFIG_DONE_EVENTID */ 4075b5aeff16SDedy Lansky struct wmi_link_stats_config_done_event { 4076b5aeff16SDedy Lansky /* wmi_fw_status_e */ 4077b5aeff16SDedy Lansky u8 status; 4078b5aeff16SDedy Lansky u8 reserved[3]; 4079b5aeff16SDedy Lansky } __packed; 4080b5aeff16SDedy Lansky 4081b5aeff16SDedy Lansky /* WMI_LINK_STATS_EVENTID */ 4082b5aeff16SDedy Lansky struct wmi_link_stats_event { 40830c936b3cSDedy Lansky __le64 tsf; 4084b5aeff16SDedy Lansky __le16 payload_size; 4085b5aeff16SDedy Lansky u8 has_next; 4086b5aeff16SDedy Lansky u8 reserved[5]; 40870c936b3cSDedy Lansky /* a stream of wmi_link_stats_record_s */ 4088104f3d95SGustavo A. R. Silva u8 payload[]; 4089b5aeff16SDedy Lansky } __packed; 4090b5aeff16SDedy Lansky 40910c936b3cSDedy Lansky /* WMI_LINK_STATS_EVENT */ 40920c936b3cSDedy Lansky struct wmi_link_stats_record { 40930c936b3cSDedy Lansky /* wmi_link_stats_record_type_e */ 4094b5aeff16SDedy Lansky u8 record_type_id; 40950c936b3cSDedy Lansky u8 reserved; 40960c936b3cSDedy Lansky __le16 record_size; 4097104f3d95SGustavo A. R. Silva u8 record[]; 40980c936b3cSDedy Lansky } __packed; 40990c936b3cSDedy Lansky 41000c936b3cSDedy Lansky /* WMI_LINK_STATS_TYPE_BASIC */ 41010c936b3cSDedy Lansky struct wmi_link_stats_basic { 4102b5aeff16SDedy Lansky u8 cid; 4103b5aeff16SDedy Lansky s8 rssi; 4104b5aeff16SDedy Lansky u8 sqi; 41050c936b3cSDedy Lansky u8 bf_mcs; 41060c936b3cSDedy Lansky u8 per_average; 4107b5aeff16SDedy Lansky u8 selected_rfc; 41080c936b3cSDedy Lansky u8 rx_effective_ant_num; 41090c936b3cSDedy Lansky u8 my_rx_sector; 41100c936b3cSDedy Lansky u8 my_tx_sector; 41110c936b3cSDedy Lansky u8 other_rx_sector; 41120c936b3cSDedy Lansky u8 other_tx_sector; 41130c936b3cSDedy Lansky u8 reserved[7]; 41140c936b3cSDedy Lansky /* 1/4 Db units */ 41150c936b3cSDedy Lansky __le16 snr; 4116b5aeff16SDedy Lansky __le32 tx_tpt; 4117b5aeff16SDedy Lansky __le32 tx_goodput; 4118b5aeff16SDedy Lansky __le32 rx_goodput; 41190c936b3cSDedy Lansky __le32 bf_count; 41200c936b3cSDedy Lansky __le32 rx_bcast_frames; 41210c936b3cSDedy Lansky } __packed; 41220c936b3cSDedy Lansky 41230c936b3cSDedy Lansky /* WMI_LINK_STATS_TYPE_GLOBAL */ 41240c936b3cSDedy Lansky struct wmi_link_stats_global { 41250c936b3cSDedy Lansky /* all ack-able frames */ 41260c936b3cSDedy Lansky __le32 rx_frames; 41270c936b3cSDedy Lansky /* all ack-able frames */ 41280c936b3cSDedy Lansky __le32 tx_frames; 41290c936b3cSDedy Lansky __le32 rx_ba_frames; 41300c936b3cSDedy Lansky __le32 tx_ba_frames; 41310c936b3cSDedy Lansky __le32 tx_beacons; 41320c936b3cSDedy Lansky __le32 rx_mic_errors; 41330c936b3cSDedy Lansky __le32 rx_crc_errors; 41340c936b3cSDedy Lansky __le32 tx_fail_no_ack; 41350c936b3cSDedy Lansky u8 reserved[8]; 4136b5aeff16SDedy Lansky } __packed; 4137b5aeff16SDedy Lansky 4138b5aeff16SDedy Lansky /* WMI_SET_GRANT_MCS_EVENTID */ 4139b5aeff16SDedy Lansky struct wmi_set_grant_mcs_event { 4140b5aeff16SDedy Lansky /* wmi_fw_status */ 4141b5aeff16SDedy Lansky u8 status; 4142b5aeff16SDedy Lansky u8 reserved[3]; 4143b5aeff16SDedy Lansky } __packed; 4144b5aeff16SDedy Lansky 4145b5aeff16SDedy Lansky /* WMI_SET_AP_SLOT_SIZE_EVENTID */ 4146b5aeff16SDedy Lansky struct wmi_set_ap_slot_size_event { 4147b5aeff16SDedy Lansky /* wmi_fw_status */ 4148b5aeff16SDedy Lansky u8 status; 4149b5aeff16SDedy Lansky u8 reserved[3]; 4150b5aeff16SDedy Lansky } __packed; 4151b5aeff16SDedy Lansky 4152b5aeff16SDedy Lansky /* WMI_SET_VRING_PRIORITY_WEIGHT_EVENTID */ 4153b5aeff16SDedy Lansky struct wmi_set_vring_priority_weight_event { 4154b5aeff16SDedy Lansky /* wmi_fw_status */ 4155b5aeff16SDedy Lansky u8 status; 4156b5aeff16SDedy Lansky u8 reserved[3]; 4157b5aeff16SDedy Lansky } __packed; 4158b5aeff16SDedy Lansky 4159b5aeff16SDedy Lansky /* WMI_SET_VRING_PRIORITY_EVENTID */ 4160b5aeff16SDedy Lansky struct wmi_set_vring_priority_event { 4161b5aeff16SDedy Lansky /* wmi_fw_status */ 4162b5aeff16SDedy Lansky u8 status; 4163b5aeff16SDedy Lansky u8 reserved[3]; 4164b5aeff16SDedy Lansky } __packed; 4165b5aeff16SDedy Lansky 416673a7d1e3SAlexei Avshalom Lazar /* WMI_RADAR_PCI_CTRL_BLOCK struct */ 416773a7d1e3SAlexei Avshalom Lazar struct wmi_radar_pci_ctrl_block { 416873a7d1e3SAlexei Avshalom Lazar /* last fw tail address index */ 416973a7d1e3SAlexei Avshalom Lazar __le32 fw_tail_index; 417073a7d1e3SAlexei Avshalom Lazar /* last SW head address index known to FW */ 417173a7d1e3SAlexei Avshalom Lazar __le32 sw_head_index; 417273a7d1e3SAlexei Avshalom Lazar __le32 last_wr_pulse_tsf_low; 417373a7d1e3SAlexei Avshalom Lazar __le32 last_wr_pulse_count; 417473a7d1e3SAlexei Avshalom Lazar __le32 last_wr_in_bytes; 417573a7d1e3SAlexei Avshalom Lazar __le32 last_wr_pulse_id; 417673a7d1e3SAlexei Avshalom Lazar __le32 last_wr_burst_id; 417773a7d1e3SAlexei Avshalom Lazar /* When pre overflow detected, advance sw head in unit of pulses */ 417873a7d1e3SAlexei Avshalom Lazar __le32 sw_head_inc; 417973a7d1e3SAlexei Avshalom Lazar __le32 reserved[8]; 418073a7d1e3SAlexei Avshalom Lazar } __packed; 418173a7d1e3SAlexei Avshalom Lazar 418273a7d1e3SAlexei Avshalom Lazar /* WMI_RBUFCAP_CFG_CMD */ 418373a7d1e3SAlexei Avshalom Lazar struct wmi_rbufcap_cfg_cmd { 418473a7d1e3SAlexei Avshalom Lazar u8 enable; 418573a7d1e3SAlexei Avshalom Lazar u8 reserved; 418673a7d1e3SAlexei Avshalom Lazar /* RBUFCAP indicates rx space unavailable when number of rx 418773a7d1e3SAlexei Avshalom Lazar * descriptors drops below this threshold. Set 0 to use system 418873a7d1e3SAlexei Avshalom Lazar * default 418973a7d1e3SAlexei Avshalom Lazar */ 419073a7d1e3SAlexei Avshalom Lazar __le16 rx_desc_threshold; 419173a7d1e3SAlexei Avshalom Lazar } __packed; 419273a7d1e3SAlexei Avshalom Lazar 419373a7d1e3SAlexei Avshalom Lazar /* WMI_RBUFCAP_CFG_EVENTID */ 419473a7d1e3SAlexei Avshalom Lazar struct wmi_rbufcap_cfg_event { 419573a7d1e3SAlexei Avshalom Lazar /* enum wmi_fw_status */ 419673a7d1e3SAlexei Avshalom Lazar u8 status; 419773a7d1e3SAlexei Avshalom Lazar u8 reserved[3]; 419873a7d1e3SAlexei Avshalom Lazar } __packed; 419973a7d1e3SAlexei Avshalom Lazar 42009b586118STzahi Sabo /* WMI_TEMP_SENSE_ALL_DONE_EVENTID 42019b586118STzahi Sabo * Measure MAC and all radio temperatures 42029b586118STzahi Sabo */ 42039b586118STzahi Sabo struct wmi_temp_sense_all_done_event { 42049b586118STzahi Sabo /* enum wmi_fw_status */ 42059b586118STzahi Sabo u8 status; 42069b586118STzahi Sabo /* Bitmap of connected RFs */ 42079b586118STzahi Sabo u8 rf_bitmap; 42089b586118STzahi Sabo u8 reserved[2]; 42099b586118STzahi Sabo /* Temperature times 1000 (actual temperature will be achieved by 42109b586118STzahi Sabo * dividing the value by 1000). When temperature cannot be read from 42119b586118STzahi Sabo * device return WMI_INVALID_TEMPERATURE 42129b586118STzahi Sabo */ 42139b586118STzahi Sabo __le32 rf_t1000[WMI_MAX_XIF_PORTS_NUM]; 42149b586118STzahi Sabo /* Temperature times 1000 (actual temperature will be achieved by 42159b586118STzahi Sabo * dividing the value by 1000). When temperature cannot be read from 42169b586118STzahi Sabo * device return WMI_INVALID_TEMPERATURE 42179b586118STzahi Sabo */ 42189b586118STzahi Sabo __le32 baseband_t1000; 42199b586118STzahi Sabo } __packed; 42209b586118STzahi Sabo 42212be7d22fSVladimir Kondratiev #endif /* __WILOCITY_WMI_H__ */ 4222