diff --git a/dp/inc/cdp_txrx_mon.h b/dp/inc/cdp_txrx_mon.h index a11bb95846..d42c596851 100644 --- a/dp/inc/cdp_txrx_mon.h +++ b/dp/inc/cdp_txrx_mon.h @@ -69,143 +69,4 @@ cdp_deliver_tx_mgmt(ol_txrx_soc_handle soc, uint8_t pdev_id, return soc->ops->mon_ops->txrx_deliver_tx_mgmt(soc, pdev_id, nbuf); } -#ifdef WLAN_FEATURE_PKT_CAPTURE -static inline void -cdp_pktcapture_record_channel( - ol_txrx_soc_handle soc, - uint8_t pdev_id, - int chan_num) -{ - if (!soc || !soc->ops) { - QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_DEBUG, - "%s invalid instance", __func__); - QDF_BUG(0); - return; - } - - if (!soc->ops->pktcapture_ops || - !soc->ops->pktcapture_ops->txrx_pktcapture_record_channel) - return; - - soc->ops->pktcapture_ops->txrx_pktcapture_record_channel(soc, - pdev_id, - chan_num); -} - -static inline void -cdp_set_packet_capture_mode(ol_txrx_soc_handle soc, - uint8_t pdev_id, - uint8_t val) -{ - if (!soc || !soc->ops) { - QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_DEBUG, - "%s invalid instance", __func__); - QDF_BUG(0); - return; - } - - if (!soc->ops->pktcapture_ops || - !soc->ops->pktcapture_ops->txrx_pktcapture_set_mode) - return; - - soc->ops->pktcapture_ops->txrx_pktcapture_set_mode(soc, pdev_id, val); -} - -static inline uint8_t -cdp_get_packet_capture_mode(ol_txrx_soc_handle soc, uint8_t pdev_id) -{ - if (!soc || !soc->ops) { - QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_DEBUG, - "%s invalid instance", __func__); - QDF_BUG(0); - return 0; - } - - if (!soc->ops->pktcapture_ops || - !soc->ops->pktcapture_ops->txrx_pktcapture_get_mode) - return 0; - - return soc->ops->pktcapture_ops->txrx_pktcapture_get_mode(soc, - pdev_id); -} - -static inline QDF_STATUS -cdp_register_pktcapture_cb( - ol_txrx_soc_handle soc, uint8_t pdev_id, void *ctx, - QDF_STATUS(txrx_pktcapture_cb)(void *, qdf_nbuf_t)) -{ - if (!soc || !soc->ops) { - QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_FATAL, - "%s invalid instance", __func__); - return QDF_STATUS_E_INVAL; - } - - if (!soc->ops->pktcapture_ops || - !soc->ops->pktcapture_ops->txrx_pktcapture_cb_register) - return QDF_STATUS_E_INVAL; - - return soc->ops->pktcapture_ops->txrx_pktcapture_cb_register( - soc, - pdev_id, - ctx, - txrx_pktcapture_cb); -} - -static inline QDF_STATUS -cdp_deregister_pktcapture_cb(ol_txrx_soc_handle soc, uint8_t pdev_id) -{ - if (!soc || !soc->ops) { - QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_FATAL, - "%s invalid instance", __func__); - return QDF_STATUS_E_INVAL; - } - - if (!soc->ops->pktcapture_ops || - !soc->ops->pktcapture_ops->txrx_pktcapture_cb_deregister) - return QDF_STATUS_E_INVAL; - - return soc->ops->pktcapture_ops->txrx_pktcapture_cb_deregister(soc, - pdev_id); -} - -static inline QDF_STATUS -cdp_pktcapture_mgmtpkt_process( - ol_txrx_soc_handle soc, - uint8_t pdev_id, - struct mon_rx_status *txrx_status, - qdf_nbuf_t nbuf, - uint8_t status) -{ - if (!soc || !soc->ops) { - QDF_TRACE(QDF_MODULE_ID_DP, QDF_TRACE_LEVEL_FATAL, - "%s invalid instance", __func__); - return QDF_STATUS_E_INVAL; - } - - if (!soc->ops->pktcapture_ops || - !soc->ops->pktcapture_ops->txrx_pktcapture_mgmtpkt_process) - return QDF_STATUS_E_INVAL; - - return soc->ops->pktcapture_ops->txrx_pktcapture_mgmtpkt_process( - soc, - pdev_id, - txrx_status, - nbuf, - status); -} -#else -static inline uint8_t -cdp_get_packet_capture_mode(ol_txrx_soc_handle soc, uint8_t pdev_id) -{ - return 0; -} - -static inline void -cdp_pktcapture_record_channel(ol_txrx_soc_handle soc, - uint8_t pdev_id, - int chan_num) -{ -} -#endif /* WLAN_FEATURE_PKT_CAPTURE */ - #endif diff --git a/dp/inc/cdp_txrx_ops.h b/dp/inc/cdp_txrx_ops.h index 40d7751a09..344e2f8861 100644 --- a/dp/inc/cdp_txrx_ops.h +++ b/dp/inc/cdp_txrx_ops.h @@ -767,40 +767,6 @@ struct cdp_mon_ops { (*config_full_mon_mode)(struct cdp_soc_t *soc, uint8_t val); }; -#ifdef WLAN_FEATURE_PKT_CAPTURE -struct cdp_pktcapture_ops { - void (*txrx_pktcapture_set_mode) - (struct cdp_soc_t *soc, - uint8_t pdev_id, - uint8_t mode); - - uint8_t (*txrx_pktcapture_get_mode) - (struct cdp_soc_t *soc, - uint8_t pdev_id); - - QDF_STATUS (*txrx_pktcapture_cb_register) - (struct cdp_soc_t *soc, - uint8_t pdev_id, - void *context, - QDF_STATUS(cb)(void *, qdf_nbuf_t)); - - QDF_STATUS (*txrx_pktcapture_cb_deregister) - (struct cdp_soc_t *soc, - uint8_t pdev_id); - - QDF_STATUS (*txrx_pktcapture_mgmtpkt_process) - (struct cdp_soc_t *soc, - uint8_t pdev_id, - struct mon_rx_status *txrx_status, - qdf_nbuf_t nbuf, uint8_t status); - - void (*txrx_pktcapture_record_channel) - (struct cdp_soc_t *soc, - uint8_t pdev_id, - int chan_no); -}; -#endif /* #ifdef WLAN_FEATURE_PKT_CAPTURE */ - struct cdp_host_stats_ops { int (*txrx_host_stats_get)(struct cdp_soc_t *soc, uint8_t vdev_id, struct ol_txrx_stats_req *req); @@ -1661,9 +1627,6 @@ struct cdp_ops { #ifdef RECEIVE_OFFLOAD struct cdp_rx_offld_ops *rx_offld_ops; #endif -#ifdef WLAN_FEATURE_PKT_CAPTURE - struct cdp_pktcapture_ops *pktcapture_ops; -#endif #if defined(WLAN_CFR_ENABLE) && defined(WLAN_ENH_CFR_ENABLE) struct cdp_cfr_ops *cfr_ops; #endif