DSP

OMAPL138的启动顺序

2019-07-13 11:57发布

#Bootloader
Bootloader为存储在ROM中的启动代码(一些程序),由TI在芯片出厂时以掩膜方式固化内容。
TI使用ROM空间的一部分,还有一部分剩余空间,用户可以委托TI写入(掩模)所需代码。 ##版本 OMAPL138的Bootloader保存在ROM中,检查内存地址0xFFFD0000,在memory window中选择Character,在偏移地址0x08可以读到版本号:版本号为类似于d800k008
##启动模式 启动模式分为两种
  • Master
    从各种内存启动
  • Slave
    从外部Master启动
除了HPI (Host Port Interface)和2种NOR (Parallel Flash) boot模式,其他模式均使用AIS(Application Image Script)格式。
管脚配置详见Using the OMAP-L132/L138 Bootloader Appendix A Boot Mode Selection Table ##启动顺序
OMAP-L138 SOC 的启动详解
OMAP-L138 的ROM内有DSP 与ARM两份启动代码,芯片上电解复位后,DSP Bootloader 先运行,通过PRU 加载ARM初始化代码,因为DSP 不能访问ARM的片上RAM空间,所以这一步通过PRU 完成,然后DSP 通过PSC 使能ARM,运行ARM的Bootloader, ARM再将DSP 置于复位态,并关闭其时钟。这个过程由芯片内部ROM 代码自动完成,所以从用户的角度,芯片就是从ARM 开始启动的。
ARM Bootloader 读取BOOTCFG 寄存器,获取用户设定的启动模式,然后从相应的外设搬移用户代码到相应的地址,跳转到用户代码的入口地址,完成SOC 的启动过程。
下面这段话未找到出处文档
When the device is powered on, it starts execution from DSP ROM. ARM is in in the disable state at this moment. The DSP ROM code will Read certain registers to know that ARM is present. (Otherwise it will be a DSP-only boot) Program PDSP0 to prepare for ARM reset vector. Bring ARM out of reset and let ARM starts execution from its ROM. (Yes, that’s the main difference from OMAPL137 silicon 1.x. ARM has its own ROM and will master the boot process afterwards) DSP stills in the idle loop. ARM starts execution from its ROM. It will Put DSP into disable state (probably local reset). Initialize HW, i.e. PSC, PLL, external memory etc. Read bootcfg registers to decide what boot mode it will be and load and run ARM UBL from appropriate boot media, i.e. SPI flash, NAND, NOR etc. ARM UBL starts running. Its behavior is totally defined by the SW. For example, TI provided ARM UBL will load and run UBOOT which will further load and run Linux. The Linux application can load and run DSP.out via DSPLINK. This model is the same as DaVinci model. Industrial customers can choose to load and run a DSP AIS image in certain boot media. Meanwhile ARM UBL also starts booting UBOOT and Linux. In that way, DSP can start processing data before Linux finishing boot.

#主要内存地址的Memory Map ARM可以访问全部地址空间,DSP不能访问ARM的内存空间。
  • DSP (C674x)
    |Section |Size | Start| End |
    |—|---