ec/lenovo/h8/acpi: Replace And() with ASL 2.0 syntax

Change-Id: Id600bcb3fad35455adffe11a8105ad2590e83feb
Signed-off-by: Felix Singer <felixsinger@posteo.net>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/60723
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sean Rhodes <sean@starlabs.systems>
This commit is contained in:
Felix Singer
2022-01-03 19:30:43 +01:00
parent 32283a86cf
commit 9a351fb445

View File

@@ -52,7 +52,7 @@ Device (HKEY)
/* Report event */ /* Report event */
Method (RHK, 1, NotSerialized) { Method (RHK, 1, NotSerialized) {
ShiftLeft (One, Arg0 - 1, Local0) ShiftLeft (One, Arg0 - 1, Local0)
If (And (EMSK, Local0)) { If (EMSK & Local0) {
Store (Arg0, BTN) Store (Arg0, BTN)
Notify (HKEY, 0x80) Notify (HKEY, 0x80)
} }
@@ -61,7 +61,7 @@ Device (HKEY)
/* Report tablet */ /* Report tablet */
Method (RTAB, 1, NotSerialized) { Method (RTAB, 1, NotSerialized) {
ShiftLeft (One, Arg0 - 1, Local0) ShiftLeft (One, Arg0 - 1, Local0)
If (And (ETAB, Local0)) { If (ETAB & Local0) {
Store (Arg0, BTAB) Store (Arg0, BTAB)
Notify (HKEY, 0x80) Notify (HKEY, 0x80)
} }
@@ -91,7 +91,7 @@ Device (HKEY)
} }
Else Else
{ {
And (DHKN, Not (Local0), DHKN) DHKN = DHKN & Not (Local0)
} }
If (EN) If (EN)
{ {
@@ -184,9 +184,9 @@ Device (HKEY)
Store (One, HAST) Store (One, HAST)
If (HBDC) { If (HBDC) {
ShiftRight (And(Arg0, 2), 1, Local0) ShiftRight (Arg0 & 2, 1, Local0)
Store (Local0, \_SB.PCI0.LPCB.EC.BTEB) Store (Local0, \_SB.PCI0.LPCB.EC.BTEB)
ShiftRight (And(Arg0, 4), 2, Local0) ShiftRight (Arg0 & 4, 2, Local0)
Store (Local0, WBDC) Store (Local0, WBDC)
} }
} }
@@ -226,9 +226,9 @@ Device (HKEY)
Store (One, HAST) Store (One, HAST)
If (HWAN) { If (HWAN) {
ShiftRight (And(Arg0, 2), 1, Local0) ShiftRight (Arg0 & 2, 1, Local0)
Store (Local0, \_SB.PCI0.LPCB.EC.WWEB) Store (Local0, \_SB.PCI0.LPCB.EC.WWEB)
ShiftRight (And(Arg0, 4), 2, WWAN) ShiftRight (Arg0 & 4, 2, WWAN)
} }
} }
@@ -258,7 +258,7 @@ Device (HKEY)
{ {
If (HKBL) { If (HKBL) {
/* FIXME: Support 2bit brightness control */ /* FIXME: Support 2bit brightness control */
Store (And(Arg0, 1), \_SB.PCI0.LPCB.EC.WWEB) Store (Arg0 & 1, \_SB.PCI0.LPCB.EC.WWEB)
} }
} }
@@ -288,7 +288,7 @@ Device (HKEY)
Method (SUWB, 1) Method (SUWB, 1)
{ {
If (HUWB) { If (HUWB) {
ShiftRight (And(Arg0, 2), 1, Local0) ShiftRight (Arg0 & 2, 1, Local0)
Store (Local0, \_SB.PCI0.LPCB.EC.UWBE) Store (Local0, \_SB.PCI0.LPCB.EC.UWBE)
} }
} }