Linux wireless drivers development
 help / color / mirror / Atom feed
* [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events
@ 2026-08-04  3:04 Jason Huang
  2026-08-04  3:04 ` [PATCH 2/7] wifi: nl80211: add roam offload extended feature Jason Huang
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Jason Huang @ 2026-08-04  3:04 UTC (permalink / raw)
  To: linux-wireless
  Cc: Jason Huang, Chung-Hsien Hsu, Chi-hsien Lin, Johannes Berg,
	linux-kernel

From: Jason Huang <jason.huang2@infineon.com>

Drivers that offload the 802.1X/FT key exchange can know that
the link is ready for data traffic when reporting a successful
connect or roam event. Carry that state through cfg80211 and
include NL80211_ATTR_PORT_AUTHORIZED in the corresponding nl80211
notification when the driver provides it.

This lets userspace avoid restarting authentication state machines
after firmware has already completed the security exchange during
offloaded roaming.

Assisted-by: GitHub Copilot CLI:gpt-5.5
Signed-off-by: Chung-Hsien Hsu <Chung-Hsien.Hsu@infineon.com>
Signed-off-by: Chi-hsien Lin <chi-hsien.lin@cypress.com>
Signed-off-by: Jason Huang <jason.huang2@infineon.com>
---
 include/net/cfg80211.h       | 6 ++++++
 include/uapi/linux/nl80211.h | 4 +++-
 net/wireless/nl80211.c       | 6 +++++-
 net/wireless/sme.c           | 2 ++
 4 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 97c16d4ff127..7f576bb7325c 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -9103,6 +9103,8 @@ struct cfg80211_fils_resp_params {
  * @assoc_encrypted: The driver should set this flag to indicate that the
  *	(Re)Association Request/Response frames are transmitted encrypted over
  *	the air.
+ * @authorized: Indicates whether the connection is ready to transport data
+ *	packets.
  */
 struct cfg80211_connect_resp_params {
 	int status;
@@ -9113,6 +9115,7 @@ struct cfg80211_connect_resp_params {
 	struct cfg80211_fils_resp_params fils;
 	enum nl80211_timeout_reason timeout_reason;
 	bool assoc_encrypted;
+	bool authorized;
 
 	const u8 *ap_mld_addr;
 	u16 valid_links;
@@ -9281,6 +9284,8 @@ cfg80211_connect_timeout(struct net_device *dev, const u8 *bssid,
  * @links.bss: For MLO roaming, entry of new bss to which STA link got
  *	roamed. For non-MLO roaming, links[0].bss points to entry of bss to
  *	which STA got roamed (may be %NULL if %links.bssid is set)
+ * @authorized: Indicates whether the new connection is ready to transport data
+ *	packets.
  */
 struct cfg80211_roam_info {
 	const u8 *req_ie;
@@ -9297,6 +9302,7 @@ struct cfg80211_roam_info {
 		struct ieee80211_channel *channel;
 		struct cfg80211_bss *bss;
 	} links[IEEE80211_MLD_MAX_NUM_LINKS];
+	bool authorized;
 };
 
 /**
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 020387d76412..66b4cfd8de86 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -2705,7 +2705,9 @@ enum nl80211_commands {
  *	in %NL80211_CMD_CONNECT to indicate that for 802.1X authentication it
  *	wants to use the supported offload of the 4-way handshake.
  * @NL80211_ATTR_PMKR0_NAME: PMK-R0 Name for offloaded FT.
- * @NL80211_ATTR_PORT_AUTHORIZED: (reserved)
+ * @NL80211_ATTR_PORT_AUTHORIZED: flag attribute used in %NL80211_CMD_CONNECT
+ *	or %NL80211_CMD_ROAM notifications to indicate that 802.1X
+ *	authentication was done by the driver or is not needed.
  *
  * @NL80211_ATTR_EXTERNAL_AUTH_ACTION: Identify the requested external
  *     authentication operation (u32 attribute with an
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 44f2bad08670..55161ddb56b4 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -21198,6 +21198,8 @@ void nl80211_send_connect_result(struct cfg80211_registered_device *rdev,
 	     (nla_put_flag(msg, NL80211_ATTR_TIMED_OUT) ||
 	      nla_put_u32(msg, NL80211_ATTR_TIMEOUT_REASON,
 			  cr->timeout_reason))) ||
+	    (cr->authorized &&
+	     nla_put_flag(msg, NL80211_ATTR_PORT_AUTHORIZED)) ||
 	    (cr->req_ie &&
 	     nla_put(msg, NL80211_ATTR_REQ_IE, cr->req_ie_len, cr->req_ie)) ||
 	    (cr->resp_ie &&
@@ -21321,7 +21323,9 @@ void nl80211_send_roamed(struct cfg80211_registered_device *rdev,
 	    (info->fils.pmk &&
 	     nla_put(msg, NL80211_ATTR_PMK, info->fils.pmk_len, info->fils.pmk)) ||
 	    (info->fils.pmkid &&
-	     nla_put(msg, NL80211_ATTR_PMKID, WLAN_PMKID_LEN, info->fils.pmkid)))
+	     nla_put(msg, NL80211_ATTR_PMKID, WLAN_PMKID_LEN, info->fils.pmkid)) ||
+	    (info->authorized &&
+	     nla_put_flag(msg, NL80211_ATTR_PORT_AUTHORIZED)))
 		goto nla_put_failure;
 
 	if (info->valid_links) {
diff --git a/net/wireless/sme.c b/net/wireless/sme.c
index 2a719b5c487e..974e79f57392 100644
--- a/net/wireless/sme.c
+++ b/net/wireless/sme.c
@@ -1067,6 +1067,7 @@ void cfg80211_connect_done(struct net_device *dev,
 	ev->cr.status = params->status;
 	ev->cr.timeout_reason = params->timeout_reason;
 	ev->cr.assoc_encrypted = params->assoc_encrypted;
+	ev->cr.authorized = params->authorized;
 
 	spin_lock_irqsave(&wdev->event_lock, flags);
 	list_add_tail(&ev->list, &wdev->event_list);
@@ -1253,6 +1254,7 @@ void cfg80211_roamed(struct net_device *dev, struct cfg80211_roam_info *info,
 		next += ETH_ALEN;
 	}
 	ev->rm.valid_links = info->valid_links;
+	ev->rm.authorized = info->authorized;
 	for_each_valid_link(info, link) {
 		ev->rm.links[link].bss = info->links[link].bss;
 
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH 2/7] wifi: nl80211: add roam offload extended feature
  2026-08-04  3:04 [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events Jason Huang
@ 2026-08-04  3:04 ` Jason Huang
  2026-08-04  6:43 ` [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events Johannes Berg
  2026-08-05 11:01 ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jason Huang
  2 siblings, 0 replies; 10+ messages in thread
From: Jason Huang @ 2026-08-04  3:04 UTC (permalink / raw)
  To: linux-wireless; +Cc: Jason Huang, Carella Chen, Johannes Berg, linux-kernel

From: Jason Huang <jason.huang2@infineon.com>

Drivers can offload FT or OKC roaming without necessarily
advertising full 802.1X 4-way handshake offload. Add an extended
feature bit for that capability and allow PMK configuration when it is
present.

This gives userspace a way to provide PMK or PMK-R0 material needed
by firmware roaming implementations while keeping the existing 4-way
handshake offload capability unchanged.

Assisted-by: GitHub Copilot CLI:gpt-5.5
Signed-off-by: Carella Chen <carella.chen@infineon.com>
Signed-off-by: Jason Huang <jason.huang2@infineon.com>
---
 include/uapi/linux/nl80211.h | 4 ++++
 net/wireless/nl80211.c       | 4 +++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 66b4cfd8de86..2b96a18def9b 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -7112,6 +7112,9 @@ enum nl80211_feature_flags {
  * @NL80211_EXT_FEATURE_PROBE_AP: Driver supports probing the associated AP
  *	in STA mode using @NL80211_CMD_PROBE_PEER.
  *
+ * @NL80211_EXT_FEATURE_ROAM_OFFLOAD: Driver supports Fast Transition or
+ *	Opportunistic Key Caching roaming offload in station mode.
+ *
  * @NUM_NL80211_EXT_FEATURES: number of extended features.
  * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
  */
@@ -7194,6 +7197,7 @@ enum nl80211_ext_feature_index {
 	NL80211_EXT_FEATURE_ROC_ADDR_FILTER,
 	NL80211_EXT_FEATURE_SET_KEY_LTF_SEED,
 	NL80211_EXT_FEATURE_PROBE_AP,
+	NL80211_EXT_FEATURE_ROAM_OFFLOAD,
 
 	/* add new features before the definition below */
 	NUM_NL80211_EXT_FEATURES,
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 55161ddb56b4..7dbd4caf2609 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -18443,7 +18443,9 @@ static int nl80211_set_pmk(struct sk_buff *skb, struct genl_info *info)
 		return -EOPNOTSUPP;
 
 	if (!wiphy_ext_feature_isset(&rdev->wiphy,
-				     NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X))
+				     NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X) &&
+	    !wiphy_ext_feature_isset(&rdev->wiphy,
+				     NL80211_EXT_FEATURE_ROAM_OFFLOAD))
 		return -EOPNOTSUPP;
 
 	if (!info->attrs[NL80211_ATTR_MAC] || !info->attrs[NL80211_ATTR_PMK])
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events
  2026-08-04  3:04 [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events Jason Huang
  2026-08-04  3:04 ` [PATCH 2/7] wifi: nl80211: add roam offload extended feature Jason Huang
@ 2026-08-04  6:43 ` Johannes Berg
  2026-08-05 11:01 ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jason Huang
  2 siblings, 0 replies; 10+ messages in thread
From: Johannes Berg @ 2026-08-04  6:43 UTC (permalink / raw)
  To: Jason Huang, linux-wireless; +Cc: Chung-Hsien Hsu, Chi-hsien Lin, linux-kernel

Something looks like it got lost - I only have 1 and 2 of 7.
Please resend either all of the changes or as a shorter series so nipa
will process it.

johannes

^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH v2 0/2] wifi: support authorized roaming offload reporting
@ 2026-08-05 10:57 Jason Huang
  0 siblings, 0 replies; 10+ messages in thread
From: Jason Huang @ 2026-08-05 10:57 UTC (permalink / raw)
  To: linux-wireless; +Cc: wlan-kernel-dev-list, Jason Huang

From: Jason Huang <jason.huang2@infineon.com>

This is a shorter resend of the cfg80211/nl80211 API patches from the
previous 7-patch series. The earlier submission appears to have been
partially processed, so resend only these two prerequisite patches as a
standalone series.

The series lets drivers report connect and roam events that are already
authorized by firmware offload, and adds a roam offload extended feature
so userspace can provide PMK material for FT/OKC roaming offload without
requiring full 802.1X 4-way handshake offload support.

Changes in v2:
- Resend as a shorter 2-patch series for nipa processing.
- No code changes

Jason Huang (2):
  wifi: cfg80211: report authorized connect and roam events
  wifi: nl80211: add roam offload extended feature

 include/net/cfg80211.h       |  6 ++++++
 include/uapi/linux/nl80211.h |  8 +++++++-
 net/wireless/nl80211.c       | 10 ++++++++--
 net/wireless/sme.c           |  2 ++
 4 files changed, 23 insertions(+), 3 deletions(-)


base-commit: 6c5fc504d0d6934132637aa3db4b9b58148eaa78
-- 
2.25.1


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH v2 0/2] wifi: support authorized roaming offload reporting
  2026-08-04  3:04 [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events Jason Huang
  2026-08-04  3:04 ` [PATCH 2/7] wifi: nl80211: add roam offload extended feature Jason Huang
  2026-08-04  6:43 ` [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events Johannes Berg
@ 2026-08-05 11:01 ` Jason Huang
  2026-08-05 11:01   ` [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events Jason Huang
                     ` (2 more replies)
  2 siblings, 3 replies; 10+ messages in thread
From: Jason Huang @ 2026-08-05 11:01 UTC (permalink / raw)
  To: linux-wireless; +Cc: wlan-kernel-dev-list, Jason Huang

From: Jason Huang <jason.huang2@infineon.com>

This is a shorter resend of the cfg80211/nl80211 API patches from the
previous 7-patch series. The earlier submission appears to have been
partially processed, so resend only these two prerequisite patches as a
standalone series.

The series lets drivers report connect and roam events that are already
authorized by firmware offload, and adds a roam offload extended feature
so userspace can provide PMK material for FT/OKC roaming offload without
requiring full 802.1X 4-way handshake offload support.

Changes in v2:
- Resend as a shorter 2-patch series for nipa processing.
- No code changes

Jason Huang (2):
  wifi: cfg80211: report authorized connect and roam events
  wifi: nl80211: add roam offload extended feature

 include/net/cfg80211.h       |  6 ++++++
 include/uapi/linux/nl80211.h |  8 +++++++-
 net/wireless/nl80211.c       | 10 ++++++++--
 net/wireless/sme.c           |  2 ++
 4 files changed, 23 insertions(+), 3 deletions(-)


base-commit: 6c5fc504d0d6934132637aa3db4b9b58148eaa78
-- 
2.25.1


^ permalink raw reply	[flat|nested] 10+ messages in thread

* [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events
  2026-08-05 11:01 ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jason Huang
@ 2026-08-05 11:01   ` Jason Huang
  2026-08-05 22:50     ` Jeff Johnson
  2026-08-05 11:01   ` [PATCH v2 2/2] wifi: nl80211: add roam offload extended feature Jason Huang
  2026-08-05 22:22   ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jeff Johnson
  2 siblings, 1 reply; 10+ messages in thread
From: Jason Huang @ 2026-08-05 11:01 UTC (permalink / raw)
  To: linux-wireless
  Cc: wlan-kernel-dev-list, Jason Huang, Chung-Hsien Hsu, Chi-hsien Lin,
	Johannes Berg, linux-kernel

From: Jason Huang <jason.huang2@infineon.com>

Drivers that offload the 802.1X/FT key exchange can know that
the link is ready for data traffic when reporting a successful
connect or roam event. Carry that state through cfg80211 and
include NL80211_ATTR_PORT_AUTHORIZED in the corresponding nl80211
notification when the driver provides it.

This lets userspace avoid restarting authentication state machines
after firmware has already completed the security exchange during
offloaded roaming.

Assisted-by: GitHub Copilot CLI:gpt-5.5
Signed-off-by: Chung-Hsien Hsu <Chung-Hsien.Hsu@infineon.com>
Signed-off-by: Chi-hsien Lin <chi-hsien.lin@cypress.com>
Signed-off-by: Jason Huang <jason.huang2@infineon.com>
---
 include/net/cfg80211.h       | 6 ++++++
 include/uapi/linux/nl80211.h | 4 +++-
 net/wireless/nl80211.c       | 6 +++++-
 net/wireless/sme.c           | 2 ++
 4 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 97c16d4ff127..7f576bb7325c 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -9103,6 +9103,8 @@ struct cfg80211_fils_resp_params {
  * @assoc_encrypted: The driver should set this flag to indicate that the
  *	(Re)Association Request/Response frames are transmitted encrypted over
  *	the air.
+ * @authorized: Indicates whether the connection is ready to transport data
+ *	packets.
  */
 struct cfg80211_connect_resp_params {
 	int status;
@@ -9113,6 +9115,7 @@ struct cfg80211_connect_resp_params {
 	struct cfg80211_fils_resp_params fils;
 	enum nl80211_timeout_reason timeout_reason;
 	bool assoc_encrypted;
+	bool authorized;
 
 	const u8 *ap_mld_addr;
 	u16 valid_links;
@@ -9281,6 +9284,8 @@ cfg80211_connect_timeout(struct net_device *dev, const u8 *bssid,
  * @links.bss: For MLO roaming, entry of new bss to which STA link got
  *	roamed. For non-MLO roaming, links[0].bss points to entry of bss to
  *	which STA got roamed (may be %NULL if %links.bssid is set)
+ * @authorized: Indicates whether the new connection is ready to transport data
+ *	packets.
  */
 struct cfg80211_roam_info {
 	const u8 *req_ie;
@@ -9297,6 +9302,7 @@ struct cfg80211_roam_info {
 		struct ieee80211_channel *channel;
 		struct cfg80211_bss *bss;
 	} links[IEEE80211_MLD_MAX_NUM_LINKS];
+	bool authorized;
 };
 
 /**
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 020387d76412..66b4cfd8de86 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -2705,7 +2705,9 @@ enum nl80211_commands {
  *	in %NL80211_CMD_CONNECT to indicate that for 802.1X authentication it
  *	wants to use the supported offload of the 4-way handshake.
  * @NL80211_ATTR_PMKR0_NAME: PMK-R0 Name for offloaded FT.
- * @NL80211_ATTR_PORT_AUTHORIZED: (reserved)
+ * @NL80211_ATTR_PORT_AUTHORIZED: flag attribute used in %NL80211_CMD_CONNECT
+ *	or %NL80211_CMD_ROAM notifications to indicate that 802.1X
+ *	authentication was done by the driver or is not needed.
  *
  * @NL80211_ATTR_EXTERNAL_AUTH_ACTION: Identify the requested external
  *     authentication operation (u32 attribute with an
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 44f2bad08670..55161ddb56b4 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -21198,6 +21198,8 @@ void nl80211_send_connect_result(struct cfg80211_registered_device *rdev,
 	     (nla_put_flag(msg, NL80211_ATTR_TIMED_OUT) ||
 	      nla_put_u32(msg, NL80211_ATTR_TIMEOUT_REASON,
 			  cr->timeout_reason))) ||
+	    (cr->authorized &&
+	     nla_put_flag(msg, NL80211_ATTR_PORT_AUTHORIZED)) ||
 	    (cr->req_ie &&
 	     nla_put(msg, NL80211_ATTR_REQ_IE, cr->req_ie_len, cr->req_ie)) ||
 	    (cr->resp_ie &&
@@ -21321,7 +21323,9 @@ void nl80211_send_roamed(struct cfg80211_registered_device *rdev,
 	    (info->fils.pmk &&
 	     nla_put(msg, NL80211_ATTR_PMK, info->fils.pmk_len, info->fils.pmk)) ||
 	    (info->fils.pmkid &&
-	     nla_put(msg, NL80211_ATTR_PMKID, WLAN_PMKID_LEN, info->fils.pmkid)))
+	     nla_put(msg, NL80211_ATTR_PMKID, WLAN_PMKID_LEN, info->fils.pmkid)) ||
+	    (info->authorized &&
+	     nla_put_flag(msg, NL80211_ATTR_PORT_AUTHORIZED)))
 		goto nla_put_failure;
 
 	if (info->valid_links) {
diff --git a/net/wireless/sme.c b/net/wireless/sme.c
index 2a719b5c487e..974e79f57392 100644
--- a/net/wireless/sme.c
+++ b/net/wireless/sme.c
@@ -1067,6 +1067,7 @@ void cfg80211_connect_done(struct net_device *dev,
 	ev->cr.status = params->status;
 	ev->cr.timeout_reason = params->timeout_reason;
 	ev->cr.assoc_encrypted = params->assoc_encrypted;
+	ev->cr.authorized = params->authorized;
 
 	spin_lock_irqsave(&wdev->event_lock, flags);
 	list_add_tail(&ev->list, &wdev->event_list);
@@ -1253,6 +1254,7 @@ void cfg80211_roamed(struct net_device *dev, struct cfg80211_roam_info *info,
 		next += ETH_ALEN;
 	}
 	ev->rm.valid_links = info->valid_links;
+	ev->rm.authorized = info->authorized;
 	for_each_valid_link(info, link) {
 		ev->rm.links[link].bss = info->links[link].bss;
 
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [PATCH v2 2/2] wifi: nl80211: add roam offload extended feature
  2026-08-05 11:01 ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jason Huang
  2026-08-05 11:01   ` [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events Jason Huang
@ 2026-08-05 11:01   ` Jason Huang
  2026-08-05 22:22   ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jeff Johnson
  2 siblings, 0 replies; 10+ messages in thread
From: Jason Huang @ 2026-08-05 11:01 UTC (permalink / raw)
  To: linux-wireless
  Cc: wlan-kernel-dev-list, Jason Huang, Carella Chen, Johannes Berg,
	linux-kernel

From: Jason Huang <jason.huang2@infineon.com>

Drivers can offload FT or OKC roaming without necessarily
advertising full 802.1X 4-way handshake offload. Add an extended
feature bit for that capability and allow PMK configuration when it is
present.

This gives userspace a way to provide PMK or PMK-R0 material needed
by firmware roaming implementations while keeping the existing 4-way
handshake offload capability unchanged.

Assisted-by: GitHub Copilot CLI:gpt-5.5
Signed-off-by: Carella Chen <carella.chen@infineon.com>
Signed-off-by: Jason Huang <jason.huang2@infineon.com>
---
 include/uapi/linux/nl80211.h | 4 ++++
 net/wireless/nl80211.c       | 4 +++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index 66b4cfd8de86..2b96a18def9b 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -7112,6 +7112,9 @@ enum nl80211_feature_flags {
  * @NL80211_EXT_FEATURE_PROBE_AP: Driver supports probing the associated AP
  *	in STA mode using @NL80211_CMD_PROBE_PEER.
  *
+ * @NL80211_EXT_FEATURE_ROAM_OFFLOAD: Driver supports Fast Transition or
+ *	Opportunistic Key Caching roaming offload in station mode.
+ *
  * @NUM_NL80211_EXT_FEATURES: number of extended features.
  * @MAX_NL80211_EXT_FEATURES: highest extended feature index.
  */
@@ -7194,6 +7197,7 @@ enum nl80211_ext_feature_index {
 	NL80211_EXT_FEATURE_ROC_ADDR_FILTER,
 	NL80211_EXT_FEATURE_SET_KEY_LTF_SEED,
 	NL80211_EXT_FEATURE_PROBE_AP,
+	NL80211_EXT_FEATURE_ROAM_OFFLOAD,
 
 	/* add new features before the definition below */
 	NUM_NL80211_EXT_FEATURES,
diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index 55161ddb56b4..7dbd4caf2609 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -18443,7 +18443,9 @@ static int nl80211_set_pmk(struct sk_buff *skb, struct genl_info *info)
 		return -EOPNOTSUPP;
 
 	if (!wiphy_ext_feature_isset(&rdev->wiphy,
-				     NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X))
+				     NL80211_EXT_FEATURE_4WAY_HANDSHAKE_STA_1X) &&
+	    !wiphy_ext_feature_isset(&rdev->wiphy,
+				     NL80211_EXT_FEATURE_ROAM_OFFLOAD))
 		return -EOPNOTSUPP;
 
 	if (!info->attrs[NL80211_ATTR_MAC] || !info->attrs[NL80211_ATTR_PMK])
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [PATCH v2 0/2] wifi: support authorized roaming offload reporting
  2026-08-05 11:01 ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jason Huang
  2026-08-05 11:01   ` [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events Jason Huang
  2026-08-05 11:01   ` [PATCH v2 2/2] wifi: nl80211: add roam offload extended feature Jason Huang
@ 2026-08-05 22:22   ` Jeff Johnson
  2 siblings, 0 replies; 10+ messages in thread
From: Jeff Johnson @ 2026-08-05 22:22 UTC (permalink / raw)
  To: Jason Huang, linux-wireless; +Cc: wlan-kernel-dev-list

On 8/5/2026 4:01 AM, Jason Huang wrote:
> From: Jason Huang <jason.huang2@infineon.com>
> 
> This is a shorter resend of the cfg80211/nl80211 API patches from the
> previous 7-patch series. The earlier submission appears to have been
> partially processed, so resend only these two prerequisite patches as a
> standalone series.
> 
> The series lets drivers report connect and roam events that are already
> authorized by firmware offload, and adds a roam offload extended feature
> so userspace can provide PMK material for FT/OKC roaming offload without
> requiring full 802.1X 4-way handshake offload support.
> 
> Changes in v2:
> - Resend as a shorter 2-patch series for nipa processing.
> - No code changes
> 
> Jason Huang (2):
>   wifi: cfg80211: report authorized connect and roam events
>   wifi: nl80211: add roam offload extended feature
> 
>  include/net/cfg80211.h       |  6 ++++++
>  include/uapi/linux/nl80211.h |  8 +++++++-
>  net/wireless/nl80211.c       | 10 ++++++++--
>  net/wireless/sme.c           |  2 ++
>  4 files changed, 23 insertions(+), 3 deletions(-)
> 
> 
> base-commit: 6c5fc504d0d6934132637aa3db4b9b58148eaa78

You need to figure out your patch posting.

You posted a v2 cover letter as a separate thread (which is correct), but
without the two actual patches.
https://lore.kernel.org/all/20260805105716.35643-1-Jason.Huang2@infineon.com/

You then posted a v2 cover letter with the 2 patches, but as a reply to the V1
which is not correct. The new version should have been a separate thread.
https://lore.kernel.org/all/20260805110116.35884-1-Jason.Huang2@infineon.com/
(has In-Reply-To: <20260804030450.232028-1-Jason.Huang2@infineon.com>)

If you are new to posting then I strongly suggest using 'b4' to post patches
since it takes care of almost all of these details for you.

/jeff

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events
  2026-08-05 11:01   ` [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events Jason Huang
@ 2026-08-05 22:50     ` Jeff Johnson
  2026-08-06  4:03       ` HungTsung Huang
  0 siblings, 1 reply; 10+ messages in thread
From: Jeff Johnson @ 2026-08-05 22:50 UTC (permalink / raw)
  To: Jason Huang, linux-wireless
  Cc: wlan-kernel-dev-list, Chung-Hsien Hsu, Chi-hsien Lin,
	Johannes Berg, linux-kernel

On 8/5/2026 4:01 AM, Jason Huang wrote:
> From: Jason Huang <jason.huang2@infineon.com>
> 
> Drivers that offload the 802.1X/FT key exchange can know that
> the link is ready for data traffic when reporting a successful
> connect or roam event. Carry that state through cfg80211 and
> include NL80211_ATTR_PORT_AUTHORIZED in the corresponding nl80211
> notification when the driver provides it.
> 
> This lets userspace avoid restarting authentication state machines
> after firmware has already completed the security exchange during
> offloaded roaming.
> 
> Assisted-by: GitHub Copilot CLI:gpt-5.5
> Signed-off-by: Chung-Hsien Hsu <Chung-Hsien.Hsu@infineon.com>
> Signed-off-by: Chi-hsien Lin <chi-hsien.lin@cypress.com>

Jason,
why are the above signing off the patch if you are the author?

> Signed-off-by: Jason Huang <jason.huang2@infineon.com>
> ---
>  include/net/cfg80211.h       | 6 ++++++
>  include/uapi/linux/nl80211.h | 4 +++-
>  net/wireless/nl80211.c       | 6 +++++-
>  net/wireless/sme.c           | 2 ++
>  4 files changed, 16 insertions(+), 2 deletions(-)
> 
> diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
> index 97c16d4ff127..7f576bb7325c 100644
> --- a/include/net/cfg80211.h
> +++ b/include/net/cfg80211.h
> @@ -9103,6 +9103,8 @@ struct cfg80211_fils_resp_params {
>   * @assoc_encrypted: The driver should set this flag to indicate that the
>   *	(Re)Association Request/Response frames are transmitted encrypted over
>   *	the air.
> + * @authorized: Indicates whether the connection is ready to transport data
> + *	packets.
>   */
>  struct cfg80211_connect_resp_params {
>  	int status;
> @@ -9113,6 +9115,7 @@ struct cfg80211_connect_resp_params {
>  	struct cfg80211_fils_resp_params fils;
>  	enum nl80211_timeout_reason timeout_reason;
>  	bool assoc_encrypted;
> +	bool authorized;
>  
>  	const u8 *ap_mld_addr;
>  	u16 valid_links;
> @@ -9281,6 +9284,8 @@ cfg80211_connect_timeout(struct net_device *dev, const u8 *bssid,
>   * @links.bss: For MLO roaming, entry of new bss to which STA link got
>   *	roamed. For non-MLO roaming, links[0].bss points to entry of bss to
>   *	which STA got roamed (may be %NULL if %links.bssid is set)
> + * @authorized: Indicates whether the new connection is ready to transport data
> + *	packets.
>   */
>  struct cfg80211_roam_info {
>  	const u8 *req_ie;
> @@ -9297,6 +9302,7 @@ struct cfg80211_roam_info {
>  		struct ieee80211_channel *channel;
>  		struct cfg80211_bss *bss;
>  	} links[IEEE80211_MLD_MAX_NUM_LINKS];
> +	bool authorized;
>  };
>  
>  /**
> diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
> index 020387d76412..66b4cfd8de86 100644
> --- a/include/uapi/linux/nl80211.h
> +++ b/include/uapi/linux/nl80211.h
> @@ -2705,7 +2705,9 @@ enum nl80211_commands {
>   *	in %NL80211_CMD_CONNECT to indicate that for 802.1X authentication it
>   *	wants to use the supported offload of the 4-way handshake.
>   * @NL80211_ATTR_PMKR0_NAME: PMK-R0 Name for offloaded FT.
> - * @NL80211_ATTR_PORT_AUTHORIZED: (reserved)
> + * @NL80211_ATTR_PORT_AUTHORIZED: flag attribute used in %NL80211_CMD_CONNECT
> + *	or %NL80211_CMD_ROAM notifications to indicate that 802.1X
> + *	authentication was done by the driver or is not needed.

This attribute became deprecated when NL80211_CMD_PORT_AUTHORIZED was
introduced. Why are you not using that?

503c1fb98ba3 ("cfg80211/nl80211: add a port authorized event")


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events
  2026-08-05 22:50     ` Jeff Johnson
@ 2026-08-06  4:03       ` HungTsung Huang
  0 siblings, 0 replies; 10+ messages in thread
From: HungTsung Huang @ 2026-08-06  4:03 UTC (permalink / raw)
  To: Jeff Johnson
  Cc: linux-wireless, wlan-kernel-dev-list, Chung-Hsien Hsu,
	Chi-hsien Lin, Johannes Berg, linux-kernel

Thanks for your review.
> > Assisted-by: GitHub Copilot CLI:gpt-5.5
> > Signed-off-by: Chung-Hsien Hsu <Chung-Hsien.Hsu@infineon.com>
> > Signed-off-by: Chi-hsien Lin <chi-hsien.lin@cypress.com> 
To clarify the roles for this patch:
- Chung-Hsien Hsu is the original author of the code.
- Chi-hsien Lin supervised and reviewed the development.
- I am responsible for refactoring, testing, and submitting this patch.

I apologize for the confusion in the sign-off chain. I will fix the patch
attribution in v3 by setting Chung-Hsien as the From/Author and will make
sure the Signed-off-by order to reflect the delivery path correctly.

> This attribute became deprecated when NL80211_CMD_PORT_AUTHORIZED was
> introduced. Why are you not using that?
> 
> 503c1fb98ba3 ("cfg80211/nl80211: add a port authorized event")
> 
You are right. I will drop this cfg80211/nl80211 change in v3 and use the
existing port-authorized event model instead.

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2026-08-06  4:03 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-04  3:04 [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events Jason Huang
2026-08-04  3:04 ` [PATCH 2/7] wifi: nl80211: add roam offload extended feature Jason Huang
2026-08-04  6:43 ` [PATCH 1/7] wifi: cfg80211: report authorized connect and roam events Johannes Berg
2026-08-05 11:01 ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jason Huang
2026-08-05 11:01   ` [PATCH v2 1/2] wifi: cfg80211: report authorized connect and roam events Jason Huang
2026-08-05 22:50     ` Jeff Johnson
2026-08-06  4:03       ` HungTsung Huang
2026-08-05 11:01   ` [PATCH v2 2/2] wifi: nl80211: add roam offload extended feature Jason Huang
2026-08-05 22:22   ` [PATCH v2 0/2] wifi: support authorized roaming offload reporting Jeff Johnson
  -- strict thread matches above, loose matches on Subject: below --
2026-08-05 10:57 Jason Huang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox