Skip to content

Commit 4ac4677

Browse files
committed
Merge tag 'thermal-6.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull thermal control updates from Rafael Wysocki: "These further rework the ACPI thermal driver, after the changes made to it in the previous cycle, to make it easier to grasp, get rid of redundant pieces of internal data structures and eliminate its reliance on a specific ordering of trip point objects in the thermal core, make thermal core adjustments needed for the ACPI thermal driver rework, modify the thermal governor interface so as to use trip pointers for representing trip points in it, switch over multiple thermal drivers to using void platform driver remove callbacks, add support for 2 hardware features to the Intel int340x thermal driver, add support for new hardware on ARM platforms, update documentation, fix problems, clean up code and update the MAINTAINERS record for thermal control. Specifics: - Untangle the initialization and updates of passive and active trip points in the ACPI thermal driver (Rafael Wysocki) - Reduce code duplication related to the initialization and updates of trip points in the ACPI thermal driver (Rafael Wysocki) - Use trip pointers for cooling device binding in the ACPI thermal driver (Rafael Wysocki) - Simplify critical and hot trips representation in the ACPI thermal driver (Rafael Wysocki) - Use trip pointers in thermal governors and in the related part of the thermal core (Rafael Wysocki) - Drop the trips_disabled bitmask that has become redundant from the thermal core (Rafael Wysocki) - Avoid updating trip points when the thermal zone temperature falls into a trip point's hysteresis range (ícolas F. R. A. Prado) - Add power floor notifications support to the int340x thermal control driver (Srinivas Pandruvada) - Rework updating trip points in the int340x thermal driver so that it does not access thermal zone internals directly (Rafael Wysocki) - Use param_get_byte() instead of param_get_int() as the max_idle module parameter .get() callback in the Intel powerclamp thermal driver to avoid possible out-of-bounds access (David Arcari) - Add workload hints support to the int340x thermal driver (Srinivas Pandruvada) - Add support for Mediatek LVTS MT8192 along with suspend/resume routines (Balsam Chihi) - Fix probe for THERMAL_V2 in the Mediatek LVTS driver (Markus Schneider-Pargmann) - Remove duplicate error message from the max76620 driver when thermal_of_zone_register() fails (Thierry Reding) - Add i.MX7D compatible bindings to fix a warning from dtbs_check for the imx6ul platform (Alexander Stein) - Add sa8775p compatible to the QCom tsens driver (Priyansh Jain) - Fix error check in lvts_debugfs_init() to be against PTR_ERR() in the LVTS Mediatek driver (Minjie Du) - Remove unused variable in thermal/tools (Kuan-Wei Chiu) - Document the imx8dl thermal sensor (Fabio Estevam) - Add variable names in callback prototypes to prevent warning from checkpatch.pl in the imx8mm driver (Bragatheswaran Manickavel) - Add missing unevaluatedProperties on child node schemas for tegra124 (Rob Herring) - Add mt7988 support to the Mediatek LVTS driver (Frank Wunderlich)" * tag 'thermal-6.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (111 commits) thermal: ACPI: Include the right header file thermal: core: Don't update trip points inside the hysteresis range thermal: core: Pass trip pointer to governor throttle callback thermal: gov_step_wise: Fold update_passive_instance() into its caller thermal: gov_power_allocator: Use trip pointers instead of trip indices thermal: gov_fair_share: Rearrange get_trip_level() thermal: trip: Define for_each_trip() macro thermal: trip: Simplify computing trip indices thermal/qcom/tsens: Drop ops_v0_1 thermal/drivers/mediatek/lvts_thermal: Update calibration data documentation thermal/drivers/mediatek/lvts_thermal: Add mt8192 support thermal/drivers/mediatek/lvts_thermal: Add suspend and resume dt-bindings: thermal: mediatek: Add LVTS thermal controller definition for mt8192 thermal/drivers/mediatek: Fix probe for THERMAL_V2 thermal/drivers/max77620: Remove duplicate error message dt-bindings: timer: add imx7d compatible dt-bindings: net: microchip: Allow nvmem-cell usage dt-bindings: imx-thermal: Add #thermal-sensor-cells property dt-bindings: thermal: tsens: Add sa8775p compatible thermal/drivers/mediatek/lvts_thermal: Fix error check in lvts_debugfs_init() ...
2 parents 89ed67e + 607218d commit 4ac4677

