Skip to content

Commit 3301c45

Browse files
oleksiimoisieievnashif
authored andcommitted
tests: drivers: tee: Fix normal_call behaviour in tests
During SMC_RPC_FUNC_ALLOC call optee driver puts new shm object to a4 and a5 variables and then expects this object to be in a1 and a2 from OP-TEE OS. Fixed behaviour so normal_call callback will act the same way as OP-TEE OS Signed-off-by: Oleksii Moisieiev <[email protected]>
1 parent 92408c0 commit 3301c45

File tree

1 file changed

+4
-4
lines changed
  • tests/drivers/tee/optee/src

1 file changed

+4
-4
lines changed

tests/drivers/tee/optee/src/main.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -246,11 +246,11 @@ void normal_call(unsigned long a0, unsigned long a1, unsigned long a2, unsigned
246246
switch (t_call.num) {
247247
case 0:
248248
res->a0 = OPTEE_SMC_RETURN_RPC_PREFIX | OPTEE_SMC_RPC_FUNC_ALLOC;
249-
res->a1 = a1;
250-
res->a2 = a2;
249+
res->a1 = a4;
250+
res->a2 = a5;
251251
res->a3 = a3;
252-
res->a4 = a4;
253-
res->a5 = a5;
252+
res->a4 = 0;
253+
res->a5 = 0;
254254
break;
255255
case 1:
256256
zassert_equal(a0, 0x32000003, "%s failed with ret %lx", __func__, a0);

0 commit comments

Comments
 (0)