From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.208.44 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796313452; b=HHLIVgMOQJLnjNazfh5DoiUy4JSEAEeYEOFQNPOUfYayF3O3DIpb95iVnPUELMYwbdo8 cpj02pxxuoMwoYzxH5dwD+v7YxUbCsJnlVA5gq5sMxMq4ZhDAPDSMlzfQCD8/w3h5PD7x iGql1x0t+LcZb7pFkVuNlYIHKgyInMzPbsbBFSOyXgHKOfVdDA+NH23J6OU0SLrXFYv5U hACI0pKCtjxGxkUqwNpbG807bbkIR6r3aYOXy2GSl8Js8ahM1GroRwpP5yKnogSQMIRg4 QAdrHoLffJOTdNqo+PqlsyjF+EQuQehqi8UpoiLJ5bZw8GQUKvH7BEHoj29zDTTdppQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796313452; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Forwarded-Encrypted:X-Gm-Message-State:X-Gm-Gg:X-Received:Received: From:To:Cc:Subject:Date:Message-ID:X-Mailer:MIME-Version:Content-Type: Content-Transfer-Encoding; bh=fcHKEpQ8d/bE82uNf/B3T/xARUwqZyVhLdS8EbRnxJc=; b=gmzZ/ivaDcdpgB+MJc8eVuFXLc1TuoOq0WJgIP1/ZD1snn+jeH2jFIgtzwmhfxay/Db+ iZumcBwDcdanOMx+EPeJqyppKXoMDXuFDzzuVSx0DjX6CgBh5MCRiBkzhPEpha/gKtS7/ W0KHhzDpx48sWvx9plAKn2tCvLlLqZRkje5gksuovEN4h1+32s2Gf1DidjrEmBldIaFy9 t6/4MZELZD2LLnY1uiH8n4VIc2qlRUFRPmadkiyPtZbp2lZ9xSLpCQHe9VEmY8/kIyx7N GxOTF0ftBhe/5ZOhA9b7YGt0Dwd1dwfTI+EidCTC+aN/zMJZyqLYfcH1rCzBjWb2sgw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=ZMvIkniB; arc=none smtp.remote-ip=209.85.208.44 Received: from mail-ed1-f44.google.com (mail-ed1-f44.google.com [209.85.208.44]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 64774606A32D for ; Thu, 3 Dec 2026 15:57:32 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 64774606A32D Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=ZMvIkniB Received: by mail-ed1-f44.google.com with SMTP id 4fb4d7f45d1cf-6b86bbce3d1so19506208a12.0 for ; Thu, 03 Dec 2026 07:57:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20260707; t=1796313451; x=1796918251; darn=vger.kernel.org; h=content-transfer-encoding:content-type:mime-version:message-id:date :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to :content-type; bh=fcHKEpQ8d/bE82uNf/B3T/xARUwqZyVhLdS8EbRnxJc=; b=ZMvIkniBBgA66fKdyQ9z4Nwl5BD5PnAmfaidAEO2kZetCVGCQQO8imKIByX4AhZAIF KkKHuXi/QYy+Zvjbzgj2Adhed+9x9jdkIeQD4FAvvERQr8NtbOKR9a60UZBMYcUVVZM4 U7FzdRpSyCyI2WTgCaZhf0KWvHnPrb53AD/EL5yemeZwL7/zrwxGfiZVbfJo7NPQLvvs YaBkj0dwpDwU2Ma6Thtahm6dBBsh/oyBwLMZ2e7+sDkE21FNdUx898s3+kENr9p5YJQ9 X8YZEqJm6AtQaU2HTUGHGSE6FV+eFY2XtrhZUjaLhrbZ71P/oMRrRDw9Qx0G+C/oW3iF feKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796313451; x=1796918251; h=content-transfer-encoding:content-type:mime-version:message-id:date :subject:cc:to:from:x-gm-gg:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to:content-type; bh=fcHKEpQ8d/bE82uNf/B3T/xARUwqZyVhLdS8EbRnxJc=; b=vG08xxcPJYg/XO5MAYRwmy0ESS59T2WX/CeTaQ18YtEFvI9rkijaQcQL9EL2Kxvxlt NKjJjOdC9vouMS/iWm3bBv7P/HEy5ZInP54FZN3miki+6Jw8lRMZJccc1HeE3A0k9iKH +i5I+8pGbPWGG3rv06uLWHmZFSmI+QmKxV4uJPzV/sDqlkja7LddPZKvXoQAvB8y3bal K39Kp4YXE+TeSNQvv2mbxUeg7cuymWXVXZehRJVgpuVqzQqnpnfC06Krn5hd4Li4G0CE sprxi+egJM/2SVeg7ggEbbLfcwy9ybn9JfQBVf2h0W+iLQcw7u8UMpdTezTCfr+HD2sB GLQA== X-Forwarded-Encrypted: i=1; AL+hErEDT79u+I8OqcVK0kUkihonV6FfMSTWO4O5dju2zWkk3s51SZvgE7NNA9s1dxt1qb91vITTHLgfc6z+w5g=@vger.kernel.org X-Gm-Message-State: APuU4Z9pFc81LeIrlSnc0wyaT37sWH9nXNEuMMIgwGLJ+6FZnD57ZWUw X+vBp96p+MexcLo5JPmMzDQCRjeXP+tR1a18sQPBNdr8Mz0MvUsoYZsL X-Gm-Gg: AZFdTZdjbQjYtAbnLy0b9YxRdHbumQegZxNaha3lyZ2LPeRkFhrrl3NuAcly5/Tc6Dq E5+LhY1f0gyFmVNN/GCHaLGocy2SlIhWiDM2vwp85vFCzAYCnBhJYz8jCSIGCymhGPAN46Wj7Ul g+nZy8Jx/nOMWFLt+sL/+GOAEEfuXb9FEx6qaCMV6drNuvTdp2udv9C8Ng8kf/YbAjufmYnAHb1 fU7r7oXFSPP1gPFSa2+vyilqFQDvYrhYA9f8wR3BuP3AP+xfMz0wH3yiWkLym72brjkbmeEK4sN vnjO/Qmf7ii8pmDqco+L0TpYNb/ommrtagp2v7PRDaWML5TPkoVHyXgi1D55RwFmvWA8RCWdv5L okyqjAOiL3HHy5ot5tPYjdWE7Jc66AEHbVh5zV5encZMFYW2xKyZbdcjh2nHTisFwz3i6H4A5RI 3YDrBS75nlKQH4EfHBt/1eKDkLhtbS2NmjdEnpOWEZduLa5jBKPqd+P1TVM2qpE/4VZbEKrraE/ 3sRRD4BrkbK6Jt5GzGhPohNdJqRAiNGzXzqdJF/GwkRTPBST4v1DyYi4oWQ989r49sxYh2b9ezJ fWP2p6196uoW9USKOB1D9KL60e9G94TelxkkBzpaM1uvWsh2tgWEZZYZp+8z9QLeGmbodNITvQJ mPGIz2WuqQaVWblk0JaCj6jEqZwML/EwT9bQPmfL7frUu X-Received: by 2002:a05:6402:274d:b0:6ba:92c3:ff04 with SMTP id 4fb4d7f45d1cf-6ba92c40932mr26037226a12.26.1796313450601; Thu, 03 Dec 2026 07:57:30 -0800 (PST) Received: from thinkpad16.ts.appmire.be ([94.110.48.221]) by smtp.gmail.com with ESMTPSA id 4fb4d7f45d1cf-6bc65ddf159sm1896383a12.10.2026.12.03.07.57.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Dec 2026 07:57:29 -0800 (PST) From: Jeroen Trappers To: rafael@kernel.org, daniel.lezcano@kernel.org, sven@kernel.org, j@jannau.net, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org Cc: rui.zhang@intel.com, lukasz.luba@arm.com, neal@gompa.dev, towinchenmi@gmail.com, konradybcio@kernel.org, asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/3] Apple T7000 (A8) die temperature sensors and thermal zones Date: Thu, 3 Dec 2026 16:55:57 +0100 Message-ID: <20261203155600.3911447-1-jeroen.trappers@gmail.com> X-Mailer: git-send-email 2.47.3 X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Apple A8 has had no thermal zones in Linux: unlike Apple Silicon Macs it has no SMC doing thermal management in firmware, and on iOS the kernel reads the die sensors itself. With nothing reading them, the only protection is the hardware failsafe (SoCHOT) at 120 C. This adds a binding and a driver for the A8's five die temperature sensors (two in the power manager, three in the CPU complex), and thermal zones in t7000.dtsi on three of them that throttle the CPUs from 70 C, with 90 C hot and 100 C critical. The register interface is the one iOS drives (AppleT700XTempSensor): only 32-bit accesses, a freeze / read / restart of each sensor's accumulator, no writes to calibration, alarm or SoCHOT registers, and the per-sensor offsets from the tempsensor0..4 nodes of the iPhone 6 device tree. The driver is adapted from Berkay Kösebay's out-of-tree A9 (S8003) driver for the same block. The A8X (t7001) has the same block; a compatible for it can follow once it is tested there. Testing, on an iPhone 6 (N61), with this driver byte-identical on a 7.3-rc1 based kernel (the iPhone 6 port this work comes from), whose t7000.dtsi has the same sensor node and whose n61 zones use the same sensors and trips (plus a GPU cooling map for a GPU driver that is not upstream); the v7.4-rc5 tree itself was not booted: - the used sensors (IDs 0, 1, 4) accumulate about 400 samples a second; the unused TCC0 / TCC1 are left untouched; unbinding the driver stops the used ones again; - 37 / 38 / 40 C (SOC0 / SOC1 / CPU complex) idle after boot; - two busy cores take the CPU complex sensor past 70 C within 10 s; the zone steps the CPUs to 1128 MHz and holds 67-74 C, while the power manager sensors stay at 55-61 C. On v7.4-rc5: W=1 / W=12 builds (arm64, and x86_64 with COMPILE_TEST), checkpatch --strict, dt_binding_check and CHECK_DTBS for every t7000 board are clean. Tool use (Documentation/process/generated-content.rst): the series was written with an LLM coding assistant over a longer working session. It drafted the driver (adapting the A9 driver to the A8 offsets and the iOS register sequence), the binding, the device tree nodes and the changelogs, and ran the on-device register checks, thermal tests and build and schema checks under my direction; a separate LLM review pass found issues that were fixed before posting. I have reviewed the series and can answer for it. Jeroen Trappers (3): dt-bindings: thermal: Add Apple T7000 die temperature sensors thermal/drivers/apple: Add T7000 (A8) on-die temperature sensor driver arm64: dts: apple: t7000: Add die temperature sensors and thermal zones .../bindings/thermal/apple,t7000-thermal.yaml | 65 +++++ MAINTAINERS | 8 + arch/arm64/boot/dts/apple/t7000.dtsi | 119 +++++++++ drivers/thermal/Kconfig | 13 + drivers/thermal/Makefile | 1 + drivers/thermal/apple_t7000_thermal.c | 239 ++++++++++++++++++ 6 files changed, 445 insertions(+) create mode 100644 Documentation/devicetree/bindings/thermal/apple,t7000-thermal.yaml create mode 100644 drivers/thermal/apple_t7000_thermal.c base-commit: fe6ff8d5d675c01793b9f051d16055dd4aa75244 -- 2.47.3