Hi, another small patch. Kind regards, Maarten Vanraes
From 4ef6f01f12874dde73025e890b012d443b355766 Mon Sep 17 00:00:00 2001 From: Maarten Vanraes <maarten.vanraes@xxxxxxxxx> Date: Mon, 26 Jul 2010 09:49:06 +0200 Subject: [PATCH 4/4] not remove unloaded modules Currently unloaded kernel modules can't be removed, because this would break kernel module renames or newer modules for certain hardware, this also has problems for chrooted installs. Signed-off-by: Maarten Vanraes <maarten.vanraes@xxxxxxxxx> --- dracut-functions | 11 +++++++---- 1 files changed, 7 insertions(+), 4 deletions(-) diff --git a/dracut-functions b/dracut-functions index be6b2e9..47a958d 100755 --- a/dracut-functions +++ b/dracut-functions @@ -607,10 +607,13 @@ instmods() { [[ -f $initdir/$1 ]] && { shift; continue; } # If we are building a host-specific initramfs and this # module is not already loaded, move on to the next one. - [[ $hostonly ]] && ! grep -q "${mod//-/_}" /proc/modules && \ - ! echo $add_drivers | grep -qe "\<${mod}\>" && { - shift; continue; - } + # NOTE: This is not desirable, if a new kernel has a renamed + # module or it has a new module with better support, that module + # won't be used here. + #[[ $hostonly ]] && ! grep -q "${mod//-/_}" /proc/modules && \ + #! echo $add_drivers | grep -qe "\<${mod}\>" && { + # shift; continue; + #} # We use '-d' option in modprobe only if modules prefix path # differs from default '/'. This allows us to use Dracut with -- 1.6.4.4