summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorr.tyminski <r.tyminski@partner.samsung.com>2017-06-14 15:08:11 +0200
committerr.tyminski <r.tyminski@partner.samsung.com>2017-06-29 11:31:24 +0200
commit1e9dacf7eeab2113cca2cdff9d81730bca5627c6 (patch)
tree54a08899a4ac1416ff6fd45c259ea6ffaa7b029a
parentc2869247409cce7e02a139d9e735c860dce5e314 (diff)
downloadtef-optee_client-1e9dacf7eeab2113cca2cdff9d81730bca5627c6.tar.gz
tef-optee_client-1e9dacf7eeab2113cca2cdff9d81730bca5627c6.tar.bz2
tef-optee_client-1e9dacf7eeab2113cca2cdff9d81730bca5627c6.zip
Allow to define custom tee fs paths.
Adding ifndef for TEE_FS_SUBPATH and TEE_FS_PATH. Change-Id: I009b49f96094a230ac1b43d90471cd2519ffb7be
-rw-r--r--tee-supplicant/Makefile1
-rw-r--r--tee-supplicant/src/tee_supp_fs.c4
2 files changed, 5 insertions, 0 deletions
diff --git a/tee-supplicant/Makefile b/tee-supplicant/Makefile
index 204273f..808d90c 100644
--- a/tee-supplicant/Makefile
+++ b/tee-supplicant/Makefile
@@ -47,6 +47,7 @@ TEES_INCLUDES := ${CURDIR}/../libteec/include \
TEES_CFLAGS := $(addprefix -I, $(TEES_INCLUDES)) $(CFLAGS) \
-DDEBUGLEVEL_$(CFG_TEE_SUPP_LOG_LEVEL) \
-DBINARY_PREFIX=\"TEES\"
+TEES_CFLAGS += -DTEE_FS_SUBPATH=\"$(TEE_FS_SUBPATH)\" -DTEE_FS_PATH=\"$(TEE_FS_PATH)\"
ifeq ($(CFG_GP_SOCKETS),y)
TEES_CFLAGS += -DCFG_GP_SOCKETS=1
endif
diff --git a/tee-supplicant/src/tee_supp_fs.c b/tee-supplicant/src/tee_supp_fs.c
index bd1a220..554026d 100644
--- a/tee-supplicant/src/tee_supp_fs.c
+++ b/tee-supplicant/src/tee_supp_fs.c
@@ -48,8 +48,12 @@
#include <linux/tee.h>
/* Path to all secure storage files. */
+#ifndef TEE_FS_SUBPATH
#define TEE_FS_SUBPATH "/data"
+#endif
+#ifndef TEE_FS_PATH
#define TEE_FS_PATH "/data/tee/"
+#endif
#ifndef PATH_MAX
#define PATH_MAX 255