All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 00/10] arm64: FF-A runtime transport for EFI variables
@ 2026-06-27 14:44 Harsimran Singh Tungal
  2026-06-27 14:44 ` [PATCH v3 01/10] efi_loader: add runtime memset helper Harsimran Singh Tungal
                   ` (9 more replies)
  0 siblings, 10 replies; 22+ messages in thread
From: Harsimran Singh Tungal @ 2026-06-27 14:44 UTC (permalink / raw)
  To: u-boot
  Cc: Abdellatif El Khlifi, Tom Rini, Ilias Apalodimas,
	Heinrich Schuchardt, Hugues Kamba Mpiana, Simon Glass,
	Harsimran Singh Tungal

Hi all,

This series adds FF-A runtime transport support so EFI variable runtime
services can communicate with the secure world after ExitBootServices().
It also extends tests, docs, and board configs to validate the runtime
path and keep boot-time behavior aligned with the runtime flow.

Changes in this series:
- Add EFI runtime-safe memset helper and FF-A runtime transport support.
- Implement FF-A runtime communication in the EFI variable TEE backend.
- Enable EFI runtime variable operations over the FF-A transport.
- Add sandbox runtime transport tests.
- Extend EFI selftests for runtime variables and bootefi selftest config.
- Document the FF-A runtime transport and selftest behavior.

Changes in v3:

Address Simon Glass's review comments:
- Move FF-A ExitBootServices event registration to the end of probe and
  clean up RX/TX buffer handling on failure.
- Rename FF-A runtime-context helpers to the ffa_runtime_context_* form.
- Rework FF-A/MM cache maintenance to cover only rounded request and
  response ranges.
- Add SetVirtualAddressMap handling for the FF-A shared buffer.
- Document FF-A shared-buffer ownership and alignment assumptions.
- Add EFIAPI to the TEE runtime GetVariable and GetNextVariableName
  entry points.
- Tighten sandbox FF-A runtime tests and reset runtime state between
  test cases.
- Update FF-A and bootefi documentation for the runtime transport and
  split runtime-variable selftests.
- Rework commit messages to drop redundant information.

Address Ilias Apalodimas's review comments:
- Keep efi_var_common.c unchanged and drop commit 6 from v2 patchset.
- Rename the TEE/FF-A runtime handlers to the *_int_runtime form.
- Remove log_*() calls from __efi_runtime FF-A/MM communication paths.

Other:
- Fix FF-A memory-share sender_id to use the runtime private endpoint
  ID after rebasing.
- Fix the expected QueryVariableInfo() return status for the
  TEE-backed runtime selftest path.


Changes in v2:

Address Simon Glass's review comments:
- Fix efi_memset_runtime() style, declaration, and byte cast
- Tighten the FF-A runtime context failure path, clean up arm-ffa-runtime.c
  style issues, and move ExitBootServices event registration earlier in probe
- Add shared-buffer bounds/alignment checks, and tightening comments/kernel-doc
- Document the FF-A shared buffer cacheline-alignment requirement and add
  BUILD_BUG_ON() checks for the address
- Cache attributes before the shared buffer is reused, moving the read-only
  check earlier, and split the u16_strsize() related change in separate patch
- Reword commit messages for the runtime helper relocation
- Rework the non-volatile runtime variable selftest into setup/verify phases
- Extend the sandbox FF-A runtime tests with no-context coverage,
  runtime-context reset, and separate errno-mapping coverage
- Refresh the FF-A runtime transport and bootefi documentation
- Drop patch 12 in v1, as ffa_mm_communicate handles both runtime and
  boottime capabilities in v2
- Squash patch 8 and patch 9 from v1

Address Ilias Apalodimas's review comments:
- Reuse common MM SP error mapping for boot and runtime paths
- Rename runtime-phase tracking to reflect the ExitBootServices transition
- Collapse duplicated boot-time and runtime MM communication helpers into common
  implementations
- Keep the arm64 cache-maintenance path runtime-safe
- Move FF-A shared-buffer runtime memory-map registration to the end of
  variable-service initialization

Link to v2: https://lore.kernel.org/u-boot/20260514124924.1804332-1-harsimransingh.tungal@arm.com/
Link to v1: https://lore.kernel.org/u-boot/20260424173151.371134-1-harsimransingh.tungal@arm.com/

