Browse Source

qcacld-3.0: Add vdev state machine for stop BSS

Adds vdev state machine for stop BSS request

Change-Id: I3324f6e7c5747d8a75817fc02620b6bca013326e
CRs-Fixed: 2316547
Abhishek Singh 6 years ago
parent
commit
caa6185945

+ 51 - 59
components/mlme/core/src/wlan_mlme_vdev_mgr_interface.c

@@ -364,128 +364,120 @@ ap_mlme_vdev_notify_up_complete(struct vdev_mlme_obj *vdev_mlme,
 }
 
 /**
- * ap_mlme_vdev_start_req_failed () - vdev start req fail callback
+ * ap_mlme_vdev_disconnect_peers() - callback to disconnect all connected peers
  * @vdev_mlme: vdev mlme object
- * @event_data_len: event data length
- * @event_data: event data
+ * @data_len: event data length
+ * @data: event data
  *
- * This function is called to handle vdev start req/rsp failure
+ * This function is called to disconnect all connected peers
  *
  * Return: QDF_STATUS
  */
-static QDF_STATUS ap_mlme_vdev_start_req_failed(struct vdev_mlme_obj *vdev_mlme,
-						uint16_t event_data_len,
-						void *event_data)
+static QDF_STATUS ap_mlme_vdev_disconnect_peers(struct vdev_mlme_obj *vdev_mlme,
+						uint16_t data_len, void *data)
 {
-	return QDF_STATUS_SUCCESS;
+	return lim_ap_mlme_vdev_disconnect_peers(vdev_mlme, data_len, data);
 }
 
 /**
- * sap_mlme_vdev_restart_send() a callback to send vdev restart
+ * ap_mlme_vdev_stop_send() - callback to send stop vdev request
  * @vdev_mlme: vdev mlme object
- * @event_data_len: event data length
- * @event_data: event data
+ * @data_len: event data length
+ * @data: event data
  *
- * This function is called to initiate and send vdev restart req
+ * This function is called to send stop vdev request
  *
  * Return: QDF_STATUS
  */
-static QDF_STATUS ap_mlme_vdev_restart_send(struct vdev_mlme_obj *vdev_mlme,
-					    uint16_t event_data_len,
-					    void *event_data)
-{
-	return QDF_STATUS_SUCCESS;
-}
-
-static QDF_STATUS ap_mlme_vdev_stop_start_send(struct vdev_mlme_obj *vdev_mlme,
-					       enum vdev_cmd_type type,
-					       uint16_t event_data_len,
-					       void *event_data)
+static QDF_STATUS ap_mlme_vdev_stop_send(struct vdev_mlme_obj *vdev_mlme,
+					 uint16_t data_len, void *data)
 {
-	return QDF_STATUS_SUCCESS;
+	return lim_ap_mlme_vdev_stop_send(vdev_mlme, data_len, data);
 }
 
 /**
- * ap_mlme_vdev_disconnect_peers() – callback to disconnect all
- *                                   connected peers
+ * ap_mlme_vdev_stop_continue() - callback to handle stop vdev resp
  * @vdev_mlme: vdev mlme object
- * @event_data_len: event data length
- * @event_data: event data
+ * @data_len: event data length
+ * @data: event data
  *
- * This function is called to disconnect all connected peers
+ * This function is called to handle stop vdev resp
  *
  * Return: QDF_STATUS
  */
-static QDF_STATUS ap_mlme_vdev_disconnect_peers(struct vdev_mlme_obj *vdev_mlme,
-						uint16_t event_data_len,
-						void *event_data)
+static QDF_STATUS ap_mlme_vdev_stop_continue(struct vdev_mlme_obj *vdev_mlme,
+					     uint16_t data_len, void *data)
 {
-	return QDF_STATUS_SUCCESS;
+	return wma_ap_mlme_vdev_stop_continue(vdev_mlme, data_len, data);
 }
 
 /**
- * ap_mlme_vdev_stop_send() – callback to send stop vdev request
+ * ap_mlme_vdev_down_send() - callback to send vdev down req
  * @vdev_mlme: vdev mlme object
- * @event_data_len: event data length
- * @event_data: event data
+ * @data_len: event data length
+ * @data: event data
  *
- * This function is called to send stop vdev request
+ * This function is called to send vdev down req
  *
  * Return: QDF_STATUS
  */
