[Bug 1811984] Re: flash-kernel 3.90ubuntu3.18.10.1 fails with mkimage: not found if no uboot is used

satmandu 1811984 at bugs.launchpad.net
Sun Feb 9 23:25:13 UTC 2020


If this is still relevant, the easiest workaround for using the
raspberry pi bootloader directly and bypassing u-boot is to do the
following. (This is actually useful if you use a custom kernel, since
the needed dtb file for u-boot may not be the one you want to use for
your custom kernel.)

Do NOT uninstall u-boot.

edit /boot/firmware/config.txt so that all kernel lines are commented
out and make sure the [all] section has these two lines:

kernel=vmlinuz
initramfs initrd.img followkernel

Then create put the following text in
/etc/kernel/postinst.d/zzzz_rpi_kernel:

#!/bin/sh -eu
#
# This uncompresses the arm64 kernel so the rpi bootloader can load it. 
#
# First exit if we aren't running an ARM64 kernel.
#
[ $(uname -m) != aarch64 ] && exit 0
#
KERNEL_VERSION="$1"
KERNEL_INSTALLED_PATH="$2"

gunzip -c -f ${KERNEL_INSTALLED_PATH} > ${KERNEL_INSTALLED_PATH}.nogz &&
mv -f ${KERNEL_INSTALLED_PATH}.nogz ${KERNEL_INSTALLED_PATH}

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to flash-kernel in Ubuntu.
https://bugs.launchpad.net/bugs/1811984

Title:
  flash-kernel 3.90ubuntu3.18.10.1 fails with mkimage: not found if no
  uboot is used

Status in flash-kernel package in Ubuntu:
  Invalid

Bug description:
  After updating flash-kernel from 3.90ubuntu3 to 3.90ubuntu3.18.10.1,
  dpkg aborted with this error:

  Processing triggers for flash-kernel (3.90ubuntu3.18.10.1) ...
  Using DTB: bcm2710-rpi-3-b-plus.dtb
  Installing /lib/firmware/4.18.0-1009-raspi2/device-tree/broadcom/bcm2710-rpi-3-b-plus.dtb into /boot/dtbs/4.18.0-1009-raspi2/bcm2710-rpi-3-b-plus.dtb
  Taking backup of bcm2710-rpi-3-b-plus.dtb.
  Installing new bcm2710-rpi-3-b-plus.dtb.
  flash-kernel: installing version 4.18.0-1009-raspi2
  Taking backup of vmlinuz.
  Installing new vmlinuz.
  Taking backup of bcm2710-rpi-3-b-plus.dtb.
  Installing new bcm2710-rpi-3-b-plus.dtb.
  Taking backup of initrd.img.
  Installing new initrd.img.
  Generating boot script u-boot image... /usr/sbin/flash-kernel: 497: /usr/sbin/flash-kernel: mkimage: not found
  dpkg: error processing package flash-kernel (--configure):
   installed flash-kernel package post-installation script subprocess returned error exit status 127
  Errors were encountered while processing:
   flash-kernel

  
  The missing mkimage tool is in the package u-boot-tools which is recommended, but no dependency. Since I don't use uboot, I don't have that installed.

  The previous version of flash-kernel didn't care about that and worked
  just fine (updated DTB, initrd and vmlinuz).

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/flash-kernel/+bug/1811984/+subscriptions



More information about the foundations-bugs mailing list