lib: avb: close optee client

Change-Id: Iee7c991f7c06acbb064e016e11338cbf846be20d
Signed-off-by: Jason Zhu <jason.zhu@rock-chips.com>
This commit is contained in:
Jason Zhu 2017-11-02 15:46:52 +08:00 committed by Kever Yang
parent 468df3b26a
commit 52b8c717cf
2 changed files with 16 additions and 0 deletions

View File

@ -215,4 +215,13 @@ int avb_read_vbootkey_hash(uint8_t *buf, uint8_t length);
*/
int avb_write_vbootkey_hash(uint8_t *buf, uint8_t length);
/**
* U-boot close the optee client when start kernel
* to prevent the optee client being invoking by other
* program.
*
* @return 0 if the command succeeded, -1 if it failed
*/
int avb_close_optee_client(void);
#endif

View File

@ -459,3 +459,10 @@ int avb_write_vbootkey_hash(uint8_t *buf, uint8_t length)
return -1;
return 0;
}
int avb_close_optee_client(void)
{
if(trusty_notify_optee_uboot_end())
return -1;
return 0;
}