implement simple device autodetection for wifi drivers
[openwrt.git] / package / base-files / default / etc / init.d / S40network
index ec29033..c772036 100755 (executable)
@@ -1,9 +1,13 @@
-#!/bin/sh
+#!/bin/sh /etc/rc.common
 # Copyright (C) 2006 OpenWrt.org
 
-setup_switch() { return 0; }
+start() {
+       setup_switch() { return 0; }
+
+       include /lib/network
+       setup_switch
+       [ -e /etc/config/wireless ] || \
+               /sbin/wifi detect > /etc/config/wireless
+       /sbin/wifi up
+}
 
-. /etc/functions.sh
-include network
-setup_switch
-/sbin/wifi
This page took 0.025593 seconds and 4 git commands to generate.