Migrate Pi users away from u-boot in impish

Bug #1936401 reported by Dave Jones
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ubuntu-release-upgrader (Ubuntu)
Fix Released
Dave Jones
Fix Released
Dave Jones

Bug Description

Currently we have a different boot sequence on the Pi depending on which release is used:

* Focal images (and prior) all use u-boot

* Groovy images (and onwards) don't

* However, upgraders from Focal to Groovy aren't forced off u-boot; their boot configuration remains untouched

We should update user's boot configuration to migrate them off u-boot if they're still on it prior to upgrade to impish. This should be added as a quirk to do-release-upgrade. The primary complexity is that the Focal boot configuration is split into three files which should be merged. Logic from pibootctl's parser can be used for a lot of this.

The specific changes required (for those that wish to perform the changes manually):

* Find "include syscfg.txt" and "include usercfg.txt" and include the content of those files directly in "config.txt" instead.

* Remove/comment out all kernel=uboot_rpi_* lines referring to u-boot (in all conditional sections), and add a kernel=vmlinuz line to the [all] conditional section (adding that section if it's not found).

* Add an "initramfs initrd.img followkernel" line to the [all] conditional section (using the section added by the prior step if required).

* Remove any "device_tree_address=" lines from the configuration.

This switches the sequence from the current one (Pi's native bootloader loads u-boot, which then loads the Linux kernel and the initrd, before passing control to the kernel), to the new one (Pi's native bootloader loads the Linux kernel and the initrd, then passes control to the kernel).

The inlining of the split configuration files deals with a subtle edge case of the early versions of pibootctl being used to set the kernel and/or initrd, and writing those settings into syscfg.txt where they would override our changes. Releases after Focal removed the split (on new images), so this also helps keep the configuration layout consistent.

Tags: fr-1505

Related branches

Dave Jones (waveform)
Changed in ubuntu-release-upgrader (Ubuntu):
assignee: nobody → Dave Jones (waveform)
Changed in ubuntu-release-upgrader (Ubuntu):
milestone: none → ubuntu-21.10-beta
tags: added: fr-1505
Dave Jones (waveform)
description: updated
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package ubuntu-release-upgrader - 1:21.10.7

ubuntu-release-upgrader (1:21.10.7) impish; urgency=medium

  [ Dave Jones ]
  * DistUpgrade/DistUpgradeQuirks.py: Add quirk to merge raspi boot config
    into one file, and remove u-boot references (LP: #1936401)

  [ Brian Murray ]
  * Run pre-build.sh: updating mirrors, demotions, and translations.

 -- Brian Murray <email address hidden> Tue, 24 Aug 2021 11:17:22 -0700

Changed in ubuntu-release-upgrader (Ubuntu Impish):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.