qcacmn: Fix invalid sa_da_idx condition in RX path

Currenly this function, is_sa_da_idx_valid(), called from dp_rx_process
does not take MC/BC packets into account. For broadcast packets e.g.
DHCP offer packets from some APs, this check may fail (incorrectly).
Thus dropping the broadcast packet, when it should have been passed
on to the stack.

Fix is_sa_da_idx_valid function by taking MC/BC packets into account.

Change-Id: Ibbb34134e997e0d5394dfa654be84b9fa43434a3
CRs-Fixed: 2466839
此提交包含在:
Mohit Khanna
2019-06-13 18:32:50 -07:00
提交者 nshrivas
父節點 f3af8bb319
當前提交 3ba9372a50
共有 2 個檔案被更改,包括 5 行新增3 行删除

查看文件

@@ -1440,9 +1440,9 @@ static inline bool is_sa_da_idx_valid(struct dp_soc *soc,
if ((qdf_nbuf_is_sa_valid(nbuf) &&
(hal_rx_msdu_end_sa_idx_get(rx_tlv_hdr) >
wlan_cfg_get_max_ast_idx(soc->wlan_cfg_ctx))) ||
(qdf_nbuf_is_da_valid(nbuf) &&
(hal_rx_msdu_end_da_idx_get(soc->hal_soc,
rx_tlv_hdr) >
(!qdf_nbuf_is_da_mcbc(nbuf) &&
qdf_nbuf_is_da_valid(nbuf) &&
(hal_rx_msdu_end_da_idx_get(soc->hal_soc, rx_tlv_hdr) >
wlan_cfg_get_max_ast_idx(soc->wlan_cfg_ctx))))
return false;