Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions source/core/wifi_ctrl_queue_handlers.c
Original file line number Diff line number Diff line change
Expand Up @@ -3231,6 +3231,12 @@ static void process_wps_cancel_event(void *data)

INT vap_index = *(INT*)data;

if (!isVapPrivate(vap_index)) {
wifi_util_error_print(WIFI_CTRL,"%s:%d WPS not applicable for vap index %d, ignoring cancel\n",
__func__, __LINE__, vap_index);
return;
}

wifi_util_info_print(WIFI_CTRL,"%s:%d wps pbc cancel vap index = %d\n",
__func__, __LINE__, vap_index);
wifi_hal_setApWpsCancel(vap_index);
Expand Down
10 changes: 7 additions & 3 deletions source/dml/tr_181/ml/cosa_wifi_dml.c
Original file line number Diff line number Diff line change
Expand Up @@ -12405,9 +12405,13 @@ WPS_SetParamBoolValue
}
if( AnscEqualString(ParamName, "X_CISCO_COM_CancelSession", TRUE))
{
instance_number -= 1;
wifi_util_dbg_print(WIFI_DMCLI,"%s:%d: WPS cancel for vap %d\n",__func__, __LINE__, instance_number);
push_event_to_ctrl_queue(&instance_number, sizeof(instance_number), wifi_event_type_command, wifi_event_type_command_wps_cancel, NULL);
if (vapInfo->u.bss_info.wps.enable == false) {
wifi_util_error_print(WIFI_DMCLI,"%s:%d: WPS not enabled for %s, cancel session not supported\n",__func__, __LINE__, vapInfo->vap_name);
return FALSE;
Comment thread
gsathish86 marked this conversation as resolved.
}
INT vap_index = (INT)(instance_number - 1);
wifi_util_dbg_print(WIFI_DMCLI,"%s:%d: WPS cancel for vap %d\n",__func__, __LINE__, vap_index);
push_event_to_ctrl_queue(&vap_index, sizeof(vap_index), wifi_event_type_command, wifi_event_type_command_wps_cancel, NULL);
return TRUE;
}
#else
Expand Down
12 changes: 9 additions & 3 deletions source/platform/common/data_model/wifi_dml_cb.c
Original file line number Diff line number Diff line change
Expand Up @@ -4820,10 +4820,16 @@ bool wps_set_param_bool_value(void *obj_ins_context, char *param_name, bool outp
}
}
} else if (STR_CMP(param_name, "X_CISCO_COM_CancelSession")) {
instance_number -= 1;
if (p_dm_vap_info->u.bss_info.wps.enable == false) {
wifi_util_error_print(WIFI_DMCLI,
"%s:%d: WPS not enabled for %s, cancel session not supported\n",
__func__, __LINE__, p_dm_vap_info->vap_name);
Comment thread
mateuszCieslak-GL marked this conversation as resolved.
return false;
}
INT vap_index = (INT)(instance_number - 1);
wifi_util_dbg_print(WIFI_DMCLI, "%s:%d: WPS cancel for vap %d\n", __func__, __LINE__,
instance_number);
push_event_to_ctrl_queue(&instance_number, sizeof(instance_number), wifi_event_type_command,
vap_index);
push_event_to_ctrl_queue(&vap_index, sizeof(vap_index), wifi_event_type_command,
wifi_event_type_command_wps_cancel, NULL);
} else {
wifi_util_info_print(WIFI_DMCLI, "%s:%d: unsupported param name:%s\n", __func__, __LINE__,
Expand Down
Loading