qcacmn: Move cmn code under QCA_MONITOR_2_0_SUPPORT to TX/RX 2.0 macro

Currently QCA_MONITOR_2_0_SUPPORT macro is used for both TX and RX 2.0.
but on MCC side, only RX 1.0 is supported and as part of this feature
TX 2.0 need to be supported.
Enabling QCA_MONITOR_2_0_SUPPORT will enable both RX 2.0 and TX 2.0, but
to support RX 1.0 and TX 2.0, we need to separate out code under
QCA_MONITOR_2_0_SUPPORT to TX and RX 2.0 macro.

As part of this change, introduce separate macros for TX 2.0 and RX 2.0
and move the common code under both macros.

Change-Id: I7ef7e488800934291538a0bca9acd21e28901214
CRs-Fixed: 3415740
This commit is contained in:
Srinivas Girigowda
2022-12-14 16:35:54 -08:00
committed by Madan Koyyalamudi
parent d549261151
commit ec3b9bdbce
6 changed files with 13 additions and 9 deletions

View File

@@ -25,7 +25,8 @@
#include "dp_be_tx.h"
#include "dp_be_rx.h"
#ifdef WIFI_MONITOR_SUPPORT
#if !defined(DISABLE_MON_CONFIG) && defined(QCA_MONITOR_2_0_SUPPORT)
#if !defined(DISABLE_MON_CONFIG) && (defined(WLAN_PKT_CAPTURE_TX_2_0) || \
defined(WLAN_PKT_CAPTURE_RX_2_0))
#include "dp_mon_2.0.h"
#endif
#include "dp_mon.h"

View File

@@ -505,7 +505,8 @@ void dp_mon_rx_update_rx_protocol_tag_stats(struct dp_pdev *pdev,
uint16_t protocol_index);
#endif /* WLAN_SUPPORT_RX_PROTOCOL_TYPE_TAG */
#if !defined(DISABLE_MON_CONFIG) && defined(QCA_MONITOR_2_0_SUPPORT)
#if !defined(DISABLE_MON_CONFIG) && (defined(WLAN_PKT_CAPTURE_TX_2_0) || \
defined(WLAN_PKT_CAPTURE_RX_2_0))
/**
* dp_mon_get_context_size_be() - get BE specific size for mon pdev/soc
* @context_type: context type for which the size is needed

View File

@@ -4796,7 +4796,8 @@ dp_ppdu_desc_user_stats_update(struct dp_pdev *pdev,
}
}
#if !defined(WLAN_TX_PKT_CAPTURE_ENH) || defined(QCA_MONITOR_2_0_SUPPORT)
#if !defined(WLAN_TX_PKT_CAPTURE_ENH) || defined(WLAN_PKT_CAPTURE_TX_2_0) || \
defined(WLAN_PKT_CAPTURE_RX_2_0)
/**
* dp_tx_ppdu_desc_notify() - Notify to upper layer about PPDU via WDI
*
@@ -6187,7 +6188,7 @@ void dp_mon_ops_register(struct dp_soc *soc)
case TARGET_TYPE_QCN9224:
case TARGET_TYPE_QCA5332:
case TARGET_TYPE_QCN6432:
#ifdef QCA_MONITOR_2_0_SUPPORT
#if defined(WLAN_PKT_CAPTURE_TX_2_0) || defined(WLAN_PKT_CAPTURE_RX_2_0)
dp_mon_ops_register_2_0(mon_soc);
#endif
break;
@@ -6258,12 +6259,12 @@ void dp_mon_cdp_ops_register(struct dp_soc *soc)
case TARGET_TYPE_QCN9224:
case TARGET_TYPE_QCA5332:
case TARGET_TYPE_QCN6432:
#ifdef QCA_MONITOR_2_0_SUPPORT
#if defined(WLAN_PKT_CAPTURE_TX_2_0) || defined(WLAN_PKT_CAPTURE_RX_2_0)
dp_mon_cdp_ops_register_2_0(ops);
#if defined(WLAN_CFR_ENABLE) && defined(WLAN_ENH_CFR_ENABLE)
dp_cfr_filter_register_2_0(ops);
#endif
#endif /* QCA_MONITOR_2_0_SUPPORT */
#endif /* WLAN_PKT_CAPTURE_TX_2_0 && WLAN_PKT_CAPTURE_RX_2_0 */
break;
default:
dp_mon_err("%s: Unknown tgt type %d", __func__, target_type);

View File

@@ -4549,7 +4549,8 @@ static inline bool dp_monitor_is_rx_cap_enabled(struct dp_peer *peer)
return peer->monitor_peer ? peer->monitor_peer->rx_cap_enabled : 0;
}
#if !(!defined(DISABLE_MON_CONFIG) && defined(QCA_MONITOR_2_0_SUPPORT))
#if !(!defined(DISABLE_MON_CONFIG) && (defined(WLAN_PKT_CAPTURE_TX_2_0) || \
defined(WLAN_PKT_CAPTURE_RX_2_0)))
/**
* dp_mon_get_context_size_be() - get BE specific size for mon pdev/soc
* @context_type: context type for which the size is needed

View File

@@ -96,7 +96,7 @@
#define UNIFIED_WBM_RELEASE_RING_6_TX_RATE_STATS_INFO_TX_RATE_STATS_LSB \
WBM_RELEASE_RING_TX_TX_RATE_STATS_PPDU_TRANSMISSION_TSF_LSB
#ifdef QCA_MONITOR_2_0_SUPPORT
#if defined(WLAN_PKT_CAPTURE_TX_2_0) || defined(WLAN_PKT_CAPTURE_RX_2_0)
#include "hal_be_api_mon.h"
#endif

View File

@@ -98,7 +98,7 @@
#define UNIFIED_WBM_RELEASE_RING_6_TX_RATE_STATS_INFO_TX_RATE_STATS_LSB \
WBM_RELEASE_RING_TX_TX_RATE_STATS_PPDU_TRANSMISSION_TSF_LSB
#ifdef QCA_MONITOR_2_0_SUPPORT
#if defined(WLAN_PKT_CAPTURE_TX_2_0) || defined(WLAN_PKT_CAPTURE_RX_2_0)
#include "hal_be_api_mon.h"
#endif