diff options
Diffstat (limited to 'src/soc/intel/common/acpi')
-rw-r--r-- | src/soc/intel/common/acpi/dptf/dptf.asl | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/soc/intel/common/acpi/dptf/dptf.asl b/src/soc/intel/common/acpi/dptf/dptf.asl index beb41e2dea..1dd57c04dc 100644 --- a/src/soc/intel/common/acpi/dptf/dptf.asl +++ b/src/soc/intel/common/acpi/dptf/dptf.asl @@ -95,6 +95,21 @@ Device (DPTF) Return (Local0) } + /* Convert from 1/10 Kelvin to Degrees C for ACPI */ + Method (KTOC, 1) { + If (LLessEqual (Arg0, 2732)) { + Return (0) + } + + /* Convert to Celsius */ + Subtract (Arg0, 2732, Local0) + + /* Convert from 10th of degrees */ + Divide (Local0, 10,, Local0) + + Return (Local0) + } + /* Include Thermal Participants */ #include "thermal.asl" |