qcacmn: Separate GetFrameControl API's for LI chipsets

For 802.11 Fragmented frames, currently there is a
generic GetFrameControl API from RX TLV for all Li
Chipsets. As the offset for frame control in RX TLV
is different for QCN9000 and QCA8074V2, reading the
frame control with generic API gives wrong frame
control value. The Offset is different as the size
of RX_MSDU_START struct is 8DWORDS in QCA8074v2 while
it is 9DWORDS in QCA9000. In the reo reinject path
the destination queue descriptor address read from ring
descriptor address is Invalid

Fix is Separating out the GetFrameControl API from
generic API to Chip specific API. Also fix the reading
of queue descriptor address.

CRs-Fixed: 3280809
change-Id: Ifc5eca31b9b7e70c84ca455d56a58c27601cd51d
This commit is contained in:
Kenvish Butani
2022-08-29 07:34:05 -07:00
committed by Madan Koyyalamudi
parent 1a5b0d838e
commit a16d867018
12 changed files with 133 additions and 21 deletions

View File

@@ -400,6 +400,25 @@ static uint8_t hal_rx_get_mpdu_frame_control_valid_8074v2(uint8_t *buf)
return HAL_RX_MPDU_GET_FRAME_CONTROL_VALID(rx_mpdu_info);
}
/**
* hal_rx_get_mpdu_frame_control_field_8074v2(): Function to
* retrieve frame control field
*
* @nbuf: Network buffer
* Returns: value of frame control field
*
*/
static uint16_t hal_rx_get_mpdu_frame_control_field_8074v2(uint8_t *buf)
{
struct rx_pkt_tlvs *pkt_tlvs = hal_rx_get_pkt_tlvs(buf);
struct rx_mpdu_info *rx_mpdu_info = hal_rx_get_mpdu_info(pkt_tlvs);
uint16_t frame_ctrl = 0;
frame_ctrl = HAL_RX_MPDU_GET_FRAME_CONTROL_FIELD(rx_mpdu_info);
return frame_ctrl;
}
/*
* hal_rx_mpdu_get_addr1_8074v2(): API to check get address1 of the mpdu
*
@@ -1328,6 +1347,8 @@ static void hal_hw_txrx_ops_attach_qca8074v2(struct hal_soc *hal_soc)
hal_soc->ops->hal_rx_mpdu_get_fr_ds = hal_rx_mpdu_get_fr_ds_8074v2;
hal_soc->ops->hal_rx_get_mpdu_frame_control_valid =
hal_rx_get_mpdu_frame_control_valid_8074v2;
hal_soc->ops->hal_rx_get_frame_ctrl_field =
hal_rx_get_mpdu_frame_control_field_8074v2;
hal_soc->ops->hal_rx_mpdu_get_addr1 = hal_rx_mpdu_get_addr1_8074v2;
hal_soc->ops->hal_rx_mpdu_get_addr2 = hal_rx_mpdu_get_addr2_8074v2;
hal_soc->ops->hal_rx_mpdu_get_addr3 = hal_rx_mpdu_get_addr3_8074v2;