Преглед изворни кода

qcacmn: Handle FP BARs without errors in wbm release ring

Only BAR frames with REO/RXDMA push reason as error are handled
in host. FP BAR frames without errors, are routed to host
via REO/RXDMA with push reason as route.

Instead of leaking the buffer, handle the routed BAR frames
gracefully. Free the buffer and log stats to detect such
cases.

Change-Id: I6e09e8b948d9b2d9d3de3b6558e54f0c70901c62
CRs-Fixed: 2814303
Padma Raghunathan пре 4 година
родитељ
комит
b82e526a72
3 измењених фајлова са 16 додато и 0 уклоњено
  1. 8 0
      dp/wifi3.0/dp_rx_err.c
  2. 4 0
      dp/wifi3.0/dp_stats.c
  3. 4 0
      dp/wifi3.0/dp_types.h

+ 8 - 0
dp/wifi3.0/dp_rx_err.c

@@ -2256,6 +2256,10 @@ done:
 						   wbm_err_info.reo_err_code);
 					qdf_nbuf_free(nbuf);
 				}
+			} else if (wbm_err_info.reo_psh_rsn
+				   == HAL_RX_WBM_REO_PSH_RSN_ROUTE) {
+				DP_STATS_INC(soc, rx.reo2rel_route_drop, 1);
+				qdf_nbuf_free(nbuf);
 			}
 		} else if (wbm_err_info.wbm_err_src ==
 					HAL_RX_WBM_ERR_SRC_RXDMA) {
@@ -2320,6 +2324,10 @@ done:
 					dp_err_rl("RXDMA error %d",
 						  wbm_err_info.rxdma_err_code);
 				}
+			} else if (wbm_err_info.rxdma_psh_rsn
+				   == HAL_RX_WBM_RXDMA_PSH_RSN_ROUTE) {
+				DP_STATS_INC(soc, rx.rxdma2rel_route_drop, 1);
+				qdf_nbuf_free(nbuf);
 			}
 		} else {
 			/* Should not come here */

+ 4 - 0
dp/wifi3.0/dp_stats.c

@@ -6640,6 +6640,10 @@ dp_print_soc_rx_stats(struct dp_soc *soc)
 		       soc->stats.rx.err.reo_cmd_send_fail);
 
 	DP_PRINT_STATS("Rx BAR frames:%d", soc->stats.rx.bar_frame);
+	DP_PRINT_STATS("Rxdma2rel route drop:%d",
+		       soc->stats.rx.rxdma2rel_route_drop);
+	DP_PRINT_STATS("Reo2rel route drop:%d",
+		       soc->stats.rx.reo2rel_route_drop);
 }
 
 #ifdef FEATURE_TSO_STATS

+ 4 - 0
dp/wifi3.0/dp_types.h

@@ -892,6 +892,10 @@ struct dp_soc_stats {
 		uint32_t msdu_scatter_wait_break;
 		/* Number of bar frames received */
 		uint32_t bar_frame;
+		/* Number of frames routed from rxdma */
+		uint32_t rxdma2rel_route_drop;
+		/* Number of frames routed from reo*/
+		uint32_t reo2rel_route_drop;
 
 		struct {
 			/* Invalid RBM error count */