From 1f64e6aa85b0560b0cbc8b7f08970efa56d27d3a Mon Sep 17 00:00:00 2001 From: Tristan Shieh Date: Thu, 13 Sep 2018 19:28:15 +0800 Subject: google/kukui: Set up EC_IN_RW GPIO for ChromeOS Set up EC_IN_RW GPIO to boot depthcharge. Without this patch, depthcharge will fail to tell if the EC firmware is RW. BUG=b:80501386 BRANCH=none TEST=Boots correctly on Kukui and see in logs, that depthcharge detects EC_IN_RW GPIO. Change-Id: Icb39d663f65b72e0ad54059c9590d9693106ee25 Signed-off-by: Tristan Shieh Reviewed-on: https://review.coreboot.org/28670 Reviewed-by: Paul Menzel Reviewed-by: Julius Werner Tested-by: build bot (Jenkins) --- src/mainboard/google/kukui/chromeos.c | 2 ++ src/mainboard/google/kukui/gpio.h | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'src/mainboard/google') diff --git a/src/mainboard/google/kukui/chromeos.c b/src/mainboard/google/kukui/chromeos.c index 9184d8835d..bb14b1cc70 100644 --- a/src/mainboard/google/kukui/chromeos.c +++ b/src/mainboard/google/kukui/chromeos.c @@ -21,12 +21,14 @@ void setup_chromeos_gpios(void) { + gpio_input_pullup(EC_IN_RW); gpio_input_pullup(EC_IRQ); } void fill_lb_gpios(struct lb_gpios *gpios) { struct lb_gpio chromeos_gpios[] = { + {EC_IN_RW.id, ACTIVE_HIGH, -1, "EC in RW"}, {EC_IRQ.id, ACTIVE_LOW, -1, "EC interrupt"}, }; lb_add_gpios(gpios, chromeos_gpios, ARRAY_SIZE(chromeos_gpios)); diff --git a/src/mainboard/google/kukui/gpio.h b/src/mainboard/google/kukui/gpio.h index cb9ad24906..a2f77606ac 100644 --- a/src/mainboard/google/kukui/gpio.h +++ b/src/mainboard/google/kukui/gpio.h @@ -18,7 +18,8 @@ #include -#define EC_IRQ GPIO(PERIPHERAL_EN1) +#define EC_IRQ GPIO(PERIPHERAL_EN1) +#define EC_IN_RW GPIO(PERIPHERAL_EN14) void setup_chromeos_gpios(void); -- cgit v1.2.3