File tree

75 files changed

+2170
-1048
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

75 files changed

+2170
-1048
lines changed

Documentation/devicetree/bindings/net/microchip,lan95xx.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ properties:
4444

4545
local-mac-address: true
4646
mac-address: true
47+
nvmem-cells: true
48+
nvmem-cell-names: true
4749

4850
required:
4951
- compatible

Documentation/devicetree/bindings/thermal/fsl,scu-thermal.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,9 @@ allOf:
1818
properties:
1919
compatible:
2020
items:
21-
- const: fsl,imx8qxp-sc-thermal
21+
- enum:
22+
- fsl,imx8dxl-sc-thermal
23+
- fsl,imx8qxp-sc-thermal
2224
- const: fsl,imx-sc-thermal
2325

2426
'#thermal-sensor-cells':

Documentation/devicetree/bindings/thermal/imx-thermal.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,19 @@ properties:
6060
clocks:
6161
maxItems: 1
6262

63+
"#thermal-sensor-cells":
64+
const: 0
65+
6366
required:
6467
- compatible
6568
- interrupts
6669
- fsl,tempmon
6770
- nvmem-cells
6871
- nvmem-cell-names
6972

73+
allOf:
74+
- $ref: thermal-sensor.yaml#
75+
7076
additionalProperties: false
7177

7278
examples:
@@ -104,5 +110,6 @@ examples:
104110
nvmem-cells = <&tempmon_calib>, <&tempmon_temp_grade>;
105111
nvmem-cell-names = "calib", "temp_grade";
106112
clocks = <&clks IMX6SX_CLK_PLL3_USB_OTG>;
113+
#thermal-sensor-cells = <0>;
107114
};
108115
};

Documentation/devicetree/bindings/thermal/mediatek,lvts-thermal.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ description: |
1818
properties:
1919
compatible:
2020
enum:
21+
- mediatek,mt7988-lvts-ap
2122
- mediatek,mt8192-lvts-ap
2223
- mediatek,mt8192-lvts-mcu
2324
- mediatek,mt8195-lvts-ap

Documentation/devicetree/bindings/thermal/nvidia,tegra124-soctherm.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,12 @@ properties:
6868
patternProperties:
6969
"^(light|heavy|oc1)$":
7070
type: object
71+
additionalProperties: false
72+
7173
properties:
74+
"#cooling-cells":
75+
const: 2
76+
7277
nvidia,priority:
7378
$ref: /schemas/types.yaml#/definitions/uint32
7479
minimum: 1

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ properties:
5151
- qcom,msm8996-tsens
5252
- qcom,msm8998-tsens
5353
- qcom,qcm2290-tsens
54+
- qcom,sa8775p-tsens
5455
- qcom,sc7180-tsens
5556
- qcom,sc7280-tsens
5657
- qcom,sc8180x-tsens

Documentation/devicetree/bindings/thermal/thermal-zones.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ $schema: http://devicetree.org/meta-schemas/base.yaml#
88
title: Thermal zone
99

1010
maintainers:
11-
- Amit Kucheria <amitk@kernel.org>
11+
- Daniel Lezcano <daniel.lezcano@linaro.org>
1212

1313
description: |
1414
Thermal management is achieved in devicetree by describing the sensor hardware

Documentation/devicetree/bindings/timer/fsl,imxgpt.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@ properties:
3636
- fsl,imxrt1170-gpt
3737
- const: fsl,imx6dl-gpt
3838
- items:
39-
- const: fsl,imx6ul-gpt
39+
- enum:
40+
- fsl,imx6ul-gpt
41+
- fsl,imx7d-gpt
4042
- const: fsl,imx6sx-gpt
4143

