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

Submitted by:  Heinrich Schuchardt <xypron>
Submitted on:  Sat 20 Jan 2018 10:58:56 AM UTC  
 
Category: BootingSeverity: Major
Priority: 5 - NormalItem Group: Feature Request
Status: NonePrivacy: Public
Assigned to: NoneOriginator Name: Heinrich Schuchardt
Open/Closed: OpenRelease: 
Release: Git masterReproducibility: 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>

 

Attached Files

 

Depends on the following items: None found

Items that depend on this one: None found

 

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

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follows 1 latest change.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 20 Jan 2018 10:58:56 AM UTCxypronAttached File-=>Added 0001-10_linux-support-loading-device-trees.patch, #42983

    Back to the top


    Powered by Savane 3.1-cleanup1