madwifi: only set the desired mode for the first vap
authorFelix Fietkau <nbd@openwrt.org>
Sun, 29 Mar 2009 00:10:31 +0000 (00:10 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Sun, 29 Mar 2009 00:10:31 +0000 (00:10 +0000)
SVN-Revision: 15059

package/madwifi/files/lib/wifi/madwifi.sh

index 3c4112a..0124285 100755 (executable)
@@ -120,10 +120,10 @@ enable_atheros() {
                        *fh) hwmode=fh;;
                        *) hwmode=auto;;
                esac
-               iwpriv "$ifname" mode "$hwmode"
                iwpriv "$ifname" pureg "$pureg"
 
                [ "$first" = 1 ] && {
+                       iwpriv "$ifname" mode "$hwmode"
                        iwconfig "$ifname" channel "$channel" >/dev/null 2>/dev/null 
                }