airgap/config/buildroot/rootfs_overlay/etc/init.d/S02modules

23 lines
377 B
Plaintext
Raw Normal View History

2020-07-07 21:13:18 +00:00
#!/bin/sh
[ -e /proc/ksyms -o -e /proc/modules ] || exit 0
case "${1}" in
start)
[ -f /etc/modules ] || exit 0
while read module args; do
printf 'Loading module %s: ' "${module}"
modprobe ${module} ${args} >/dev/null
if [ $? -eq 0 ]; then
echo "OK"
else
echo "FAIL"
fi
2020-07-08 20:54:10 +00:00
done < /etc/modules
2020-07-07 21:13:18 +00:00
;;
*)
echo "Usage: ${0} {start}"
exit 1
;;
esac