qcacmn: Add hal_rx_encryption_info_valid API

Implement hal_rx_encryption_info API based
on the chipset as the macro to retrieve
sa_idx value is chipset dependent.

Change-Id: I0c48800dfa5628898c53f7a9271e517b6bfa3da7
CRs-Fixed: 2522133
Este commit está contenido en:
Venkata Sharath Chandra Manchala
2019-09-20 17:42:07 -07:00
cometido por nshrivas
padre f05b2ae5c2
commit c1a4c8b4fc
Se han modificado 14 ficheros con 149 adiciones y 17 borrados

Ver fichero

@@ -210,6 +210,23 @@ static uint32_t hal_rx_msdu_end_l3_hdr_padding_get_8074v1(uint8_t *buf)
return l3_header_padding;
}
/*
* @ hal_rx_encryption_info_valid_8074v1: Returns encryption type.
*
* @ buf: rx_tlv_hdr of the received packet
* @ Return: encryption type
*/
static uint32_t hal_rx_encryption_info_valid_8074v1(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;
struct rx_mpdu_info *mpdu_info = &mpdu_start->rx_mpdu_info_details;
uint32_t encryption_info = HAL_RX_MPDU_ENCRYPTION_INFO_VALID(mpdu_info);
return encryption_info;
}
struct hal_hw_txrx_ops qca8074_hal_hw_txrx_ops = {
/* init and setup */
@@ -258,6 +275,7 @@ struct hal_hw_txrx_ops qca8074_hal_hw_txrx_ops = {
hal_rx_msdu_end_sa_idx_get_8074v1,
hal_rx_desc_is_first_msdu_8074v1,
hal_rx_msdu_end_l3_hdr_padding_get_8074v1,
hal_rx_encryption_info_valid_8074v1,
};
struct hal_hw_srng_config hw_srng_table_8074[] = {

Ver fichero

@@ -53,6 +53,12 @@
RX_MSDU_END_5_L3_HEADER_PADDING_OFFSET)), \
RX_MSDU_END_5_L3_HEADER_PADDING_MASK, \
RX_MSDU_END_5_L3_HEADER_PADDING_LSB))
#define HAL_RX_MPDU_ENCRYPTION_INFO_VALID(_rx_mpdu_info) \
(_HAL_MS((*_OFFSET_TO_WORD_PTR(_rx_mpdu_info, \
RX_MPDU_INFO_2_FRAME_ENCRYPTION_INFO_VALID_OFFSET)), \
RX_MPDU_INFO_2_FRAME_ENCRYPTION_INFO_VALID_MASK, \
RX_MPDU_INFO_2_FRAME_ENCRYPTION_INFO_VALID_LSB))
/*
* hal_rx_msdu_start_nss_get_8074(): API to get the NSS
* Interval from rx_msdu_start