Felix Held has submitted this change. ( https://review.coreboot.org/c/coreboot/+/73890 )
Change subject: mb/google/brya/acpi: Add support for GPS_REQUESTDXSTATE ......................................................................
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 taruntuli@google.com Change-Id: I6dab9b793fe1d0b1c875eddbe6ae324d2894efe6 Reviewed-on: https://review.coreboot.org/c/coreboot/+/73890 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Eric Lai eric_lai@quanta.corp-partner.google.com --- M src/mainboard/google/brya/acpi/gps.asl 1 file changed, 30 insertions(+), 1 deletion(-)
Approvals: build bot (Jenkins): Verified Eric Lai: Looks good to me, approved
diff --git a/src/mainboard/google/brya/acpi/gps.asl b/src/mainboard/google/brya/acpi/gps.asl index 36bccc1..f201037 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 @@ (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 @@ } } } + 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)