From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: Andrew Lunn <andrew@lunn.ch>
Cc: Martyn Welch <martyn.welch@collabora.com>,
Vivien Didelot <vivien.didelot@gmail.com>,
Florian Fainelli <f.fainelli@gmail.com>,
Vladimir Oltean <olteanv@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
netdev@vger.kernel.org
Subject: Re: [PATCH RFC net] net: dsa: mv88e6xxx: allow use of PHYs on CPU and DSA ports
Date: Tue, 7 Dec 2021 15:28:07 +0000 [thread overview]
Message-ID: <Ya99h4RmUMmqYrSR@shell.armlinux.org.uk> (raw)
In-Reply-To: <Ya94roatTK0y7t70@lunn.ch>
On Tue, Dec 07, 2021 at 04:07:26PM +0100, Andrew Lunn wrote:
> On Tue, Dec 07, 2021 at 02:58:26PM +0000, Russell King (Oracle) wrote:
> > On Tue, Dec 07, 2021 at 03:54:37PM +0100, Andrew Lunn wrote:
> > > On Tue, Dec 07, 2021 at 10:59:19AM +0000, Russell King (Oracle) wrote:
> > > > Martyn Welch reports that his CPU port is unable to link where it has
> > > > been necessary to use one of the switch ports with an internal PHY for
> > > > the CPU port. The reason behind this is the port control register is
> > > > left forcing the link down, preventing traffic flow.
> > > >
> > > > This occurs because during initialisation, phylink expects the link to
> > > > be down, and DSA forces the link down by synthesising a call to the
> > > > DSA drivers phylink_mac_link_down() method, but we don't touch the
> > > > forced-link state when we later reconfigure the port.
> > > >
> > > > Resolve this by also unforcing the link state when we are operating in
> > > > PHY mode and the PPU is set to poll the PHY to retrieve link status
> > > > information.
> > > >
> > > > Reported-by: Martyn Welch <martyn.welch@collabora.com>
> > > > Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
> > >
> > > Hi Russell
> > >
> > > It would be good to have a Fixes: tag here, to help with back porting.
> >
> > Oh, I thought this was a new development, not a regression. Do you have
> > a pointer to the earlier bits of the thread please, e.g. the message ID
> > of the original report.
>
> This all seems to be part of:
>
> b98043f66e8c6f1fd75d11af7b28c55018c58d79.camel@collabora.com
>
> It looks like 5.15-rc3 has issues, but i suspect it goes back further.
> I'm also assuming it is a regression, not that it never worked in the
> first place. Maybe i'm wrong?
Thanks.
It looks like DT support for this was added in e26dead44268, which is
in v4.16-rc1.
The introduction of the phylink_mac_link_down() in net/dsa/port.c was
in 3be98b2d5fbc, v5.7-rc2, as was the addition of MLO_AN_FIXED in
mv88e6xxx DSA link down/up functions in 34b5e6a33c1a (these are
consecutive commits.)
Thankfully, the addition of mv88e6xxx_port_ppu_updates was in v5.7-rc1.
Now, this patch can't simply be backported without the update to
mv88e6xxx_port_ppu_updates(), so I feel we need to invent a Requires:
or Depends: tag so stable people don't backport this without the other
patch - my recent experience with stable is that patches get picked up
quite randomly.
I think I'd be tempted to go with:
Fixes: 3be98b2d5fbc ("net: dsa: Down cpu/dsa ports phylink will control")
I think we also need:
Cc: <stable@vger.kernel.org> # v5.7-rc2: xxxxx: net: dsa: mv88e6xxx: fix "don't use PHY_DETECT on internal PHY's"
which seems to be a thing according to stable-kernel-rules.rst...
with the xxxxx replaced with the proper sha1 ID once the dependent
patch has been applied to the net tree.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 40Mbps down 10Mbps up. Decent connectivity at last!
prev parent reply other threads:[~2021-12-07 15:28 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-07 10:59 [PATCH RFC net] net: dsa: mv88e6xxx: allow use of PHYs on CPU and DSA ports Russell King (Oracle)
2021-12-07 12:47 ` Martyn Welch
2021-12-07 12:58 ` Russell King (Oracle)
2021-12-07 14:20 ` Martyn Welch
2021-12-07 14:23 ` Russell King (Oracle)
2021-12-07 14:54 ` Andrew Lunn
2021-12-07 14:58 ` Russell King (Oracle)
2021-12-07 15:07 ` Andrew Lunn
2021-12-07 15:28 ` Russell King (Oracle) [this message]
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=Ya99h4RmUMmqYrSR@shell.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--cc=kuba@kernel.org \
--cc=martyn.welch@collabora.com \
--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).