P2PS: Save wps_prov_info on the responder side
When device A sends PD response to device B, device A should save wps_prov_info for device B. Not doing so would result in a redundant and incorrect PD flow, e.g., when upon PROV-DISC-DONE event device B starts a GO and device A should join it. Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com> Reviewed-by: Ilan Peer <ilan.peer@intel.com>
This commit is contained in:
parent
2fc866d1bc
commit
223ccebfa3
1 changed files with 20 additions and 0 deletions
|
@ -786,6 +786,26 @@ out:
|
|||
msg.capability ? msg.capability[1] :
|
||||
0,
|
||||
msg.group_id, msg.group_id_len);
|
||||
|
||||
if (dev) {
|
||||
switch (config_methods) {
|
||||
case WPS_CONFIG_DISPLAY:
|
||||
dev->wps_prov_info = WPS_CONFIG_KEYPAD;
|
||||
break;
|
||||
case WPS_CONFIG_KEYPAD:
|
||||
dev->wps_prov_info = WPS_CONFIG_DISPLAY;
|
||||
break;
|
||||
case WPS_CONFIG_PUSHBUTTON:
|
||||
dev->wps_prov_info = WPS_CONFIG_PUSHBUTTON;
|
||||
break;
|
||||
case WPS_CONFIG_P2PS:
|
||||
dev->wps_prov_info = WPS_CONFIG_P2PS;
|
||||
break;
|
||||
default:
|
||||
dev->wps_prov_info = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
p2p_parse_free(&msg);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue