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

Commit 10159460 authored by Osvaldo Banuelos's avatar Osvaldo Banuelos
Browse files

ARM: dts: msm: add support for VDD_APC CPR speed bins 2/3 for msm8998v2



Update the VDD_APC0 and VDD_APC1 CPR devices to support two additional
speed bins. This allows CPR operation on bin 2 and 3 parts which have
different performance cluster frequency configurations compared to bin
0 and 1.

CRs-Fixed: 1086294
Change-Id: Id0854f1094ee3e4d4b1961f98a77003f7bcca1da
Signed-off-by: default avatarOsvaldo Banuelos <osvaldob@codeaurora.org>
parent 58f0a952
Loading
Loading
Loading
Loading
+183 −65
Original line number Diff line number Diff line
@@ -363,29 +363,14 @@
&apc0_pwrcl_vreg {
	regulator-max-microvolt = <23>;

	qcom,cpr-fuse-combos = <16>;
	qcom,cpr-speed-bins = <2>;
	qcom,cpr-speed-bin-corners = <22 22>;
	qcom,cpr-corners =
		/* Speed bin 0 */
		<22 22 22 22 22 22 22 22>,
		/* Speed bin 1 */
		<22 22 22 22 22 22 22 22>;
	qcom,cpr-fuse-combos = <32>;
	qcom,cpr-speed-bins = <4>;
	qcom,cpr-speed-bin-corners = <22 22 22 22>;
	qcom,cpr-corners = <22>;

	qcom,cpr-corner-fmax-map =
		/* Speed bin 0 */
		<8 11 18 22>,
		/* Speed bin 1 */
		<8 11 18 22>;
	qcom,cpr-corner-fmax-map = <8 11 18 22>;

	qcom,cpr-voltage-ceiling =
		/* Speed bin 0 */
		<828000  828000  828000  828000  828000
		 828000  828000  828000  828000  828000
		 828000  900000  900000  900000  900000
		 900000  900000  900000  952000  952000
		1056000 1056000>,
		/* Speed bin 1 */
		<828000  828000  828000  828000  828000
		 828000  828000  828000  828000  828000
		 828000  900000  900000  900000  900000
@@ -393,13 +378,6 @@
		1056000 1056000>;

	qcom,cpr-voltage-floor =
		/* Speed bin 0 */
		<568000  568000  568000  568000  568000
		 568000  568000  568000  568000  568000
		 568000  632000  632000  632000  632000
		 632000  632000  632000  712000  712000
		 772000  772000>,
		/* Speed bin 1 */
		<568000  568000  568000  568000  568000
		 568000  568000  568000  568000  568000
		 568000  632000  632000  632000  632000
@@ -407,14 +385,6 @@
		 772000  772000>;

	qcom,cpr-floor-to-ceiling-max-range =
		/* Speed bin 0 */
		<32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  40000  40000
		 40000  40000>,
		/* Speed bin 1 */
		<32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
@@ -423,16 +393,6 @@
		 40000  40000>;

	qcom,corner-frequencies =
		/* Speed bin 0 */
		<300000000  364800000  441600000
		 518400000  595200000  672000000
		 748800000  825600000  883200000
		 960000000 1036800000 1094400000
		1171200000 1248000000 1324800000
		1401600000 1478400000 1555200000
		1670400000 1747200000 1824000000
		1900800000>,
		/* Speed bin 1 */
		<300000000  364800000  441600000
		 518400000  595200000  672000000
		 748800000  825600000  883200000
@@ -474,6 +434,24 @@
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		/* Speed bin 2 */
		<40000  24000   12000  30000>,
		<40000  24000   12000  30000>,
		<40000  24000   12000  30000>,
		<40000  24000   12000  30000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		/* Speed bin 3 */
		<40000  24000   12000  30000>,
		<40000  24000   12000  30000>,
		<40000  24000   12000  30000>,
		<40000  24000   12000  30000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>,
		<25000   9000  (-3000) 15000>;

	qcom,cpr-closed-loop-voltage-fuse-adjustment =
@@ -494,15 +472,35 @@
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		/* Speed bin 2 */
		<20000  26000   12000  30000>,
		<20000  26000   12000  30000>,
		<20000  26000   12000  30000>,
		<20000  26000   12000  30000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		/* Speed bin 3 */
		<20000  26000   12000  30000>,
		<20000  26000   12000  30000>,
		<20000  26000   12000  30000>,
		<20000  26000   12000  30000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>,
		< 5000  11000  (-3000) 15000>;

	qcom,allow-voltage-interpolation;
	qcom,allow-quotient-interpolation;
	qcom,cpr-scaled-open-loop-voltage-as-ceiling;

	qcom,cpr-aging-ref-corner = <22 22>;
	qcom,cpr-aging-ref-corner = <22>;
	qcom,cpr-aging-ro-scaling-factor = <1620>;
	qcom,allow-aging-voltage-adjustment =
		<0 0 0 0 1 1 1 1>,
		<0 0 0 0 1 1 1 1>,
		<0 0 0 0 1 1 1 1>,
		<0 0 0 0 1 1 1 1>;
};
@@ -514,22 +512,30 @@
};

