Lines Matching +full:in +full:- +full:ports

1 .. SPDX-License-Identifier: GPL-2.0
10 .. _dsa-config-showcases:
13 -----------------------
15 To configure a DSA switch a couple of commands need to be executed. In this
37 The user interfaces depend on the conduit interface being up in order for them
42 - when a DSA user interface is brought up, the conduit interface is
44 - when the conduit interface is brought down, all DSA user interfaces are
47 In this documentation the following Ethernet interfaces are used:
71 * lan1: 192.0.2.1/30 (192.0.2.0 - 192.0.2.3)
72 * lan2: 192.0.2.5/30 (192.0.2.4 - 192.0.2.7)
73 * lan3: 192.0.2.9/30 (192.0.2.8 - 192.0.2.11)
76 * br0: 192.0.2.129/25 (192.0.2.128 - 192.0.2.255)
79 * br0: 192.0.2.129/25 (192.0.2.128 - 192.0.2.255)
80 * wan: 192.0.2.1/30 (192.0.2.0 - 192.0.2.3)
82 .. _dsa-tagged-configuration:
85 ----------------------------------
92 .. code-block:: sh
100 # brought up manually before the user ports.
109 .. code-block:: sh
112 # brought up manually before the user ports.
123 # add ports to bridge
135 .. code-block:: sh
138 # brought up manually before the user ports.
152 # add ports to bridge
162 .. _dsa-vlan-configuration:
165 -------------------------------------
174 .. code-block:: sh
182 # brought up manually before the user ports.
199 # add ports to bridges
204 # tag traffic on ports
219 .. code-block:: sh
225 # brought up manually before the user ports.
240 # add ports to bridge
246 # tag traffic on ports
258 .. code-block:: sh
265 # brought up manually before the user ports.
281 # add ports to bridges
287 # tag traffic on ports
300 ------------------------------------
303 the software FDB of the bridge in sync with the hardware tables, so the two
313 .. code-block:: sh
325 .. code-block:: sh
340 Between kernel v4.14 and v5.14, DSA has supported in parallel two modes of
342 well as a new mode using the ``master`` flag which installs FDB entries in the
345 .. code-block:: sh
351 the ``self`` flag) has been removed. This results in the following changes:
353 .. code-block:: sh
367 Affinity of user ports to CPU ports
368 -----------------------------------
371 interface, but in cases where the switch chip is discrete, the hardware design
372 may permit the use of 2 or more ports connected to the host, for an increase in
375 DSA can make use of multiple CPU ports in two ways. First, it is possible to
378 custom policies of static load balancing between user ports, by spreading the
379 affinities according to the available CPU ports.
381 Secondly, it is possible to perform load balancing between CPU ports on a per
382 packet basis, rather than statically assigning user ports to CPU ports.
385 on the CPU ports facing the physical DSA conduits that constitute the LAG slave
388 To make use of multiple CPU ports, the firmware (device tree) description of
389 the switch must mark all the links between CPU ports and their DSA conduits
391 and DSA conduit will be used - the numerically first port from the firmware
404 .. code-block:: sh
406 # See the DSA conduit in current use
407 ip -d link show dev swp0
417 # CPU ports in LAG, using explicit assignment of the DSA conduit
418 ip link add bond0 type bond mode balance-xor && ip link set bond0 up
425 ip -d link show dev swp0
429 # CPU ports in LAG, relying on implicit migration of the DSA conduit
430 ip link add bond0 type bond mode balance-xor && ip link set bond0 up
433 ip -d link show dev swp0
437 Notice that in the case of CPU ports under a LAG, the use of the
440 and migrates all user ports to the new upper of ``eth0``, ``bond0``. Similarly,
441 when ``bond0`` is destroyed using ``RTM_DELLINK``, DSA migrates the user ports
446 In a setup with more than 2 physical CPU ports, it is therefore possible to mix
449 upper interfaces (this includes LAG devices - the conduit must always be the LAG
450 in this case).
453 permitted, in order to allow dynamic redistribution in response to traffic.