In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-03 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/02 Report--
Read how ARM devices start the Linux kernel uboot through uboot and the kernel is a bare metal program.
(1) the essence of uboot is a more complicated bare metal program, which is not essentially different from the bare metal program written in ARM.
(2) the kernel itself is also a bare-metal program, which is not essentially different from uboot and bare-metal programs. The difference is that after the kernel is running, it is divided into kernel layer and application layer in software. after layering, the permissions of the two layers are different, and the management of memory access and device operation is more elaborate (the kernel can access all kinds of hardware at will. Applications can only have restricted access to hardware and memory addresses).
(3) intuitively, the image of uboot is u-boot.bin, and the image of linux system is zImage. These two things are actually two images of bare metal programs. From the system startup point of view, the kernel is actually a large and complex bare metal program.
Deployed in a specific partition of the SD card
(1) A complete embedded system of software and hardware, bootloader, kernel, rootfs and other necessary software are stored in the boot medium in the form of mirror image (iNand/ SD card in x210) when at rest (when not powered on), and run in DDR memory and have nothing to do with the storage media. The above two states are stable, and the third state is a dynamic process, that is, the process from the static state to the running state, that is, the start-up process.
(2) the dynamic startup process is to gradually move from the SD card to the DDR memory, and run the startup code to initialize the hardware and establish the software architecture, and finally reach a stable state at run time.
(3) when at rest, u-boot.bin, kernel and rootfs are all in the SD card, and they cannot exist anywhere in the SD card at will, so it is necessary to partition the SD card, and then store various images in different partitions, so that the uboot and the kernel will know where to find them during startup. (the partition tables in uboot and kernel must be consistent with the actual partitions used by SD cards)
The runtime must first be loaded into the link address in DDR
(1) when uboot relocates in the first phase, the second phase (the entire uboot) is loaded into the 0xC3E00000 address of DDR, which is the link address of uboot.
(2) the kernel has similar requirements. When uboot starts the kernel, the kernel is read from the SD card and put into the DDR (actually a process of repositioning). It cannot be placed at will, but must be placed at the link address of the kernel, otherwise it will not start. For example, the kernel link address used in x210 is 0x30008000.
Necessary parameters are required for kernel startup
(1) uboot starts unconditionally and starts from scratch.
(2) the kernel cannot be booted automatically and completely from scratch, and the kernel needs help to start. Uboot needs to help the kernel to relocate (from SD card to DDR), and uboot also provides startup parameters to the kernel.
Original address of this article: https://www.linuxprobe.com/uboot-image.html
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 235
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.