diff --git a/marvell/services/optee_app/libsecure_storage/host/libsecure_storage.c b/marvell/services/optee_app/libsecure_storage/host/libsecure_storage.c
index b5701dd..2c47cd8 100755
--- a/marvell/services/optee_app/libsecure_storage/host/libsecure_storage.c
+++ b/marvell/services/optee_app/libsecure_storage/host/libsecure_storage.c
@@ -28,6 +28,12 @@
 #include <err.h>
 #include <stdio.h>
 #include <string.h>
+#include <fcntl.h>
+#include <time.h>
+#include <errno.h>
+#include <sys/stat.h>
+#include <unistd.h>
+#include <semaphore.h>
 #include <tee_client_api.h>
 #include "mbtk_log.h"
 
@@ -41,13 +47,12 @@
 	TEEC_Session sess;
 };
 
-
+sem_t* sem;
+#define TEE_SEM_NAME "/tee_session_mutex"
 int prepare_tee_session(struct test_ctx *ctx)
 {
-	TEEC_UUID uuid = TA_SECURE_STORAGE_UUID;
-	uint32_t origin;
 	TEEC_Result res;
-
+	
 	/* Initialize a context connecting us to the TEE */
 	res = TEEC_InitializeContext(NULL, &ctx->ctx);
 	if (res != TEEC_SUCCESS)
@@ -55,31 +60,78 @@
 	    LOGE("TEEC_InitializeContext failed with code 0x%x", res);
 	    return -1;
 	}
-	/* Open a session with the TA */
-	res = TEEC_OpenSession(&ctx->ctx, &ctx->sess, &uuid, TEEC_LOGIN_PUBLIC, NULL, NULL, &origin);
-	if (res != TEEC_SUCCESS)
+	sem = sem_open(TEE_SEM_NAME, O_CREAT | O_EXCL, 0666, 1);
+    if (sem == SEM_FAILED)
 	{
-		LOGE("TEEC_Opensession failed with code 0x%x origin 0x%x",res, origin);
-		return -1;
-	}
+        if (errno == EEXIST)
+		{
+            sem = sem_open(TEE_SEM_NAME, 0);
+        }
+        if (sem == SEM_FAILED)
+		{
+            LOGE("sem_open failed");
+            return -1;
+        }
+    }
 
 	return 0;
 }
 
 void terminate_tee_session(struct test_ctx *ctx)
 {
-	TEEC_CloseSession(&ctx->sess);
+	if (sem) {
+        sem_close(sem);
+        sem_unlink(TEE_SEM_NAME);
+    }
 	TEEC_FinalizeContext(&ctx->ctx);
 }
 
