mirror of
https://github.com/torvalds/linux.git
synced 2026-06-08 06:25:52 +02:00
OP-TEE: optimize client application running process
Client applications are forbidden to run before supplicant application is ready. Detection of supplicant application status is added at the entry of open operation. Change-Id: Ief4106bcd75251790b82d76e4d69092900af29e3 Signed-off-by: Elon Zhang <zhangzj@rock-chips.com>
This commit is contained in:
parent
08e8e9538e
commit
78f9f87a9d
|
|
@ -174,6 +174,12 @@ static int tee_supp_open(struct tee *tee)
|
|||
__func__);
|
||||
atomic_sub(1, &tee->rpc->used);
|
||||
}
|
||||
} else {
|
||||
if (atomic_read(&tee->rpc->used) == 0) {
|
||||
ret = -EPERM;
|
||||
dev_err(tee->dev, "%s: ERROR Supplicant application NOT ready\n",
|
||||
__func__);
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user