diff options
author | Michael Straube <straube.linux@gmail.com> | 2021-08-23 14:01:03 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-08-26 12:23:12 +0200 |
commit | 2d4fe65101b5216838c1d92e6c39a150fc72c837 (patch) | |
tree | 08f983ebe219760f9feab5cb26117cee3a4b8728 | |
parent | d0624c3379a17b9c6c267378831cdaa60c0af835 (diff) |
staging: r8188eu: use is_multicast_ether_addr in core/rtw_security.c
Use is_multicast_ether_addr instead of custom macro IS_MCAST, all
buffers are properly aligned.
Acked-by: Phillip Potter <phil@philpotter.co.uk>
Signed-off-by: Michael Straube <straube.linux@gmail.com>
Link: https://lore.kernel.org/r/20210823120106.9633-6-straube.linux@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/r8188eu/core/rtw_security.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/staging/r8188eu/core/rtw_security.c b/drivers/staging/r8188eu/core/rtw_security.c index b9ab4b20ed8e..5aa893ab46e9 100644 --- a/drivers/staging/r8188eu/core/rtw_security.c +++ b/drivers/staging/r8188eu/core/rtw_security.c @@ -538,7 +538,7 @@ u32 rtw_tkip_encrypt(struct adapter *padapter, u8 *pxmitframe) stainfo = rtw_get_stainfo(&padapter->stapriv, &pattrib->ra[0]); if (stainfo) { - if (IS_MCAST(pattrib->ra)) + if (is_multicast_ether_addr(pattrib->ra)) prwskey = psecuritypriv->dot118021XGrpKey[psecuritypriv->dot118021XGrpKeyid].skey; else prwskey = &stainfo->dot118021x_UncstKey.skey[0]; @@ -608,7 +608,7 @@ u32 rtw_tkip_decrypt(struct adapter *padapter, u8 *precvframe) if (prxattrib->encrypt == _TKIP_) { stainfo = rtw_get_stainfo(&padapter->stapriv, &prxattrib->ta[0]); if (stainfo) { - if (IS_MCAST(prxattrib->ra)) { + if (is_multicast_ether_addr(prxattrib->ra)) { if (!psecuritypriv->binstallGrpkey) { res = _FAIL; DBG_88E("%s:rx bc/mc packets, but didn't install group key!!!!!!!!!!\n", __func__); @@ -1188,7 +1188,7 @@ u32 rtw_aes_encrypt(struct adapter *padapter, u8 *pxmitframe) stainfo = rtw_get_stainfo(&padapter->stapriv, &pattrib->ra[0]); if (stainfo) { - if (IS_MCAST(pattrib->ra)) + if (is_multicast_ether_addr(pattrib->ra)) prwskey = psecuritypriv->dot118021XGrpKey[psecuritypriv->dot118021XGrpKeyid].skey; else prwskey = &stainfo->dot118021x_UncstKey.skey[0]; @@ -1421,7 +1421,7 @@ u32 rtw_aes_decrypt(struct adapter *padapter, u8 *precvframe) if (prxattrib->encrypt == _AES_) { stainfo = rtw_get_stainfo(&padapter->stapriv, &prxattrib->ta[0]); if (stainfo) { - if (IS_MCAST(prxattrib->ra)) { + if (is_multicast_ether_addr(prxattrib->ra)) { /* in concurrent we should use sw descrypt in group key, so we remove this message */ if (!psecuritypriv->binstallGrpkey) { res = _FAIL; |