aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/r8188eu/core/rtw_mlme_ext.c
diff options
context:
space:
mode:
authorMartin Kaiser <martin@kaiser.cx>2022-04-17 12:22:16 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-04-20 18:37:17 +0200
commit59e8d56f00a5a7635be11d4c4959de9458230553 (patch)
tree4d4cf77b5cbff3df5357ae7cf5a0842b7e66c68b /drivers/staging/r8188eu/core/rtw_mlme_ext.c
parentstaging: r8188eu: place constants in right side in a comparison (diff)
downloadlinux-dev-59e8d56f00a5a7635be11d4c4959de9458230553.tar.xz
linux-dev-59e8d56f00a5a7635be11d4c4959de9458230553.zip
staging: r8188eu: check receiver address only once
Check only once in mgt_dispatcher that the receiver address is the local address or the broadcast address. The second identical check can be removed. Signed-off-by: Martin Kaiser <martin@kaiser.cx> Link: https://lore.kernel.org/r/20220417102221.466524-2-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to '')
-rw-r--r--drivers/staging/r8188eu/core/rtw_mlme_ext.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/staging/r8188eu/core/rtw_mlme_ext.c b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
index fd343ea9f3ad..ebcdc4cf10f3 100644
--- a/drivers/staging/r8188eu/core/rtw_mlme_ext.c
+++ b/drivers/staging/r8188eu/core/rtw_mlme_ext.c
@@ -431,13 +431,8 @@ void mgt_dispatcher(struct adapter *padapter, struct recv_frame *precv_frame)
ptable->func = &OnAuthClient;
}
- if (ptable->func) {
- /* receive the frames that ra(a1) is my address or ra(a1) is bc address. */
- if (memcmp(hdr->addr1, myid(&padapter->eeprompriv), ETH_ALEN) &&
- !is_broadcast_ether_addr(hdr->addr1))
- return;
+ if (ptable->func)
ptable->func(padapter, precv_frame);
- }
}
static u32 p2p_listen_state_process(struct adapter *padapter, unsigned char *da)