29 Jan, 2018

1 commit

  • This commit allows overriding the default assumption that the boot UBI
    MTD partition is named 'UBI' and the UBI volume is 'boot'. A board
    desiring to use a legacy or alternative NAND layout can now define the
    following two extra environment variables:

    bootubipart=
    bootubivol=

    EXAMPLE:

    [include/configs/some_board.h]
    ---8

    #define MEM_LAYOUT_ENV_SETTINGS \
    DEFAULT_LINUX_BOOT_ENV

    #define BOOT_TARGET_DEVICES(func) \
    func(UBIFS, ubifs, 0)

    #include
    [...]
    #define CONFIG_EXTRA_ENV_SETTINGS \
    MEM_LAYOUT_ENV_SETTINGS \
    "bootubivol=rootfs\0" \
    "bootubipart=rootfs\0" \
    BOOTENV
    [...]
    ---8

    Derald D. Woods
     

30 Nov, 2017

1 commit

  • Currently X86 does not properly support distro defaults.
    This patch is only a partial fix.

    It provides the name of the bootloader EFI application
    for the X86 architecture.

    The architecture dependent file names are defined in the UEFI
    specification.

    Signed-off-by: Heinrich Schuchardt
    Reviewed-by: Simon Glass
    Reviewed-by: Bin Meng

    Heinrich Schuchardt
     

20 Sep, 2017

1 commit

  • Similar to a "real" UEFI implementation, the bootmgr looks at the
    BootOrder and BootXXXX variables to try to find an EFI payload to load
    and boot. This is added as a sub-command of bootefi.

    The idea is that the distro bootcmd would first try loading a payload
    via the bootmgr, and then if that fails (ie. first boot or corrupted
    EFI variables) it would fallback to loading bootaa64.efi. (Which
    would then load fallback.efi which would look for \EFI\*\boot.csv and
    populate BootOrder and BootXXXX based on what it found.)

    Signed-off-by: Rob Clark
    Signed-off-by: Alexander Graf

    Rob Clark
     

12 Aug, 2017

1 commit

  • This option enables the 'pci enum' command. It is only enabled by a few
    board and these have not yet been converted to driver model, which always
    enables this command. It seems easiest to just remove this option.

    The affected boards can be converted to use driver model for PCI if
    needed.

    Signed-off-by: Simon Glass
    Reviewed-by: Bin Meng
    Reviewed-by: Philipp Tomsich

    Simon Glass
     

12 Jul, 2017

1 commit


23 May, 2017

1 commit

  • At present IDE support is controlled by CONFIG_CMD_IDE. Add a separate
    CONFIG_IDE option so that IDE support can be enabled without requiring
    the 'ide' command.

    Update existing users and move the ide driver into drivers/block since
    it should not be in common/.

    Signed-off-by: Simon Glass

    Simon Glass
     

28 Jan, 2017

1 commit


25 Jun, 2016

1 commit

  • The distro script is supposed to use the internal fdt as fallback if we
    find no viable other option. However, we're missing a space key to actually
    make that work.

    Add the space, so we can successfully load an EFI blob even when there is
    no device tree provided on the target device.

    Signed-off-by: Alexander Graf

    Alexander Graf
     

28 May, 2016

1 commit

  • Now that we can expose network functionality to EFI applications,
    the logical next step is to load them via pxe to execute them as
    well.

    This patch adds the necessary bits to the distro script to automatically
    load and execute EFI payloads. It identifies the dhcp client as a uEFI
    capable PXE client, hoping the server returns a tftp path to a workable
    EFI binary that we can then execute.

    To enable boards that don't come with a working device tree preloaded,
    this patch also adds support to load a device tree from the /dtb directory
    on the remote tftp server.

    Signed-off-by: Alexander Graf
    Reviewed-by: Tom Rini

    Alexander Graf
     

17 May, 2016

1 commit


19 Apr, 2016

2 commits

  • When there is no $fdtfile variable set, we still have a good chance
    that on 32bit arm the fdtfile really is just called $soc-$board.dtb.

    Enable the exports for $soc and $board in our distr defaults and make
    use of them in the efi boot script.

    Reported-by: Andreas Faerber
    Reported-by: Stephen Warren
    Signed-off-by: Alexander Graf
    Reviewed-by: Andreas Färber

    Alexander Graf
     
  • The bootefi cmd today fetches its device tree pointer from either the
    location appointed by "fdt addr" with a fallback to the U-Boot control
    fdt.

    This integration is unusual for U-Boot and diverges from the way we
    usually handle parameters to boot commands. So let's pass the fdt
    directly into the bootefi command instead and move the control fdt
    logic into the distro boot script.

    Signed-off-by: Alexander Graf
    Acked-by: Stephen Warren
    Reviewed-by: Andreas Färber

    Alexander Graf
     

16 Mar, 2016

