7 ms·
> Also, there are multiple u-boot binaries with separate environments. It could be done for redundancy or different modes. I’m not sure. This is typically done
by richarme 5y ago
> Also, there are multiple u-boot binaries with separate environments. It could be done for redundancy or different modes. I’m not sure.
This is typically done in order to be able to safely update the u-boot bootloader, retaining the ability to boot the previous version if the upgrade fails. Also called A/B firmware update. The previous bootloader stage ("SBL" or "TZ", depending on secure boot mechanism) might check a flag in a configuration partition to see which loader should be started and whether a previous boot to that loader was attempted, and will revert back to the previously active one after an upgrade that fails to boot up, or fails to pass secure boot integrity checks.
A failure could for instance happen if the power drops while writing the update to the u-boot partition. Without such a mechanism, an update failure would brick the device. Alternatives are "never update the bootloader", or "hope for the best".
- colejohnson66 5y agoSome x86 motherboards (especially high-end ones) are now adding this feature as well. They're sometimes referred to as "dual BIOS" motherboards.
- pixl97 5y agoIn this way BIOS's are so much better these days. You can even boot and update your BIOS without a working processor. Did this over Christmas when the mainboard/CPU combo I got for a family member wasn't compatible. Just put in a USB drive with the correct file name and press a button on the board and it updated and I was good to go. A little of topic, but just wanted to state how much better these things are than the old days where it was easy to brick a board.
- oblak 5y agoMinor correction: many motherboards, especially high-end ones, have had this feature a decade or so