ARM Linux 重启过程 [英] ARM Linux reboot process

查看:48
本文介绍了ARM Linux 重启过程的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

重启程序如何在运行 Linux 的 ARM SOC 上工作,例如引导加载程序是否重新初始化 DDR 内存?谁能详细解释一下重启过程.

How reboot procedure works on ARM SOCs running Linux, e.g do boot loaders reinitialize DDR memory? can anybody please explain me rebooting process in detail.

推荐答案

这太宽泛了.这不仅取决于 SoC 供应商,还取决于硬件和软件.

This is way too broad. It's not only SoC vendor dependent, but also hardware and software dependent.

但是,最典型的设置是:

  1. CPU 执行第一阶段引导加载程序 (FSB).

  1. CPU executes first-stage bootloader (FSB).

FSB 位于芯片本身的 ROM 或 EEPROM 中并且非常小(AT91RM9200 FSB 最大为 10kB,AFAIR).然后 FSB 初始化最小外设集(时钟、RAM、闪存),将第二阶段引导加载程序 (U-Boot) 传输到 RAM,并执行它.

FSB is located on the chip itself in ROM or EEPROM and is very small (AT91RM9200 FSB is 10kB max, AFAIR). FSB then initializes minimum set of peripherals (clocks, RAM, flash), transfers second-stage bootloader (U-Boot) to RAM, and executes it.

U-Boot 启动.

U-Boot 初始化一些其他硬件(串行、以太网等),将 Linux 内核传输到 RAM,准备指向内核输入参数的指针并跳转到它的入口点.

U-Boot initializes some other hardware (serial, ethernet, etc), transfers Linux kernel to RAM, prepares the pointer to kernel input parameters and jumps into it's entry point.

Linux 内核启动.

Linux kernel starts.

魔法在这里发生.系统现在可以通过 SSH 控制台为您提供 cookie 和/或执行任何需要执行的操作.

Magic happens here. The system now able to serve you cookies via SSH console and/or executes whatever needs to be executed.

关于热启动的更深入信息:

A bit more in-depth info about warm start:

热启动是软件复位,而冷启动是上电或硬件复位.一些(大多数?)SoC 能够将有关热启动的信息传递给 FSB/SSB.通过这种方式,引导加载程序能够跳过对已初始化外围设备的重新初始化,从而最大限度地缩短总体引导时间.

Warm start is a software reset, while cold start is power-on or hardware reset. Some (most?) SoC's are able to pass the info to FSB/SSB about warm start. This way bootloaders are able to minimize the overall boot time by skipping re-initializion of already initialized peripherals.

同样,这是我 15 年以上嵌入式领域经验中最典型的设置.

Again, this is most typical setup from my 15+ years experience in embedded world.

这篇关于ARM Linux 重启过程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