Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp2961714rwi; Tue, 11 Oct 2022 16:19:53 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5biLGitgERCh8h2F1A/TV+R3qZUtsxh5WX3qQ3gniJMIzcz8+r9St7fsfuS+y8FbMqoPC0 X-Received: by 2002:a63:441b:0:b0:439:103b:25a4 with SMTP id r27-20020a63441b000000b00439103b25a4mr22489518pga.487.1665530393587; Tue, 11 Oct 2022 16:19:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665530393; cv=none; d=google.com; s=arc-20160816; b=e3u9gzMLFjPK8jXl9gRryMTfDBg2e9ZAyJfXAxbkmw/8vZnfNv60GOaBZ3bLBLhjcm DaNzu5M6iJ2s/80NQB1qIG6H+q3ElFvvZX43aFpoq/D4cjSAxEGp9OfPzIbxUjs8e7/h idpSrVd+I0F3mSaK+bFCLY/PMhw/DuxoArejB3ebFB+9dYa4/GK1aoRfoC92FKRDDP7P CIbOxy+qyeyrO/N3PH5fmix+hUHYcspFtUULdskrNwvrDRt0d85DmROa/tX3j98VyfBg NfWEg0M7Ss1J/PqFb1Xp91JJaAMVdS3K8IbKGpVZMDh2cIhELMpo4xniRxwo5e0bMCGj IFqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=6o1KqrZ+fXEMS7aaZARPQ/NnoBxO34uPUaUPmbI+thE=; b=q74e5zinj94cEVUWYzXSVOZzu+oL4E6uhD5a9koLTe7BuPShYlWgq0JAeft3umZxN2 xWowRAlmOJVoFUUjQlb3pi0OKrBOcA2HW9btKxIQmbrYgphAYNumlAdjyMpcgcc+wIjM Ak7URg/Y3MhxkJ1TFxi7K+miyOGRkHA29JxPSxoWw9IdDJWgleN2/NlVFM7NPr1MHP4o xPPJh7AYxA64N+sY4GgIGzUONrAeNi3nDIx1CXEYByYZgoW6vtBNxCVmyy3CWeC+DRhx IHPva1Jq76CQ48wp+ifUlfiNtWewjWFfaOwyHtk7BdH6FD1LIOjmNtPkE1fnYBqdJ6E4 3xWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=BwpJsVD1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o14-20020a63a80e000000b0044ac2bbaccasi17570628pgf.729.2022.10.11.16.19.41; Tue, 11 Oct 2022 16:19:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=BwpJsVD1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229659AbiJKXSg (ORCPT + 99 others); Tue, 11 Oct 2022 19:18:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38908 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229662AbiJKXSS (ORCPT ); Tue, 11 Oct 2022 19:18:18 -0400 Received: from lelv0143.ext.ti.com (lelv0143.ext.ti.com [198.47.23.248]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9DA8F5FAD7; Tue, 11 Oct 2022 16:18:16 -0700 (PDT) Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id 29BNI4CN086187; Tue, 11 Oct 2022 18:18:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1665530284; bh=6o1KqrZ+fXEMS7aaZARPQ/NnoBxO34uPUaUPmbI+thE=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=BwpJsVD1lZ6mO65P1Pvpa5krJOoy0K0Z1pqoyJvYH4M4cJo09CUocCWwFpaMfm/5l fSkSecXQMDhnNG5ODNSVYyRciyMIWsH30Ko700SpBvETIF9xqYKnFQllLSPv7TdGgc GA4XeZuEpQfjdnLjWd/vxeummEOXZGst16nolTmM= Received: from DFLE101.ent.ti.com (dfle101.ent.ti.com [10.64.6.22]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id 29BNI4Eq096425 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 11 Oct 2022 18:18:04 -0500 Received: from DFLE114.ent.ti.com (10.64.6.35) by DFLE101.ent.ti.com (10.64.6.22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.6; Tue, 11 Oct 2022 18:18:03 -0500 Received: from lelv0326.itg.ti.com (10.180.67.84) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2507.6 via Frontend Transport; Tue, 11 Oct 2022 18:18:03 -0500 Received: from localhost (ileaxei01-snat2.itg.ti.com [10.180.69.6]) by lelv0326.itg.ti.com (8.15.2/8.15.2) with ESMTP id 29BNI3e2022106; Tue, 11 Oct 2022 18:18:03 -0500 From: Bryan Brattlof To: Rob Herring , Krzysztof Kozlowski CC: "Rafael J. Wysocki" , Daniel Lezcano , Amit Kucheria , Zhang Rui , Nishanth Menon , Vignesh Raghavendra , Tero Kristo , Keerthy , Linux Thermal , Linux Device Tree , LKML , Linux ARM , Bryan Brattlof Subject: [PATCH 07/11] arm64: dts: ti: k3-am64-main: add VTM node Date: Tue, 11 Oct 2022 18:17:23 -0500 Message-ID: <20221011231727.8090-8-bb@ti.com> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221011231727.8090-1-bb@ti.com> References: <20221011231727.8090-1-bb@ti.com> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=3254; h=from:subject; bh=HE07q6h/VkPG0znQw7MNm8QBZyEJDwtYuYDWFc4WF+Y=; b=owNCWmg5MUFZJlNZN0wH+AAAZX////7/fmVp+/67D0Zdn99/x7+/4e+3///Tf/97191v8/ywARsw HajQaBoaaAaGmgZBoaYmgADQABoGmg0AGgA00GhpoANDRpoNDRgg0aMhow0IgaAANAA0NMgaAABkPU yGmhkGJkaNAGTQDIAPUAaDR6JjU0HqAYRoBoGgAHJp6Q00NDTINGgDEGQGIGg0aNA0aNDRkyAAaAAy AMQNNAAAaA0xAGAhkAAFiHMMHK2AeZF2IiSM6tJ/g4eH35fdMcsqgEw0C+gmlZ4AyuGzwB+TsMjnsD CxkdOl4ZhpgXwjuzfwGQWaBZh1ga5OTUB02504PJDijVsekUCVZSpgrVgfQ9lUmgmYpLxsRzQyNcB5 OCkpx/CE5qLQ4ub6LLR6SJHQrN1Ifn0RP3owYkQT1xQeY0GPixgg8cNG4Ef1mT6pAFG5RLduO5H0pE aVEJCghA6RQWs074zDQCTgIouzf/K3QTzRA3SmUx0TiB+ZWO7ST+7fRzvfeFEuKjxpQYL8vAqCAdUF 8toyFL5JahTKmdovtVNsCpn79Tp4CiNrCHsu/ec1SN5aUYMK9AvELlzqnuSRoc45AhCsWxQApXUs/k BivqibNybpGFMAThdi9srFqxPFAftK5+MYDrAiDDSObYLUKA1CLcVYcak8ZtYEcL/F3JFOFCQN0wH+ AA== X-Developer-Key: i=bb@ti.com; a=openpgp; fpr=D3D177E40A38DF4D1853FEEF41B90D5D71D56CE0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The am64x supports a single VTM module which is located in the main domain with two associated temperature monitors located at different hot spots on the die. Signed-off-by: Bryan Brattlof --- arch/arm64/boot/dts/ti/k3-am64-main.dtsi | 8 +++++ arch/arm64/boot/dts/ti/k3-am64-thermal.dtsi | 33 +++++++++++++++++++++ arch/arm64/boot/dts/ti/k3-am64.dtsi | 4 +++ 3 files changed, 45 insertions(+) create mode 100644 arch/arm64/boot/dts/ti/k3-am64-thermal.dtsi diff --git a/arch/arm64/boot/dts/ti/k3-am64-main.dtsi b/arch/arm64/boot/dts/ti/k3-am64-main.dtsi index ada00575f0f2e..4cd687cc44d9e 100644 --- a/arch/arm64/boot/dts/ti/k3-am64-main.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am64-main.dtsi @@ -1308,4 +1308,12 @@ main_mcan1: can@20711000 { interrupt-names = "int0", "int1"; bosch,mram-cfg = <0x0 128 64 64 64 64 32 32>; }; + + vtm0: temperature-sensor@b00000 { + compatible = "ti,j7200-vtm"; + reg = <0x00 0xb00000 0x00 0x400>, + <0x00 0xb01000 0x00 0x400>; + power-domains = <&k3_pds 95 TI_SCI_PD_EXCLUSIVE>; + #thermal-sensor-cells = <1>; + }; }; diff --git a/arch/arm64/boot/dts/ti/k3-am64-thermal.dtsi b/arch/arm64/boot/dts/ti/k3-am64-thermal.dtsi new file mode 100644 index 0000000000000..1819a6948b19d --- /dev/null +++ b/arch/arm64/boot/dts/ti/k3-am64-thermal.dtsi @@ -0,0 +1,33 @@ +// SPDX-License-Identifier: GPL-2.0 + +#include + +thermal_zones: thermal-zones { + main0_thermal: main0-thermal { + polling-delay-passive = <250>; /* milliSeconds */ + polling-delay = <500>; /* milliSeconds */ + thermal-sensors = <&vtm0 0>; + + trips { + main0_crit: main0-crit { + temperature = <105000>; /* milliCelsius */ + hysteresis = <2000>; /* milliCelsius */ + type = "critical"; + }; + }; + }; + + main1_thermal: main1-thermal { + polling-delay-passive = <250>; /* milliSeconds */ + polling-delay = <500>; /* milliSeconds */ + thermal-sensors = <&vtm0 1>; + + trips { + main1_crit: main1-crit { + temperature = <105000>; /* milliCelsius */ + hysteresis = <2000>; /* milliCelsius */ + type = "critical"; + }; + }; + }; +}; diff --git a/arch/arm64/boot/dts/ti/k3-am64.dtsi b/arch/arm64/boot/dts/ti/k3-am64.dtsi index 016dd8511ca6f..4ebee0be648e0 100644 --- a/arch/arm64/boot/dts/ti/k3-am64.dtsi +++ b/arch/arm64/boot/dts/ti/k3-am64.dtsi @@ -69,6 +69,7 @@ cbass_main: bus@f4000 { <0x00 0x00420000 0x00 0x00420000 0x00 0x00001000>, /* ESM0 */ <0x00 0x00600000 0x00 0x00600000 0x00 0x00001100>, /* GPIO */ <0x00 0x00a40000 0x00 0x00a40000 0x00 0x00000800>, /* Timesync router */ + <0x00 0x00b00000 0x00 0x00b00000 0x00 0x00002400>, /* VTM */ <0x00 0x01000000 0x00 0x01000000 0x00 0x02330400>, /* First peripheral window */ <0x00 0x08000000 0x00 0x08000000 0x00 0x00200000>, /* Main CPSW */ <0x00 0x0d000000 0x00 0x0d000000 0x00 0x00800000>, /* PCIE_CORE */ @@ -104,6 +105,9 @@ cbass_mcu: bus@4000000 { ranges = <0x00 0x04000000 0x00 0x04000000 0x00 0x01ff1400>; /* Peripheral window */ }; }; + + #include "k3-am64-thermal.dtsi" + }; /* Now include the peripherals for each bus segments */ -- 2.38.0