arch/x86/acpi: Replace Store() with ASL 2.0 syntax
Change-Id: I30bbd0288475fbefec55ce294e7963df1de6aa6a Signed-off-by: Felix Singer <felixsinger@posteo.net> Reviewed-on: https://review.coreboot.org/c/coreboot/+/60720 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Sean Rhodes <sean@starlabs.systems> Reviewed-by: Sridhar Siricilla <sridhar.siricilla@intel.com>
This commit is contained in:
parent
311981ef48
commit
a44620dea9
|
@ -27,12 +27,12 @@ OperationRegion(CREG, SystemIO, 0x3F8, 8)
|
|||
*/
|
||||
Method(DINI)
|
||||
{
|
||||
store(0x83, DLCR)
|
||||
store(0x01, CDAT) /* 115200 baud (low) */
|
||||
store(0x00, CDLM) /* 115200 baud (high) */
|
||||
store(0x03, DLCR) /* word=8 stop=1 parity=none */
|
||||
store(0x03, CMCR) /* DTR=1 RTS=1 Out2=Off Loop=Off */
|
||||
store(0x00, CDLM) /* turn off interrupts */
|
||||
DLCR = 0x83
|
||||
CDAT = 1 /* 115200 baud (low) */
|
||||
CDLM = 0 /* 115200 baud (high) */
|
||||
DLCR = 3 /* word=8 stop=1 parity=none */
|
||||
CMCR = 3 /* DTR=1 RTS=1 Out2=Off Loop=Off */
|
||||
CDLM = 0 /* turn off interrupts */
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -54,7 +54,7 @@ Method(THRE)
|
|||
Method(OUTX, 1)
|
||||
{
|
||||
THRE()
|
||||
store(Arg0, CDAT)
|
||||
CDAT = Arg0
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -136,10 +136,10 @@ Method(DBGO, 1)
|
|||
}
|
||||
} else {
|
||||
Name(BDBG, Buffer(80) {})
|
||||
store(Arg0, BDBG)
|
||||
store(0, Local1)
|
||||
BDBG = Arg0
|
||||
Local1 = 0
|
||||
while (One) {
|
||||
store(GETC(BDBG, Local1), Local0)
|
||||
Local0 = GETC(BDBG, Local1)
|
||||
if (Local0 == 0) {
|
||||
return (0)
|
||||
}
|
||||
|
|
|
@ -18,7 +18,7 @@ Method(MIN, 2)
|
|||
|
||||
Method(SLEN, 1)
|
||||
{
|
||||
Store(Arg0, Local0)
|
||||
Local0 = Arg0
|
||||
Return(Sizeof(Local0))
|
||||
}
|
||||
|
||||
|
@ -26,23 +26,23 @@ Method(S2BF, 1, Serialized)
|
|||
{
|
||||
Local0 = SLEN(Arg0) + 1
|
||||
Name(BUFF, Buffer(Local0) {})
|
||||
Store(Arg0, BUFF)
|
||||
BUFF = Arg0
|
||||
Return(BUFF)
|
||||
}
|
||||
|
||||
/* Strong string compare. Checks both length and content */
|
||||
Method(SCMP, 2)
|
||||
{
|
||||
Store(S2BF(Arg0), Local0)
|
||||
Store(S2BF(Arg1), Local1)
|
||||
Store(Zero, Local4)
|
||||
Store(SLEN(Arg0), Local5)
|
||||
Store(SLEN(Arg1), Local6)
|
||||
Store(MIN(Local5, Local6), Local7)
|
||||
Local0 = S2BF(Arg0)
|
||||
Local1 = S2BF(Arg1)
|
||||
Local4 = 0
|
||||
Local5 = SLEN(Arg0)
|
||||
Local6 = SLEN(Arg1)
|
||||
Local7 = MIN(Local5, Local6)
|
||||
|
||||
While(Local4 < Local7) {
|
||||
Store(Derefof(Local0[Local4]), Local2)
|
||||
Store(Derefof(Local1[Local4]), Local3)
|
||||
Local2 = Derefof(Local0[Local4])
|
||||
Local3 = Derefof(Local1[Local4])
|
||||
if (Local2 > Local3) {
|
||||
Return(One)
|
||||
} else {
|
||||
|
@ -69,13 +69,13 @@ Method(SCMP, 2)
|
|||
*/
|
||||
Method(WCMP, 2)
|
||||
{
|
||||
Store(S2BF(Arg0), Local0)
|
||||
Store(S2BF(Arg1), Local1)
|
||||
Local0 = S2BF(Arg0)
|
||||
Local1 = S2BF(Arg1)
|
||||
if (SLEN(Arg0) < SLEN(Arg1)) {
|
||||
Return(0)
|
||||
}
|
||||
Store(Zero, Local2)
|
||||
Store(SLEN(Arg1), Local3)
|
||||
Local2 = 0
|
||||
Local3 = SLEN(Arg1)
|
||||
|
||||
While(Local2 < Local3) {
|
||||
if (Derefof(Local0[Local2]) != Derefof(Local1[Local2])) {
|
||||
|
@ -91,9 +91,9 @@ Method(WCMP, 2)
|
|||
*/
|
||||
Method(I2BM, 1)
|
||||
{
|
||||
Store(0, Local0)
|
||||
Local0 = 0
|
||||
if (ARG0 != 0) {
|
||||
Store(1, Local1)
|
||||
Local1 = 1
|
||||
Local0 = Local1 << ARG0
|
||||
}
|
||||
Return(Local0)
|
||||
|
|
Loading…
Reference in New Issue