qcacld-3.0: Add VDEV state machine for STA

Add support for VDEV state machine support
for STA connection

Change-Id: Ifbf12d13e936b6535baee8f9bbf7062e56f84014
CRs-Fixed: 2321423
diff --git a/core/mac/src/pe/lim/lim_process_sme_req_messages.c b/core/mac/src/pe/lim/lim_process_sme_req_messages.c
index e53d170..b3515e0 100644
--- a/core/mac/src/pe/lim/lim_process_sme_req_messages.c
+++ b/core/mac/src/pe/lim/lim_process_sme_req_messages.c
@@ -1205,6 +1205,33 @@
 {}
 #endif
 
+/**
+ * lim_send_join_req() - send vdev start request
+ *@session: pe session
+ *@mlm_join_req: join req
+ *
+ * Return: QDF_STATUS
+ */
+
+#ifdef CONFIG_VDEV_SM
+static QDF_STATUS lim_send_join_req(tpPESession session,
+				    tLimMlmJoinReq *mlm_join_req)
+{
+	return wlan_vdev_mlme_sm_deliver_evt(session->vdev,
+					     WLAN_VDEV_SM_EV_START,
+					     sizeof(*mlm_join_req),
+					     mlm_join_req);
+}
+#else
+static QDF_STATUS lim_send_join_req(tpPESession session,
+				    tLimMlmJoinReq *mlm_join_req)
+{
+	lim_process_mlm_join_req(session->mac_ctx, mlm_join_req);
+
+	return QDF_STATUS_SUCCESS;
+}
+#endif
+
 
 /**
  * __lim_process_sme_join_req() - process SME_JOIN_REQ message
@@ -1686,8 +1713,7 @@
 		session->isOSENConnection = sme_join_req->isOSENConnection;
 
 		/* Issue LIM_MLM_JOIN_REQ to MLM */
-		lim_post_mlm_message(mac_ctx, LIM_MLM_JOIN_REQ,
-				     (uint32_t *) mlm_join_req);
+		lim_send_join_req(session, mlm_join_req);
 		return;
 
 	} else {