From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.1 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7C7B8C433DF for ; Wed, 5 Aug 2020 19:57:06 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5894F20842 for ; Wed, 5 Aug 2020 19:57:06 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="HYhDSNmO" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728458AbgHET5F (ORCPT ); Wed, 5 Aug 2020 15:57:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45438 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727998AbgHEQoM (ORCPT ); Wed, 5 Aug 2020 12:44:12 -0400 Received: from mail-il1-x142.google.com (mail-il1-x142.google.com [IPv6:2607:f8b0:4864:20::142]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CB433C08ED2B; Wed, 5 Aug 2020 06:17:29 -0700 (PDT) Received: by mail-il1-x142.google.com with SMTP id j9so33893460ilc.11; Wed, 05 Aug 2020 06:17:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=U9j+MufxMDRYF1VNGK/h8ZpxbV45735lCqjDi7az7Y4=; b=HYhDSNmOIeR8Tsx8WIrVaqjB1BsfWU/aDZd+mWUzIkl92tNvGHxuV98CEr4ICg5bZj 0hMqGfgpfY0LmImX9w5DtGi+O5L/JgjPyvAAnDDwcIFA+JiEH4lTU/iYTZ4kzSfyjVN/ APHqSnfypG1GSBKovRFe8+eUbJLog8nP7ypyeUlkdqpyuq3+fPS5sXRKdpZpTAHtttDW VsLqacvZOAeeZOqzobmFGX5eZWyQyVHa5ExdjZ8ZigsYZzuaQEYs7/LdG+R+u8I7iMWP JNNhNcHMSQRRLVOBUQiRIQY1q/eDk8A0E4ZlwRBXgQx4xECv3OiwvnkQxuUSm40BJZWG YuMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=U9j+MufxMDRYF1VNGK/h8ZpxbV45735lCqjDi7az7Y4=; b=h92tL9f5cpMt6h3GVoMA0UoUB3ySXn5whPYW9eiwm+bxH5U1fvlOhSCERFcYeI/WKT +9dd2EnuYS1oi7gbcm7snOKAueLtZO3RLFYqXTLbG9V9ZJ96PKKvWcCYYDEu56ULHSxr INyhRe6/ylaxuUWstTuX6GvIBGnVMy903fDTqnAaOvTsXgqL5Fz1w4e+aX15PHNMOtyR pmDuDnqmdRVhGf8oeB+r3X5o8v8QvUFTtN0s46+5TLeRV/xGmoLnMWbVwnRMrjodE4WS To3MHjpSCSOuUNaJw2b4qckGviptnnH/I98dGCy5bRY80/2I4K22G+oCfim2Wm4d8xnZ +OZA== X-Gm-Message-State: AOAM532OFR6m1OGh0SOcJMtrkciGM25VFBt8DO/F/s7Dg9GKMAgA8oLx 5rm6uYDnY1CGTCkrELPIgVMlaRLeE2BFLa93f8gnvg== X-Google-Smtp-Source: ABdhPJwHeDoHvq2FDyJUbZK5qgI7U+gsBRFp8nkzGnu2r/YdKckPQIeQukn5HdbnZh+8a/s0rnH4tJdWMvWvFKiyjHE= X-Received: by 2002:a92:60d:: with SMTP id x13mr3933276ilg.214.1596633448397; Wed, 05 Aug 2020 06:17:28 -0700 (PDT) MIME-Version: 1.0 References: <20191007220540.30690-1-aford173@gmail.com> <20191007220540.30690-2-aford173@gmail.com> In-Reply-To: <20191007220540.30690-2-aford173@gmail.com> From: Adam Ford Date: Wed, 5 Aug 2020 08:17:16 -0500 Message-ID: Subject: Re: [PATCH 2/2] ARM: dts: omap3: Add cpu trips and cooling map for omap34/36 families To: Linux-OMAP Cc: Adam Ford , "H. Nikolaus Schaller" , =?UTF-8?Q?Beno=C3=AEt_Cousson?= , Tony Lindgren , Rob Herring , Mark Rutland , Russell King , devicetree , Linux Kernel Mailing List , arm-soc Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Oct 7, 2019 at 5:06 PM Adam Ford wrote: > > The OMAP3530, OMAP3630, and DM3730 all show thresholds of 90C and 105C > depending on commercial or industrial temperature ratings. > > This patch expands the thermal information to include the limits of 90 > and 105C for alert and critical. It sets the coolings-cells for the > 34xx and 36xx CPU's which both point to omap3-cpu-thermal.dtsi. > > For boards who never use industrial temperatures, these can be > changed on their respective device trees with something like: > > &cpu_alert0 { > temperature = <85000>; /* millicelsius */ > }; > > &cpu_crit { > temperature = <90000>; /* millicelsius */ > }; > > Signed-off-by: Adam Ford > Tested-by: H. Nikolaus Schaller # on GTA04A5 with dm3730cbp100 > Tony, I know this is an old thread. I am trying to revisit some of the other issues that came about with this, but is there any way we can get patch 2/2 applied? It might not do anything unless the bandgap sensor is enabled, but it at least gets us one step closer for those who choose to enable it. With 1GHz support now available, it would be nice to have the precautions to protect the processor from running too fast when its too hot. thanks adam > diff --git a/arch/arm/boot/dts/omap3-cpu-thermal.dtsi b/arch/arm/boot/dts/omap3-cpu-thermal.dtsi > index 235ecfd61e2d..dfbd0cb0b00b 100644 > --- a/arch/arm/boot/dts/omap3-cpu-thermal.dtsi > +++ b/arch/arm/boot/dts/omap3-cpu-thermal.dtsi > @@ -17,4 +17,25 @@ cpu_thermal: cpu_thermal { > > /* sensor ID */ > thermal-sensors = <&bandgap 0>; > + > + cpu_trips: trips { > + cpu_alert0: cpu_alert { > + temperature = <90000>; /* millicelsius */ > + hysteresis = <2000>; /* millicelsius */ > + type = "passive"; > + }; > + cpu_crit: cpu_crit { > + temperature = <105000>; /* millicelsius */ > + hysteresis = <2000>; /* millicelsius */ > + type = "critical"; > + }; > + }; > + > + cpu_cooling_maps: cooling-maps { > + map0 { > + trip = <&cpu_alert0>; > + cooling-device = > + <&cpu THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; > + }; > + }; > }; > diff --git a/arch/arm/boot/dts/omap34xx.dtsi b/arch/arm/boot/dts/omap34xx.dtsi > index 7b09cbee8bb8..99a7161bebb2 100644 > --- a/arch/arm/boot/dts/omap34xx.dtsi > +++ b/arch/arm/boot/dts/omap34xx.dtsi > @@ -26,6 +26,7 @@ > 600000 1350000 > >; > clock-latency = <300000>; /* From legacy driver */ > + #cooling-cells = <2>; > }; > }; > > diff --git a/arch/arm/boot/dts/omap36xx.dtsi b/arch/arm/boot/dts/omap36xx.dtsi > index 1e552f08f120..8096b6ef0ae1 100644 > --- a/arch/arm/boot/dts/omap36xx.dtsi > +++ b/arch/arm/boot/dts/omap36xx.dtsi > @@ -28,6 +28,7 @@ > 800000 1325000 > >; > clock-latency = <300000>; /* From legacy driver */ > + #cooling-cells = <2>; > }; > }; > > -- > 2.17.1 >