Ground Embedded KO Subscribe

Notes / Embedded Linux

Boot process: from power-on to login

It comes up in the order boot ROM, U-Boot, Linux kernel, root file system, init. Knowing where it stopped narrows the problem.

GROUND EMBEDDED · NOTEEmbedded Linux 03Boot sequence 1$ make ARCH=arm 2$ insmod gnd_gpio.ko 3[ 1.024] gnd: probe ok 4$ cat /dev/gnd0 50x5A 6$ _
Stage What it does How to check
1. Boot ROM Built into the chip. Loads the first loader from SD/eMMC/USB according to boot pins or fuses No serial output is often normal
2. SPL / first-stage loader Initialises DRAM The "U-Boot SPL" message
3. U-Boot Loads the kernel, device tree and initramfs into memory and runs them The U-Boot prompt
4. Kernel Initialises hardware, loads drivers, mounts the root file system dmesg messages
5. init (systemd and others) Starts services The login prompt
ROM codeBootloaderU-BootKernelMount root file systeminit → login
What runs, in order, after power-on.

The serial console is your lifeline

Keep the board's debug UART connected to the PC through a USB-serial adapter and you can see at once which stage it stopped at. Serial works even when the network does not come up.

What you can do in U-Boot

  • Change the kernel arguments (bootargs) through environment variables
  • Fetch the kernel over the network with TFTP and boot it → no need to rewrite the SD card on every build
  • Test memory and storage

Shortening the boot time

Remove unneeded drivers and services, change the kernel compression method, and show a splash in the U-Boot stage if you need a fast display. For automotive Linux, boot optimisation matters because of functions that must be up within a few seconds, such as the rear-view camera.

FREE PDFGet the 3 free ebooksIf you want to keep reading this topic as one book: BLDC motor control, serial communication and sensors at book length. PDFs are in Korean.Get them free →