[PATCH 1/7] NAN: Add instant communication configuration

Andrei Otcheretianski andrei.otcheretianski at intel.com
Thu Oct 8 09:54:32 PDT 2026


From: Ilan Peer <ilan.peer at intel.com>

Extend the driver NAN configuration interface to allow enable/disable
NAN Instant Communication (IC) mode.

Extend the NAN_SET command to also support configuring the IC mode:
'instant_comm'.

Signed-off-by: Ilan Peer <ilan.peer at intel.com>
---
 src/drivers/driver.h            | 4 ++++
 wpa_supplicant/nan_supplicant.c | 1 +
 2 files changed, 5 insertions(+)

diff --git a/src/drivers/driver.h b/src/drivers/driver.h
index e957a56ae0..32fcb4ec81 100644
--- a/src/drivers/driver.h
+++ b/src/drivers/driver.h
@@ -2299,6 +2299,8 @@ struct nan_capa {
 #define WPA_DRIVER_FLAGS_NAN_SUPPORT_NDP		0x00000008
 /** Driver supports NAN beacon protection */
 #define WPA_DRIVER_FLAGS_NAN_SUPPORT_BEACON_PROT	0x00000010
+/** Driver supports NAN instant communication */
+#define WPA_DRIVER_FLAGS_NAN_SUPPORT_INSTANT_COMM	0x00000020
 	u32 drv_flags;
 	u8 num_radios;
 	u8 sched_chans;
@@ -3484,6 +3486,7 @@ struct nan_band_config {
  * @master_pref: Master preference for the cluster
  * @dual_band: Dual band operation enabled
  * @enable_dw_notif: Enable discovery window notifications
+ * @instant_comm: Enable NAN instant communication mode
  * @cluster_id: Cluster ID for the NAN cluster
  * @scan_period: Period for NAN scan in seconds
  * @scan_dwell_time: Dwell time for NAN scan in TUs per channel
@@ -3499,6 +3502,7 @@ struct nan_cluster_config {
 	u8 master_pref;
 	u8 dual_band;
 	bool enable_dw_notif;
+	bool instant_comm;
 
 	u8 cluster_id[ETH_ALEN];
 	u16 scan_period;
diff --git a/wpa_supplicant/nan_supplicant.c b/wpa_supplicant/nan_supplicant.c
index bd964697eb..a9ffab6172 100644
--- a/wpa_supplicant/nan_supplicant.c
+++ b/wpa_supplicant/nan_supplicant.c
@@ -2016,6 +2016,7 @@ int wpas_nan_set(struct wpa_supplicant *wpa_s, char *cmd)
 	NAN_PARSE_INT(scan_period, 0, 0xffff);
 	NAN_PARSE_INT(scan_dwell_time, 10, 150);
 	NAN_PARSE_INT(discovery_beacon_interval, 50, 200);
+	NAN_PARSE_INT(instant_comm, 0, 1);
 
 	NAN_PARSE_BAND(low_band_cfg);
 	NAN_PARSE_BAND(high_band_cfg);
-- 
2.53.0




More information about the Hostap mailing list