summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAmadeusz Żołnowski <aidecoe@gentoo.org>2015-08-16 11:33:59 +0100
committerAmadeusz Żołnowski <aidecoe@gentoo.org>2015-08-16 11:36:10 +0100
commit01f96bde83ab52f47cea0c0f9641e0528b87522e (patch)
treecdf7499c9b7aa06667b5259d438f96001e542a5f /sys-kernel/dracut/files
parentsys-process/htop: Use slot operators for ncurses; drop old (diff)
downloadgentoo-01f96bde83ab52f47cea0c0f9641e0528b87522e.tar.gz
gentoo-01f96bde83ab52f47cea0c0f9641e0528b87522e.tar.bz2
gentoo-01f96bde83ab52f47cea0c0f9641e0528b87522e.zip
sys-kernel/dracut: Add patch fixing dracut-initramfs-restore
Patch makes mount error nonfatal in dracut-initramfs-restore. Commit on behalf of Alexander Tsoy <alexander@tsoy.me>. Gentoo-Bug: 533084 Package-Manager: portage-2.2.20.1
Diffstat (limited to 'sys-kernel/dracut/files')
-rw-r--r--sys-kernel/dracut/files/043-0004-dracut-initramfs-restore-make-mount-er.patch28
1 files changed, 28 insertions, 0 deletions
diff --git a/sys-kernel/dracut/files/043-0004-dracut-initramfs-restore-make-mount-er.patch b/sys-kernel/dracut/files/043-0004-dracut-initramfs-restore-make-mount-er.patch
new file mode 100644
index 000000000000..23e30e1f7050
--- /dev/null
+++ b/sys-kernel/dracut/files/043-0004-dracut-initramfs-restore-make-mount-er.patch
@@ -0,0 +1,28 @@
+From a18c8fdc9cb3eb917e9a7a30466839c33131cc8a Mon Sep 17 00:00:00 2001
+From: Alexander Tsoy <alexander@tsoy.me>
+Date: Tue, 28 Jul 2015 14:55:59 +0300
+Subject: [PATCH 4/4] dracut-initramfs-restore: make mount error nonfatal
+
+Script enables errexit option (set -e). So if /boot is not a mount point
+or is already mounted, then script dies after unsuccessful mount
+command. Fix this by always returning successful result.
+---
+ dracut-initramfs-restore.sh | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/dracut-initramfs-restore.sh b/dracut-initramfs-restore.sh
+index 0e6a1a8..0c41a59 100644
+--- a/dracut-initramfs-restore.sh
++++ b/dracut-initramfs-restore.sh
+@@ -14,7 +14,7 @@ SKIP="$dracutbasedir/skipcpio"
+
+ [[ -f /etc/machine-id ]] && read MACHINE_ID < /etc/machine-id
+
+-mount -o ro /boot &>/dev/null
++mount -o ro /boot &>/dev/null || true
+
+ if [[ $MACHINE_ID ]] && [[ -d /boot/${MACHINE_ID} || -L /boot/${MACHINE_ID} ]] ; then
+ IMG="/boot/${MACHINE_ID}/${KERNEL_VERSION}/initrd"
+--
+2.5.0
+