The dboot command simplifies operating system bootup by performing the following operations:

  • Downloads the required files (kernel, flattened device tree, init ramdisk) from the specified media to RAM

  • Sets the bootargs variable with the boot command line required for the selected operating system

  • Boots the system

Syntax

'dboot' syntax
=> help dboot
dboot - Digi modules boot command

Usage:
dboot <os> [source] [extra-args...]
 Description: Boots <os> via <source>
 Arguments:
   - os:           one of the operating systems reserved names:
                   linux|android
   - [source]:     tftp|nfs|mmc|usb
   - [extra-args]: extra arguments depending on 'source'

      source=tftp|nfs -> [filename]
       - filename: kernel file to transfer (if not provided, filename
                   will be taken from the variable pointed to by
                   $dboot_kernel_var)

      source=mmc|usb -> [device:part] [filename]
       - device:part: number of device and partition
       - filename: kernel file to transfer (if not provided, filename
                   will be taken from the variable pointed to by
                   $dboot_kernel_var)

Examples

Example 1: Boot Linux from TFTP using kernel image myImage-test.

=> dboot linux tftp myImage-test

Example 2: Boot Linux from the internal eMMC (kernel image name is taken by default from variable $imagegz):

=> dboot linux mmc

Customize 'dboot' using environment variables

The behavior of the dboot command is highly customizable through its parameters and also using the following environment variables:

Addresses

Variable Description

$loadaddr

RAM address where the kernel image is downloaded (or uncompressed if using a *.gz image)

$lzipaddr

RAM address where the kernel image is downloaded if using a *.gz image

$fdt_addr

RAM address where the Flattened Device Tree image is downloaded

$initrd_addr

RAM address where the init ramdisk image is downloaded

Image file names

Variable Description

$imagegz

Kernel image filename if using a *.gz image

$image

Kernel image filename if using an uncompressed image

$fdt_file

Flattened Device Tree image filename

$initrd_file

Init ramdisk image filename

Modifiers

Variable Description

$boot_fdt

Whether the kernel requires a Flattened Device Tree (FDT). Valid values are:

  • yes: FDT is required. If it cannot be downloaded, dboot command will fail.

  • try: FDT is optional. dboot will try to load it but will continue to boot the kernel without it if not available.

  • no: FDT is not required. dboot will not try to download it.

$boot_initrd

Whether the kernel requires an init ramdisk. Valid values are:

  • yes: Init ramdisk is required. If it cannot be downloaded, dboot command will fail.

  • try: Init ramdisk is optional. dboot will try to load it but will continue to boot the kernel without it if not available.

  • no: Init ramdisk is not required. dboot will not try to download it.

Source media

Variable Description

$mmcdev

Default MMC device index to read files from (when no device index is passed as parameter).

$mmcpart

Default MMC partition index to read files from (when no partition index is passed as parameter).

Boot arguments

Variable Description

$bootargs_mmc_linux

Script that sets the $bootargs variable with Linux boot arguments when booting from MMC.

$bootargs_tftp_linux

Scripts that set the $bootargs variable with Linux boot arguments when booting from TFTP.

$bootargs_nfs_linux

Scripts that set the $bootargs variable with Linux boot arguments when booting from NFS.

$rootpath

NFS root path to use in the $bootargs variable when booting from TFTP/NFS.

$mmcroot

Root path to use in the $bootargs variable when booting from MMC.

$bootargs_once

Special variable that is appended to the $bootargs. It can only be set locally with the equals sign, not with the setenv command:

=> bootargs_once="<arguments>"

Locally set variables are not saved across reboots so this will pass boot arguments to the operating system only once.

$extra_bootargs

Placeholder for appending any customized boot arguments at the end of the kernel command line.