slitaz-boot-scripts rev 134
Fix pci detection and remove black list stuff
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Tue Feb 17 01:20:28 2009 +0100 (2009-02-17) |
parents | 1dc47d7c92cc |
children | d549fce3ce20 |
files | etc/init.d/hwconf.sh etc/rcS.conf |
line diff
1.1 --- a/etc/init.d/hwconf.sh Mon Feb 16 17:50:01 2009 +0000 1.2 +++ b/etc/init.d/hwconf.sh Tue Feb 17 01:20:28 2009 +0100 1.3 @@ -16,17 +16,15 @@ 1.4 1.5 . /etc/rcS.conf 1.6 1.7 + # We need module_name to match output of lsmod. 1.8 echo "Detecting PCI devices..." 1.9 MODULES_LIST=`lspci -k | grep "modules" | cut -d ":" -f 2 | sed s/-/_/g` 1.10 for mod in $MODULES_LIST 1.11 do 1.12 - if ! `lsmod | grep -q "$mod"` && ! `echo $BLACKLIST_MODULES | grep -q "$mod"`; then 1.13 - modname=`echo "$mod" | sed s/_/-/g` 1.14 - if [ -f "$(modprobe -l $modname)" ]; then 1.15 - echo "Loading Kernel modules: $modname" 1.16 - detect="$detect $modname" 1.17 - /sbin/modprobe $modname 1.18 - fi 1.19 + if ! lsmod | grep -q "$mod" && [ -f "$(modprobe -l $mod)" ]; then 1.20 + echo "Loading Kernel modules: $mod" 1.21 + detect="$detect $mod" 1.22 + /sbin/modprobe $modname 1.23 fi 1.24 done 1.25 # yenta_socket = laptop 1.26 @@ -39,7 +37,6 @@ 1.27 fi 1.28 echo "$detect" > /var/lib/detected-modules 1.29 # Now add modules to rcS.conf 1.30 - 1.31 load=`echo "$LOAD_MODULES $detect" | sed s/" "/" "/g` 1.32 sed -i s/"LOAD_MODULES=\"$LOAD_MODULES\""/"LOAD_MODULES=\"$load\""/ \ 1.33 /etc/rcS.conf
2.1 --- a/etc/rcS.conf Mon Feb 16 17:50:01 2009 +0000 2.2 +++ b/etc/rcS.conf Tue Feb 17 01:20:28 2009 +0100 2.3 @@ -24,9 +24,6 @@ 2.4 # 2.5 LOAD_MODULES="vfat nls_utf8 ohci_hcd" 2.6 2.7 -# Kernel modules that we never want to load. 2.8 -BLACKLIST_MODULES="" 2.9 - 2.10 # Initialization scripts to run at boot time. Boot order is important, 2.11 # bootopts.sh (boot options) must start first, then you are free to choose. 2.12 # Note that the local.sh script exists to let you quickly add some local startup