qcacmn: Add rx_ops and TGT layer APIs for MGMT Rx FW consumed event handler
When MGMT frames are consumed by the FW, FW sends MGMT Rx FW consumed event to the Host. Add rx_ops and TGT layer functions for this event handling. Change-Id: I50a4b02063bc545d6976944cf331982dc3e853d0 CRs-Fixed: 2959082
Este commit está contenido en:

cometido por
Madan Koyyalamudi

padre
ff18a53051
commit
3bde57d8de
@@ -224,6 +224,17 @@ struct wlan_lmac_if_mgmt_rx_reo_tx_ops {
|
||||
enum mgmt_rx_reo_snapshot_id id,
|
||||
struct mgmt_rx_reo_snapshot_params *value);
|
||||
};
|
||||
|
||||
/**
|
||||
* struct wlan_lmac_if_mgmt_txrx_rx_ops - structure of rx function
|
||||
* pointers for mgmt rx reo module
|
||||
* @fw_consumed_event_handler: FW consumed event handler
|
||||
*/
|
||||
struct wlan_lmac_if_mgmt_rx_reo_rx_ops {
|
||||
QDF_STATUS (*fw_consumed_event_handler)(
|
||||
struct wlan_objmgr_psoc *psoc,
|
||||
struct mgmt_rx_reo_params *params);
|
||||
};
|
||||
#endif
|
||||
|
||||
/**
|
||||
@@ -1284,6 +1295,9 @@ struct wlan_lmac_if_mgmt_txrx_rx_ops {
|
||||
uint32_t desc_id);
|
||||
uint32_t (*mgmt_txrx_get_free_desc_pool_count)(
|
||||
struct wlan_objmgr_pdev *pdev);
|
||||
#ifdef WLAN_MGMT_RX_REO_SUPPORT
|
||||
struct wlan_lmac_if_mgmt_rx_reo_rx_ops mgmt_rx_reo_rx_ops;
|
||||
#endif
|
||||
};
|
||||
|
||||
struct wlan_lmac_if_reg_rx_ops {
|
||||
|
@@ -77,6 +77,8 @@
|
||||
#include "wifi_pos_api.h"
|
||||
#endif
|
||||
|
||||
#include "wlan_mgmt_txrx_rx_reo_tgt_api.h"
|
||||
|
||||
/* Function pointer for OL/WMA specific UMAC tx_ops
|
||||
* registration.
|
||||
*/
|
||||
@@ -547,6 +549,57 @@ register_dfs_chan_postnol_rx_ops(struct wlan_lmac_if_dfs_rx_ops *rx_ops)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef WLAN_MGMT_RX_REO_SUPPORT
|
||||
static QDF_STATUS
|
||||
wlan_lmac_if_mgmt_rx_reo_rx_ops_register(
|
||||
struct wlan_lmac_if_mgmt_txrx_rx_ops *mgmt_txrx_rx_ops)
|
||||
{
|
||||
struct wlan_lmac_if_mgmt_rx_reo_rx_ops *mgmt_rx_reo_rx_ops;
|
||||
|
||||
mgmt_rx_reo_rx_ops = &mgmt_txrx_rx_ops->mgmt_rx_reo_rx_ops;
|
||||
mgmt_rx_reo_rx_ops->fw_consumed_event_handler =
|
||||
tgt_mgmt_rx_reo_fw_consumed_event_handler;
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
#else
|
||||
static QDF_STATUS
|
||||
wlan_lmac_if_mgmt_rx_reo_rx_ops_register(
|
||||
struct wlan_lmac_if_mgmt_txrx_rx_ops *mgmt_txrx_rx_ops)
|
||||
{
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
#endif
|
||||
|
||||
static QDF_STATUS
|
||||
wlan_lmac_if_mgmt_txrx_rx_ops_register(struct wlan_lmac_if_rx_ops *rx_ops)
|
||||
{
|
||||
struct wlan_lmac_if_mgmt_txrx_rx_ops *mgmt_txrx_rx_ops;
|
||||
|
||||
if (!rx_ops) {
|
||||
qdf_print("lmac if rx ops pointer is NULL");
|
||||
return QDF_STATUS_E_NULL_VALUE;
|
||||
}
|
||||
|
||||
/* mgmt txrx rx ops */
|
||||
mgmt_txrx_rx_ops = &rx_ops->mgmt_txrx_rx_ops;
|
||||
|
||||
mgmt_txrx_rx_ops->mgmt_tx_completion_handler =
|
||||
tgt_mgmt_txrx_tx_completion_handler;
|
||||
mgmt_txrx_rx_ops->mgmt_rx_frame_handler =
|
||||
tgt_mgmt_txrx_rx_frame_handler;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_nbuf_from_desc_id =
|
||||
tgt_mgmt_txrx_get_nbuf_from_desc_id;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_peer_from_desc_id =
|
||||
tgt_mgmt_txrx_get_peer_from_desc_id;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_vdev_id_from_desc_id =
|
||||
tgt_mgmt_txrx_get_vdev_id_from_desc_id;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_free_desc_pool_count =
|
||||
tgt_mgmt_txrx_get_free_desc_pool_count;
|
||||
|
||||
return wlan_lmac_if_mgmt_rx_reo_rx_ops_register(mgmt_txrx_rx_ops);
|
||||
}
|
||||
|
||||
static QDF_STATUS
|
||||
wlan_lmac_if_umac_dfs_rx_ops_register(struct wlan_lmac_if_rx_ops *rx_ops)
|
||||
{
|
||||
@@ -699,6 +752,7 @@ wlan_lmac_if_umac_ftm_rx_ops_register(struct wlan_lmac_if_rx_ops *rx_ops)
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* wlan_lmac_if_umac_rx_ops_register() - UMAC rx handler register
|
||||
* @rx_ops: Pointer to rx_ops structure to be populated
|
||||
@@ -714,28 +768,13 @@ wlan_lmac_if_umac_rx_ops_register(struct wlan_lmac_if_rx_ops *rx_ops)
|
||||
* respective callbacks
|
||||
* Ex: rx_ops->fp = function;
|
||||
*/
|
||||
struct wlan_lmac_if_mgmt_txrx_rx_ops *mgmt_txrx_rx_ops;
|
||||
|
||||
if (!rx_ops) {
|
||||
qdf_print("lmac if rx ops pointer is NULL");
|
||||
return QDF_STATUS_E_INVAL;
|
||||
}
|
||||
|
||||
/* mgmt txrx rx ops */
|
||||
mgmt_txrx_rx_ops = &rx_ops->mgmt_txrx_rx_ops;
|
||||
|
||||
mgmt_txrx_rx_ops->mgmt_tx_completion_handler =
|
||||
tgt_mgmt_txrx_tx_completion_handler;
|
||||
mgmt_txrx_rx_ops->mgmt_rx_frame_handler =
|
||||
tgt_mgmt_txrx_rx_frame_handler;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_nbuf_from_desc_id =
|
||||
tgt_mgmt_txrx_get_nbuf_from_desc_id;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_peer_from_desc_id =
|
||||
tgt_mgmt_txrx_get_peer_from_desc_id;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_vdev_id_from_desc_id =
|
||||
tgt_mgmt_txrx_get_vdev_id_from_desc_id;
|
||||
mgmt_txrx_rx_ops->mgmt_txrx_get_free_desc_pool_count =
|
||||
tgt_mgmt_txrx_get_free_desc_pool_count;
|
||||
wlan_lmac_if_mgmt_txrx_rx_ops_register(rx_ops);
|
||||
|
||||
/* scan rx ops */
|
||||
rx_ops->scan.scan_ev_handler = tgt_scan_event_handler;
|
||||
|
Referencia en una nueva incidencia
Block a user