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

Commit dd814199 authored by Hardik Kantilal Patel's avatar Hardik Kantilal Patel
Browse files

wcnss: configure iris into cxo mode



configure iris into cxo mode when iris card not present
to avoid crash at boot time.

Change-Id: I7056ca9269be05598ffdc5545ee5647a6e432046
CRs-fixed: 691946
Signed-off-by: default avatarHardik Kantilal Patel <hkpatel@codeaurora.org>
parent 70db5225
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -256,6 +256,18 @@ configure_iris_xo(struct device *dev,
				cpu_relax();

			iris_reg = readl_relaxed(iris_read_reg);
			pr_info("wcnss: IRIS Reg: %08x\n", iris_reg);
			if (iris_reg == PRONTO_IRIS_REG_CHIP_ID) {
				pr_info("wcnss: IRIS Card not Preset\n");
				auto_detect = WCNSS_XO_INVALID;
				/* Reset iris read bit */
				reg &= ~WCNSS_PMU_CFG_IRIS_XO_READ;
				/* Clear XO_MODE[b2:b1] bits.
				   Clear implies 19.2 MHz TCXO
				 */
				reg &= ~(WCNSS_PMU_CFG_IRIS_XO_MODE);
				goto xo_configure;
			}
			auto_detect = xo_auto_detect(iris_reg);

			/* Reset iris read bit */
@@ -278,6 +290,7 @@ configure_iris_xo(struct device *dev,
				*iris_xo_set = WCNSS_XO_48MHZ;
		}

xo_configure:
		writel_relaxed(reg, pmu_conf_reg);

		/* Reset IRIS */