qcacmn: Handle PPDU ID format message
This is a generic T2H message in which a target can specify bits and offsets to extract a parameter from PPDU-id. Use link-id bit and offset present in T2H message to extract hw link-id from PPDU-id on Tx completion. Change-Id: I64b7559e88b037e30f52ba0b75ab62349e469d20 CRs-Fixed: 3195432
This commit is contained in:

committed by
Madan Koyyalamudi

parent
83d3a9032e
commit
26dff6988a
@@ -3166,6 +3166,33 @@ dp_htt_rx_addba_handler(struct dp_soc *soc, uint16_t peer_id,
|
|||||||
peer_id, win_sz, tid, status);
|
peer_id, win_sz, tid, status);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* dp_htt_ppdu_id_fmt_handler() - PPDU ID Format handler
|
||||||
|
* @htt_soc: HTT SOC handle
|
||||||
|
* @msg_word: Pointer to payload
|
||||||
|
*
|
||||||
|
* Return: None
|
||||||
|
*/
|
||||||
|
static void
|
||||||
|
dp_htt_ppdu_id_fmt_handler(struct dp_soc *soc, uint32_t *msg_word)
|
||||||
|
{
|
||||||
|
uint8_t msg_type, valid, bits, offset;
|
||||||
|
|
||||||
|
msg_type = HTT_T2H_MSG_TYPE_GET(*msg_word);
|
||||||
|
|
||||||
|
msg_word += HTT_PPDU_ID_FMT_IND_LINK_ID_OFFSET;
|
||||||
|
valid = HTT_PPDU_ID_FMT_IND_VALID_GET_BITS31_16(*msg_word);
|
||||||
|
bits = HTT_PPDU_ID_FMT_IND_BITS_GET_BITS31_16(*msg_word);
|
||||||
|
offset = HTT_PPDU_ID_FMT_IND_OFFSET_GET_BITS31_16(*msg_word);
|
||||||
|
|
||||||
|
dp_info("link_id: valid %u bits %u offset %u", valid, bits, offset);
|
||||||
|
|
||||||
|
if (valid) {
|
||||||
|
soc->link_id_offset = offset;
|
||||||
|
soc->link_id_bits = bits;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* dp_htt_t2h_msg_handler() - Generic Target to host Msg/event handler
|
* dp_htt_t2h_msg_handler() - Generic Target to host Msg/event handler
|
||||||
* @context: Opaque context (HTT SOC handle)
|
* @context: Opaque context (HTT SOC handle)
|
||||||
@@ -3354,6 +3381,11 @@ static void dp_htt_t2h_msg_handler(void *context, HTC_PACKET *pkt)
|
|||||||
tid, win_sz);
|
tid, win_sz);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
case HTT_T2H_PPDU_ID_FMT_IND:
|
||||||
|
{
|
||||||
|
dp_htt_ppdu_id_fmt_handler(soc->dp_soc, msg_word);
|
||||||
|
break;
|
||||||
|
}
|
||||||
case HTT_T2H_MSG_TYPE_EXT_STATS_CONF:
|
case HTT_T2H_MSG_TYPE_EXT_STATS_CONF:
|
||||||
{
|
{
|
||||||
dp_txrx_fw_stats_handler(soc->dp_soc, htt_t2h_msg);
|
dp_txrx_fw_stats_handler(soc->dp_soc, htt_t2h_msg);
|
||||||
|
@@ -2382,6 +2382,9 @@ struct dp_soc {
|
|||||||
#ifdef DP_UMAC_HW_RESET_SUPPORT
|
#ifdef DP_UMAC_HW_RESET_SUPPORT
|
||||||
struct dp_soc_umac_reset_ctx umac_reset_ctx;
|
struct dp_soc_umac_reset_ctx umac_reset_ctx;
|
||||||
#endif
|
#endif
|
||||||
|
/* PPDU to link_id mapping parameters */
|
||||||
|
uint8_t link_id_offset;
|
||||||
|
uint8_t link_id_bits;
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifdef IPA_OFFLOAD
|
#ifdef IPA_OFFLOAD
|
||||||
|
Reference in New Issue
Block a user