mb/google/corsola: implement get_ec_is_trusted

Set VB2_CONTEXT_EC_TRUSTED in verstage_main.

TEST=build pass
BUG=b:202871018

Signed-off-by: Rex-BC Chen <rex-bc.chen@mediatek.com>
Change-Id: If2837f5db52f91f5418d222d4dcd1af2aebcc105
Reviewed-on: https://review.coreboot.org/c/coreboot/+/59942
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Yu-Ping Wu <yupingso@google.com>
This commit is contained in:
Rex-BC Chen 2021-11-18 15:02:35 +08:00 committed by Hung-Te Lin
parent 9f01bbf410
commit e96861f5c7
1 changed files with 6 additions and 0 deletions

View File

@ -26,3 +26,9 @@ void fill_lb_gpios(struct lb_gpios *gpios)
}; };
lb_add_gpios(gpios, chromeos_gpios, ARRAY_SIZE(chromeos_gpios)); lb_add_gpios(gpios, chromeos_gpios, ARRAY_SIZE(chromeos_gpios));
} }
int get_ec_is_trusted(void)
{
/* EC is trusted if not in RW. This is active low. */
return !!gpio_get(GPIO_EC_IN_RW);
}