From: henry.tsou Date: Thu, 21 Nov 2019 07:15:32 +0000 (+0800) Subject: PDVFS: enable PDVFS feature [1/2] X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=07eef3fcdd88fd85bb5c78c678f6bc066fcaa0a8;p=GitHub%2FLineageOS%2FG12%2Fandroid_kernel_amlogic_linux-4.9.git PDVFS: enable PDVFS feature [1/2] PD#GH-122 Problem: Due to we has run out of thermal budget at Sabrina Gaming scenario, so the 200mW increase from new DVFS table will be a risk for us. So we need smart DVFS table for more power saving Solution: Enable PDVFS feature Verify: Sabrina-P2 Sabrina-P1 Change-Id: Iea2e351fac765c8fb821603fa6724117cd9c7673 --- diff --git a/arch/arm/boot/dts/amlogic/sm1_s905d3_sabrina.dts b/arch/arm/boot/dts/amlogic/sm1_s905d3_sabrina.dts index cf1a86e8e5e8..305e9a549eb7 100644 --- a/arch/arm/boot/dts/amlogic/sm1_s905d3_sabrina.dts +++ b/arch/arm/boot/dts/amlogic/sm1_s905d3_sabrina.dts @@ -989,51 +989,159 @@ opp00 { opp-hz = /bits/ 64 <100000000>; - opp-microvolt = <730000>; + opp-microvolt = <760000>; }; opp01 { opp-hz = /bits/ 64 <250000000>; - opp-microvolt = <730000>; + opp-microvolt = <760000>; }; opp02 { opp-hz = /bits/ 64 <500000000>; - opp-microvolt = <730000>; + opp-microvolt = <760000>; }; opp03 { opp-hz = /bits/ 64 <667000000>; - opp-microvolt = <750000>; + opp-microvolt = <780000>; }; opp04 { opp-hz = /bits/ 64 <1000000000>; - opp-microvolt = <770000>; + opp-microvolt = <800000>; }; opp05 { opp-hz = /bits/ 64 <1200000000>; - opp-microvolt = <780000>; + opp-microvolt = <810000>; }; opp06 { opp-hz = /bits/ 64 <1404000000>; - opp-microvolt = <790000>; + opp-microvolt = <820000>; }; opp07 { opp-hz = /bits/ 64 <1512000000>; + opp-microvolt = <830000>; + }; + opp08 { + opp-hz = /bits/ 64 <1608000000>; + opp-microvolt = <860000>; + }; + opp09 { + opp-hz = /bits/ 64 <1704000000>; + opp-microvolt = <900000>; + }; + opp10 { + opp-hz = /bits/ 64 <1800000000>; + opp-microvolt = <940000>; + }; + opp11 { + opp-hz = /bits/ 64 <1908000000>; + opp-microvolt = <970000>; + }; + }; + + cpu_opp_table1: cpu_opp_table1 { + compatible = "operating-points-v2"; + opp-shared; + + opp00 { + opp-hz = /bits/ 64 <100000000>; + opp-microvolt = <760000>; + }; + opp01 { + opp-hz = /bits/ 64 <250000000>; + opp-microvolt = <760000>; + }; + opp02 { + opp-hz = /bits/ 64 <500000000>; + opp-microvolt = <760000>; + }; + opp03 { + opp-hz = /bits/ 64 <667000000>; + opp-microvolt = <780000>; + }; + opp04 { + opp-hz = /bits/ 64 <1000000000>; opp-microvolt = <800000>; }; + opp05 { + opp-hz = /bits/ 64 <1200000000>; + opp-microvolt = <810000>; + }; + opp06 { + opp-hz = /bits/ 64 <1404000000>; + opp-microvolt = <820000>; + }; + opp07 { + opp-hz = /bits/ 64 <1500000000>; + opp-microvolt = <830000>; + }; opp08 { opp-hz = /bits/ 64 <1608000000>; + opp-microvolt = <860000>; + }; + opp09 { + opp-hz = /bits/ 64 <1704000000>; + opp-microvolt = <900000>; + }; + opp10 { + opp-hz = /bits/ 64 <1800000000>; + opp-microvolt = <910000>; + }; + opp11 { + opp-hz = /bits/ 64 <1908000000>; + opp-microvolt = <910000>; + }; + }; + + cpu_opp_table2: cpu_opp_table2 { + compatible = "operating-points-v2"; + opp-shared; + + opp00 { + opp-hz = /bits/ 64 <100000000>; + opp-microvolt = <760000>; + }; + opp01 { + opp-hz = /bits/ 64 <250000000>; + opp-microvolt = <760000>; + }; + opp02 { + opp-hz = /bits/ 64 <500000000>; + opp-microvolt = <760000>; + }; + opp03 { + opp-hz = /bits/ 64 <667000000>; + opp-microvolt = <780000>; + }; + opp04 { + opp-hz = /bits/ 64 <1000000000>; + opp-microvolt = <800000>; + }; + opp05 { + opp-hz = /bits/ 64 <1200000000>; opp-microvolt = <810000>; }; + opp06 { + opp-hz = /bits/ 64 <1404000000>; + opp-microvolt = <820000>; + }; + opp07 { + opp-hz = /bits/ 64 <1500000000>; + opp-microvolt = <830000>; + }; + opp08 { + opp-hz = /bits/ 64 <1608000000>; + opp-microvolt = <860000>; + }; opp09 { opp-hz = /bits/ 64 <1704000000>; - opp-microvolt = <850000>; + opp-microvolt = <860000>; }; opp10 { opp-hz = /bits/ 64 <1800000000>; - opp-microvolt = <900000>; + opp-microvolt = <860000>; }; opp11 { opp-hz = /bits/ 64 <1908000000>; - opp-microvolt = <950000>; + opp-microvolt = <860000>; }; }; @@ -1046,6 +1154,38 @@ }; /* end of / */ +&CPU0 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + +&CPU1 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + +&CPU2 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + +&CPU3 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + &meson_fb { status = "okay"; display_size_default = <1920 1080 1920 2160 32>; diff --git a/arch/arm64/boot/dts/amlogic/sm1_s905d3_sabrina.dts b/arch/arm64/boot/dts/amlogic/sm1_s905d3_sabrina.dts index 23ea8f97be9f..211c216af0d6 100644 --- a/arch/arm64/boot/dts/amlogic/sm1_s905d3_sabrina.dts +++ b/arch/arm64/boot/dts/amlogic/sm1_s905d3_sabrina.dts @@ -1029,7 +1029,115 @@ }; opp11 { opp-hz = /bits/ 64 <1908000000>; - opp-microvolt = <1000000>; + opp-microvolt = <970000>; + }; + }; + + cpu_opp_table1: cpu_opp_table1 { + compatible = "operating-points-v2"; + opp-shared; + + opp00 { + opp-hz = /bits/ 64 <100000000>; + opp-microvolt = <760000>; + }; + opp01 { + opp-hz = /bits/ 64 <250000000>; + opp-microvolt = <760000>; + }; + opp02 { + opp-hz = /bits/ 64 <500000000>; + opp-microvolt = <760000>; + }; + opp03 { + opp-hz = /bits/ 64 <667000000>; + opp-microvolt = <780000>; + }; + opp04 { + opp-hz = /bits/ 64 <1000000000>; + opp-microvolt = <800000>; + }; + opp05 { + opp-hz = /bits/ 64 <1200000000>; + opp-microvolt = <810000>; + }; + opp06 { + opp-hz = /bits/ 64 <1404000000>; + opp-microvolt = <820000>; + }; + opp07 { + opp-hz = /bits/ 64 <1500000000>; + opp-microvolt = <830000>; + }; + opp08 { + opp-hz = /bits/ 64 <1608000000>; + opp-microvolt = <860000>; + }; + opp09 { + opp-hz = /bits/ 64 <1704000000>; + opp-microvolt = <900000>; + }; + opp10 { + opp-hz = /bits/ 64 <1800000000>; + opp-microvolt = <910000>; + }; + opp11 { + opp-hz = /bits/ 64 <1908000000>; + opp-microvolt = <910000>; + }; + }; + + cpu_opp_table2: cpu_opp_table2 { + compatible = "operating-points-v2"; + opp-shared; + + opp00 { + opp-hz = /bits/ 64 <100000000>; + opp-microvolt = <760000>; + }; + opp01 { + opp-hz = /bits/ 64 <250000000>; + opp-microvolt = <760000>; + }; + opp02 { + opp-hz = /bits/ 64 <500000000>; + opp-microvolt = <760000>; + }; + opp03 { + opp-hz = /bits/ 64 <667000000>; + opp-microvolt = <780000>; + }; + opp04 { + opp-hz = /bits/ 64 <1000000000>; + opp-microvolt = <800000>; + }; + opp05 { + opp-hz = /bits/ 64 <1200000000>; + opp-microvolt = <810000>; + }; + opp06 { + opp-hz = /bits/ 64 <1404000000>; + opp-microvolt = <820000>; + }; + opp07 { + opp-hz = /bits/ 64 <1500000000>; + opp-microvolt = <830000>; + }; + opp08 { + opp-hz = /bits/ 64 <1608000000>; + opp-microvolt = <860000>; + }; + opp09 { + opp-hz = /bits/ 64 <1704000000>; + opp-microvolt = <860000>; + }; + opp10 { + opp-hz = /bits/ 64 <1800000000>; + opp-microvolt = <860000>; + }; + opp11 { + opp-hz = /bits/ 64 <1908000000>; + opp-microvolt = <860000>; }; }; @@ -1042,6 +1150,38 @@ }; /* end of / */ +&CPU0 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + +&CPU1 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + +&CPU2 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + +&CPU3 { + /*set multi table cpufreq max*/ + multi_tables_available; + operating-points-v2 = <&cpu_opp_table0>, + <&cpu_opp_table1>, + <&cpu_opp_table2>; +}; + &meson_fb { status = "okay"; display_size_default = <1920 1080 1920 2160 32>;