From patchwork Thu Jan 24 15:12:11 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Horman X-Patchwork-Id: 10779187 X-Patchwork-Delegate: horms@verge.net.au Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 815BE13B4 for ; Thu, 24 Jan 2019 15:12:56 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 70C3E30D85 for ; Thu, 24 Jan 2019 15:12:56 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6E78A31111; Thu, 24 Jan 2019 15:12:56 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F251630D85 for ; Thu, 24 Jan 2019 15:12:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728451AbfAXPMz (ORCPT ); Thu, 24 Jan 2019 10:12:55 -0500 Received: from kirsty.vergenet.net ([202.4.237.240]:39115 "EHLO kirsty.vergenet.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727566AbfAXPMz (ORCPT ); Thu, 24 Jan 2019 10:12:55 -0500 Received: from reginn.horms.nl (watermunt.horms.nl [80.127.179.77]) by kirsty.vergenet.net (Postfix) with ESMTPA id DE42525BEE4; Fri, 25 Jan 2019 02:12:42 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=verge.net.au; s=mail; t=1548342763; bh=V/VYZfXMlzwifpfno6K1W+fHMAezSQXBQvACGg8dVyw=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ghf7iNPe12yar5XT75vQkwD6QJo8m/+5LAmrj9+gR5m/imxClXeQXPuCZmZUOva2X cG/lhERD4m9Fv4VLA3dYT1ZYwVMD8sPyTZ6qVp3Ck5+YhKkgmymTBHp276kLIkOvdE UT2q4pEjk4zhY692WqiIG0oJ4YmanFLDOwDcc50U= Received: by reginn.horms.nl (Postfix, from userid 7100) id 2C3E3940471; Thu, 24 Jan 2019 16:12:40 +0100 (CET) From: Simon Horman To: linux-renesas-soc@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, Magnus Damm , Fabrizio Castro , Simon Horman Subject: [PATCH 17/44] arm64: dts: renesas: r8a774c0: Add thermal support Date: Thu, 24 Jan 2019 16:12:11 +0100 Message-Id: <6e9dd34eb6b0ffb9e5ff7f18c58193737d24cb37.1548233325.git.horms+renesas@verge.net.au> X-Mailer: git-send-email 2.11.0 In-Reply-To: References: Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Fabrizio Castro This patch adds the thermal device node and the thermal-zones node to the SoC specific dtsi for the RZ/G2E. Signed-off-by: Fabrizio Castro Reviewed-by: Geert Uytterhoeven Signed-off-by: Simon Horman --- arch/arm64/boot/dts/renesas/r8a774c0.dtsi | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/arch/arm64/boot/dts/renesas/r8a774c0.dtsi b/arch/arm64/boot/dts/renesas/r8a774c0.dtsi index 446cab189c10..9532d2960f9c 100644 --- a/arch/arm64/boot/dts/renesas/r8a774c0.dtsi +++ b/arch/arm64/boot/dts/renesas/r8a774c0.dtsi @@ -255,6 +255,18 @@ #power-domain-cells = <1>; }; + thermal: thermal@e6190000 { + compatible = "renesas,thermal-r8a774c0"; + reg = <0 0xe6190000 0 0x10>, <0 0xe6190100 0 0x38>; + interrupts = , + , + ; + clocks = <&cpg CPG_MOD 522>; + power-domains = <&sysc R8A774C0_PD_ALWAYS_ON>; + resets = <&cpg 522>; + #thermal-sensor-cells = <0>; + }; + intc_ex: interrupt-controller@e61c0000 { compatible = "renesas,intc-ex-r8a774c0", "renesas,irqc"; #interrupt-cells = <2>; @@ -902,6 +914,25 @@ }; }; + thermal-zones { + cpu-thermal { + polling-delay-passive = <250>; + polling-delay = <1000>; + thermal-sensors = <&thermal>; + + trips { + cpu-crit { + temperature = <120000>; + hysteresis = <2000>; + type = "critical"; + }; + }; + + cooling-maps { + }; + }; + }; + timer { compatible = "arm,armv8-timer"; interrupts-extended = <&gic GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(2) | IRQ_TYPE_LEVEL_LOW)>,