From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5E0A2606A33C for ; Mon, 30 Nov 2026 15:31:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=ctX3qO1o; dkim=pass (2048-bit key) header.d=baylibre.com header.i=@baylibre.com header.a=rsa-sha256 header.s=google header.b=WsY1nAsi DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Unsubscribe-Post:List-Owner; bh=xj0AHsLrmQ202hEBId+65kYQ6O04XMnSAjjhd5Zm4RI=; b=ctX3qO1oPrCBj0uwCey+pwQNR+ QWSW+R4y5YaemQ5EBYzJX+PBF2WaUa1QlGAr5vMlBNFFtxMVMtDdHQpqWjjBa+v2g6LGsFFiesJK+ peg3Q0tClOsFDk/gPRAiWRZqGV+nFOVyuEC67yrRjexhQZf9rnAkcvba/Thr3w9S6845MFUhhLDaj 0Ni4eybkaudJz0O8vZqI5xId+0Sl5tI68Xbz+y2XY61bXeCsMlBMMLiWHOrNqmfZHut4xXiDSeED1 y5iZp4ngmraFe9sp/QOtXyx2K7bAkZ53YcLRTpPdENseWNzRIVrjqsZgSeaCKjd3bqTxwd0CE56Na Khu0Ygxw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xY3MB-000000052hb-3cAR; Mon, 30 Nov 2026 15:31:56 +0000 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]) by bombadil.infradead.org with esmtps (Exim 4.100.1 #2 (Red Hat Linux)) id 1xY3M2-000000052eZ-2dO5 for linux-mediatek@lists.infradead.org; Mon, 30 Nov 2026 15:31:54 +0000 Received: by mail-wr1-x432.google.com with SMTP id ffacd0b85a97d-48e3b22e971so5500621f8f.0 for ; Mon, 30 Nov 2026 07:31:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre.com; s=google; t=1796052705; x=1796657505; darn=lists.infradead.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=xj0AHsLrmQ202hEBId+65kYQ6O04XMnSAjjhd5Zm4RI=; b=WsY1nAsiC8p34lta3MCar1Mgqs5/6axm8IndnyD/TTUa28K47TGxbYXYtEuaUXnpZa 72E1Ks3pnmL8K2L94TpqgAsFiQZWRuYcupECITXak+L0AzpPDMyfwFCJZEL0QKRbBbo1 uTVATYQIdEMNypxELawIPiX8TjR7rx2xpCeGymABZFOs17PoN3XuHm+QK39RRM3rFTiV luU8rYRr5zaYeH/yLoQfxG77WvYG5mSwQtN1q/yafKtcHuZz37HfO1SOKlrSls9w/QPt q4FwP9aQyxNUZS0L0uuUFh8voyYjmMavku1DfITXha+DzwiTeGXFidDa9oEHhSi86ird ZdYA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796052705; x=1796657505; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=xj0AHsLrmQ202hEBId+65kYQ6O04XMnSAjjhd5Zm4RI=; b=FlnoJZyQpC1EYYqxdNV6tJ/ZICf6YHyh3K7+aV+0OkFB4CSwsencQmv06qC8jxupt4 rGLB8kUZkdtGqlRZcrfvC6yhU36Khd/5HXP3vXArmM/L982U9ZgaqZ/me9Z9HgOYEqrw 8V2tPeWh6LxAz11UQ8pSYXmAR+o3PQvuWxme20cNOJU7vPQHAkR3GNwegn/RF/w3KLBn D/3Y40PoPKQYlcbufUB0mXD15UxTAi/X0/6qoocDg6+GbdIPa62GHmAgyEZZK1Sx0ki1 sf727PKP3z4JI5U77dZ43llR2WmaMBZG9cIgbOvNbh56ebjywGFSz1IbteuPt8RB9nWX rUNg== X-Forwarded-Encrypted: i=1; AL+hErF/S23axWqglBTFGI08ZMtglozYWPjpXBkST8Y4KLFA8cAgOYZM5DaH8itQ8x8/JEWog1EAOu9MdKY4SbJOQA==@lists.infradead.org X-Gm-Message-State: APuU4Z+RM3+ZUD12+fZ5x5qDH8FmZjwS/M4ALna7ojdqEf06aOHtWaHm by07KOEWoCs2r5VbJyTxAoWjrcgMwDYqLgF+LTJVll2ZOCsHv0Jmg2+iRYGaWppdSHA= X-Gm-Gg: AZFdTZckf4reqWxSLeXp4+k5a2D7OAXwHyZQL+VKUyd+7JAPNlYee9r6+LjuQKNIwao /EXs7xwUEoWRo8jKnzf54rbvoXahrXmHfdF2o8M6z8qiHhTLxcsNwboyFITrlJeIlqnGqNACa9u Onn9MmS8Yh3CbOWS49rew1XPiS1eInnts1DvjIkL8VjykeFhrLD+erCd+UobWIxcFADzeW6p/Uk h+1bCfwwG4MheqvL0LBUjTJm18f/PbLMqao8X7/z03o3rsMlKqgpBvZI+HKvjHhY1FLAhMX5EDF eqjPcJljsnZbG8C6OVPzSvLAiLtTaqFPqSP3Q1yfLzK9pCfMnzznocJNyM4Motbi1KyKclIASND XrOBD073TVzON6uFG2zOu7+gWZfnfrSpMneE1UFYbHn28Gs7YaOFztxoKV/BMn8cKqJg9tvkRIA SWXT1BAIt9zAr607hLHJIDWTgobL9YgE8R4Y1Th7hdmcT7nSRCTfdC9rn+8mi979LRDNaZDXcpO AhGLDYk2Wc04m172V8AsYCqCH0x/Qd2HKJTkrU9ErtoQ8vILO2m+nGM7h+Arx90f93n/TGgWsqL /2aQ6GOwdY6SfmgXM5GUf5Tet8WSXvH7Cp+hXVehWqTrur8uohClc0CYgON50dF7Mj1dk9N30Zs VzmSJVKDngzVNApKc X-Received: by 2002:a05:6000:2883:b0:4a4:39bb:970d with SMTP id ffacd0b85a97d-4abab02c469mr64303526f8f.2.1796052704566; Mon, 30 Nov 2026 07:31:44 -0800 (PST) Received: from localhost (p200300f65f125a08442a8896ffafbf0f.dip0.t-ipconnect.de. [2003:f6:5f12:5a08:442a:8896:ffaf:bf0f]) by smtp.gmail.com with UTF8SMTPSA id ffacd0b85a97d-4b70c05b9desm40857341f8f.54.2026.11.30.07.31.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Nov 2026 07:31:43 -0800 (PST) Date: Mon, 30 Nov 2026 16:31:42 +0100 From: Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= To: Alexandre Mergnat Cc: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno , Nicolas Frattaroli , Ulf Hansson , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, linux-pm@vger.kernel.org Subject: Re: [PATCH 3/3] thermal/drivers/mediatek: Add GPUEB thermal driver Message-ID: References: <20261130-mtk-mfg-thermal-v1-0-e0617e26f902@baylibre.com> <20261130-mtk-mfg-thermal-v1-3-e0617e26f902@baylibre.com> X-Archived-By: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="sgkx5usyeo3f4s6v" Content-Disposition: inline In-Reply-To: <20261130-mtk-mfg-thermal-v1-3-e0617e26f902@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20261130_073146_687416_2CF9574D X-CRM114-Status: GOOD ( 25.62 ) X-Spam-Score: -2.1 (--) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" X-Spam-Status: No, score=-15.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 --sgkx5usyeo3f4s6v Content-Type: text/plain; protected-headers=v1; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: Re: [PATCH 3/3] thermal/drivers/mediatek: Add GPUEB thermal driver MIME-Version: 1.0 On Mon, Nov 30, 2026 at 02:19:33PM +0000, Alexandre Mergnat wrote: > Add a driver for the auxiliary device that the mtk-mfg power domain > driver creates on MT8196. It registers the GPU temperature that the > GPUEB reports as a thermal sensor, so that a thermal zone can monitor > the GPU. >=20 > The auxiliary device shares the device tree node of the gpufreq device, > so a thermal zone selects this sensor by referring to that node. >=20 > Signed-off-by: Alexandre Mergnat > --- > drivers/thermal/mediatek/Kconfig | 9 ++++++ > drivers/thermal/mediatek/Makefile | 1 + > drivers/thermal/mediatek/gpueb_thermal.c | 52 ++++++++++++++++++++++++++= ++++++ > 3 files changed, 62 insertions(+) >=20 > diff --git a/drivers/thermal/mediatek/Kconfig b/drivers/thermal/mediatek/= Kconfig > index d82c86d9be56..a721b75d0790 100644 > --- a/drivers/thermal/mediatek/Kconfig > +++ b/drivers/thermal/mediatek/Kconfig > @@ -34,4 +34,13 @@ config MTK_LVTS_THERMAL_DEBUGFS > help > Enable this option to debug the internals of the device driver. > =20 > +config MTK_GPUEB_THERMAL > + tristate "GPUEB GPU temperature driver for MediaTek SoCs" > + depends on MTK_MFG_PM_DOMAIN > + help > + Enable this option if you want to get GPU temperature > + information for MediaTek SoCs such as the MT8196. > + The temperature is reported by the GPUEB, the microcontroller > + that manages the GPU power and frequency. > + > endif > diff --git a/drivers/thermal/mediatek/Makefile b/drivers/thermal/mediatek= /Makefile > index 1c6daa1e644b..3ec5295e8514 100644 > --- a/drivers/thermal/mediatek/Makefile > +++ b/drivers/thermal/mediatek/Makefile > @@ -1,2 +1,3 @@ > obj-$(CONFIG_MTK_SOC_THERMAL) +=3D auxadc_thermal.o > obj-$(CONFIG_MTK_LVTS_THERMAL) +=3D lvts_thermal.o > +obj-$(CONFIG_MTK_GPUEB_THERMAL) +=3D gpueb_thermal.o > diff --git a/drivers/thermal/mediatek/gpueb_thermal.c b/drivers/thermal/m= ediatek/gpueb_thermal.c > new file mode 100644 > index 000000000000..f63b5751a0c0 > --- /dev/null > +++ b/drivers/thermal/mediatek/gpueb_thermal.c > @@ -0,0 +1,52 @@ > +// SPDX-License-Identifier: GPL-2.0-only > +/* > + * Copyright (C) 2026 BayLibre, SAS > + */ > + > +#include > +#include > +#include already provides auxiliary_device_id with much less overhead than . So to reduce build time (a tiny bit) and build dependencies and not fight against my quest to remove , please drop the #include for . Thanks Uwe --sgkx5usyeo3f4s6v Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEP4GsaTp6HlmJrf7Tj4D7WH0S/k4FAmsNltsACgkQj4D7WH0S /k4/swgAmD03JtFswv3Kzu/UVE/udTb+JvqDEd82UXAv2fTy+mS0Oxlif+ssSqUC XnT7yjPW4HbEHEJCjyECb9202EH547uNeXtq9SClZ2JaKDuNsRvIFFTbp8v2PdRr Q5uzC43bjNej30OyUMLvw+QSd4Sc9jMHFskm1t7LKu0ABaymZRYjZgjV7fCI8gFk fo+im3ggaQlPVYFe/QQJMscayktfDgPg/EqrLsGI49RIiXuqMDf6ycmFL5Til2zw ffyOW8Rwj50mKXXBlw492QvY9zkMVRdVRUlbDLfAkaXSaUiX2zH75ye26p/J2cW4 l+j4/uogXN3FPluod96DH9uXXYHN6g== =u2qw -----END PGP SIGNATURE----- --sgkx5usyeo3f4s6v--