Blame SOURCES/0509-dracut.sh-gather-host_modalias-when-no-hostonly-defa.patch

1755ca
From 0489607bf69ce521e1409e902380f3e168eeb302 Mon Sep 17 00:00:00 2001
1755ca
From: Lukas Nykryn <lnykryn@redhat.com>
1755ca
Date: Fri, 27 Oct 2017 14:36:26 +0200
1755ca
Subject: [PATCH] dracut.sh: gather host_modalias when
1755ca
 "--no-hostonly-default-device" is set
1755ca
1755ca
rhel-only
1755ca
Related: #1483838
1755ca
---
1755ca
 dracut.sh | 2 ++
1755ca
 1 file changed, 2 insertions(+)
1755ca
1755ca
diff --git a/dracut.sh b/dracut.sh
1755ca
index 0b23a838..1dd3eabd 100755
1755ca
--- a/dracut.sh
1755ca
+++ b/dracut.sh
1755ca
@@ -1121,8 +1121,10 @@ if [[ $hostonly ]] && [[ "$hostonly_default_device" != "no" ]]; then
1755ca
             [[ -b $_dev ]] && push host_devs "$_dev"
1755ca
         done < /etc/fstab
1755ca
     fi
1755ca
+fi
1755ca
 
1755ca
 
1755ca
+if [[ $hostonly ]]; then
1755ca
     # record all host modaliases
1755ca
     declare -A host_modalias
1755ca
     find  /sys/devices/ -name uevent -print > "$initdir/.modalias"