mirror of
https://git.kernel.org/pub/scm/network/wireless/iwd.git
synced 2024-12-22 21:22:37 +01:00
dpp: rework order of operations after being configured
Now the result is sent immediately. Prior a connect attempt or scan could have started, potentially losing this frame. In addition the offchannel operation is cancelled after sending the result which will allow the subsequent connect or scan to happen much faster since it doesn't have to wait for ROC to expire.
This commit is contained in:
parent
94afeabc18
commit
fc61e5fe46
14
src/dpp.c
14
src/dpp.c
@ -639,6 +639,11 @@ static void dpp_handle_config_response_frame(const struct mmpdu_header *frame,
|
|||||||
}
|
}
|
||||||
|
|
||||||
dpp_write_config(config, network);
|
dpp_write_config(config, network);
|
||||||
|
dpp_configuration_free(config);
|
||||||
|
|
||||||
|
send_config_result(dpp, dpp->auth_addr);
|
||||||
|
|
||||||
|
offchannel_cancel(dpp->wdev_id, dpp->offchannel_id);
|
||||||
|
|
||||||
if (network && bss)
|
if (network && bss)
|
||||||
__station_connect_network(station, network, bss);
|
__station_connect_network(station, network, bss);
|
||||||
@ -647,15 +652,10 @@ static void dpp_handle_config_response_frame(const struct mmpdu_header *frame,
|
|||||||
dpp_scan_triggered,
|
dpp_scan_triggered,
|
||||||
dpp_scan_results, dpp,
|
dpp_scan_results, dpp,
|
||||||
dpp_scan_destroy);
|
dpp_scan_destroy);
|
||||||
if (!dpp->connect_scan_id)
|
if (dpp->connect_scan_id)
|
||||||
goto scan_failed;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
dpp_configuration_free(config);
|
|
||||||
|
|
||||||
send_config_result(dpp, dpp->auth_addr);
|
|
||||||
|
|
||||||
scan_failed:
|
|
||||||
dpp_reset(dpp);
|
dpp_reset(dpp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user