Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7f94163f authored by Prashanth Bhatta's avatar Prashanth Bhatta
Browse files

icnss: Top level reset if clocks are dead



During recovery, if not able to force enable hardware clocks then
do top level reset only.

CRs-fixed: 1067868
Change-Id: Ie23ca022c94cd214a9e415e9fb774055cfaf881d
Signed-off-by: default avatarPrashanth Bhatta <bhattap@codeaurora.org>
parent 6c104f8d
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -1320,7 +1320,7 @@ int icnss_hw_reset(struct icnss_priv *priv)
				 MPM_WCSSAON_CONFIG_FORCE_ACTIVE, 1);

	icnss_hw_poll_reg_field(priv->mem_base_va, SR_WCSSAON_SR_LSB_OFFSET,
				SR_WCSSAON_SR_LSB_RETENTION_STATUS, 1, 100,
				SR_WCSSAON_SR_LSB_RETENTION_STATUS, 1, 200,
				ICNSS_HW_REG_RETRY);

	for (i = 0; i < ICNSS_HW_REG_RETRY; i++) {
@@ -1348,11 +1348,13 @@ int icnss_hw_reset(struct icnss_priv *priv)
	}

	if (i >= ICNSS_HW_REG_RETRY)
		ICNSS_ASSERT(false);
		goto top_level_reset;

	icnss_hw_write_reg_field(priv->mpm_config_va, MPM_WCSSAON_CONFIG_OFFSET,
				 MPM_WCSSAON_CONFIG_DISCONNECT_CLR, 0x1);

	usleep_range(200, 300);

	icnss_hw_reset_wlan_ss_power_down(priv);

	icnss_hw_reset_common_ss_power_down(priv);