Embedded study notes (4) Detailed explanation of the startup process of S5PV210

1.9.1 Memory

    SRAM is characterized by small capacity and high price. The advantage is that it can be used directly after power-on without software initialization.

    DRAM is characterized by large capacity and low price. The disadvantage is that it cannot be used directly after power-on and requires software initialization.

1.9.2 External storage

    NorFlash: It is characterized by small capacity and high price. The advantage is that it can be connected to the CPU bus. After the CPU is powered on, it can be read directly, so it is used as a boot medium.

    NandFlash: It is characterized by large capacity and low price. The disadvantage is that the CPU cannot be accessed by the bus, and it needs to be initialized and read and written through the sequential interface.

General PC: very small-capacity BIOS (NorFlash) + large-capacity hard disk (similar to NandFlash) + large-capacity DRAM

General single-chip microcomputer: NorFlash with small capacity + SRAM with small capacity (so no initialization is required, and it can be used after power-on)

General embedded (210): Because NorFlash is very expensive, embedded systems tend not to use NorFlash, but directly use: Nand + DRAM + iRAM (96KB SRAM) + iROM (64KB NorFlash)

1.9.3 The startup process of S5PV210 

The initialization program BL0, BL1 + BL2 in the manufacturer's built-in iROM (boot code u-boot = BL1 + BL2)

    Step 1: After the CPU is powered on, the pre-set code (BL0) runs in the iROM. BL0 is responsible for turning off the watchdog, initializing the cache, setting the stack pointer, and initializing the internal block device copy function (used to quickly convert from nand, nor, SD card and other external storage devices to copy the code to iRAM), copy the first 16KB (BL1) of the boot device to iRAM, confirm whether the code in the boot device is valid (check the checksum byte), etc.

    Step 2: Run BL1 in iRAM, BL1 is responsible for initializing various components of the board, and then load BL2 to iRAM.

    The third step: run BL2 in iRAM, BL2 is responsible for initializing SDRAM, copying the kernel to SDRAM, and then booting the operation of the kernel.

(The above startup process is that uboot is less than 96KB, which is the recommended startup method for 210. In fact, the startup process of our uboot is somewhat different from the startup process here)

For more embedded study notes and practical projects, click here to get free

Guess you like

Origin blog.csdn.net/m0_70888041/article/details/132566976