summaryrefslogtreecommitdiffstats
path: root/urunlevel/my_linux/Trinux/loadmodules
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xurunlevel/my_linux/Trinux/loadmodules30
1 files changed, 30 insertions, 0 deletions
diff --git a/urunlevel/my_linux/Trinux/loadmodules b/urunlevel/my_linux/Trinux/loadmodules
new file mode 100755
index 0000000..69c28ad
--- /dev/null
+++ b/urunlevel/my_linux/Trinux/loadmodules
@@ -0,0 +1,30 @@
1#!/bin/sh
2
3ls /lib/modules/*.o > /tmp/modules.in 2> /dev/null
4ls /usr/local/lib/modules/*.o >> /tmp/modules.in 2> /dev/null
5
6sort /tmp/modules.in | uniq > /tmp/modules
7
8for module in `cat /tmp/modules`
9do
10 base=`basename $module`
11 naked=`basename $base .o`
12
13
14 #echo "base: $base"
15 #echo "naked: $naked"
16
17
18 if grep $naked /etc/tux/config/modules 2> /dev/null
19 then
20 param=`grep $naked /etc/tux/config/modules | cut -d' ' -f2- 2> /dev/null`
21 echo "Loading $module $param"
22 if insmod $module $param 2> /dev/null
23 then
24 echo $module >> /etc/proc/modules.in
25 else
26 echo $module >> /etc/proc/modules.out
27 fi
28 fi
29done
30