diff --git a/drivers/staging/fw-api/fw/htt_ppdu_stats.h b/drivers/staging/fw-api/fw/htt_ppdu_stats.h index fed6e2d63975..8425b487ccb0 100644 --- a/drivers/staging/fw-api/fw/htt_ppdu_stats.h +++ b/drivers/staging/fw-api/fw/htt_ppdu_stats.h @@ -1192,8 +1192,6 @@ typedef struct { */ A_UINT32 sw_rts_prot_dur_us; - /* Data fields related to Transmit power */ - /* tx_pwr_multiplier: * Hawkeye now supports power accuracy in 0.25 dBm steps, * so all powers are x4. @@ -1216,7 +1214,8 @@ typedef struct { A_UINT32 tx_pwr_multiplier : 8, chain_enable_bits : 8, is_smart_ulofdma_basic_trig: 1, - reserved2 : 15; + is_primary_link_peer : 1, + reserved2 : 14; /* * Transmit powers (signed values packed into unsigned bitfields) diff --git a/drivers/staging/fw-api/fw/htt_stats.h b/drivers/staging/fw-api/fw/htt_stats.h index f2fc4f5a75cc..821753e011d2 100644 --- a/drivers/staging/fw-api/fw/htt_stats.h +++ b/drivers/staging/fw-api/fw/htt_stats.h @@ -4486,6 +4486,8 @@ typedef struct { * multicast/broadcast packets received on STA side. */ A_UINT32 mec_notify; + A_UINT32 arp_response; + A_UINT32 arp_request; } htt_stats_tx_de_classify_stats_tlv; /* preserve old name alias for new name consistent with the tag name */ typedef htt_stats_tx_de_classify_stats_tlv htt_tx_de_classify_stats_tlv; diff --git a/drivers/staging/fw-api/fw/wmi_services.h b/drivers/staging/fw-api/fw/wmi_services.h index b0e825a49107..1890f9182450 100644 --- a/drivers/staging/fw-api/fw/wmi_services.h +++ b/drivers/staging/fw-api/fw/wmi_services.h @@ -648,6 +648,11 @@ typedef enum { WMI_SERVICE_SW_PROG_DFS_SUPPORT = 395, /* Indicate FW support SW progressive DFS */ WMI_SERVICE_MULTIPLE_REORDER_QUEUE_SETUP_SUPPORT = 396, /* Indicate FW supports multiple TID reorder queues setup in one cmd */ WMI_SERVICE_MULTIPLE_COEX_CONFIG_SUPPORT = 397, /* FW supports mutiple coex configs in one cmd */ + WMI_SERVICE_PCIE_DATA_RATE_LED_BLINK_SUPPORT = 398, /* FW supports Data Rate based LED blinking for PCI chips */ + WMI_SERVICE_VDEV_DCS_STATS_SUPPORT = 399, /* FW supports VDEV level DCS stats reporting */ + WMI_SERVICE_WIFI_RADAR_SUPPORT = 400, /* FW supports wifi radar */ + WMI_SERVICE_P2P_DEVICE_UPDATE_MAC_ADDR_SUPPORT = 401, /* indicate FW support dynamic update mac address for P2P device */ + WMI_MAX_EXT2_SERVICE diff --git a/drivers/staging/fw-api/fw/wmi_tlv_defs.h b/drivers/staging/fw-api/fw/wmi_tlv_defs.h index ce93e5939ecf..ba7225dd062d 100644 --- a/drivers/staging/fw-api/fw/wmi_tlv_defs.h +++ b/drivers/staging/fw-api/fw/wmi_tlv_defs.h @@ -1421,6 +1421,10 @@ typedef enum { WMITLV_TAG_STRUC_wmi_disallowed_mlo_mode_bitmap_param, WMITLV_TAG_STRUC_wmi_led_blink_rate_table, WMITLV_TAG_STRUC_wmi_enable_led_blink_download_rate_table_fixed_param, + WMITLV_TAG_STRUC_wmi_vdev_get_twt_session_stats_info_cmd_fixed_param, + WMITLV_TAG_STRUC_wmi_pdev_enable_wifi_radar_cmd_fixed_param, + WMITLV_TAG_STRUC_wmi_dma_buf_release_wifi_radar_meta_data, + WMITLV_TAG_STRUC_wmi_mlo_link_info, } WMITLV_TAG_ID; /* * IMPORTANT: Please add _ALL_ WMI Commands Here. @@ -1963,6 +1967,8 @@ typedef enum { OP(WMI_PEER_MULTIPLE_REORDER_QUEUE_SETUP_CMDID) \ OP(WMI_COEX_MULTIPLE_CONFIG_CMDID) \ OP(WMI_PDEV_ENABLE_LED_BLINK_DOWNLOAD_TABLE_CMDID) \ + OP(WMI_VDEV_GET_TWT_SESSION_STATS_INFO_CMDID) \ + OP(WMI_PDEV_ENABLE_WIFI_RADAR_CMDID) \ /* add new CMD_LIST elements above this line */ @@ -3627,6 +3633,11 @@ WMITLV_CREATE_PARAM_STRUC(WMI_VDEV_SET_WMM_PARAMS_CMDID); WMITLV_CREATE_PARAM_STRUC(WMI_VDEV_SET_TWT_EDCA_PARAMS_CMDID); +#define WMITLV_TABLE_WMI_VDEV_GET_TWT_SESSION_STATS_INFO_CMDID(id,op,buf,len) \ + WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_vdev_get_twt_session_stats_info_cmd_fixed_param, wmi_vdev_get_twt_session_stats_info_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX) + +WMITLV_CREATE_PARAM_STRUC(WMI_VDEV_GET_TWT_SESSION_STATS_INFO_CMDID); + #define WMITLV_TABLE_WMI_VDEV_SET_GTX_PARAMS_CMDID(id,op,buf,len) \ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_vdev_set_gtx_params_cmd_fixed_param, wmi_vdev_set_gtx_params_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX) @@ -4826,7 +4837,8 @@ WMITLV_CREATE_PARAM_STRUC(WMI_WLM_CONFIG_CMDID); WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_roam_trigger_kickout, roam_trigger_kickout, WMITLV_SIZE_VAR) \ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_roam_trigger_per, roam_trigger_per, WMITLV_SIZE_VAR) \ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_roam_trigger_periodic, roam_trigger_periodic, WMITLV_SIZE_VAR) \ - WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_roam_trigger_hi_rssi, roam_trigger_hi_rssi, WMITLV_SIZE_VAR) + WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_roam_trigger_hi_rssi, roam_trigger_hi_rssi, WMITLV_SIZE_VAR) \ + WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_mlo_link_info, mlo_link_info, WMITLV_SIZE_VAR) WMITLV_CREATE_PARAM_STRUC(WMI_ROAM_STATS_EVENTID); /* Motion detection cmd */ @@ -5550,6 +5562,11 @@ WMITLV_CREATE_PARAM_STRUC(WMI_VDEV_OOB_CONNECTION_REQ_CMDID); WMITLV_ELEM(id, op, buf, len, WMITLV_TAG_ARRAY_STRUC, WMI_COEX_CONFIG_CMD_fixed_param, config_list, WMITLV_SIZE_VAR) WMITLV_CREATE_PARAM_STRUC(WMI_COEX_MULTIPLE_CONFIG_CMDID); +/* Wifi radar enable command */ +#define WMITLV_TABLE_WMI_PDEV_ENABLE_WIFI_RADAR_CMDID(id,op,buf,len) \ + WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_STRUC_wmi_pdev_enable_wifi_radar_cmd_fixed_param, wmi_pdev_enable_wifi_radar_cmd_fixed_param, fixed_param, WMITLV_SIZE_FIX) +WMITLV_CREATE_PARAM_STRUC(WMI_PDEV_ENABLE_WIFI_RADAR_CMDID); + /************************** TLV definitions of WMI events *******************************/ @@ -7097,7 +7114,8 @@ WMITLV_CREATE_PARAM_STRUC(WMI_PDEV_DMA_RING_CFG_RSP_EVENTID); WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_dma_buf_release_entry, entries, WMITLV_SIZE_VAR) \ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_dma_buf_release_spectral_meta_data, meta_data, WMITLV_SIZE_VAR) \ WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_dma_buf_release_cv_upload_meta_data, cv_meta_data, WMITLV_SIZE_VAR) \ - WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_dma_buf_release_cqi_upload_meta_data, cqi_meta_data, WMITLV_SIZE_VAR) + WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_dma_buf_release_cqi_upload_meta_data, cqi_meta_data, WMITLV_SIZE_VAR) \ + WMITLV_ELEM(id,op,buf,len, WMITLV_TAG_ARRAY_STRUC, wmi_dma_buf_release_wifi_radar_meta_data, wifi_radar_meta_data, WMITLV_SIZE_VAR) WMITLV_CREATE_PARAM_STRUC(WMI_PDEV_DMA_RING_BUF_RELEASE_EVENTID); /* ctl failsafe check event */ diff --git a/drivers/staging/fw-api/fw/wmi_unified.h b/drivers/staging/fw-api/fw/wmi_unified.h index 564205c70262..ac9342cd35e7 100644 --- a/drivers/staging/fw-api/fw/wmi_unified.h +++ b/drivers/staging/fw-api/fw/wmi_unified.h @@ -521,6 +521,8 @@ typedef enum { * and download LED ON/OFF Rate table */ WMI_PDEV_ENABLE_LED_BLINK_DOWNLOAD_TABLE_CMDID, + /** WMI Command to enable wifi radar */ + WMI_PDEV_ENABLE_WIFI_RADAR_CMDID, /* VDEV (virtual device) specific commands */ @@ -1514,6 +1516,7 @@ typedef enum { WMI_TWT_BTWT_REMOVE_STA_CMDID, WMI_TWT_NUDGE_DIALOG_CMDID, WMI_VDEV_SET_TWT_EDCA_PARAMS_CMDID, /* XPAN TWT */ + WMI_VDEV_GET_TWT_SESSION_STATS_INFO_CMDID, /** WMI commands related to motion detection **/ WMI_MOTION_DET_CONFIG_PARAM_CMDID = WMI_CMD_GRP_START_ID(WMI_GRP_MOTION_DET), @@ -3590,10 +3593,15 @@ typedef struct { A_UINT32 rx_aggr_ba_win_size_max; /* - * max link number per MLD FW supports. + * max link number per STA MLD FW supports. */ A_UINT32 num_max_mlo_link_per_ml_bss_supp; + /* + * max link number per SAP MLD FW supports. + */ + A_UINT32 num_max_mlo_link_per_ml_sap_supp; + /* Followed by next TLVs: * WMI_DMA_RING_CAPABILITIES dma_ring_caps[]; * wmi_spectral_bin_scaling_params wmi_bin_scaling_params[]; @@ -5450,6 +5458,68 @@ typedef enum { #define WMI_SET_STA_DUMP_SUPPORT(feature_bitmap, val) \ WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 112, 1, val) +/* Peer protocol features supported info (contd) */ +#define WMI_GET_STA_P2P_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 113, 1) +#define WMI_SET_STA_P2P_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 113, 1, val) +#define WMI_GET_STA_SAP_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 114, 1) +#define WMI_SET_STA_SAP_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 114, 1, val) +#define WMI_GET_STA_NAN_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 115, 1) +#define WMI_SET_STA_NAN_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 115, 1, val) +#define WMI_GET_STA_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 116, 1) +#define WMI_SET_STA_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 116, 1, val) +/* Reserving 16 bits for accomodating other 2 port concurrencies later */ + +#define WMI_GET_STA_SAP_P2P_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 133, 1) +#define WMI_SET_STA_SAP_P2P_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 133, 1, val) +#define WMI_GET_STA_SAP_NAN_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 134, 1) +#define WMI_SET_STA_SAP_NAN_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 134, 1, val) +#define WMI_GET_STA_P2P_NAN_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 135, 1) +#define WMI_SET_STA_P2P_NAN_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 135, 1, val) +#define WMI_GET_STA_P2P_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 136, 1) +#define WMI_SET_STA_P2P_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 136, 1, val) +#define WMI_GET_STA_SAP_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 137, 1) +#define WMI_SET_STA_SAP_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 137, 1, val) +#define WMI_GET_STA_NAN_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 138, 1) +#define WMI_SET_STA_NAN_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 138, 1, val) +/* Reserving 16 bits for accomodating other 3 port concurrencies later */ + +#define WMI_GET_STA_SAP_P2P_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 155, 1) +#define WMI_SET_STA_SAP_P2P_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 155, 1, val) +#define WMI_GET_STA_SAP_NAN_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 156, 1) +#define WMI_SET_STA_SAP_NAN_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 156, 1, val) +#define WMI_GET_STA_P2P_P2P_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 157, 1) +#define WMI_SET_STA_P2P_P2P_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 157, 1, val) +#define WMI_GET_STA_P2P_NAN_TDLS_SUPPORT(var, feature_bitmap) \ + WMI_GET_BITS_ARRAY_LEN32_BYTES(var, feature_bitmap, 158, 1) +#define WMI_SET_STA_P2P_NAN_TDLS_SUPPORT(feature_bitmap, val) \ + WMI_SET_BITS_ARRAY_LEN32_BYTES(feature_bitmap, 158, 1, val) + /* * Specify how many A_UINT32 words are needed to hold the feature bitmap flags. * This value may change over time. @@ -5457,7 +5527,7 @@ typedef enum { * It is provided simply as a convenience for the feature_set_bitmap sender to * know how many 32-bit words to allocate for the bitmap. */ -#define WMI_FEATURE_SET_BITMAP_ARRAY_LEN32 4 +#define WMI_FEATURE_SET_BITMAP_ARRAY_LEN32 6 /** * TLV for channel list @@ -9369,6 +9439,19 @@ typedef enum { * default to immediate LMR feedback. **/ WMI_PDEV_PARAM_ENABLE_DELAYED_LMR_FEEDBACK, + + /* DFS_RADAR_MASK: Radar mask setting programmed in HW registers. + * bit | config_mode + * ----------------------- + * 0 - 15 | Each bit represents a 20 MHz portion of the channel. + * | 0-Unmasked 1-Masked + * 16 - 31 | Reserved. + * Bit 0 represents the highest 20 MHz portion within the channel. + * For example... + * For a 80 MHz channel, bit0 = highest 20 MHz, bit3 = lowest 20 MHz + * For a 320 MHz channel, bit0 = highest 20 MHz, bit15 = lowest 20 MHz + */ + WMI_PDEV_PARAM_DFS_RADAR_MASK, } WMI_PDEV_PARAM; #define WMI_PDEV_ONLY_BSR_TRIG_IS_ENABLED(trig_type) WMI_GET_BITS(trig_type, 0, 1) @@ -10436,6 +10519,12 @@ typedef struct { */ } wmi_vdev_set_twt_edca_params_cmd_fixed_param; +typedef struct { + /** TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_vdev_get_twt_session_stats_info_cmd_fixed_param */ + A_UINT32 tlv_header; + A_UINT32 vdev_id; +} wmi_vdev_get_twt_session_stats_info_cmd_fixed_param; + typedef enum { WMI_REQUEST_PEER_STAT = 0x00001, WMI_REQUEST_AP_STAT = 0x00002, @@ -17002,6 +17091,9 @@ typedef struct { A_UINT32 mbssid_multi_group_flag; /* Flag to identify whether multi group mbssid is supported */ A_UINT32 mbssid_multi_group_id; /* Group id of current vdev only valid when multi group mbssid is supported */ + /* Target TSF value by which VDEV restart procedure should be completed in FW */ + A_UINT32 target_tsf_us_lo; /* bits 31:0 */ + A_UINT32 target_tsf_us_hi; /* bits 63:32 */ /* The TLVs follows this structure: * wmi_channel chan; <-- WMI channel @@ -18277,6 +18369,9 @@ typedef enum { */ WMI_VDEV_PARAM_MLO_MAX_RECOM_ACTIVE_LINKS, /* 0xC1 */ + /* DCS stats enable configuration at VDEV level */ + WMI_VDEV_PARAM_DCS, /* 0xC2 */ + /*=== ADD NEW VDEV PARAM TYPES ABOVE THIS LINE === * The below vdev param types are used for prototyping, and are @@ -21227,6 +21322,12 @@ typedef struct { * See macros starting with WMI_PDEV_ID_ for values. */ A_UINT32 pdev_id; + /** VDEV ID for identifying DCS stats reported at VDEV level. + * Should be interpreted only when WMI_SERVICE_VDEV_DCS_STATS_SUPPORT + * service cap is advertized by target. + * And value would be 0xFF if DCS stats is still configured at PDEV level. + */ + A_UINT32 vdev_id; /* * Following this struct are these TLVs. Note that they are both array of structures * but can have at most one element. Which TLV is empty or has one element depends @@ -28959,6 +29060,7 @@ typedef struct { A_UINT32 reassoc_rsp_len; /** the length of reassoc req */ A_UINT32 reassoc_req_len; + A_INT32 bcn_probe_resp_rssi; /* RSSI units dBm */ /** * TLV (tag length value) parameters follows roam_synch_event * The TLV's are: @@ -34124,9 +34226,37 @@ typedef struct { A_UINT32 freqNum; } wmi_pdev_nfcal_power_all_channels_freqNum; +/* Bit set/unset definitions for valid_bitmap field in ani_cck_event */ +#define WMI_ANI_CCK_EVENT_PDEV_ID_SET(bitmap, val) \ + WMI_SET_BITS(bitmap, 0, 8, val) +#define WMI_ANI_CCK_EVENT_PDEV_ID_GET(bitmap) \ + WMI_GET_BITS(bitmap, 0, 8) + +#define WMI_ANI_CCK_EVENT_PDEV_ID_VALID_BIT_SET(bitmap, val) \ + WMI_SET_BITS(bitmap, 31, 1, val) +#define WMI_ANI_CCK_EVENT_PDEV_ID_VALID_BIT_GET(bitmap) \ + WMI_GET_BITS(bitmap, 31, 1) + typedef struct { A_UINT32 tlv_header; /* TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_ani_cck_event_fixed_param */ A_UINT32 cck_level; + union { + A_UINT32 pdev_id_valid__pdev_id__word; + struct { + /** + * word containng the pdev_id for identifying the MAC + * Contents: + * bits 7:0 - pdev ID + * bits 30:8 - reserved + * bit 31 - pdev ID valid flag + * See macros starting with WMI_ANI_CCK_EVENT_PDEV_ID_ for values. + * pdev_id is valid when pdev_id_valid is set. + */ + A_UINT32 pdev_id: 8, + reserved: 23, + pdev_id_valid: 1; + }; + }; } wmi_ani_cck_event_fixed_param; typedef enum wmi_power_debug_reg_fmt_type { @@ -34489,9 +34619,37 @@ typedef struct { A_UINT32 protocol_wake_lock_bitmap[4]; /* bitmap with bits set for modules (from WLAN_MODULE_ID enum) voting against sleep for prolonged duration */ } wmi_chip_power_save_failure_detected_fixed_param; +/* Bit set/unset definitions for valid_bitmap field in ani_ofdm_event */ +#define WMI_ANI_OFDM_EVENT_PDEV_ID_BIT_SET(bitmap, val) \ + WMI_SET_BITS(bitmap, 0, 8, val) +#define WMI_ANI_OFDM_EVENT_PDEV_ID_BIT_GET(bitmap) \ + WMI_GET_BITS(bitmap, 0, 8) + +#define WMI_ANI_OFDM_EVENT_PDEV_ID_VALID_BIT_SET(bitmap, val) \ + WMI_SET_BITS(bitmap, 31, 1, val) +#define WMI_ANI_OFDM_EVENT_PDEV_ID_VALID_BIT_GET(bitmap) \ + WMI_GET_BITS(bitmap, 31, 1) + typedef struct { A_UINT32 tlv_header; /* TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_ani_ofdm_event_fixed_param */ A_UINT32 ofdm_level; + union { + A_UINT32 pdev_id_valid__pdev_id__word; + struct { + /** + * word containng the pdev_id for identifying the MAC + * Contents: + * bits 7:0 - pdev ID + * bits 30:8 - reserved + * bit 31 - pdev ID valid flag + * See macros starting with WMI_ANI_OFDM_EVENT_PDEV_ID_ for values. + * pdev_id is valid when pdev_id_valid is set. + */ + A_UINT32 pdev_id: 8, + reserved: 23, + pdev_id_valid: 1; + }; + }; } wmi_ani_ofdm_event_fixed_param; /* When a bit is set it specifies the particular WLAN traffic type is high priority. @@ -37111,6 +37269,7 @@ static INLINE A_UINT8 *wmi_id_to_name(A_UINT32 wmi_command) WMI_RETURN_STRING(WMI_PEER_MULTIPLE_REORDER_QUEUE_SETUP_CMDID); WMI_RETURN_STRING(WMI_COEX_MULTIPLE_CONFIG_CMDID); WMI_RETURN_STRING(WMI_PDEV_ENABLE_LED_BLINK_DOWNLOAD_TABLE_CMDID); + WMI_RETURN_STRING(WMI_PDEV_ENABLE_WIFI_RADAR_CMDID); } return (A_UINT8 *) "Invalid WMI cmd"; @@ -38325,6 +38484,11 @@ typedef struct { */ #define WLM_FLAGS_PS_DISABLE_MLO_PROBE_SCAN 1 /* disable MLO probe scan */ +/* bit 24: WLM_FLAGS_PS_DISABLE_ULL_FORCED_MLMR, + * disable forced MLMR on ULL if bit is set + */ +#define WLM_FLAGS_PS_DISABLE_ULL_FORCED_MLMR 1 /* disable forced MLMR on ULL */ + #define WLM_FLAGS_SCAN_IS_SUPPRESS(flag) WMI_GET_BITS(flag, 0, 1) #define WLM_FLAGS_SCAN_SET_SUPPRESS(flag, val) WMI_SET_BITS(flag, 0, 1, val) #define WLM_FLAGS_SCAN_IS_SKIP_DFS(flag) WMI_GET_BITS(flag, 1, 1) @@ -38360,6 +38524,8 @@ typedef struct { #define WLM_FLAGS_SCAN_SET_ADAPT_SCAN_ENABLE(flag, val) WMI_SET_BITS(flag, 22, 1, val) #define WLM_FLAGS_PS_IS_MLO_PROBE_SCAN_DISABLED(flag) WMI_GET_BITS(flag, 23, 1) #define WLM_FLAGS_PS_SET_MLO_PROBE_SCAN_DISABLE(flag, val) WMI_SET_BITS(flag, 23, 1, val) +#define WLM_FLAGS_PS_IS_ULL_FORCED_MLMR_DISABLED(flag) WMI_GET_BITS(flag, 24, 1) +#define WLM_FLAGS_PS_SET_ULL_FORCED_MLMR_DISABLE(flag, val) WMI_SET_BITS(flag, 24, 1, val) #define WLM_FLAGS_SET_FORCE_DEFAULT_LATENCY(flag, val) WMI_SET_BITS(flag, 0, 1, val) #define WLM_FLAGS_GET_FORCE_DEFAULT_LATENCY(flag) WMI_GET_BITS(flag, 0, 1) @@ -38989,6 +39155,7 @@ typedef enum { WMI_DMA_RING_CONFIG_MODULE_SPECTRAL, WMI_DMA_RING_CONFIG_MODULE_RTT, WMI_DMA_RING_CONFIG_MODULE_CV_UPLOAD, + WMI_DMA_RING_CONFIG_MODULE_WIFI_RADAR, } WMI_DMA_RING_SUPPORTED_MODULE; typedef struct { @@ -39150,6 +39317,8 @@ typedef struct { * wmi_dma_buf_release_cv_upload_meta_data cv_meta_data[num_meta_data_entry] * wmi_dma_buf_release_cqi_upload_meta_data * cqi_meta_data[num_meta_data_entry] + * wmi_dma_buf_release_wifi_radar_meta_data + * wifi_radar_meta_data[num_meta_data_entry] */ } wmi_dma_buf_release_fixed_param; @@ -39873,6 +40042,7 @@ typedef struct { * bit 1-31: reserved. */ A_UINT32 flags; + wmi_mac_addr mld_addr; } wmi_roam_ap_info; typedef enum { @@ -40061,6 +40231,9 @@ typedef struct { #define WMI_GET_TX_FAILED_REASON(frame_info_ext) WMI_GET_BITS(frame_info_ext, 22, 4) #define WMI_SET_TX_FAILED_REASON(frame_info_ext, val) WMI_SET_BITS(frame_info_ext, 22, 4, val) +#define WMI_GET_MAP_ID(frame_info_ext) WMI_GET_BITS(frame_info_ext, 26, 6) +#define WMI_SET_MAP_ID(frame_info_ext, val) WMI_SET_BITS(frame_info_ext, 26, 6, val) + typedef struct { A_UINT32 tlv_header; /* TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_roam_frame_info_tlv_param */ /* timestamp is the absolute time w.r.t host timer which is synchronized between the host and target */ @@ -40115,7 +40288,8 @@ typedef struct { * Refer to WMI_[GET,SET]_RX_INDICATE macros. * Bit 22-25 : opaque tx failure reason * Refer to WMI_[GET,SET]_TX_FAILED_REASON macros. - * Bit 26-31 : reserved for future use. + * Bit 26-31 : Indicate the map id, used to identify the all the + * ML link info corresponding to current roaming candidate. */ A_UINT32 frame_info_ext; } wmi_roam_frame_info; @@ -40320,6 +40494,33 @@ typedef struct { A_UINT32 hi_rssi_threshold; } wmi_roam_trigger_hi_rssi; +#define WMI_MLO_LINK_INFO_GET_MAP_ID(link_info) WMI_GET_BITS(link_info, 0, 6) +#define WMI_MLO_LINK_INFO_SET_MAP_ID(link_info, val) WMI_SET_BITS(link_info, 0, 6, val) + +#define WMI_MLO_LINK_INFO_GET_STATUS(link_info) WMI_GET_BITS(link_info, 6, 1) +#define WMI_MLO_LINK_INFO_SET_STATUS(link_info, val) WMI_SET_BITS(link_info, 6, 1, val) + +#define WMI_MLO_LINK_INFO_GET_BAND(link_info) WMI_GET_BITS(link_info, 7, 3) +#define WMI_MLO_LINK_INFO_SET_BAND(link_info, val) WMI_SET_BITS(link_info, 7, 3, val) + +#define WMI_MLO_LINK_INFO_GET_IEEE_LINK_ID(link_info) WMI_GET_BITS(link_info, 10, 4) +#define WMI_MLO_LINK_INFO_SET_IEEE_LINK_ID(link_info, val) WMI_SET_BITS(link_info, 10, 4, val) + +typedef struct { + A_UINT32 tlv_header; /* TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_mlo_link_info_tlv_param */ + wmi_mac_addr link_addr; + A_UINT32 link_info; + /* + * b[0-5] : Map Id - maps the corresponding candidate AP for which + * re-assoc resp received. + * b[6] : Status - link status, AP accepted/rejected this link + * 0 - accepted + * 1 - rejected + * b[7-9] : Band - link band info (band value is from wmi_mlo_band_info) + * b[10-13] : IEEE link id - Link id associated with AP + */ +} wmi_mlo_link_info; + typedef struct { A_UINT32 tlv_header; /* TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_roam_get_scan_channel_list_cmd_fixed_param */ A_UINT32 vdev_id; @@ -44539,12 +44740,16 @@ typedef struct { /* service period start TSF */ A_UINT32 sp_tsf_us_lo; /* bits 31:0 */ A_UINT32 sp_tsf_us_hi; /* bits 63:32 */ + /* Current TSF */ + A_UINT32 curr_tsf_us_lo; /* bits 31:0 */ + A_UINT32 curr_tsf_us_hi; /* bits 63:32 */ } wmi_twt_session_stats_info; enum wmi_twt_session_stats_type { WMI_TWT_SESSION_SETUP = 1, WMI_TWT_SESSION_TEARDOWN = 2, WMI_TWT_SESSION_UPDATE = 3, + WMI_TWT_SESSION_QUERY_RSP = 4, }; typedef struct { @@ -44848,6 +45053,7 @@ typedef struct wmi_mlo_set_active_link_number_param #define WMI_MLO_MODE_MLMR 0x1; #define WMI_MLO_MODE_EMLSR 0x2; +#define WMI_MLO_IEEE_LINK_ID_INVALID 0xFF #define WMI_MLO_IEEE_LINK_ID_COMB_GET_LINK_ID1(ieee_link_id_comb) WMI_GET_BITS(ieee_link_id_comb, 0, 8) #define WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID1(ieee_link_id_comb, value) WMI_SET_BITS(ieee_link_id_comb, 0, 8, value) @@ -44882,6 +45088,8 @@ typedef struct wmi_disallowed_mlo_mode_bitmap_param * Give combination of IEEE link IDs for which above disallowed_mode_bitmap * is applicable. * Each 8-bits in ieee_link_id_comb represents one link ID. + * A link ID is an integer value between 0 and 14. + * Please set WMI_MLO_IEEE_LINK_ID_INVALID (0xff) if 8-bits is not used. * Use WMI_MLO_IEEE_LINK_ID_COMB_GET_LINK_ID* and _SET_LINK_ID* to get/set * link IDs in this field. */ @@ -44889,30 +45097,30 @@ typedef struct wmi_disallowed_mlo_mode_bitmap_param /** Example: - * Say there are 3 MLO links with ieee link IDs as 1,2 and 32. + * Say there are 3 MLO links with ieee link IDs as 1,2 and 10. * Say host wants to disallow MLMR between links with IDs 1 and 2, - * disallow eMLSR between links with IDs 1 and 32, - * disallow MLMR and eMLSR for links with IDs 2 and 32. + * disallow eMLSR between links with IDs 1 and 10, + * disallow MLMR and eMLSR for links with IDs 2 and 10. * There will be 3 TLVs of type wmi_disallowed_mlo_mode_bitmap_param * like below. * * wmi_disallowed_mlo_mode_bitmap_param[0]: * disallowed_mode_bitmap = 0x1, - * ieee_link_id_comb = 0x00000201 - * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID1(ieee_link_id_comb, 0x1) - * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID2(ieee_link_id_comb, 0x2) + * ieee_link_id_comb = 0xFFFF0201 + * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID1(ieee_link_id_comb, 0x01) + * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID2(ieee_link_id_comb, 0x02) * * wmi_disallowed_mlo_mode_bitmap_param[1] * disallowed_mode_bitmap = 0x2, - * ieee_link_id_comb = 0x00002001 - * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID1(ieee_link_id_comb, 0x1) - * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID2(ieee_link_id_comb, 0x20) + * ieee_link_id_comb = 0xFFFF0A01 + * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID1(ieee_link_id_comb, 0x01) + * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID2(ieee_link_id_comb, 0x0a) * * wmi_disallowed_mlo_mode_bitmap_param[2] * disallowed_mode_bitmap = 0x3, - * ieee_link_id_comb = 0x00002002 - * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID1(ieee_link_id_comb, 0x2) - * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID2(ieee_link_id_comb, 0x20) + * ieee_link_id_comb = 0xFFFF0A02 + * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID1(ieee_link_id_comb, 0x02) + * WMI_MLO_IEEE_LINK_ID_COMB_SET_LINK_ID2(ieee_link_id_comb, 0x0a) */ } wmi_disallowed_mlo_mode_bitmap_param; @@ -45201,8 +45409,8 @@ typedef struct{ A_UINT32 pdev_id; /** vdev_id for identifying the MLO Vap */ A_UINT32 vdev_id; - /** disabled link bits */ - A_UINT32 disabled_link_bitmap; + /** DEPRECATED: disabled link bits */ + A_UINT32 disabled_link_bitmap; /* DEPRECATED */ /** * Following this structure is the TLV: * struct wmi_mlo_ap_vdev_tid_to_link_map_ie_info[]; @@ -45560,6 +45768,9 @@ typedef struct { * hw_tid_7_link_map:16 */ A_UINT32 hw_tid_6_7_link_map; + + /* Indicates the disabled link map for 802.11be T2LM */ + A_UINT32 disabled_link_bitmap; } wmi_mlo_ap_vdev_tid_to_link_map_ie_info; #define WMI_IGMP_OFFLOAD_SUPPORT_DISABLE_BITMASK 0x0 @@ -46721,6 +46932,30 @@ typedef struct { A_UINT32 fb_params; } wmi_dma_buf_release_cv_upload_meta_data; +typedef struct { + A_UINT32 tlv_header; /** TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_dma_buf_release_radar_meta_data */ + /* timestamp at the time of the capture */ + A_UINT32 timestamp_us; + /* phy mode WLAN_PHY_MODE of the channel defined in wlan_defs.h */ + A_UINT32 phy_mode; + /* frequency (in MHz) of the primary 20 MHz channel */ + A_UINT32 chan_mhz; + /* Center frequency 1 in MHz */ + A_UINT32 band_center_freq1; + /* Center frequency 2 in MHz - valid only for 11acvht 80plus80 mode */ + A_UINT32 band_center_freq2; + /* tx chain mask */ + A_UINT32 tx_chain_mask; + /* rx chain mask */ + A_UINT32 rx_chain_mask; + /* number of LTFs sent for capture */ + A_UINT32 num_ltf_tx; + /* number of LTFs skipped in rx */ + A_UINT32 num_skip_ltf_rx; + /* number of LTFs used for accumulation */ + A_UINT32 num_ltf_accumulation; +} wmi_dma_buf_release_wifi_radar_meta_data; + typedef struct { /** TLV tag and len; tag equals WMITLV_TAG_STRUC_wmi_dma_buf_release_cqi_upload_meta_data */ A_UINT32 tlv_header; @@ -47371,6 +47606,40 @@ typedef struct { A_UINT32 switch_type; /* see definition of WMI_AUDIO_TRANSPORT_SWITCH_TYPE */ } wmi_audio_transport_switch_resp_status_cmd_fixed_param; +typedef struct { + /** TLV tag and len; tag equals + * WMITLV_TAG_STRUC_wmi_pdev_enable_wifi_radar_cmd_fixed_param + */ + A_UINT32 tlv_header; + /* host pdev id */ + A_UINT32 pdev_id; + /* tx_chain_mask: + * tx chain mask to use for wifi radar tx. + * Only one chain is supposed to be set. + */ + A_UINT32 tx_chain_mask; + /* rx chain mask for wifi radar capture. Can have multiple bits set. */ + A_UINT32 rx_chain_mask; + /* number of LTFs to send for capture */ + A_UINT32 num_ltf_tx; + /* number of extra LTFs that are to be skipped for accumulation */ + A_UINT32 num_skip_ltf_rx; + /* number of LTFs to use for accumulation. Must be power of 2. */ + A_UINT32 num_ltf_accumulation; + /* bandwidth to use for capture + * 0 = 20 MHz + * 1 = 40 MHz + * 2 = 80 MHz + * 3 = 160 MHz + * 4 = 320 MHz + */ + A_UINT32 bw; + /* 0 to stop capture, 1 to start periodic capture, 2 to do calibration */ + A_UINT32 capture_calibrate; + /* periodicity of capture in milliseconds */ + A_UINT32 capture_interval_ms; +} wmi_pdev_enable_wifi_radar_cmd_fixed_param; + /* ADD NEW DEFS HERE */ diff --git a/drivers/staging/fw-api/fw/wmi_version.h b/drivers/staging/fw-api/fw/wmi_version.h index e5411d6562fc..3ba4c9227c65 100644 --- a/drivers/staging/fw-api/fw/wmi_version.h +++ b/drivers/staging/fw-api/fw/wmi_version.h @@ -37,7 +37,7 @@ #define __WMI_VER_MINOR_ 0 /** WMI revision number has to be incremented when there is a * change that may or may not break compatibility. */ -#define __WMI_REVISION_ 1422 +#define __WMI_REVISION_ 1431 /** The Version Namespace should not be normally changed. Only * host and firmware of the same WMI namespace will work diff --git a/mm/filemap.c b/mm/filemap.c index cc3c08f7ba26..3b12481fc9a4 100644 --- a/mm/filemap.c +++ b/mm/filemap.c @@ -2004,7 +2004,7 @@ static void shrink_readahead_size_eio(struct file *filp, * This is really ugly. But the goto's actually try to clarify some * of the logic when it comes to error handling etc. */ -static ssize_t generic_file_buffered_read(struct kiocb *iocb, +ssize_t generic_file_buffered_read(struct kiocb *iocb, struct iov_iter *iter, ssize_t written) { struct file *filp = iocb->ki_filp; @@ -2256,6 +2256,7 @@ out: file_accessed(filp); return written ? written : error; } +EXPORT_SYMBOL_GPL(generic_file_buffered_read); /** * generic_file_read_iter - generic filesystem read routine