4244
reg:

Documentation/driver-api/thermal/intel_dptf.rst

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,16 @@ ABI.
164164
``power_limit_1_tmax_us`` (RO)
165165
Maximum powercap sysfs constraint_1_time_window_us for Intel RAPL
166166

167+
``power_floor_status`` (RO)
168+
When set to 1, the power floor of the system in the current
169+
configuration has been reached. It needs to be reconfigured to allow
170+
power to be reduced any further.
171+
172+
``power_floor_enable`` (RW)
173+
When set to 1, enable reading and notification of the power floor
174+
status. Notifications are triggered for the power_floor_status
175+
attribute value changes.
176+
167177
:file:`/sys/bus/pci/devices/0000\:00\:04.0/`
168178

169179
``tcc_offset_degree_celsius`` (RW)
@@ -315,3 +325,57 @@ DPTF Fan Control
315325
----------------------------------------
316326

317327
Refer to Documentation/admin-guide/acpi/fan_performance_states.rst
328+
329+
Workload Type Hints
330+
----------------------------------------
331+
332+
The firmware in Meteor Lake processor generation is capable of identifying
333+
workload type and passing hints regarding it to the OS. A special sysfs
334+
interface is provided to allow user space to obtain workload type hints from
335+
the firmware and control the rate at which they are provided.
336+
337+
User space can poll attribute "workload_type_index" for the current hint or
338+
can receive a notification whenever the value of this attribute is updated.
339+
340+
file:`/sys/bus/pci/devices/0000:00:04.0/workload_hint/`
341+
Segment 0, bus 0, device 4, function 0 is reserved for the processor thermal
342+
device on all Intel client processors. So, the above path doesn't change
343+
based on the processor generation.
344+
345+
``workload_hint_enable`` (RW)
346+
Enable firmware to send workload type hints to user space.
347+
348+
``notification_delay_ms`` (RW)
349+
Minimum delay in milliseconds before firmware will notify OS. This is
350+
for the rate control of notifications. This delay is between changing
351+
the workload type prediction in the firmware and notifying the OS about
352+
the change. The default delay is 1024 ms. The delay of 0 is invalid.
353+
The delay is rounded up to the nearest power of 2 to simplify firmware
354+
programming of the delay value. The read of notification_delay_ms
355+
attribute shows the effective value used.
356+
357+
``workload_type_index`` (RO)
358+
Predicted workload type index. User space can get notification of
359+
change via existing sysfs attribute change notification mechanism.
360+
361+
The supported index values and their meaning for the Meteor Lake
362+
processor generation are as follows:
363+
364+
0 - Idle: System performs no tasks, power and idle residency are
365+
consistently low for long periods of time.
366+
367+
1 – Battery Life: Power is relatively low, but the processor may
368+
still be actively performing a task, such as video playback for
369+
a long period of time.
370+
371+
2 – Sustained: Power level that is relatively high for a long period
372+
of time, with very few to no periods of idleness, which will
373+
eventually exhaust RAPL Power Limit 1 and 2.
374+
375+
3 – Bursty: Consumes a relatively constant average amount of power, but
376+
periods of relative idleness are interrupted by bursts of
377+
activity. The bursts are relatively short and the periods of
378+
relative idleness between them typically prevent RAPL Power
379+
Limit 1 from being exhausted.
380+
381+
4 – Unknown: Can't classify.

MAINTAINERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21402,8 +21402,8 @@ F: drivers/media/radio/radio-raremono.c
2140221402
THERMAL
2140321403
M: Rafael J. Wysocki <[email protected]>
2140421404
M: Daniel Lezcano <[email protected]>
21405-
R: Amit Kucheria <[email protected]>
2140621405
R: Zhang Rui <[email protected]>
21406+
R: Lukasz Luba <[email protected]>
2140721407
2140821408
S: Supported
2140921409
Q: https://patchwork.kernel.org/project/linux-pm/list/

0 commit comments

Comments
 (0)