-static QDF_STATUS ap_mlme_vdev_stop_send(struct vdev_mlme_obj *vdev_mlme,
-					 uint16_t event_data_len,
-					 void *event_data)
+static QDF_STATUS ap_mlme_vdev_down_send(struct vdev_mlme_obj *vdev_mlme,
+					 uint16_t data_len, void *data)
 {
-	return QDF_STATUS_SUCCESS;
+	return wma_ap_mlme_vdev_down_send(vdev_mlme, data_len, data);
 }
-
 /**
- * ap_mlme_vdev_stop_continue() – callback to handle stop vdev resp
+ * ap_vdev_notify_down_complete() - callback to indicate vdev down is completed
  * @vdev_mlme: vdev mlme object
- * @event_data_len: event data length
- * @event_data: event data
+ * @data_len: event data length
+ * @data: event data
  *
- * This function is called to handle stop vdev resp
+ * This function is called to indicate vdev down is completed
  *
  * Return: QDF_STATUS
  */
-static QDF_STATUS ap_mlme_vdev_stop_continue(struct vdev_mlme_obj *vdev_mlme,
-					     uint16_t event_data_len,
-					     void *event_data)
+static QDF_STATUS ap_vdev_notify_down_complete(struct vdev_mlme_obj *vdev_mlme,
+					       uint16_t data_len, void *data)
 {
-	return QDF_STATUS_SUCCESS;
+	return wma_ap_mlme_vdev_notify_down_complete(vdev_mlme, data_len, data);
 }
 
 /**
- * ap_mlme_vdev_down_send() – callback to send vdev down req
+ * ap_mlme_vdev_start_req_failed () - vdev start req fail callback
  * @vdev_mlme: vdev mlme object
  * @event_data_len: event data length
  * @event_data: event data
  *
- * This function is called to send vdev down req
+ * This function is called to handle vdev start req/rsp failure
  *
  * Return: QDF_STATUS
  */
-static QDF_STATUS ap_mlme_vdev_down_send(struct vdev_mlme_obj *vdev_mlme,
-					 uint16_t event_data_len,
-					 void *event_data)
+static QDF_STATUS ap_mlme_vdev_start_req_failed(struct vdev_mlme_obj *vdev_mlme,
+						uint16_t event_data_len,
+						void *event_data)
 {
 	return QDF_STATUS_SUCCESS;
 }
 
 /**
- * ap_vdev_notify_down_complete() – callback to indicate vdev
- *                                  down is completed
+ * sap_mlme_vdev_restart_send() a callback to send vdev restart
  * @vdev_mlme: vdev mlme object
  * @event_data_len: event data length
  * @event_data: event data
  *
- * This function is called to indicate vdev down is completed
+ * This function is called to initiate and send vdev restart req
  *
  * Return: QDF_STATUS
  */
-static QDF_STATUS ap_vdev_notify_down_complete(struct vdev_mlme_obj *vdev_mlme,
+static QDF_STATUS ap_mlme_vdev_restart_send(struct vdev_mlme_obj *vdev_mlme,
+					    uint16_t event_data_len,
+					    void *event_data)
+{
+	return QDF_STATUS_SUCCESS;
+}
+
+static QDF_STATUS ap_mlme_vdev_stop_start_send(struct vdev_mlme_obj *vdev_mlme,
+					       enum vdev_cmd_type type,
 					       uint16_t event_data_len,
 					       void *event_data)
 {

+ 34 - 1
core/mac/src/pe/lim/lim_process_sme_req_messages.c

@@ -2930,9 +2930,22 @@ void lim_delete_all_peers(tpPESession session)
 			QDF_ASSERT(0);
 		}
 	}
+
+#ifdef CONFIG_VDEV_SM
+	status =
+	    wlan_vdev_mlme_sm_deliver_evt(session->vdev,
+					  WLAN_VDEV_SM_EV_DISCONNECT_COMPLETE,
+					  sizeof(*session), session);
+	if (QDF_IS_STATUS_ERROR(status)) {
+		pe_err("failed to post WLAN_VDEV_SM_EV_DISCONNECT_COMPLETE for vdevid %d",
+		       session->smeSessionId);
+		lim_send_stop_bss_failure_resp(mac_ctx, session);
+	}
+#endif
+
 }
 
