summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Roth <martinroth@google.com>2018-05-06 18:13:19 -0500
committerMartin Roth <martinroth@google.com>2018-06-03 14:19:58 +0000
commita50b1f9dd0e6caa3f33ddac4e54c44f881876ede (patch)
tree1a7ba52f879da012b3d631faea799bc74aca55ac
parente36a00af719347f1f26d37d4b13fe2d416cdfef1 (diff)
downloadcoreboot-a50b1f9dd0e6caa3f33ddac4e54c44f881876ede.tar.xz
intel bd82x6x/lynxpoint systems: Update ACPI thermal zone handler
Currently the throttle event handler method THRM is defined as an extern on the intel bd82x6x and lynxpoint chipsets, then defined again in the platform with thermal event handling. In newer versions of IASL, this generates an error, as the method is defined in two places. Simply removing the extern causes the call to it to fail on platforms where it isn't actually defined, so add a preprocessor define where it's implemented, and only call the method on those platforms. This also requires moving the thermal handler, which now includes the define to before the gnvs asl file. TEST=Build before and after, make sure correct code is included. Change-Id: I7af4a346496c1352ec20bda8acb338b5d277d99b Signed-off-by: Martin Roth <martinroth@google.com> Reviewed-on: https://review.coreboot.org/26123 Reviewed-by: Nico Huber <nico.h@gmx.de> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r--src/mainboard/google/auron/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/auron/dsdt.asl6
-rw-r--r--src/mainboard/google/beltino/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/beltino/dsdt.asl6
-rw-r--r--src/mainboard/google/butterfly/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/butterfly/dsdt.asl5
-rw-r--r--src/mainboard/google/jecht/dsdt.asl6
-rw-r--r--src/mainboard/google/jecht/variants/guado/include/variant/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/jecht/variants/jecht/include/variant/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/jecht/variants/rikku/include/variant/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/jecht/variants/tidus/include/variant/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/link/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/link/dsdt.asl4
-rw-r--r--src/mainboard/google/parrot/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/parrot/dsdt.asl5
-rw-r--r--src/mainboard/google/slippy/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/slippy/dsdt.asl6
-rw-r--r--src/mainboard/google/stout/acpi/thermal.asl1
-rw-r--r--src/mainboard/google/stout/dsdt.asl5
-rw-r--r--src/mainboard/intel/emeraldlake2/acpi/thermal.asl1
-rw-r--r--src/mainboard/intel/emeraldlake2/dsdt.asl5
-rw-r--r--src/mainboard/kontron/ktqm77/acpi/thermal.asl1
-rw-r--r--src/mainboard/kontron/ktqm77/dsdt.asl5
-rw-r--r--src/mainboard/roda/rv11/acpi/thermal.asl1
-rw-r--r--src/mainboard/roda/rv11/dsdt.asl5
-rw-r--r--src/mainboard/samsung/lumpy/acpi/thermal.asl1
-rw-r--r--src/mainboard/samsung/lumpy/dsdt.asl5
-rw-r--r--src/southbridge/intel/bd82x6x/acpi/globalnvs.asl3
-rw-r--r--src/southbridge/intel/lynxpoint/acpi/globalnvs.asl3
29 files changed, 55 insertions, 29 deletions
diff --git a/src/mainboard/google/auron/acpi/thermal.asl b/src/mainboard/google/auron/acpi/thermal.asl
index 8fc6217fa3..16d1d45f92 100644
--- a/src/mainboard/google/auron/acpi/thermal.asl
+++ b/src/mainboard/google/auron/acpi/thermal.asl
@@ -17,6 +17,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/auron/dsdt.asl b/src/mainboard/google/auron/dsdt.asl
index 531d6a7247..445d927d5f 100644
--- a/src/mainboard/google/auron/dsdt.asl
+++ b/src/mainboard/google/auron/dsdt.asl
@@ -26,6 +26,9 @@ DefinitionBlock(
// Some generic macros
#include <soc/intel/broadwell/acpi/platform.asl>
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <soc/intel/broadwell/acpi/globalnvs.asl>
@@ -43,9 +46,6 @@ DefinitionBlock(
}
}
- // Thermal handler
- #include "acpi/thermal.asl"
-
// Chrome OS specific
#include <vendorcode/google/chromeos/acpi/chromeos.asl>
diff --git a/src/mainboard/google/beltino/acpi/thermal.asl b/src/mainboard/google/beltino/acpi/thermal.asl
index af36a5c985..1d4eca3a09 100644
--- a/src/mainboard/google/beltino/acpi/thermal.asl
+++ b/src/mainboard/google/beltino/acpi/thermal.asl
@@ -17,6 +17,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/beltino/dsdt.asl b/src/mainboard/google/beltino/dsdt.asl
index 6393d688fb..268cd9dc9e 100644
--- a/src/mainboard/google/beltino/dsdt.asl
+++ b/src/mainboard/google/beltino/dsdt.asl
@@ -26,6 +26,9 @@ DefinitionBlock(
// Some generic macros
#include "acpi/platform.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/lynxpoint/acpi/globalnvs.asl>
@@ -45,9 +48,6 @@ DefinitionBlock(
// Mainboard devices
#include "acpi/mainboard.asl"
- // Thermal handler
- #include "acpi/thermal.asl"
-
// Chrome OS specific
#include <vendorcode/google/chromeos/acpi/chromeos.asl>
diff --git a/src/mainboard/google/butterfly/acpi/thermal.asl b/src/mainboard/google/butterfly/acpi/thermal.asl
index f6158bac0f..2faa7de636 100644
--- a/src/mainboard/google/butterfly/acpi/thermal.asl
+++ b/src/mainboard/google/butterfly/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/butterfly/dsdt.asl b/src/mainboard/google/butterfly/dsdt.asl
index c1ea0e6717..b4fd6cff2d 100644
--- a/src/mainboard/google/butterfly/dsdt.asl
+++ b/src/mainboard/google/butterfly/dsdt.asl
@@ -29,14 +29,15 @@ DefinitionBlock(
#include "acpi/platform.asl"
#include "acpi/mainboard.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
// General Purpose Events
//#include "acpi/gpe.asl"
- #include "acpi/thermal.asl"
-
#include <cpu/intel/model_206ax/acpi/cpu.asl>
Scope (\_SB) {
diff --git a/src/mainboard/google/jecht/dsdt.asl b/src/mainboard/google/jecht/dsdt.asl
index 1ac32887d1..8157a84d36 100644
--- a/src/mainboard/google/jecht/dsdt.asl
+++ b/src/mainboard/google/jecht/dsdt.asl
@@ -26,6 +26,9 @@ DefinitionBlock(
// Some generic macros
#include "acpi/platform.asl"
+ // Thermal handler
+ #include <variant/acpi/thermal.asl>
+
// global NVS and variables
#include <soc/intel/broadwell/acpi/globalnvs.asl>
@@ -43,9 +46,6 @@ DefinitionBlock(
}
}
- // Thermal handler
- #include <variant/acpi/thermal.asl>
-
// Chrome OS specific
#include <vendorcode/google/chromeos/acpi/chromeos.asl>
diff --git a/src/mainboard/google/jecht/variants/guado/include/variant/acpi/thermal.asl b/src/mainboard/google/jecht/variants/guado/include/variant/acpi/thermal.asl
index 1cd1b9b713..d09b4915fb 100644
--- a/src/mainboard/google/jecht/variants/guado/include/variant/acpi/thermal.asl
+++ b/src/mainboard/google/jecht/variants/guado/include/variant/acpi/thermal.asl
@@ -17,6 +17,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/jecht/variants/jecht/include/variant/acpi/thermal.asl b/src/mainboard/google/jecht/variants/jecht/include/variant/acpi/thermal.asl
index 1cd1b9b713..d09b4915fb 100644
--- a/src/mainboard/google/jecht/variants/jecht/include/variant/acpi/thermal.asl
+++ b/src/mainboard/google/jecht/variants/jecht/include/variant/acpi/thermal.asl
@@ -17,6 +17,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/jecht/variants/rikku/include/variant/acpi/thermal.asl b/src/mainboard/google/jecht/variants/rikku/include/variant/acpi/thermal.asl
index 151ac51289..7bf7155dca 100644
--- a/src/mainboard/google/jecht/variants/rikku/include/variant/acpi/thermal.asl
+++ b/src/mainboard/google/jecht/variants/rikku/include/variant/acpi/thermal.asl
@@ -17,6 +17,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/jecht/variants/tidus/include/variant/acpi/thermal.asl b/src/mainboard/google/jecht/variants/tidus/include/variant/acpi/thermal.asl
index 78e7bf75c7..177d75e1c7 100644
--- a/src/mainboard/google/jecht/variants/tidus/include/variant/acpi/thermal.asl
+++ b/src/mainboard/google/jecht/variants/tidus/include/variant/acpi/thermal.asl
@@ -17,6 +17,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/link/acpi/thermal.asl b/src/mainboard/google/link/acpi/thermal.asl
index 9163493673..e0d25e711d 100644
--- a/src/mainboard/google/link/acpi/thermal.asl
+++ b/src/mainboard/google/link/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (CRIT)
diff --git a/src/mainboard/google/link/dsdt.asl b/src/mainboard/google/link/dsdt.asl
index 82fb3f62df..5af07938c5 100644
--- a/src/mainboard/google/link/dsdt.asl
+++ b/src/mainboard/google/link/dsdt.asl
@@ -29,13 +29,15 @@ DefinitionBlock(
#include "acpi/platform.asl"
#include "acpi/mainboard.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
// General Purpose Events
//#include "acpi/gpe.asl"
- #include "acpi/thermal.asl"
#include <cpu/intel/model_206ax/acpi/cpu.asl>
diff --git a/src/mainboard/google/parrot/acpi/thermal.asl b/src/mainboard/google/parrot/acpi/thermal.asl
index 98aa52da7c..38fe15f77d 100644
--- a/src/mainboard/google/parrot/acpi/thermal.asl
+++ b/src/mainboard/google/parrot/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/parrot/dsdt.asl b/src/mainboard/google/parrot/dsdt.asl
index 4f2f9866e1..ebc86cacfc 100644
--- a/src/mainboard/google/parrot/dsdt.asl
+++ b/src/mainboard/google/parrot/dsdt.asl
@@ -28,14 +28,15 @@ DefinitionBlock(
// Some generic macros
#include "acpi/platform.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
// General Purpose Events
//#include "acpi/gpe.asl"
- #include "acpi/thermal.asl"
-
#include <cpu/intel/model_206ax/acpi/cpu.asl>
Scope (\_SB) {
diff --git a/src/mainboard/google/slippy/acpi/thermal.asl b/src/mainboard/google/slippy/acpi/thermal.asl
index 36b0e21604..0c694c0f70 100644
--- a/src/mainboard/google/slippy/acpi/thermal.asl
+++ b/src/mainboard/google/slippy/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
// Handler for throttle requests on this platform
diff --git a/src/mainboard/google/slippy/dsdt.asl b/src/mainboard/google/slippy/dsdt.asl
index 7d41f9adb3..076039d888 100644
--- a/src/mainboard/google/slippy/dsdt.asl
+++ b/src/mainboard/google/slippy/dsdt.asl
@@ -26,6 +26,9 @@ DefinitionBlock(
// Some generic macros
#include "acpi/platform.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/lynxpoint/acpi/globalnvs.asl>
@@ -56,9 +59,6 @@ DefinitionBlock(
// Mainboard specific
#include "acpi/mainboard.asl"
- // Thermal handler
- #include "acpi/thermal.asl"
-
// Chrome OS specific
#include <vendorcode/google/chromeos/acpi/chromeos.asl>
diff --git a/src/mainboard/google/stout/acpi/thermal.asl b/src/mainboard/google/stout/acpi/thermal.asl
index 01f6229627..335f018ecd 100644
--- a/src/mainboard/google/stout/acpi/thermal.asl
+++ b/src/mainboard/google/stout/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/google/stout/dsdt.asl b/src/mainboard/google/stout/dsdt.asl
index b12c963e54..60ea646cb6 100644
--- a/src/mainboard/google/stout/dsdt.asl
+++ b/src/mainboard/google/stout/dsdt.asl
@@ -29,14 +29,15 @@ DefinitionBlock(
#include "acpi/platform.asl"
#include "acpi/mainboard.asl"
+ // Thermal handeler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
// General Purpose Events
//#include "acpi/gpe.asl"
- #include "acpi/thermal.asl"
-
#include <cpu/intel/model_206ax/acpi/cpu.asl>
Scope (\_SB) {
diff --git a/src/mainboard/intel/emeraldlake2/acpi/thermal.asl b/src/mainboard/intel/emeraldlake2/acpi/thermal.asl
index 448cb97392..b3d3824eb6 100644
--- a/src/mainboard/intel/emeraldlake2/acpi/thermal.asl
+++ b/src/mainboard/intel/emeraldlake2/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/intel/emeraldlake2/dsdt.asl b/src/mainboard/intel/emeraldlake2/dsdt.asl
index 4adc4571b4..fc6fd1efc6 100644
--- a/src/mainboard/intel/emeraldlake2/dsdt.asl
+++ b/src/mainboard/intel/emeraldlake2/dsdt.asl
@@ -28,14 +28,15 @@ DefinitionBlock(
// Some generic macros
#include "acpi/platform.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
// General Purpose Events
//#include "acpi/gpe.asl"
- #include "acpi/thermal.asl"
-
#include "../../../cpu/intel/model_206ax/acpi/cpu.asl"
Scope (\_SB) {
diff --git a/src/mainboard/kontron/ktqm77/acpi/thermal.asl b/src/mainboard/kontron/ktqm77/acpi/thermal.asl
index 0bdef147f5..9c1407ea90 100644
--- a/src/mainboard/kontron/ktqm77/acpi/thermal.asl
+++ b/src/mainboard/kontron/ktqm77/acpi/thermal.asl
@@ -16,6 +16,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/kontron/ktqm77/dsdt.asl b/src/mainboard/kontron/ktqm77/dsdt.asl
index 1b26ed0a2a..0432f778d4 100644
--- a/src/mainboard/kontron/ktqm77/dsdt.asl
+++ b/src/mainboard/kontron/ktqm77/dsdt.asl
@@ -29,14 +29,15 @@ DefinitionBlock(
#include "acpi/platform.asl"
#include "acpi/mainboard.asl"
+ // Thermal Handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
// General Purpose Events
//#include "acpi/gpe.asl"
- #include "acpi/thermal.asl"
-
#include <cpu/intel/model_206ax/acpi/cpu.asl>
Scope (\_SB) {
diff --git a/src/mainboard/roda/rv11/acpi/thermal.asl b/src/mainboard/roda/rv11/acpi/thermal.asl
index b87fc4f63d..a1d28e4c53 100644
--- a/src/mainboard/roda/rv11/acpi/thermal.asl
+++ b/src/mainboard/roda/rv11/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
// Convert from Degrees C to 1/10 Kelvin for ACPI
diff --git a/src/mainboard/roda/rv11/dsdt.asl b/src/mainboard/roda/rv11/dsdt.asl
index 4934eed542..ff837959f2 100644
--- a/src/mainboard/roda/rv11/dsdt.asl
+++ b/src/mainboard/roda/rv11/dsdt.asl
@@ -28,11 +28,12 @@ DefinitionBlock(
#include "acpi/platform.asl"
#include "acpi/mainboard.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
- #include "acpi/thermal.asl"
-
#include "acpi/alsd.asl"
#include <cpu/intel/model_206ax/acpi/cpu.asl>
diff --git a/src/mainboard/samsung/lumpy/acpi/thermal.asl b/src/mainboard/samsung/lumpy/acpi/thermal.asl
index c61a3b613a..10a74f3bb0 100644
--- a/src/mainboard/samsung/lumpy/acpi/thermal.asl
+++ b/src/mainboard/samsung/lumpy/acpi/thermal.asl
@@ -15,6 +15,7 @@
// Thermal Zone
+#define HAVE_THERMALZONE
Scope (\_TZ)
{
ThermalZone (THRM)
diff --git a/src/mainboard/samsung/lumpy/dsdt.asl b/src/mainboard/samsung/lumpy/dsdt.asl
index f42bec66b4..3ca8bf2cc1 100644
--- a/src/mainboard/samsung/lumpy/dsdt.asl
+++ b/src/mainboard/samsung/lumpy/dsdt.asl
@@ -28,6 +28,9 @@ DefinitionBlock(
// Some generic macros
#include "acpi/platform.asl"
+ // Thermal handler
+ #include "acpi/thermal.asl"
+
// global NVS and variables
#include <southbridge/intel/bd82x6x/acpi/globalnvs.asl>
@@ -36,8 +39,6 @@ DefinitionBlock(
#include <cpu/intel/model_206ax/acpi/cpu.asl>
- #include "acpi/thermal.asl"
-
Scope (\_SB) {
Device (PCI0)
{
diff --git a/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl b/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl
index 2a3227d3da..f7652ee5a5 100644
--- a/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl
+++ b/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl
@@ -233,15 +233,16 @@ Method (XHCD)
{
Store (Zero, \XHCI)
}
-External (\_TZ.THRM)
External (\_TZ.SKIN)
Method (TZUP)
{
+#ifdef HAVE_THERMALZONE
/* Update Primary Thermal Zone */
If (CondRefOf (\_TZ.THRM)) {
Notify (\_TZ.THRM, 0x81)
}
+#endif
/* Update Secondary Thermal Zone */
If (CondRefOf (\_TZ.SKIN)) {
diff --git a/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl b/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl
index 468c755b16..ba9f850208 100644
--- a/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl
+++ b/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl
@@ -216,15 +216,16 @@ Method (S3GD)
Store (Zero, \S33G)
}
-External (\_TZ.THRM)
External (\_TZ.SKIN)
Method (TZUP)
{
+#ifdef HAVE_THERMALZONE
/* Update Primary Thermal Zone */
If (CondRefOf (\_TZ.THRM)) {
Notify (\_TZ.THRM, 0x81)
}
+#endif
/* Update Secondary Thermal Zone */
If (CondRefOf (\_TZ.SKIN)) {