aboutsummaryrefslogtreecommitdiff
path: root/src/security
diff options
context:
space:
mode:
Diffstat (limited to 'src/security')
-rw-r--r--src/security/tpm/tspi/crtm.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/security/tpm/tspi/crtm.c b/src/security/tpm/tspi/crtm.c
index 24b9fbd2d7..6f8f58fcd1 100644
--- a/src/security/tpm/tspi/crtm.c
+++ b/src/security/tpm/tspi/crtm.c
@@ -54,12 +54,14 @@ static uint32_t tspi_init_crtm(void)
}
/* measure bootblock from RO */
- struct region_device bootblock_fmap;
- if (fmap_locate_area_as_rdev("BOOTBLOCK", &bootblock_fmap) == 0) {
- if (tpm_measure_region(&bootblock_fmap,
- TPM_CRTM_PCR,
- "FMAP: BOOTBLOCK"))
- return VB2_ERROR_UNKNOWN;
+ if (!CONFIG(ARCH_X86)) {
+ struct region_device bootblock_fmap;
+ if (fmap_locate_area_as_rdev("BOOTBLOCK", &bootblock_fmap) == 0) {
+ if (tpm_measure_region(&bootblock_fmap,
+ TPM_CRTM_PCR,
+ "FMAP: BOOTBLOCK"))
+ return VB2_ERROR_UNKNOWN;
+ }
} else if (CONFIG(BOOTBLOCK_IN_CBFS)){
/* Mapping measures the file. We know we can safely map here because
bootblock-as-a-file is only used on x86, where we don't need cache to map. */