NBOOT启动至BOOTLOADER之前
2010-10-14 09:43
211 查看
S3C2440A boot code can be executed on an external NAND flash memory. In order to support NAND flash bootloader, the S3C2440A is equipped with an internal SRAM buffer called "Steppingstone". When booting, the first 4KBytes of the NAND flash memory will be loaded into Steppingstone and the boot code loaded into Steppingstone will be executed.
Generally, the boot code will copy NAND flash content to SDRAM. Using hardware ECC generating, the NAND flash data validity will be checked. Upon the completion of the copy, the main program will be executed on the SDRAM.
2440的启动代码可以从外部的nandflash上执行。为了能支持nboot,2440需要带有一个叫steppingstone的内部sram缓冲区。在启动加载的时候,nandflash的前4k的内容(nboot部分)要被先load到steppingstone中去(此时steppingstone被映射为物理地址的0x0,复位后执行的第一条指令就是从这里取的),然后在steppingstone中去执行该启动代码。这部分代码(nboot)的作用是会将nandflash中的bootloader step2部分(Eboot OR uboot)拷贝到sdram中去,并跳到sdram中去执行以加载内核(nk)。
nboot从nandflash被load到steppingstone中的过程为:在上电的时候,nandflash控制器通过几个引脚的状态(NCON-Adv flash;GPG13-Page size;GPG14-Address cycle;GPG15-Bus width)来得到nandflash的相关信息,之后nandflash控制器就会自动load nandflash中前4k的启动代码到steppingstone中去,并在其中执行了。
不管是uboot还eboot在执行之前都要执行nboot(至少在smdk上是这样的)。在设备上电后首先要跳到nboot中,之后nboot做一些初始化操作(和uboot和eboot中的差不多),将指定block上的uboot或者eboot拷贝到内存中指定的地址去,在这里的操作都是用的物理地址。
stepldr流程(NBOOT)分为以下几步:
①SetupCopySection(pTOC)
②MMU_EnableICache()——使能ICache
③Port_Init()——GPIO端口初始化
④Uart_Init()——初始化UART(调试端口)
⑤NF_Init()——初始化nand flash接口
⑥将Image从flash拷贝到RAM
⑦((PFN_IMAGE_LAUNCH)(LOAD_ADDRESS_PHYSICAL))()——跳转
参考资料:
wince6.0+s3c2443启动之NBOOT: http://blog.csdn.net/chinesedragon2010/archive/2010/08/14/5811524.aspx
NBOOT startup.s汇编详细介绍:http://cky0612.blog.163.com/blog/static/27478916201012515110914/
EBOOT startup.s汇编详细介绍:
http://blog.csdn.net/chinesedragon2010/archive/2010/09/20/5895956.aspx
http://blog.csdn.net/chinesedragon2010/archive/2010/10/03/5919717.aspx
http://blog.csdn.net/chinesedragon2010/archive/2010/10/05/5922489.aspx
http://blog.csdn.net/chinesedragon2010/archive/2010/10/12/5936777.aspx
Generally, the boot code will copy NAND flash content to SDRAM. Using hardware ECC generating, the NAND flash data validity will be checked. Upon the completion of the copy, the main program will be executed on the SDRAM.
2440的启动代码可以从外部的nandflash上执行。为了能支持nboot,2440需要带有一个叫steppingstone的内部sram缓冲区。在启动加载的时候,nandflash的前4k的内容(nboot部分)要被先load到steppingstone中去(此时steppingstone被映射为物理地址的0x0,复位后执行的第一条指令就是从这里取的),然后在steppingstone中去执行该启动代码。这部分代码(nboot)的作用是会将nandflash中的bootloader step2部分(Eboot OR uboot)拷贝到sdram中去,并跳到sdram中去执行以加载内核(nk)。
nboot从nandflash被load到steppingstone中的过程为:在上电的时候,nandflash控制器通过几个引脚的状态(NCON-Adv flash;GPG13-Page size;GPG14-Address cycle;GPG15-Bus width)来得到nandflash的相关信息,之后nandflash控制器就会自动load nandflash中前4k的启动代码到steppingstone中去,并在其中执行了。
不管是uboot还eboot在执行之前都要执行nboot(至少在smdk上是这样的)。在设备上电后首先要跳到nboot中,之后nboot做一些初始化操作(和uboot和eboot中的差不多),将指定block上的uboot或者eboot拷贝到内存中指定的地址去,在这里的操作都是用的物理地址。
stepldr流程(NBOOT)分为以下几步:
①SetupCopySection(pTOC)
②MMU_EnableICache()——使能ICache
③Port_Init()——GPIO端口初始化
④Uart_Init()——初始化UART(调试端口)
⑤NF_Init()——初始化nand flash接口
⑥将Image从flash拷贝到RAM
⑦((PFN_IMAGE_LAUNCH)(LOAD_ADDRESS_PHYSICAL))()——跳转
参考资料:
wince6.0+s3c2443启动之NBOOT: http://blog.csdn.net/chinesedragon2010/archive/2010/08/14/5811524.aspx
NBOOT startup.s汇编详细介绍:http://cky0612.blog.163.com/blog/static/27478916201012515110914/
EBOOT startup.s汇编详细介绍:
http://blog.csdn.net/chinesedragon2010/archive/2010/09/20/5895956.aspx
http://blog.csdn.net/chinesedragon2010/archive/2010/10/03/5919717.aspx
http://blog.csdn.net/chinesedragon2010/archive/2010/10/05/5922489.aspx
http://blog.csdn.net/chinesedragon2010/archive/2010/10/12/5936777.aspx
相关文章推荐
- bootloader的启动 from rom code to uboot
- 【嵌入式开发】 Bootloader 详解 ( 代码环境 | ARM 启动流程 | uboot 工作流程 | 架构设计)
- 【嵌入式开发】 Bootloader 详解 ( 代码环境 | ARM 启动流程 | uboot 工作流程 | 架构设计)
- Bootloader及u-boot简介/u-boot系统启动流程
- Bootloader U-boot启动
- bootloader 之U-Boot启动trace
- 正式学习bootloader,基于u-boot1.1.4(启动流程框架)
- 嵌入式启动顺序 - uboot之前
- bootloader详解----u-boot启动的2个阶段
- Bootloader/u-boot的启动模式
- 正式学习bootloader,基于u-boot1.1.4(启动流程框架)
- Uboot学习笔记②---(bootloader的一些共同特性、uboot启动过程、编译环境、地址规划设计)
- 高通Qualcomm平台lk(light kernel)启动流程1——aboot_init()之前
- 正式学习bootloader,基于u-boot1.1.4(启动流程框架)
- arm-linux内核start_kernel之前启动分析(1)-接过bootloader的衣钵
- Android 启动之 Bootloader(uboot)
- 深入理解 bootloader 启动linux atags/boot param 传递
- 三。把bootloader(uboot)、内核(zImage)、根文件系统(rootfs)都写到开发板上。nand启动方式
- Linux中关于 -- Bootloader , Uboot的作用,和整个linux系统的启动过程分析
- arm-linux内核start_kernel之前启动分析(1)-接过bootloader的衣钵