netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: George McCollister <george.mccollister@gmail.com>
To: Vladimir Oltean <olteanv@gmail.com>
Cc: Jakub Kicinski <kuba@kernel.org>, Andrew Lunn <andrew@lunn.ch>,
	Vivien Didelot <vivien.didelot@gmail.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Jonathan Corbet <corbet@lwn.net>,
	netdev@vger.kernel.org
Subject: Re: [RESEND PATCH net-next 1/4] net: hsr: generate supervision frame without HSR tag
Date: Mon, 8 Feb 2021 09:26:51 -0600	[thread overview]
Message-ID: <CAFSKS=MVcQq3812us46HW2sK4uYoWxUbTvEDwH3dMF5b6bvohw@mail.gmail.com> (raw)
In-Reply-To: <20210206234324.wk676psq3mwslud4@skbuf>

On Sat, Feb 6, 2021 at 5:43 PM Vladimir Oltean <olteanv@gmail.com> wrote:
>
> On Tue, Feb 02, 2021 at 08:49:25AM -0600, George McCollister wrote:
> > > > > Why is it such a big deal if supervision frames have HSR/PRP tag or not?
> > > >
> > > > Because if the switch does automatic HSR/PRP tag insertion it will end
> > > > up in there twice. You simply can't send anything with an HSR/PRP tag
> > > > if this is offloaded.
> > >
> > > When exactly will your hardware push a second HSR tag when the incoming
> > > packet already contains one? Obviously for tagged packets coming from
> > > the ring it should not do that. It must be treating the CPU port special
> > > somehow, but I don't understand how.
> >
> > From the datasheet I linked before:
> > "At input the HSR tag is always removed if the port is in HSR mode. At
> > output a HSR tag is added if the output port is in HSR mode."
> > I don't see a great description of what happens internally when it's
> > forwarding from one redundant port to the other when in HSR (not PRP)
> > but perhaps it strips off the tag information, saves it and reapplies
> > it as it's going out? The redundant ports are in HSR mode, the CPU
> > facing port is not. Anyway I can tell you from using it, it does add a
> > second HSR tag if the CPU port sends a frame with one and the frames
> > going between the ring redundancy ports are forwarded with their
> > single tag.
>
> So if I understand correctly, the CPU port is configured as an interlink
> port, which according to the standard can operate in 3 modes:
> 1) HSR-SAN: the traffic on the interlink is not HSR, not PRP
> 2) HSR-PRP: the traffic on the interlink is PRP-tagged as “A” or “B”
> 3) HSR-HSR the traffic on the interlink is HSR-tagged.
>
> What you are saying is equivalent to the CPU port being configured for a
> HSR-SAN interlink. If the CPU port was configured as HSR-HSR interlink,
> this change would have not been necessary.
>
> However 6.7 Allowed Port Modes of the XRS7000 datasheet you shared says:
>
> | Not every port of XRS is allowed to be configured in every mode, Table
> | 25 lists the allowed modes for each port.
>
> That table basically says that while any port can operate as a 'non-HSR,
> non-PRP' interlink, only port 3 of the XRS7004 can operate as an HSR
> interlink. So it is more practical to you to leave the CPU port as a
> normal interlink and leave the switch push the tags.

If one were to set "HSR/PRP enabled" and "Port is HSR/PRP interlink
port" in HSR_CFG on the CPU port it wouldn't be possible (per the
datasheet) to enable the management or PTP timer trailer. Those modes
are intended for interlinking with a second HSR/PRP switch's
interlink. I was trying to keep this commit message somewhat switch
model agnostic and not dive into the details of the XRS7000 series. Do
you think I should describe all of this in detail in this commit
message?

-George

  reply	other threads:[~2021-02-08 15:30 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-01 14:04 [RESEND PATCH net-next 0/4] add HSR offloading support for DSA switches George McCollister
2021-02-01 14:05 ` [RESEND PATCH net-next 1/4] net: hsr: generate supervision frame without HSR tag George McCollister
2021-02-01 14:59   ` Vladimir Oltean
2021-02-01 19:43     ` George McCollister
2021-02-02  0:37       ` Vladimir Oltean
2021-02-02 14:49         ` George McCollister
2021-02-03 21:16           ` Vladimir Oltean
2021-02-06 23:43           ` Vladimir Oltean
2021-02-08 15:26             ` George McCollister [this message]
2021-02-01 14:05 ` [RESEND PATCH net-next 2/4] net: hsr: add offloading support George McCollister
2021-02-01 15:23   ` Vladimir Oltean
2021-02-01 20:15     ` George McCollister
2021-02-03 20:43     ` George McCollister
2021-02-01 14:05 ` [RESEND PATCH net-next 3/4] net: dsa: add support for offloading HSR George McCollister
2021-02-01 14:05 ` [RESEND PATCH net-next 4/4] net: dsa: xrs700x: add HSR offloading support George McCollister
2021-02-01 15:29   ` Vladimir Oltean
2021-02-01 21:25     ` George McCollister

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='CAFSKS=MVcQq3812us46HW2sK4uYoWxUbTvEDwH3dMF5b6bvohw@mail.gmail.com' \
    --to=george.mccollister@gmail.com \
    --cc=andrew@lunn.ch \
    --cc=corbet@lwn.net \
    --cc=f.fainelli@gmail.com \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=vivien.didelot@gmail.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).