From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andre Przywara Subject: [PATCH 6/8] arm64: dts: allwinner: a64: add SCPI sensors support Date: Fri, 30 Jun 2017 10:56:06 +0100 Message-ID: <20170630095608.24943-7-andre.przywara@arm.com> References: <20170630095608.24943-1-andre.przywara@arm.com> Reply-To: andre.przywara-5wv7dgnIgG8@public.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: Sender: linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org In-Reply-To: <20170630095608.24943-1-andre.przywara-5wv7dgnIgG8@public.gmane.org> List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , To: Jassi Brar , Sudeep Holla Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org, Maxime Ripard , Chen-Yu Tsai , Icenowy Zheng , Rob Herring , Mark Rutland , devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: devicetree@vger.kernel.org The SCPI protocol allows various sensors to be exposed to the OS. The list of supported sensors (and their kind) is provided by the SCPI provider, which is in ARM Trusted Firmware. The current implementation exports the temperature sensors, for instance. Since the temperature sensor requires a clock to be running, we set a fixed clock rate for this particular clock to prevent the Linux driver from turning it off. Signed-off-by: Andre Przywara --- arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi index 58c3675..7cb1b04 100644 --- a/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi +++ b/arch/arm64/boot/dts/allwinner/sun50i-a64.dtsi @@ -163,6 +163,11 @@ clock-output-names = "cpu_clk"; }; }; + + scpi_sensors0: sensors { + compatible = "arm,scpi-sensors"; + #thermal-sensor-cells = <1>; + }; }; soc { @@ -307,6 +312,8 @@ clock-names = "hosc", "losc"; #clock-cells = <1>; #reset-cells = <1>; + assigned-clocks = <&ccu CLK_THS>; + assigned-clock-rates = <4000000>; }; pio: pinctrl@1c20800 { -- 2.9.0