&apc1_perfcl_vreg {
	regulator-max-microvolt = <31>;
	regulator-max-microvolt = <33>;

	qcom,cpr-fuse-combos = <16>;
	qcom,cpr-speed-bins = <2>;
	qcom,cpr-speed-bin-corners = <30 26>;
	qcom,cpr-fuse-combos = <32>;
	qcom,cpr-speed-bins = <4>;
	qcom,cpr-speed-bin-corners = <32 26 30 31>;
	qcom,cpr-corners =
		/* Speed bin 0 */
		<30 30 30 30 30 30 30 30>,
		<32 32 32 32 32 32 32 32>,
		/* Speed bin 1 */
		<26 26 26 26 26 26 26 26>;
		<26 26 26 26 26 26 26 26>,
		/* Speed bin 2 */
		<30 30 30 30 30 30 30 30>,
		/* Speed bin 3 */
		<31 31 31 31 31 31 31 31>;

	qcom,cpr-corner-fmax-map =
		/* Speed bin 0 */
		<8 12 20 30>,
		<8 12 20 32>,
		/* Speed bin 1 */
		<8 12 20 26>;
		<8 12 20 26>,
		/* Speed bin 2 */
		<8 12 20 30>,
		/* Speed bin 3 */
		<8 12 20 31>;

	qcom,cpr-voltage-ceiling =
		/* Speed bin 0 */
@@ -537,15 +543,31 @@
		 828000  828000  828000  828000  828000
		 828000  828000  900000  900000  900000
		 900000  900000  900000  900000  900000
		 952000  952000  952000 1056000 1056000
		1056000 1056000 1056000 1056000 1056000>,
		 952000  952000  952000 1136000 1136000
		1136000 1136000 1136000 1136000 1136000
		1136000 1136000>,
		/* Speed bin 1 */
		<828000  828000  828000  828000  828000
		 828000  828000  828000  828000  828000
		 828000  828000  900000  900000  900000
		 900000  900000  900000  900000  900000
		 952000  952000  952000 1056000 1056000
		1056000>;
		 952000  952000  952000 1136000 1136000
		1136000>,
		/* Speed bin 2 */
		<828000  828000  828000  828000  828000
		 828000  828000  828000  828000  828000
		 828000  828000  900000  900000  900000
		 900000  900000  900000  900000  900000
		 952000  952000  952000 1136000 1136000
		1136000 1136000 1136000 1136000 1136000>,
		/* Speed bin 3 */
		<828000  828000  828000  828000  828000
		 828000  828000  828000  828000  828000
		 828000  828000  900000  900000  900000
		 900000  900000  900000  900000  900000
		 952000  952000  952000 1136000 1136000
		1136000 1136000 1136000 1136000 1136000
		1136000>;

	qcom,cpr-voltage-floor =
		/* Speed bin 0 */
@@ -554,13 +576,29 @@
		 568000  568000  632000  632000  632000
		 632000  632000  632000  632000  632000
		 712000  712000  712000  772000  772000
		 772000  772000  772000  772000  772000>,
		 772000  772000  772000  772000  772000
		 772000  772000>,
		/* Speed bin 1 */
		<568000  568000  568000  568000  568000
		 568000  568000  568000  568000  568000
		 568000  568000  632000  632000  632000
		 632000  632000  632000  632000  632000
		 712000  712000  712000  772000  772000
		 772000>,
		/* Speed bin 2 */
		<568000  568000  568000  568000  568000
		 568000  568000  568000  568000  568000
		 568000  568000  632000  632000  632000
		 632000  632000  632000  632000  632000
		 712000  712000  712000  772000  772000
		 772000  772000  772000  772000  772000>,
		/* Speed bin 3 */
		<568000  568000  568000  568000  568000
		 568000  568000  568000  568000  568000
		 568000  568000  632000  632000  632000
		 632000  632000  632000  632000  632000
		 712000  712000  712000  772000  772000
		 772000  772000  772000  772000  772000
		 772000>;

	qcom,cpr-floor-to-ceiling-max-range =
@@ -572,7 +610,7 @@
		 32000  32000  32000  32000
		 40000  40000  40000  40000
		 40000  40000  40000  40000
		 40000  40000>,
		 40000  40000  40000  40000>,
		/* Speed bin 1 */
		<32000  32000  32000  32000
		 32000  32000  32000  32000
@@ -580,7 +618,25 @@
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 40000  40000  40000  40000
		 40000  40000>;
		 40000  40000>,
		/* Speed bin 2 */
		<32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 40000  40000  40000  40000
		 40000  40000  40000  40000
		 40000  40000>,
		/* Speed bin 3 */
		<32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 32000  32000  32000  32000
		 40000  40000  40000  40000
		 40000  40000  40000  40000
		 40000  40000  40000>;

	qcom,corner-frequencies =
		/* Speed bin 0 */
@@ -592,8 +648,9 @@
		1420800000 1497600000 1574400000
		1651200000 1728000000 1804800000
		1881600000 1958400000 2035200000
		2112000000 2188800000 2265600000
		2342400000 2419200000 2496000000>,
		2112000000 2208000000 2265600000
		2342400000 2419200000 2457600000
		2476800000 2496000000>,
		/* Speed bin 1 */
		<300000000  345600000  422400000
		 499200000  576000000  652800000
@@ -603,7 +660,30 @@
		1420800000 1497600000 1574400000
		1651200000 1728000000 1804800000
		1881600000 1958400000 2035200000
		2112000000 2208000000>;
		2112000000 2208000000>,
		/* Speed bin 2 */
		<300000000  345600000  422400000
		 499200000  576000000  652800000
		 729600000  806400000  902400000
		 979200000 1056000000 1132800000
		1190400000 1267200000 1344000000
		1420800000 1497600000 1574400000
		1651200000 1728000000 1804800000
		1881600000 1958400000 2035200000
		2112000000 2208000000 2265600000
		2323200000 2342400000 2361600000>,
		/* Speed bin 3 */
		<300000000  345600000  422400000
		 499200000  576000000  652800000
		 729600000  806400000  902400000
		 979200000 1056000000 1132800000
		1190400000 1267200000 1344000000
		1420800000 1497600000 1574400000
		1651200000 1728000000 1804800000
		1881600000 1958400000 2035200000
		2112000000 2208000000 2265600000
		2323200000 2342400000 2361600000
		2457600000>;

	qcom,cpr-ro-scaling-factor =
		<2857 3057 2828 2952 2699 2798 2446
@@ -637,9 +717,45 @@
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		/* Speed bin 2 */
		<  8000        0   12000  52000>,
		<  8000        0   12000  52000>,
		<  8000        0   12000  52000>,
		<  8000        0   12000  52000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		/* Speed bin 3 */
		<  8000        0   12000  52000>,
		<  8000        0   12000  52000>,
		<  8000        0   12000  52000>,
		<  8000        0   12000  52000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>,
		<(-7000) (-15000) (-3000) 37000>;

	qcom,cpr-closed-loop-voltage-fuse-adjustment =
		/* Speed bin 0 */
		<      0        0   12000  50000>,
		<      0        0   12000  50000>,
		<      0        0   12000  50000>,
		<      0        0   12000  50000>,
		<(-15000) (-15000) (-3000) 35000>,
		<(-15000) (-15000) (-3000) 35000>,
		<(-15000) (-15000) (-3000) 35000>,
		<(-15000) (-15000) (-3000) 35000>,
		/* Speed bin 1 */
		<      0        0   12000  50000>,
		<      0        0   12000  50000>,
		<      0        0   12000  50000>,
		<      0        0   12000  50000>,
		<(-15000) (-15000) (-3000) 35000>,
		<(-15000) (-15000) (-3000) 35000>,
		<(-15000) (-15000) (-3000) 35000>,
		<(-15000) (-15000) (-3000) 35000>,
		/* Speed bin 0 */
		<      0        0   12000  50000>,
		<      0        0   12000  50000>,
@@ -663,9 +779,11 @@
	qcom,allow-quotient-interpolation;
	qcom,cpr-scaled-open-loop-voltage-as-ceiling;

	qcom,cpr-aging-ref-corner = <30 26>;
	qcom,cpr-aging-ref-corner = <32 26 30 31>;
	qcom,cpr-aging-ro-scaling-factor = <1700>;
	qcom,allow-aging-voltage-adjustment =
		<0 0 0 0 1 1 1 1>,
		<0 0 0 0 1 1 1 1>,
		<0 0 0 0 1 1 1 1>,
		<0 0 0 0 1 1 1 1>;
};