aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/bcm53xx/base-files
diff options
context:
space:
mode:
authorDan Haab <dan.haab@legrand.com>2020-04-06 16:14:39 -0700
committerRafał Miłecki <rafal@milecki.pl>2020-04-07 15:27:52 +0200
commitc459a6bf482f5afc4746a4a108a143e9194cd59d (patch)
tree6915249faa714d1444cd02dbe8e04d8e8b957f4b /target/linux/bcm53xx/base-files
parent7daab6286110b95167e291409395494f18edc9dc (diff)
downloadupstream-c459a6bf482f5afc4746a4a108a143e9194cd59d.tar.gz
upstream-c459a6bf482f5afc4746a4a108a143e9194cd59d.tar.bz2
upstream-c459a6bf482f5afc4746a4a108a143e9194cd59d.zip
bcm53xx: add support for Luxul FullMAC WiFi devices
This prepares support for models XAP-1610 and XWR-3150. Flashing requires using Luxul firmware version: 1) 8.1.0 or newer for XAP-1610 2) 6.4.0 or newer for XWR-3150 and uploading firmware using "Firmware Update" web UI page. Signed-off-by: Dan Haab <dan.haab@legrand.com>
Diffstat (limited to 'target/linux/bcm53xx/base-files')
-rwxr-xr-xtarget/linux/bcm53xx/base-files/etc/board.d/02_network19
1 files changed, 18 insertions, 1 deletions
diff --git a/target/linux/bcm53xx/base-files/etc/board.d/02_network b/target/linux/bcm53xx/base-files/etc/board.d/02_network
index f86f12407f..b3d614d6a2 100755
--- a/target/linux/bcm53xx/base-files/etc/board.d/02_network
+++ b/target/linux/bcm53xx/base-files/etc/board.d/02_network
@@ -36,6 +36,15 @@ bcm53xx_setup_interfaces()
ucidef_add_switch "switch0" \
"0:wan" "1:lan:4" "2:lan:3" "3:lan:2" "4:lan:1" "5@eth0"
;;
+ luxul,xap-1610-v1)
+ ucidef_add_switch "switch0" \
+ "0:lan" "1:lan" "5@eth0"
+ ucidef_set_interface_lan "eth0.1" "dhcp"
+ ;;
+ luxul,xwr-3150-v1)
+ ucidef_add_switch "switch0" \
+ "0:lan:1" "1:lan:2" "2:lan:3" "3:lan:4" "4:wan" "5@eth0"
+ ;;
phicomm,k3)
ucidef_add_switch "switch0" \
"0:lan" "1:lan" "2:lan" "3:wan" "5@eth0"
@@ -87,20 +96,28 @@ bcm53xx_setup_macs()
case "$board" in
asus,rt-ac87u)
etXmacaddr=$(nvram get et1macaddr)
+ offset=1
;;
dlink,dir-885l | \
netgear,r7900 | \
netgear,r8000 | \
netgear,r8500)
etXmacaddr=$(nvram get et2macaddr)
+ offset=1
+ ;;
+ luxul,xwr-3100v1 | \
+ luxul,xwr-3150-v1)
+ etXmacaddr=$(nvram get et0macaddr)
+ offset=5
;;
*)
etXmacaddr=$(nvram get et0macaddr)
+ offset=1
;;
esac
# If WAN MAC isn't explicitly set, calculate it using base MAC as reference.
- [ -z "$wan_macaddr" -a -n "$etXmacaddr" ] && wan_macaddr=$(macaddr_add "$etXmacaddr" 1)
+ [ -z "$wan_macaddr" -a -n "$etXmacaddr" ] && wan_macaddr=$(macaddr_add "$etXmacaddr" $offset)
[ -n "$wan_macaddr" ] && ucidef_set_interface_macaddr "wan" "$wan_macaddr"
}