diff options
author | Duncan Laurie <dlaurie@google.com> | 2019-03-20 12:51:07 -0700 |
---|---|---|
committer | Duncan Laurie <dlaurie@chromium.org> | 2019-03-21 03:42:57 +0000 |
commit | 32346f0aa29eac2c91859e99dcefb401d3365784 (patch) | |
tree | e346736ebbb04cee222640447b4144212275dd97 /src/ec/google/wilco/commands.c | |
parent | a9273b5015f1cbcf3fc5db048663147c25c76f83 (diff) |
ec/google/wilco: Add function to indicate if EC uses signed FW
This will be used to distinguish the mainboard SKU so that the
correct EC firmware can be bundled with the board.
This is read from EC RAM so it can be used by an ACPI method in
the future.
BUG=b:119490232
Change-Id: I71b8017fc4b88e793dfe709e1cb1ab0f0bcdc4fa
Signed-off-by: Duncan Laurie <dlaurie@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/32001
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src/ec/google/wilco/commands.c')
-rw-r--r-- | src/ec/google/wilco/commands.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/ec/google/wilco/commands.c b/src/ec/google/wilco/commands.c index 1c7646106c..da04e2759b 100644 --- a/src/ec/google/wilco/commands.c +++ b/src/ec/google/wilco/commands.c @@ -14,6 +14,7 @@ */ #include <console/console.h> +#include <ec/acpi/ec.h> #include <stdint.h> #include <string.h> @@ -167,3 +168,10 @@ int wilco_ec_change_wake(uint8_t source, enum ec_wake_change change) wake_source, ARRAY_SIZE(wake_source), NULL, 0); } + +int wilco_ec_signed_fw(void) +{ + ec_set_ports(CONFIG_EC_BASE_ACPI_COMMAND, + CONFIG_EC_BASE_ACPI_DATA); + return !!ec_read(EC_RAM_SIGNED_FW); +} |