From: Jintao Lin Date: Wed, 31 Jul 2024 18:50:01 +0000 (+0000) Subject: P2P: Use specified frequency for group client in P2P_GROUP_ADD command X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d40788a5cbc66748fa415ab60f246c8f3e8aa45d;p=thirdparty%2Fhostap.git P2P: Use specified frequency for group client in P2P_GROUP_ADD command In P2P_GROUP_ADD command and GroupAdd dbus method, frequency is passed in as a parameter when restarting a persistent group. This is the group operating frequency determined out of band. Use this pre-determined frequency in P2P client as well to expedite the P2P scan. Signed-off-by: Jintao Lin --- diff --git a/wpa_supplicant/ctrl_iface.c b/wpa_supplicant/ctrl_iface.c index 0f00eb2e5..96e0740fb 100644 --- a/wpa_supplicant/ctrl_iface.c +++ b/wpa_supplicant/ctrl_iface.c @@ -7172,7 +7172,7 @@ static int p2p_ctrl_group_add_persistent(struct wpa_supplicant *wpa_s, return -1; } - return wpas_p2p_group_add_persistent(wpa_s, ssid, 0, freq, 0, + return wpas_p2p_group_add_persistent(wpa_s, ssid, 0, freq, freq, vht_center_freq2, ht40, vht, vht_chwidth, he, edmg, NULL, 0, 0, allow_6ghz, 0, diff --git a/wpa_supplicant/dbus/dbus_new_handlers_p2p.c b/wpa_supplicant/dbus/dbus_new_handlers_p2p.c index 418a8fd42..3de6ed89f 100644 --- a/wpa_supplicant/dbus/dbus_new_handlers_p2p.c +++ b/wpa_supplicant/dbus/dbus_new_handlers_p2p.c @@ -473,7 +473,7 @@ DBusMessage * wpas_dbus_handler_p2p_group_add(DBusMessage *message, if (ssid == NULL || ssid->disabled != 2) goto inv_args; - if (wpas_p2p_group_add_persistent(wpa_s, ssid, 0, freq, 0, + if (wpas_p2p_group_add_persistent(wpa_s, ssid, 0, freq, freq, freq2, ht40, vht, max_oper_chwidth, he, edmg, NULL, 0, 0, allow_6ghz,