Blame SOURCES/0004-dracut.sh-we-don-t-need-to-read-the-modalias-files.patch

712866
From 72ce014bc79933379cb864cef665114ac5d4ccfa Mon Sep 17 00:00:00 2001
712866
From: Harald Hoyer <harald@redhat.com>
712866
Date: Fri, 13 Sep 2013 17:51:29 +0200
712866
Subject: [PATCH] dracut.sh: we don't need to read the modalias files
712866
712866
udev does only parse the uevent MODALIAS line, so whatever is in the
712866
modalias files would not trigger any module load.
712866
---
712866
 dracut.sh | 5 +----
712866
 1 file changed, 1 insertion(+), 4 deletions(-)
712866
712866
diff --git a/dracut.sh b/dracut.sh
5c6c2a
index ce39151c..196b3ad4 100755
712866
--- a/dracut.sh
712866
+++ b/dracut.sh
712866
@@ -919,15 +919,12 @@ if [[ $hostonly ]]; then
712866
     fi
712866
     # record all host modaliases
712866
     declare -A host_modalias
712866
-    find  /sys/devices/ -name modalias -print > "$initdir/.modalias"
712866
-    while read m; do
712866
-        modalias="$(<"$m")" && [[ $modalias ]] && host_modalias["$modalias"]=1
712866
-    done < "$initdir/.modalias"
712866
     find  /sys/devices/ -name uevent -print > "$initdir/.modalias"
712866
     while read m; do
712866
         while read line; do
712866
             [[ "$line" != MODALIAS\=* ]] && continue
712866
             modalias="${line##MODALIAS=}" && [[ $modalias ]] && host_modalias["$modalias"]=1
712866
+            break
712866
         done < "$m"
712866
     done < "$initdir/.modalias"
712866