瀏覽代碼

qcacmn: Add function to reset mon interrupt mask

Add function to reset monitor interrupt mask.

Change-Id: If40093cc87dc02432645ec687b00fe856894238d
CRs-Fixed: 3007273
Jeevan Kukkalli 3 年之前
父節點
當前提交
2536fbaf5c
共有 2 個文件被更改,包括 26 次插入0 次删除
  1. 8 0
      dp/wifi3.0/dp_internal.h
  2. 18 0
      dp/wifi3.0/dp_main.c

+ 8 - 0
dp/wifi3.0/dp_internal.h

@@ -3050,4 +3050,12 @@ QDF_STATUS dp_pdev_bkp_stats_attach(struct dp_pdev *pdev);
  */
 void dp_peer_flush_frags(struct cdp_soc_t *soc_hdl, uint8_t vdev_id,
 			 uint8_t *peer_mac);
+
+/**
+ * dp_soc_reset_mon_intr_mask() - reset mon intr mask
+ * @soc: pointer to dp_soc handle
+ *
+ * Return:
+ */
+void dp_soc_reset_mon_intr_mask(struct dp_soc *soc);
 #endif /* #ifndef _DP_INTERNAL_H_ */

+ 18 - 0
dp/wifi3.0/dp_main.c

@@ -448,6 +448,24 @@ uint32_t dp_soc_get_mon_mask_for_interrupt_mode(struct dp_soc *soc, int intr_ctx
 	return wlan_cfg_get_rx_mon_ring_mask(soc->wlan_cfg_ctx, intr_ctx_num);
 }
 
+/**
+ * dp_soc_reset_mon_intr_mask() - reset mon intr mask
+ * @soc: pointer to dp_soc handle
+ *
+ * Return:
+ */
+void dp_soc_reset_mon_intr_mask(struct dp_soc *soc)
+{
+	int i;
+
+	for (i = 0; i < wlan_cfg_get_num_contexts(soc->wlan_cfg_ctx); i++) {
+		soc->intr_ctx[i].rx_mon_ring_mask = 0;
+		soc->intr_ctx[i].host2rxdma_mon_ring_mask = 0;
+	}
+}
+
+qdf_export_symbol(dp_soc_reset_mon_intr_mask);
+
 /*
  * dp_service_lmac_rings()- timer to reap lmac rings
  * @arg: SoC Handle