allow resolution of symbol dependencies with modprobe for .ko loading
Jason D. Clinton [Tue, 21 Apr 2009 23:08:41 +0000 (18:08 -0500)]
etc/library.sh

index 54738e1..e7d7bd3 100755 (executable)
@@ -124,9 +124,10 @@ load_module() {
 
        MODULE_PATH=${1}
        MODULE_NAME=`basename ${MODULE_PATH}`
+       MODULE_NAME=${MODULE_NAME%.ko}
 
        msg -n "Trying to load ${MODULE_NAME}"
-       /sbin/insmod "${MODULE_PATH}"  >> /tmp/stdout.log 2>> /tmp/stderr.log
+       /sbin/modprobe "${MODULE_NAME}"  >> /tmp/stdout.log 2>> /tmp/stderr.log
        if [ "$?" = "1" ];
        then
                fail_msg