aboutsummaryrefslogtreecommitdiffstats
path: root/package/mac80211
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2010-02-28 19:02:05 +0000
committerFelix Fietkau <nbd@openwrt.org>2010-02-28 19:02:05 +0000
commitbbb7e33b6f638cc53548530ca042095244cceb78 (patch)
treebf9761b190b6269088839f5a7113e9a465a047fc /package/mac80211
parent14376d2461d3a7dc42f6175e320f234227398073 (diff)
downloadupstream-bbb7e33b6f638cc53548530ca042095244cceb78.tar.gz
upstream-bbb7e33b6f638cc53548530ca042095244cceb78.tar.bz2
upstream-bbb7e33b6f638cc53548530ca042095244cceb78.zip
mac80211: fix client mode
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@19915 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/mac80211')
-rw-r--r--package/mac80211/files/lib/wifi/mac80211.sh24
1 files changed, 12 insertions, 12 deletions
diff --git a/package/mac80211/files/lib/wifi/mac80211.sh b/package/mac80211/files/lib/wifi/mac80211.sh
index f127b28566..87f7d29daa 100644
--- a/package/mac80211/files/lib/wifi/mac80211.sh
+++ b/package/mac80211/files/lib/wifi/mac80211.sh
@@ -329,20 +329,20 @@ enable_mac80211() {
start_hostapd=1
done
- [ -n "$start_hostapd" ] || return 0
+ [ -n "$start_hostapd" ] && {
+ hostapd -P /var/run/wifi-$phy.pid -B /var/run/hostapd-$phy.conf || {
+ echo "Failed to start hostapd for $phy"
+ return
+ }
+ sleep 2
- hostapd -P /var/run/wifi-$phy.pid -B /var/run/hostapd-$phy.conf || {
- echo "Failed to start hostapd for $phy"
- return
+ for vif in $vifs; do
+ config_get mode "$vif" mode
+ config_get ifname "$vif" ifname
+ [ "$mode" = "ap" ] || continue
+ mac80211_start_vif "$vif" "$ifname"
+ done
}
- sleep 2
-
- for vif in $vifs; do
- config_get mode "$vif" mode
- config_get ifname "$vif" ifname
- [ "$mode" = "ap" ] || continue
- mac80211_start_vif "$vif" "$ifname"
- done
for vif in $vifs; do
config_get mode "$vif" mode