All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vladimir Oltean <vladimir.oltean@nxp.com>
To: Jakub Kicinski <kuba@kernel.org>
Cc: Xiaoliang Yang <xiaoliang.yang_1@nxp.com>,
	"davem@davemloft.net" <davem@davemloft.net>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"allan.nielsen@microchip.com" <allan.nielsen@microchip.com>,
	"joergen.andreasen@microchip.com"
	<joergen.andreasen@microchip.com>,
	"UNGLinuxDriver@microchip.com" <UNGLinuxDriver@microchip.com>,
	"vinicius.gomes@intel.com" <vinicius.gomes@intel.com>,
	"jiri@mellanox.com" <jiri@mellanox.com>,
	"idosch@mellanox.com" <idosch@mellanox.com>,
	"alexandre.belloni@bootlin.com" <alexandre.belloni@bootlin.com>,
	Po Liu <po.liu@nxp.com>, Leo Li <leoyang.li@nxp.com>,
	"f.fainelli@gmail.com" <f.fainelli@gmail.com>,
	"andrew@lunn.ch" <andrew@lunn.ch>,
	"vivien.didelot@gmail.com" <vivien.didelot@gmail.com>,
	Claudiu Manoil <claudiu.manoil@nxp.com>,
	"matthias.bgg@gmail.com" <matthias.bgg@gmail.com>,
	"horatiu.vultur@microchip.com" <horatiu.vultur@microchip.com>
Subject: Re: [PATCH v6 net-next 0/8] net: dsa: felix: psfp support on vsc9959
Date: Fri, 1 Oct 2021 23:17:07 +0000	[thread overview]
Message-ID: <20211001231706.szeo66plekzwszci@skbuf> (raw)
In-Reply-To: <20211001155936.48eec95d@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com>

On Fri, Oct 01, 2021 at 03:59:36PM -0700, Jakub Kicinski wrote:
> On Fri, 1 Oct 2021 22:46:34 +0000 Vladimir Oltean wrote:
> > On Fri, Oct 01, 2021 at 03:11:15PM -0700, Jakub Kicinski wrote:
> > > On Thu, 30 Sep 2021 15:59:40 +0800 Xiaoliang Yang wrote:  
> > > > VSC9959 hardware supports Per-Stream Filtering and Policing(PSFP).
> > > > This patch series add PSFP support on tc flower offload of ocelot
> > > > driver. Use chain 30000 to distinguish PSFP from VCAP blocks. Add gate
> > > > and police set to support PSFP in VSC9959 driver.  
> > >
> > > Vladimir, any comments?  
> > 
> > Sorry, I was intending to try out the patches and get an overall feel
> > from there, but I had an incredibly busy week and simply didn't have time.
> > If it's okay to wait a bit more I will do that tomorrow.
> 
> Take your time, I'll mark it as Deferred for now.

Thank you.

> Maybe I shouldn't comment based on the snippets of understanding but
> "steal some FDB entries" would be my first reaction.

No, it's absolutely reasonable. I feel like it's also going to be your
second reaction, and third, and...

The thing is, if we depend on the bridge driver's state only for this
snowflake piece of hardware, user experience is going to absolutely suck.
Having a selftest inside the kernel would be the litmus test we need for
deciding whether the way we expose the feature is sane or not.
The kernel should abstract the hardware and its quirks and provide a
standardized and abstract interface, that's literally its job. If you
tell me your hardware needs special massaging in this or that way, I'm
better off just using a random SDK.

> Xiaoliang said:
> 
> 	The PSFP gate and police action are set on ingress port, and
> 	"tc-filter" has no parameter to set the forward port for the
> 	filtered stream.
> 
> which seems to undersell TC.

I know, right? That's the loop we can't get out of, TSN is still pretty
much in its infancy, and with pre-standard hardware it's really difficult
to create software models that stand the test of time.
I've seen other hardware implementations for PSFP and they do use TCAM
and are strictly decoupled from the bridging service. Microchip say that
their newer hardware generations are also thought out this way. So while
yes, Ocelot is driving me crazy for special-casing the NULL stream
identification function and implementing it using bridge FDB entries
(because those types of flows only match on MAC DA and VLAN ID, somebody
thought "oh, I know something that can already do that!"). That is
definitely not what TSN streams in the general sense are about, and I do
feel that classifier-action pairs in TC are really the right software
model overall, from an application/user point of view.

  reply	other threads:[~2021-10-01 23:17 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-30  7:59 [PATCH v6 net-next 0/8] net: dsa: felix: psfp support on vsc9959 Xiaoliang Yang
2021-09-30  7:59 ` Xiaoliang Yang
2021-09-30  7:59 ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 1/8] net: mscc: ocelot: serialize access to the MAC table Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 2/8] net: mscc: ocelot: add MAC table stream learn and lookup operations Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 3/8] net: mscc: ocelot: set vcap IS2 chain to goto PSFP chain Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 4/8] net: mscc: ocelot: add gate and police action offload to PSFP Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 5/8] net: dsa: felix: support psfp filter on vsc9959 Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-10-06 13:13   ` Vladimir Oltean
2021-10-06 13:13     ` Vladimir Oltean
2021-10-06 13:13     ` Vladimir Oltean
2021-11-10 10:43     ` Xiaoliang Yang
2021-11-10 10:43       ` Xiaoliang Yang
2021-11-10 10:43       ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 6/8] net: dsa: felix: add stream gate settings for psfp Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 7/8] net: mscc: ocelot: use index to set vcap policer Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59 ` [PATCH v6 net-next 8/8] net: dsa: felix: use vcap policer to set flow meter for psfp Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-09-30  7:59   ` Xiaoliang Yang
2021-10-01 22:11 ` [PATCH v6 net-next 0/8] net: dsa: felix: psfp support on vsc9959 Jakub Kicinski
2021-10-01 22:46   ` Vladimir Oltean
2021-10-01 22:59     ` Jakub Kicinski
2021-10-01 23:17       ` Vladimir Oltean [this message]
2021-10-06 12:12         ` Vladimir Oltean
2021-11-10 10:32           ` Xiaoliang Yang

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=20211001231706.szeo66plekzwszci@skbuf \
    --to=vladimir.oltean@nxp.com \
    --cc=UNGLinuxDriver@microchip.com \
    --cc=alexandre.belloni@bootlin.com \
    --cc=allan.nielsen@microchip.com \
    --cc=andrew@lunn.ch \
    --cc=claudiu.manoil@nxp.com \
    --cc=davem@davemloft.net \
    --cc=f.fainelli@gmail.com \
    --cc=horatiu.vultur@microchip.com \
    --cc=idosch@mellanox.com \
    --cc=jiri@mellanox.com \
    --cc=joergen.andreasen@microchip.com \
    --cc=kuba@kernel.org \
    --cc=leoyang.li@nxp.com \
    --cc=matthias.bgg@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=po.liu@nxp.com \
    --cc=vinicius.gomes@intel.com \
    --cc=vivien.didelot@gmail.com \
    --cc=xiaoliang.yang_1@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.