Files
libuev/nmeamux/root/etc/init.d/S15modules
T
2011-02-21 22:20:14 +01:00

49 lines
839 B
Bash
Executable File

#! /bin/sh
#
# Beregn afhængigheder mellem moduler, opret modules.dep og load moduler fra /etc/modules.
. /etc/init.d/rcS-helper
start() {
# This will work when busysbox is configured with MODPROBE_SMALL
modprobe depmod-dummy 2>/dev/null
# Loop over every line in /etc/modules.
dmesg -n 5
echo -n 'Loading modules: '
(cat /etc/modules; echo) | # The echo make sure there is a LF at the end.
while read module args; do
case "$module" in
\#*|"") continue ;;
esac
echo -n "$module: "
modprobe $module $args
done
echo ''
dmesg -n 7
}
stop() {
:
}
restart() {
stop
start
}
case "$1" in
start)
start
;;
stop)
stop
;;
restart|reload)
restart
;;
*)
echo $"Usage: $0 {start|stop|restart}"
exit 1
esac