-void lim_send_vdev_stop(tpPESession session)
+QDF_STATUS lim_send_vdev_stop(tpPESession session)
 {
 	tpAniSirGlobal mac_ctx = session->mac_ctx;
 	QDF_STATUS status;
@@ -2943,6 +2956,8 @@ void lim_send_vdev_stop(tpPESession session)
 		pe_err("delBss failed for bss %d", session->bssIdx);
 		lim_send_stop_bss_failure_resp(mac_ctx, session);
 	}
+
+	return status;
 }
 
 /**
@@ -2951,12 +2966,30 @@ void lim_send_vdev_stop(tpPESession session)
  *
  * Return None
  */
+#ifdef CONFIG_VDEV_SM
+static void lim_delete_peers_and_send_vdev_stop(tpPESession session)
+{
+	tpAniSirGlobal mac_ctx = session->mac_ctx;
+	QDF_STATUS status;
+
+	status = wlan_vdev_mlme_sm_deliver_evt(session->vdev,
+					       WLAN_VDEV_SM_EV_DOWN,
+					       sizeof(*session), session);
+	if (QDF_IS_STATUS_ERROR(status)) {
+		pe_err("failed to post WLAN_VDEV_SM_EV_DOWN for vdevid %d",
+		       session->smeSessionId);
+		lim_send_stop_bss_failure_resp(mac_ctx, session);
+	}
+}
+#else
 static void lim_delete_peers_and_send_vdev_stop(tpPESession session)
 {
 	lim_delete_all_peers(session);
 	/* send a delBss to HAL and wait for a response */
 	lim_send_vdev_stop(session);
 }
+#endif
+
 
 static void
 __lim_handle_sme_stop_bss_request(tpAniSirGlobal pMac, uint32_t *pMsgBuf)

+ 14 - 1
core/mac/src/pe/lim/lim_utils.c

@@ -8504,11 +8504,24 @@ QDF_STATUS lim_ap_mlme_vdev_up_send(struct vdev_mlme_obj *vdev_mlme,
 	return status;
 }
 