-TEEC_Result read_secure_object(struct test_ctx *ctx, const char *id,
-			char *data, size_t data_len)
+int open_tee_session(struct test_ctx *ctx)
 {
+	TEEC_Result res;
+	uint32_t origin;
+	TEEC_UUID uuid = TA_SECURE_STORAGE_UUID;
+	struct timespec ts = {0};
+	/* Open a session with the TA */
+	if (clock_gettime(CLOCK_MONOTONIC, &ts) == -1) 
+	{
+        LOGE("clock_gettime failed: %s", strerror(errno));
+        return -1;
+    }
+	ts.tv_sec += 1;  // 秒部分
+//    ts.tv_nsec += 300 * 1000000; // 纳秒部分
+	if (sem_timedwait(sem, &ts) != 0)
+	{
+		if (errno == ETIMEDOUT)
+		{
+            LOGE("TEE session lock timeout after 300 milliseconds");
+        } else
+		{
+            LOGE("sem_timedwait error: %s", strerror(errno));
+        }
+        return -1;
+    }
+	res = TEEC_OpenSession(&ctx->ctx, &ctx->sess, &uuid, TEEC_LOGIN_PUBLIC, NULL, NULL, &origin);
+	if (res != TEEC_SUCCESS)
+	{
+		LOGE("TEEC_Opensession failed with code 0x%x origin 0x%x",res, origin);
+		sem_post(sem);
+		return -1;
+	}
+	return 0;
+}
+
+TEEC_Result read_secure_object(struct test_ctx *ctx, const char *id,
+			char *data, size_t *data_len)
+{
+	LOGE("read start\n");
 	TEEC_Operation op;
 	uint32_t origin;
 	TEEC_Result res;
 	size_t id_len = strlen(id);
-
+	int ret = open_tee_session(ctx);
+	if (ret)
+		return -1;
 	memset(&op, 0, sizeof(op));
 	op.paramTypes = TEEC_PARAM_TYPES(TEEC_MEMREF_TEMP_INPUT,
 					 TEEC_MEMREF_TEMP_OUTPUT,
@@ -88,31 +140,43 @@
 	op.params[0].tmpref.size = id_len;
 
 	op.params[1].tmpref.buffer = data;
-	op.params[1].tmpref.size = data_len;
+	op.params[1].tmpref.size = *data_len;
 
 	res = TEEC_InvokeCommand(&ctx->sess,
 				 TA_SECURE_STORAGE_CMD_READ_RAW,
 				 &op, &origin);
 	switch (res) {
 	case TEEC_SUCCESS:
+	{
+		*data_len = op.params[1].tmpref.size;
+	}
 	case TEEC_ERROR_SHORT_BUFFER:
 	case TEEC_ERROR_ITEM_NOT_FOUND:
 		break;
 	default:
 		LOGE("Command READ_RAW failed: 0x%x / %u\n", res, origin);
 	}
-
+	//data[2048] = '\0';
+	//LOGE("str:%d\n",strlen(data));
+	LOGE("DATA-LEN:%d\n",op.params[1].tmpref.size);
+	TEEC_CloseSession(&ctx->sess);
+	sem_post(sem);
+	LOGE("res:%x\n",res);
+	LOGE("read end\n");
 	return res;
 }
 
 TEEC_Result write_secure_object(struct test_ctx *ctx, const char *id,
 			char *data, size_t data_len)
 {
+	LOGE("write start\n");
 	TEEC_Operation op;
 	uint32_t origin;
 	TEEC_Result res;
 	size_t id_len = strlen(id);
-
+	int ret = open_tee_session(ctx);
+	if (ret)
+		return -1;
 	memset(&op, 0, sizeof(op));
 	op.paramTypes = TEEC_PARAM_TYPES(TEEC_MEMREF_TEMP_INPUT,
 					 TEEC_MEMREF_TEMP_INPUT,
@@ -136,17 +200,22 @@
 	default:
 		LOGE("Command WRITE_RAW failed: 0x%x / %u\n", res, origin);
 	}
-
+	TEEC_CloseSession(&ctx->sess);
+	sem_post(sem);
+	LOGE("write end\n");
 	return res;
 }
 
 TEEC_Result delete_secure_object(struct test_ctx *ctx, const char *id)
 {
+	LOGE("delete start\n");
 	TEEC_Operation op;
 	uint32_t origin;
 	TEEC_Result res;
 	size_t id_len = strlen(id);
-
+	int ret = open_tee_session(ctx);
+	if (ret)
+		return -1;
 	memset(&op, 0, sizeof(op));
 	op.paramTypes = TEEC_PARAM_TYPES(TEEC_MEMREF_TEMP_INPUT,
 					 TEEC_NONE, TEEC_NONE, TEEC_NONE);
@@ -165,6 +234,8 @@
 	default:
 		LOGE("Command DELETE failed: 0x%x / %u\n", res, origin);
 	}
-
+	TEEC_CloseSession(&ctx->sess);
+	sem_post(sem);
+	LOGE("delete end\n");
 	return res;
 }
diff --git a/mbtk/libgsw_lib/gsw_secrypt_ss_interface.c b/mbtk/libgsw_lib/gsw_secrypt_ss_interface.c
index d724b0b..6013227 100755
--- a/mbtk/libgsw_lib/gsw_secrypt_ss_interface.c
+++ b/mbtk/libgsw_lib/gsw_secrypt_ss_interface.c
@@ -161,7 +161,7 @@
 
 int (*prepare_tee_session)(struct test_ctx *ctx);
 void (*terminate_tee_session)(struct test_ctx *ctx);
-TEEC_Result (*read_secure_object)(struct test_ctx *ctx, const char *id,char *data, size_t data_len);
+TEEC_Result (*read_secure_object)(struct test_ctx *ctx, const char *id,char *data, size_t *data_len);
 TEEC_Result (*write_secure_object)(struct test_ctx *ctx, const char *id,char *data, size_t data_len);
 TEEC_Result (*delete_secure_object)(struct test_ctx *ctx, const char *id);
 
@@ -206,7 +206,7 @@
         return GSW_HAL_NORMAL_FAIL;
     }
 
