int go = s->mode == WPAS_MODE_P2P_GO;
wpas_p2p_group_add_persistent(
wpa_s, s, go, 0, op_freq, 0, 0, NULL,
- go ? P2P_MAX_INITIAL_CONN_WAIT_GO_REINVOKE : 0);
+ go ? P2P_MAX_INITIAL_CONN_WAIT_GO_REINVOKE : 0,
+ 1);
} else if (bssid) {
wpa_s->user_initiated_pd = 0;
wpas_p2p_join(wpa_s, bssid, go_dev_addr,
channels,
ssid->mode == WPAS_MODE_P2P_GO ?
P2P_MAX_INITIAL_CONN_WAIT_GO_REINVOKE :
- 0);
+ 0, 1);
}
persistent_go->mode ==
WPAS_MODE_P2P_GO ?
P2P_MAX_INITIAL_CONN_WAIT_GO_REINVOKE :
- 0);
+ 0, 0);
} else if (response_done) {
wpas_p2p_group_add(wpa_s, 1, 0, 0, 0);
}
wpas_p2p_group_add_persistent(
wpa_s, persistent_go, 0, 0, 0, 0, 0, NULL,
persistent_go->mode == WPAS_MODE_P2P_GO ?
- P2P_MAX_INITIAL_CONN_WAIT_GO_REINVOKE : 0);
+ P2P_MAX_INITIAL_CONN_WAIT_GO_REINVOKE : 0, 0);
} else {
wpas_p2p_group_add(wpa_s, 1, 0, 0, 0);
}
static int wpas_start_p2p_client(struct wpa_supplicant *wpa_s,
struct wpa_ssid *params, int addr_allocated,
- int freq)
+ int freq, int force_scan)
{
struct wpa_ssid *ssid;
wpa_s = wpas_p2p_get_group_iface(wpa_s, addr_allocated, 0);
if (wpa_s == NULL)
return -1;
+ if (force_scan)
+ os_get_reltime(&wpa_s->scan_min_time);
wpa_s->p2p_last_4way_hs_fail = NULL;
wpa_supplicant_ap_deinit(wpa_s);
struct wpa_ssid *ssid, int addr_allocated,
int force_freq, int neg_freq, int ht40,
int vht, const struct p2p_channels *channels,
- int connection_timeout)
+ int connection_timeout, int force_scan)
{
struct p2p_go_neg_results params;
int go = 0, freq;
freq = 0;
}
- return wpas_start_p2p_client(wpa_s, ssid, addr_allocated, freq);
+ return wpas_start_p2p_client(wpa_s, ssid, addr_allocated, freq,
+ force_scan);
} else {
return -1;
}