diff options
-rwxr-xr-x | package/madwifi/files/lib/wifi/madwifi.sh | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/package/madwifi/files/lib/wifi/madwifi.sh b/package/madwifi/files/lib/wifi/madwifi.sh index 1dce76715..15e7850eb 100755 --- a/package/madwifi/files/lib/wifi/madwifi.sh +++ b/package/madwifi/files/lib/wifi/madwifi.sh @@ -99,12 +99,13 @@ enable_atheros() { *bg) agmode=11g;; *g) agmode=11g; pureg=1;; *a) agmode=11a;; - *) agmode=11g;; + *) agmode=auto;; esac - iwconfig "$ifname" channel 0 + iwconfig "$ifname" channel 0 >/dev/null 2>/dev/null + ifconfig "$ifname" up iwpriv "$ifname" mode "$agmode" iwpriv "$ifname" pureg "$pureg" - iwconfig "$ifname" channel "$channel" + iwconfig "$ifname" channel "$channel" >/dev/null 2>/dev/null } config_get_bool hidden "$vif" hidden @@ -181,7 +182,7 @@ enable_atheros() { fi ifconfig "$ifname" up - iwconfig "$ifname" channel "$channel" + iwconfig "$ifname" channel "$channel" >/dev/null 2>/dev/null local net_cfg bridge net_cfg="$(find_net_config "$vif")" |