wifi: ath12k: fix mac id extraction when MSDU spillover in rx error path
authorKarthikeyan Periyasamy <quic_periyasa@quicinc.com>
Wed, 10 Apr 2024 14:14:55 +0000 (17:14 +0300)
committerKalle Valo <quic_kvalo@quicinc.com>
Tue, 16 Apr 2024 07:15:42 +0000 (10:15 +0300)
commitf351772c544bd20db63a61f20a70fb1fe3867000
tree3aca601f01f30974731a8d71f45c61c8ea8506c1
parent4f242b1d6996af14f98cb1093d26cdacd6a83ad7
wifi: ath12k: fix mac id extraction when MSDU spillover in rx error path

Currently, in the rx error data path, mac id is extracted from the
last 64bits of MSDU end description tag for each entry received in
the WBM error ring. Then, each entry will be updated into the MSDU
list for further processing. The extracted mac id is valid when a
single MSDU is not fragmented and received in the WBM error ring.

In scenarios where the size of a single MSDU received exceeds the
descriptor buffer size, resulting in fragmented or spillover MSDU
entries into the WBM error ring. In this case, the extracted mac id
from each spillover entry is invalid except the last spillover entry
of the MSDU. This invalid mac id leads to packet rejection.

To address this issue, check if the MSDU continuation flag is set,
then extract the valid mac id from the last spillover entry.
Propagate the valid mac id to all the spillover entries of the single
MSDU in the temporary MSDU list(scatter_msdu_list). Then, update this
into the MSDU list (msdu_list) for further processing.

Tested-on: QCN9274 hw2.0 PCI WLAN.WBE.1.0.1-00029-QCAHKSWPL_SILICONZ-1

Signed-off-by: Karthikeyan Periyasamy <quic_periyasa@quicinc.com>
Signed-off-by: Nithyanantham Paramasivam <quic_nithp@quicinc.com>
Acked-by: Jeff Johnson <quic_jjohnson@quicinc.com>
Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>
Link: https://msgid.link/20240404141538.1277258-1-quic_nithp@quicinc.com
drivers/net/wireless/ath/ath12k/dp_rx.c