Skip to content

Commit

Permalink
u-boot: add support for devicetree
Browse files Browse the repository at this point in the history
Likewise the corresponding support for syslinux introduced by commit
c5112c2, this one enables writing devicetree
filename into the uEnv.txt environment file for u-boot.

Since u-boot does not strictly defines variable names, here 'fdt_file' was
chosen as it appear to be one the most frequently adopted names in u-boot
default environments. Outer boot logic should of course comply with this choice
and use $fdt_file as the device tree file name to pass to boot commands.

This was tested on a custom board booting with u-boot.

Closes: #1590
Approved by: cgwalters
  • Loading branch information
gizero authored and rh-atomic-bot committed May 23, 2018
1 parent 4b330fe commit ce2995e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/libostree/ostree-bootloader-uboot.c
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,10 @@ create_config_from_boot_loader_entries (OstreeBootloaderUboot *self,
if (val)
g_ptr_array_add (new_lines, g_strdup_printf ("ramdisk_image%s=%s", index_suffix, val));

val = ostree_bootconfig_parser_get (config, "devicetree");
if (val)
g_ptr_array_add (new_lines, g_strdup_printf ("fdt_file%s=%s", index_suffix, val));

val = ostree_bootconfig_parser_get (config, "options");
if (val)
{
Expand Down

0 comments on commit ce2995e

Please sign in to comment.