Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp3740757rwd; Sat, 10 Jun 2023 13:53:25 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7Dvon1ykgIZrJlqdjQjoGIqbQbMc9aA9F6fYlMidoIepWmB65T8Ttam1x68juChHF4iKrZ X-Received: by 2002:a17:902:d489:b0:1b0:3c2a:2b4e with SMTP id c9-20020a170902d48900b001b03c2a2b4emr3281162plg.8.1686430405198; Sat, 10 Jun 2023 13:53:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686430405; cv=none; d=google.com; s=arc-20160816; b=T69s/2cXRvIFUSPqYrXiZXASp8jD0xSrj/pRwMSs2tsS8gpiMyW4255/A/cV5m/vwQ /1BKqtNpXSe2sRBkYAqz120VDF1VrWB2hx/euJajomz4taYht4DL7zVAghC8XL1eXVmw /LoFE+1cVZwyzU78edpplSgGmSd3hVeXVUFv8FZtE0r0VjxeMFnJk6i0S6kGpIwC03Oj 0vadvto5/lSKh93gFgAA901tHaBEuagT6ZdP22NOpa4k8M7gaEecwC4ZNQJqt9WpN0B9 tI5xyAKYhNtfcaYD6r0SuytxgoQmfypKetYouEZLG+hn9L0MjoeqrBb58+NiT0B0n5Lz GRzQ== 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=++GIztv4naBcPicwbwUH4k+fuc5iv8tnHanmi3MA+54=; b=smKUgDYWbx8GrndjbZRzSodOu1McjDKY0xiE/sRZKf0HA+s4Pbd79YU7SumOHL381T Wdy+VHaZzZfkBV0bkOVq1wQ5lUR3+wAplpB83KxgAK45L5vUWi6iusDnNzkThO6lWjNJ 4WPFLSCZpCdnpt84RKjd9P9gz8rHlxwxYrihPtjTXOlhLivCwjg3QZGdH8WJ1y49ASGf vznBQ0TwgoVtVwBoKupSqfrnnyI7ACM1b7LAsEoB/Aoj9ZtGud+GT7MV7PU1jUu1qT5g eN2imxKh1wbKAQMuoilgXMqsVPJnkvAeKVUpNi5POZfFnb75glAod49Sxrh3XcyVUONx aAPA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=kpQA3nek; 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 e12-20020a17090301cc00b001a6e719421asi4624210plh.366.2023.06.10.13.53.13; Sat, 10 Jun 2023 13:53:25 -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=kpQA3nek; 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 S231752AbjFJUnV (ORCPT + 99 others); Sat, 10 Jun 2023 16:43:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47572 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232683AbjFJUnN (ORCPT ); Sat, 10 Jun 2023 16:43:13 -0400 Received: from mail-wm1-x332.google.com (mail-wm1-x332.google.com [IPv6:2a00:1450:4864:20::332]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 29EAAA1; Sat, 10 Jun 2023 13:43:06 -0700 (PDT) Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-3f7378a74faso21684485e9.0; Sat, 10 Jun 2023 13:43:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686429784; x=1689021784; 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=++GIztv4naBcPicwbwUH4k+fuc5iv8tnHanmi3MA+54=; b=kpQA3nekPL+98p6cmI9mnzaVKKHSve6cxGy1RhXCla4biUstK0AKaCtI/Yd8gbQI9C sKvam+wssABxv9MLaA8kl5BJhpNt80OT9bNZPqEmuKvB7Y1ZlMAjG5j1EByVLPBFSquv XZYWdbif7Djrbj3cU6/YT0/+uIqkCKD0uhA31WONT9nr87Vc+mqKv1p723rj55+9H79T Kk8WI4Y4aYbVsEMcYPZ5hDCoMCTI0rh34BEzenayM7ndQUqivI9EIRPkk9GG396NAB47 brloEtunNG2rvV8Q6S66JAxklc2EW244yyggOBvkLx2SDrPU2Xds3WhVzhas6d7dA5jX 9ceg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686429784; x=1689021784; 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=++GIztv4naBcPicwbwUH4k+fuc5iv8tnHanmi3MA+54=; b=Nw3aUx5VOGbkGci01LyJ7hWbs4qWsWAPeGLq9CJ/NYnoNIOyeXYzyvllrpzfbvmcQp 3Ryjsy7E/niXohs2dtl6aMWSMOaxcriSgzi2cLkvRLir2ZOHGpB8ylqqHC7ulquvu7/A kYUbdQARBhrktFlbzwVihf7ev7iLYqeqFRMEDpIzuIiL9x0YChf5Mag9/4EhQMYyqaWZ gTSGrQPcHwXyV2B1u7WgjjTBoWsKZ18lsQl46Bf/f+TimuOu5/itvRN2cHUAr2uG1bGN ae2V+crI38WsMvoPQQvtUn3iuOAV6g2ZTGvuTFDMM8PWkgGnd2qmz/MnYWWTPQqSahSR YP+g== X-Gm-Message-State: AC+VfDyi035SPP6jH8qbwtPNI8ZiEa9KC1VbKNqkJ9vlvpCxLSRLPgLJ YHtexZK0KwRx2R4KH5YoEsKIBImrKhJTqka/ X-Received: by 2002:a05:600c:28d3:b0:3f6:48e:92ca with SMTP id h19-20020a05600c28d300b003f6048e92camr2906917wmd.39.1686429784280; Sat, 10 Jun 2023 13:43:04 -0700 (PDT) Received: from user-PC.. ([178.134.198.138]) by smtp.gmail.com with ESMTPSA id p14-20020a7bcc8e000000b003f605566610sm6547733wma.13.2023.06.10.13.43.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 10 Jun 2023 13:43:03 -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 , 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 v3 3/3] riscv: dts: allwinner: d1: Add thermal sensor and thermal zone Date: Sat, 10 Jun 2023 23:42:20 +0300 Message-Id: <20230610204225.1133473-4-bigunclemax@gmail.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230610204225.1133473-1-bigunclemax@gmail.com> References: <20230610204225.1133473-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 --- .../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