qcacld-3.0: Ignore active timeout handler in case of ROC timeout

qcacld-2.0 to qcacld-3.0 propagation

DUT sends continuous GO Negotiation Response for the request
while ROC is in progress. These frames increase timeout of
cancel ROC timer and ROC is not removed from the active timout.
This can cause ROC to be in active cmd list even after current
timeout value.

Add changes to return from active timeout handler in case of ROC.

Change-Id: I58577b5d2addf7614d8ee458df0ce4632dafa7c0
CRs-Fixed: 990808
diff --git a/core/sme/src/common/sme_api.c b/core/sme/src/common/sme_api.c
index 3a811f2..55b4666 100644
--- a/core/sme/src/common/sme_api.c
+++ b/core/sme/src/common/sme_api.c
@@ -11648,6 +11648,8 @@
 {
 	tHalHandle hal = (tHalHandle)userData;
 	tpAniSirGlobal mac_ctx = PMAC_STRUCT(hal);
+	tListElem *entry;
+	tSmeCmd *temp_cmd = NULL;
 
 	if (NULL == mac_ctx) {
 		QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
@@ -11673,6 +11675,14 @@
 	else
 		qdf_trace_dump_all(mac_ctx, 0, 0, 500, 0);
 
+	entry = csr_ll_peek_head(&mac_ctx->sme.smeCmdActiveList,
+				 LL_ACCESS_LOCK);
+	if (entry)
+		temp_cmd = GET_BASE_ADDR(entry, tSmeCmd, Link);
+	/* Ignore if ROC took more than 120 sec */
+	if (temp_cmd && (eSmeCommandRemainOnChannel == temp_cmd->command))
+		return;
+
 	if (mac_ctx->sme.enableSelfRecovery) {
 		sme_save_active_cmd_stats(hal);
 		cds_trigger_recovery();