From b3ccd8f0926ecb72b4c96e05a8dd5af6eeff578f Mon Sep 17 00:00:00 2001 From: Vinayak Yadawad Date: Fri, 22 Sep 2023 14:55:51 +0530 Subject: [PATCH] BACKPORT: wifi: cfg80211: OWE DH IE handling offload Introduce new feature flags for OWE offload that driver can advertise to indicate kernel/application space to avoid DH IE handling. When this flag is advertised, the driver/device will take care of DH IE inclusion and processing of peer DH IE to generate PMK. Signed-off-by: Vinayak Yadawad Link: https://lore.kernel.org/r/f891cce4b52c939dfc6b71bb2f73e560e8cad287.1695374530.git.vinayak.yadawad@broadcom.com Signed-off-by: Johannes Berg Bug: 301410304 (cherry picked from commit 5482c0a28b2634e7a7d8ddaca7feac183e74b528) [chenpaul: use reserved fields instead of adding new one] Signed-off-by: Paul Chen Change-Id: I8322e53b74d995471411967aba846a2b712e5d85 --- include/uapi/linux/nl80211.h | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h index 8fc5fc92adde..f3af16ce1f64 100644 --- a/include/uapi/linux/nl80211.h +++ b/include/uapi/linux/nl80211.h @@ -334,6 +334,15 @@ * use %NL80211_CMD_START_AP or similar functions. */ +/** + * DOC: OWE DH IE handling offload + * + * By setting @NL80211_EXT_FEATURE_OWE_OFFLOAD flag, drivers can indicate + * kernel/application space to avoid DH IE handling. When this flag is + * advertised, the driver/device will take care of DH IE inclusion and + * processing of peer DH IE to generate PMK. + */ + /** * enum nl80211_commands - supported nl80211 commands * @@ -6434,6 +6443,12 @@ enum nl80211_feature_flags { * in authentication and deauthentication frames sent to unassociated peer * using @NL80211_CMD_FRAME. * + * @NL80211_EXT_FEATURE_OWE_OFFLOAD: Driver/Device wants to do OWE DH IE + * handling in station mode. + * + * @NL80211_EXT_FEATURE_OWE_OFFLOAD_AP: Driver/Device wants to do OWE DH IE + * handling in AP mode. + * * @NUM_NL80211_EXT_FEATURES: number of extended features. * @MAX_NL80211_EXT_FEATURES: highest extended feature index. */ @@ -6505,8 +6520,8 @@ enum nl80211_ext_feature_index { NL80211_EXT_FEATURE_PUNCT, NL80211_EXT_FEATURE_SECURE_NAN, NL80211_EXT_FEATURE_AUTH_AND_DEAUTH_RANDOM_TA, - NL80211_EXT_FEATURE_ANDROID_KABI_RESERVED_1, - NL80211_EXT_FEATURE_ANDROID_KABI_RESERVED_2, + NL80211_EXT_FEATURE_OWE_OFFLOAD, + NL80211_EXT_FEATURE_OWE_OFFLOAD_AP, NL80211_EXT_FEATURE_ANDROID_KABI_RESERVED_3, NL80211_EXT_FEATURE_ANDROID_KABI_RESERVED_4, NL80211_EXT_FEATURE_ANDROID_KABI_RESERVED_5,