diff --git a/dp/inc/cdp_txrx_cmn.h b/dp/inc/cdp_txrx_cmn.h index e783889e4f..fda03d624f 100644 --- a/dp/inc/cdp_txrx_cmn.h +++ b/dp/inc/cdp_txrx_cmn.h @@ -2755,4 +2755,30 @@ void cdp_set_rtpm_tput_policy_requirement(ol_txrx_soc_handle soc, #endif /* FEATURE_RUNTIME_PM */ +/** + * cdp_enable_mon_reap_timer() - enable/disable reap timer + * @soc: Datapath soc handle + * @pdev_id: id of objmgr pdev + * @enable: enable/disable reap timer of monitor status ring + * + * Return: none + */ +static inline void +cdp_enable_mon_reap_timer(ol_txrx_soc_handle soc, uint8_t pdev_id, + bool enable) +{ + if (!soc || !soc->ops) { + QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_FATAL, + "%s invalid instance", __func__); + QDF_BUG(0); + return; + } + + if (!soc->ops->mon_ops || + !soc->ops->mon_ops->txrx_enable_mon_reap_timer) + return; + + return soc->ops->mon_ops->txrx_enable_mon_reap_timer(soc, pdev_id, + enable); +} #endif /* _CDP_TXRX_CMN_H_ */ diff --git a/dp/inc/cdp_txrx_ctrl.h b/dp/inc/cdp_txrx_ctrl.h index 9c314ed28d..f4b8ecc4d5 100644 --- a/dp/inc/cdp_txrx_ctrl.h +++ b/dp/inc/cdp_txrx_ctrl.h @@ -1077,33 +1077,6 @@ cdp_cfr_clr_dbg_stats(ol_txrx_soc_handle soc, uint8_t pdev_id) soc->ops->cfr_ops->txrx_clear_cfr_dbg_stats(soc, pdev_id); } - -/** - * cdp_enable_mon_reap_timer() - enable/disable reap timer - * @soc: Datapath soc handle - * @pdev_id: id of objmgr pdev - * @enable: enable/disable reap timer of monitor status ring - * - * Return: none - */ -static inline void -cdp_enable_mon_reap_timer(ol_txrx_soc_handle soc, uint8_t pdev_id, - bool enable) -{ - if (!soc || !soc->ops) { - QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_FATAL, - "%s invalid instance", __func__); - QDF_BUG(0); - return; - } - - if (!soc->ops->cfr_ops || - !soc->ops->cfr_ops->txrx_enable_mon_reap_timer) - return; - - return soc->ops->cfr_ops->txrx_enable_mon_reap_timer(soc, pdev_id, - enable); -} #endif #if defined(WLAN_TX_PKT_CAPTURE_ENH) || defined(WLAN_RX_PKT_CAPTURE_ENH) diff --git a/dp/inc/cdp_txrx_ops.h b/dp/inc/cdp_txrx_ops.h index 62f8751d0d..4809f233d1 100644 --- a/dp/inc/cdp_txrx_ops.h +++ b/dp/inc/cdp_txrx_ops.h @@ -889,6 +889,14 @@ struct cdp_me_ops { bool is_igmp, bool is_dms_pkt); }; +/** + * struct cdp_mon_ops - host mon ops + * @txrx_reset_monitor_mode: Handler to reset monitor mode + * @txrx_deliver_tx_mgmt: deliver mgmt tx frame + * @txrx_set_advance_monitor_filter: set advanced monitor mode + * @config_full_mon_mode: configure full monitor mode + * @txrx_enable_mon_reap_timer: Enable/Disable reap timer of monitor status ring + */ struct cdp_mon_ops { QDF_STATUS (*txrx_reset_monitor_mode) @@ -912,6 +920,11 @@ struct cdp_mon_ops { QDF_STATUS (*get_mon_pdev_rx_stats)(struct cdp_soc_t *soc, uint8_t pdev_id, struct cdp_pdev_mon_stats *stats); + + /* Configure monitor status srng reap timer */ + void (*txrx_enable_mon_reap_timer)(struct cdp_soc_t *soc_hdl, + uint8_t pdev_id, + bool enable); }; struct cdp_host_stats_ops { @@ -1850,7 +1863,6 @@ struct cdp_rx_offld_ops { * @txrx_set_cfr_rcc: Handler to enable/disable CFR mode * @txrx_get_cfr_dbg_stats: Handler to get debug statistics for CFR mode * @txrx_clear_cfr_dbg_stats: Handler to clear debug statistics for CFR mode - * @txrx_enable_mon_reap_timer: Enable/Disable reap timer of monitor status ring */ struct cdp_cfr_ops { void (*txrx_cfr_filter)(struct cdp_soc_t *soc_hdl, @@ -1867,9 +1879,6 @@ struct cdp_cfr_ops { struct cdp_cfr_rcc_stats *buf); void (*txrx_clear_cfr_dbg_stats)(struct cdp_soc_t *soc_hdl, uint8_t pdev_id); - void (*txrx_enable_mon_reap_timer)(struct cdp_soc_t *soc_hdl, - uint8_t pdev_id, - bool enable); }; #endif diff --git a/dp/wifi3.0/dp_main.c b/dp/wifi3.0/dp_main.c index 058b3e7b5d..2f58682b83 100644 --- a/dp/wifi3.0/dp_main.c +++ b/dp/wifi3.0/dp_main.c @@ -12425,7 +12425,6 @@ static struct cdp_cfr_ops dp_ops_cfr = { .txrx_set_cfr_rcc = dp_set_cfr_rcc, .txrx_get_cfr_dbg_stats = dp_get_cfr_dbg_stats, .txrx_clear_cfr_dbg_stats = dp_clear_cfr_dbg_stats, - .txrx_enable_mon_reap_timer = NULL, }; #endif diff --git a/dp/wifi3.0/dp_tx.h b/dp/wifi3.0/dp_tx.h index 9876bde4fe..6d043503e1 100644 --- a/dp/wifi3.0/dp_tx.h +++ b/dp/wifi3.0/dp_tx.h @@ -22,9 +22,13 @@ #include #include #include "dp_types.h" -#if defined(MESH_MODE_SUPPORT) || defined(FEATURE_PERPKT_INFO) +#ifdef FEATURE_PERPKT_INFO +#if defined(QCA_SUPPORT_LATENCY_CAPTURE) || \ + defined(QCA_TX_CAPTURE_SUPPORT) || \ + defined(QCA_MCOPY_SUPPORT) #include "if_meta_hdr.h" #endif +#endif #include "dp_internal.h" #include "hal_tx.h" #include @@ -716,6 +720,9 @@ static inline void dp_tx_vdev_update_search_flags(struct dp_vdev *vdev) #endif /* QCA_HOST_MODE_WIFI_DISABLED */ +#if defined(QCA_SUPPORT_LATENCY_CAPTURE) || \ + defined(QCA_TX_CAPTURE_SUPPORT) || \ + defined(QCA_MCOPY_SUPPORT) #ifdef FEATURE_PERPKT_INFO QDF_STATUS dp_get_completion_indication_for_stack(struct dp_soc *soc, @@ -728,6 +735,7 @@ dp_get_completion_indication_for_stack(struct dp_soc *soc, void dp_send_completion_to_stack(struct dp_soc *soc, struct dp_pdev *pdev, uint16_t peer_id, uint32_t ppdu_id, qdf_nbuf_t netbuf); +#endif #else static inline QDF_STATUS dp_get_completion_indication_for_stack(struct dp_soc *soc, diff --git a/dp/wifi3.0/dp_txrx_wds.c b/dp/wifi3.0/dp_txrx_wds.c index 3a77d3d5e8..5d263f5385 100644 --- a/dp/wifi3.0/dp_txrx_wds.c +++ b/dp/wifi3.0/dp_txrx_wds.c @@ -1335,6 +1335,9 @@ void dp_hmwds_ast_add_notify(struct dp_peer *peer, #endif } +#if defined(QCA_SUPPORT_LATENCY_CAPTURE) || \ + defined(QCA_TX_CAPTURE_SUPPORT) || \ + defined(QCA_MCOPY_SUPPORT) #ifdef FEATURE_PERPKT_INFO /** * dp_get_completion_indication_for_stack() - send completion to stack @@ -1441,3 +1444,4 @@ void dp_send_completion_to_stack(struct dp_soc *soc, struct dp_pdev *pdev, WDI_NO_VAL, pdev->pdev_id); } #endif +#endif diff --git a/dp/wifi3.0/monitor/1.0/dp_mon_1.0.c b/dp/wifi3.0/monitor/1.0/dp_mon_1.0.c index 627ca20b48..47cc4e1151 100644 --- a/dp/wifi3.0/monitor/1.0/dp_mon_1.0.c +++ b/dp/wifi3.0/monitor/1.0/dp_mon_1.0.c @@ -1219,6 +1219,7 @@ struct cdp_mon_ops dp_ops_mon_1_0 = { .config_full_mon_mode = dp_config_full_mon_mode, .soc_config_full_mon_mode = dp_soc_config_full_mon_mode, .get_mon_pdev_rx_stats = dp_pdev_get_rx_mon_stats, + .txrx_enable_mon_reap_timer = dp_enable_mon_reap_timer, }; #ifdef QCA_MONITOR_OPS_PER_SOC_SUPPORT diff --git a/dp/wifi3.0/monitor/2.0/dp_mon_2.0.c b/dp/wifi3.0/monitor/2.0/dp_mon_2.0.c index 0b6344925c..a539405f2c 100644 --- a/dp/wifi3.0/monitor/2.0/dp_mon_2.0.c +++ b/dp/wifi3.0/monitor/2.0/dp_mon_2.0.c @@ -1327,6 +1327,7 @@ struct cdp_mon_ops dp_ops_mon_2_0 = { .config_full_mon_mode = NULL, .soc_config_full_mon_mode = NULL, .get_mon_pdev_rx_stats = dp_pdev_get_rx_mon_stats, + .txrx_enable_mon_reap_timer = dp_enable_mon_reap_timer, }; #ifdef QCA_MONITOR_OPS_PER_SOC_SUPPORT diff --git a/dp/wifi3.0/monitor/dp_mon.c b/dp/wifi3.0/monitor/dp_mon.c index 86431701ef..1dc579156c 100644 --- a/dp/wifi3.0/monitor/dp_mon.c +++ b/dp/wifi3.0/monitor/dp_mon.c @@ -1611,16 +1611,9 @@ static void dp_cfr_filter(struct cdp_soc_t *soc_hdl, &htt_tlv_filter); } } +#endif -/* - * dp_enable_mon_reap_timer() - enable/disable reap timer - * @soc_hdl: Datapath soc handle - * @pdev_id: id of objmgr pdev - * @enable: Enable/Disable reap timer of monitor status ring - * - * Return: none - */ -static void +void dp_enable_mon_reap_timer(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, bool enable) { @@ -1653,7 +1646,6 @@ dp_enable_mon_reap_timer(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, else qdf_timer_sync_cancel(&mon_soc->mon_reap_timer); } -#endif #if defined(DP_CON_MON) #ifndef REMOVE_PKT_LOG @@ -5470,7 +5462,6 @@ void dp_mon_cdp_ops_register(struct dp_soc *soc) #if defined(WLAN_CFR_ENABLE) && defined(WLAN_ENH_CFR_ENABLE) ops->cfr_ops->txrx_cfr_filter = dp_cfr_filter; - ops->cfr_ops->txrx_enable_mon_reap_timer = dp_enable_mon_reap_timer; #endif ops->cmn_drv_ops->txrx_set_monitor_mode = dp_vdev_set_monitor_mode; ops->cmn_drv_ops->txrx_get_mon_vdev_from_pdev = @@ -5541,7 +5532,6 @@ void dp_mon_cdp_ops_deregister(struct dp_soc *soc) #if defined(WLAN_CFR_ENABLE) && defined(WLAN_ENH_CFR_ENABLE) ops->cfr_ops->txrx_cfr_filter = NULL; - ops->cfr_ops->txrx_enable_mon_reap_timer = NULL; #endif ops->cmn_drv_ops->txrx_set_monitor_mode = NULL; ops->cmn_drv_ops->txrx_get_mon_vdev_from_pdev = NULL; diff --git a/dp/wifi3.0/monitor/dp_mon.h b/dp/wifi3.0/monitor/dp_mon.h index 2b45421692..68acee83ef 100644 --- a/dp/wifi3.0/monitor/dp_mon.h +++ b/dp/wifi3.0/monitor/dp_mon.h @@ -3907,4 +3907,14 @@ void dp_mon_register_feature_ops(struct dp_soc *soc) */ QDF_STATUS dp_pdev_get_rx_mon_stats(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, struct cdp_pdev_mon_stats *stats); +/* + * dp_enable_mon_reap_timer() - enable/disable reap timer + * @soc_hdl: Datapath soc handle + * @pdev_id: id of objmgr pdev + * @enable: Enable/Disable reap timer of monitor status ring + * + * Return: none + */ +void dp_enable_mon_reap_timer(struct cdp_soc_t *soc_hdl, uint8_t pdev_id, + bool enable); #endif /* _DP_MON_H_ */