summaryrefslogtreecommitdiff
blob: 92cd72a981071d707738a80750a10c76d9ae0b04 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
--- util/grub.d/10_linux.in
+++ util/grub.d/10_linux.in
@@ -182,17 +182,19 @@
   linux_root_device_thisversion="${LINUX_ROOT_DEVICE}"
 
   initrd=
+  pushd "${dirname}" > /dev/null
   for i in "initrd.img-${version}" "initrd-${version}.img" "initrd-${version}.gz" \
 	   "initrd-${version}" "initramfs-${version}.img" \
 	   "initrd.img-${alt_version}" "initrd-${alt_version}.img" \
 	   "initrd-${alt_version}" "initramfs-${alt_version}.img" \
-	   "initramfs-genkernel-${version}" \
-	   "initramfs-genkernel-${alt_version}"; do
-    if test -e "${dirname}/${i}" ; then
+	   "initramfs-genkernel"*"-${version}" \
+	   "initramfs-genkernel"*"-${alt_version}"; do
+    if test -e "${i}" ; then
       initrd="$i"
       break
     fi
   done
+  popd > /dev/null
 
   config=
   for i in "${dirname}/config-${version}" "${dirname}/config-${alt_version}" "/etc/kernels/kernel-config-${version}" ; do