aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xrc.d/rc.sysinit7
1 files changed, 6 insertions, 1 deletions
diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit
index 29db361c..0883fb4b 100755
--- a/rc.d/rc.sysinit
+++ b/rc.d/rc.sysinit
@@ -146,8 +146,13 @@ eval `kmodule -d | while read devtype mod ; do
esac
done`
+blacklist=$(modprobe -c | LC_ALL=C awk '/^[[:space:]]*blacklist/ { print $2 }')
+
load_module () {
- LC_ALL=C fgrep -xq "$1" /etc/hotplug/blacklist 2>/dev/null || modprobe $1 >/dev/null 2>&1
+ for module in $blacklist ; do
+ [ "$1" = "$module" ] && return
+ done
+ modprobe $1 >/dev/null 2>&1
}
# IDE