Signed-off-by: Ferenc Wagner <[email protected]>

diff --git a/target/linux/brcm-2.4/base-files/etc/preinit.arch 
b/target/linux/brcm-2.4/base-files/etc/preinit.arch
index 18b6ae5..fd73e37 100755
--- a/target/linux/brcm-2.4/base-files/etc/preinit.arch
+++ b/target/linux/brcm-2.4/base-files/etc/preinit.arch
@@ -46,10 +46,12 @@ check_module () {
   return $?
 }
 
-insmod switch-core
-check_module switch-robo || check_module switch-adm  || { 
-  check_module bcm57xx activate_gpio=0x4 && cpu_port="8u*"
-} || rmmod switch-core
+if insmod switch-core; then
+  check_module switch-robo ||
+  check_module switch-adm  || 
+  check_module bcm57xx activate_gpio=0x4 && cpu_port="8u*" ||
+  rmmod switch-core
+fi
 
 [ -d /proc/switch/eth0 ] && {
        echo 1 > /proc/switch/eth0/reset

_______________________________________________
openwrt-devel mailing list
[email protected]
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to