All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ilias Apalodimas <ilias.apalodimas@linaro.org>
To: u-boot@lists.denx.de
Subject: [PATCH 6/6] doc: uefi.rst: Add OP-TEE variable storage config options
Date: Mon, 11 May 2020 11:52:05 +0300	[thread overview]
Message-ID: <20200511085205.GD73895@apalos.home> (raw)
In-Reply-To: <3c41f317-4bc0-20a2-a769-17ebdee04e68@gmx.de>

On Sat, May 09, 2020 at 11:51:48AM +0200, Heinrich Schuchardt wrote:
> On 5/6/20 9:12 PM, Ilias Apalodimas wrote:
> > If OP-TEE is compiled with an EDK2 application running in secure world
> > it can process and store UEFI variables in an RPMB.
> > Add documentation for the config options enabling this
> >
> > Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
> > ---
> >  doc/uefi/uefi.rst | 10 ++++++++++
> >  1 file changed, 10 insertions(+)
> >
> > diff --git a/doc/uefi/uefi.rst b/doc/uefi/uefi.rst
> > index 4fda00d68721..93b0faadd26e 100644
> > --- a/doc/uefi/uefi.rst
> > +++ b/doc/uefi/uefi.rst
> > @@ -188,6 +188,16 @@ on the sandbox
> >      cd <U-Boot source directory>
> >      pytest.py test/py/tests/test_efi_secboot/test_signed.py --bd sandbox
> >
> > +Using OP-TEE for EFI variables
> > +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > +
> > +If an RPMB and it's drivers is available in U-Boot, OP-TEE can be used for
> 
> %s/is available/are available/
> 
> ..., OP-TEE in conjunction with EDK2's secure management module (SMM)
> can be used to provide variable services.
> 
> > +variable services.
> > +Enabling CONFIG_EFI_MM_COMM_TEE=y will dispatch the variables services to
> 
> %s/dispatch/delegate/
> 
> > +OP-TEE. OP-TEE needs to be compiled with a secure application (coming from EDK2)
> 
> Is it really compiling? I thought it was only linking.
> 
> ... needs to be linked with EDK2's secure management module (SMM) which
> will process the variables ...

It's a bit weird, you practically append the whole binary *after* OP-TEE source
code. So you compile OP-TEE with:
make CFG_ARM64_core=y PLATFORM=<plat> CFG_STMM_PATH=BL32_AP_MM.fd

> 
> > +which will process variables in the Secure World and store them in the RPMB
> > +using the OP-TEE supplicant.
> > +
> >  Executing the boot manager
> >  ~~~~~~~~~~~~~~~~~~~~~~~~~~
> >
> >
> 
> We should separate in the description between OP-TEE being used to
> provide variable services and the specific embodiment using SMM, e.g.
> 
> How about:
> 
> 
> Using OP-TEE for EFI variables
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> Instead of implementing UEFI variable services inside U-Boot they can
> also be provided in the secure world by a module for OP-TEE[1]. The
> interface between U-Boot and OP-TEE for variable services is enabled by
> CONFIG_EFI_MM_COMM_TEE=y.
> 
> Tianocore EDK II's standalone management mode driver for variables can
> be linked to OP-TEE for this purpose. This module uses the Replay
> Protected Memory Block (RPMB) of an eMMC device for persisting
> non-volatile variables. When calling the variable services via the
> OP-TEE API U-Boot's OP-TEE supplicant relays calls to the RPMB driver
> which has to be enabled via CONFIG_SUPPORT_EMMC_RPMB=y.
> 
> [1] https://optee.readthedocs.io/ - OP-TEE documentation

Ok sounbds better, I'll use this.

Regards
/Ilias
> 
> Best regards
> 
> Heinrich

      reply	other threads:[~2020-05-11  8:52 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-06 19:12 [PATCH 0/6] EFI variable support via OP-TEE Ilias Apalodimas
2020-05-06 19:12 ` [PATCH 1/6] charset: Add support for calculating bytes occupied by a u16 string Ilias Apalodimas
2020-05-09  6:44   ` Heinrich Schuchardt
2020-05-06 19:12 ` [PATCH 2/6] efi_loader: Add headers for EDK2 StandAloneMM communication Ilias Apalodimas
2020-05-09  8:12   ` Heinrich Schuchardt
2020-05-11 10:25     ` Ilias Apalodimas
2020-05-06 19:12 ` [PATCH 3/6] efi_loader: Implement EFI variable handling via OP-TEE Ilias Apalodimas
2020-05-09  9:14   ` Heinrich Schuchardt
2020-05-11  8:43     ` Ilias Apalodimas
2020-05-11 10:00     ` Ilias Apalodimas
2020-05-06 19:12 ` [PATCH 4/6] cmd: efidebug: Add support for querying UEFI variable storage Ilias Apalodimas
2020-05-09  9:58   ` Heinrich Schuchardt
2020-05-11  8:49     ` Ilias Apalodimas
2020-05-06 19:12 ` [PATCH 5/6] MAINTAINERS: Add maintainer for EFI variables via OP-TEE Ilias Apalodimas
2020-05-09  9:17   ` Heinrich Schuchardt
2020-05-11  8:47     ` Ilias Apalodimas
2020-05-06 19:12 ` [PATCH 6/6] doc: uefi.rst: Add OP-TEE variable storage config options Ilias Apalodimas
2020-05-09  9:51   ` Heinrich Schuchardt
2020-05-11  8:52     ` Ilias Apalodimas [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200511085205.GD73895@apalos.home \
    --to=ilias.apalodimas@linaro.org \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.