Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp3440763rwd; Sat, 10 Jun 2023 07:45:25 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ63ImKgMpUrlgwyJfYYV0NAwiEICW2Cb0kgjrNoXFenLsbIPlpLsKIksoivfgthJZWWCfYY X-Received: by 2002:aa7:d785:0:b0:50d:9de4:5664 with SMTP id s5-20020aa7d785000000b0050d9de45664mr1043712edq.40.1686408325000; Sat, 10 Jun 2023 07:45:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686408324; cv=none; d=google.com; s=arc-20160816; b=xwvjsNG+Jm8sTbSP4Ril9lvEJZFD20E8zQnRTJmpOzVJaXCiaf8rL/MA83DW2F4Apy 5Sf26wn+xF1tz2eO2h0iz1B0BjfRHldiPDXD7/qD3qz4RPZ8DFT4s3rP8+tA+A5HbnKW 00TW7XeuQN6xqlrSNiCu+AlrWs+oEc89Xa6pxkzfqRpffVyd4flLQ9pw+BGSG8on3rAq T/9aqGBte05XGkYRjz2nADwM2HVsxYPvsRrYc+444/ZMkKreerKfCChcxLRp2nMAfPe9 HzP93fR8ioBxJfxN//KuJ6Dl4GFDLj9AfcloU3f4j/dvU2D1EvOHEkrO11sat5Jf43FO edNg== 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=iADzhJzSziS7zTAopdQl1F1LJEpxTBMZdMAeH9fjzio=; b=U9cBhQ6ken/Fz4Us9G7cb6W11z/MoMe7RQ1DNrB75FjgDzA33bxurx9LaehN2El602 MZz+aoWToU207Z2MjzVuPgrR5ta0/MvmaOGYJcW2X7K+Bl+d5/eE/py9Gs/C8gbXmnVt X+7C+akuLVwLJNUrTKJ9+3O4sgnhVsopqFRQUz0UWaiwBogldSOnxKKVQU9Q12ernMS4 oEJap6R++jWRwO5pLQ7QA7fiz8k0V2QO8vQfdCZSkyYCpERhEM50UrKovA6dLw54O2cA wd7QEDyd2KZ6UOc/qVXB8Rh0/C6AouR6gP4dd6VAKZ7AFkP4ONH1rWqt2IJ6dDRSuG4e Bdyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b="pkzfO/5s"; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f21-20020a05640214d500b00514a45f1ef0si3684014edx.391.2023.06.10.07.45.00; Sat, 10 Jun 2023 07:45:24 -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=@gmail.com header.s=20221208 header.b="pkzfO/5s"; 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=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235328AbjFJOS2 (ORCPT + 99 others); Sat, 10 Jun 2023 10:18:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34526 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232422AbjFJOSY (ORCPT ); Sat, 10 Jun 2023 10:18:24 -0400 Received: from mail-wm1-x32f.google.com (mail-wm1-x32f.google.com [IPv6:2a00:1450:4864:20::32f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4183C3C15; Sat, 10 Jun 2023 07:18:15 -0700 (PDT) Received: by mail-wm1-x32f.google.com with SMTP id 5b1f17b1804b1-3f7f6341b99so20688945e9.2; Sat, 10 Jun 2023 07:18:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686406693; x=1688998693; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=iADzhJzSziS7zTAopdQl1F1LJEpxTBMZdMAeH9fjzio=; b=pkzfO/5sjuHYso+oiyL7XG0FVK9wYghdGfliIDHkuHEiBLv06cMTld/rPbe9ZcWq89 q5zfw/OPDhI5rl8hUlLsjSD/Y3sE0DDEpJXtoWttBEwADBgfV97tRv9SkNXEMh7sVweQ iOgdA5YtlapviAswCw34D/Ex9EcTRe6FG98PT+Ygta0VcuxrnKxRD8afLvwDWVVaK0sL 6H82RYlSoRjAKTalAG1Pr+6X4qIpg8x5kues3GSMOIxOtK3bVT+r9oL6G7dMMZ6FAMUp 6u8yvU+TJvHddmSXZmzCR2YmUdWJXRTYJk0lXTsID5AHjF0kE2PlcO6JdJqMBkjFbgjq lZVQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686406693; x=1688998693; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=iADzhJzSziS7zTAopdQl1F1LJEpxTBMZdMAeH9fjzio=; b=CNriqzrgdG7rmg1R+sdtunsl9ScAuGP1eUnvguJAdP2lOJQlZctkwu7QevzkxMQF4g PAIyeg94fsAxAlTKF97Uyoo68zA1MiHJlIoB0ZGsewHY6nfs8nEaQlwk+w+BTGZJozJE 8cwJHDSKyzmvweQ+jDu9lUhtq9TN5BsdA3dWIS2kkkDUBObqjFgMPSjqRbLJhdRZ9H49 Ef9MhdbFI7WaJlPjo0qJZiua4KVHPtPoTl0kX+bXHlIsrMvK5n3JXaQ7Vzfd+1xbewuL uU7qoSq3xK36l6TgVISmSsS/e1oEEN0BBh6ApGwUA8kkCvBRsfcc3BufhySy8jb0Bmwa TxfQ== X-Gm-Message-State: AC+VfDzEvIRdCYmzxg1WDIf7YgqrXjtQwZ7gftRsEEJl3Lpqj2I0+wvg aqciRSb+dfm/EyVa6yymRQYDZFStzkFD+JcC X-Received: by 2002:a05:600c:290:b0:3f7:3991:e128 with SMTP id 16-20020a05600c029000b003f73991e128mr3027448wmk.2.1686406692941; Sat, 10 Jun 2023 07:18:12 -0700 (PDT) Received: from user-PC.. ([178.134.198.138]) by smtp.gmail.com with ESMTPSA id z10-20020a05600c220a00b003f735d6fa74sm5841488wml.9.2023.06.10.07.18.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 10 Jun 2023 07:18:12 -0700 (PDT) From: Maksim Kiselev To: linux-kernel@vger.kernel.org Cc: Maxim Kiselev , Vasily Khoruzhick , Yangtao Li , "Rafael J. Wysocki" , Daniel Lezcano , Amit Kucheria , Zhang Rui , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Paul Walmsley , Palmer Dabbelt , Albert Ou , Cristian Ciocaltea , Heiko Stuebner , linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-riscv@lists.infradead.org Subject: [PATCH v1 2/3] riscv: dts: allwinner: d1: Add thermal sensor and thermal zone Date: Sat, 10 Jun 2023 17:17:33 +0300 Message-Id: <20230610141739.999268-3-bigunclemax@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230610141739.999268-1-bigunclemax@gmail.com> References: <20230610141739.999268-1-bigunclemax@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 From: Maxim Kiselev This patch adds a thermal sensor controller node for the D1/T113s. Also it adds a THS calibration data cell and thermal zone. Signed-off-by: Maxim Kiselev Signed-off-by: Maksim Kiselev --- .../boot/dts/allwinner/sunxi-d1s-t113.dtsi | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/arch/riscv/boot/dts/allwinner/sunxi-d1s-t113.dtsi b/arch/riscv/boot/dts/allwinner/sunxi-d1s-t113.dtsi index 922e8e0e2c09..b893f3325554 100644 --- a/arch/riscv/boot/dts/allwinner/sunxi-d1s-t113.dtsi +++ b/arch/riscv/boot/dts/allwinner/sunxi-d1s-t113.dtsi @@ -10,6 +10,7 @@ #include #include #include +#include / { #address-cells = <1>; @@ -138,6 +139,19 @@ ccu: clock-controller@2001000 { #reset-cells = <1>; }; + ths: thermal-sensor@2009400 { + compatible = "allwinner,sun20i-d1-ths"; + reg = <0x02009400 0x400>; + interrupts = ; + clocks = <&ccu CLK_BUS_THS>; + clock-names = "bus"; + resets = <&ccu RST_BUS_THS>; + nvmem-cells = <&ths_calibration>; + nvmem-cell-names = "calibration"; + status = "disabled"; + #thermal-sensor-cells = <0>; + }; + dmic: dmic@2031000 { compatible = "allwinner,sun20i-d1-dmic", "allwinner,sun50i-h6-dmic"; @@ -365,6 +379,10 @@ sid: efuse@3006000 { reg = <0x3006000 0x1000>; #address-cells = <1>; #size-cells = <1>; + + ths_calibration: thermal-sensor-calibration@14 { + reg = <0x14 0x4>; + }; }; crypto: crypto@3040000 { @@ -843,4 +861,12 @@ rtc: rtc@7090000 { #clock-cells = <1>; }; }; + + thermal-zones { + cpu_thermal: cpu-thermal { + polling-delay-passive = <0>; + polling-delay = <0>; + thermal-sensors = <&ths 0>; + }; + }; }; -- 2.39.2