Received: by 2002:ab2:b82:0:b0:1f3:401:3cfb with SMTP id 2csp666809lqh; Thu, 28 Mar 2024 12:27:32 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCU5yCr8YSk9MXe0Ms/0YThj9P7Rna534de6Oi20/GX0YPmMWZsy1EN8mpX2oA1Z5+SQS5J8xardT1p2WmqPFCRJtA32ndHVhyGVzj+2AQ== X-Google-Smtp-Source: AGHT+IGIdADgUIol14yLpcuOoR0aRMR270xtv3Kh71tHZ7ZvU/brhns/4ISJoPcYOXHZhl6RSqLa X-Received: by 2002:ac8:588a:0:b0:430:d6ce:ced4 with SMTP id t10-20020ac8588a000000b00430d6ceced4mr324954qta.20.1711654052772; Thu, 28 Mar 2024 12:27:32 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711654052; cv=pass; d=google.com; s=arc-20160816; b=ygk/j/YzwKvv+fS0MeFaaHH14ZLX1tTJ3NeQatrPVNtvjp7wBiOW1g4jjWRxsZUUmu JzuDMPKHjECDmu6z3NlgVUnlw2+Hp28WIP1dbE46DeEDKDTi/d1QJLMaP3cmyu1cyqqA YRtQoUf13AYp1q9HmKwmCoxH4/2U55RsXZay47Ysvowd7n/aC8pqCa/w1sJBPyC/4hB7 uFxLbTm6CPkQ3gIZKz5jxwckVY1Tp+2qQ2LuAJNVbMZNP6ZXt9DcuB028J/8PHbpxDLv 1NYl0Eb83bXGc2G39A1W6KGxC4EUGTOThmYh9w8mjYrvlSwCuel3AePtUQZsQdnrp4zN SWaA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature:dkim-filter; bh=9CPwvn2kpzZJnAOi5N/hirprKnzIWIB81uV2cDqMcbY=; fh=byLtYStTBgqWsH7RqVUzGNNXm5S/nkk9nurNFY6Z5MM=; b=wtoug7h352YWNH++4VgqcKrjsCP5nzymjm1cOSqiAL6mk74D2Bn+r2A5Go3r2cIW5C xpWNUbcXvwM9eL3gfBApwUFut8UZ292cBj5tW6MkehVsbgoFPnQ9OGbpSA9H2TbB5jgY dzmWy2s2XdrDxvEHsPoOZW2F0TqncKS58KNTNTsn8Pbq5EqSY4o/gfy+5uFwQxfBMAKE iIElqFCQbYyJyj/qwXZTaQpQMxqCmWaR4SzE+4IU7bqP/GirGyQxeBp5P4f2k/6Sn9Cd VZddDOv/6bNL3O/eVeqfVROL47q7TKPhMxkc8eLjDysLPD8glOpFSv/fKJ1pepUkYzyf 6ddg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@salutedevices.com header.s=mail header.b=h3CSHwYt; arc=pass (i=1 spf=pass spfdomain=salutedevices.com dkim=pass dkdomain=salutedevices.com dmarc=pass fromdomain=salutedevices.com); spf=pass (google.com: domain of linux-kernel+bounces-123479-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-123479-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=salutedevices.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id c20-20020a05622a059400b00432b311faa1si1999292qtb.537.2024.03.28.12.27.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Mar 2024 12:27:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-123479-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@salutedevices.com header.s=mail header.b=h3CSHwYt; arc=pass (i=1 spf=pass spfdomain=salutedevices.com dkim=pass dkdomain=salutedevices.com dmarc=pass fromdomain=salutedevices.com); spf=pass (google.com: domain of linux-kernel+bounces-123479-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-123479-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=salutedevices.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 7B9E71C2947D for ; Thu, 28 Mar 2024 19:27:32 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1885B13957B; Thu, 28 Mar 2024 19:27:00 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=salutedevices.com header.i=@salutedevices.com header.b="h3CSHwYt" Received: from mx1.sberdevices.ru (mx2.sberdevices.ru [45.89.224.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8499212A157; Thu, 28 Mar 2024 19:26:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.89.224.132 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711654019; cv=none; b=OrBaLUVJmryNlxIyZhqlZvsswwhsh16QoPOB3UnFOJ6lBEcMq/gT6TP855doOGszpp19XR7cL5/4g5f+SzmoBBJjeqcJ1uBfZ6xK4gGHTnf2G7d4GN1j1LVONmwVfYDhKDp4X+HjvQ3eD8apotOJF6+FKBzg1F3FCBUJ4QYBSN0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711654019; c=relaxed/simple; bh=vwSFSGR9bfNDcThzkOUIaAgtD60B7Pss7f2WlcQz124=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=PM5O7eE1EGf4cCtfWZW/kQakcgR1TVpVhq7yBGO8gRvrDoH4u6SWz0d7UXyyDNd3RLHUzeBTu3rX3Zy9eaA5dJmFLzl0xm4hMGNl4X1YOfkzQcaCQaKR3Ixeim0RKHuwH+zcIOlJefXUoNjiRJFjkfRRBwr8GpEjn68a095sifo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=salutedevices.com; spf=pass smtp.mailfrom=salutedevices.com; dkim=pass (2048-bit key) header.d=salutedevices.com header.i=@salutedevices.com header.b=h3CSHwYt; arc=none smtp.client-ip=45.89.224.132 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=salutedevices.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=salutedevices.com Received: from p-infra-ksmg-sc-msk02 (localhost [127.0.0.1]) by mx1.sberdevices.ru (Postfix) with ESMTP id 569F8120008; Thu, 28 Mar 2024 22:26:55 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.sberdevices.ru 569F8120008 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=salutedevices.com; s=mail; t=1711654015; bh=9CPwvn2kpzZJnAOi5N/hirprKnzIWIB81uV2cDqMcbY=; h=From:To:Subject:Date:Message-ID:MIME-Version:Content-Type:From; b=h3CSHwYtFF/KwKbX/wGQsM4F/cTdE6pc4j3/iGviZDcfxXjJZuD0n4NfPVDlCZYVC d03MnVVfX2lvNUkL+5tfaZNkraHA/VffptosJiRKsBhf6HFgmQuPUVEx1oGa5vYUza RCY11ca31+eWlurcUoKuj/hQ/GmvW3Qyta8GAhEuI4vSNnk3tu1SHE7pnqCcBZPSWm 8AzUa4SrCmCHVczhQumNjoeMLIcLGrD9tSBTZH1YPyJW5wr5Mt9U8GGa1jeVFEGZzD wnjFeaV72QzUbdNVezQ45V0HK/FKF6tikgq1LznpvTRCpgMG/MvgZQo7tBnttNCEhG mdnj9jp+ub2EA== Received: from smtp.sberdevices.ru (p-i-exch-sc-m02.sberdevices.ru [172.16.192.103]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.sberdevices.ru (Postfix) with ESMTPS; Thu, 28 Mar 2024 22:26:55 +0300 (MSK) Received: from CAB-WSD-L081021.sberdevices.ru (100.64.160.123) by p-i-exch-sc-m02.sberdevices.ru (172.16.192.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Thu, 28 Mar 2024 22:26:54 +0300 From: Dmitry Rokosov To: , , , , , , , , , , , , CC: , , , , , , , Dmitry Rokosov Subject: [PATCH v2 3/3] arm64: dts: amlogic: ad402: setup thermal-zones Date: Thu, 28 Mar 2024 22:26:37 +0300 Message-ID: <20240328192645.20914-4-ddrokosov@salutedevices.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240328192645.20914-1-ddrokosov@salutedevices.com> References: <20240328192645.20914-1-ddrokosov@salutedevices.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: p-i-exch-sc-m02.sberdevices.ru (172.16.192.103) To p-i-exch-sc-m02.sberdevices.ru (172.16.192.103) X-KSMG-Rule-ID: 10 X-KSMG-Message-Action: clean X-KSMG-AntiSpam-Lua-Profiles: 184477 [Mar 28 2024] X-KSMG-AntiSpam-Version: 6.1.0.4 X-KSMG-AntiSpam-Envelope-From: ddrokosov@salutedevices.com X-KSMG-AntiSpam-Rate: 0 X-KSMG-AntiSpam-Status: not_detected X-KSMG-AntiSpam-Method: none X-KSMG-AntiSpam-Auth: dkim=none X-KSMG-AntiSpam-Info: LuaCore: 14 0.3.14 5a0c43d8a1c3c0e5b0916cc02a90d4b950c01f96, {Tracking_from_domain_doesnt_match_to}, smtp.sberdevices.ru:7.1.1,5.0.1;salutedevices.com:7.1.1;127.0.0.199:7.1.2;100.64.160.123:7.1.2;d41d8cd98f00b204e9800998ecf8427e.com:7.1.1, FromAlignment: s, ApMailHostAddress: 100.64.160.123 X-MS-Exchange-Organization-SCL: -1 X-KSMG-AntiSpam-Interceptor-Info: scan successful X-KSMG-AntiPhishing: Clean X-KSMG-LinksScanning: Clean X-KSMG-AntiVirus: Kaspersky Secure Mail Gateway, version 2.0.1.6960, bases: 2024/03/28 18:13:00 #24496606 X-KSMG-AntiVirus-Status: Clean, skipped There is one thermal zone with 3 trip points: soc_passive, soc_hot, and soc_critical, as well as two cooling maps. Signed-off-by: Dmitry Rokosov --- .../arm64/boot/dts/amlogic/meson-a1-ad402.dts | 45 +++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-a1-ad402.dts b/arch/arm64/boot/dts/amlogic/meson-a1-ad402.dts index 6c02301840ff..2d22e8b45c6d 100644 --- a/arch/arm64/boot/dts/amlogic/meson-a1-ad402.dts +++ b/arch/arm64/boot/dts/amlogic/meson-a1-ad402.dts @@ -7,6 +7,7 @@ /dts-v1/; #include "meson-a1.dtsi" +#include #include @@ -177,6 +178,50 @@ codec { }; }; }; + + thermal-zones { + soc_thermal: soc_thermal { + polling-delay = <1000>; + polling-delay-passive = <100>; + sustainable-power = <130>; + + thermal-sensors = <&cpu_temp>; + + trips { + soc_passive: soc-passive { + temperature = <70000>; + hysteresis = <2000>; + type = "passive"; + }; + + soc_hot: soc-hot { + temperature = <85000>; + hysteresis = <5000>; + type = "hot"; + }; + + soc_critical: soc-critical { + temperature = <110000>; + hysteresis = <1000>; + type = "critical"; + }; + }; + + soc_cooling_maps: cooling-maps { + map0 { + trip = <&soc_passive>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + }; + + map1 { + trip = <&soc_hot>; + cooling-device = <&cpu0 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>, + <&cpu1 THERMAL_NO_LIMIT THERMAL_NO_LIMIT>; + }; + }; + }; + }; }; /* Bluetooth HCI H4 */ -- 2.43.0