From 985acc218bf9e3f5ed6a386cf43feecd432365fb Mon Sep 17 00:00:00 2001 From: Matt DeVillier Date: Sun, 29 Jan 2023 15:36:45 -0600 Subject: ec/google/wilco/acpi: Add DPTF RCDP() method The Windows DPTF drivers expect this method, and if not present appear to hang. Adding this method fixes DPTF under Windows on drallion. Modeled after existing method used by chrome-ec. TEST=build/boot Win11 on google/drallion, verify DPTF functional. Change-Id: I6570345379da413273251ecf5209c4997aac9b11 Original-patch-by: Coolstar Signed-off-by: Matt DeVillier Reviewed-on: https://review.coreboot.org/c/coreboot/+/72578 Tested-by: build bot (Jenkins) Reviewed-by: Eric Lai Reviewed-by: Caveh Jalali --- src/ec/google/wilco/acpi/dptf.asl | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'src/ec/google/wilco/acpi') diff --git a/src/ec/google/wilco/acpi/dptf.asl b/src/ec/google/wilco/acpi/dptf.asl index 6de72e817d..1b2bf80c2e 100644 --- a/src/ec/google/wilco/acpi/dptf.asl +++ b/src/ec/google/wilco/acpi/dptf.asl @@ -116,3 +116,18 @@ Method (PATX, 0, Serialized) /* Clear sensor events */ W (DWTQ, Local0) } + +#ifdef EC_ENABLE_MULTIPLE_DPTF_PROFILES +/* + * Read current Device DPTF Profile Number + */ +Method (RCDP, 0, NotSerialized) +{ + Local0 = R(DRTI) + If (Local0 == 0) { + Return (R(OTBL)) + } else { + Return (Local0 - 1) + } +} +#endif -- cgit v1.2.3