commit | 022175f49371aeb3bb267201ae06125fd6ae262e | [log] [tgz] |
---|---|---|
author | Harrison Mutai <harrison.mutai@arm.com> | Tue May 13 16:15:57 2025 +0000 |
committer | Harrison Mutai <harrison.mutai@arm.com> | Fri Jun 13 13:52:57 2025 +0000 |
tree | ae38bbe721cea87148fc85f242d830890cbbcb53 | |
parent | 2886e1501b2dfcd881bae4962ec7de35baa31922 [diff] |
feat(libtl): add TPM event log management helpers Introduce `tpm_event_log.c` and `tpm_event_log.h` to simplify managing the TPM event log within a Transfer List. These helpers allow: - Extending an existing event log entry in-place if possible - Adding a new event log TE if needed, while preserving old data - Finalizing and resizing the TE after log writing is complete This isolates common event log handling logic used during measured boot, making integration simpler across different firmware stages. Change-Id: I5506b4a7111ae690e1c9032bb245618a16fb1fff Signed-off-by: Harrison Mutai <harrison.mutai@arm.com>
The Transfer List Library (LibTL) implements the Firmware Handoff specification, providing a streamlined interface for managing transfer lists. LibTL offers a user-friendly interface for:
The library supports building with host tools such as Clang and GCC, and cross compilation with the Aarch64 GNU compiler.
Tool | Minimum Version |
---|---|
Clang-Format | 14 |
CMake | 3.15 |
To configure the project with the default settings (using GCC as the host compiler), run:
cmake -B build
Then, to compile the project and produce libtl.a
in the build/
directory:
cmake --build build
To cross-compile the project (e.g., for AArch64), specify the appropriate tool using the CC
option when configuring the project:
CC=aarch64-none-elf-gcc cmake -B build -DCMAKE_TRY_COMPILE_TARGET_TYPE=STATIC_LIBRARY cmake --build build
You can specify the build mode using the CMAKE_BUILD_TYPE
option. Supported modes include:
Debug
– Full debug info with no optimization.Release
– Optimized build without debug info.RelWithDebInfo
– Optimized build with debug info.MinSizeRel
– Optimized for minimum size.APIs for specific projects can be conditionally included in the static library using the PROJECT_API
option.
Tests for LibTL are provided in the folder test
, to configure the project for test builds, run:
cmake -B build -DTARGET_GROUP=test cmake --build build
Then, to run the tests with ctest
, use:
ctest --test-dir build/