From a0353b573d3b6cc3bef20d2e01ddfbe09730ca27 Mon Sep 17 00:00:00 2001 From: Tarun Tuli Date: Tue, 21 Mar 2023 14:25:04 +0000 Subject: mb/google/brya/acpi: Add support for GPS_REQUESTDXSTATE Implement the GPS_REQUESTDXSTATE function which forces the current D notifier state to re-report. TEST=verified that notifications are forced out when invoked using acpiexec BUG=b:271938907 Signed-off-by: Tarun Tuli Change-Id: I6dab9b793fe1d0b1c875eddbe6ae324d2894efe6 Reviewed-on: https://review.coreboot.org/c/coreboot/+/73890 Tested-by: build bot (Jenkins) Reviewed-by: Eric Lai --- src/mainboard/google/brya/acpi/gps.asl | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'src/mainboard/google/brya/acpi') diff --git a/src/mainboard/google/brya/acpi/gps.asl b/src/mainboard/google/brya/acpi/gps.asl index 36bccc1a98..f201037f06 100644 --- a/src/mainboard/google/brya/acpi/gps.asl +++ b/src/mainboard/google/brya/acpi/gps.asl @@ -4,11 +4,14 @@ #define GPS_FUNC_GETCALLBACKS 0x13 #define GPS_FUNC_PSHARESTATUS 0x20 #define GPS_FUNC_PSHAREPARAMS 0x2a +#define GPS_FUNC_REQUESTDXSTATE 0x12 #define QUERY_GET_STATUS 0 #define QUERY_GET_SUPPORTED_FIELDS 1 #define QUERY_GET_CURRENT_LIMITS 2 +#define EC_D_NOTIFY_MASK 0x7 + /* GPS return Package */ Name (GPSP, Buffer (0x28) {0x0}) CreateDWordField (GPSP, 0, RETN) @@ -31,7 +34,8 @@ Method (GPS, 2, Serialized) (1 << GPS_FUNC_SUPPORT) | (1 << GPS_FUNC_GETCALLBACKS) | (1 << GPS_FUNC_PSHARESTATUS) | - (1 << GPS_FUNC_PSHAREPARAMS))) + (1 << GPS_FUNC_PSHAREPARAMS) | + (1 << GPS_FUNC_REQUESTDXSTATE))) } Case (GPS_FUNC_GETCALLBACKS) { @@ -88,6 +92,12 @@ Method (GPS, 2, Serialized) } } } + Case (GPS_FUNC_REQUESTDXSTATE) + { + Local0 = ToInteger(\_SB.PCI0.LPCB.EC0.GPUD) & EC_D_NOTIFY_MASK + \_SB.PCI0.PEG0.PEGP.DNOT (Local0, 1) + Return (NV_ERROR_SUCCESS) + } } Return (NV_ERROR_UNSUPPORTED) -- cgit v1.2.3