summaryrefslogtreecommitdiffstats
path: root/src/ec/google
diff options
context:
space:
mode:
authorFrans Hendriks <fhendriks@eltan.com>2019-12-06 11:54:01 +0100
committerPatrick Georgi <pgeorgi@google.com>2019-12-17 13:10:27 +0000
commit9cb88a70f7a636806752542216e177ba625e77d2 (patch)
tree644be51cf2404c8fcf071e153b7a5dda4bf7698f /src/ec/google
parent50a445489225b94339adc15fe8d1b6c3fa57b095 (diff)
downloadcoreboot-9cb88a70f7a636806752542216e177ba625e77d2.tar.gz
coreboot-9cb88a70f7a636806752542216e177ba625e77d2.tar.bz2
coreboot-9cb88a70f7a636806752542216e177ba625e77d2.zip
src: Conditionally include TEVT
ACPI method TEVT is reported as unused by iASL (20190509) when ChromeEC support is not enabled. The message is “Method Argument is never used (Arg0)” on Method (TEVT, 1, NotSerialized), which indicates the TEVT method is empty. The solution is to only enable the TEVT code in mainboard or SoC when an EC is used that uses this event. The TEVT code in the EC is only enabled if the mainboard or SoC code implements TEVT. The TEVT method will be removed from the ASL code when the EC does not support TEVT. BUG=N/A TEST=Tested on facebook monolith. Change-Id: I8d2e14407ae2338e58797cdc7eb7d0cadf3cc26e Signed-off-by: Wim Vervoorn <wvervoorn@eltan.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/37560 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Frans Hendriks <fhendriks@eltan.com>
Diffstat (limited to 'src/ec/google')
-rw-r--r--src/ec/google/chromeec/Kconfig1
-rw-r--r--src/ec/google/wilco/Kconfig1
-rw-r--r--src/ec/google/wilco/acpi/dptf.asl2
3 files changed, 4 insertions, 0 deletions
diff --git a/src/ec/google/chromeec/Kconfig b/src/ec/google/chromeec/Kconfig
index 2eb3b95c7d9c..b33864f09e91 100644
--- a/src/ec/google/chromeec/Kconfig
+++ b/src/ec/google/chromeec/Kconfig
@@ -1,5 +1,6 @@
config EC_GOOGLE_CHROMEEC
bool
+ select EC_SUPPORTS_DPTF_TEVT
help
Google's Chrome EC
diff --git a/src/ec/google/wilco/Kconfig b/src/ec/google/wilco/Kconfig
index 25d7cfafc23c..ee7b55655179 100644
--- a/src/ec/google/wilco/Kconfig
+++ b/src/ec/google/wilco/Kconfig
@@ -3,6 +3,7 @@ config EC_GOOGLE_WILCO
default n
select EC_GOOGLE_COMMON_MEC
select EC_ACPI
+ select EC_SUPPORTS_DPTF_TEVT
help
Google Wilco Embedded Controller interface.
diff --git a/src/ec/google/wilco/acpi/dptf.asl b/src/ec/google/wilco/acpi/dptf.asl
index 0f1663f714d2..42fc9fdeed88 100644
--- a/src/ec/google/wilco/acpi/dptf.asl
+++ b/src/ec/google/wilco/acpi/dptf.asl
@@ -115,8 +115,10 @@ Method (PATX, 0, Serialized)
/* Handle bits that are set */
While (FindSetRightBit (Local1, Local2))
{
+#ifdef HAVE_THERM_EVENT_HANDLER
/* DPTF will Notify sensor devices */
\_SB.DPTF.TEVT (Local2)
+#endif
/* Clear current sensor number */
Local1 &= ~(1 << (Local2 - 1))