dracut/0028-feat-lsinitrd.sh-look-for-initrd-in-usr-lib-modules.patch
Pavel Valena 5857b7d190 Resolves: RHEL-39404,RHEL-47145,RHEL-53350,RHEL-53361,RHEL-53431,RHEL-53791,RHEL-54650
From-source-git-commit: e3d7b6907c414bbe25a93a3fcd2de2205316c13f

Changes added using `packit source-git update-dist-git`, which has different
patch definition format than `centpkg import` (this will be used from now on).

Also, fixup previous entry wrong date in %changelog.
2024-08-19 13:34:50 +02:00

37 lines
1.2 KiB
Diff

From afd17820980728f18a5cc96e794d4c56a8694698 Mon Sep 17 00:00:00 2001
From: Pavel Valena <pvalena@redhat.com>
Date: Fri, 16 Aug 2024 20:40:15 +0200
Subject: [PATCH 28/31] feat(lsinitrd.sh): look for initrd in /usr/lib/modules/
Introduce new path for lsinitrd.sh to look into:
/usr/lib/modules/$kver/initramfs.img
Which is valid on all ostree-based systems, and also other image based
systems with pre-generated initramfs.
Ref: https://issues.redhat.com/browse/RHEL-35890
(cherry picked from commit 22ae6ecaf9ecdb9db3e79aa9a72d527e7436c282)
Resolves: RHEL-54650
---
lsinitrd.sh | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lsinitrd.sh b/lsinitrd.sh
index 952dbc9f..429cce7e 100755
--- a/lsinitrd.sh
+++ b/lsinitrd.sh
@@ -136,6 +136,8 @@ else
image="/lib/modules/${KERNEL_VERSION}/initramfs.img"
elif [[ -f /boot/initramfs-${KERNEL_VERSION}.img ]]; then
image="/boot/initramfs-${KERNEL_VERSION}.img"
+ elif [[ -f /usr/lib/modules/${KERNEL_VERSION}/initramfs.img ]]; then
+ image="/usr/lib/modules/${KERNEL_VERSION}/initramfs.img"
elif [[ $MACHINE_ID ]] \
&& mountpoint -q /efi; then
image="/efi/${MACHINE_ID}/${KERNEL_VERSION}/initrd"
--
2.42.0