rt3200: add DSA

this creates a bunch of network interfaces {lan[1234],wan}@eth0
This commit is contained in:
Daniel Barlow 2023-10-02 18:59:23 +01:00
parent c18f07f02f
commit b8dea2ed34

View file

@ -40,7 +40,6 @@
ARCH_MEDIATEK = "y"; ARCH_MEDIATEK = "y";
# ARM_MEDIATEK_CPUFREQ = "y"; # ARM_MEDIATEK_CPUFREQ = "y";
# needed for "Cannot find regmap for /infracfg@10000000" # needed for "Cannot find regmap for /infracfg@10000000"
MFD_SYSCON = "y"; MFD_SYSCON = "y";
MTK_INFRACFG = "y"; MTK_INFRACFG = "y";
@ -85,6 +84,12 @@
MMC_CQHCI = "y"; MMC_CQHCI = "y";
MMC_MTK = "y"; MMC_MTK = "y";
# Distributed Switch Architecture is needed
# to make the ethernet ports visible
NET_DSA="y";
NET_DSA_MT7530="y";
NET_DSA_TAG_MTK="y";
PSTORE = "y"; PSTORE = "y";
PSTORE_RAM = "y"; PSTORE_RAM = "y";
PSTORE_CONSOLE = "y"; PSTORE_CONSOLE = "y";
@ -129,12 +134,18 @@
flash.eraseBlockSize = "65536"; # c.f. pkgs/mips-vm/mips-vm.sh flash.eraseBlockSize = "65536"; # c.f. pkgs/mips-vm/mips-vm.sh
networkInterfaces = networkInterfaces =
let inherit (config.system.service.network) link; let
in { inherit (config.system.service.network) link;
wan = link.build { ifname = "eth0"; }; inherit (config.system.service) bridge;
lan = link.build { ifname = "eth1"; }; in rec {
wan = link.build { ifname = "wan"; };
lan1 = link.build { ifname = "lan1"; };
lan2 = link.build { ifname = "lan2"; };
lan3 = link.build { ifname = "lan3"; };
lan4 = link.build { ifname = "lan4"; };
lan = lan3;
wlan_24 = link.build { wlan = link.build {
ifname = "wlan0"; ifname = "wlan0";
dependencies = [ mac80211 ]; dependencies = [ mac80211 ];
}; };