Skip to content

Commit eb0b341

Browse files
oleksiimoisieievnashif
authored andcommitted
drivers: tee: optee: Introducing OP-TEE driver implementation
This includes the TEE driver api implementation for OP-TEE. It provides an interface to the OP-TEE TrustZone from the Normal space to start sessions and request functions of the TA. - targets ARM and ARM64; - use SMC to connect to OP-TEE; - accepts requests on privileged and unprivileged device. Signed-off-by: Oleksii Moisieiev <[email protected]>
1 parent e1a6676 commit eb0b341

File tree

5 files changed

+1298
-0
lines changed

5 files changed

+1298
-0
lines changed

drivers/tee/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# SPDX-License-Identifier: Apache-2.0
22

3+
add_subdirectory_ifdef(CONFIG_OPTEE optee)
4+
35
if (CONFIG_TEE)
46
zephyr_library()
57
zephyr_library_sources(tee.c)

drivers/tee/Kconfig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,6 @@ module-str = tee
1313

1414
comment "Device Drivers"
1515

16+
source "drivers/tee/optee/Kconfig"
17+
1618
endif # TEE

drivers/tee/optee/CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Copyright (c) 2023 EPAM Systems
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
zephyr_library()
5+
6+
zephyr_library_sources(optee.c)

drivers/tee/optee/Kconfig

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Copyright (c) 2023 EPAM Systems
2+
# SPDX-License-Identifier: Apache-2.0
3+
4+
config OPTEE
5+
bool "OP-TEE driver"
6+
depends on (ARM64 && ARMV8_A_NS && HAS_ARM_SMCCC) || ZTEST
7+
help
8+
This implements support of the OP-TEE firmware which is loaded
9+
as BL32 image. OP-TEE is a Trust Zone OS which implements mechanisms
10+
of the hardware isolation and rely to ARM TrustZone technology.
11+
Driver requests functions from the OP-TEE and implements RPC mechanism
12+
needed by OP-TEE to run services. See https://www.op-tee.org for more
13+
information.
14+
15+
config OPTEE_MAX_NOTIF
16+
int "Max number of OP-TEE notifications"
17+
depends on OPTEE
18+
default 255
19+
help
20+
Sets the maximum notifications from OP-TEE to the Normal World. OP-TEE using
21+
this mechanism for the synchronization.

0 commit comments

Comments
 (0)