Merge "qcacmn: fix the issue for block ack/ack for tx capture mode"

This commit is contained in:
Linux Build Service Account 2020-01-28 19:39:18 -08:00 • committed by Gerrit - the friendly Code Review server
commit b1261d4e0c
10 changed files with 122 additions and 5 deletions

View file

@ -543,10 +543,25 @@ struct hal_rx_ppdu_cfr_info {
struct hal_rx_ppdu_cfr_info {};
#endif
struct mon_rx_info {
uint8_t qos_control_info_valid;
uint16_t qos_control;
uint8_t mac_addr1_valid;
uint8_t mac_addr1[QDF_MAC_ADDR_SIZE];
};
struct mon_rx_user_info {
uint16_t qos_control;
uint8_t qos_control_info_valid;
uint32_t bar_frame:1;
};
struct hal_rx_ppdu_info {
struct hal_rx_ppdu_common_info com_info;
struct mon_rx_status rx_status;
struct mon_rx_user_status rx_user_status[HAL_MAX_UL_MU_USERS];
struct mon_rx_info rx_info;
struct mon_rx_user_info rx_user_info[HAL_MAX_UL_MU_USERS];
struct hal_rx_msdu_payload_info msdu_info;
struct hal_rx_msdu_payload_info fcs_ok_msdu_info;
struct hal_rx_nac_info nac_info;

View file

@ -310,6 +310,30 @@ hal_rx_populate_mu_user_info(void *rx_tlv, void *ppduinfo,
hal_rx_populate_byte_count(rx_tlv, ppdu_info, mon_rx_user_status);
}
#ifdef WLAN_TX_PKT_CAPTURE_ENH
static inline void
hal_rx_populate_tx_capture_user_info(void *ppduinfo,
uint32_t user_id)
{
struct hal_rx_ppdu_info *ppdu_info;
struct mon_rx_info *mon_rx_info;
struct mon_rx_user_info *mon_rx_user_info;
ppdu_info = (struct hal_rx_ppdu_info *)ppduinfo;
mon_rx_info = &ppdu_info->rx_info;
mon_rx_user_info = &ppdu_info->rx_user_info[user_id];
mon_rx_user_info->qos_control_info_valid =
mon_rx_info->qos_control_info_valid;
mon_rx_user_info->qos_control = mon_rx_info->qos_control;
}
#else
static inline void
hal_rx_populate_tx_capture_user_info(void *ppduinfo,
uint32_t user_id)
{
}
#endif
#define HAL_RX_UPDATE_RSSI_PER_CHAIN_BW(chain, word_1, word_2, \
ppdu_info, rssi_info_tlv) \
{ \
@ -357,6 +381,50 @@ hal_rx_update_rssi_chain(struct hal_rx_ppdu_info *ppdu_info,
return 0;
}
#ifdef WLAN_TX_PKT_CAPTURE_ENH
static inline void
hal_get_qos_control(void *rx_tlv,
struct hal_rx_ppdu_info *ppdu_info)
{
ppdu_info->rx_info.qos_control_info_valid =
HAL_RX_GET(rx_tlv, RX_PPDU_END_USER_STATS_3,
QOS_CONTROL_INFO_VALID);
if (ppdu_info->rx_info.qos_control_info_valid)
ppdu_info->rx_info.qos_control =
HAL_RX_GET(rx_tlv,
RX_PPDU_END_USER_STATS_5,
QOS_CONTROL_FIELD);
}
static inline void
hal_get_mac_addr1(uint8_t *rx_mpdu_start,
struct hal_rx_ppdu_info *ppdu_info)
{
if (ppdu_info->sw_frame_group_id
== HAL_MPDU_SW_FRAME_GROUP_MGMT_PROBE_REQ) {
ppdu_info->rx_info.mac_addr1_valid =
HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start);
*(uint32_t *)&ppdu_info->rx_info.mac_addr1[0] =
HAL_RX_GET(rx_mpdu_start,
RX_MPDU_INFO_15,
MAC_ADDR_AD1_31_0);
}
}
#else
static inline void
hal_get_qos_control(void *rx_tlv,
struct hal_rx_ppdu_info *ppdu_info)
{
}
static inline void
hal_get_mac_addr1(uint8_t *rx_mpdu_start,
struct hal_rx_ppdu_info *ppdu_info)
{
}
#endif
/**
* hal_rx_status_get_tlv_info() - process receive info TLV
* @rx_tlv_hdr: pointer to TLV header
@ -504,6 +572,8 @@ hal_rx_status_get_tlv_info_generic(void *rx_tlv_hdr, void *ppduinfo,
HAL_RX_GET(rx_tlv,
RX_PPDU_END_USER_STATS_4,
FRAME_CONTROL_FIELD);
hal_get_qos_control(rx_tlv, ppdu_info);
}
ppdu_info->rx_status.data_sequence_control_info_valid =
@ -564,6 +634,10 @@ hal_rx_status_get_tlv_info_generic(void *rx_tlv_hdr, void *ppduinfo,
hal_rx_populate_mu_user_info(rx_tlv, ppdu_info,
mon_rx_user_status);
hal_rx_populate_tx_capture_user_info(ppdu_info,
user_id);
}
break;
}
@ -1392,6 +1466,9 @@ hal_rx_status_get_tlv_info_generic(void *rx_tlv_hdr, void *ppduinfo,
ppdu_info->nac_info.frame_control;
}
hal_get_mac_addr1(rx_mpdu_start,
ppdu_info);
ppdu_info->nac_info.mac_addr2_valid =
HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start);

View file

@ -1137,7 +1137,9 @@ hal_rx_msdu_start_toeplitz_get(uint8_t *buf)
* @ HAL_MPDU_SW_FRAME_GROUP_UNICAST_DATA: unicast data frame
* @ HAL_MPDU_SW_FRAME_GROUP_NULL_DATA: NULL data frame
* @ HAL_MPDU_SW_FRAME_GROUP_MGMT: management frame
* @ HAL_MPDU_SW_FRAME_GROUP_MGMT_PROBE_REQ: probe req frame
* @ HAL_MPDU_SW_FRAME_GROUP_CTRL: control frame
* @ HAL_MPDU_SW_FRAME_GROUP_CTRL_BAR: BAR frame
* @ HAL_MPDU_SW_FRAME_GROUP_UNSUPPORTED: unsupported
* @ HAL_MPDU_SW_FRAME_GROUP_MAX: max limit
*/
@ -1147,8 +1149,10 @@ enum hal_rx_mpdu_info_sw_frame_group_id_type {
HAL_MPDU_SW_FRAME_GROUP_UNICAST_DATA,
HAL_MPDU_SW_FRAME_GROUP_NULL_DATA,
HAL_MPDU_SW_FRAME_GROUP_MGMT,
HAL_MPDU_SW_FRAME_GROUP_MGMT_PROBE_REQ = 8,
HAL_MPDU_SW_FRAME_GROUP_MGMT_BEACON = 12,
HAL_MPDU_SW_FRAME_GROUP_CTRL = 20,
HAL_MPDU_SW_FRAME_GROUP_CTRL_BAR = 28,
HAL_MPDU_SW_FRAME_GROUP_UNSUPPORTED = 36,
HAL_MPDU_SW_FRAME_GROUP_MAX = 37,
};

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2016-2019 The Linux Foundation. All rights reserved.
* Copyright (c) 2016-2020 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@ -255,6 +255,9 @@
#define HAL_RX_GET_TO_DS_FLAG(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, TO_DS)
#define HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD1_VALID)
#define HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD2_VALID)

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2016-2019 The Linux Foundation. All rights reserved.
* Copyright (c) 2016-2020 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@ -261,6 +261,9 @@
#define HAL_RX_GET_TO_DS_FLAG(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, TO_DS)
#define HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD1_VALID)
#define HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD2_VALID)

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2019 The Linux Foundation. All rights reserved.
* Copyright (c) 2019-2020 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@ -264,6 +264,9 @@
#define HAL_RX_GET_TO_DS_FLAG(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, TO_DS)
#define HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, MAC_ADDR_AD1_VALID)
#define HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, MAC_ADDR_AD2_VALID)

View file

@ -264,6 +264,9 @@
#define HAL_RX_GET_TO_DS_FLAG(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, TO_DS)
#define HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, MAC_ADDR_AD1_VALID)
#define HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, MAC_ADDR_AD2_VALID)

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2016-2019 The Linux Foundation. All rights reserved.
* Copyright (c) 2016-2020 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@ -244,6 +244,9 @@
#define HAL_RX_GET_TO_DS_FLAG(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, TO_DS)
#define HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD1_VALID)
#define HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD2_VALID)

View file

@ -253,6 +253,9 @@
#define HAL_RX_GET_TO_DS_FLAG(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, TO_DS)
#define HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD1_VALID)
#define HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_2, MAC_ADDR_AD2_VALID)

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2016-2019 The Linux Foundation. All rights reserved.
* Copyright (c) 2016-2020 The Linux Foundation. All rights reserved.
*
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
@ -38,6 +38,9 @@
#define HAL_RX_GET_TO_DS_FLAG(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, TO_DS)
#define HAL_RX_GET_MAC_ADDR1_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, MAC_ADDR_AD1_VALID)
#define HAL_RX_GET_MAC_ADDR2_VALID(rx_mpdu_start) \
HAL_RX_GET(rx_mpdu_start, RX_MPDU_INFO_11, MAC_ADDR_AD2_VALID)