From 35e65a8bc36628baad7d2ed94bef7619971e6d88 Mon Sep 17 00:00:00 2001 From: Felix Singer Date: Fri, 16 Dec 2022 07:11:17 +0100 Subject: tree: Replace And(a,b,c) with ASL 2.0 syntax Replace `And (a, b, c)` with `c = a & b`, respectively `c &= b` where possible. Change-Id: Ie558f9d0b597c56ca3b31498edb68de8877d3a2f Signed-off-by: Felix Singer Reviewed-on: https://review.coreboot.org/c/coreboot/+/70850 Reviewed-by: Eric Lai Tested-by: build bot (Jenkins) --- src/ec/quanta/ene_kb3940q/acpi/ec.asl | 2 +- src/ec/quanta/it8518/acpi/battery.asl | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src/ec/quanta') diff --git a/src/ec/quanta/ene_kb3940q/acpi/ec.asl b/src/ec/quanta/ene_kb3940q/acpi/ec.asl index 9d38bb6461..f60238b950 100644 --- a/src/ec/quanta/ene_kb3940q/acpi/ec.asl +++ b/src/ec/quanta/ene_kb3940q/acpi/ec.asl @@ -131,7 +131,7 @@ Device (EC0) Local0 = CTMP // Use Local0 to avoid iasl warning: Method Local is set but never used - And(Local0, Ones, Local0) + Local0 &= Ones // Find and program number of P-States MPST = SizeOf (\_SB.CP00._PSS) diff --git a/src/ec/quanta/it8518/acpi/battery.asl b/src/ec/quanta/it8518/acpi/battery.asl index ef7a8e2520..53bcb6a10f 100644 --- a/src/ec/quanta/it8518/acpi/battery.asl +++ b/src/ec/quanta/it8518/acpi/battery.asl @@ -244,7 +244,7 @@ Device (BATX) If (ACPW) { // Set only charging/discharging bits - And (Local0, 0x03, Local1) + Local1 = Local0 & 3 } Else { @@ -253,7 +253,7 @@ Device (BATX) } // Flag if the battery level is critical - And (Local0, 0x04, Local4) + Local4 = Local0 & 4 Local1 |= Local4 PBST[0] = Local1 -- cgit v1.2.3