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.

[参考译文] TMS570LC4357:TMS570LC43xx -启动- HalcogGen

Guru**** 2471280 points


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

https://e2e.ti.com/support/microcontrollers/arm-based-microcontrollers-group/arm-based-microcontrollers/f/arm-based-microcontrollers-forum/980846/tms570lc4357-tms570lc43xx---startup---halcogen

器件型号:TMS570LC4357

尊敬的团队:

使用函数 coreInitRegisters (hL_sys-core.asm)、将通过系统模式写入 spsr 寄存器

根据 ARM DDI 0460C Cortex-R5和 Cortex-R5F 技术参考手册、这在系统和用户模式中不存在

您能否简单地向我解释一下为什么仍然写入启动代码中的寄存器? 这是启动代码中的错误吗? 或者、您甚至必须写入寄存器吗? 如果寄存器甚至不存在、您写什么?

谢谢、此致

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

    您好 Sebastian、

    是的、这是一个软件错误。 由于系统和用户模式没有 SPSR、所以您发布的代码的最后两行是不必要的。

    当 CPU 模式为系统模式时、可移除下面的2行。