[PATCH 2/2] acpi/ec: check _GPE is not used for hardware-reduced

Alex Hung alex.hung at canonical.com
Wed Sep 30 01:52:25 UTC 2020


ACPI spec states "This method is not required on Hardware-reduced ACPI
platforms". In addition, Linux also ignores _GPE for hardware-reduced.
See kernel's drivers/acpi/ec.c for details.

Signed-off-by: Alex Hung <alex.hung at canonical.com>
---
 src/acpi/devices/ec/ec.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/src/acpi/devices/ec/ec.c b/src/acpi/devices/ec/ec.c
index 856b091f..59d099eb 100644
--- a/src/acpi/devices/ec/ec.c
+++ b/src/acpi/devices/ec/ec.c
@@ -93,6 +93,14 @@ static void method_test_GPE_return(
 	FWTS_UNUSED(buf);
 	bool failed = false;
 
+	if (fwts_acpi_is_reduced_hardware(fw)) {
+		fwts_failed(fw, LOG_LEVEL_HIGH,
+			"MethodGPEExist",
+			"%s is not required for Hardware-reduced ACPI platforms",
+			name);
+		return;
+	}
+
 	switch (obj->Type) {
 	case ACPI_TYPE_INTEGER:
 		if (obj->Integer.Value <= 255)
-- 
2.25.1




More information about the fwts-devel mailing list