bugGNU GRUB - Bugs: bug #52939, [PATCH] 10_linux: support loading...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #52939: [PATCH] 10_linux: support loading device trees

Submitter:  Heinrich Schuchardt <xypron>
Submitted:  Sat 20 Jan 2018 10:58:56 AM UTC
   
 
Category:  Booting Severity:  Major
Priority:  5 - Normal Item Group:  Feature Request
Status:  None Privacy:  Public
Assigned to:  None Originator Name:  Heinrich Schuchardt
Open/Closed:  Open Release:  Git master
Release:  Reproducibility:  Every Time
Planned Release:  None

Sat 20 Jan 2018 10:58:56 AM UTC, original submission:  

Currently grub only loads the Linux kernel and the initial file system before booting.

On the arm and arm64 architectures the device tree is also needed for booting. The device tree is Linux kernel version dependent. So we can not rely on the initial bootloader to provide the correct device tree when calling grub.

For example I am using U-Boot to load iPXE. In iPXE I choose an iSCSI target. iPXE connects to the target and starts grubaa64.efi. The device tree that has to be used depends on the Linux kernel installed on the chosen iSCSI target.

Luckily the device tree to be loaded can be specified in grub with the devicetree command.

The patch changes the 10_linux script to look in sequence for files

  • ${dirname}/dtb-${version} and
  • ${dirname}/dtb.


If one of the files is present an entry

    devicetreee ${rel_dirname}/${dtb}

is added to the Linux boot entry.

Distro suppport


Debian maintains a symbolic link /boot/dtb to the most current device tree and another symbolic link /boot/dtb-${version} for the version specific devicetree if package flash-kernel is installed.

On Suse a symbolic link /boot/dtb points to the current
/boot/dtb-${version}.

Caveats


The EFI bootloader will still have to supply a dummy device tree which will be replaced by the devicetree command.

As of U-Boot version v2018.01 U-Boot this dummy device tree has to be passed explicitely to the bootefi command.

Heinrich Schuchardt <xypron>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by xypron (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-01-20 xypron Attached File- Added 0001-10_linux-support-loading-device-trees.patch, #42983

    Back to the top

    Powered by Savane 3.13-3230.
    Corresponding source code