diff options
author | Patrick Georgi <patrick@georgi-clan.de> | 2015-08-11 10:54:15 +0200 |
---|---|---|
committer | Patrick Georgi <pgeorgi@google.com> | 2015-08-11 17:54:03 +0200 |
commit | 82fe90829b73241c0d100daec7067c263b8a9093 (patch) | |
tree | 261d69bc541af59531843e107978e0397c029560 /src/mainboard/getac | |
parent | c7ae731430ce9ffa78bb6752f70a4c5706560408 (diff) | |
download | coreboot-82fe90829b73241c0d100daec7067c263b8a9093.tar.xz |
getac/p470: Clean up SIO access in ACPI
This adapts Ia5101d5a1 for the p470.
Change-Id: Ib09a0bc58fddd6240834cc890f00df91a74f4161
Signed-off-by: Patrick Georgi <patrick@georgi-clan.de>
Reviewed-on: http://review.coreboot.org/11160
Tested-by: build bot (Jenkins)
Reviewed-by: Martin Roth <martinroth@google.com>
Diffstat (limited to 'src/mainboard/getac')
-rw-r--r-- | src/mainboard/getac/p470/acpi/superio.asl | 110 |
1 files changed, 45 insertions, 65 deletions
diff --git a/src/mainboard/getac/p470/acpi/superio.asl b/src/mainboard/getac/p470/acpi/superio.asl index cca32cd613..5ffba15e46 100644 --- a/src/mainboard/getac/p470/acpi/superio.asl +++ b/src/mainboard/getac/p470/acpi/superio.asl @@ -127,28 +127,23 @@ Device (SIO1) Return(NONE) } - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR1._CRS._IOA._MIN, IOLO) - CreateByteField(RSRC, 0x03, IOHI) // Why? - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR1._CRS._IOA._MAX, IORL) - CreateByteField(RSRC, 0x05, IORH) // Why? - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR1._CRS._IRA._INT, IRQL) - - Store (READ(0, 0x24, 0xff), Local0) - And (Local0, 0xc0, Local1) - ShiftRight(Local1, 0x06, Local1) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR1._CRS._IOA._MIN, IOMN) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR1._CRS._IOA._MAX, IOMX) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR1._CRS._IRA._INT, IRQ) + + /* I/O Base */ + Store (READ(0, 0x24, 0xfe), Local0) ShiftLeft(Local0, 0x02, Local0) - Store(Local0, IOLO) - Store(Local1, IOHI) - Store(IOLO, IORL) - Store(IOHI, IORH) + Store(Local0, IOMN) + Store(Local0, IOMX) /* Interrupt */ Store(READ(0, 0x28, 0xf0), Local0) ShiftRight(Local0, 4, Local0) - ShiftLeft(1, Local0, IRQL) + ShiftLeft(1, Local0, IRQ) Return(RSRC) } @@ -282,28 +277,23 @@ Device (SIO1) Return(NONE) } - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR2._CRS._IOB._MIN, IOLO) - CreateByteField(RSRC, 0x03, IOHI) - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR2._CRS._IOB._MAX, IORL) - CreateByteField(RSRC, 0x05, IORH) - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR2._CRS._IRB._INT, IRQL) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR2._CRS._IOB._MIN, IOMN) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR2._CRS._IOB._MAX, IOMX) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR2._CRS._IRB._INT, IRQ) - Store (READ(0, 0x25, 0xff), Local0) - And (Local0, 0xc0, Local1) - ShiftRight(Local1, 0x06, Local1) + /* I/O Base */ + Store (READ(0, 0x25, 0xfe), Local0) ShiftLeft(Local0, 0x02, Local0) - Store(Local0, IOLO) - Store(Local1, IOHI) - Store(IOLO, IORL) - Store(IOHI, IORH) + Store(Local0, IOMN) + Store(Local0, IOMX) /* Interrupt */ Store(READ(0, 0x28, 0x0f), Local0) ShiftRight(Local0, 4, Local0) - ShiftLeft(1, Local0, IRQL) + ShiftLeft(1, Local0, IRQ) Return(RSRC) } @@ -436,28 +426,23 @@ Device (SIO1) Return(NONE) } - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR3._CRS._IOA._MIN, IOLO) - CreateByteField(RSRC, 0x03, IOHI) // Why? - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR3._CRS._IOA._MAX, IORL) - CreateByteField(RSRC, 0x05, IORH) // Why? - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR3._CRS._IRA._INT, IRQL) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR3._CRS._IOA._MIN, IOMN) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR3._CRS._IOA._MAX, IOMX) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR3._CRS._IRA._INT, IRQ) - Store (READ(0, 0x1b, 0xff), Local0) - And (Local0, 0xc0, Local1) - ShiftRight(Local1, 0x06, Local1) + /* I/O Base */ + Store (READ(0, 0x1b, 0xfe), Local0) ShiftLeft(Local0, 0x02, Local0) - Store(Local0, IOLO) - Store(Local1, IOHI) - Store(IOLO, IORL) - Store(IOHI, IORH) + Store(Local0, IOMN) + Store(Local0, IOMX) /* Interrupt */ Store(READ(0, 0x1d, 0xf0), Local0) ShiftRight(Local0, 4, Local0) - ShiftLeft(1, Local0, IRQL) + ShiftLeft(1, Local0, IRQ) Return(RSRC) } @@ -588,28 +573,23 @@ Device (SIO1) Return(NONE) } - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR4._CRS._IOA._MIN, IOLO) - CreateByteField(RSRC, 0x03, IOHI) // Why? - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR4._CRS._IOA._MAX, IORL) - CreateByteField(RSRC, 0x05, IORH) // Why? - CreateByteField(RSRC, - \_SB.PCI0.LPCB.SIO1.UAR4._CRS._IRA._INT, IRQL) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR4._CRS._IOA._MIN, IOMN) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR4._CRS._IOA._MAX, IOMX) + CreateWordField(RSRC, + \_SB.PCI0.LPCB.SIO1.UAR4._CRS._IRA._INT, IRQ) - Store (READ(0, 0x1c, 0xff), Local0) - And (Local0, 0xc0, Local1) - ShiftRight(Local1, 0x06, Local1) + /* I/O Base */ + Store (READ(0, 0x1c, 0xfe), Local0) ShiftLeft(Local0, 0x02, Local0) - Store(Local0, IOLO) - Store(Local1, IOHI) - Store(IOLO, IORL) - Store(IOHI, IORH) + Store(Local0, IOMN) + Store(Local0, IOMX) /* Interrupt */ Store(READ(0, 0x1d, 0xf0), Local0) ShiftRight(Local0, 4, Local0) - ShiftLeft(1, Local0, IRQL) + ShiftLeft(1, Local0, IRQ) Return(RSRC) } |