From 92d0f966c2cafcae6d81f163d60d4a1386b4e8bf Mon Sep 17 00:00:00 2001 From: zhu Date: Mon, 22 Jul 2019 17:53:45 +0800 Subject: [PATCH] arm64: overlays-rockpi4: Add rk3399 overclocking support --- .../dts/rockchip/overlays-rockpi4/Makefile | 3 +- .../overlays-rockpi4/cpufreq-overlay.dts | 29 +++++++++++++++++++ .../rockchip/overlays-rockpi4/hw_intfc.conf | 3 ++ 3 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 arch/arm64/boot/dts/rockchip/overlays-rockpi4/cpufreq-overlay.dts diff --git a/arch/arm64/boot/dts/rockchip/overlays-rockpi4/Makefile b/arch/arm64/boot/dts/rockchip/overlays-rockpi4/Makefile index 22495d5ce18e8..4b8826779c7c0 100644 --- a/arch/arm64/boot/dts/rockchip/overlays-rockpi4/Makefile +++ b/arch/arm64/boot/dts/rockchip/overlays-rockpi4/Makefile @@ -13,7 +13,8 @@ dtbo-$(CONFIG_ARCH_ROCKCHIP) += \ spi1-flash.dtbo \ hifiberry-dac.dtbo \ hifiberry-dacplus.dtbo \ - raspberrypi-7-inch-lcd.dtbo + raspberrypi-7-inch-lcd.dtbo \ + cpufreq.dtbo targets += dtbs dtbs_install targets += $(dtbo-y) diff --git a/arch/arm64/boot/dts/rockchip/overlays-rockpi4/cpufreq-overlay.dts b/arch/arm64/boot/dts/rockchip/overlays-rockpi4/cpufreq-overlay.dts new file mode 100644 index 0000000000000..39c0e66d61f9a --- /dev/null +++ b/arch/arm64/boot/dts/rockchip/overlays-rockpi4/cpufreq-overlay.dts @@ -0,0 +1,29 @@ +/dts-v1/; +/plugin/; + +/ { + model = "ROCK PI 4B"; + compatible = "rockchip,rockpi","rockchip,rk3399"; + + fragment@0 { + target = <&cluster0_opp>; + + __overlay__ { + opp-1512000000 { + opp-hz = /bits/ 64 <1512000000>; + opp-microvolt = <1150000>; + }; + }; + }; + + fragment@1 { + target = <&cluster1_opp>; + + __overlay__ { + opp-2016000000 { + opp-hz = /bits/ 64 <2016000000>; + opp-microvolt = <1250000>; + }; + }; + }; +}; diff --git a/arch/arm64/boot/dts/rockchip/overlays-rockpi4/hw_intfc.conf b/arch/arm64/boot/dts/rockchip/overlays-rockpi4/hw_intfc.conf index 1e2f41d1b6057..8e81b315b0730 100644 --- a/arch/arm64/boot/dts/rockchip/overlays-rockpi4/hw_intfc.conf +++ b/arch/arm64/boot/dts/rockchip/overlays-rockpi4/hw_intfc.conf @@ -55,3 +55,6 @@ intfc:dtoverlay=console-on-ttyS2 #enable raspberry pi official 7 inch LCD support #intfc:dtoverlay=raspberrypi-7-inch-lcd + +# setting cpu frequency over-2GHz +#intfc:dtoverlay=cpufreq \ No newline at end of file