This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] AM625:keyrev - tisci 错误

Guru**** 2390755 points


请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1500124/am625-keyrev---tisci-error

器件型号:AM625

工具/软件:

您好、

我一直在尝试对安全器件上的 KEYREV 值进行现场升级、以适应需要使主密钥无效的情况。

我创建了用户区代码来进行调用、并与我创建的 PTA 进行通信;然后、PTA 在 plat-k3驱动程序中进行调用。

'stock' plat-k3驱动程序没有调用 TI_SCI_MSG_WRITE_KEYREV 函数的例程,所以我已经"滚动了自己的"。

我已经按照 运行时读/写 KEYREV 和 SWREV—TISCI 用户指南中所述创建了证书、我已经尽可能地检查了参数-但我总是收到错误消息、并在下面附上日志。  

"你是什么人?

在下面附加日志驱动程序片段、

Error log below
---------------------------------------------------------
D/TC:? 0 ti_sci_set_keyrev:494 inside ti_sci_set_keyrev
F/TC:? 0 k3_sec_proxy_send:131 Verifying the thread
F/TC:? 0 k3_sec_proxy_verify_thread:71 Check for thread corruption
F/TC:? 0 k3_sec_proxy_verify_thread:88 Check for thread direction
F/TC:? 0 k3_sec_proxy_verify_thread:100 Check for thread queue
F/TC:? 0 k3_sec_proxy_verify_thread:113 Success
F/TC:? 0 k3_sec_proxy_recv:193 Verifying thread
F/TC:? 0 k3_sec_proxy_verify_thread:71 Check for thread corruption
F/TC:? 0 k3_sec_proxy_verify_thread:88 Check for thread direction
F/TC:? 0 k3_sec_proxy_verify_thread:100 Check for thread queue
F/TC:? 0 k3_sec_proxy_verify_thread:113 Success
D/TC:? 0 ti_sci_get_response:120 Message not acknowledged
D/TC:? 0 ti_sci_set_keyrev:510 ti_sci_do_xfer failed ffff0001
D/TC:? 0 write_otp_keyrev:140 ti_sci_set_keyrev ffff0001
D/TC:? 0 tee_ta_invoke_command:788 Error: ffff0001 of 4
otpread: F/TC:? 0 plat_prng_add_jitter_entropy:72 0xB7
Invoke command failed with code 0xffff0001 origin 0x4
D/TC:? 0 tee_ta_close_session:460 csess 0x9e8958a0 id 2
D/TC:? 0 tee_ta_close_session:479 Destroy session


---------------------------------------------------->
int ti_sci_set_keyrev(uint32_t key_rev, uint32_t cert_addr_lo, uint32_t cert_addr_hi)
{
    struct ti_sci_msg_req_set_keyrev req = { };
    struct ti_sci_msg_resp_set_keyrev resp = { };
    struct ti_sci_xfer xfer = { };
    int ret = 0;
 
 
 
    DMSG("inside ti_sci_set_keyrev");
    ret = ti_sci_setup_xfer(TI_SCI_MSG_WRITE_KEYREV, 0,
              &req, sizeof(req), &resp, sizeof(resp), &xfer);
 
    if (ret) {
        DMSG("ti_sci_setup_xfer failed %x", ret);
        return ret;
       }
 
 
    req.value = key_rev;
    req.cert_addr_lo = cert_addr_lo;
    req.cert_addr_hi = cert_addr_hi;
    
    ret = ti_sci_do_xfer(&xfer);
    if (ret) {
        DMSG("ti_sci_do_xfer failed %x", ret);
        return ret;
       }
    memzero_explicit(&resp, sizeof(resp));
    memzero_explicit(&req, sizeof(req));
    return ret;
    /*@rj*/
}

此致、

- RJ