qcacmn: Add hal_rx_is_unicast API
Implement hal_rx_is_unicase API based on the chipset as the macro to retrieve is_unicast bit value is chipset dependent. Change-Id: I38807f478c295309adf2a07ce9010b1bc04c734e CRs-Fixed: 2522133
This commit is contained in:

committed by
nshrivas

parent
68d6f0d585
commit
5ddc518b2e
@@ -1216,26 +1216,17 @@ enum hal_rx_mpdu_info_sw_frame_group_id_type {
|
||||
|
||||
/**
|
||||
* hal_rx_is_unicast: check packet is unicast frame or not.
|
||||
*
|
||||
* @ buf: pointer to rx pkt TLV.
|
||||
* @hal_soc_hdl: hal_soc handle
|
||||
* @buf: pointer to rx pkt TLV.
|
||||
*
|
||||
* Return: true on unicast.
|
||||
*/
|
||||
static inline bool
|
||||
hal_rx_is_unicast(uint8_t *buf)
|
||||
hal_rx_is_unicast(hal_soc_handle_t hal_soc_hdl, uint8_t *buf)
|
||||
{
|
||||
struct rx_pkt_tlvs *pkt_tlvs = (struct rx_pkt_tlvs *)buf;
|
||||
struct rx_mpdu_start *mpdu_start =
|
||||
&pkt_tlvs->mpdu_start_tlv.rx_mpdu_start;
|
||||
uint32_t grp_id;
|
||||
uint8_t *rx_mpdu_info = (uint8_t *)&mpdu_start->rx_mpdu_info_details;
|
||||
struct hal_soc *hal_soc = (struct hal_soc *)hal_soc_hdl;
|
||||
|
||||
grp_id = (_HAL_MS((*_OFFSET_TO_WORD_PTR((rx_mpdu_info),
|
||||
RX_MPDU_INFO_0_SW_FRAME_GROUP_ID_OFFSET)),
|
||||
RX_MPDU_INFO_0_SW_FRAME_GROUP_ID_MASK,
|
||||
RX_MPDU_INFO_0_SW_FRAME_GROUP_ID_LSB));
|
||||
|
||||
return (HAL_MPDU_SW_FRAME_GROUP_UNICAST_DATA == grp_id) ? true : false;
|
||||
return hal_soc->ops->hal_rx_is_unicast(buf);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user