Netdev List
 help / color / mirror / Atom feed
From: Vladimir Oltean <olteanv@gmail.com>
To: "Russell King (Oracle)" <linux@armlinux.org.uk>
Cc: Andrew Lunn <andrew@lunn.ch>,
	Heiner Kallweit <hkallweit1@gmail.com>,
	Sergei Antonov <saproj@gmail.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	netdev@vger.kernel.org
Subject: Re: [PATCH net-next v2] net: dsa: mv88e6060: add phylink_get_caps implementation
Date: Thu, 10 Aug 2023 20:11:00 +0300	[thread overview]
Message-ID: <20230810171100.dvnsjgjo67hax4ld@skbuf> (raw)
In-Reply-To: <ZNUV2VzY01TWVSgk@shell.armlinux.org.uk>

On Thu, Aug 10, 2023 at 05:52:41PM +0100, Russell King (Oracle) wrote:
> I wonder whether we have any implementation using SNI mode. I couldn't
> find anything in the in-kernel dts files for this driver, the only
> dts we have is one that was posted on-list recently, and that was using
> MII at 100Mbps:
> 
> https://lore.kernel.org/r/CABikg9zfGVEJsWf7eq=K5oKQozt86LLn-rzMaVmycekXkQEa8Q@mail.gmail.com
> 
> No one would be able to specify "sni" in their dts, so maybe for the
> sake of simplicity, we shouldn't detect whether it's in SNI mode, and
> just use MII, and limit the speed to just 10Mbps?

Based on the fact that "marvell,mv88e6060" is in
dsa_switches_apply_workarounds[], it is technically possible that there
exist boards which use the SNI mode but have no phy-mode and other
phylink properties on the CPU port, and thus they work fine while
skipping phylink. Of course, "possible" != "real".

What I would like is to not discourage the board user to set phy-mode =
"sni" in the device tree if that's what PortMode in the Port Status
Register says that the port is strapped for. I'm afraid that by
intentionally ignoring that bit and putting PHY_INTERFACE_MODE_REVMII in
supported_interfaces, we're kind of suggesting to that person that this
is what is correct, as that is the only thing that would work without
modifying the kernel?

Maybe if we don't want to introduce PHY_INTERFACE_MODE_SNI for fear of a
lack of real users, we could at least detect PortMode=0, and not
populate supported_interfaces, leading to an intentional validation
failure and a comment above that check, stating that phy-mode = "sni" is
not yet implemented?

  reply	other threads:[~2023-08-10 17:11 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-09 14:46 [PATCH net-next v2] net: dsa: mv88e6060: add phylink_get_caps implementation Russell King (Oracle)
2023-08-10 16:44 ` Vladimir Oltean
2023-08-10 16:52   ` Russell King (Oracle)
2023-08-10 17:11     ` Vladimir Oltean [this message]
2023-08-10 17:38       ` Russell King (Oracle)
2023-08-10 18:17         ` Sergei Antonov
2023-08-10 18:31           ` Vladimir Oltean
2023-08-10 18:27         ` Vladimir Oltean
2023-08-10 18:09 ` Sergei Antonov

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=20230810171100.dvnsjgjo67hax4ld@skbuf \
    --to=olteanv@gmail.com \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=f.fainelli@gmail.com \
    --cc=hkallweit1@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=saproj@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