#!/bin/bash

sys_modules_file="/etc/modules"
modules_file="/data/etc/modules"

test -n "$os_version" || source /etc/init.d/base

case "$1" in
    start)
        msg_begin "Loading kernel modules"

        if [ -r $sys_modules_file ]; then
            cat $sys_modules_file | while read line; do test -n "$line" && /sbin/modprobe $line &>/dev/null; done
        fi

        if [ -r $modules_file ]; then
            cat $modules_file | while read line; do test -n "$line" && /sbin/modprobe $line &>/dev/null; done
        fi

        msg_done
        ;;

    stop)
        true
        ;;

    *)
        echo "Usage: $0 {start}"
        exit 1
esac

exit $?

