dracut/0091-plymouth-plymouth-pretrigger.sh-don-t-exit-0-for-a-s.patch

53 lines
2.7 KiB
Diff
Raw Normal View History

From 540eca9d9d651b52c2d3e18a3df7f9e36c23b681 Mon Sep 17 00:00:00 2001
From: Harald Hoyer <harald@redhat.com>
Date: Mon, 30 Jul 2012 17:07:43 +0200
Subject: [PATCH] plymouth/plymouth-pretrigger.sh: don't "exit 0" for a
sourced script
---
modules.d/50plymouth/plymouth-pretrigger.sh | 28 ++++++++++++++--------------
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/modules.d/50plymouth/plymouth-pretrigger.sh b/modules.d/50plymouth/plymouth-pretrigger.sh
index e536564..17533bb 100755
--- a/modules.d/50plymouth/plymouth-pretrigger.sh
+++ b/modules.d/50plymouth/plymouth-pretrigger.sh
@@ -2,23 +2,23 @@
# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
# ex: ts=8 sw=4 sts=4 et filetype=sh
-[ -x /bin/plymouthd -a ! -n "$DRACUT_SYSTEMD" ] || exit 0
-
-if getargbool 1 plymouth.enable && getargbool 1 rd.plymouth -d -n rd_NO_PLYMOUTH; then
+if [ -x /bin/plymouthd -a ! -n "$DRACUT_SYSTEMD" ]; then
+ if getargbool 1 plymouth.enable && getargbool 1 rd.plymouth -d -n rd_NO_PLYMOUTH; then
# first trigger graphics subsystem
- udevadm trigger --action=add --attr-match=class=0x030000 >/dev/null 2>&1
+ udevadm trigger --action=add --attr-match=class=0x030000 >/dev/null 2>&1
# first trigger graphics and tty subsystem
- udevadm trigger --action=add --subsystem-match=graphics --subsystem-match=drm --subsystem-match=tty >/dev/null 2>&1
+ udevadm trigger --action=add --subsystem-match=graphics --subsystem-match=drm --subsystem-match=tty >/dev/null 2>&1
- udevadm settle --timeout=30 2>&1 | vinfo
+ udevadm settle --timeout=30 2>&1 | vinfo
- info "Starting plymouth daemon"
- mkdir -m 0755 /run/plymouth
- read consoledev rest < /sys/class/tty/console/active
- consoledev=${consoledev:-tty0}
- [ -x /lib/udev/console_init -a -e "/dev/$consoledev" ] && /lib/udev/console_init "/dev/$consoledev"
- [ -x /bin/plymouthd ] && /bin/plymouthd --attach-to-session --pid-file /run/plymouth/pid
- /bin/plymouth --show-splash 2>&1 | vinfo
+ info "Starting plymouth daemon"
+ mkdir -m 0755 /run/plymouth
+ read consoledev rest < /sys/class/tty/console/active
+ consoledev=${consoledev:-tty0}
+ [ -x /lib/udev/console_init -a -e "/dev/$consoledev" ] && /lib/udev/console_init "/dev/$consoledev"
+ [ -x /bin/plymouthd ] && /bin/plymouthd --attach-to-session --pid-file /run/plymouth/pid
+ /bin/plymouth --show-splash 2>&1 | vinfo
# reset tty after plymouth messed with it
- [ -x /lib/udev/console_init -a -e "/dev/$consoledev" ] && /lib/udev/console_init "/dev/$consoledev"
+ [ -x /lib/udev/console_init -a -e "/dev/$consoledev" ] && /lib/udev/console_init "/dev/$consoledev"
+ fi
fi