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

Commit 71a5d7ed authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ARM: dts: msm: add dpdm regulator for smb1351 of qcs405"

parents 9ec26f12 820d5139
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1076,6 +1076,7 @@
		pinctrl-names = "default";
		pinctrl-0 = <&smb_stat>;
		qcom,switch-freq = <2>;
		dpdm-supply = <&usb2_phy0>;
	};
};

+0 −6
Original line number Diff line number Diff line
@@ -426,17 +426,14 @@ static int msm_snps_dpdm_regulator_enable(struct regulator_dev *rdev)
	int ret = 0;
	struct msm_snps_hsphy *phy = rdev_get_drvdata(rdev);

	mutex_lock(&phy->phy_lock);
	if (phy->dpdm_enable) {
		dev_dbg(phy->phy.dev, "%s: DP DM regulator already enabled\n",
								__func__);
		mutex_unlock(&phy->phy_lock);
		return 0;
	}

	msm_snps_hsphy_enable_regulators(phy);
	phy->dpdm_enable = true;
	mutex_unlock(&phy->phy_lock);

	return ret;
}
@@ -446,17 +443,14 @@ static int msm_snps_dpdm_regulator_disable(struct regulator_dev *rdev)
	int ret = 0;
	struct msm_snps_hsphy *phy = rdev_get_drvdata(rdev);

	mutex_lock(&phy->phy_lock);
	if (!phy->dpdm_enable) {
		dev_dbg(phy->phy.dev, "%s: DP DM regulator already enabled\n",
								__func__);
		mutex_unlock(&phy->phy_lock);
		return 0;
	}

	msm_snps_hsphy_disable_regulators(phy);
	phy->dpdm_enable = false;
	mutex_unlock(&phy->phy_lock);

	return ret;
}