+QDF_STATUS lim_ap_mlme_vdev_disconnect_peers(struct vdev_mlme_obj *vdev_mlme,
+					     uint16_t data_len, void *data)
+{
+	lim_delete_all_peers((tpPESession)data);
+
+	return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS lim_ap_mlme_vdev_stop_send(struct vdev_mlme_obj *vdev_mlme,
+				      uint16_t data_len, void *data)
+{
+	return lim_send_vdev_stop((tpPESession)data);
+}
+
 #else
 
 void lim_send_beacon(tpAniSirGlobal mac_ctx, tpPESession session)
 {
 	lim_send_beacon_ind(mac_ctx, session);
 }
-
 #endif

+ 29 - 2
core/mac/src/pe/lim/lim_utils.h

@@ -1376,9 +1376,9 @@ void lim_delete_all_peers(tpPESession session);
  * lim_send_vdev_stop() -send delete bss/stop vdev req
  * @session: session pointer
  *
- * Return None
+ * Return QDF_STATUS
  */
-void lim_send_vdev_stop(tpPESession session);
+QDF_STATUS lim_send_vdev_stop(tpPESession session);
 
 /**
  * lim_send_start_bss_confirm() -send start bss confirm req
@@ -1539,6 +1539,33 @@ QDF_STATUS lim_ap_mlme_vdev_update_beacon(struct vdev_mlme_obj *vdev_mlme,
 QDF_STATUS lim_ap_mlme_vdev_up_send(struct vdev_mlme_obj *vdev_mlme,
 				    uint16_t data_len, void *data);
 
+/**
+ * lim_ap_mlme_vdev_disconnect_peers - Disconnect peers
+ * @vdev_mlme_obj:  VDEV MLME comp object
+ * @data_len: data size
+ * @data: event data
+ *
+ * API trigger stations disconnection connected with AP
+ *
+ * Return: SUCCESS on successful invocation of station disconnection
+ *         FAILURE, if it fails due to any
+ */
+QDF_STATUS lim_ap_mlme_vdev_disconnect_peers(struct vdev_mlme_obj *vdev_mlme,
+					     uint16_t data_len, void *data);
+
+/**
+ * lim_ap_mlme_vdev_stop_send - Invokes VDEV stop operation
+ * @vdev_mlme_obj:  VDEV MLME comp object
+ * @data_len: data size
+ * @data: event data
+ *
+ * API invokes VDEV stop operation
+ *
+ * Return: SUCCESS on successful completion of stop operation
+ *         FAILURE, if it fails due to any
+ */
+QDF_STATUS lim_ap_mlme_vdev_stop_send(struct vdev_mlme_obj *vdev_mlme,
+				      uint16_t data_len, void *data);
 #endif
 
 #endif /* __LIM_UTILS_H */

+ 43 - 17
core/sap/src/sap_fsm.c

@@ -105,9 +105,8 @@ static QDF_STATUS sap_get_channel_list(struct sap_context *sapContext,
    SIDE EFFECTS
    ============================================================================*/
 
-#ifndef CONFIG_VDEV_SM
 static int sap_stop_dfs_cac_timer(struct sap_context *sapContext);
-#endif
+
 /*==========================================================================
    FUNCTION    sapStartDfsCacTimer
 
@@ -2500,20 +2499,49 @@ static QDF_STATUS sap_fsm_state_starting(struct sap_context *sap_ctx,
 		}
 	} else if (msg == eSAP_MAC_START_FAILS ||
 			msg == eSAP_HDD_STOP_INFRA_BSS) {
-		/*
-		 * Transition from SAP_STARTING to SAP_INIT
-		 * (both without substates)
-		 */
-		QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_INFO_HIGH,
-			  FL("from state %s => %s"),
-			  "SAP_STARTING", "SAP_INIT");
 
-		/* Advance outer statevar */
-		sap_ctx->fsm_state = SAP_INIT;
-		qdf_status = sap_signal_hdd_event(sap_ctx, NULL,
-				eSAP_START_BSS_EVENT,
-				(void *) eSAP_STATUS_FAILURE);
-		qdf_status = sap_goto_init(sap_ctx);
+#ifdef CONFIG_VDEV_SM
+		if (msg == eSAP_HDD_STOP_INFRA_BSS &&
+		    wlan_vdev_mlme_get_state(sap_ctx->vdev) ==
+		    WLAN_VDEV_S_DFS_CAC_WAIT) {
+			/* Transition from SAP_STARTING to SAP_STOPPING */
+			QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_INFO_HIGH,
+				  FL("In cac wait state from state %s => %s"),
+				  "SAP_STARTING", "SAP_STOPPING");
+			/*
+			 * Stop the CAC timer only in following conditions
+			 * single AP: if there is a single AP then stop timer
+			 * mulitple APs: incase of multiple APs, make sure that
+			 *               all APs are down.
+			 */
+			if (!sap_find_valid_concurrent_session(hal)) {
+				QDF_TRACE(QDF_MODULE_ID_SAP,
+					  QDF_TRACE_LEVEL_INFO_MED,
+					  FL("sapdfs: no sessions are valid, stopping timer"));
+				sap_stop_dfs_cac_timer(sap_ctx);
+			}
+
+			sap_ctx->fsm_state = SAP_STOPPING;
+			qdf_status = sap_goto_stopping(sap_ctx);
+		} else
+#endif
+		{
+			/*
+			 * Transition from SAP_STARTING to SAP_INIT
+			 * (both without substates)
+			 */
+			QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_INFO_HIGH,
+				  FL("from state %s => %s"),
+				  "SAP_STARTING", "SAP_INIT");
+
+			/* Advance outer statevar */
+			sap_ctx->fsm_state = SAP_INIT;
+			qdf_status = sap_signal_hdd_event(sap_ctx, NULL,
+							  eSAP_START_BSS_EVENT,
+							  (void *)
+							  eSAP_STATUS_FAILURE);
+			qdf_status = sap_goto_init(sap_ctx);
+		}
 		/* Close the SME session */
 	} else if (msg == eSAP_OPERATING_CHANNEL_CHANGED) {
 		/* The operating channel has changed, update hostapd */
@@ -3524,7 +3552,6 @@ void sap_dfs_cac_timer_callback(void *data)
 	sap_fsm(sapContext, &sapEvent);
 }
 
-#ifndef CONFIG_VDEV_SM
 /*
  * Function to stop the DFS CAC Timer
  */
@@ -3561,7 +3588,6 @@ static int sap_stop_dfs_cac_timer(struct sap_context *sapContext)
 
 	return 0;
 }
-#endif
 
 /*
  * Function to start the DFS CAC Timer

+ 44 - 0
core/wma/inc/wma_api.h

@@ -423,6 +423,50 @@ uint8_t wma_get_mcs_idx(uint16_t max_rate, uint8_t rate_flags,
  */
 QDF_STATUS wma_ap_mlme_vdev_start_continue(struct vdev_mlme_obj *vdev_mlme,
 					   uint16_t data_len, void *data);
