Prechádzať zdrojové kódy

qcacmn: Force free leaking tx buffers in defconfig build

Currently, when tx completions are pending for more than 60
seconds, assert is generated in defconfig builds.
Force free leaking tx buffers in defconfig builds so system
can go to suspend in defconfig builds.

Change-Id: Ie66506d58e85176320c7aa35d49059f808be0054
CRs-Fixed: 3318409
Ananya Gupta 2 rokov pred
rodič
commit
683ffb600f
1 zmenil súbory, kde vykonal 0 pridanie a 65 odobranie
  1. 0 65
      dp/wifi3.0/dp_main.c

+ 0 - 65
dp/wifi3.0/dp_main.c

@@ -14149,7 +14149,6 @@ static bool dp_tx_comp_delay_check(struct dp_tx_desc_s *tx_desc)
 	return false;
 }
 
-#if defined(CONFIG_SLUB_DEBUG_ON)
 /**
  * dp_find_missing_tx_comp() - check for leaked descriptor in tx path
  * @soc - DP SOC context
@@ -14160,69 +14159,6 @@ static bool dp_tx_comp_delay_check(struct dp_tx_desc_s *tx_desc)
  * Return: None.
  */
 static void dp_find_missing_tx_comp(struct dp_soc *soc)
-{
-	uint8_t i;
-	uint32_t j;
-	uint32_t num_desc, page_id, offset;
-	uint16_t num_desc_per_page;
-	struct dp_tx_desc_s *tx_desc = NULL;
-	struct dp_tx_desc_pool_s *tx_desc_pool = NULL;
-	bool send_fw_stats_cmd = false;
-	uint8_t vdev_id;
-
-	for (i = 0; i < MAX_TXDESC_POOLS; i++) {
-		tx_desc_pool = &soc->tx_desc[i];
-		if (!(tx_desc_pool->pool_size) ||
-		    IS_TX_DESC_POOL_STATUS_INACTIVE(tx_desc_pool) ||
-		    !(tx_desc_pool->desc_pages.cacheable_pages))
-			continue;
-
-		num_desc = tx_desc_pool->pool_size;
-		num_desc_per_page =
-			tx_desc_pool->desc_pages.num_element_per_page;
-		for (j = 0; j < num_desc; j++) {
-			page_id = j / num_desc_per_page;
-			offset = j % num_desc_per_page;
-
-			if (qdf_unlikely(!(tx_desc_pool->
-					 desc_pages.cacheable_pages)))
-				break;
-
-			tx_desc = dp_tx_desc_find(soc, i, page_id, offset);
-			if (tx_desc->magic == DP_TX_MAGIC_PATTERN_FREE) {
-				continue;
-			} else if (tx_desc->magic ==
-				   DP_TX_MAGIC_PATTERN_INUSE) {
-				if (dp_tx_comp_delay_check(tx_desc)) {
-					dp_err_rl("Tx completion not rcvd for id: %u",
-						  tx_desc->id);
-
-					if (!send_fw_stats_cmd) {
-						send_fw_stats_cmd = true;
-						vdev_id = i;
-					}
-				}
-			} else {
-				dp_err_rl("tx desc %u corrupted, flags: 0x%x",
-				       tx_desc->id, tx_desc->flags);
-			}
-		}
-	}
-
-	/*
-	 * The unit test command to dump FW stats is required only once as the
-	 * stats are dumped at pdev level and not vdev level.
-	 */
-	if (send_fw_stats_cmd && soc->cdp_soc.ol_ops->dp_send_unit_test_cmd) {
-		uint32_t fw_stats_args[2] = {533, 1};
-
-		soc->cdp_soc.ol_ops->dp_send_unit_test_cmd(vdev_id,
-							   WLAN_MODULE_TX, 2,
-							   fw_stats_args);
-	}
-}
-#else
-static void dp_find_missing_tx_comp(struct dp_soc *soc)
 {
 	uint8_t i;
 	uint32_t j;
@@ -14275,7 +14211,6 @@ static void dp_find_missing_tx_comp(struct dp_soc *soc)
 		}
 	}
 }
-#endif /* CONFIG_SLUB_DEBUG_ON */
 #else
 static inline void dp_find_missing_tx_comp(struct dp_soc *soc)
 {