summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Rini <[email protected]>2025-09-26 09:31:44 -0600
committerIlias Apalodimas <[email protected]>2025-10-14 10:42:27 +0300
commit398f988410c94e95b49fe6679d8d848d2a09835a (patch)
tree1191b25efdc297ee2d2759702e6906d0ac66292e
parent038ca2c803cd0f51dad7ebd1d3da96118fb67056 (diff)
tee: Rework Makefile logic
The intention of how this Makefile was written was to allow for sandbox to build and test drivers still while otherwise requiring OPTEE to be enabled. This however didn't work quite right in practice as sandbox could enable some drivers which would then fail to link. Rework things such that sandbox will also traverse the optee directory when SANDBOX_TEE is enabled, but only build one of the optee-specific files when OPTEE is enabled. Signed-off-by: Tom Rini <[email protected]> Acked-by: Ilias Apalodimas <[email protected]> Signed-off-by: Ilias Apalodimas <[email protected]>
-rw-r--r--drivers/tee/Makefile4
-rw-r--r--drivers/tee/optee/Makefile2
2 files changed, 2 insertions, 4 deletions
diff --git a/drivers/tee/Makefile b/drivers/tee/Makefile
index ff844195ae1..5bc5df0d380 100644
--- a/drivers/tee/Makefile
+++ b/drivers/tee/Makefile
@@ -1,8 +1,6 @@
# SPDX-License-Identifier: GPL-2.0+
obj-y += tee-uclass.o
-obj-$(CONFIG_SANDBOX) += sandbox.o
-obj-$(CONFIG_OPTEE_TA_RPC_TEST) += optee/supplicant.o
-obj-$(CONFIG_OPTEE_TA_RPC_TEST) += optee/i2c.o
+obj-$(CONFIG_SANDBOX_TEE) += sandbox.o optee/
obj-$(CONFIG_OPTEE) += optee/
obj-y += broadcom/
diff --git a/drivers/tee/optee/Makefile b/drivers/tee/optee/Makefile
index 068c6e7aa1b..36ac085ef42 100644
--- a/drivers/tee/optee/Makefile
+++ b/drivers/tee/optee/Makefile
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: GPL-2.0+
-obj-y += core.o
+obj-$(CONFIG_OPTEE) += core.o
obj-y += supplicant.o
obj-$(CONFIG_DM_I2C) += i2c.o
obj-$(CONFIG_SUPPORT_EMMC_RPMB) += rpmb.o