edk2-rk3576

Architecture

English 简体中文

How the tree is put together, and why.

Boot chain

BootROM -> U-Boot SPL -> TF-A BL31 -> EDK2 (BL33) -> OS

The prebuilt inputs and how each was built are in binaries/README.md.

Layout

Platform/ArmSoM/CM5IO/       board package: DSC, PMIC/GPIO/PHY glue, ACPI, DTS
Platform/Radxa/ROCK4D/
Platform/LCKFB/TaishanPi3M/
Silicon/Rockchip/RK3576/     SoC package: RK3576Base.dsc.inc, FDF, ACPI, drivers
Silicon/Rockchip/            drivers shared across Rockchip SoCs
Silicon/Synopsys/DesignWare/ DWC EQoS and DWC MMC
boards/                      one .conf per board, read by the scripts
scripts/                     setup-host, build, package; serial and KD helpers
patches/                     patches to the TianoCore core, applied at setup
binaries/                    BL31, DDR init blob, SPL
devicetree/                  board DTS (mainline-based), vendor DTBs
docs/                        the site at edk2.gahingwoo.com

Board and SoC split

A board DSC holds only what differs between boards: which devices exist, GPIOs, PMIC and PHY glue, defaults of setup options, the ACPI DSDT and the device tree. Everything the SoC decides is in Silicon/Rockchip/RK3576/RK3576Base.dsc.inc and RK3576.fdf.

The RK3576 package is standalone, not layered on RK3588’s configuration, because inherited RK3588 values (memory map, I2C addresses, reset IDs) were wrong for RK3576. The older layered tree is on the legacy/v0.1 branch.

ACPI and device tree

The CM5-IO and the TaishanPi 3M install ACPI tables and a device tree side by side, so Windows uses ACPI and Linux the device tree. The ROCK 4D builds the device tree only. Details: ACPI.

The device tree handed to Linux is the firmware’s own, built from devicetree/mainline/, with fix-ups at boot (FdtPlatformDxe): for example the DSI panel and backlight on the TaishanPi 3M when the screen is attached, a simple-framebuffer node when “Force UEFI GOP Display” is on, and always-on USB-A VBUS supplies.

Core patches

third_party/edk2 is tianocore/edk2 pinned to edk2-stable202602. Changes to it are patch files in patches/, applied by setup-host.sh, because edits in the submodule are lost when it is reset. Each patch is described in patches/README.md.