qcacmn: Enabling TX FW metadata V2
As part of TX FW metadata V2 global sequence number based and SVC ID based support added. Change-Id: Iefee2c47ecbebf6edfec9a687ef67e0e270bbf06 CRs-Fixed: 3136931
This commit is contained in:

committed by
Madan Koyyalamudi

parent
193246d3d3
commit
9e4a8f0f21
@@ -330,15 +330,61 @@ dp_htt_h2t_send_complete(void *context, HTC_PACKET *htc_pkt)
|
|||||||
|
|
||||||
#endif /* ENABLE_CE4_COMP_DISABLE_HTT_HTC_MISC_LIST */
|
#endif /* ENABLE_CE4_COMP_DISABLE_HTT_HTC_MISC_LIST */
|
||||||
|
|
||||||
#ifdef WLAN_MCAST_MLO
|
|
||||||
/*
|
/*
|
||||||
* dp_htt_h2t_add_tcl_metadata_verg() - Add tcl_metadata verion
|
* dp_htt_h2t_add_tcl_metadata_ver_v1() - Add tcl_metadata verion V1
|
||||||
* @htt_soc: HTT SOC handle
|
* @htt_soc: HTT SOC handle
|
||||||
* @msg: Pointer to nbuf
|
* @msg: Pointer to nbuf
|
||||||
*
|
*
|
||||||
* Return: 0 on success; error code on failure
|
* Return: 0 on success; error code on failure
|
||||||
*/
|
*/
|
||||||
static int dp_htt_h2t_add_tcl_metadata_ver(struct htt_soc *soc, qdf_nbuf_t *msg)
|
static int dp_htt_h2t_add_tcl_metadata_ver_v1(struct htt_soc *soc,
|
||||||
|
qdf_nbuf_t *msg)
|
||||||
|
{
|
||||||
|
uint32_t *msg_word;
|
||||||
|
|
||||||
|
*msg = qdf_nbuf_alloc(
|
||||||
|
soc->osdev,
|
||||||
|
HTT_MSG_BUF_SIZE(HTT_VER_REQ_BYTES),
|
||||||
|
/* reserve room for the HTC header */
|
||||||
|
HTC_HEADER_LEN + HTC_HDR_ALIGNMENT_PADDING, 4, TRUE);
|
||||||
|
if (!*msg)
|
||||||
|
return QDF_STATUS_E_NOMEM;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Set the length of the message.
|
||||||
|
* The contribution from the HTC_HDR_ALIGNMENT_PADDING is added
|
||||||
|
* separately during the below call to qdf_nbuf_push_head.
|
||||||
|
* The contribution from the HTC header is added separately inside HTC.
|
||||||
|
*/
|
||||||
|
if (!qdf_nbuf_put_tail(*msg, HTT_VER_REQ_BYTES)) {
|
||||||
|
QDF_TRACE(QDF_MODULE_ID_TXRX, QDF_TRACE_LEVEL_ERROR,
|
||||||
|
"%s: Failed to expand head for HTT_H2T_MSG_TYPE_VERSION_REQ msg",
|
||||||
|
__func__);
|
||||||
|
return QDF_STATUS_E_FAILURE;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* fill in the message contents */
|
||||||
|
msg_word = (u_int32_t *)qdf_nbuf_data(*msg);
|
||||||
|
|
||||||
|
/* rewind beyond alignment pad to get to the HTC header reserved area */
|
||||||
|
qdf_nbuf_push_head(*msg, HTC_HDR_ALIGNMENT_PADDING);
|
||||||
|
|
||||||
|
*msg_word = 0;
|
||||||
|
HTT_H2T_MSG_TYPE_SET(*msg_word, HTT_H2T_MSG_TYPE_VERSION_REQ);
|
||||||
|
|
||||||
|
return QDF_STATUS_SUCCESS;
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef QCA_DP_TX_FW_METADATA_V2
|
||||||
|
/*
|
||||||
|
* dp_htt_h2t_add_tcl_metadata_ver_v2() - Add tcl_metadata verion V2
|
||||||
|
* @htt_soc: HTT SOC handle
|
||||||
|
* @msg: Pointer to nbuf
|
||||||
|
*
|
||||||
|
* Return: 0 on success; error code on failure
|
||||||
|
*/
|
||||||
|
static int dp_htt_h2t_add_tcl_metadata_ver_v2(struct htt_soc *soc,
|
||||||
|
qdf_nbuf_t *msg)
|
||||||
{
|
{
|
||||||
uint32_t *msg_word;
|
uint32_t *msg_word;
|
||||||
|
|
||||||
@@ -383,9 +429,9 @@ static int dp_htt_h2t_add_tcl_metadata_ver(struct htt_soc *soc, qdf_nbuf_t *msg)
|
|||||||
|
|
||||||
return QDF_STATUS_SUCCESS;
|
return QDF_STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
#else
|
|
||||||
/*
|
/*
|
||||||
* dp_htt_h2t_add_tcl_metadata_verg() - Add tcl_metadata verion
|
* dp_htt_h2t_add_tcl_metadata_ver() - Add tcl_metadata verion
|
||||||
* @htt_soc: HTT SOC handle
|
* @htt_soc: HTT SOC handle
|
||||||
* @msg: Pointer to nbuf
|
* @msg: Pointer to nbuf
|
||||||
*
|
*
|
||||||
@@ -393,39 +439,16 @@ static int dp_htt_h2t_add_tcl_metadata_ver(struct htt_soc *soc, qdf_nbuf_t *msg)
|
|||||||
*/
|
*/
|
||||||
static int dp_htt_h2t_add_tcl_metadata_ver(struct htt_soc *soc, qdf_nbuf_t *msg)
|
static int dp_htt_h2t_add_tcl_metadata_ver(struct htt_soc *soc, qdf_nbuf_t *msg)
|
||||||
{
|
{
|
||||||
uint32_t *msg_word;
|
/* Use tcl_metadata_v1 when NSS offload is enabled */
|
||||||
|
if (wlan_cfg_get_dp_soc_nss_cfg(soc->dp_soc->wlan_cfg_ctx))
|
||||||
*msg = qdf_nbuf_alloc(
|
return dp_htt_h2t_add_tcl_metadata_ver_v1(soc, msg);
|
||||||
soc->osdev,
|
else
|
||||||
HTT_MSG_BUF_SIZE(HTT_VER_REQ_BYTES),
|
return dp_htt_h2t_add_tcl_metadata_ver_v2(soc, msg);
|
||||||
/* reserve room for the HTC header */
|
|
||||||
HTC_HEADER_LEN + HTC_HDR_ALIGNMENT_PADDING, 4, TRUE);
|
|
||||||
if (!*msg)
|
|
||||||
return QDF_STATUS_E_NOMEM;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Set the length of the message.
|
|
||||||
* The contribution from the HTC_HDR_ALIGNMENT_PADDING is added
|
|
||||||
* separately during the below call to qdf_nbuf_push_head.
|
|
||||||
* The contribution from the HTC header is added separately inside HTC.
|
|
||||||
*/
|
|
||||||
if (!qdf_nbuf_put_tail(*msg, HTT_VER_REQ_BYTES)) {
|
|
||||||
QDF_TRACE(QDF_MODULE_ID_TXRX, QDF_TRACE_LEVEL_ERROR,
|
|
||||||
"%s: Failed to expand head for HTT_H2T_MSG_TYPE_VERSION_REQ msg",
|
|
||||||
__func__);
|
|
||||||
return QDF_STATUS_E_FAILURE;
|
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
/* fill in the message contents */
|
static int dp_htt_h2t_add_tcl_metadata_ver(struct htt_soc *soc, qdf_nbuf_t *msg)
|
||||||
msg_word = (u_int32_t *)qdf_nbuf_data(*msg);
|
{
|
||||||
|
return dp_htt_h2t_add_tcl_metadata_ver_v1(soc, msg);
|
||||||
/* rewind beyond alignment pad to get to the HTC header reserved area */
|
|
||||||
qdf_nbuf_push_head(*msg, HTC_HDR_ALIGNMENT_PADDING);
|
|
||||||
|
|
||||||
*msg_word = 0;
|
|
||||||
HTT_H2T_MSG_TYPE_SET(*msg_word, HTT_H2T_MSG_TYPE_VERSION_REQ);
|
|
||||||
|
|
||||||
return QDF_STATUS_SUCCESS;
|
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@@ -120,7 +120,7 @@ cdp_dump_flow_pool_info(struct cdp_soc_t *soc)
|
|||||||
#define TXCOMP_RING4_NUM WBM2SW_TXCOMP_RING4_NUM
|
#define TXCOMP_RING4_NUM WBM2SW_TXCOMP_RING4_NUM
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef WLAN_MCAST_MLO
|
#ifdef QCA_DP_TX_FW_METADATA_V2
|
||||||
#define DP_TX_TCL_METADATA_PDEV_ID_SET(_var, _val) \
|
#define DP_TX_TCL_METADATA_PDEV_ID_SET(_var, _val) \
|
||||||
HTT_TX_TCL_METADATA_V2_PDEV_ID_SET(_var, _val)
|
HTT_TX_TCL_METADATA_V2_PDEV_ID_SET(_var, _val)
|
||||||
#else
|
#else
|
||||||
|
@@ -69,7 +69,7 @@
|
|||||||
|
|
||||||
#define DP_RETRY_COUNT 7
|
#define DP_RETRY_COUNT 7
|
||||||
|
|
||||||
#ifdef WLAN_MCAST_MLO
|
#ifdef QCA_DP_TX_FW_METADATA_V2
|
||||||
#define DP_TX_TCL_METADATA_PDEV_ID_SET(_var, _val)\
|
#define DP_TX_TCL_METADATA_PDEV_ID_SET(_var, _val)\
|
||||||
HTT_TX_TCL_METADATA_V2_PDEV_ID_SET(_var, _val)
|
HTT_TX_TCL_METADATA_V2_PDEV_ID_SET(_var, _val)
|
||||||
#define DP_TX_TCL_METADATA_VALID_HTT_SET(_var, _val) \
|
#define DP_TX_TCL_METADATA_VALID_HTT_SET(_var, _val) \
|
||||||
|
Reference in New Issue
Block a user