summaryrefslogtreecommitdiff
path: root/src/ec
diff options
context:
space:
mode:
authorFelix Singer <felix.singer@secunet.com>2021-07-26 17:00:08 +0200
committerNico Huber <nico.h@gmx.de>2021-07-28 13:48:41 +0000
commit7f4d53a21c737a21dc2563189cb537b036b119dd (patch)
tree9fb3cc85b80133d66603f20c4d346e98a9617cfc /src/ec
parent5b53d3e233cae57a9eeea506d025febf0aac7c10 (diff)
ec/roda/it8518/acpi: Make use of the assignment operator
Replace `Store()` with the assignment operator. Change-Id: I2931a3e1b9a55198ec4dacc9218b6c9028052631 Signed-off-by: Felix Singer <felix.singer@secunet.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/56605 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'src/ec')
-rw-r--r--src/ec/roda/it8518/acpi/battery.asl28
-rw-r--r--src/ec/roda/it8518/acpi/ec.asl22
2 files changed, 25 insertions, 25 deletions
diff --git a/src/ec/roda/it8518/acpi/battery.asl b/src/ec/roda/it8518/acpi/battery.asl
index 2859fcef29..12c07b1f39 100644
--- a/src/ec/roda/it8518/acpi/battery.asl
+++ b/src/ec/roda/it8518/acpi/battery.asl
@@ -44,13 +44,13 @@ Device (BAT0)
{
Printf ("-----> BAT0: _STA")
- Store (0x0F, Local0)
+ Local0 = 0x0F
- Store (ECPS, Local1)
+ Local1 = ECPS
And (Local1, 0x02, Local1)
If (LEqual (Local1, 0x02))
{
- Store (0x1F, Local0)
+ Local0 = 0x1F
}
Printf ("<----- BAT0: _STA")
@@ -62,9 +62,9 @@ Device (BAT0)
{
Printf ("-----> BAT0: _BIF")
- Store (B0FC, PBIF[2])
- Store (Divide (Multiply (B0FC, 6), 100), PBIF[5])
- Store (Divide (Multiply (B0FC, 3), 100), PBIF[6])
+ PBIF[2] = B0FC
+ PBIF[5] = Divide (Multiply (B0FC, 6), 100)
+ PBIF[6] = Divide (Multiply (B0FC, 3), 100)
Printf ("<----- BAT0: _BIF")
@@ -75,33 +75,33 @@ Device (BAT0)
{
Printf ("-----> BAT0: _BST")
- Store (B0ST, Local0)
+ Local0 = B0ST
And (Local0, 0x40, Local0)
If (LEqual (Local0, 0x40))
{
If (LEqual (PWRS, 1))
{
- Store (0x00, PBST[0])
+ PBST[0] = 0x00
}
Else
{
- Store (0x01, PBST[0])
+ PBST[0] = 0x01
}
}
Else
{
- Store (0x02, PBST[0])
+ PBST[0] = 0x02
}
- Store (B0AC, Local1)
+ Local1 = B0AC
If (LGreaterEqual (Local1, 0x8000))
{
Subtract (0x00010000, Local1, Local1)
}
- Store (Local1, PBST[1])
- Store (B0RC, PBST[2])
- Store (B0VT, PBST[3])
+ PBST[1] = Local1
+ PBST[2] = B0RC
+ PBST[3] = B0VT
Printf ("<----- BAT0: _BST")
diff --git a/src/ec/roda/it8518/acpi/ec.asl b/src/ec/roda/it8518/acpi/ec.asl
index 6542bc397f..6c8a738e03 100644
--- a/src/ec/roda/it8518/acpi/ec.asl
+++ b/src/ec/roda/it8518/acpi/ec.asl
@@ -53,7 +53,7 @@ Device (EC0)
{
Printf ("-----> EC: _REG")
- Store (0x01, ECOS)
+ ECOS = 0x01
Printf ("<----- EC: _REG")
}
@@ -62,7 +62,7 @@ Device (EC0)
{
Printf ("-----> EC: _Q29")
- Store (1, PWRS)
+ PWRS = 1
Notify (AC, 0x80)
Notify (AC, 0x00)
Notify (BAT0, 0x00)
@@ -75,7 +75,7 @@ Device (EC0)
{
Printf ("-----> EC: _Q31")
- Store (0, PWRS)
+ PWRS = 0
Notify (AC, 0x80)
Notify (AC, 0x00)
Notify (BAT0, 0x00)
@@ -132,12 +132,12 @@ Device (EC0)
{
Printf ("-----> EC: _Q43")
- Store (BRIG, Local0)
+ Local0 = BRIG
Increment (Local0)
If (LGreater (Local0, 0xAA)) {
- Store (0xAA, Local0)
+ Local0 = 0xAA
}
- Store (Local0, BRIG)
+ BRIG = Local0
\_SB.PCI0.GFX0.INCB ()
@@ -148,13 +148,13 @@ Device (EC0)
{
Printf ("-----> EC: _Q44")
- Store (BRIG, Local0)
+ Local0 = BRIG
Decrement (Local0)
If (LLess (Local0, 0xA0))
{
- Store (0xA0, Local0)
+ Local0 = 0xA0
}
- Store (Local0, BRIG)
+ BRIG = Local0
\_SB.PCI0.GFX0.DECB ()
@@ -165,7 +165,7 @@ Device (EC0)
{
Printf ("-----> EC: _Q45")
- Store (0, LIDS)
+ LIDS = 0
Notify (LID, 0x80)
Printf ("<----- EC: _Q45")
@@ -175,7 +175,7 @@ Device (EC0)
{
Printf ("-----> EC: _Q46")
- Store (1, LIDS)
+ LIDS = 1
Notify (LID, 0x80)
Printf ("<----- EC: _Q46")