-    read_secure_object = (TEEC_Result (*)(struct test_ctx *ctx, const char *id,char *data, size_t data_len))dlsym(dlHandle_secure, "read_secure_object");
+    read_secure_object = (TEEC_Result (*)(struct test_ctx *ctx, const char *id,char *data, size_t *data_len))dlsym(dlHandle_secure, "read_secure_object");
     if (read_secure_object == NULL) 
     {
         LOGE("read_secure_object dlsym fail\n");
@@ -246,7 +246,7 @@
         return ret;
     }
     ret = prepare_tee_session(&ctx);
-
+    LOGE("init end\n");
     return ret;
 }
 
@@ -261,12 +261,14 @@
 #define basic_buf_len  7000
 int32_t gsw_tee_read_secure_data(const char* in_obj_name, char* out_buf, unsigned int* p_out_buf_len)
 {
+    LOGE("start read\n");
     if (in_obj_name == NULL || out_buf == NULL)
     {
         return GSW_HAL_NORMAL_FAIL;
     }
-        
+    
     int32_t ret = 0;
+    size_t size = basic_buf_len;
     char *tmp_buf = (char*)malloc(basic_buf_len);
     if (NULL == tmp_buf)
     {
@@ -274,14 +276,15 @@
         return GSW_HAL_NO_MEMORY;
     }
     
-    TEEC_Result res = read_secure_object(&ctx, in_obj_name, tmp_buf, basic_buf_len);
+    TEEC_Result res = read_secure_object(&ctx, in_obj_name, tmp_buf, &size);
     if (res != TEEC_SUCCESS)
     {
 	LOGE("Failed to read an object from the secure storage");
         ret = GSW_HAL_NORMAL_FAIL;
     }
-    memcpy(out_buf, tmp_buf, strlen(tmp_buf)+1);
-    *p_out_buf_len = strlen(out_buf);
+    LOGE("really start end\n");
+    memcpy(out_buf, tmp_buf, size);
+    *p_out_buf_len = size;
     free(tmp_buf);
     return ret;
 }
@@ -295,6 +298,7 @@
 */
 int32_t gsw_tee_write_secure_data(const char* in_obj_name, char* in_buf, unsigned int in_buf_len)
 {
+    LOGE("write start\n");
     if (in_obj_name == NULL || in_buf == NULL)
         return GSW_HAL_NORMAL_FAIL;
     int32_t ret = 0;
@@ -305,7 +309,7 @@
 	LOGE("Failed to write an object from the secure storage");
         ret = GSW_HAL_NORMAL_FAIL;
     }
-
+    LOGE("write really end\n");
     return ret;
 }
 
@@ -317,6 +321,7 @@
 */
 int32_t gsw_tee_delete_secure_data(const char* in_obj_name)
 {
+    LOGE("delete start\n");
     if (in_obj_name == NULL)
         return GSW_HAL_NORMAL_FAIL;
     int32_t ret = 0;
@@ -327,7 +332,7 @@
 	LOGE("Failed to delete the object: 0x%x", res);
         ret = GSW_HAL_NORMAL_FAIL;
     }
-
+    LOGE("delete really end\n");
     return ret;
 }
 
@@ -341,14 +346,14 @@
     if (in_obj_name == NULL)
         return GSW_HAL_NORMAL_FAIL;
     int32_t ret = 1;
-
+    size_t size = basic_buf_len;
     char *tmp_buf = (char*)malloc(basic_buf_len);
     if (NULL == tmp_buf)
     {
         LOGE("Failed malloc fail");
         return GSW_HAL_NO_MEMORY;
     }
-    TEEC_Result res = read_secure_object(&ctx, in_obj_name, tmp_buf, basic_buf_len);
+    TEEC_Result res = read_secure_object(&ctx, in_obj_name, tmp_buf, &size);
     if (res == TEEC_ERROR_ITEM_NOT_FOUND)
     {
         LOGE("the obj no found\n");
@@ -376,6 +381,7 @@
 */
 int32_t gsw_tee_sdk_deinit(void)
 {
+    LOGE("deinit start\n");
     if (terminate_tee_session) {
         terminate_tee_session(&ctx);  // 终止TEE会话
         terminate_tee_session = NULL;
@@ -390,7 +396,7 @@
         dlclose(dlHandle_mbtk);  // 卸载日志库
         dlHandle_mbtk = NULL;
     }
-
+    LOGE("deinit end\n");
     return GSW_HAL_SUCCESS;
 }
 
