Ver código fonte

qcacld-3.0: Check if pipes already enabled for IPA enable pipes

Currently there is a race condition during enable of IPA WDI pipes
after IPA_RM_RESOURCE_GRANTED notification from IPA RM and at the
same time client disconnect happens. Because of this race condition
subsequent enable IPA pipes at the time of client connection IPA
driver returns error as the pipes are not disabled before. In this
change after requesting IPA resource check for IPA pipes state and
if pipes are not enabled then enable the pipes.

Change-Id: Idd0d4089efa5b81d5301a278fb0dd836db0ecb48
CRs-Fixed: 2082118
Sravan Kumar Kairam 7 anos atrás
pai
commit
c76f28a675
1 arquivos alterados com 11 adições e 0 exclusões
  1. 11 0
      core/hdd/src/wlan_hdd_ipa.c

+ 11 - 0
core/hdd/src/wlan_hdd_ipa.c

@@ -1921,12 +1921,23 @@ static int hdd_ipa_uc_handle_first_con(struct hdd_ipa_priv *hdd_ipa)
 			/* RM PROD request sync return
 			 * enable pipe immediately
 			 */
+			if (!hdd_ipa->ipa_pipes_down) {
+				HDD_IPA_LOG(QDF_TRACE_LEVEL_DEBUG,
+					"%s: IPA WDI Pipe already activated",
+					__func__);
+				return 0;
+			}
+
 			if (hdd_ipa_uc_enable_pipes(hdd_ipa)) {
 				HDD_IPA_LOG(QDF_TRACE_LEVEL_ERROR,
 					"IPA WDI Pipe activation failed");
 				hdd_ipa->resource_loading = false;
 				return -EBUSY;
 			}
+		} else {
+			HDD_IPA_LOG(QDF_TRACE_LEVEL_INFO,
+				    "%s: IPA WDI Pipe activation deferred",
+					__func__);
 		}
 	} else {
 		/* RM Disabled