[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210317174458.2349642-6-vladimir.oltean@nxp.com>
Date: Wed, 17 Mar 2021 19:44:58 +0200
From: Vladimir Oltean <vladimir.oltean@....com>
To: netdev@...r.kernel.org, "David S . Miller" <davem@...emloft.net>,
Jakub Kicinski <kuba@...nel.org>
Cc: Andrew Lunn <andrew@...n.ch>,
Florian Fainelli <f.fainelli@...il.com>,
Vivien Didelot <vivien.didelot@...il.com>,
Jiri Pirko <jiri@...nulli.us>,
Ido Schimmel <idosch@...sch.org>,
Stephen Rothwell <sfr@...b.auug.org.au>
Subject: [PATCH net-next 5/5] Documentation: networking: dsa: mention that the master is brought up automatically
Since commit 9d5ef190e561 ("net: dsa: automatically bring up DSA master
when opening user port"), DSA manages the administrative status of the
host port automatically. Update the configuration steps to reflect this.
Signed-off-by: Vladimir Oltean <vladimir.oltean@....com>
---
.../networking/dsa/configuration.rst | 29 ++++++++++++++-----
1 file changed, 21 insertions(+), 8 deletions(-)
diff --git a/Documentation/networking/dsa/configuration.rst b/Documentation/networking/dsa/configuration.rst
index d20b908bd861..774f0e76c746 100644
--- a/Documentation/networking/dsa/configuration.rst
+++ b/Documentation/networking/dsa/configuration.rst
@@ -34,8 +34,15 @@ interface. The CPU port is the switch port connected to an Ethernet MAC chip.
The corresponding linux Ethernet interface is called the master interface.
All other corresponding linux interfaces are called slave interfaces.
-The slave interfaces depend on the master interface. They can only brought up,
-when the master interface is up.
+The slave interfaces depend on the master interface being up in order for them
+to send or receive traffic. Prior to kernel v5.12, the state of the master
+interface had to be managed explicitly by the user. Starting with kernel v5.12,
+the behavior is as follows:
+
+- when a DSA slave interface is brought up, the master interface is
+ automatically brought up.
+- when the master interface is brought down, all DSA slave interfaces are
+ automatically brought down.
In this documentation the following Ethernet interfaces are used:
@@ -86,7 +93,8 @@ without using a VLAN based configuration.
ip addr add 192.0.2.5/30 dev lan2
ip addr add 192.0.2.9/30 dev lan3
- # The master interface needs to be brought up before the slave ports.
+ # For kernels earlier than v5.12, the master interface needs to be
+ # brought up manually before the slave ports.
ip link set eth0 up
# bring up the slave interfaces
@@ -97,7 +105,8 @@ without using a VLAN based configuration.
*bridge*
.. code-block:: sh
- # The master interface needs to be brought up before the slave ports.
+ # For kernels earlier than v5.12, the master interface needs to be
+ # brought up manually before the slave ports.
ip link set eth0 up
# bring up the slave interfaces
@@ -122,7 +131,8 @@ without using a VLAN based configuration.
*gateway*
.. code-block:: sh
- # The master interface needs to be brought up before the slave ports.
+ # For kernels earlier than v5.12, the master interface needs to be
+ # brought up manually before the slave ports.
ip link set eth0 up
# bring up the slave interfaces
@@ -165,7 +175,8 @@ configuration.
ip link add link eth0 name eth0.2 type vlan id 2
ip link add link eth0 name eth0.3 type vlan id 3
- # The master interface needs to be brought up before the slave ports.
+ # For kernels earlier than v5.12, the master interface needs to be
+ # brought up manually before the slave ports.
ip link set eth0 up
ip link set eth0.1 up
ip link set eth0.2 up
@@ -207,7 +218,8 @@ configuration.
# tag traffic on CPU port
ip link add link eth0 name eth0.1 type vlan id 1
- # The master interface needs to be brought up before the slave ports.
+ # For kernels earlier than v5.12, the master interface needs to be
+ # brought up manually before the slave ports.
ip link set eth0 up
ip link set eth0.1 up
@@ -246,7 +258,8 @@ configuration.
ip link add link eth0 name eth0.1 type vlan id 1
ip link add link eth0 name eth0.2 type vlan id 2
- # The master interface needs to be brought up before the slave ports.
+ # For kernels earlier than v5.12, the master interface needs to be
+ # brought up manually before the slave ports.
ip link set eth0 up
ip link set eth0.1 up
ip link set eth0.2 up
--
2.25.1
Powered by blists - more mailing lists