Skip to content

hwmon (coretemp): Add support for dynamic tjmax/ttarget

Zhang Rui linux-hwmon 2 versions – Applied

Status from this message: Applied to hwmon-next.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 3 repliesApplied
  2. v13 patches 5 repliesApplied

Changes in v2 from the cover letter

- rearrange the code to avoid forward declaration
- optimize logic to check target temperature support only once
- coding style changes

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/3hwmon (coretemp): rearrange tjmax handing codedrivers/hwmon/coretemp.c+78 -781 reply
2/3hwmon (coretemp): Add support for dynamic tjmaxdrivers/hwmon/coretemp.c+31 -151 reply
3/3hwmon (coretemp): Add support for dynamic ttargetdrivers/hwmon/coretemp.c+41 -161 reply

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH V2 0/3] hwmon (coretemp): Add support for dynamic tjmax/ttarget

Tjmax value retrieved from MSR_IA32_TEMPERATURE_TARGET can be changed at runtime when the Intel SST-PP (Intel Speed Select Technology - Performance Profile) level is changed. As a result, the ttarget temperature also changes.

Enhance the coretemp driver to always use updated tjmax when it can be retrieved from MSR_IA32_TEMPERATURE_TARGET.

When tjmax can not be retrieved from MSR_IA32_TEMPERATURE_TARGET, stick with previous behavior and always use static value. Plus that ttarget is not available in this case.

The same dynaimic tjmax enhancement, for driver/thermal drivers can be found at https://patchwork.kernel.org/project/linux-pm/list/?series=693050

thanks,
rui

---
Changes since V1:
- rearrange the code to avoid forward declaration
- optimize logic to check target temperature support only once
- coding style changes