blob: 0aad59085902dc3d4074cdd578ec8ee55c43aa4d [file] [log] [blame]
Eddie Jamesfb1c10e2023-10-24 10:43:52 -05001.. SPDX-License-Identifier: GPL-2.0+
2
3Measured Boot
4=====================
5
6U-Boot can perform a measured boot, the process of hashing various components
7of the boot process, extending the results in the TPM and logging the
8component's measurement in memory for the operating system to consume.
9
10By default, U-Boot will measure the operating system (linux) image, the
11initrd image, and the "bootargs" environment variable. By enabling
12CONFIG_MEASURE_DEVICETREE, U-Boot will also measure the devicetree image.
13
14The operating system typically would verify that the hashes found in the
15TPM PCRs match the contents of the event log. This can further be checked
16against the hash results of previous boots.
17
18Requirements
19---------------------
20
21* A hardware TPM 2.0 supported by the U-Boot drivers
22* CONFIG_TPM=y
23* CONFIG_MEASURED_BOOT=y
24* Device-tree configuration of the TPM device to specify the memory area
25 for event logging. The TPM device node must either contain a phandle to
26 a reserved memory region or "linux,sml-base" and "linux,sml-size"
27 indicating the address and size of the memory region. An example can be
28 found in arch/sandbox/dts/test.dts
29* The operating system must also be configured to use the memory regions
30 specified in the U-Boot device-tree in order to make use of the event
31 log.