Skip to content

Commit f20025d

Browse files
committed
Merge branch 'thermal' into linux-next
* thermal: ACPI: thermal: Execute _SCP before reading trip points ACPI: OSI: Stop advertising support for "3.0 _SCP Extensions" thermal/drivers/airoha: Fix spelling mistake thermal/drivers/qcom/tsens: Add support for IPQ5018 tsens thermal/drivers/qcom/tsens: Add support for tsens v1 without RPM thermal/drivers/qcom/tsens: Update conditions to strictly evaluate for IP v2+ dt-bindings: thermal: qcom-tsens: Add ipq5018 compatible thermal/drivers: Add support for Airoha EN7581 thermal sensor dt-bindings: thermal: Add support for Airoha EN7581 thermal sensor thermal/drivers/mediatek/lvts: Remove unused lvts_debugfs_exit thermal/drivers/mediatek/lvts: Fix debugfs unregister on failure thermal/drivers/amlogic: Rename Uptat to uptat to follow kernel coding style vsprintf: remove redundant and unused %pCn format specifier thermal/drivers/bcm2835: Use %pC instead of %pCn thermal/drivers/hisi: Do not enable by default during compile testing thermal: int340x: processor_thermal: Platform temperature control documentation thermal: intel: int340x: Enable platform temperature control thermal: intel: int340x: Add platform temperature control interface
2 parents fcdb3a6 + a60a98c commit f20025d

22 files changed

Lines changed: 946 additions & 49 deletions

File tree

Documentation/core-api/printk-formats.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -571,9 +571,8 @@ struct clk
571571
::
572572

573573
%pC pll1
574-
%pCn pll1
575574

576-
For printing struct clk structures. %pC and %pCn print the name of the clock
575+
For printing struct clk structures. %pC prints the name of the clock
577576
(Common Clock Framework) or a unique 32-bit ID (legacy clock framework).
578577

579578
Passed by reference.
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2+
%YAML 1.2
3+
---
4+
$id: http://devicetree.org/schemas/thermal/airoha,en7581-thermal.yaml#
5+
$schema: http://devicetree.org/meta-schemas/core.yaml#
6+
7+
title: Airoha EN7581 Thermal Sensor and Monitor
8+
9+
maintainers:
10+
- Christian Marangi <ansuelsmth@gmail.com>
11+
12+
properties:
13+
compatible:
14+
const: airoha,en7581-thermal
15+
16+
reg:
17+
maxItems: 1
18+
19+
interrupts:
20+
maxItems: 1
21+
22+
airoha,chip-scu:
23+
description: phandle to the chip SCU syscon
24+
$ref: /schemas/types.yaml#/definitions/phandle
25+
26+
'#thermal-sensor-cells':
27+
const: 0
28+
29+
required:
30+
- compatible
31+
- reg
32+
- interrupts
33+
- airoha,chip-scu
34+
35+
additionalProperties: false
36+
37+
examples:
38+
- |
39+
#include <dt-bindings/interrupt-controller/arm-gic.h>
40+
41+
thermal-sensor@1efbd800 {
42+
compatible = "airoha,en7581-thermal";
43+
reg = <0x1efbd000 0xd5c>;
44+
interrupts = <GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH>;
45+
airoha,chip-scu = <&chip_scu>;
46+
47+
#thermal-sensor-cells = <0>;
48+
};

Documentation/devicetree/bindings/thermal/qcom-tsens.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ properties:
3939
- description: v1 of TSENS
4040
items:
4141
- enum:
42+
- qcom,ipq5018-tsens
4243
- qcom,msm8937-tsens
4344
- qcom,msm8956-tsens
4445
- qcom,msm8976-tsens
@@ -251,6 +252,7 @@ allOf:
251252
compatible:
252253
contains:
253254
enum:
255+
- qcom,ipq5018-tsens
254256
- qcom,ipq8064-tsens
255257
- qcom,msm8960-tsens
256258
- qcom,tsens-v0_1

Documentation/driver-api/thermal/intel_dptf.rst

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,27 @@ ABI.
191191
User space can specify any one of the available workload type using
192192
this interface.
193193

