diff options
author | Mary Ruthven <mruthven@chromium.org> | 2022-08-16 14:17:16 -0500 |
---|---|---|
committer | Chromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com> | 2022-11-02 23:46:46 +0000 |
commit | b9d1609c4c96c592ac9bf2c64b54c784412b5617 (patch) | |
tree | 761ad5e6416ce12c61a591ed27189ca00c71841b /board/cr50/usb_spi_board.h | |
parent | 83be28f6f56c7daa543c03633b28a742e2c462a3 (diff) | |
download | chrome-ec-b9d1609c4c96c592ac9bf2c64b54c784412b5617.tar.gz |
ap_ro: v1: check the gbb flags are 0
This change verifies the GBB flags are 0. Before running verification
find the GBB flags using FMAP. Read the flags and verify they're 0. If
they are continue with verification. If verification passes, set the
status to AP_RO_PASS instead of AP_RO_PASS_UNVERIFIED_GBB.
BUG=b:236844541
TEST=manual
# Set GBB flags to 0x42b9
/usr/share/vboot/bin/set_gbb_flags.sh 0x42b9
# save the hash with GBB 0x42b9
ap_ro_hash.py WP_RO
# Verify AP RO verification fails because flags are 0x42b9
[72.692916 RO Validation triggered]
[72.694034 enable_spi_pinmux: AP]
[72.696472 spi_hash_pp_done: AP]
[72.747348 validate_gbbd: invalid flags 42b9]
[72.748043 spi_hash_disable]
[72.748325 AP RO FAILED!]
# reboot cr50 to release ec reset
> reboot
# Set GBB flags to 0
/usr/share/vboot/bin/set_gbb_flags.sh 0
# Verify ap ro verification passes.
[11.887981 RO Validation triggered]
[11.890193 enable_spi_pinmux: AP]
[11.893215 spi_hash_pp_done: AP]
[11.944625 validate_gbbd: ok]
[11.945545 validate_ranges_sha: 0:400000]
[12.001037 AC: -F]
[19.201118 spi_hash_disable]
[19.202487 AP RO PASS!]
[19.212337 AP off]
[19.264606 CCD state: UARTEC+TX]
# Verify verification fails if the FMAP isn't in the hash.
# Set the hash
ap_ro_hash.py COREBOOT GBB
# Trigger verification. It should fail because the fmap isn't in
# the hash.
[87.274055 RO Validation triggered]
[87.275653 enable_spi_pinmux: AP]
[87.278614 spi_hash_pp_done: AP]
[87.329715 init_gbbd: FMAP(3c0000:47c) not in hash.]
[87.367118 combo0 efs rst]
[87.367698 Recovery Requested]
[87.388858 AC: -F]
[87.544731 init_gbbd: FMAP(13c0000:47c) not in hash.]
[87.707511 spi_hash_disable]
[87.708415 AP RO FAILED!]
Change-Id: I3f53272a9c1aa1e82df16461dd4ac6577e4060c8
Signed-off-by: Mary Ruthven <mruthven@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3840651
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Diffstat (limited to 'board/cr50/usb_spi_board.h')
0 files changed, 0 insertions, 0 deletions