arm_ffa: efi: introduce FF-A MM communication
authorAbdellatif El Khlifi <abdellatif.elkhlifi@arm.com>
Thu, 13 Jul 2023 13:28:46 +0000 (14:28 +0100)
committerTom Rini <trini@konsulko.com>
Mon, 24 Jul 2023 19:30:03 +0000 (15:30 -0400)
commitaabbc2f8b2a4e1a458a34b9ff5becb997c6157ff
treed42d114d5132371d0d960f02600715267140c303
parent20e2b994f98642cf4152c117bd72fa719aca1de1
arm_ffa: efi: introduce FF-A MM communication

Add MM communication support using FF-A transport

This feature allows accessing MM partitions services through
EFI MM communication protocol. MM partitions such as StandAlonneMM
or smm-gateway secure partitions which reside in secure world.

An MM shared buffer and a door bell event are used to exchange
the data.

The data is used by EFI services such as GetVariable()/SetVariable()
and copied from the communication buffer to the MM shared buffer.

The secure partition is notified about availability of data in the
MM shared buffer by an FF-A message (door bell).

On such event, MM SP can read the data and updates the MM shared
buffer with the response data.

The response data is copied back to the communication buffer and
consumed by the EFI subsystem.

MM communication protocol supports FF-A 64-bit direct messaging.

Signed-off-by: Abdellatif El Khlifi <abdellatif.elkhlifi@arm.com>
Tested-by: Gowtham Suresh Kumar <gowtham.sureshkumar@arm.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Cc: Tom Rini <trini@konsulko.com>
Cc: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Cc: Jens Wiklander <jens.wiklander@linaro.org>
include/mm_communication.h
lib/efi_loader/Kconfig
lib/efi_loader/efi_variable_tee.c