projects
/
openwrt
/
svn-archive
/
openwrt.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c6610d6
)
merge r27976
author
Jo-Philipp Wich
<jow@openwrt.org>
Sat, 13 Aug 2011 23:20:45 +0000
(23:20 +0000)
committer
Jo-Philipp Wich
<jow@openwrt.org>
Sat, 13 Aug 2011 23:20:45 +0000
(23:20 +0000)
SVN-Revision: 27978
package/mac80211/files/lib/wifi/mac80211.sh
patch
|
blob
|
history
diff --git
a/package/mac80211/files/lib/wifi/mac80211.sh
b/package/mac80211/files/lib/wifi/mac80211.sh
index 2472f8ea8483c8575765f2851352e209e32d03c6..a1e298df21243ebc7a26a96388c2574c7a8c65f5 100644
(file)
--- a/
package/mac80211/files/lib/wifi/mac80211.sh
+++ b/
package/mac80211/files/lib/wifi/mac80211.sh
@@
-17,7
+17,13
@@
mac80211_hostapd_setup_base() {
config_get basic_rate_list "$device" basic_rate
config_get_bool noscan "$device" noscan
[ -n "$channel" -a -z "$hwmode" ] && wifi_fixup_hwmode "$device"
- [ "$channel" = auto ] && channel=
+
+ [ "$channel" = auto ] && {
+ channel=$(iw phy "$phy" info | \
+ sed -ne '/MHz/ { /disabled\|passive\|radar/d; s/.*\[//; s/\].*//; p; q }')
+ config_set "$device" channel "$channel"
+ }
+
[ -n "$hwmode" ] && {
config_get hwmode_11n "$device" hwmode_11n
[ -n "$hwmode_11n" ] && {