Purpose
Upon power up, hardware usually starts uninitialized. To continue booting, the system may need to read a bootloader from some peripheral device. It is often easier to implement routines for reading from external storage devices in software than in hardware. A boot ROM provides a place to store this initial loading code, at a fixed location immediately available to the processor when execution starts.Operation
The boot ROM is mapped into memory at a fixed location, and the processor is designed to start executing from this location after reset, according to the processor's reset vector. The boot ROM is either placed on the same die as the CPU or is an external ROM chip. On modern systems, the boot ROM (whether integrated into CPU or external ROM chip) usually uses NOR flash, which supports execute in place. The boot ROM will then initialize the hardware busses and peripherals needed to boot. In some cases, the boot ROM is capable of initializing RAM, and in other cases it is up to the bootloader to do that. At the end of the hardware initialization, the boot ROM will try to load a bootloader from external peripheral(s) (such as aSuspend to RAM
When aSpecific implementations
Allwinner
On many Allwinner systems on a chip (A10, A20, A64), the boot ROM either waits for a bootloader to be loaded through USB (if a specific PIN is high) or tries to boot on several peripherals in a fixed order. Some Allwinner systems on a chip can verify the signature of the booloaders. But most devices being manufactured are not configured for that. This has enabled free and open-source software to add support for many Allwinner systems on a chip and devices using them in bootloaders like U-Boot.Apple
On iPhone, iPad, Apple Watch, iPod Touch, and Apple TV devices, the boot ROM is called "SecureROM" It is a stripped-down version of iBoot. It provides a Device Firmware Upgrade (DFU) mechanism, which can be activated using a special button combination.NXP
The boot ROM of NXP systems on a chip (SOCs) support configuring the peripherals through specific pins of the system on a chip. On the i.MX6 family it also supports configuring the boot order through eFuses. The boot ROM of several NXP SoCs have many ways to load the first stage bootloader (from eMMC, microSD, USB, etc.). Several NXP SoCs can be configured to verify the signature of the bootloaders. Many devices with such SoCs were sold without that verification configured and on those devices users can install the bootloader they want, including several free and open-source software bootloaders like Das U-Boot and Barebox.Texas Instruments
The boot ROMs of several Texas Instruments systems on a chip support configuring the peripherals through specific pins of the system on a chip. They have many ways to load the first stage bootloader (which is called MLO in the systems on a chip reference manuals): * It can be loaded from various storage devices (MMC/SD/eMMC, NAND, etc.). * With MMC/SD/eMMC, it can be loaded directly from card sectors (called RAW mode in the manual) or from a FAT12/16/32 partition. * It can also be loaded from USB or UART. On the OMAP36xx system on a chip, the boot ROM looks for the first stage bootloader at the sectors 0x0 and 0x20000 (128KB), and on the AM3358STMicroelectronics
STMicroelectronics STM32 family microcontrollers have embedded ROM (also referred as "on-chip ROM") called ''system memory'' to facilitate empty system flashing. Certain pin combinations or sometimes efuses and/or empty flash checks force the chip to boot from ROM instead of the firmware in main flash. This allows empty chips to be flashed without resorting to hardware programming interfaces. Technically this ROM is stored in a dedicated area of the flash array and programmed by ST during production. Most STM32 microcontrollers can at least be flashed over UART, some support USB and eventually other interfaces like e.g. I2C, SPI, or CAN. The Cortex-M core normally fetches vectors from the well-known addresses 0x00000000 (initial stack pointer value) and 0x00000004 (initial program counter value). However pins and/or fuses define which memory is mapped at these addresses. System memory is one of the mapping options, another would typically be main firmware in flash. In this case, firmware is supposed to do all the jobs boot ROMs do; part of the firmware could act as a bootloader similar to ST's boot ROM. Hardware could provide read-only enforcement on the boot area, turning it into a user-provided version of boot ROM.Security
Apple
On devices running iOS, boot ROM exploits (like the limera1n, alloc8, and checkm8 exploits) are sometimes used for iOS jailbreaking. The advantage for people wanting to jailbreak their devices over exploits that affect iOS is that since the boot ROM cannot be modified—and that devices running iOS do not have fuses to append code to the boot ROM, Apple cannot fix the vulnerability on existing devices.Nvidia Tegra
The boot ROM of the Tegra SoC of Nvidia (used by the Nintendo Switch) contained a vulnerability which made it possible for users to run the bootloader they want.See also
* Booting process of Android devices * ROM image * BootX (Apple)References
{{Firmware and booting Computer memory Firmware Booting