SMARC-sAMX7 User Guide. Rev. 1.9
// 45
7.11.
Bootloader Boot Source Support
The SMARC v2.0 Specification defines three boot select signals BOOT_SEL[0:2]# that allows the user to select from
eight possible boot devices. On the SMARC_sAMX7, U-Boot detects the BOOT_SEL signals from the carrier and sets
the environment variable "boot_sel" as shown below.
Table 20: Environment Variables for "boot_sel"
BOOT_SEL2#
BOOT_SEL1# BOOT_SEL0#
boot_sel
Boot Source
GND
GND
GND
carrier_sata
Carrier SATA
GND
GND
Float
carrier_sd
Carrier SD Card
GND
Float
GND
carrier_mmc
Carrier eSPI (CS0#)
GND
Float
Float
carrier_spi
Carrier SPI (CS0#)
Float
GND
GND
module_device
Module Device (NAND, NOR) – vendor
specific
Float
GND
Float
remote
Remote boot (GBE, serial) – vendor
specific
Float
Float
GND
module_mmc
Module eMMC Flash
Float
Float
Float
module_spi
Module SPI
Bootloader environment scripts can use the boot_sel environment variable to select the source where the dedicated
OS image can be loaded. As an example, the bootloader environment of the SMARC_sAMX7 implements some small
scripts that will load a linux system from the boot source as defined by the BOOT_SEL pins.
bootsel_boot=echo BOOT_SEL ${boot_sel} selected && run ${boot_sel}_boot
module_mmc_boot=run mmcboot
module_spi_boot=run mmcboot
Running the "run bootsel_boot" script will load a linux system from MMC if BOOT_SEL pins define the module MMC
Flash or the Module SPI as boot source. Depending on application, the script variables in environment can be
adapted.
The bootloader is always booted from the boot source defined by fuse settings, which is
normally the QSPI flash device. The BOOT_SEL pins only define boot source for the OS.
7.12.
Bootloader Boot Counter
The module EEPROM device contents implements a SMBIOS Running-time data block (type 161) as defined in the
KEU EEPROM Specification Rev. 1.4. The running-time data block structure implements a 64bit boot counter. U-Boot
on the SMARC_sAMX7 module will read the current boot counter value and increment it on every boot cycle. Current
boot counter is shown as part of the information shown by the "kboardinfo" command (see description of
kboardinfo).
7.13.
Bootloader Update
Bootloader update on SMARC_sAMX7 is using an update script containing all necessary checks and installation
commands. It is provided by Kontron on an USB thumb device containing the scriptfile and update images in the
dedicated "update_smx7_spl" folder.
As an alternative it is possible to perform bootloader update from network. To achieve this, the "update_smx7_spl"
folder mentioned above must have been copied to the server path of the TFTP server machine.
Given these prerequisites are met, update can be done from bootloader CLI using the predefined "update" script:
=> run update