From 18a7c0fc7aab50e18c2d264bb89a8d7d01e1c1e9 Mon Sep 17 00:00:00 2001 From: Sean Rhodes Date: Mon, 7 Mar 2022 07:48:21 +0000 Subject: ec/starlabs/merlin: Use ECWR function Use ECWR function, instead of writing raw values to emem, to avoid a lack of syncronisation as it uses a mutex. Signed-off-by: Sean Rhodes Change-Id: I90cfd3e1752fe25493bd72ea6bcab1fd9318d2e3 Reviewed-on: https://review.coreboot.org/c/coreboot/+/62637 Tested-by: build bot (Jenkins) Reviewed-by: Angel Pons --- src/ec/starlabs/merlin/acpi/suspend.asl | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src') diff --git a/src/ec/starlabs/merlin/acpi/suspend.asl b/src/ec/starlabs/merlin/acpi/suspend.asl index 70a9bda6d4..679281a0b3 100644 --- a/src/ec/starlabs/merlin/acpi/suspend.asl +++ b/src/ec/starlabs/merlin/acpi/suspend.asl @@ -89,15 +89,15 @@ Method (RWAK, 1, Serialized) // 0x01 == Disabled == 0x22 Case (0x00) { - \_SB.PCI0.LPCB.EC.TPLE = 0x00 + \_SB.PCI0.LPCB.EC.ECWR (0x00, RefOf(\_SB.PCI0.LPCB.EC.TPLE)) } Case (0x01) { - \_SB.PCI0.LPCB.EC.TPLE = 0x22 + \_SB.PCI0.LPCB.EC.ECWR (0x22, RefOf(\_SB.PCI0.LPCB.EC.TPLE)) } } - \_SB.PCI0.LPCB.EC.FLKE = \_SB.PCI0.LPCB.FLKC + \_SB.PCI0.LPCB.EC.ECWR (\_SB.PCI0.LPCB.FLKC, RefOf(\_SB.PCI0.LPCB.EC.FLKE)) Switch (ToInteger (\_SB.PCI0.LPCB.KLSC)) { @@ -105,11 +105,11 @@ Method (RWAK, 1, Serialized) // 0x01 == Enabled == 0xdd Case (0x00) { - \_SB.PCI0.LPCB.EC.KLSE = 0x00 + \_SB.PCI0.LPCB.EC.ECWR (0x00, RefOf(\_SB.PCI0.LPCB.EC.KLSE)) } Case (0x01) { - \_SB.PCI0.LPCB.EC.KLSE = 0xdd + \_SB.PCI0.LPCB.EC.ECWR (0xdd, RefOf(\_SB.PCI0.LPCB.EC.KLSE)) } } @@ -121,19 +121,19 @@ Method (RWAK, 1, Serialized) // 0x03 == High == 0xaa Case (0x00) { - \_SB.PCI0.LPCB.EC.KLBE = 0xdd + \_SB.PCI0.LPCB.EC.ECWR (0xdd, RefOf(\_SB.PCI0.LPCB.EC.KLBE)) } Case (0x01) { - \_SB.PCI0.LPCB.EC.KLBE = 0xcc + \_SB.PCI0.LPCB.EC.ECWR (0xcc, RefOf(\_SB.PCI0.LPCB.EC.KLBE)) } Case (0x02) { - \_SB.PCI0.LPCB.EC.KLBE = 0xbb + \_SB.PCI0.LPCB.EC.ECWR (0xbb, RefOf(\_SB.PCI0.LPCB.EC.KLBE)) } Case (0x03) { - \_SB.PCI0.LPCB.EC.KLBE = 0xaa + \_SB.PCI0.LPCB.EC.ECWR (0xaa, RefOf(\_SB.PCI0.LPCB.EC.KLBE)) } } } -- cgit v1.2.3