mbox series

[net-next,0/4] Automatically manage DSA master interface state

Message ID 20210127010028.1619443-1-olteanv@gmail.com (mailing list archive)
Headers show
Series Automatically manage DSA master interface state | expand

Message

Vladimir Oltean Jan. 27, 2021, 1 a.m. UTC
From: Vladimir Oltean <vladimir.oltean@nxp.com>

This patch series adds code that makes DSA open the master interface
automatically whenever one user interface gets opened, either by the
user, or by various networking subsystems: netconsole, nfsroot.
With that in place, we can remove some of the places in the network
stack where DSA-specific code was sprinkled.

Vladimir Oltean (4):
  net: dsa: automatically bring up DSA master when opening user port
  net: dsa: automatically bring user ports down when master goes down
  Revert "net: Have netpoll bring-up DSA management interface"
  Revert "net: ipv4: handle DSA enabled master network devices"

 Documentation/networking/dsa/dsa.rst |  4 ---
 net/core/netpoll.c                   | 22 +++------------
 net/dsa/slave.c                      | 40 ++++++++++++++++++++++++++--
 net/ipv4/ipconfig.c                  | 21 ++++++++++++---
 4 files changed, 59 insertions(+), 28 deletions(-)

Comments

Vladimir Oltean Jan. 27, 2021, 12:03 p.m. UTC | #1
On Wed, Jan 27, 2021 at 03:25:46AM +0200, Vladimir Oltean wrote:
> Please treat this as RFC. There's still some debugging I need to do with
> nfsroot.

Sorry, please treat this as non-RFC again. The problem I had with
nfsroot was completely unrelated.
Florian Fainelli Jan. 28, 2021, 1:03 a.m. UTC | #2
On 1/26/2021 5:00 PM, Vladimir Oltean wrote:
> From: Vladimir Oltean <vladimir.oltean@nxp.com>
> 
> This patch series adds code that makes DSA open the master interface
> automatically whenever one user interface gets opened, either by the
> user, or by various networking subsystems: netconsole, nfsroot.
> With that in place, we can remove some of the places in the network
> stack where DSA-specific code was sprinkled.
> 
> Vladimir Oltean (4):
>   net: dsa: automatically bring up DSA master when opening user port
>   net: dsa: automatically bring user ports down when master goes down
>   Revert "net: Have netpoll bring-up DSA management interface"
>   Revert "net: ipv4: handle DSA enabled master network devices"

I really like all patches but number #2, though I don't believe there
are existing use cases besides you one you described where it makes
sense to keep a switch in an unmanaged mode being "headless" with its
CPU port down, while the user-facing ports are up.
Vladimir Oltean Jan. 28, 2021, 1:30 a.m. UTC | #3
On Wed, Jan 27, 2021 at 05:03:23PM -0800, Florian Fainelli wrote:
> I really like all patches but number #2, though I don't believe there
> are existing use cases besides you one you described where it makes
> sense to keep a switch in an unmanaged mode being "headless" with its
> CPU port down, while the user-facing ports are up.

So what should I do with #2? Every other stacked interface goes down
when its lowers go down, if that brings any consolation.
Florian Fainelli Jan. 28, 2021, 1:55 a.m. UTC | #4
On 1/27/2021 5:30 PM, Vladimir Oltean wrote:
> On Wed, Jan 27, 2021 at 05:03:23PM -0800, Florian Fainelli wrote:
>> I really like all patches but number #2, though I don't believe there
>> are existing use cases besides you one you described where it makes
>> sense to keep a switch in an unmanaged mode being "headless" with its
>> CPU port down, while the user-facing ports are up.
> 
> So what should I do with #2? Every other stacked interface goes down
> when its lowers go down, if that brings any consolation.

I suppose it does, part of me may have just grown too used to existing
model and fear a change.