Skip to content

Commit

Permalink
[BugFix]: enlarge stacksize for ca_triad_tool
Browse files Browse the repository at this point in the history
[Desc]:
1. enalrge stacksize for ca_triad_tool in the qemu.
2. fix right access for comsst ta api

Signed-off-by: pengyinjie <[email protected]>
  • Loading branch information
XMPengYinjie committed Dec 27, 2024
1 parent e7249e7 commit 0ecbb31
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
10 changes: 4 additions & 6 deletions ca/comsst/comsst_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,14 +67,12 @@ int main(int argc, FAR char* argv[])
uint32_t res;
clock_t start = clock();

if (argc == 5 && strcmp(argv[1], "check") != 0) {
if (argc == 5 && strcmp(argv[1], "check") == 0) {
res = is_comsst_data_exited(scope, name, is_deletable);
if (res == 0) {
printf("item is exited.\n");
} else if (res == 0xffff0008) {
printf("item is not exited.\n");
printf("item is notexisted.\n");
} else {
printf("item check fail.\n");
printf("item isexisted\n");
}
} else if (argc == 5 && strcmp(argv[1], "delete") == 0) {
if (comsst_data_delete(scope, name, is_deletable) == 0) {
Expand Down Expand Up @@ -105,7 +103,7 @@ int main(int argc, FAR char* argv[])
if (res == 0) {
printf("item verify successfully.\n");
} else if (res == 0xffff0008) {
printf("item is not exited.\n");
printf("item is notexisted.\n");
} else {
printf("item verify failed.\n");
}
Expand Down
2 changes: 1 addition & 1 deletion ca/triad/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ config CA_TRIAD_TOOL_PRIORITY

config CA_TRIAD_TOOL_STACKSIZE
int "Triad test stack size"
default DEFAULT_TASK_STACKSIZE
default 4096
endif

endif
4 changes: 2 additions & 2 deletions ta/comsst/comsst_ta.c
Original file line number Diff line number Diff line change
Expand Up @@ -184,13 +184,13 @@ static TEE_Result Comsst_DeleteItem(uint32_t param_types __unused,
res = TEE_OpenPersistentObject(TEE_STORAGE_PRIVATE,
params[1].memref.buffer,
params[0].value.a,
TEE_DATA_FLAG_ACCESS_READ,
TEE_DATA_FLAG_ACCESS_WRITE_META,
&obj);
} else {
res = TEE_OpenPersistentObject(TEE_STORAGE_USER,
params[1].memref.buffer,
params[0].value.a,
TEE_DATA_FLAG_ACCESS_READ,
TEE_DATA_FLAG_ACCESS_WRITE_META,
&obj);
}

Expand Down

0 comments on commit 0ecbb31

Please sign in to comment.