(2)s5pv210启动过程

11 篇文章 0 订阅

一、IROM和IRAM
IROM(内部ROM)和IRAM(内部RAM)均为不需要初始化就可以启动的静态内存。现在来看一张图,IROM和IRAM的信息就一目了然了:
在这里插入图片描述
如上图所示,IROM和IRAM均是在s5pv210内部的,IROM大小为64KB(BL0中为固化代码),IRAM为96KB(BL1/BL2:可以可变大小从引导设备复制到内部SRAM区域。BL1最大。大小为16KB。BL2最大。大小为80KB)。
原文:
① iROM can do initial boot up : initialize system clock, device specific controller and booting device.
② iROM boot codes can load boot-loader to SRAM. The boot-loader is called BL1.
then iROM verify integrity of BL1 in case of secure boot mode.
③ BL1 will be executed: BL1 will load remained boot loader which is called BL2 on the SRAM
then BL1 verify integrity of BL2 in case of secure boot mode.
④ BL2 will be executed : BL2 initialize DRAM controller then load OS data to SDRAM.
⑤ Finally, jump to start address of OS. That will make good environment to use system.
译文:
1、IROM可以进行初始引导:初始化系统时钟、设备专用控制器和引导设备。
2 、IROM引导代码可以将引导加载程序加载到SRAM。引导加载程序称为BL1。然后,在安全引导模式的情况下,IROM验证BL1的完整性。
3、将执行BL1:在安全引导模式的情况下,BL1将在SRAM上加载名为BL2的剩余引导加载程序,然后BL1验证BL2的完整性。
4、将执行BL2:BL2初始化DRAM控制器,然后将操作系统数据加载到SDRAM。
5、最后,跳转到操作系统的起始地址。这将为系统的使用创造良好的环境。

二、启动顺序
系统刚启动时,会运行IROM中的固化代码(存放在BL0中),进行一些通用的初始化,具体步骤包括:
原文:
iROM(BL0) boot-up sequence (Refer 2.3 V210 boot-up diagram)
1.Disable the Watch-Dog Timer
2.Initialize the instruction cache
3.Initialize the stack region (see “memory map” on chap 2.5)
4.Initialize the heap region. (see “memory map” on chap 2.5)
5.Initialize the Block Device Copy Function. (see “Device Copy Function” on chap 2.7)
6.Initialize the PLL and Set system clock. (see “clock configuration” on chap 2.11)
7.Copy the BL1 to the internal SRAM region (see “Device Copy Function” on chap 2.7)
8.Verify the checksum of BL1.
If checksum fails, iROM will try the second boot up. (SD/MMC channel 2)
9.Check if it is secure-boot mode or not.
If the security key value is written in S5PV210, It’s secure-boot mode.
If it is secure-boot mode, verify the integrity of BL1.
10.Jump to the start address of BL1 .
译文(非直接翻译,以下为总结内容):
第一步 关闭看门狗;
第二步 初始化 icache;
第三步 初始化堆栈;
第四步 设置时钟;
第五步 判断启动设备(nand/sd/onenand 等),检查校验和,然后从启动设备中拷贝前 16K 的代码
到 IRAM 的 0xD0020000 处(此处用就是指SD卡启动,需要16K的头,也就是(1)汇编点亮LED中mkv210_image.c所做的工作,将led.bin添加16k的校验头生成210.bin);
第六步 若是安全模式启动,则进行完整性检查;
第七步 跳转到 IRAM 的 0xD0020010 地址上继续运行;

开机示意图:
在这里插入图片描述
在这里插入图片描述
上图红色线路是睡眠启动线路。
Tiny210 支持 SD 卡和 Nand Flash 两种启动模式,通过 S2来进行切换启动模式。

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值