From: Florian Fainelli <f.fainelli@gmail.com>
To: Lukasz Majewski <lukma@denx.de>,
Vladimir Oltean <olteanv@gmail.com>,
Jakub Kicinski <kuba@kernel.org>,
netdev@vger.kernel.org, Paolo Abeni <pabeni@redhat.com>
Cc: Eric Dumazet <edumazet@google.com>,
"David S. Miller" <davem@davemloft.net>,
Oleksij Rempel <o.rempel@pengutronix.de>,
Tristram.Ha@microchip.com,
Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
Simon Horman <horms@kernel.org>,
Dan Carpenter <dan.carpenter@linaro.org>,
"Ricardo B. Marliere" <ricardo@marliere.net>,
Casper Andersson <casper.casan@gmail.com>,
linux-kernel@vger.kernel.org,
Woojung Huh <woojung.huh@microchip.com>,
UNGLinuxDriver@microchip.com, Andrew Lunn <andrew@lunn.ch>
Subject: Re: [PATCH v3 net-next] net: dsa: ksz_common: Allow only up to two HSR HW offloaded ports for KSZ9477
Date: Wed, 19 Jun 2024 16:25:23 +0100 [thread overview]
Message-ID: <b76a1dc8-f4b2-46b0-84af-b46e5cf6acab@gmail.com> (raw)
In-Reply-To: <20240619145809.1252915-1-lukma@denx.de>
On 6/19/2024 3:58 PM, Lukasz Majewski wrote:
> The KSZ9477 allows HSR in-HW offloading for any of two selected ports.
> This patch adds check if one tries to use more than two ports with
> HSR offloading enabled.
>
> The problem is with RedBox configuration (HSR-SAN) - when configuring:
> ip link add name hsr0 type hsr slave1 lan1 slave2 lan2 interlink lan3 \
> supervision 45 version 1
>
> The lan1 (port0) and lan2 (port1) are correctly configured as ports, which
> can use HSR offloading on ksz9477.
>
> However, when we do already have two bits set in hsr_ports, we need to
> return (-ENOTSUPP), so the interlink port (lan3) would be used with
> SW based HSR RedBox support.
>
> Otherwise, I do see some strange network behavior, as some HSR frames are
> visible on non-HSR network and vice versa.
>
> This causes the switch connected to interlink port (lan3) to drop frames
> and no communication is possible.
>
> Moreover, conceptually - the interlink (i.e. HSR-SAN port - lan3/port2)
> shall be only supported in software as it is also possible to use ksz9477
> with only SW based HSR (i.e. port0/1 -> hsr0 with offloading, port2 ->
> HSR-SAN/interlink, port4/5 -> hsr1 with SW based HSR).
>
> Fixes: 5055cccfc2d1 ("net: hsr: Provide RedBox support (HSR-SAN)")
> Signed-off-by: Lukasz Majewski <lukma@denx.de>
> Reviewed-by: Andrew Lunn <andrew@lunn.ch>
> Reviewed-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
--
Florian
next prev parent reply other threads:[~2024-06-19 15:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-06-19 14:58 [PATCH v3 net-next] net: dsa: ksz_common: Allow only up to two HSR HW offloaded ports for KSZ9477 Lukasz Majewski
2024-06-19 15:25 ` Florian Fainelli [this message]
2024-06-21 9:20 ` patchwork-bot+netdevbpf
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=b76a1dc8-f4b2-46b0-84af-b46e5cf6acab@gmail.com \
--to=f.fainelli@gmail.com \
--cc=Tristram.Ha@microchip.com \
--cc=UNGLinuxDriver@microchip.com \
--cc=andrew@lunn.ch \
--cc=bigeasy@linutronix.de \
--cc=casper.casan@gmail.com \
--cc=dan.carpenter@linaro.org \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lukma@denx.de \
--cc=netdev@vger.kernel.org \
--cc=o.rempel@pengutronix.de \
--cc=olteanv@gmail.com \
--cc=pabeni@redhat.com \
--cc=ricardo@marliere.net \
--cc=woojung.huh@microchip.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).