Kaynağa Gözat

qcacld-3.0: Disconnect TX pipe when RX pipe connect fails

Currently when IPA RX WDI pipe connect fails during start modules
host does not clean up the TX pipe which is allocated before the
RX pipe. As part of proper clean up from host in this change
disconnect the TX pipe handle when RX pipe connect returns failure.

Change-Id: Ic037dd2415ab5be497a0617d8151d63219868fd1
CRs-Fixed: 2040146
Sravan Kumar Kairam 8 yıl önce
ebeveyn
işleme
6b92adff7d
1 değiştirilmiş dosya ile 6 ekleme ve 2 silme
  1. 6 2
      core/hdd/src/wlan_hdd_ipa.c

+ 6 - 2
core/hdd/src/wlan_hdd_ipa.c

@@ -3090,11 +3090,15 @@ QDF_STATUS hdd_ipa_uc_ol_init(hdd_context_t *hdd_ctx)
 		ret = ipa_connect_wdi_pipe(&ipa_ctxt->prod_pipe_in, &pipe_out);
 		if (ret) {
 			HDD_IPA_LOG(QDF_TRACE_LEVEL_ERROR,
-				"ipa_connect_wdi_pipe falied for Rx: ret=%d",
+				"ipa_connect_wdi_pipe failed for Rx: ret=%d",
 				ret);
 			stat = QDF_STATUS_E_FAILURE;
+			ret = ipa_disconnect_wdi_pipe(ipa_ctxt->tx_pipe_handle);
+			if (ret)
+				HDD_IPA_LOG(QDF_TRACE_LEVEL_ERROR,
+					    "disconnect failed for TX: ret=%d",
+					    ret);
 			goto fail_return;
-
 		}
 		ipa_ctxt->rx_ready_doorbell_paddr = pipe_out.uc_door_bell_pa;
 		ipa_ctxt->rx_pipe_handle = pipe_out.clnt_hdl;