qcacld-3.0: Close cds sched as part of cds_close()

cds_sched_open is called as part of cds_open, but cds_sched_close is
called outside of cds_close. This leads to situations where the CDS
scheduler is started but not properly closed. Move the call to
cds_sched_close into cds_close, such that the CDS scheduler lifecycle is
tied directly to the CDS core lifecycle, to prevent CDS from closing
without closing the CDS scheduler.

Change-Id: I440ec279e6b750a7b41ec05000fc66b6cebdb8d8
CRs-Fixed: 2151049
diff --git a/core/cds/src/cds_api.c b/core/cds/src/cds_api.c
index 4d0fae0..39561b3 100644
--- a/core/cds/src/cds_api.c
+++ b/core/cds/src/cds_api.c
@@ -1122,6 +1122,11 @@
 {
 	QDF_STATUS qdf_status;
 
+	qdf_status = cds_sched_close();
+	QDF_ASSERT(QDF_IS_STATUS_SUCCESS(qdf_status));
+	if (QDF_IS_STATUS_ERROR(qdf_status))
+		cds_err("Failed to close CDS Scheduler");
+
 	dispatcher_psoc_close(psoc);
 
 	qdf_status = wma_wmi_work_close();