aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/lantiq/xrx200
diff options
context:
space:
mode:
authorMartin Blumenstingl <martin.blumenstingl@googlemail.com>2020-06-07 15:07:28 +0200
committerHauke Mehrtens <hauke@hauke-m.de>2021-06-26 16:05:36 +0200
commitb1df48caac1b3f75a65768a5abf8de84801edbf0 (patch)
tree6a5f5e9ec3b0a1e2f07feb18a872fa830ecf990f /target/linux/lantiq/xrx200
parentdea4bae7c2b963af02e1e3e3bdb5cd656a5ea3d3 (diff)
downloadupstream-b1df48caac1b3f75a65768a5abf8de84801edbf0.tar.gz
upstream-b1df48caac1b3f75a65768a5abf8de84801edbf0.tar.bz2
upstream-b1df48caac1b3f75a65768a5abf8de84801edbf0.zip
lantiq: xrx200: switch the subtarget to the mainline DSA driver
Enable the XRX200 PMAC, GSWIP DSA tag and GSIP DSA drivers in the 5.4 kernel config. Update the existing vr9_*.dts{,i} to use the new Ethernet and switch drivers. Drop the swconfig package from the xrx200 target because swconfig doesn't manage DSA based switches. The new /etc/config/network format for the DSA driver is not compatible with the old (swconfig) based one. Show a message during sysupgrade notifying users about this change and asking them to start with a fresh config (or forcefully update and then migrate the config manually). Failsafe mode can now automatically bring up the first lan interface based on board.json including DSA based setups. Drop 05_set_preinit_iface_lantiq from the xRX200 sub-target as this is not needed anymore. For now we are keeping it for the ase, xway and xway_legacy until there's some confirmation that it can be dropped from there as well. While here, some boards also receive minor fixups: - Use LAN1 as LAN1 (according to a photo this port can also be configured as WAN) on the Buffalo WBMR-300HPD. This makes it easier to read the port mapping because otherwise we would have LAN{2,3,4} and WAN (which was the case for the non-DSA version previously). - vr9_avm_fritz3390.dts: move the "gpio" comment from port 0 and 1 to their corresponding PHYs - vr9_tplink_vr200.dtsi: move the "gpio" comment from port 0 to PHY 0 - vr9_tplink_tdw89x0.dtsi: move the "gpio" comment from port 0 to PHY 0 Acked-by: Aleksander Jan Bajkowski <A.Bajkowski@stud.elka.pw.edu.pl> Tested-by: Notupus <notpp46@googlemail.com> # TD-W9980/DM200/FRITZ 7430 Tested-by: Martin Schiller <ms@dev.tdt.de> # tested on TDT VR2020 Tested-by: Martin Schiller <ms@dev.tdt.de> # tested on TP-Link TD-W8980B Tested-by: Martin Schiller <ms@dev.tdt.de> # tested on ZyXEL P-2812HNU-F1 Tested-by: Daniel Kestrel <kestrel1974@t-online.de> # tested on Fritzbox 7490 Tested-by: Daniel Kestrel <kestrel1974@t-online.de> # tested on Fritzbox 3490 Tested-by: @jospezial <jospezial@gmx.de> # tested on VGV7510KW22 (o2 Box 6431) Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Diffstat (limited to 'target/linux/lantiq/xrx200')
-rw-r--r--target/linux/lantiq/xrx200/base-files/etc/board.d/02_network60
-rw-r--r--target/linux/lantiq/xrx200/base-files/etc/board.d/05_compat-version18
-rw-r--r--target/linux/lantiq/xrx200/config-5.1010
-rw-r--r--target/linux/lantiq/xrx200/config-5.411
-rw-r--r--target/linux/lantiq/xrx200/target.mk3
5 files changed, 52 insertions, 50 deletions
diff --git a/target/linux/lantiq/xrx200/base-files/etc/board.d/02_network b/target/linux/lantiq/xrx200/base-files/etc/board.d/02_network
index 476cc7eb8f..3122d40c92 100644
--- a/target/linux/lantiq/xrx200/base-files/etc/board.d/02_network
+++ b/target/linux/lantiq/xrx200/base-files/etc/board.d/02_network
@@ -11,65 +11,41 @@ lantiq_setup_interfaces()
local board="$1"
case "$board" in
- alphanetworks,asl56026)
- ucidef_add_switch "switch0" \
- "2:lan" "3:lan" "6t@eth0"
+ alphanetworks,asl56026|\
+ arcadyan,vg3503j)
+ ucidef_set_interface_lan "lan1 lan2"
;;
arcadyan,arv7519rw22)
- ucidef_add_switch "switch0" \
- "0:lan:5" "2:lan:3" "3:lan:4" "4:lan:1" "5:lan:2" "6t@eth0"
- ;;
- arcadyan,vg3503j)
- ucidef_add_switch "switch0" \
- "2:lan:2" "4:lan:1" "6t@eth0"
+ ucidef_set_interface_lan "lan1 lan2 lan3 lan4 lan5"
;;
arcadyan,vgv7510kw22-brn|\
- arcadyan,vgv7510kw22-nor)
- ucidef_add_switch "switch0" \
- "2:lan:2" "3:lan:1" "4:lan:4" "5:lan:3" "0:wan:5" "6t@eth0"
- ;;
+ arcadyan,vgv7510kw22-nor|\
arcadyan,vgv7519-brn|\
arcadyan,vgv7519-nor|\
+ bt,homehub-v5a|\
lantiq,easy80920-nand|\
- lantiq,easy80920-nor)
- ucidef_add_switch "switch0" \
- "0:lan:4" "1:lan:3" "2:lan:2" "4:lan:1" "5:wan:5" "6t@eth0"
+ lantiq,easy80920-nor|\
+ zyxel,p-2812hnu-f1|\
+ zyxel,p-2812hnu-f3)
+ ucidef_set_interfaces_lan_wan "lan1 lan2 lan3 lan4" "wan"
;;
avm,fritz3370-rev2-hynix|\
avm,fritz3370-rev2-micron|\
avm,fritz3390|\
avm,fritz7360sl|\
avm,fritz7360-v2|\
- avm,fritz7362sl)
- ucidef_add_switch "switch0" \
- "0:lan:3" "1:lan:4" "2:lan:2" "4:lan:1" "6t@eth0"
- ;;
- avm,fritz7430)
- ucidef_add_switch "switch0" \
- "2:lan:3" "3:lan:4" "4:lan:1" "5:lan:2" "6t@eth0"
- ;;
- bt,homehub-v5a)
- ucidef_add_switch "switch0" \
- "0:lan:3" "1:lan:4" "2:lan:2" "4:lan:1" "5:wan:5" "6t@eth0"
- ;;
- buffalo,wbmr-300hpd)
- ucidef_add_switch "switch0" \
- "5:lan:2" "2:lan:3" "3:lan:4" "4:wan:1" "6t@eth0"
- ;;
+ avm,fritz7362sl|\
+ avm,fritz7430|\
+ buffalo,wbmr-300hpd|\
tplink,tdw8970|\
- tplink,tdw8980)
- ucidef_add_switch "switch0" \
- "0:lan:2" "2:lan:3" "4:lan:4" "5:lan:1" "6t@eth0"
- ;;
+ tplink,tdw8980|\
tplink,vr200|\
tplink,vr200v)
- ucidef_add_switch "switch0" \
- "0:lan" "2:lan" "4:lan" "5:lan" "6t@eth0"
+ ucidef_set_interface_lan "lan1 lan2 lan3 lan4"
;;
- zyxel,p-2812hnu-f1|\
- zyxel,p-2812hnu-f3)
- ucidef_add_switch "switch0" \
- "0:lan" "1:lan" "2:lan" "4:lan" "5:wan" "6t@eth0"
+ avm,fritz7412|\
+ netgear,dm200)
+ ucidef_set_interface_lan "lan"
;;
*)
ucidef_set_interface_lan 'eth0'
diff --git a/target/linux/lantiq/xrx200/base-files/etc/board.d/05_compat-version b/target/linux/lantiq/xrx200/base-files/etc/board.d/05_compat-version
new file mode 100644
index 0000000000..45bef9385b
--- /dev/null
+++ b/target/linux/lantiq/xrx200/base-files/etc/board.d/05_compat-version
@@ -0,0 +1,18 @@
+#
+# Copyright (C) 2020 OpenWrt.org
+#
+
+. /lib/functions.sh
+. /lib/functions/uci-defaults.sh
+
+board_config_update
+
+case "$(board_name)" in
+ *)
+ ucidef_set_compat_version "1.1"
+ ;;
+esac
+
+board_config_flush
+
+exit 0
diff --git a/target/linux/lantiq/xrx200/config-5.10 b/target/linux/lantiq/xrx200/config-5.10
index 51d8b6dcdf..d231acda83 100644
--- a/target/linux/lantiq/xrx200/config-5.10
+++ b/target/linux/lantiq/xrx200/config-5.10
@@ -18,6 +18,7 @@ CONFIG_CRYPTO_ZSTD=y
CONFIG_EXTRA_FIRMWARE="lantiq/xrx200_phy11g_a14.bin lantiq/xrx200_phy11g_a22.bin lantiq/xrx200_phy22f_a14.bin lantiq/xrx200_phy22f_a22.bin"
CONFIG_EXTRA_FIRMWARE_DIR="firmware"
CONFIG_GENERIC_ALLOCATOR=y
+CONFIG_GRO_CELLS=y
CONFIG_HWMON=y
CONFIG_HW_RANDOM=y
CONFIG_ICPLUS_PHY=y
@@ -27,7 +28,7 @@ CONFIG_INPUT_EVDEV=y
CONFIG_INPUT_POLLDEV=y
CONFIG_INTEL_XWAY_PHY=y
# CONFIG_ISDN is not set
-CONFIG_LANTIQ_XRX200_LEGACY=y
+CONFIG_LANTIQ_XRX200=y
CONFIG_LZO_COMPRESS=y
CONFIG_LZO_DECOMPRESS=y
CONFIG_MIPS_MT=y
@@ -50,7 +51,12 @@ CONFIG_MTD_UBI=y
CONFIG_MTD_UBI_BEB_LIMIT=20
CONFIG_MTD_UBI_BLOCK=y
CONFIG_MTD_UBI_WL_THRESHOLD=4096
+CONFIG_NET_DEVLINK=y
+CONFIG_NET_DSA=y
+CONFIG_NET_DSA_LANTIQ_GSWIP=y
+CONFIG_NET_DSA_TAG_GSWIP=y
CONFIG_NET_FLOW_LIMIT=y
+CONFIG_NET_SWITCHDEV=y
CONFIG_NLS=y
CONFIG_NR_CPUS=2
CONFIG_PADATA=y
@@ -77,7 +83,6 @@ CONFIG_SMP=y
CONFIG_SMP_UP=y
CONFIG_SOC_TYPE_XWAY=y
CONFIG_SOC_XWAY=y
-CONFIG_SWCONFIG_LEDS=y
CONFIG_SYNC_R4K=y
CONFIG_SYS_SUPPORTS_SCHED_SMT=y
CONFIG_SYS_SUPPORTS_SMP=y
@@ -88,7 +93,6 @@ CONFIG_USB=y
CONFIG_USB_COMMON=y
CONFIG_USB_SUPPORT=y
CONFIG_XPS=y
-CONFIG_XRX200_PHY_FW=y
CONFIG_XXHASH=y
CONFIG_ZLIB_DEFLATE=y
CONFIG_ZLIB_INFLATE=y
diff --git a/target/linux/lantiq/xrx200/config-5.4 b/target/linux/lantiq/xrx200/config-5.4
index 4782014285..c24b89cb8f 100644
--- a/target/linux/lantiq/xrx200/config-5.4
+++ b/target/linux/lantiq/xrx200/config-5.4
@@ -17,6 +17,7 @@ CONFIG_CRYPTO_ZSTD=y
CONFIG_EXTRA_FIRMWARE="lantiq/xrx200_phy11g_a14.bin lantiq/xrx200_phy11g_a22.bin lantiq/xrx200_phy22f_a14.bin lantiq/xrx200_phy22f_a22.bin"
CONFIG_EXTRA_FIRMWARE_DIR="firmware"
CONFIG_GENERIC_ALLOCATOR=y
+CONFIG_GRO_CELLS=y
CONFIG_HWMON=y
CONFIG_ICPLUS_PHY=y
CONFIG_IFX_VPE_EXT=y
@@ -25,7 +26,7 @@ CONFIG_INPUT_EVDEV=y
CONFIG_INPUT_POLLDEV=y
CONFIG_INTEL_XWAY_PHY=y
# CONFIG_ISDN is not set
-CONFIG_LANTIQ_XRX200_LEGACY=y
+CONFIG_LANTIQ_XRX200=y
CONFIG_LZO_COMPRESS=y
CONFIG_LZO_DECOMPRESS=y
CONFIG_MIPS_MT=y
@@ -47,7 +48,12 @@ CONFIG_MTD_UBI=y
CONFIG_MTD_UBI_BEB_LIMIT=20
CONFIG_MTD_UBI_BLOCK=y
CONFIG_MTD_UBI_WL_THRESHOLD=4096
+CONFIG_NET_DEVLINK=y
+CONFIG_NET_DSA=y
+CONFIG_NET_DSA_LANTIQ_GSWIP=y
+CONFIG_NET_DSA_TAG_GSWIP=y
CONFIG_NET_FLOW_LIMIT=y
+CONFIG_NET_SWITCHDEV=y
CONFIG_NLS=y
CONFIG_NR_CPUS=2
CONFIG_PADATA=y
@@ -56,6 +62,7 @@ CONFIG_PCIEPORTBUS=y
CONFIG_PCIE_LANTIQ=y
CONFIG_PCI_DOMAINS=y
CONFIG_PCI_LANTIQ=y
+CONFIG_PHYLINK=y
CONFIG_PHY_LANTIQ_VRX200_PCIE=y
CONFIG_POWER_RESET_GPIO=y
CONFIG_POWER_SUPPLY=y
@@ -72,7 +79,6 @@ CONFIG_SENSORS_LTQ_CPUTEMP=y
CONFIG_SGL_ALLOC=y
CONFIG_SMP=y
CONFIG_SMP_UP=y
-CONFIG_SWCONFIG_LEDS=y
CONFIG_SYNC_R4K=y
CONFIG_SYS_SUPPORTS_SCHED_SMT=y
CONFIG_SYS_SUPPORTS_SMP=y
@@ -83,7 +89,6 @@ CONFIG_USB=y
CONFIG_USB_COMMON=y
CONFIG_USB_SUPPORT=y
CONFIG_XPS=y
-CONFIG_XRX200_PHY_FW=y
CONFIG_XXHASH=y
CONFIG_ZLIB_DEFLATE=y
CONFIG_ZLIB_INFLATE=y
diff --git a/target/linux/lantiq/xrx200/target.mk b/target/linux/lantiq/xrx200/target.mk
index f7dc8ac1c7..c89f4bb83c 100644
--- a/target/linux/lantiq/xrx200/target.mk
+++ b/target/linux/lantiq/xrx200/target.mk
@@ -15,8 +15,7 @@ DEFAULT_PACKAGES+=kmod-leds-gpio \
ltq-vdsl-app \
dsl-vrx200-firmware-xdsl-a \
dsl-vrx200-firmware-xdsl-b-patch \
- ppp-mod-pppoa \
- swconfig
+ ppp-mod-pppoa
define Target/Description
Lantiq XRX200