From 94ad304451c42c79b1a1fab5ede822aba40a909f Mon Sep 17 00:00:00 2001 From: Matt DeVillier Date: Fri, 28 Jul 2023 09:32:07 -0500 Subject: mb/google/rambi: Fix built-in audio under Windows Move the jack detect GpioInt resources under the codec (where they belong), but also leave a copy under LPEA for since the Linux drivers (incorrectly) require them there. Add pin list for Windows' SST driver. Adapted from the Intel ValleyView edk2 ACPI reference code. TEST=build/boot Win11, Linux on google/swanky; verify audio functional OOTB under Linux, under Windows with coolstar's drivers. Change-Id: I51c07013fc20f07d2fd3639f7fbc2af0e0e490a0 Signed-off-by: Matt DeVillier Reviewed-on: https://review.coreboot.org/c/coreboot/+/76795 Reviewed-by: Sean Rhodes Tested-by: build bot (Jenkins) Reviewed-by: CoolStar --- src/mainboard/google/rambi/acpi/mainboard.asl | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) (limited to 'src/mainboard') diff --git a/src/mainboard/google/rambi/acpi/mainboard.asl b/src/mainboard/google/rambi/acpi/mainboard.asl index bfbb66bf80..5f835e8517 100644 --- a/src/mainboard/google/rambi/acpi/mainboard.asl +++ b/src/mainboard/google/rambi/acpi/mainboard.asl @@ -89,6 +89,9 @@ Scope (\_SB.PCI0.I2C2) { BOARD_CODEC_IRQ } + GpioIo (Exclusive, PullNone, 0, 0, , "\\_SB.GPSC", 0, ResourceConsumer, ,){ 0x000E } + + GpioIo (Exclusive, PullNone, 0, 0, , "\\_SB.GPSC", 0, ResourceConsumer, ,){ 0x000F } }) Method (_STA) @@ -107,13 +110,22 @@ Scope (\_SB.PCI0.LPEA) Name (GBUF, ResourceTemplate () { /* Jack Detect (index 0) */ - GpioInt (Level, ActiveHigh, Exclusive, PullNone,, - "\\_SB.GPSC") { 14 } + GpioIo (Exclusive, PullNone, 0, 0, , "\\_SB.GPSC", 0, ResourceConsumer, ,){ 0x000E } /* Mic Detect (index 1) */ - GpioInt (Level, ActiveHigh, Exclusive, PullNone,, - "\\_SB.GPSC") { 15 } + GpioIo (Exclusive, PullNone, 0, 0, , "\\_SB.GPSC", 0, ResourceConsumer, ,){ 0x000F } + + /* SST Wants This */ + GpioInt (Edge, ActiveHigh, Exclusive, PullNone, 0x0000, + "\\_SB.GPSS", 0x00, ResourceConsumer, ,) + { + 0x001C // Pin list + } }) + Method (_DIS, 0x0, NotSerialized) + { + //Add a dummy disable function + } } #include -- cgit v1.2.3