aboutsummaryrefslogtreecommitdiff
path: root/src/ec
diff options
context:
space:
mode:
authorFelix Singer <felixsinger@posteo.net>2022-12-16 02:43:56 +0100
committerFelix Singer <felixsinger@posteo.net>2022-12-23 08:30:09 +0000
commit3c9291b3359d91d7238ed1886f4d87d635a6df55 (patch)
tree55e5b79d71fd2e0b68b841195b5820bfa4f43520 /src/ec
parent034920c1d438ff39f9243a1d6b0d41957405d34c (diff)
tree: Replace ShiftLeft(a,b,c) with ASL 2.0 syntax
Replace `ShiftLeft (a, b, c)` with `c = a << b`. Change-Id: Ibd25a05f49f79e80592482a1b0532334f727af58 Signed-off-by: Felix Singer <felixsinger@posteo.net> Reviewed-on: https://review.coreboot.org/c/coreboot/+/70841 Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/ec')
-rw-r--r--src/ec/lenovo/h8/acpi/thinkpad.asl6
-rw-r--r--src/ec/smsc/mec1308/acpi/battery.asl2
2 files changed, 4 insertions, 4 deletions
diff --git a/src/ec/lenovo/h8/acpi/thinkpad.asl b/src/ec/lenovo/h8/acpi/thinkpad.asl
index e1c979eaae..28431e8f03 100644
--- a/src/ec/lenovo/h8/acpi/thinkpad.asl
+++ b/src/ec/lenovo/h8/acpi/thinkpad.asl
@@ -51,7 +51,7 @@ Device (HKEY)
/* Report event */
Method (RHK, 1, NotSerialized) {
- ShiftLeft (One, Arg0 - 1, Local0)
+ Local0 = One << (Arg0 - 1)
If (EMSK & Local0) {
BTN = Arg0
Notify (HKEY, 0x80)
@@ -60,7 +60,7 @@ Device (HKEY)
/* Report tablet */
Method (RTAB, 1, NotSerialized) {
- ShiftLeft (One, Arg0 - 1, Local0)
+ Local0 = One << (Arg0 - 1)
If (ETAB & Local0) {
BTAB = Arg0
Notify (HKEY, 0x80)
@@ -84,7 +84,7 @@ Device (HKEY)
/* Enable/disable event. */
Method (MHKM, 2, NotSerialized) {
If (Arg0 <= 0x20) {
- ShiftLeft (One, Arg0 - 1, Local0)
+ Local0 = One << (Arg0 - 1)
If (Arg1)
{
Or (DHKN, Local0, DHKN)
diff --git a/src/ec/smsc/mec1308/acpi/battery.asl b/src/ec/smsc/mec1308/acpi/battery.asl
index dbccf0fa21..fad52d2091 100644
--- a/src/ec/smsc/mec1308/acpi/battery.asl
+++ b/src/ec/smsc/mec1308/acpi/battery.asl
@@ -60,7 +60,7 @@ Device (BAT0)
Method (SWAB, 1, NotSerialized)
{
Local0 = Arg0 >> 8
- ShiftLeft (Arg0, 8, Local1)
+ Local1 = Arg0 << 8
And (Local1, 0xFF00, Local1)
Or (Local0, Local1, Local0)
If (Local0 == 0xFFFF) {