Netdev Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Vladimir Oltean <olteanv@gmail.com>
To: Andrew Lunn <andrew@lunn.ch>
Cc: David Miller <davem@davemloft.net>,
	netdev <netdev@vger.kernel.org>, Chris Healy <cphealy@gmail.com>,
	Vivien Didelot <vivien.didelot@gmail.com>
Subject: Re: [PATCH net-next 2/7] net: dsa: Add devlink regions support to DSA
Date: Mon, 17 Aug 2020 01:17:09 +0300	[thread overview]
Message-ID: <20200816221709.ugb6qf7k4koc3y43@skbuf> (raw)
In-Reply-To: <20200816220632.GA2294711@lunn.ch>

On Mon, Aug 17, 2020 at 12:06:32AM +0200, Andrew Lunn wrote:
> > Could we perhaps open-code these from the drivers themselves? There's
> > hardly any added value in DSA providing a "helper" for creation of
> > devlink resources (regions, shared buffers, etc).
>
> If we do change to open coding, would we remove the existing wrappers
> as well?
> 

Maybe?
I reckon one of the main reasons why DSA hides struct net_device is to
present a unified API for the ports that don't have one.
But with devlink we don't have that problem.

> > Take the ocelot/felix driver for example.
> 
> ocelot/felix is just plain odd. We have to do a balancing act for
> it. We don't want to take stuff out of the core just for this one odd
> switch, at the detriment for other normal DSA drivers.
> 

Yes, the ocelot/felix driver _is_ odd, but in my defence it's only as
odd as the hardware was integrated.
On the other hand, the model you're proposing would be forcing me to
register devlink regions in one way for felix DSA, and in another way
for ocelot switchdev. Or could I just ignore the helper, and call
devlink directly, even if there's a helper in place?

Thanks,
-Vladimir

  reply	other threads:[~2020-08-16 22:17 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-16 19:43 [PATCH net-next 0/7] net: dsa: mv88e6xxx: Add devlink regions support Andrew Lunn
2020-08-16 19:43 ` [PATCH net-next 1/7] net: dsa: Add helper to convert from devlink to ds Andrew Lunn
2020-08-17 17:08   ` Florian Fainelli
2020-08-16 19:43 ` [PATCH net-next 2/7] net: dsa: Add devlink regions support to DSA Andrew Lunn
2020-08-16 21:50   ` Vladimir Oltean
2020-08-16 22:06     ` Andrew Lunn
2020-08-16 22:17       ` Vladimir Oltean [this message]
2020-08-16 19:43 ` [PATCH net-next 3/7] net: dsa: mv88e6xxx: Move devlink code into its own file Andrew Lunn
2020-08-16 19:43 ` [PATCH net-next 4/7] net: dsa: mv88e6xxx: Create helper for FIDs in use Andrew Lunn
2020-08-16 19:43 ` [PATCH net-next 5/7] net: dsa: mv88e6xxx: Add devlink regions Andrew Lunn
2020-08-16 22:12   ` Vladimir Oltean
2020-08-16 22:39     ` Andrew Lunn
2020-08-17 17:15       ` Florian Fainelli
2020-08-17 19:02         ` Andrew Lunn
2020-08-16 19:43 ` [PATCH net-next 6/7] net: dsa: wire up devlink info get Andrew Lunn
2020-08-16 21:56   ` Vladimir Oltean
2020-08-16 22:16     ` Andrew Lunn
2020-08-16 19:43 ` [PATCH net-next 7/7] net: dsa: mv88e6xxx: Implement devlink info get callback Andrew Lunn
2020-08-17 16:03   ` Jakub Kicinski
2020-08-16 20:17 ` [PATCH net-next 0/7] net: dsa: mv88e6xxx: Add devlink regions support Chris Healy
2020-08-17 17:08 ` Florian Fainelli
2020-08-17 19:08   ` Andrew Lunn

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=20200816221709.ugb6qf7k4koc3y43@skbuf \
    --to=olteanv@gmail.com \
    --cc=andrew@lunn.ch \
    --cc=cphealy@gmail.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=vivien.didelot@gmail.com \
    --subject='Re: [PATCH net-next 2/7] net: dsa: Add devlink regions support to DSA' \
    /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

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).