Nico Huber has submitted this change. ( https://review.coreboot.org/c/coreboot/+/56607 )
Change subject: ec/roda/it8518/acpi: Use mathematical operators ......................................................................
ec/roda/it8518/acpi: Use mathematical operators
Use mathematical operators instead of their equivalent methods.
Change-Id: I5b1d5d9882eae5e8bcf2d97bcefaeea1a7ad8f4d Signed-off-by: Felix Singer felix.singer@secunet.com Reviewed-on: https://review.coreboot.org/c/coreboot/+/56607 Reviewed-by: Angel Pons th3fanbus@gmail.com Tested-by: build bot (Jenkins) no-reply@coreboot.org --- M src/ec/roda/it8518/acpi/battery.asl M src/ec/roda/it8518/acpi/ec.asl 2 files changed, 5 insertions(+), 5 deletions(-)
Approvals: build bot (Jenkins): Verified Angel Pons: Looks good to me, approved
diff --git a/src/ec/roda/it8518/acpi/battery.asl b/src/ec/roda/it8518/acpi/battery.asl index 882168f..e9e7edb 100644 --- a/src/ec/roda/it8518/acpi/battery.asl +++ b/src/ec/roda/it8518/acpi/battery.asl @@ -63,8 +63,8 @@ Printf ("-----> BAT0: _BIF")
PBIF[2] = B0FC - PBIF[5] = Divide (Multiply (B0FC, 6), 100) - PBIF[6] = Divide (Multiply (B0FC, 3), 100) + PBIF[5] = (B0FC * 6) / 100 + PBIF[6] = (B0FC * 3) / 100
Printf ("<----- BAT0: _BIF")
@@ -96,7 +96,7 @@ Local1 = B0AC If (Local1 >= 0x8000) { - Subtract (0x00010000, Local1, Local1) + Local1 = 0x00010000 - Local1 }
PBST[1] = Local1 diff --git a/src/ec/roda/it8518/acpi/ec.asl b/src/ec/roda/it8518/acpi/ec.asl index 76c0b63..8b89075 100644 --- a/src/ec/roda/it8518/acpi/ec.asl +++ b/src/ec/roda/it8518/acpi/ec.asl @@ -133,7 +133,7 @@ Printf ("-----> EC: _Q43")
Local0 = BRIG - Increment (Local0) + Local0 += 1 If (Local0 > 0xAA) { Local0 = 0xAA } @@ -149,7 +149,7 @@ Printf ("-----> EC: _Q44")
Local0 = BRIG - Decrement (Local0) + Local0 -= 1 If (Local0 < 0xA0) { Local0 = 0xA0