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

Commit bbf6ae64 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ARM: dts: msm: Hold QUSB PHY1 into reset with MSM8996 variant"

parents 5d79677d c234c1e3
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -166,6 +166,7 @@ Optional properties:
 - qcom,tune2-efuse-bit-pos: TUNE2 parameter related start bit position with EFUSE register
 - qcom,tune2-efuse-num-bits: Number of bits based value to use for TUNE2 high nibble
 - qcom,emulation: Indicates that we are running on emulation platform.
 - qcom,hold-reset: Indicates that hold QUSB PHY into reset state.

Example:
	qusb_phy: qusb@f9b39000 {
+1 −0
Original line number Diff line number Diff line
@@ -1949,6 +1949,7 @@
					0x21 0x10
					0x14 0x9C>;
		phy_type = "utmi";
		qcom,hold-reset;

		clocks = <&clock_gcc clk_ln_bb_clk>,
			 <&clock_gcc clk_gcc_rx2_usb2_clkref_clk>,
+10 −0
Original line number Diff line number Diff line
@@ -770,6 +770,7 @@ static int qusb_phy_probe(struct platform_device *pdev)
	struct resource *res;
	int ret = 0, size = 0;
	const char *phy_type;
	bool hold_phy_reset;

	qphy = devm_kzalloc(dev, sizeof(*qphy), GFP_KERNEL);
	if (!qphy)
@@ -934,6 +935,7 @@ static int qusb_phy_probe(struct platform_device *pdev)
		return ret;
	}

	hold_phy_reset = of_property_read_bool(dev->of_node, "qcom,hold-reset");
	ret = of_property_read_u32_array(dev->of_node, "qcom,vdd-voltage-level",
					 (u32 *) qphy->vdd_levels,
					 ARRAY_SIZE(qphy->vdd_levels));
@@ -975,6 +977,14 @@ static int qusb_phy_probe(struct platform_device *pdev)
		qphy->phy.notify_disconnect     = qusb_phy_notify_disconnect;
	}

	/*
	 * On some platforms multiple QUSB PHYs are available. If QUSB PHY is
	 * not used, there is leakage current seen with QUSB PHY related voltage
	 * rail. Hence keep QUSB PHY into reset state explicitly here.
	 */
	if (hold_phy_reset)
		clk_reset(qphy->phy_reset, CLK_RESET_ASSERT);

	ret = usb_add_phy_dev(&qphy->phy);
	return ret;
}