tee: optee: add TEE bus device enumeration support
authorSumit Garg <sumit.garg@linaro.org>
Tue, 29 Jan 2019 05:49:37 +0000 (11:19 +0530)
committerJens Wiklander <jens.wiklander@linaro.org>
Fri, 1 Feb 2019 14:12:46 +0000 (15:12 +0100)
commitc3fa24af92445c419c19df5981ab4e41a3ae3361
treed868485cdd06f68fffdc9d33450dd6a19878ed0e
parent0fc1db9d105915021260eb241661b8e96f5c0f1a
tee: optee: add TEE bus device enumeration support

OP-TEE provides a pseudo TA to enumerate TAs which can act as devices/
services for TEE bus. So implement device enumeration using invoke
function: PTA_CMD_GET_DEVICES provided by pseudo TA to fetch array of
device UUIDs. Also register these enumerated devices with TEE bus as
"optee-clntX" device.

Signed-off-by: Sumit Garg <sumit.garg@linaro.org>
Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>
[jw: fix optee_enumerate_devices() with no devices found]
Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
drivers/tee/optee/Makefile
drivers/tee/optee/core.c
drivers/tee/optee/device.c [new file with mode: 0644]
drivers/tee/optee/optee_private.h