+
+/**
+ * wma_ap_mlme_vdev_stop_continue - VDEV stop response handling
+ * @vdev_mlme_obj:  VDEV MLME comp object
+ * @data_len: data size
+ * @data: event data
+ *
+ * API invokes VDEV stop response actions
+ *
+ * Return: SUCCESS on successful completion of stop response operation
+ *         FAILURE, if it fails due to any
+ */
+QDF_STATUS wma_ap_mlme_vdev_stop_continue(struct vdev_mlme_obj *vdev_mlme,
+					  uint16_t data_len, void *data);
+
+/**
+ * wma_ap_mlme_vdev_down_send - VDEV down operation
+ * @vdev_mlme_obj:  VDEV MLME comp object
+ * @data_len: data size
+ * @data: event data
+ *
+ * API invokes VDEV down operation
+ *
+ * Return: SUCCESS on successful completion of VDEV down operation
+ *         FAILURE, if it fails due to any
+ */
+QDF_STATUS wma_ap_mlme_vdev_down_send(struct vdev_mlme_obj *vdev_mlme,
+				      uint16_t data_len, void *data);
+
+/**
+ * wma_ap_mlme_vdev_notify_down_complete - VDEV init state transition
+ * notification
+ * @vdev_mlme_obj:  VDEV MLME comp object
+ * @data_len: data size
+ * @data: event data
+ *
+ * API notifies MLME on moving to INIT state
+ *
+ * Return: SUCCESS on successful completion of down notification
+ *         FAILURE, if it fails due to any
+ */
+QDF_STATUS
+wma_ap_mlme_vdev_notify_down_complete(struct vdev_mlme_obj *vdev_mlme,
+				      uint16_t data_len, void *data);
 #endif
 
 #endif

+ 12 - 0
core/wma/inc/wma_internal.h

@@ -548,6 +548,7 @@ QDF_STATUS wma_create_peer(tp_wma_handle wma, struct cdp_pdev *pdev,
  * Return: none
  */
 void wma_send_del_bss_response(tp_wma_handle wma, struct wma_target_req *req);
+
 /**
  * __wma_vdev_stop_resp_handler() - vdev stop response handler
  * @handle: wma handle
@@ -1475,4 +1476,15 @@ QDF_STATUS wma_get_roam_scan_stats(WMA_HANDLE handle,
 int wma_roam_scan_stats_event_handler(void *handle, uint8_t *event,
 				      uint32_t len);
 
+/**
+ * wma_send_del_bss_response() - send del bss resp to upper layer
+ * @wma: wma handle.
+ * @vdev_id: vdev ID of device for which MCC has to be checked
+ *
+ * This function sends del bss resp to upper layer
+ *
+ * Return: none
+ */
+void wma_send_vdev_down_bss(tp_wma_handle wma, struct wma_target_req *req);
+
 #endif

+ 37 - 13
core/wma/src/wma_dev_if.c

@@ -2080,20 +2080,12 @@ void wma_send_del_bss_response(tp_wma_handle wma, struct wma_target_req *req)
 	}
 }
 
-/**
- * wma_send_del_bss_response() - send del bss resp to upper layer
- * @wma: wma handle.
- * @vdev_id: vdev ID of device for which MCC has to be checked
- *
- * This function sends del bss resp to upper layer
- *
- * Return: none
- */
-static void
-wma_send_vdev_down_bss(tp_wma_handle wma, struct wma_target_req *req)
+void wma_send_vdev_down_bss(tp_wma_handle wma, struct wma_target_req *req)
 {
 	uint8_t vdev_id;
-
+#ifdef CONFIG_VDEV_SM
+	struct wma_txrx_node *iface = &wma->interfaces[req->vdev_id];
+#endif
 	if (!req) {
 		WMA_LOGE("%s req is NULL", __func__);
 		return;
@@ -2110,7 +2102,13 @@ wma_send_vdev_down_bss(tp_wma_handle wma, struct wma_target_req *req)
 		wma_check_and_find_mcc_ap(wma, vdev_id);
 	}
 
+#ifdef CONFIG_VDEV_SM
+	wlan_vdev_mlme_sm_deliver_evt(iface->vdev,
+				      WLAN_VDEV_SM_EV_DOWN_COMPLETE,
+				      sizeof(*req), req);
+#else
 	wma_send_del_bss_response(wma, req);
+#endif
 }
 
 QDF_STATUS
