Browse Source

qcacmn: prevent double free on buffer

wdi event has to be called before dp_txrx_ppdu_stats_handler.
this will handle all pktlog htt messages including cases for mgmt frame

Change-Id: Iefba15b61278fe77cbb6d6df9190e66b46ed573c
Ruben Columbus 5 years ago
parent
commit
e762bb831e
1 changed files with 3 additions and 3 deletions
  1. 3 3
      dp/wifi3.0/dp_htt.c

+ 3 - 3
dp/wifi3.0/dp_htt.c

@@ -4192,11 +4192,11 @@ dp_ppdu_stats_ind_handler(struct htt_soc *soc,
 	target_pdev_id = HTT_T2H_PPDU_STATS_PDEV_ID_GET(*msg_word);
 	target_pdev_id = HTT_T2H_PPDU_STATS_PDEV_ID_GET(*msg_word);
 	pdev_id = dp_get_host_pdev_id_for_target_pdev_id(soc->dp_soc,
 	pdev_id = dp_get_host_pdev_id_for_target_pdev_id(soc->dp_soc,
 							 target_pdev_id);
 							 target_pdev_id);
+	dp_wdi_event_handler(WDI_EVENT_LITE_T2H, soc->dp_soc,
+			     htt_t2h_msg, HTT_INVALID_PEER, WDI_NO_VAL,
+			     pdev_id);
 	free_buf = dp_txrx_ppdu_stats_handler(soc->dp_soc, pdev_id,
 	free_buf = dp_txrx_ppdu_stats_handler(soc->dp_soc, pdev_id,
 					      htt_t2h_msg);
 					      htt_t2h_msg);
-	dp_wdi_event_handler(WDI_EVENT_LITE_T2H, soc->dp_soc,
-		htt_t2h_msg, HTT_INVALID_PEER, WDI_NO_VAL,
-		pdev_id);
 	return free_buf;
 	return free_buf;
 }
 }
 #else
 #else