Skip to content

Commit

Permalink
RPi: Switch to initramfs-tools for kernel deps
Browse files Browse the repository at this point in the history
initramfs-tools was chosen initially, since the (new) RPi kernel packages forcefully triggered the generation of an iniramfs image, while the RPi kernel does not require it, and tiny-tinitramfs images are some orders of magnitudes smaller. However, in between, the RPi kernel packages set INITRD=No if SKIP_INITRAMFS_GEN=yes is given, so the initramfs generation can be skipped. This exact thing does not work with tiny-initramfs until including Bookworm. Support for INITRD=No has been added for Trixie: https://salsa.debian.org/debian/tiny-initramfs/-/merge_requests/2
Additionally, tiny-initramfs cannot satisfy the dependency of a 64-bit kernel on a 32-bit OS: #7402 (comment)
  • Loading branch information
MichaIng committed Feb 13, 2025
1 parent 49206d4 commit d1b9e1d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
4 changes: 1 addition & 3 deletions .build/images/dietpi-installer
Original file line number Diff line number Diff line change
Expand Up @@ -1288,11 +1288,9 @@ _EOF_
5) kernel=('linux-image-rpi-2712');;
*) { G_DIETPI-NOTIFY 1 "Unexpected hardware model passed: \"$G_HW_MODEL\". Aborting ..."; exit 1; };;
esac
# tiny-initramfs to satisfy dependency: https://github.com/RPi-Distro/repo/issues/358
G_AGI raspi-firmware
G_CONFIG_INJECT 'SKIP_INITRAMFS_GEN=' 'SKIP_INITRAMFS_GEN=yes' /etc/default/raspi-firmware
G_AGI "${kernel[@]}" raspi-utils-core raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}" tiny-initramfs
G_EXEC apt-mark auto tiny-initramfs
G_AGI "${kernel[@]}" raspi-utils-core raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}"
G_EXEC rm -f /boot/initrd.img-* /boot/firmware/initramfs*
else
G_AGI raspberrypi-bootloader raspberrypi-kernel libraspberrypi0 libraspberrypi-bin raspberrypi-sys-mods raspberrypi-archive-keyring "${a32bit[@]}"
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ v9.11
Enhancements:

Bug fixes:
- DietPi-Config | Resolved an issue where selecting the linux-image-rpi-v8 kernel on 32-bit images could have failed, due to an outstanding APT update. Many thanks to @SOULV1CE for reporting this issue: https://github.com/MichaIng/DietPi/issues/7402
- DietPi-Config | Resolved an issue where selecting the linux-image-rpi-v8 kernel on 32-bit images failed. Many thanks to @SOULV1CE for reporting this issue: https://github.com/MichaIng/DietPi/issues/7402

As always, many smaller code performance and stability improvements, visual and spelling fixes have been done, too much to list all of them here. Check out all code changes of this release on GitHub: https://github.com/MichaIng/DietPi/pull/ADDME

Expand Down
2 changes: 1 addition & 1 deletion dietpi/func/dietpi-set_software
Original file line number Diff line number Diff line change
Expand Up @@ -929,7 +929,7 @@ deb $INPUT_MODE_VALUE $G_DISTRO_NAME-backports main contrib non-free' > /etc/apt
\n- $optional for ${models[$optional]}" && to_install=("$optional") || to_remove=("$optional")
fi

G_AGI "$kernel_package" "${to_install[@]}" raspi-firmware raspi-utils-core tiny-initramfs
G_AGI "$kernel_package" "${to_install[@]}" raspi-firmware raspi-utils-core
G_AGP "${to_remove[@]}" raspberrypi-kernel raspberrypi-headers-kernel raspberrypi-bootloader libraspberrypi-bin libraspberrypi0
}

Expand Down

0 comments on commit d1b9e1d

Please sign in to comment.