All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ansuel Smith <ansuelsmth@gmail.com>
To: Vladimir Oltean <vladimir.oltean@nxp.com>
Cc: "Vladimir Oltean" <olteanv@gmail.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"Jakub Kicinski" <kuba@kernel.org>,
	"Florian Fainelli" <f.fainelli@gmail.com>,
	"Vivien Didelot" <vivien.didelot@gmail.com>,
	"Andrew Lunn" <andrew@lunn.ch>,
	"Tobias Waldekranz" <tobias@waldekranz.com>,
	"Marek Behún" <kabel@kernel.org>,
	"DENG Qingfang" <dqfext@gmail.com>,
	"Alvin Šipraga" <alsi@bang-olufsen.dk>,
	"Claudiu Manoil" <claudiu.manoil@nxp.com>,
	"Alexandre Belloni" <alexandre.belloni@bootlin.com>,
	"UNGLinuxDriver@microchip.com" <UNGLinuxDriver@microchip.com>,
	"Colin Foster" <colin.foster@in-advantage.com>,
	"Linus Walleij" <linus.walleij@linaro.org>,
	"Luiz Angelo Daros de Luca" <luizluca@gmail.com>,
	"Roopa Prabhu" <roopa@nvidia.com>,
	"Nikolay Aleksandrov" <razor@blackwall.org>,
	"Frank Wunderlich" <frank-w@public-files.de>
Subject: Re: [RFC PATCH net-next 00/12] DSA changes for multiple CPU ports (part 3)
Date: Tue, 24 May 2022 14:38:53 +0200	[thread overview]
Message-ID: <628cd1e0.1c69fb81.d28b0.df81@mx.google.com> (raw)
In-Reply-To: <20220524122905.4y5kbpdjwvb6ee4p@skbuf>

On Tue, May 24, 2022 at 12:29:06PM +0000, Vladimir Oltean wrote:
> On Tue, May 24, 2022 at 02:02:19PM +0200, Ansuel Smith wrote:
> > Probably offtopic but I wonder if the use of a LAG as master can
> > cause some problem with configuration where the switch use a mgmt port
> > to send settings. Wonder if with this change we will have to introduce
> > an additional value to declare a management port that will be used since
> > master can now be set to various values. Or just the driver will have to
> > handle this with its priv struct (think this is the correct solution)
> > 
> > I still have to find time to test this with qca8k.
> 
> Not offtopic, this is a good point. dsa_tree_master_admin_state_change()
> and dsa_tree_master_oper_state_change() set various flags in cpu_dp =
> master->dsa_ptr. It's unclear if the cpu_dp we assign to a LAG should
> track the admin/oper state of the LAG itself or of the physical port.
> Especially since the lag->dsa_ptr is the same as one of the master->dsa_ptr.
> It's clear that the same structure can't track both states. I'm thinking
> we should suppress the NETDEV_CHANGE and NETDEV_UP monitoring from slave.c
> on LAG DSA masters, and track only the physical ones. In any case,
> management traffic does not really benefit from being sent/received over
> a LAG, and I'm thinking we should just use the physical port.
> Your qca8k_master_change() function explicitly only checks for CPU port
> 0, which in retrospect was a very wise decision in terms of forward
> compatibility with device trees with multiple CPU ports.

Switch can also have some hw limitation where mgmt packet are accepted
only by one specific port and I assume using a LAG with load balance can
cause some problem (packet not ack).

Yes I think the oper_state_change would be problematic with a LAG
configuration since the driver should use the pysical port anyway (to
prevent any hw limitation/issue) and track only that.

But I think we can put that on hold and think of a correct solution when
we have a solid base with all of this implemented. Considering qca8k
is the only user of that feature and things will have to change anyway
when qca8k will get support for multiple cpu port, we can address that
later. (in theory everything should work correctly if qca8k doesn't
declare multiple cpu port or a LAG is not confugred) 

-- 
	Ansuel

  reply	other threads:[~2022-05-24 12:39 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-23 10:42 [RFC PATCH net-next 00/12] DSA changes for multiple CPU ports (part 3) Vladimir Oltean
2022-05-23 10:42 ` [RFC PATCH net-next 01/12] net: introduce iterators over synced hw addresses Vladimir Oltean
2022-05-23 17:54   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 02/12] net: dsa: walk through all changeupper notifier functions Vladimir Oltean
2022-05-23 18:11   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 03/12] net: dsa: don't stop at NOTIFY_OK when calling ds->ops->port_prechangeupper Vladimir Oltean
2022-05-23 17:56   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 04/12] net: bridge: move DSA master bridging restriction to DSA Vladimir Oltean
2022-05-23 17:57   ` Florian Fainelli
2022-05-23 23:02   ` Nikolay Aleksandrov
2022-05-23 10:42 ` [RFC PATCH net-next 05/12] net: dsa: existing DSA masters cannot join upper interfaces Vladimir Oltean
2022-05-23 17:58   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 06/12] net: dsa: only bring down user ports assigned to a given DSA master Vladimir Oltean
2022-05-23 17:59   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 07/12] net: dsa: all DSA masters must be down when changing the tagging protocol Vladimir Oltean
2022-05-23 18:00   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 08/12] net: dsa: use dsa_tree_for_each_cpu_port in dsa_tree_{setup,teardown}_master Vladimir Oltean
2022-05-23 18:01   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 09/12] net: dsa: introduce dsa_port_get_master() Vladimir Oltean
2022-05-23 18:08   ` Florian Fainelli
2022-05-23 10:42 ` [RFC PATCH net-next 10/12] net: dsa: allow the DSA master to be seen and changed through rtnetlink Vladimir Oltean
2022-05-23 18:41   ` Florian Fainelli
2022-05-23 23:08     ` Vladimir Oltean
2022-05-23 10:42 ` [RFC PATCH net-next 11/12] net: dsa: allow masters to join a LAG Vladimir Oltean
2022-05-23 10:42 ` [RFC PATCH net-next 12/12] net: dsa: felix: add support for changing DSA master Vladimir Oltean
2022-05-23 21:53 ` [RFC PATCH net-next 00/12] DSA changes for multiple CPU ports (part 3) Florian Fainelli
2022-05-23 22:51   ` Vladimir Oltean
2022-05-24 12:02 ` Ansuel Smith
2022-05-24 12:29   ` Vladimir Oltean
2022-05-24 12:38     ` Ansuel Smith [this message]
2022-05-24 13:24       ` Vladimir Oltean

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=628cd1e0.1c69fb81.d28b0.df81@mx.google.com \
    --to=ansuelsmth@gmail.com \
    --cc=UNGLinuxDriver@microchip.com \
    --cc=alexandre.belloni@bootlin.com \
    --cc=alsi@bang-olufsen.dk \
    --cc=andrew@lunn.ch \
    --cc=claudiu.manoil@nxp.com \
    --cc=colin.foster@in-advantage.com \
    --cc=dqfext@gmail.com \
    --cc=f.fainelli@gmail.com \
    --cc=frank-w@public-files.de \
    --cc=kabel@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=luizluca@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=razor@blackwall.org \
    --cc=roopa@nvidia.com \
    --cc=tobias@waldekranz.com \
    --cc=vivien.didelot@gmail.com \
    --cc=vladimir.oltean@nxp.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.