qcacmn: Add extra check in mec event when replacing ast entry

Check if the ast_entry peer is same as the peer received
in MEC event before removing the wds entry. This check is
required for wds repeater scenarios. When a multicast packet
goes from station to the rootap via the repeater, a mec event
will be received in host but the entry should not be replaced.

Change-Id: Ia6fae9f08b411b481fc6d7c3f829bd127f92caec
This commit is contained in:
Nandha Kishore Easwaran 2018-11-30 15:02:20 +05:30 • committed by nshrivas
commit 8dd440d33c

View file

@ -588,10 +588,16 @@ int dp_peer_add_ast(struct dp_soc *soc,
/* Modify an already existing AST entry from type
* WDS to MEC on promption. This serves as a fix when
* backbone of interfaces are interchanged wherein
* wds entr becomes its own MEC.
* wds entr becomes its own MEC. The entry should be
* replaced only when the ast_entry peer matches the
* peer received in mec event. This additional check
* is needed in wds repeater cases where a multicast
* packet from station to the root via the repeater
* should not remove the wds entry.
*/
if ((ast_entry->type == CDP_TXRX_AST_TYPE_WDS) &&
(type == CDP_TXRX_AST_TYPE_MEC)) {
(type == CDP_TXRX_AST_TYPE_MEC) &&
(ast_entry->peer == peer)) {
ast_entry->is_active = FALSE;
dp_peer_del_ast(soc, ast_entry);
}