Sfoglia il codice sorgente

qcacld-3.0: Add net buff pop fail counter

Add net buff pop fail counter which helps to debug issues
related to scenario when RX ring fill count exceeds the fill
level.

Change-Id: I00f4a4e245e0732ef04518e4c1db95999edc6687
CRs-Fixed: 2106523
Sravan Kumar Kairam 7 anni fa
parent
commit
8ea5ee2120
2 ha cambiato i file con 6 aggiunte e 0 eliminazioni
  1. 5 0
      core/dp/htt/htt_rx.c
  2. 1 0
      core/dp/htt/htt_types.h

+ 5 - 0
core/dp/htt/htt_rx.c

@@ -2305,6 +2305,7 @@ htt_rx_amsdu_rx_in_order_pop_ll(htt_pdev_handle pdev,
 	if (qdf_unlikely(NULL == msdu)) {
 		qdf_print("%s: netbuf pop failed!\n", __func__);
 		*tail_msdu = NULL;
+		pdev->rx_ring.pop_fail_cnt++;
 		return 0;
 	}
 
@@ -2398,6 +2399,7 @@ htt_rx_amsdu_rx_in_order_pop_ll(htt_pdev_handle pdev,
 					qdf_print("%s: netbuf pop failed!\n",
 								 __func__);
 					*tail_msdu = NULL;
+					pdev->rx_ring.pop_fail_cnt++;
 					return 0;
 				}
 
@@ -2429,6 +2431,7 @@ htt_rx_amsdu_rx_in_order_pop_ll(htt_pdev_handle pdev,
 				qdf_print("%s: netbuf pop failed!\n",
 					  __func__);
 				*tail_msdu = NULL;
+				pdev->rx_ring.pop_fail_cnt++;
 				return 0;
 			}
 			qdf_nbuf_set_next(msdu, next);
@@ -3188,6 +3191,7 @@ int htt_rx_msdu_buff_in_order_replenish(htt_pdev_handle pdev, uint32_t num)
 		qdf_spin_lock_bh(&(pdev->rx_ring.refill_lock));
 	}
 	pdev->rx_buff_fill_n_invoked++;
+
 	filled = htt_rx_ring_fill_n(pdev, num);
 
 	if (filled > num) {
@@ -3629,6 +3633,7 @@ int htt_rx_attach(struct htt_pdev_t *pdev)
 		 QDF_TIMER_TYPE_SW);
 
 	pdev->rx_ring.fill_cnt = 0;
+	pdev->rx_ring.pop_fail_cnt = 0;
 #ifdef DEBUG_DMA_DONE
 	pdev->rx_ring.dbg_ring_idx = 0;
 	pdev->rx_ring.dbg_refill_cnt = 0;

+ 1 - 0
core/dp/htt/htt_types.h

@@ -316,6 +316,7 @@ struct htt_pdev_t {
 
 		int fill_level; /* how many rx buffers to keep in the ring */
 		int fill_cnt;   /* # of rx buffers (full+empty) in the ring */
+		int pop_fail_cnt;   /* # of nebuf pop failures */
 
 		/*
 		 * target_idx -