On 12/22/2024 10:45 AM, Karthikeyan Periyasamy wrote:
On 12/21/2024 10:00 AM, P Praneesh wrote:
ath12k_mac_op_configure_filter() gets called multiple times during
interface bringup. Applying filter configuration from this function leads
to writing same filter configurations multiple times.
Fix it by moving the filter configuration to ath12k_mac_op_start().
Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.3.1-00173-QCAHKSWPL_SILICONZ-1
Tested-on: WCN7850 hw2.0 PCI WLAN.HMT.1.0.c5-00481-
QCAHMTSWPL_V1.0_V2.0_SILICONZ-3
Signed-off-by: P Praneesh <quic_ppranees@xxxxxxxxxxx>
---
drivers/net/wireless/ath/ath12k/mac.c | 55 ++++++++++++++-------------
1 file changed, 29 insertions(+), 26 deletions(-)
diff --git a/drivers/net/wireless/ath/ath12k/mac.c b/drivers/net/
wireless/ath/ath12k/mac.c
index 6f10813d9378..2cb6e9b529d7 100644
--- a/drivers/net/wireless/ath/ath12k/mac.c
+++ b/drivers/net/wireless/ath/ath12k/mac.c
@@ -7237,8 +7237,34 @@ void ath12k_mac_drain_tx(struct ath12k *ar)
static int ath12k_mac_config_mon_status_default(struct ath12k *ar,
bool enable)
{
- return -EOPNOTSUPP;
- /* TODO: Need to support new monitor mode */
+ struct htt_rx_ring_tlv_filter tlv_filter = {};
+ struct ath12k_base *ab = ar->ab;
+ u32 ring_id, i;
+ int ret = 0;
+
+ lockdep_assert_wiphy(ath12k_ar_to_hw(ar)->wiphy);
+
+ if (!ab->hw_params->rxdma1_enable)
+ return ret;
+
+ if (enable)
+ tlv_filter = ath12k_mac_mon_status_filter_default;
No need to disable the filter in the else case like below ?
tlv_filter.rxmon_disable = true;
Yes, setting this flag to true fully disables the monitor ring. I'll
include this change in the next version.