thermal/intel: Introduce intel-tcc lib and enhance tjmax handling
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest6 patches 1 replyIn review
- v16 patches 16 repliesSuperseded
Changes in v2 from the cover letter
- remove unnecessary API parameters
- avoid reading MSR on a remote CPU when possible
- coding format improvements
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | thermal/intel: Introduce Intel TCC librarydrivers/ drivers/ drivers/ +1 more | +162 | 0 replies | |
| 2/6 | thermal/int340x/processor_thermal: Use Intel TCC librarydrivers/ drivers/ | +22 | 0 replies | |
| 3/6 | thermal/intel/intel_soc_dts_iosf: Use Intel TCC librarydrivers/ drivers/ | +6 | 0 replies | |
| 4/6 | thermal/intel/intel_tcc_cooling: Use Intel TCC librarydrivers/ drivers/ | +9 | 0 replies | |
| 5/6 | thermal/x86_pkg_temp_thermal: Use Intel TCC librarydrivers/ drivers/ | +14 | 0 replies | |
| 6/6 | thermal/x86_pkg_temp_thermal: Add support for handling dynamic tjmaxdrivers/ | +19 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH V2 0/6] thermal/intel: Introduce intel-tcc lib and enhance tjmax handling
Currently, all the thermal drivers that access the Intel CPU TCC (thermal control circuitry) MSRs have two problems,
1. they have their own implementation for the same TCC functionalities, including getting the tjmax/temperature, getting/setting the TCC offset. This introduces a lot of duplicate code.
2. they get TjMax value once and always use the cached value later. But Tjmax value retrieved from MSR_IA32_TEMPERATURE_TARGET can be changed at runtime for cases like the Intel SST-PP (Intel Speed Select Technology- Performance Profile) level change.
The intel-tcc library is introduced in patch 1/6 for cleaning up the duplicate code among these drivers, and it also ensures the temperature is alway got based on the updated tjmax value.
Patch 2 ~ 5 cleans up the drivers by using the new Intel TCC lib APIs.
Patch 6/6 enhances the x86_pkg_temp driver to handle dynamic tjmax when progamming the thermal interrupt threshold.
Actually, the thermal interrupt threshold programming can also be part of the TCC library, but I didn't do it in this version because x86_pkg_temp is the only user for now.
thanks,
rui
---
Changes since V1:
- remove unnecessary API parameters
- avoid reading MSR on a remote CPU when possible
- coding format improvements