summaryrefslogtreecommitdiff
path: root/src/mainboard/system76/kbl-u/acpi
diff options
context:
space:
mode:
authorFelix Singer <felixsinger@posteo.net>2022-12-26 09:32:47 +0100
committerFelix Singer <felixsinger@posteo.net>2022-12-27 09:05:56 +0000
commitfa06bcba06c5842faae797629e9f72ec28d511c0 (patch)
tree8fba8940a2bf47e403ee5009a623960cf344c975 /src/mainboard/system76/kbl-u/acpi
parent7b8ac0030c611ad84d9ba84b3e90c36233a32c11 (diff)
mainboard/acpi: Replace constant "Zero" with actual number
Change-Id: I4f2f02623b060ef0ebefc5aceb713c77a8b1e9a6 Signed-off-by: Felix Singer <felixsinger@posteo.net> Reviewed-on: https://review.coreboot.org/c/coreboot/+/71523 Reviewed-by: Elyes Haouas <ehaouas@noos.fr> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Diffstat (limited to 'src/mainboard/system76/kbl-u/acpi')
-rw-r--r--src/mainboard/system76/kbl-u/acpi/battery.asl18
-rw-r--r--src/mainboard/system76/kbl-u/acpi/ec.asl14
-rw-r--r--src/mainboard/system76/kbl-u/acpi/ec_ram.asl2
-rw-r--r--src/mainboard/system76/kbl-u/acpi/hid.asl18
-rw-r--r--src/mainboard/system76/kbl-u/acpi/s76.asl4
5 files changed, 28 insertions, 28 deletions
diff --git a/src/mainboard/system76/kbl-u/acpi/battery.asl b/src/mainboard/system76/kbl-u/acpi/battery.asl
index ec1ef31265..48cd4f1828 100644
--- a/src/mainboard/system76/kbl-u/acpi/battery.asl
+++ b/src/mainboard/system76/kbl-u/acpi/battery.asl
@@ -3,12 +3,12 @@
Device (BAT0)
{
Name (_HID, EisaId ("PNP0C0A") /* Control Method Battery */) // _HID: Hardware ID
- Name (_UID, Zero) // _UID: Unique ID
+ Name (_UID, 0) // _UID: Unique ID
Name (_PCL, Package (0x01) // _PCL: Power Consumer List
{
_SB
})
- Name (BFCC, Zero)
+ Name (BFCC, 0)
Method (_STA, 0, NotSerialized) // _STA: Status
{
If (^^PCI0.LPCB.EC0.ECOK)
@@ -35,8 +35,8 @@ Device (BAT0)
0xFFFFFFFF, // 2 - Last Full Charge Capacity
1, // 3 - Battery Technology
0x39D0, // 4 - Design Voltage
- Zero, // 5 - Design Capacity of Warning
- Zero, // 6 - Design Capacity of Low
+ 0, // 5 - Design Capacity of Warning
+ 0, // 6 - Design Capacity of Low
0x40, // 7 - Battery Capacity Granularity 1
0x40, // 8 - Battery Capacity Granularity 2
"BAT", // 9 - Model Number
@@ -53,7 +53,7 @@ Device (BAT0)
PBIF [10] = " "
PBIF [11] = " "
PBIF [12] = " "
- BFCC = Zero
+ BFCC = 0
}
Method (UPBI, 0, NotSerialized)
@@ -98,14 +98,14 @@ Device (BAT0)
Name (PBST, Package (0x04)
{
- Zero, // 0 - Battery state
+ 0, // 0 - Battery state
0xFFFFFFFF, // 1 - Battery present rate
0xFFFFFFFF, // 2 - Battery remaining capacity
0x3D90 // 3 - Battery present voltage
})
Method (IVBS, 0, NotSerialized)
{
- PBST [0] = Zero
+ PBST [0] = 0
PBST [1] = 0xFFFFFFFF
PBST [2] = 0xFFFFFFFF
PBST [3] = 0x2710
@@ -115,8 +115,8 @@ Device (BAT0)
{
If (^^PCI0.LPCB.EC0.BAT0)
{
- Local0 = Zero
- Local1 = Zero
+ Local0 = 0
+ Local1 = 0
If (^^AC.ACFG)
{
If (((^^PCI0.LPCB.EC0.BST0 & 0x02) == 0x02))
diff --git a/src/mainboard/system76/kbl-u/acpi/ec.asl b/src/mainboard/system76/kbl-u/acpi/ec.asl
index ff31c01c9c..6663a2e819 100644
--- a/src/mainboard/system76/kbl-u/acpi/ec.asl
+++ b/src/mainboard/system76/kbl-u/acpi/ec.asl
@@ -22,7 +22,7 @@ Device (EC0)
#include "acpi/ec_ram.asl"
- Name (ECOK, Zero)
+ Name (ECOK, 0)
Method (_REG, 2, Serialized) // _REG: Region Availability
{
Debug = Concatenate("EC: _REG", Concatenate(ToHexString(Arg0), Concatenate(" ", ToHexString(Arg1))))
@@ -40,8 +40,8 @@ Device (EC0)
^^^^BAT0.UPBS()
// Notify of changes
- Notify(^^^^AC, Zero)
- Notify(^^^^BAT0, Zero)
+ Notify(^^^^AC, 0)
+ Notify(^^^^BAT0, 0)
PNOT ()
@@ -53,7 +53,7 @@ Device (EC0)
}
}
- Name (S3OS, Zero)
+ Name (S3OS, 0)
Method (PTS, 1, Serialized) {
Debug = Concatenate("EC: PTS: ", ToHexString(Arg0))
If (ECOK) {
@@ -61,7 +61,7 @@ Device (EC0)
S3OS = ECOS
// Clear wake cause
- WFNO = Zero
+ WFNO = 0
}
}
@@ -79,8 +79,8 @@ Device (EC0)
^^^^BAT0.UPBS()
// Notify of changes
- Notify(^^^^AC, Zero)
- Notify(^^^^BAT0, Zero)
+ Notify(^^^^AC, 0)
+ Notify(^^^^BAT0, 0)
// Reset System76 Device
^^^^S76D.RSET()
diff --git a/src/mainboard/system76/kbl-u/acpi/ec_ram.asl b/src/mainboard/system76/kbl-u/acpi/ec_ram.asl
index 0b6d27e051..2ee90e51ce 100644
--- a/src/mainboard/system76/kbl-u/acpi/ec_ram.asl
+++ b/src/mainboard/system76/kbl-u/acpi/ec_ram.asl
@@ -1,6 +1,6 @@
/* SPDX-License-Identifier: GPL-2.0-only */
-OperationRegion (ERAM, EmbeddedControl, Zero, 0xFF)
+OperationRegion (ERAM, EmbeddedControl, 0, 0xFF)
Field (ERAM, ByteAcc, Lock, Preserve)
{
NMSG, 8,
diff --git a/src/mainboard/system76/kbl-u/acpi/hid.asl b/src/mainboard/system76/kbl-u/acpi/hid.asl
index 8bbb65bc45..eb5f420cce 100644
--- a/src/mainboard/system76/kbl-u/acpi/hid.asl
+++ b/src/mainboard/system76/kbl-u/acpi/hid.asl
@@ -3,19 +3,19 @@
Device (HIDD)
{
Name (_HID, "INT33D5")
- Name (HBSY, Zero)
- Name (HIDX, Zero)
- Name (HRDY, Zero)
+ Name (HBSY, 0)
+ Name (HIDX, 0)
+ Name (HRDY, 0)
Method (HDEM, 0, Serialized)
{
- HBSY = Zero
+ HBSY = 0
Return (HIDX)
}
Method (HDMM, 0, Serialized)
{
- Return (Zero)
+ Return (0)
}
Method (HDSM, 1, Serialized)
@@ -29,7 +29,7 @@ Device (HIDD)
HIDX = Arg0
Notify (HIDD, 0xC0)
- Local0 = Zero
+ Local0 = 0
While ((Local0 < 0xFA) && HBSY)
{
Sleep (0x04)
@@ -38,13 +38,13 @@ Device (HIDD)
If (HBSY == 1)
{
- HBSY = Zero
- HIDX = Zero
+ HBSY = 0
+ HIDX = 0
Return (1)
}
Else
{
- Return (Zero)
+ Return (0)
}
}
}
diff --git a/src/mainboard/system76/kbl-u/acpi/s76.asl b/src/mainboard/system76/kbl-u/acpi/s76.asl
index c4f7837e69..babca3a82a 100644
--- a/src/mainboard/system76/kbl-u/acpi/s76.asl
+++ b/src/mainboard/system76/kbl-u/acpi/s76.asl
@@ -68,7 +68,7 @@ Device (S76D) {
^^PCI0.LPCB.EC0.FDAT = 1
^^PCI0.LPCB.EC0.FCMD = 0xCA
Local0 = ^^PCI0.LPCB.EC0.FBUF
- ^^PCI0.LPCB.EC0.FCMD = Zero
+ ^^PCI0.LPCB.EC0.FCMD = 0
}
Return (Local0)
}
@@ -76,7 +76,7 @@ Device (S76D) {
// Set KB Led
Method (SKBL, 1, Serialized) {
If (^^PCI0.LPCB.EC0.ECOK) {
- ^^PCI0.LPCB.EC0.FDAT = Zero
+ ^^PCI0.LPCB.EC0.FDAT = 0
^^PCI0.LPCB.EC0.FBUF = Arg0
^^PCI0.LPCB.EC0.FCMD = 0xCA
}