regression 1029 (thread local storage): accept TEE_ERROR_NOT_SUPPORTED
The Thread Local Storage test (__thread attribute) is modified to accept
TEE_ERROR_NOT_SUPPORTED without failing. This return value will be used
in a later commit in case an unsupported compiler is used to build the
TA.
Signed-off-by: Jerome Forissier <jerome@forissier.org>
Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
Acked-by: Etienne Carriere <etienne.carriere@linaro.org>
diff --git a/host/xtest/regression_1000.c b/host/xtest/regression_1000.c
index 5cc4d64..105baef 100644
--- a/host/xtest/regression_1000.c
+++ b/host/xtest/regression_1000.c
@@ -2202,6 +2202,7 @@
static void xtest_tee_test_1029(ADBG_Case_t *c)
{
+ TEEC_Result res = TEEC_SUCCESS;
TEEC_Session session = { 0 };
uint32_t ret_orig = 0;
@@ -2211,15 +2212,23 @@
return;
Do_ADBG_BeginSubCase(c, "TLS variables (main program)");
- ADBG_EXPECT_TEEC_SUCCESS(c,
- TEEC_InvokeCommand(&session, TA_OS_TEST_CMD_TLS_TEST_MAIN, NULL,
- &ret_orig));
+ res = TEEC_InvokeCommand(&session, TA_OS_TEST_CMD_TLS_TEST_MAIN, NULL,
+ &ret_orig);
+ if (res == TEEC_ERROR_NOT_SUPPORTED)
+ Do_ADBG_Log(" - 1029 - skip test, "
+ "TA returned TEEC_ERROR_NOT_SUPPORTED");
+ else
+ ADBG_EXPECT_TEEC_SUCCESS(c, res);
Do_ADBG_EndSubCase(c, "TLS variables (main program)");
Do_ADBG_BeginSubCase(c, "TLS variables (shared library)");
- ADBG_EXPECT_TEEC_SUCCESS(c,
- TEEC_InvokeCommand(&session, TA_OS_TEST_CMD_TLS_TEST_SHLIB,
- NULL, &ret_orig));
+ res = TEEC_InvokeCommand(&session, TA_OS_TEST_CMD_TLS_TEST_SHLIB, NULL,
+ &ret_orig);
+ if (res == TEEC_ERROR_NOT_SUPPORTED)
+ Do_ADBG_Log(" - 1029 - skip test, "
+ "TA returned TEEC_ERROR_NOT_SUPPORTED");
+ else
+ ADBG_EXPECT_TEEC_SUCCESS(c, res);
Do_ADBG_EndSubCase(c, "TLS variables (shared library)");
TEEC_CloseSession(&session);