optee: probe RPMB device using RPMB subsystem
authorJens Wiklander <jens.wiklander@linaro.org>
Wed, 14 Aug 2024 15:35:58 +0000 (17:35 +0200)
committerUlf Hansson <ulf.hansson@linaro.org>
Mon, 26 Aug 2024 11:16:20 +0000 (13:16 +0200)
commitf0c8431568eedee7705c92f5c341bdc4567e3ad5
treed102b8ab05f0e34e24bfeb86094c4b46c3d1fe5b
parentc30b855e814d9094e369a19fbd86c9bb5badc154
optee: probe RPMB device using RPMB subsystem

Adds support in the OP-TEE drivers (both SMC and FF-A ABIs) to probe and
use an RPMB device via the RPMB subsystem instead of passing the RPMB
frames via tee-supplicant in user space. A fallback mechanism is kept to
route RPMB frames via tee-supplicant if the RPMB subsystem isn't
available.

The OP-TEE RPC ABI is extended to support iterating over all RPMB
devices until one is found with the expected RPMB key already
programmed.

Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
Tested-by: Manuel Traut <manut@mecka.net>
Reviewed-by: Sumit Garg <sumit.garg@linaro.org>
Link: https://lore.kernel.org/r/20240814153558.708365-5-jens.wiklander@linaro.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Documentation/ABI/testing/sysfs-class-tee [new file with mode: 0644]
MAINTAINERS
drivers/tee/optee/core.c
drivers/tee/optee/device.c
drivers/tee/optee/ffa_abi.c
drivers/tee/optee/optee_ffa.h
drivers/tee/optee/optee_private.h
drivers/tee/optee/optee_rpc_cmd.h
drivers/tee/optee/optee_smc.h
drivers/tee/optee/rpc.c
drivers/tee/optee/smc_abi.c