qcacld-3.0: In Monitor mode use proper event for restart failure

In monitor mode in case of restart failure,
event WLAN_VDEV_SM_EV_START_REQ_FAIL is used to move the vdev SM
to init state. But this event will not be handled in
WLAN_VDEV_SS_START_RESTART_PROGRESS and thus the vdev stop/down
won't be sent for the vdev.

Use event WLAN_VDEV_SM_EV_RESTART_REQ_FAIL for restart failure
to send vdev stop/down.

Change-Id: I2db459136955b8dc2213c0251284a08a8f57aa57
CRs-Fixed: 2964875
This commit is contained in:
Abhishek Singh 2021-06-14 10:29:33 +05:30 • committed by Madan Koyyalamudi
commit e73530cc01

View file

@ -2859,10 +2859,17 @@ static void lim_handle_mon_switch_channel_rsp(struct pe_session *session,
return;
if (QDF_IS_STATUS_ERROR(status)) {
pe_err("Set channel failed for monitor mode");
wlan_vdev_mlme_sm_deliver_evt(session->vdev,
WLAN_VDEV_SM_EV_START_REQ_FAIL,
0, NULL);
enum wlan_vdev_sm_evt event = WLAN_VDEV_SM_EV_START_REQ_FAIL;
pe_err("Set channel failed for monitor mode vdev substate %d",
wlan_vdev_mlme_get_substate(session->vdev));
if (QDF_IS_STATUS_SUCCESS(
wlan_vdev_is_restart_progress(session->vdev)))
event = WLAN_VDEV_SM_EV_RESTART_REQ_FAIL;
wlan_vdev_mlme_sm_deliver_evt(session->vdev, event, 0, NULL);
return;
}