IPQ40xx Switch Config "Strangeness" (swconfig)

Hi...
I'm one of the developers that managed to get support for the EA6350v3. Studying the OEM firmware, I managed to get a solution for reverting back to stock. And now I want to get involved into this.

Again, by studying the OEM firmware I found this piece of text:

# switch configuration
#
# Defines how the interfaces (switches) are configured. This information is
# used by linkstate, linkmgr, and other processes to access the correct ports
# for information, and in case of Broadcom, this is also used to configure
# the switches.
#
# Each interface is numbered by mode.
# <mode> is currently "router" or "bridge"
#
# switch::<mode>_max - the number of interfaces defined for this mode
#
# switch::<mode>_#::<parameters> - where parameters are vendor dependent
#   Required:
#     ifname - the OS interface name
#     physical_ifname - the physical interface (may be the same as ifname)
#     port_numbers - list of ports that belong to this interface
#     port_names - list of human-readable names for each port
#     wan_monitor_port - the port to be monitored (but only if this is WAN)
#   Optional (vendor dependent):
#     vlan_num - if vlan is used, the vlan number
#     cpu_port_number - number designated as CPU port
#     driver_hw_name - name of the Ethernet device (according to Broadcom
#                      driver) for this interface
#     interface_suffix - can be empty, "*" (default), or "u" (untag)
#

# router mode
$switch::router_max=2

$switch::router_1::ifname=eth1
$switch::router_1::physical_ifname=eth1
$switch::router_1::port_numbers=1 2 3 4
$switch::router_1::port_names=port1 port2 port3 port4

$switch::router_2::ifname=eth0
$switch::router_2::physical_ifname=eth0
$switch::router_2::port_numbers=5
$switch::router_2::port_names=wan
$switch::router_2::wan_monitor_port=5

# bridge mode
$switch::bridge_max=1

$switch::bridge_1::ifname=eth1
$switch::bridge_1::physical_ifname=eth1
$switch::bridge_1::port_numbers=1 2 3 4 5
$switch::bridge_1::port_names=port1 port2 port3 port4 wan
$switch::bridge_1::wan_monitor_port=5

I'm modifying the firmware now because given that it works currently by adding the port 5 in /etc/config/network, and given the fragment cited above from Linksys, I think that:

  1. Exposing the CPU eth1 port
  2. Exposing the port 5 as “wan” role
    Will fix the problem of configuring the switch in the LuCI UI.

If you have a Linksys EA6350v3, you may want to test the next build (v0.17) and provide me with feedback as I have no Ethernet devices to test (100% wireless ;).

2 Likes