From a48a3f3ef31e7741cc1139753d3c01c9db1c57ac Mon Sep 17 00:00:00 2001 From: CoolStar Date: Fri, 3 May 2024 02:44:59 -0700 Subject: [PATCH] ec/google/chromeec/acpi/cros_ec: Ensure GpioInt and _PRW are mutually exclusive Under Windows ACPI, GpioInt and _PRW must be mututally exclusive within the scope of a device, otherwise a BSOD occurs with an ACPI_BIOS_ERROR. To enforce this, only use _PRW when EC_ENABLE_SYNC_IRQ_GPIO is not set. If both EC_ENABLE_WAKE_PIN and EC_ENABLE_SYNC_IRQ_GPIO are set, then ensure that the GpioInt is flagged as ExclusiveAndWake (vs just Exclusive) so that the CREC device is still able to wake the device as needed. TEST=Build/boot google/{nocturne,frostflow} to Win11 w/ sync_irq_gpio and wake_pin both enabled. Change-Id: Ia59cce2ee12bfc8d3ac0173a7a4ec88d7079a958 Signed-off-by: CoolStar Signed-off-by: Matt DeVillier Reviewed-on: https://review.coreboot.org/c/coreboot/+/82233 Reviewed-by: Paul Menzel Reviewed-by: Subrata Banik Tested-by: build bot (Jenkins) --- src/ec/google/chromeec/acpi/cros_ec.asl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ec/google/chromeec/acpi/cros_ec.asl b/src/ec/google/chromeec/acpi/cros_ec.asl index 1159f9f49a..5b5229b601 100644 --- a/src/ec/google/chromeec/acpi/cros_ec.asl +++ b/src/ec/google/chromeec/acpi/cros_ec.asl @@ -6,7 +6,11 @@ Device (CREC) Name (_UID, 1) Name (_DDN, "EC Command Device") #ifdef EC_ENABLE_WAKE_PIN +#ifndef EC_ENABLE_SYNC_IRQ_GPIO Name (_PRW, Package () { EC_ENABLE_WAKE_PIN, 0x5 }) +#else +#define EC_SYNC_IRQ_WAKE_CAPABLE +#endif #endif #ifdef EC_SYNC_IRQ_WAKE_CAPABLE