194+
:file:`/sys/bus/pci/devices/0000\:00\:04.0/ptc_0_control`
195+
:file:`/sys/bus/pci/devices/0000\:00\:04.0/ptc_1_control`
196+
:file:`/sys/bus/pci/devices/0000\:00\:04.0/ptc_2_control`
197+
198+
All these controls needs admin privilege to update.
199+
200+
``enable`` (RW)
201+
1 for enable, 0 for disable. Shows the current enable status of
202+
platform temperature control feature. User space can enable/disable
203+
hardware controls.
204+
205+
``temperature_target`` (RW)
206+
Update a new temperature target in milli degree celsius for hardware to
207+
use for the temperature control.
208+
209+
Given that this is platform temperature control, it is expected that a
210+
single user-level manager owns and manages the controls. If multiple
211+
user-level software applications attempt to write different targets, it
212+
can lead to unexpected behavior.
213+
214+
194215
DPTF Processor thermal RFIM interface
195216
--------------------------------------------
196217

Documentation/translations/zh_CN/core-api/printk-formats.rst

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -523,9 +523,8 @@ clk结构体
523523
::
524524

525525
%pC pll1
526-
%pCn pll1
527526

528-
用于打印clk结构。%pC 和 %pCn 打印时钟的名称(通用时钟框架)或唯一的32位
527+
用于打印clk结构。%pC 打印时钟的名称(通用时钟框架)或唯一的32位
529528
ID(传统时钟框架)。
530529

531530
通过引用传递。

drivers/acpi/osi.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ static struct acpi_osi_entry
4242
osi_setup_entries[OSI_STRING_ENTRIES_MAX] __initdata = {
4343
{"Module Device", true},
4444
{"Processor Device", true},
45-
{"3.0 _SCP Extensions", true},
4645
{"Processor Aggregator Device", true},
4746
};
4847

drivers/acpi/thermal.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -803,6 +803,12 @@ static int acpi_thermal_add(struct acpi_device *device)
803803

804804
acpi_thermal_aml_dependency_fix(tz);
805805

806+
/*
807+
* Set the cooling mode [_SCP] to active cooling. This needs to happen before
808+
* we retrieve the trip point values.
809+
*/
810+
acpi_execute_simple_method(tz->device->handle, "_SCP", ACPI_THERMAL_MODE_ACTIVE);
811+
806812
/* Get trip points [_ACi, _PSV, etc.] (required). */
807813
acpi_thermal_get_trip_points(tz);
808814

@@ -814,10 +820,6 @@ static int acpi_thermal_add(struct acpi_device *device)
814820
if (result)
815821
goto free_memory;
816822

817-
/* Set the cooling mode [_SCP] to active cooling. */
818-
acpi_execute_simple_method(tz->device->handle, "_SCP",
819-
ACPI_THERMAL_MODE_ACTIVE);
820-
821823
/* Determine the default polling frequency [_TZP]. */
822824
if (tzp)
823825
tz->polling_frequency = tzp;

drivers/thermal/Kconfig

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ config HISI_THERMAL
257257
depends on ARCH_HISI || COMPILE_TEST
258258
depends on HAS_IOMEM
259259
depends on OF
260-
default y
260+
default ARCH_HISI
261261
help
262262
Enable this to plug hisilicon's thermal sensor driver into the Linux
263263
thermal framework. cpufreq is used as the cooling device to throttle
@@ -327,6 +327,15 @@ config QORIQ_THERMAL
327327
cpufreq is used as the cooling device to throttle CPUs when the
328328
passive trip is crossed.
329329

330+
config AIROHA_THERMAL
331+
tristate "Airoha thermal sensor driver"
332+
depends on ARCH_AIROHA || COMPILE_TEST
333+
depends on MFD_SYSCON
334+
depends on OF
335+
help
336+
Enable this to plug the Airoha thermal sensor driver into the Linux
337+
thermal framework.
338+
330339
config SPEAR_THERMAL
331340
tristate "SPEAr thermal sensor driver"
332341
depends on PLAT_SPEAR || COMPILE_TEST

drivers/thermal/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ obj-$(CONFIG_K3_THERMAL) += k3_bandgap.o k3_j72xx_bandgap.o
3838
# platform thermal drivers
3939
obj-y += broadcom/
4040
obj-$(CONFIG_THERMAL_MMIO) += thermal_mmio.o
41+
obj-$(CONFIG_AIROHA_THERMAL) += airoha_thermal.o
4142
obj-$(CONFIG_SPEAR_THERMAL) += spear_thermal.o
4243
obj-$(CONFIG_SUN8I_THERMAL) += sun8i_thermal.o
4344
obj-$(CONFIG_ROCKCHIP_THERMAL) += rockchip_thermal.o

0 commit comments

Comments
 (0)