diff options
Diffstat (limited to 'src/mainboard/google/auron')
-rw-r--r-- | src/mainboard/google/auron/chromeos.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/mainboard/google/auron/chromeos.c b/src/mainboard/google/auron/chromeos.c index 50eeddce0a..f449c9cf7f 100644 --- a/src/mainboard/google/auron/chromeos.c +++ b/src/mainboard/google/auron/chromeos.c @@ -8,6 +8,13 @@ /* SPI Write protect is GPIO 16 */ #define CROS_WP_GPIO 58 +/* EC_IN_RW is GPIO 25 in samus and 14 otherwise */ +#if CONFIG(BOARD_GOOGLE_SAMUS) +#define EC_IN_RW_GPIO 25 +#else +#define EC_IN_RW_GPIO 14 +#endif + void fill_lb_gpios(struct lb_gpios *gpios) { struct lb_gpio chromeos_gpios[] = { @@ -32,3 +39,9 @@ void mainboard_chromeos_acpi_generate(void) { chromeos_acpi_gpio_generate(cros_gpios, ARRAY_SIZE(cros_gpios)); } + +int get_ec_is_trusted(void) +{ + /* EC is trusted if not in RW. */ + return !get_gpio(EC_IN_RW_GPIO); +} |