3
0
mirror of https://git.kernel.org/pub/scm/network/wireless/iwd.git synced 2024-12-22 13:02:44 +01:00

ie: use bitwise compare for IE_AKM_IS_FT

This has the same effect when passing a single AKM value, but also
handles AKM bit fields (e.g. ie_rsn_info->akm_suites)
This commit is contained in:
James Prestwood 2021-05-12 16:01:46 -07:00 committed by Denis Kenzior
parent 8e09c4a6fb
commit 9a3639f2fa

View File

@ -289,12 +289,12 @@ enum ie_rsn_akm_suite {
(akm == IE_RSN_AKM_SUITE_FT_OVER_SAE_SHA256))
#define IE_AKM_IS_FT(akm) \
((akm == IE_RSN_AKM_SUITE_FT_OVER_8021X) || \
(akm == IE_RSN_AKM_SUITE_FT_USING_PSK) || \
(akm == IE_RSN_AKM_SUITE_FT_OVER_SAE_SHA256) || \
(akm == IE_RSN_AKM_SUITE_FT_OVER_8021X_SHA384) || \
(akm == IE_RSN_AKM_SUITE_FT_OVER_FILS_SHA256) || \
(akm == IE_RSN_AKM_SUITE_FT_OVER_FILS_SHA384))
(akm & (IE_RSN_AKM_SUITE_FT_OVER_8021X | \
IE_RSN_AKM_SUITE_FT_USING_PSK | \
IE_RSN_AKM_SUITE_FT_OVER_SAE_SHA256 | \
IE_RSN_AKM_SUITE_FT_OVER_8021X_SHA384 | \
IE_RSN_AKM_SUITE_FT_OVER_FILS_SHA256 | \
IE_RSN_AKM_SUITE_FT_OVER_FILS_SHA384))
#define IE_AKM_IS_FILS(akm) \
((akm == IE_RSN_AKM_SUITE_FILS_SHA256) || \