@@ -2196,8 +2194,13 @@ __wma_vdev_stop_resp_handler(wmi_vdev_stopped_event_fixed_param *resp_event)
 		   wma->wmi_handle,
 		   wmi_service_sync_delete_cmds))
 			goto free_req_msg;
-
+#ifdef CONFIG_VDEV_SM
+		wlan_vdev_mlme_sm_deliver_evt(iface->vdev,
+					      WLAN_VDEV_SM_EV_MLME_DOWN_REQ,
+					      sizeof(*req_msg), req_msg);
+#else
 		wma_send_vdev_down_bss(wma, req_msg);
+#endif
 	} else if (req_msg->msg_type == WMA_SET_LINK_STATE) {
 		tpLinkStateParams params =
 			(tpLinkStateParams) req_msg->user_data;
@@ -2252,6 +2255,9 @@ int wma_vdev_stop_resp_handler(void *handle, uint8_t *cmd_param_info,
 	tp_wma_handle wma = (tp_wma_handle) handle;
 	WMI_VDEV_STOPPED_EVENTID_param_tlvs *param_buf;
 	wmi_vdev_stopped_event_fixed_param *resp_event;
+#ifdef CONFIG_VDEV_SM
+	struct wma_txrx_node *iface;
+#endif
 	int32_t status = 0;
 
 	WMA_LOGD("%s: Enter", __func__);
@@ -2270,7 +2276,15 @@ int wma_vdev_stop_resp_handler(void *handle, uint8_t *cmd_param_info,
 		return -EINVAL;
 	}
 
+#ifdef CONFIG_VDEV_SM
+	iface = &wma->interfaces[resp_event->vdev_id];
+	status =  wlan_vdev_mlme_sm_deliver_evt(iface->vdev,
+						WLAN_VDEV_SM_EV_STOP_RESP,
+						sizeof(*resp_event),
+						resp_event);
+#else
 	status = __wma_vdev_stop_resp_handler(resp_event);
+#endif
 	if (QDF_IS_STATUS_ERROR(status))
 		return -EINVAL;
 
@@ -3192,7 +3206,17 @@ int wma_peer_delete_handler(void *handle, uint8_t *cmd_param_info,
 		}
 		wma_send_msg(wma, WMA_SET_LINK_STATE_RSP, (void *)params, 0);
 	} else if (req_msg->type == WMA_DELETE_PEER_RSP) {
+#ifdef CONFIG_VDEV_SM
+		struct wma_txrx_node *iface =
+					&wma->interfaces[req_msg->vdev_id];
+
+		wlan_vdev_mlme_sm_deliver_evt(iface->vdev,
+					      WLAN_VDEV_SM_EV_MLME_DOWN_REQ,
+					      sizeof(*req_msg), req_msg);
+#else
 		wma_send_vdev_down_bss(wma, req_msg);
+#endif
+
 	}
 	qdf_mem_free(req_msg);
 	return status;

+ 29 - 0
core/wma/src/wma_utils.c

@@ -4817,4 +4817,33 @@ QDF_STATUS wma_ap_mlme_vdev_start_continue(struct vdev_mlme_obj *vdev_mlme,
 {
 	return wma_ap_vdev_send_start_resp(vdev_mlme, data);
 }
+
+QDF_STATUS wma_ap_mlme_vdev_stop_continue(struct vdev_mlme_obj *vdev_mlme,
+					  uint16_t data_len, void *data)
+{
+	return __wma_vdev_stop_resp_handler(
+			(wmi_vdev_stopped_event_fixed_param *)data);
+}
+
+QDF_STATUS wma_ap_mlme_vdev_down_send(struct vdev_mlme_obj *vdev_mlme,
+				      uint16_t data_len, void *data)
+{
+	tp_wma_handle wma = cds_get_context(QDF_MODULE_ID_WMA);
+
+	wma_send_vdev_down_bss(wma, (struct wma_target_req *)data);
+
+	return QDF_STATUS_SUCCESS;
+}
+
+QDF_STATUS
+wma_ap_mlme_vdev_notify_down_complete(struct vdev_mlme_obj *vdev_mlme,
+				      uint16_t data_len, void *data)
+{
+	tp_wma_handle wma = cds_get_context(QDF_MODULE_ID_WMA);
+
+	wma_send_del_bss_response(wma, (struct wma_target_req *)data);
+
+	return QDF_STATUS_SUCCESS;
+}
+
 #endif