From: <markus.stockhausen@gmx.de>
To: <kuba@kernel.org>, "'Andrew Lunn'" <andrew@lunn.ch>
Cc: <linux@armlinux.org.uk>, <davem@davemloft.net>,
<edumazet@google.com>, <pabeni@redhat.com>,
<michael@fossekall.de>, <daniel@makrotopia.org>,
<netdev@vger.kernel.org>,
"'Chris Packham'" <Chris.Packham@alliedtelesis.co.nz>,
<hkallweit1@gmail.com>
Subject: AW: AW: [PATCH] net: phy: realtek: convert RTL8226-CG to c45 only
Date: Thu, 3 Jul 2025 08:18:00 +0200 [thread overview]
Message-ID: <012b01dbebe2$3e0da720$ba28f560$@gmx.de> (raw)
In-Reply-To:
Hi,
> Von: markus.stockhausen@gmx.de <markus.stockhausen@gmx.de>
> Gesendet: Donnerstag, 19. Juni 2025 08:23
>
> > Von: Chris Packham <Chris.Packham@alliedtelesis.co.nz>
> > Gesendet: Donnerstag, 19. Juni 2025 04:48
> >
> > So I did another check. If I clear INTF_SEL bits in SMI_GLB_CTRL the
> > switch will not detect the link status correctly. C45 MDIO access from
> > the kernel seems to work regardless.
> >
> > This is using the Realtek u-boot to do some HW init and my as yet
> > unpublished switchdev driver for the RTL9300. Something somewhere needs
> > to configure SMI_GLB_CTRL so the switch will get the port link status
> > correctly. It doesn't have to be the mdio driver, if I remove that code
> > completely everything still works (it's using the SMI_GLB_CTRL value
> > that has been put there by Realtek's U-Boot).
>
> Thanks for the test. This fits some of my observations but has other
> dependencies on polling. Some c45 registers are still blocked. To find
> a perfect solution that switches polling off/on and toggles the bus
> c22/c45 on demand will need a lot of testing.
>
> See also notes from my recent addition:
> https://github.com/openwrt/openwrt/blob/c9e934ffd87774a64fa0c8a2af92373ef1d0894f/target/linux/realtek/files-6.12/drivers/net/phy/rtl83xx-phy.c#L1172
>
> To sum it up. On those devices it is only safe to stay in a single
> clause access. Converting the RTL8226 from the current mixed
> mode access should be hopefully ok.
Is there anything else you want me to do?
Best regards.
Markus
prev parent reply other threads:[~2025-07-03 6:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-17 15:01 [PATCH] net: phy: realtek: convert RTL8226-CG to c45 only Markus Stockhausen
2025-06-17 15:36 ` Andrew Lunn
2025-06-18 6:03 ` AW: " markus.stockhausen
2025-06-18 21:27 ` Chris Packham
2025-06-19 2:47 ` Chris Packham
2025-06-19 6:23 ` AW: " markus.stockhausen
2025-07-03 6:18 ` markus.stockhausen [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='012b01dbebe2$3e0da720$ba28f560$@gmx.de' \
--to=markus.stockhausen@gmx.de \
--cc=Chris.Packham@alliedtelesis.co.nz \
--cc=andrew@lunn.ch \
--cc=daniel@makrotopia.org \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=kuba@kernel.org \
--cc=linux@armlinux.org.uk \
--cc=michael@fossekall.de \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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).