From 4877c1c0687b42799c9ab91ba9166cc4d82cb7c4 Mon Sep 17 00:00:00 2001 From: Tarun Tuli Date: Thu, 30 Mar 2023 14:02:22 +0000 Subject: [PATCH] mb/google/brya/acpi: Add support for forcing notifications in DNOT func Currently the DNOT function first checks to see if the current DNOT value has already been reported. Add support to allow forcing regardless if it had been sent already. TEST=confirmed that when enabled, all events notify. When disabled, only events on value change are notified. BUG=b:271938907 Signed-off-by: Tarun Tuli Change-Id: I7a93cca6a8f922574dd46b46572b230755db9aa7 Reviewed-on: https://review.coreboot.org/c/coreboot/+/73900 Tested-by: build bot (Jenkins) Reviewed-by: Eric Lai --- src/mainboard/google/brya/acpi/gpu_ec.asl | 2 +- src/mainboard/google/brya/acpi/gpu_top.asl | 9 ++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/mainboard/google/brya/acpi/gpu_ec.asl b/src/mainboard/google/brya/acpi/gpu_ec.asl index 998d9c0e6a..59875ad138 100644 --- a/src/mainboard/google/brya/acpi/gpu_ec.asl +++ b/src/mainboard/google/brya/acpi/gpu_ec.asl @@ -8,6 +8,6 @@ Scope (\_SB.PCI0.LPCB.EC0) Method (_Q0C, 0, Serialized) { Local0 = ToInteger(GPUD) & EC_D_NOTIFY_MASK - \_SB.PCI0.PEG0.PEGP.DNOT (Local0) + \_SB.PCI0.PEG0.PEGP.DNOT (Local0, 0) } } diff --git a/src/mainboard/google/brya/acpi/gpu_top.asl b/src/mainboard/google/brya/acpi/gpu_top.asl index e23e3cfa5e..492502c3d4 100644 --- a/src/mainboard/google/brya/acpi/gpu_top.asl +++ b/src/mainboard/google/brya/acpi/gpu_top.asl @@ -40,12 +40,15 @@ Scope (\_SB.PCI0.PEG0) } } - /* Current D Notify Value, defaults to D1 */ + /* Current D Notify Value, defaults to D1 + * Arg0 == Shared value + * Arg1 == force notification if no change (0 or 1) + */ Name (CDNV, D1_EC) - Method (DNOT, 1, Serialized) + Method (DNOT, 2, Serialized) { Printf ("EC: GPU D-Notify, %o", Arg0) - If (Arg0 != CDNV) + If ((Arg0 != CDNV) || (Arg1 == 1)) { CDNV = Arg0 Local0 = CNVD (Arg0)