2 commits

  • The commonly defined environment variable to determine the device tree
    file name is called fdtfile rather than fdt_name. Replace all occurences
    of fdt_name with fdtfile.

    Signed-off-by: Alexander Graf

    Alexander Graf
     
  • UEFI defines a simple boot protocol for removable media. There we should look
    at the EFI (first GPT FAT) partition and search for /efi/boot/bootXXX.efi with
    XXX being different between different platforms (x86, x64, arm, aa64, ...).

    This patch implements a simple version of that protocol for the default distro
    boot script. With this we can automatically boot from valid UEFI enabled
    removable media.

    Because from all I could see U-Boot by default doesn't deliver device tree
    blobs with its firmware, we also need to load the dtb from somewhere. Traverse
    the same EFI partition for an fdt file that fits our current board so that
    an OS receives a valid device tree when booted automatically.

    Signed-off-by: Alexander Graf
    Reviewed-by: Simon Glass

    Alexander Graf
     

29 Jan, 2016

2 commits

  • The PCI bus must be enumerated before PCI devices, such as Ethernet
    devices, are known to U-Boot. Enhance the distro boot commands to perform
    PCI enumeration when needed.

    Signed-off-by: Stephen Warren
    Reviewed-by: Simon Glass

    Stephen Warren
     
  • Currently, the distro boot commands always enumerate USB devices before
    performing network operations. However, depending on the board and end-
    user configuration, network devices may not be attached to USB, and so
    enumerating USB may not be necessary. Enhance the scripts to make this
    step optional, so that the user can decrease boot time if they don't
    need USB.

    This change is performed by moving the "usb start" invocation into a
    standalone variable. If the user desires, they can replace that
    variable's value with some no-op command such as "true" instead.

    Booting from a USB storage device always needs to enumerate USB devices,
    so this action is still hard-coded.

    Signed-off-by: Stephen Warren
    Reviewed-by: Simon Glass

    Stephen Warren
     

25 Oct, 2015

1 commit


23 Oct, 2015

1 commit

  • Hush has an oddity where using ${var} causes var to resolved in the the global
    address space (iotw the environment) first and only afterwards will the local
    variable space be searched.

    This causes odd side-effects when iterating over the boot partitions
    using ${bootpart} if the environment also has a bootpart variable (e.g. for
    the various TI boards). Fix this by using the hopefully more unique
    ${distro_bootpart} instead of ${bootpart}.

    Signed-off-by: Sjoerd Simons
    Acked-by: Stephen Warren

    Sjoerd Simons
     

20 Apr, 2015

1 commit


26 Mar, 2015

1 commit


13 Mar, 2015

1 commit


17 Feb, 2015

1 commit


30 Jan, 2015

3 commits

  • Modify $bootcmd_dhcp to read the downloaded script filename from an
    environment variable rather than hard-coding it. This allows the user
    (or another script) to select a different script name if they want,
    without editing the whole value of $bootcmd_dhcp.

    Signed-off-by: Stephen Warren

    Stephen Warren
     
  • Move the bootcmd commands into a seperate distro_bootcmd environment
    variable. Allowing a user to easily launch the distro boot sequence if
    the default bootcmd did not default to distro boot commands.

    Also set CONFIG_BOOTCOMMAND to "run distro_bootcmd" if it hasn't been
    configured yet rather then putting it directly in the environment. This
    allows boards to make the distro boot commands available without
    necessarily default to them or to use them as a fallback after running
    some board specific commands instead.

    Signed-off-by: Sjoerd Simons
    Reviewed-by: Stephen Warren

    Sjoerd Simons
     
  • Not all devices use the convention that the boot scripts are on the
    first partition. For example on chromebooks it seems common for the
    first two partitions to be ChromeOS kernel partitions.

    So instead of just the first partition scan all partitions on a device
    with a filesystem u-boot can recognize.

    Signed-off-by: Sjoerd Simons

    Sjoerd Simons
     

18 Jan, 2015

1 commit


25 Sep, 2014

1 commit


09 Aug, 2014

1 commit

  • This generic $bootcmd, and associated support macros, automatically
    searches a defined set of storage devices (or network protocols) for an
    extlinux configuration file or U-Boot boot script in various standardized
    locations. Distros that install such a boot config file/script in those
    standard locations will get easy-to-set-up booting on HW that enables
    this generic $bootcmd.

    Boards can define the set of devices from which boot is attempted, and
    the order in which they are attempted. Users may later customize this
    set/order by edting $boot_targets.

    Users may interrupt the boot process and boot from a specific device
    simply by executing e.g.:

    $ run bootcmd_mmc1
    or:
    $ run bootcmd_pxe

    This patch was originally written by Dennis Gilmore based on Tegra and
    rpi_b boot scripts. I have made the following modifications since then:

    * Boards must define the BOOT_TARGET_DEVICES macro in order to specify
    the set of devices (and order) from which to attempt boot. If needed,
    we can define a default directly in config_distro_bootcmd.h.

    * Removed $env_import and related variables; nothing used them, and I
    think it's better for boards to pre-load an environment customization
    file using CONFIG_PREBOOT if they need.

    * Renamed a bunch of variables to suit my whims:-)

    Signed-off-by: Dennis Gilmore
    Signed-off-by: Stephen Warren
    Reviewed-by: Marek Vasut
    Acked-by: Simon Glass

    Dennis Gilmore