Add support for H616 Thermal system
From: | Martin Botka <martin.botka-AT-somainline.org> | |
To: | Vasily Khoruzhick <anarsoul-AT-gmail.com>, Yangtao Li <tiny.windzz-AT-gmail.com>, "Rafael J. Wysocki" <rafael-AT-kernel.org>, Daniel Lezcano <daniel.lezcano-AT-linaro.org>, Amit Kucheria <amitk-AT-kernel.org>, Zhang Rui <rui.zhang-AT-intel.com>, Rob Herring <robh+dt-AT-kernel.org>, Krzysztof Kozlowski <krzysztof.kozlowski+dt-AT-linaro.org>, Conor Dooley <conor+dt-AT-kernel.org>, Chen-Yu Tsai <wens-AT-csie.org>, Jernej Skrabec <jernej.skrabec-AT-gmail.com>, Samuel Holland <samuel-AT-sholland.org> | |
Subject: | [PATCH v2 0/3] Add support for H616 Thermal system | |
Date: | Mon, 21 Aug 2023 16:03:45 +0200 | |
Message-ID: | <20230821-ths-h616-v2-0-cda60d556798@somainline.org> | |
Cc: | linux-pm-AT-vger.kernel.org, devicetree-AT-vger.kernel.org, linux-arm-kernel-AT-lists.infradead.org, linux-sunxi-AT-lists.linux.dev, linux-kernel-AT-vger.kernel.org, Andre Przywara <andre.przywara-AT-arm.com>, Alan Ma <tech-AT-biqu3d.com>, Luke Harrison <bttuniversity-AT-biqu3d.com>, Marijn Suijten <marijn.suijten-AT-somainline.org>, AngeloGioacchino Del Regno <angelogioacchino.delregno-AT-somainline.org>, Konrad Dybcio <konrad.dybcio-AT-somainline.org>, Martin Botka <martin-AT-biqu3d.com>, Martin Botka <martin.botka-AT-somainline.org>, Krzysztof Kozlowski <krzysztof.kozlowski-AT-linaro.org> | |
Archive-link: | Article |
Hello, This patch series adds support to thermal system found in H616 SoC. There are 4 thermal sensors in this SoC. One for GPU, CPU, DRAM and VE. Trips while unused for now until cpufreq is implemented (WIP) are required by dt-bindings and thus included here. Cheers, Martin --------------- Hello, Im very much not sure if the trips should be included or not. Since they are not optional part I decided to add them but please let me know. Cheers, Martin Signed-off-by: Martin Botka <martin.botka@somainline.org> --- Changes in v2: - Fix typos - Remove h616 calc and init functions - Use TEMP_CALIB_MASK insteaf of 0xffff - Adjust calibration function to new offset and scale - Add proper comment to bindings patch - Split delta calculations to 2 lines - Add parentheses around caldata[2|3] >> 12 - Negate bindings if for clocks - Link to v1: https://lore.kernel.org/r/20230818-ths-h616-v1-0-0e1e058b... --- Martin Botka (3): dt-bindings: thermal: sun8i: Add binding for H616 THS controller thermal: sun8i: Add support for H616 THS controller arm64: dts: allwinner: h616: Add thermal sensor and thermal zones .../bindings/thermal/allwinner,sun8i-a83t-ths.yaml | 18 ++--- arch/arm64/boot/dts/allwinner/sun50i-h616.dtsi | 87 ++++++++++++++++++++++ drivers/thermal/sun8i_thermal.c | 74 ++++++++++++++++++ 3 files changed, 169 insertions(+), 10 deletions(-) --- base-commit: df6283416a280d17609f5e55388601458241348c change-id: 20230815-ths-h616-77b2db565249 Best regards, -- Martin Botka <martin.botka@somainline.org>