Parcourir la source

qcacld-3.0: Add debug code to rootcause command timeout issue.

qcacld-2.0 to qcacld-3.0 propagation

when EXIT_BMPS is pending in activeList, it causes crash
with excess logging for RoamPending list. In this scenario
gTraceTbl has lost SME details due to other MTRACE commands.
Because of which, the issue is not rootcaused.

Add below changes to rootcause if the issue appears again:
1. print only first 5 commands from roamPendingList
2. Bug_on if the commandlist is full
3. Add MTRACE for PMC commands

CRs-Fixed: 833261
Change-Id: Id5bb399c4a8c8e84ddfa121a66881e3ecb901b05
DARAM SUDHA il y a 10 ans
Parent
commit
f6c3f9705e
1 fichiers modifiés avec 17 ajouts et 9 suppressions
  1. 17 9
      core/sme/src/common/sme_api.c

+ 17 - 9
core/sme/src/common/sme_api.c

@@ -546,29 +546,37 @@ tSmeCmd *sme_get_command_buffer(tpAniSirGlobal pMac)
 				csr_ll_next(&pMac->sme.smeCmdPendingList, pEntry,
 					    LL_ACCESS_NOLOCK);
 		}
-		/* Increment static variable so that it prints
-		 * pending command only once
-		 */
-		sme_command_queue_full++;
-
 		csr_ll_unlock(&pMac->sme.smeCmdPendingList);
 
+		idx = 1;
 		/* There may be some more command in CSR's own pending queue */
 		csr_ll_lock(&pMac->roam.roamCmdPendingList);
 		pEntry =
 			csr_ll_peek_head(&pMac->roam.roamCmdPendingList,
 					 LL_ACCESS_NOLOCK);
-		while (pEntry) {
+		while (pEntry  && !sme_command_queue_full) {
 			pTempCmd = GET_BASE_ADDR(pEntry, tSmeCmd, Link);
-			sms_log(pMac, LOGE,
-				"Out of command buffer.... CSR pending command #%d (0x%X)",
-				idx++, pTempCmd->command);
+			/* Print only 1st five commands from CSR pending queue */
+			if (idx <= 5)
+				sms_log(pMac, LOGE,
+					"Out of command buffer.... "
+					"CSR roamCmdPendingList command #%d (0x%X)",
+					idx, pTempCmd->command);
+			idx++;
 			dump_csr_command_info(pMac, pTempCmd);
 			pEntry =
 				csr_ll_next(&pMac->roam.roamCmdPendingList, pEntry,
 					    LL_ACCESS_NOLOCK);
 		}
+
+		/* Increment static variable so that it prints
+		 * pending command only once
+		 */
+		sme_command_queue_full++;
 		csr_ll_unlock(&pMac->roam.roamCmdPendingList);
+
+		/* panic with out-of-command */
+		CDF_BUG(0);
 	}
 
 	/* memset to zero */