From patchwork Thu Jan 28 04:32:55 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Horman X-Patchwork-Id: 8146101 X-Patchwork-Delegate: horms@verge.net.au Return-Path: X-Original-To: patchwork-linux-renesas-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 4C6CE9F8AA for ; Thu, 28 Jan 2016 04:33:11 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A0C8920251 for ; Thu, 28 Jan 2016 04:33:10 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 44E7920122 for ; Thu, 28 Jan 2016 04:33:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S967671AbcA1EdI (ORCPT ); Wed, 27 Jan 2016 23:33:08 -0500 Received: from kirsty.vergenet.net ([202.4.237.240]:48608 "EHLO kirsty.vergenet.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S966525AbcA1EdI (ORCPT ); Wed, 27 Jan 2016 23:33:08 -0500 Received: from reginn.isobedori.kobe.vergenet.net (p5023-ipbfp803kobeminato.hyogo.ocn.ne.jp [123.221.39.23]) by kirsty.vergenet.net (Postfix) with ESMTPA id 2AA6E25B76D; Thu, 28 Jan 2016 15:33:05 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=verge.net.au; s=mail; t=1453955585; bh=KCIN3Uc4FZHZzl4D4bskvtzkr0J5H/+gg9Mx56Qp+es=; h=From:To:Cc:Subject:Date:From; b=lSrsBw64ppha5UGxcqVERlz8qh/yE9z/9fVs02z4+MuXIugqlgw+qAYkXug8TJkf0 gbMaPuMnXE+1NyLB1i/pAjc3DxGJAheg0jx6T5qLDkQGSYuYI9cwXhmp1q/SSYXYt0 0rgpnDelQrAfgzSSMoc05gs9EKkK7pCOC6Krb9Sc= Received: by reginn.isobedori.kobe.vergenet.net (Postfix, from userid 7100) id C03E29403D7; Thu, 28 Jan 2016 13:33:03 +0900 (JST) From: Simon Horman To: linux-renesas-soc@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, Magnus Damm , Simon Horman , Magnus Damm Subject: [PATCH/RFC] ARM: shmobile: r8a7794: Add thermal device to DT Date: Thu, 28 Jan 2016 13:32:55 +0900 Message-Id: <1453955575-32008-1-git-send-email-horms+renesas@verge.net.au> X-Mailer: git-send-email 2.1.4 Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP *** Currently does not work *** Not for upstream merge *** For informational purposes only Instantiate the thermal sensor in the r8a7794 device tree. Based on very similar work for the r8a7790 by Magnus Damm. Cc: Magnus Damm Signed-off-by: Simon Horman --- Hi Morimoto-san, as discussed briefly last week I am having some trouble enabling thermal for the r8a7794/alt. With this patch applied on top of renesas-devel-20160127-v4.5-rc1 I see: # dmesg | grep thermal [ 1.089897] rcar_thermal e61f0000.thermal: thermal sensor was broken [ 1.101225] rcar_thermal: probe of e61f0000.thermal failed with error -22 I also see this with "[PATCH] thermal: core: don't call unsupported trip on thermal_tripped_notify()" applied. Is this a kernel issue that you are aware of? Is there a possibility that there is a problem with my hardware? Any insight would be greatly appreciated. AFIK this is not urgent. --- arch/arm/boot/dts/r8a7794.dtsi | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/arch/arm/boot/dts/r8a7794.dtsi b/arch/arm/boot/dts/r8a7794.dtsi index 5d5d8cb41191..3b84bf3c1124 100644 --- a/arch/arm/boot/dts/r8a7794.dtsi +++ b/arch/arm/boot/dts/r8a7794.dtsi @@ -187,6 +187,14 @@ status = "disabled"; }; + thermal@e61f0000 { + compatible = "renesas,thermal-r8a7794", "renesas,rcar-thermal"; + reg = <0 0xe61f0000 0 0x14>, <0 0xe61f0100 0 0x38>; + interrupts = ; + clocks = <&mstp5_clks R8A7794_CLK_THERMAL>; + power-domains = <&cpg_clocks>; + }; + timer { compatible = "arm,armv7-timer"; interrupts = , @@ -1045,6 +1053,14 @@ clock-indices = ; clock-output-names = "irqc"; }; + mstp5_clks: mstp5_clks@e6150144 { + compatible = "renesas,r8a7794-mstp-clocks", "renesas,cpg-mstp-clocks"; + reg = <0 0xe6150144 0 4>, <0 0xe615003c 0 4>; + clocks = <&extal_clk>; + #clock-cells = <1>; + clock-indices = ; + clock-output-names = "thermal"; + }; mstp7_clks: mstp7_clks@e615014c { compatible = "renesas,r8a7794-mstp-clocks", "renesas,cpg-mstp-clocks"; reg = <0 0xe615014c 0 4>, <0 0xe61501c4 0 4>;