diff options
author | Etienne Carriere <etienne.carriere@linaro.org> | 2021-11-09 17:08:20 +0100 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2021-11-23 13:53:03 -0500 |
commit | 1662ed0c1a464b39ff5b303950c034a352054114 (patch) | |
tree | 7ff85dd5d1dd50cdc21363c3564a5f9096d60ab2 | |
parent | 32190a959de4c9467008249d0e9fb4b425332a5c (diff) | |
download | u-boot-1662ed0c1a464b39ff5b303950c034a352054114.zip u-boot-1662ed0c1a464b39ff5b303950c034a352054114.tar.gz u-boot-1662ed0c1a464b39ff5b303950c034a352054114.tar.bz2 |
tee: define session login identifiers
Define identifiers for clnt_login field in struct tee_open_session_arg
based in GlobalPlatform Device TEE IDs and on the REE_KERNEL identifier
extension from OP-TEE OS.
Cc: Jens Wiklander <jens.wiklander@linaro.org>
Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Signed-off-by: Etienne Carriere <etienne.carriere@linaro.org>
-rw-r--r-- | include/tee.h | 23 |
1 files changed, 21 insertions, 2 deletions
diff --git a/include/tee.h b/include/tee.h index 44e9cd4..30ea2ee 100644 --- a/include/tee.h +++ b/include/tee.h @@ -32,6 +32,25 @@ TEE_PARAM_ATTR_META) /* + * Global Platform login identifiers for tee_open_session_arg::clnt_login + */ +#define TEE_LOGIN_PUBLIC 0x00000000 +#define TEE_LOGIN_USER 0x00000001 +#define TEE_LOGIN_GROUP 0x00000002 +#define TEE_LOGIN_APPLICATION 0x00000004 +#define TEE_LOGIN_APPLICATION_USER 0x00000005 +#define TEE_LOGIN_APPLICATION_GROUP 0x00000006 +/* + * Reserve use of GP implementation specific login method range + * (0x80000000 - 0xBFFFFFFF). This range is rather being used + * for REE kernel clients or TEE implementation. + */ +#define TEE_LOGIN_REE_KERNEL_MIN 0x80000000 +#define TEE_LOGIN_REE_KERNEL_MAX 0xBFFFFFFF +/* Private login method for REE kernel/privileged clients */ +#define TEE_LOGIN_REE_KERNEL 0x80000000 + +/* * Some Global Platform error codes which has a meaning if the * TEE_GEN_CAP_GP bit is returned by the driver in * struct tee_version_data::gen_caps @@ -135,8 +154,8 @@ struct tee_param { /** * struct tee_open_session_arg - extra arguments for tee_open_session() * @uuid: [in] UUID of the Trusted Application - * @clnt_uuid: [in] Normally zeroes - * @clnt_login: [in] Normally 0 + * @clnt_uuid: [in] UUID of client, zeroes for PUBLIC/REE_KERNEL + * @clnt_login: [in] Class of client TEE_LOGIN_* * @session: [out] Session id * @ret: [out] return value * @ret_origin: [out] origin of the return value |