diff options
author | Linux Build Service Account <lnxbuild@localhost> | 2019-05-30 12:10:21 -0700 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2019-05-30 12:10:21 -0700 |
commit | 52e7331bd7cdbc20582603c706ff5c56f9159401 (patch) | |
tree | ec6b4fe3c7a8ad46607aec899ade3652c9d14176 | |
parent | 77f5afa425958e757eb7972747e352c13b95094c (diff) | |
parent | 91ecb1518676e515c6ebbb3d87a8a99b44ffc07d (diff) | |
download | vendor_qcom_opensource_power-52e7331bd7cdbc20582603c706ff5c56f9159401.tar.gz vendor_qcom_opensource_power-52e7331bd7cdbc20582603c706ff5c56f9159401.tar.bz2 vendor_qcom_opensource_power-52e7331bd7cdbc20582603c706ff5c56f9159401.zip |
Merge "power: Add config and makefiles" into power.lnx.2.0
-rw-r--r-- | config/kona/powerhint.xml | 54 | ||||
-rw-r--r-- | config/msmnile/powerhint.xml | 274 | ||||
-rw-r--r-- | power-vendor-board.mk | 1 | ||||
-rw-r--r-- | power-vendor-product.mk | 10 |
4 files changed, 339 insertions, 0 deletions
diff --git a/config/kona/powerhint.xml b/config/kona/powerhint.xml new file mode 100644 index 0000000..fa338f5 --- /dev/null +++ b/config/kona/powerhint.xml @@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="utf-8" ?> + +<!-- +/* Copyright (c) 2019, The Linux Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of The Linux Foundation nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +--> +<HintConfigs> + <Powerhint> + <!--video encode 30 fps--> + <Config + Id="0x00001203" Enable="true" Target="kona" + Resources="" /> + + <!--sustained performance--> + <Config + Id="0x00001206" Enable="true" Target="kona" + Resources=""/> + <!--vr mode--> + <Config + Id="0x00001207" Enable="true" Target="kona" + Resources=""/> + + <!--vr mode sustained performance--> + <Config + Id="0x00001301" Enable="true" Target="kona" + Resources=""/> + </Powerhint> +</HintConfigs> + diff --git a/config/msmnile/powerhint.xml b/config/msmnile/powerhint.xml new file mode 100644 index 0000000..71e9db1 --- /dev/null +++ b/config/msmnile/powerhint.xml @@ -0,0 +1,274 @@ +<?xml version="1.0" encoding="utf-8" ?> + +<!-- +/* Copyright (c) 2019, The Linux Foundation. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are + * met: + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of The Linux Foundation nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR + * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE + * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN + * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ +--> +<HintConfigs> + <Powerhint> + <!--video encode 30 fps--> + <Config + Id="0x00001203" Enable="true" Target="msmnile" Timeout="0" + Resources="" /> + + <!--sustained performance--> + <!-- B CPU - Cluster min freq ~1.05GHz --> + <!-- L CPU - Cluster min freq ~1.03GHz --> + <!-- B CPU - Cluster max freq ~1.80GHz --> + <!-- GPU - min pwrlevel 2 --> + <!-- GPU - max pwrlevel 0 --> + <!-- Max Prime CPUs 0 --> + <Config + Id="0x00001206" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x420, 0x40800100, 0x40C, 0x40804000, 0x70C, + 0X42804000, 0x2, 0X42808000, 0x0, 0x41004200, 0x0"/> + <!--vr mode--> + <Config + Id="0x00001207" Enable="true" Target="msmnile" Timeout="0" + Resources=""/> + + <!--vr mode sustained performance--> + <Config + Id="0x00001301" Enable="true" Target="msmnile" Timeout="0" + Resources=""/> + + <!-- same settings for all the VR power levels intentionally --> + + <!-- qvr level cpu1 gpu1 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x0000130A" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu1 gpu2 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x0000130B" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu1 gpu3 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x0000130C" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu2 gpu1 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x0000130D" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu2 gpu2 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x0000130E" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu2 gpu3 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x0000130F" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu3 gpu1 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x00001310" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu3 gpu2 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~.2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x00001311" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- qvr level cpu3 gpu3 --> + <!-- B CPU - Cluster min freq ~.864 Ghz --> + <!-- B CPU - Cluster max freq ~2.016 Ghz --> + <!-- L CPU - Cluster min freq ~.576 Ghz --> + <!-- L CPU - Cluster max freq ~1.267 Ghz --> + <!-- P CPU - PRIME CPU min freq ~.941 Ghz--> + <!-- P CPU - PRIME CPU max freq ~2.054Ghz --> + <!-- GPU - min pwrlevel 5 (freq 215 Mhz) --> + <!-- GPU - max pwrlevel 0 (freq 600 Mhz) --> + <!-- Min Big CPUs 3 --> + <!-- Min Prime CPUs 1 --> + <!-- Idefinite Duration --> + <Config + Id="0x00001312" Enable="true" Target="msmnile" Timeout="0" + Resources="0x40800000, 0x360, 0x40804000, 0x7E0, 0x40800100, 0x240, 0x40804100, 0x4F3, 0x40800200, 0x3AD, 0x40804200, 0x806, + 0x42804000, 0x5, 0x42808000, 0x0, 0x41000000, 0x3, 0x41000200, 0x1"/> + + <!-- camera general --> + <!--L CPU CORE 0 SCHED LOAD BOOST --> + <!--L CPU CORE 1 SCHED LOAD BOOST --> + <!--L CPU CORE 2 SCHED LOAD BOOST --> + <!--L CPU CORE 3 SCHED LOAD BOOST --> + <!--L CPU - Disable schedutil PL --> + <!--L CPU - Set hispeed load 99 --> + <!--LLC-DDR BWMON - Set sample_ms 10 --> + <!--CPU-LLC BWMON - Set sample_ms 10 --> + <!--LLC-DDR BWMON - Set io_percent 100 --> + <!--CPU-LLC BWMON - Set io_percent 100 --> + <!--CPU-LLC BWMON - Set hyst_length 0 --> + <!--LLC-DDR BWMON - Set hyst_length 0 --> + <!--CPU0-LLC MEM LAT - Set ratio_ceil 100 --> + <Config + Id="0x00001331" Enable="true" Timeout="0" Target="msmnile" + Resources="0x40C68100, 0xFFFFFFF6, 0x40C68110, 0xFFFFFFF6, 0x40C68120, 0xFFFFFFF6, + 0x40C68130, 0xFFFFFFF6,0x41444100, 0, 0x41440100, 0x63, + 0x4300C000, 0xA ,0x41820000, 0xA, 0x43004000, 0x64 ,0x41808000, 0x64, 0x4180C000, 0, 0x43008000, 0, 0x43420000, 0x64"/> + + <!-- camera 60fps --> + <!--L CPU CORE 0 SCHED LOAD BOOST --> + <!--L CPU CORE 1 SCHED LOAD BOOST --> + <!--L CPU CORE 2 SCHED LOAD BOOST --> + <!--L CPU CORE 3 SCHED LOAD BOOST --> + <!--L CPU - Disable schedutil PL --> + <!--L CPU - Set hispeed load 95 --> + <!--LLC-DDR BWMON - Set sample_ms 20 --> + <!--CPU-LLC BWMON - Set sample_ms 20 --> + <Config + Id="0x00001332" Enable="true" Timeout="0" Target="msmnile" + Resources="0x40C68100, 0xFFFFFFF6, 0x40C68110, 0xFFFFFFF6, 0x40C68120, 0xFFFFFFF6, + 0x40C68130, 0xFFFFFFF6,0x41444100, 0, 0x41440100, 0x5F, 0x4300C000, 0x14 ,0x41820000, 0x14"/> + + <!-- camera HFR --> + <!--L CPU CORE 0 SCHED LOAD BOOST --> + <!--L CPU CORE 1 SCHED LOAD BOOST --> + <!--L CPU CORE 2 SCHED LOAD BOOST --> + <!--L CPU CORE 3 SCHED LOAD BOOST --> + <!--LLC-DDR BWMON - Set sample_ms 10 --> + <!--CPU-LLC BWMON - Set sample_ms 10 --> + <Config + Id="0x00001333" Enable="true" Timeout="0" Target="msmnile" + Resources="0x40C68100, 0xFFFFFFF6, 0x40C68110, 0xFFFFFFF6, 0x40C68120, 0xFFFFFFF6, + 0x40C68130, 0xFFFFFFF6, 0x4300C000, 0xA ,0x41820000, 0xA"/> + + <!-- camera 480fps - HFR --> + <!--L CPU CORE 0 SCHED LOAD BOOST --> + <!--L CPU CORE 1 SCHED LOAD BOOST --> + <!--L CPU CORE 2 SCHED LOAD BOOST --> + <!--L CPU CORE 3 SCHED LOAD BOOST --> + <!--LLC-DDR BWMON - Set sample_ms 10 --> + <!--CPU-LLC BWMON - Set sample_ms 10 --> + <Config + Id="0x00001334" Enable="true" Timeout="0" Target="msmnile" + Resources="0x40C68100, 0xFFFFFFF6, 0x40C68110, 0xFFFFFFF6, 0x40C68120, 0xFFFFFFF6, + 0x40C68130, 0xFFFFFFF6, 0x4300C000, 0xA ,0x41820000, 0xA"/> + </Powerhint> +</HintConfigs> + diff --git a/power-vendor-board.mk b/power-vendor-board.mk new file mode 100644 index 0000000..23d97aa --- /dev/null +++ b/power-vendor-board.mk @@ -0,0 +1 @@ +TARGET_USES_NON_LEGACY_POWERHAL := true diff --git a/power-vendor-product.mk b/power-vendor-product.mk new file mode 100644 index 0000000..c0dfbc5 --- /dev/null +++ b/power-vendor-product.mk @@ -0,0 +1,10 @@ +#Power product definitions +PRODUCT_PACKAGES += android.hardware.power@1.2-impl +PRODUCT_PACKAGES += android.hardware.power@1.2-service + +#Powerhint File +ifeq ($(TARGET_BOARD_PLATFORM),msmnile) +PRODUCT_COPY_FILES += vendor/qcom/opensource/power/config/msmnile/powerhint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.xml +else ifeq ($(TARGET_BOARD_PLATFORM),kona) +PRODUCT_COPY_FILES += vendor/qcom/opensource/power/config/kona/powerhint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/powerhint.xml +endif |