summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHarald Hoyer <harald@redhat.com>2013-07-31 13:49:52 +0200
committerHarald Hoyer <harald@redhat.com>2013-07-31 13:56:03 +0200
commit868f935e23bc7b9e3d6378c868cd91853587d2d0 (patch)
treea37d21261ba328d34ec424398c20b2e9d4ac0305
parent4ba662ff90b5687f6f5a46f1db17bfb257114f44 (diff)
downloaddracut-868f935e23bc7b9e3d6378c868cd91853587d2d0.tar.gz
dracut-868f935e23bc7b9e3d6378c868cd91853587d2d0.tar.bz2
dracut-868f935e23bc7b9e3d6378c868cd91853587d2d0.zip
kernel-modules/module-setup.sh: silently omit some filesystem drivers
-rwxr-xr-xdracut-functions.sh8
-rwxr-xr-xmodules.d/90kernel-modules/module-setup.sh3
2 files changed, 9 insertions, 2 deletions
diff --git a/dracut-functions.sh b/dracut-functions.sh
index c5bb1c4b..eb1278e0 100755
--- a/dracut-functions.sh
+++ b/dracut-functions.sh
@@ -1410,6 +1410,14 @@ install_kmod_with_fw() {
fi
fi
+ if [[ $silent_omit_drivers ]]; then
+ local _kmod=${1##*/}
+ _kmod=${_kmod%.ko}
+ _kmod=${_kmod/-/_}
+ [[ "$_kmod" =~ $silent_omit_drivers ]] && return 0
+ [[ "${1##*/lib/modules/$kernel/}" =~ $silent_omit_drivers ]] && return 0
+ fi
+
inst_simple "$1" "/lib/modules/$kernel/${1##*/lib/modules/$kernel/}"
ret=$?
[[ $DRACUT_KERNEL_LAZY_HASHDIR ]] && \
diff --git a/modules.d/90kernel-modules/module-setup.sh b/modules.d/90kernel-modules/module-setup.sh
index 3d4048aa..0e7a9a12 100755
--- a/modules.d/90kernel-modules/module-setup.sh
+++ b/modules.d/90kernel-modules/module-setup.sh
@@ -61,8 +61,7 @@ installkernel() {
# if the required list is not set via the filesystems variable
if ! [[ $hostonly ]]; then
if [[ -z $filesystems ]]; then
- omit_drivers="${omit_drivers}|kernel/fs/nfs|kernel/fs/nfsd|kernel/fs/lockd" \
- omit_drivers="${omit_drivers##|}" \
+ silent_omit_drivers="kernel/fs/nfs|kernel/fs/nfsd|kernel/fs/lockd" \
instmods '=fs'
fi
else