summaryrefslogtreecommitdiff
path: root/src/southbridge/intel/lynxpoint/acpi
diff options
context:
space:
mode:
authorDuncan Laurie <dlaurie@chromium.org>2013-05-15 15:03:57 -0700
committerStefan Reinauer <stefan.reinauer@coreboot.org>2013-11-25 23:28:27 +0100
commitd7cb8d074f4a9e437ed897ac596ca794698b38c9 (patch)
tree6e940fa98877925ab3f0d52427a3527789ceb753 /src/southbridge/intel/lynxpoint/acpi
parent8d783b84930e2e14e4f70234ea6589acd06557e7 (diff)
downloadcoreboot-d7cb8d074f4a9e437ed897ac596ca794698b38c9.tar.xz
lynxpoint: Change SerialIO device enable reporting to ACPI
In order to report whether coreboot enabled a SerialIO device in ACPI mode we had been relying on reading NVS in the _STA method for the SerialIO device. The ACPI _STA method has restrictions on what it can access and is unable to access OperationRegions outside its scope which means it should not be trying to read NVS. This change adds a new SSDT to the ACPI tables and fills it with constants that indicate whether or not a device is enabled in ACPI mode. The ACPI code is changed to read these variables from the SSDT and use that instead of trying to query a variable in NVS. Attempt to use lpt-clk driver to probe the device clocks for SerialIO devices and see that the kernel does not complain about accessing the GNVS region. Change-Id: I8538bee4390daed4ecca679496ab0cb313f174ce Signed-off-by: Duncan Laurie <dlaurie@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/51369 Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: http://review.coreboot.org/4170 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich <rminnich@gmail.com>
Diffstat (limited to 'src/southbridge/intel/lynxpoint/acpi')
-rw-r--r--src/southbridge/intel/lynxpoint/acpi/serialio.asl27
1 files changed, 19 insertions, 8 deletions
diff --git a/src/southbridge/intel/lynxpoint/acpi/serialio.asl b/src/southbridge/intel/lynxpoint/acpi/serialio.asl
index 03f6974a38..4c0d36bcc6 100644
--- a/src/southbridge/intel/lynxpoint/acpi/serialio.asl
+++ b/src/southbridge/intel/lynxpoint/acpi/serialio.asl
@@ -24,6 +24,17 @@
// Serial IO Device BAR0 and BAR1 is 4KB
#define SIO_BAR_LEN 0x1000
+// This is defined in SSDT2 which is generated at boot based
+// on whether or not the device is enabled in ACPI mode.
+External(\S0EN)
+External(\S1EN)
+External(\S2EN)
+External(\S3EN)
+External(\S4EN)
+External(\S5EN)
+External(\S6EN)
+External(\S7EN)
+
// Serial IO Resource Consumption for BAR1
Device (SIOR)
{
@@ -143,7 +154,7 @@ Device (SDMA)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S0B0, 0)) {
+ If (LEqual (\S0EN, 0)) {
Return (0x0)
} Else {
Return (0xF)
@@ -194,7 +205,7 @@ Device (I2C0)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S1B0, 0)) {
+ If (LEqual (\S1EN, 0)) {
Return (0x0)
} Else {
Return (0xF)
@@ -245,7 +256,7 @@ Device (I2C1)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S2B0, 0)) {
+ If (LEqual (\S2EN, 0)) {
Return (0x0)
} Else {
Return (0xF)
@@ -283,7 +294,7 @@ Device (SPI0)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S3B0, 0)) {
+ If (LEqual (\S3EN, 0)) {
Return (0x0)
} Else {
Return (0xF)
@@ -334,7 +345,7 @@ Device (SPI1)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S4B0, 0)) {
+ If (LEqual (\S4EN, 0)) {
Return (0x0)
} Else {
Return (0xF)
@@ -385,7 +396,7 @@ Device (UAR0)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S5B0, 0)) {
+ If (LEqual (\S5EN, 0)) {
Return (0x0)
} Else {
Return (0xF)
@@ -423,7 +434,7 @@ Device (UAR1)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S6B0, 0)) {
+ If (LEqual (\S6EN, 0)) {
Return (0x0)
} Else {
Return (0xF)
@@ -461,7 +472,7 @@ Device (SDIO)
Method (_STA, 0, NotSerialized)
{
- If (LEqual (\S7B0, 0)) {
+ If (LEqual (\S7EN, 0)) {
Return (0x0)
} Else {
Return (0xF)