|
@@ -1058,7 +1058,6 @@ send_rsp:
|
|
|
*
|
|
|
* Return: none
|
|
|
*/
|
|
|
-#ifdef CONFIG_VDEV_SM
|
|
|
static void wma_send_start_resp(tp_wma_handle wma,
|
|
|
tpAddBssParams add_bss,
|
|
|
wmi_vdev_start_response_event_fixed_param *
|
|
@@ -1090,26 +1089,6 @@ static void wma_send_start_resp(tp_wma_handle wma,
|
|
|
resp_event->vdev_id, add_bss->status);
|
|
|
wma_send_msg_high_priority(wma, WMA_ADD_BSS_RSP, (void *)add_bss, 0);
|
|
|
}
|
|
|
-#else
|
|
|
-static void wma_send_start_resp(tp_wma_handle wma,
|
|
|
- tpAddBssParams add_bss,
|
|
|
- wmi_vdev_start_response_event_fixed_param *
|
|
|
- resp_event)
|
|
|
-{
|
|
|
- /* Send vdev stop if vdev start was success */
|
|
|
- if (QDF_IS_STATUS_ERROR(add_bss->status)) {
|
|
|
- if (!resp_event->status)
|
|
|
- if (wma_send_vdev_stop_to_fw(wma, resp_event->vdev_id))
|
|
|
- WMA_LOGE(FL("Failed to send vdev stop"));
|
|
|
-
|
|
|
- wma_remove_peer_on_add_bss_failure(add_bss);
|
|
|
- }
|
|
|
-
|
|
|
- WMA_LOGD(FL("Sending add bss rsp to umac(vdev %d status %d)"),
|
|
|
- resp_event->vdev_id, add_bss->status);
|
|
|
- wma_send_msg_high_priority(wma, WMA_ADD_BSS_RSP, (void *)add_bss, 0);
|
|
|
-}
|
|
|
-#endif
|
|
|
|
|
|
/**
|
|
|
* wma_vdev_start_rsp() - send vdev start response to upper layer
|
|
@@ -1235,7 +1214,6 @@ static void wma_find_mcc_ap(tp_wma_handle wma, uint8_t vdev_id, bool add)
|
|
|
}
|
|
|
#endif /* FEATURE_AP_MCC_CH_AVOIDANCE */
|
|
|
|
|
|
-#ifdef CONFIG_VDEV_SM
|
|
|
/**
|
|
|
* wma_handle_hidden_ssid_restart() - handle hidden ssid restart
|
|
|
* @wma: wma handle
|
|
@@ -1339,101 +1317,6 @@ wma_handle_channel_switch_resp(tp_wma_handle wma,
|
|
|
|
|
|
return QDF_STATUS_SUCCESS;
|
|
|
}
|
|
|
-#else
|
|
|
-static void wma_handle_hidden_ssid_restart(tp_wma_handle wma,
|
|
|
- struct wma_txrx_node *iface,
|
|
|
- struct wma_target_req *req)
|
|
|
-{
|
|
|
- tpHalHiddenSsidVdevRestart hidden_ssid_restart =
|
|
|
- (tpHalHiddenSsidVdevRestart)req->user_data;
|
|
|
- WMA_LOGE("%s: vdev restart event recevied for hidden ssid set using IOCTL",
|
|
|
- __func__);
|
|
|
-
|
|
|
- wma_set_hidden_ssid_restart_in_progress(iface, 0);
|
|
|
- wma_send_msg(wma, WMA_HIDDEN_SSID_RESTART_RSP,
|
|
|
- (void *)hidden_ssid_restart, 0);
|
|
|
-}
|
|
|
-
|
|
|
-static QDF_STATUS
|
|
|
-wma_handle_channel_switch_resp(tp_wma_handle wma,
|
|
|
- wmi_vdev_start_response_event_fixed_param
|
|
|
- *resp_event,
|
|
|
- struct wma_target_req *req)
|
|
|
-{
|
|
|
- struct wma_txrx_node *iface;
|
|
|
- tpSwitchChannelParams params = (tpSwitchChannelParams)req->user_data;
|
|
|
-
|
|
|
- if (!params) {
|
|
|
- WMA_LOGE("%s: channel switch params is NULL for vdev %d",
|
|
|
- __func__, resp_event->vdev_id);
|
|
|
- policy_mgr_set_do_hw_mode_change_flag(wma->psoc, false);
|
|
|
- return QDF_STATUS_E_FAILURE;
|
|
|
- }
|
|
|
-
|
|
|
- iface = &wma->interfaces[resp_event->vdev_id];
|
|
|
- WMA_LOGD("%s: Send channel switch resp vdev %d status %d",
|
|
|
- __func__, resp_event->vdev_id, resp_event->status);
|
|
|
- params->chainMask = resp_event->chain_mask;
|
|
|
- if ((resp_event->cfgd_rx_streams != 2) ||
|
|
|
- (resp_event->cfgd_tx_streams != 2))
|
|
|
- params->nss = 1;
|
|
|
-
|
|
|
- params->smpsMode = host_map_smps_mode(resp_event->smps_mode);
|
|
|
- params->status = resp_event->status;
|
|
|
-
|
|
|
- if (wma->interfaces[resp_event->vdev_id].is_channel_switch)
|
|
|
- wma->interfaces[resp_event->vdev_id].is_channel_switch = false;
|
|
|
-
|
|
|
- if ((QDF_IS_STATUS_SUCCESS(resp_event->status) &&
|
|
|
- (resp_event->resp_type == WMI_VDEV_RESTART_RESP_EVENT) &&
|
|
|
- ((iface->type == WMI_VDEV_TYPE_STA) ||
|
|
|
- (iface->type == WMI_VDEV_TYPE_MONITOR))) ||
|
|
|
- ((resp_event->resp_type == WMI_VDEV_START_RESP_EVENT) &&
|
|
|
- (iface->type == WMI_VDEV_TYPE_MONITOR))) {
|
|
|
- wmi_host_channel_width chanwidth;
|
|
|
- struct vdev_up_params vdev_up_param = {0};
|
|
|
- QDF_STATUS status;
|
|
|
- int err;
|
|
|
-
|
|
|
- /* for CSA case firmware expects phymode before ch_wd */
|
|
|
- err = wma_set_peer_param(wma, iface->bssid,
|
|
|
- WMI_PEER_PHYMODE, iface->chanmode,
|
|
|
- resp_event->vdev_id);
|
|
|
- WMA_LOGD("%s:vdev_id %d chanmode %d status %d",
|
|
|
- __func__, resp_event->vdev_id, iface->chanmode, err);
|
|
|
-
|
|
|
- chanwidth = wmi_get_ch_width_from_phy_mode(wma->wmi_handle,
|
|
|
- iface->chanmode);
|
|
|
- err = wma_set_peer_param(wma, iface->bssid, WMI_PEER_CHWIDTH,
|
|
|
- chanwidth, resp_event->vdev_id);
|
|
|
- WMA_LOGD("%s:vdev_id %d chanwidth %d status %d",
|
|
|
- __func__, resp_event->vdev_id, chanwidth, err);
|
|
|
- vdev_up_param.vdev_id = resp_event->vdev_id;
|
|
|
- vdev_up_param.assoc_id = iface->aid;
|
|
|
- status = wma_send_vdev_up_to_fw(wma,
|
|
|
- &vdev_up_param, iface->bssid);
|
|
|
- if (QDF_IS_STATUS_ERROR(status)) {
|
|
|
- WMA_LOGE("%s:vdev_up failed vdev_id %d",
|
|
|
- __func__, resp_event->vdev_id);
|
|
|
-
|
|
|
- wma_vdev_set_mlme_state_stop(wma, resp_event->vdev_id);
|
|
|
-
|
|
|
- policy_mgr_set_do_hw_mode_change_flag(wma->psoc, false);
|
|
|
- } else {
|
|
|
- wma_vdev_set_mlme_state_run(wma, resp_event->vdev_id);
|
|
|
- if (iface->beacon_filter_enabled)
|
|
|
- wma_add_beacon_filter(wma,
|
|
|
- &iface->beacon_filter);
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- wma_send_msg_high_priority(wma, WMA_SWITCH_CHANNEL_RSP,
|
|
|
- (void *)params, 0);
|
|
|
-
|
|
|
- return QDF_STATUS_SUCCESS;
|
|
|
-}
|
|
|
-
|
|
|
-#endif
|
|
|
|
|
|
/**
|
|
|
* wma_vdev_start_resp_handler() - vdev start response handler
|
|
@@ -1580,7 +1463,6 @@ int wma_vdev_start_resp_handler(void *handle, uint8_t *cmd_param_info,
|
|
|
wma->psoc, false);
|
|
|
return -EEXIST;
|
|
|
}
|
|
|
- wma_vdev_set_mlme_state_run(wma, resp_event->vdev_id);
|
|
|
ucfg_ocb_config_channel(wma->pdev);
|
|
|
}
|
|
|
if ((wma->interfaces[resp_event->vdev_id].type == WMI_VDEV_TYPE_AP) &&
|
|
@@ -2479,7 +2361,6 @@ void wma_send_del_bss_response(tp_wma_handle wma, struct wma_target_req *req)
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-#ifdef CONFIG_VDEV_SM
|
|
|
void wma_send_vdev_down(tp_wma_handle wma, struct wma_target_req *req)
|
|
|
{
|
|
|
uint8_t vdev_id;
|
|
@@ -2537,51 +2418,6 @@ static void wma_handle_set_link_down_rsp(tp_wma_handle wma,
|
|
|
WLAN_VDEV_SM_EV_MLME_DOWN_REQ,
|
|
|
sizeof(*req), req);
|
|
|
}
|
|
|
-#else
|
|
|
-void wma_send_vdev_down(tp_wma_handle wma, struct wma_target_req *req)
|
|
|
-{
|
|
|
- uint8_t vdev_id;
|
|
|
- tpDeleteBssParams params = (tpDeleteBssParams)req->user_data;
|
|
|
-
|
|
|
- if (!req) {
|
|
|
- WMA_LOGE("%s req is NULL", __func__);
|
|
|
- return;
|
|
|
- }
|
|
|
-
|
|
|
- vdev_id = req->vdev_id;
|
|
|
-
|
|
|
- if (req->msg_type == WMA_DELETE_BSS_HO_FAIL_REQ) {
|
|
|
- params->status = QDF_STATUS_SUCCESS;
|
|
|
- wma_send_msg_high_priority(wma, WMA_DELETE_BSS_HO_FAIL_RSP,
|
|
|
- (void *)params, 0);
|
|
|
- return;
|
|
|
- }
|
|
|
-
|
|
|
- if (wma_send_vdev_down_to_fw(wma, vdev_id) != QDF_STATUS_SUCCESS) {
|
|
|
- WMA_LOGE("Failed to send vdev down cmd: vdev %d", vdev_id);
|
|
|
- } else {
|
|
|
- wma_vdev_set_mlme_state_stop(wma, vdev_id);
|
|
|
- wma_check_and_find_mcc_ap(wma, vdev_id);
|
|
|
- }
|
|
|
-
|
|
|
- wma_send_del_bss_response(wma, req);
|
|
|
-}
|
|
|
-
|
|
|
-static void wma_send_vdev_down_bss(tp_wma_handle wma,
|
|
|
- struct wma_target_req *req)
|
|
|
-{
|
|
|
- wma_send_vdev_down(wma, req);
|
|
|
-}
|
|
|
-
|
|
|
-static void wma_handle_set_link_down_rsp(tp_wma_handle wma,
|
|
|
- struct wma_target_req *req)
|
|
|
-{
|
|
|
- if (wma_send_vdev_down_to_fw(wma, req->vdev_id) != QDF_STATUS_SUCCESS)
|
|
|
- WMA_LOGE("Failed to send vdev down cmd: vdev %d", req->vdev_id);
|
|
|
-
|
|
|
- wma_send_set_link_response(wma, req);
|
|
|
-}
|
|
|
-#endif
|
|
|
|
|
|
#ifdef WLAN_FEATURE_11W
|
|
|
static void wma_clear_iface_key(struct wma_txrx_node *iface)
|
|
@@ -2782,7 +2618,6 @@ free_req_msg:
|
|
|
*
|
|
|
* Return: QDF_STATUS
|
|
|
*/
|
|
|
-#ifdef CONFIG_VDEV_SM
|
|
|
static QDF_STATUS
|
|
|
wma_handle_vdev_stop_rsp(tp_wma_handle wma,
|
|
|
wmi_vdev_stopped_event_fixed_param *resp_event)
|
|
@@ -2794,14 +2629,6 @@ wma_handle_vdev_stop_rsp(tp_wma_handle wma,
|
|
|
WLAN_VDEV_SM_EV_STOP_RESP,
|
|
|
sizeof(*resp_event), resp_event);
|
|
|
}
|
|
|
-#else
|
|
|
-static QDF_STATUS
|
|
|
-wma_handle_vdev_stop_rsp(tp_wma_handle wma,
|
|
|
- wmi_vdev_stopped_event_fixed_param *resp_event)
|
|
|
-{
|
|
|
- return __wma_handle_vdev_stop_rsp(resp_event);
|
|
|
-}
|
|
|
-#endif
|
|
|
|
|
|
int wma_vdev_stop_resp_handler(void *handle, uint8_t *cmd_param_info,
|
|
|
uint32_t len)
|
|
@@ -3553,14 +3380,7 @@ QDF_STATUS wma_vdev_start(tp_wma_handle wma,
|
|
|
temp_reg_info_2;
|
|
|
}
|
|
|
|
|
|
- if (isRestart) {
|
|
|
- /*
|
|
|
- * Marking the VDEV UP STATUS to false
|
|
|
- * since, VDEV RESTART will do a VDEV DOWN
|
|
|
- * in the firmware.
|
|
|
- */
|
|
|
- wma_vdev_set_mlme_state_stop(wma, params.vdev_id);
|
|
|
- } else {
|
|
|
+ if (!isRestart) {
|
|
|
WMA_LOGD("%s, vdev_id: %d, unpausing tx_ll_queue at VDEV_START",
|
|
|
__func__, params.vdev_id);
|
|
|
cdp_fc_vdev_unpause(cds_get_context(QDF_MODULE_ID_SOC),
|
|
@@ -4040,7 +3860,6 @@ void wma_remove_req(tp_wma_handle wma, uint8_t vdev_id,
|
|
|
qdf_mem_free(req_msg);
|
|
|
}
|
|
|
|
|
|
-#ifdef CONFIG_VDEV_SM
|
|
|
/**
|
|
|
* wma_handle_channel_switch_req_timeout() - handle channel switch req timeout
|
|
|
* @wma: wma handler
|
|
@@ -4099,51 +3918,6 @@ wma_handle_add_bss_req_timeout(tp_wma_handle wma, struct wma_target_req *req)
|
|
|
WLAN_VDEV_SM_EV_DOWN,
|
|
|
sizeof(*params), params);
|
|
|
}
|
|
|
-#else
|
|
|
-static
|
|
|
-void wma_handle_channel_switch_req_timeout(tp_wma_handle wma,
|
|
|
- struct wma_target_req *req)
|
|
|
-{
|
|
|
- tpSwitchChannelParams params = (tpSwitchChannelParams)req->user_data;
|
|
|
-
|
|
|
- params->status = QDF_STATUS_E_TIMEOUT;
|
|
|
- WMA_LOGA("%s: WMA_SWITCH_CHANNEL_REQ timedout", __func__);
|
|
|
-
|
|
|
- /*
|
|
|
- * Trigger host crash if the flag is set or if the timeout
|
|
|
- * is not due to fw down
|
|
|
- */
|
|
|
- if (wma_crash_on_fw_timeout(wma->fw_timeout_crash))
|
|
|
- wma_trigger_recovery_assert_on_fw_timeout(
|
|
|
- WMA_CHNL_SWITCH_REQ);
|
|
|
-
|
|
|
- if (wma->interfaces[req->vdev_id].is_channel_switch)
|
|
|
- wma->interfaces[req->vdev_id].is_channel_switch = false;
|
|
|
-
|
|
|
- wma_send_msg_high_priority(wma, WMA_SWITCH_CHANNEL_RSP,
|
|
|
- (void *)params, 0);
|
|
|
-}
|
|
|
-
|
|
|
-static void
|
|
|
-wma_handle_add_bss_req_timeout(tp_wma_handle wma, struct wma_target_req *req)
|
|
|
-{
|
|
|
- tpAddBssParams params = (tpAddBssParams) req->user_data;
|
|
|
-
|
|
|
- params->status = QDF_STATUS_E_TIMEOUT;
|
|
|
- WMA_LOGA("%s: WMA_ADD_BSS_REQ timedout", __func__);
|
|
|
- WMA_LOGD("%s: bssid %pM vdev_id %d", __func__, params->bssId,
|
|
|
- req->vdev_id);
|
|
|
-
|
|
|
- if (wma_crash_on_fw_timeout(wma->fw_timeout_crash))
|
|
|
- wma_trigger_recovery_assert_on_fw_timeout(WMA_ADD_BSS_REQ);
|
|
|
-
|
|
|
- if (wma_send_vdev_stop_to_fw(wma, req->vdev_id))
|
|
|
- WMA_LOGE("%s: Failed to send vdev stop to fw", __func__);
|
|
|
-
|
|
|
- wma_remove_peer_on_add_bss_failure(params);
|
|
|
- wma_send_msg_high_priority(wma, WMA_ADD_BSS_RSP, (void *)params, 0);
|
|
|
-}
|
|
|
-#endif
|
|
|
|
|
|
/**
|
|
|
* wma_vdev_resp_timer() - wma response timeout function
|
|
@@ -4259,7 +4033,6 @@ void wma_vdev_resp_timer(void *data)
|
|
|
WMA_LOGE("Failed to send vdev down cmd: vdev %d",
|
|
|
tgt_req->vdev_id);
|
|
|
} else {
|
|
|
- wma_vdev_set_mlme_state_stop(wma, tgt_req->vdev_id);
|
|
|
#ifdef FEATURE_AP_MCC_CH_AVOIDANCE
|
|
|
if (mac_ctx->sap.sap_channel_avoidance)
|
|
|
wma_find_mcc_ap(wma, tgt_req->vdev_id, false);
|
|
@@ -4335,8 +4108,6 @@ void wma_vdev_resp_timer(void *data)
|
|
|
|
|
|
WMA_LOGE("Hidden ssid vdev restart Timed Out; vdev_id: %d, type = %d",
|
|
|
tgt_req->vdev_id, tgt_req->type);
|
|
|
- wma_set_hidden_ssid_restart_in_progress(
|
|
|
- &wma->interfaces[tgt_req->vdev_id], 0);
|
|
|
qdf_mem_free(tgt_req->user_data);
|
|
|
}
|
|
|
} else if (tgt_req->msg_type == WMA_SET_LINK_STATE) {
|
|
@@ -5582,41 +5353,6 @@ static void wma_send_bss_color_change_enable(tp_wma_handle wma,
|
|
|
}
|
|
|
#endif
|
|
|
|
|
|
-#ifdef CONFIG_VDEV_SM
|
|
|
-static inline QDF_STATUS wma_indicate_start_success(tp_wma_handle wma,
|
|
|
- struct wma_txrx_node *iface,
|
|
|
- tpAddStaParams params)
|
|
|
-{
|
|
|
- return QDF_STATUS_SUCCESS;
|
|
|
-}
|
|
|
-#else
|
|
|
-static QDF_STATUS wma_indicate_start_success(tp_wma_handle wma,
|
|
|
- struct wma_txrx_node *iface,
|
|
|
- tpAddStaParams params)
|
|
|
-{
|
|
|
- QDF_STATUS status;
|
|
|
- struct vdev_up_params param = {0};
|
|
|
-
|
|
|
- param.vdev_id = params->smesessionId;
|
|
|
- param.assoc_id = params->assocId;
|
|
|
- param.profile_idx = params->mbssid_info.profile_num;
|
|
|
- param.profile_num = params->mbssid_info.profile_count;
|
|
|
- qdf_mem_copy(¶m.trans_bssid, ¶ms->mbssid_info.trans_bssid,
|
|
|
- QDF_MAC_ADDR_SIZE);
|
|
|
- status = wma_send_vdev_up_to_fw(wma, ¶m, params->bssId);
|
|
|
- if (QDF_IS_STATUS_ERROR(status)) {
|
|
|
- WMA_LOGE("%s: Failed to send vdev up cmd: vdev %d bssid %pM",
|
|
|
- __func__, params->smesessionId, params->bssId);
|
|
|
- policy_mgr_set_do_hw_mode_change_flag(wma->psoc, false);
|
|
|
- } else {
|
|
|
- wma_set_vdev_mgmt_rate(wma, params->smesessionId);
|
|
|
- wma_vdev_set_mlme_state_run(wma, params->smesessionId);
|
|
|
- }
|
|
|
-
|
|
|
- return status;
|
|
|
-}
|
|
|
-#endif
|
|
|
-
|
|
|
/**
|
|
|
* wma_add_sta_req_sta_mode() - process add sta request in sta mode
|
|
|
* @wma: wma handle
|
|
@@ -5789,7 +5525,6 @@ static void wma_add_sta_req_sta_mode(tp_wma_handle wma, tpAddStaParams params)
|
|
|
params->smesessionId);
|
|
|
}
|
|
|
}
|
|
|
- wma_indicate_start_success(wma, iface, params);
|
|
|
qdf_atomic_set(&iface->bss_status, WMA_BSS_STATUS_STARTED);
|
|
|
WMA_LOGD("%s: STA mode (type %d subtype %d) BSS is started",
|
|
|
__func__, iface->type, iface->sub_type);
|
|
@@ -6288,7 +6023,6 @@ void wma_delete_bss_ho_fail(tp_wma_handle wma, tpDeleteBssParams params)
|
|
|
qdf_atomic_set(&iface->bss_status, WMA_BSS_STATUS_STOPPED);
|
|
|
WMA_LOGD("%s: (type %d subtype %d) BSS is stopped",
|
|
|
__func__, iface->type, iface->sub_type);
|
|
|
- wma_vdev_set_mlme_state_stop(wma, params->smesessionId);
|
|
|
params->status = QDF_STATUS_SUCCESS;
|
|
|
|
|
|
msg = wma_fill_vdev_req(wma, params->smesessionId,
|
|
@@ -6455,7 +6189,6 @@ void wma_delete_bss(tp_wma_handle wma, tpDeleteBssParams params)
|
|
|
WMA_LOGD("LFR3:%s: Setting vdev_up to FALSE for session %d",
|
|
|
__func__, params->smesessionId);
|
|
|
|
|
|
- wma_vdev_set_mlme_state_stop(wma, params->smesessionId);
|
|
|
goto detach_peer;
|
|
|
}
|
|
|
msg = wma_fill_vdev_req(wma, params->smesessionId, WMA_DELETE_BSS_REQ,
|