Add support for Ubiquiti Bullet M

Signed-off-by: Christian Dresel <fff@chrisi01.de>
Reviewed-by: Tim Niemeyer <tim@tn-x.org>
    [rebased to master]
Signed-off-by: Tim Niemeyer <tim@tn-x.org>
This commit is contained in:
Christian Dresel 2016-03-31 10:45:34 +02:00 committed by Tim Niemeyer
parent 2499110673
commit 51d512e23d
3 changed files with 35 additions and 0 deletions

View File

@ -0,0 +1,31 @@
WANDEV=eth0
SWITCHDEV=eth0
CLIENT_PORTS=""
WAN_PORTS=""
BATMAN_PORTS=""
. /etc/network.mode
CLIENTIF="w2ap"
ETHMESHMAC=
ROUTERMAC=w2mesh
uci set network.$SWITCHDEV=interface
uci set network.$SWITCHDEV.ifname=$SWITCHDEV
uci set network.mesh.ifname="bat0"
if [ "$ETHMODE" = "WAN" ] ; then
## Activate for WAN:
echo "net.ipv6.conf.$WANDEV.accept_ra_defrtr = 1" >> /etc/sysctl.conf
echo "net.ipv6.conf.$WANDEV.accept_ra_pinfo = 1" >> /etc/sysctl.conf
echo "net.ipv6.conf.$WANDEV.autoconf = 1" >> /etc/sysctl.conf
echo "net.ipv6.conf.$WANDEV.accept_ra_rtr_pref = 1" >> /etc/sysctl.conf
uci set network.wan.ifname=$WANDEV
elif [ "$ETHMODE" = "CLIENT" ] ; then
## Activate Client:
CLIENTIF="w2ap eth0"
uci set network.mesh.ifname="bat0 $SWITCHDEV"
else
## Activate BATMAN:
uci set network.ethmesh.ifname="$SWITCHDEV"
fi

View File

@ -18,6 +18,7 @@ images=("openwrt-ar71xx-generic-ubnt-nano-m-squashfs-sysupgrade.bin"
"openwrt-ar71xx-generic-tl-wa850re-v1-squashfs-sysupgrade.bin"
"openwrt-ar71xx-generic-gl-ar150-squashfs-sysupgrade.bin"
"openwrt-ar71xx-generic-tl-mr3020-v1-squashfs-sysupgrade.bin"
"openwrt-ar71xx-generic-ubnt-bullet-m-squashfs-sysupgrade.bin"
)
board_prepare() {

View File

@ -26,6 +26,9 @@ case "$BOARD" in
nanostation-m)
BOARD=ubnt-nano-m
;;
bullet-m)
BOARD=ubnt-bullet-m
;;
loco-m-xw)
BOARD=ubnt-loco-m-xw
;;