[PATCH 07/21] wpa_supplicant: Add helper to check for CIP support

Benjamin Berg benjamin at sipsolutions.net
Tue Oct 27 06:16:53 PDT 2026


From: Benjamin Berg <benjamin.berg at intel.com>

The driver flags support for CIP per interface. As such, add a function
to check for support as there is no driver flag for this.

Signed-off-by: Benjamin Berg <benjamin.berg at intel.com>
Reviewed-by: Andrei Otcheretianski <andrei.otcheretianski at intel.com>
---
 wpa_supplicant/driver_i.h | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/wpa_supplicant/driver_i.h b/wpa_supplicant/driver_i.h
index 9122b9353b..559be7aad6 100644
--- a/wpa_supplicant/driver_i.h
+++ b/wpa_supplicant/driver_i.h
@@ -1386,4 +1386,21 @@ static inline int wpa_drv_get_inact_sec(struct wpa_supplicant *wpa_s,
 
 #endif /* CONFIG_NAN */
 
+static inline int wpa_drv_get_cip_supported(struct wpa_supplicant *wpa_s)
+{
+	enum wpa_driver_if_type iftype = WPA_IF_STATION;
+	u8 cip_capab;
+
+	if (!wpa_s->driver->get_cip_capab)
+		return 0;
+
+#ifdef CONFIG_P2P
+	if (wpa_s->go_params)
+		iftype = WPA_IF_P2P_CLIENT;
+#endif
+
+	return !wpa_s->driver->get_cip_capab(wpa_s->drv_priv, iftype,
+					     &cip_capab);
+}
+
 #endif /* DRIVER_I_H */
-- 
2.56.0




More information about the Hostap mailing list