Harsimran Singh Tungal (10):
  efi_loader: add runtime memset helper
  arm-ffa: add FF-A bus runtime support
  efi_loader: add FF-A runtime support in EFI variable TEE driver
  efi_loader: enable EFI runtime SetVariable()/GetVariable() using FF-A
    transport
  charset: mark u16_strsize() as __efi_runtime
  corstone1000: enable bootefi selftest
  efi: selftest: add runtime variable tests with non-volatile storage
  test: dm: add sandbox FF-A runtime transport tests
  doc: arm64: document FF-A runtime path for EFI variables
  doc: bootefi: note two-phase runtime variables selftest

 arch/arm/cpu/armv8/cache.S                    |   8 +
 arch/arm/cpu/armv8/cache_v8.c                 |  13 +-
 arch/sandbox/include/asm/sandbox_arm_ffa.h    |  16 +-
 configs/corstone1000_defconfig                |   3 +
 doc/arch/arm64.ffa.rst                        |  88 ++-
 doc/usage/cmd/armffa.rst                      |  11 +
 doc/usage/cmd/bootefi.rst                     |  31 +
 drivers/firmware/arm-ffa/Kconfig              |  11 +
 drivers/firmware/arm-ffa/Makefile             |   4 +-
 drivers/firmware/arm-ffa/arm-ffa-runtime.c    | 294 +++++++
 drivers/firmware/arm-ffa/arm-ffa-uclass.c     | 114 +--
 drivers/firmware/arm-ffa/arm-ffa.c            |  16 +-
 drivers/firmware/arm-ffa/ffa-emul-uclass.c    |  49 +-
 include/arm_ffa.h                             |  16 +-
 include/arm_ffa_priv.h                        |  22 +-
 include/arm_ffa_runtime.h                     | 191 +++++
 include/efi_loader.h                          |   3 +
 lib/charset.c                                 |   2 +-
 lib/efi_loader/Kconfig                        |   4 +
 lib/efi_loader/efi_runtime.c                  |  20 +
 lib/efi_loader/efi_variable_tee.c             | 726 +++++++++++++++---
 .../efi_selftest_variables_runtime.c          | 715 +++++++++++------
 test/dm/Makefile                              |   3 +-
 test/dm/ffa.c                                 |   6 +-
 test/dm/ffa_runtime.c                         | 123 +++
 25 files changed, 1997 insertions(+), 492 deletions(-)
 create mode 100644 drivers/firmware/arm-ffa/arm-ffa-runtime.c
 create mode 100644 include/arm_ffa_runtime.h
 create mode 100644 test/dm/ffa_runtime.c

-- 
2.34.1


^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2026-07-01 14:00 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-27 14:44 [PATCH v3 00/10] arm64: FF-A runtime transport for EFI variables Harsimran Singh Tungal
2026-06-27 14:44 ` [PATCH v3 01/10] efi_loader: add runtime memset helper Harsimran Singh Tungal
2026-06-29 18:21   ` Abdellatif El Khlifi
2026-06-27 14:44 ` [PATCH v3 02/10] arm-ffa: add FF-A bus runtime support Harsimran Singh Tungal
2026-06-29 18:12   ` Abdellatif El Khlifi
2026-07-01 12:59   ` Ilias Apalodimas
2026-07-01 13:59   ` Ilias Apalodimas
2026-06-27 14:44 ` [PATCH v3 03/10] efi_loader: add FF-A runtime support in EFI variable TEE driver Harsimran Singh Tungal
2026-06-29 18:40   ` Abdellatif El Khlifi
2026-07-01 13:56   ` Ilias Apalodimas
2026-06-27 14:44 ` [PATCH v3 04/10] efi_loader: enable EFI runtime SetVariable()/GetVariable() using FF-A transport Harsimran Singh Tungal
2026-07-01 13:49   ` Ilias Apalodimas
2026-06-27 14:44 ` [PATCH v3 05/10] charset: mark u16_strsize() as __efi_runtime Harsimran Singh Tungal
2026-06-27 18:50   ` Ilias Apalodimas
2026-06-29 18:28   ` Abdellatif El Khlifi
2026-06-27 14:44 ` [PATCH v3 06/10] corstone1000: enable bootefi selftest Harsimran Singh Tungal
2026-06-29 18:44   ` Abdellatif El Khlifi
2026-06-27 14:44 ` [PATCH v3 07/10] efi: selftest: add runtime variable tests with non-volatile storage Harsimran Singh Tungal
2026-06-27 14:44 ` [PATCH v3 08/10] test: dm: add sandbox FF-A runtime transport tests Harsimran Singh Tungal
2026-06-27 14:44 ` [PATCH v3 09/10] doc: arm64: document FF-A runtime path for EFI variables Harsimran Singh Tungal
2026-06-29 18:15   ` Abdellatif El Khlifi
2026-06-27 14:44 ` [PATCH v3 10/10] doc: bootefi: note two-phase runtime variables selftest Harsimran Singh Tungal

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.