From 2db6fbc47b1070a40f5c9b00f6ac9957ca8a4199 Mon Sep 17 00:00:00 2001 From: Lijian Zhao Date: Thu, 8 Feb 2018 12:57:01 -0800 Subject: chromeec: Fix ACPI compile warning For system without secondary battery, current DSDT will report warning during build time. Add a conditional check to make sure only battery index 0 can return success. TEST=Build pass. Change-Id: Iae12c5d1aa749948ef4025c8b5e60c97e1b747a5 Signed-off-by: Lijian Zhao Reviewed-on: https://review.coreboot.org/23661 Reviewed-by: Furquan Shaikh Tested-by: build bot (Jenkins) Reviewed-by: Nicolas Boichat Reviewed-by: Aaron Durbin --- src/ec/google/chromeec/acpi/battery.asl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ec/google/chromeec/acpi/battery.asl b/src/ec/google/chromeec/acpi/battery.asl index 18b612db2a..d8056b03b2 100644 --- a/src/ec/google/chromeec/acpi/battery.asl +++ b/src/ec/google/chromeec/acpi/battery.asl @@ -42,6 +42,10 @@ Method (BTSW, 1) Return (One) } } +#else + If (LNotEqual (0, Arg0)) { + Return (One) + } #endif Return (Zero) } -- cgit v1.2.3