From: Yao Zi <ziyao@disroot.org>
To: Xi Ruoyao <xry111@xry111.site>,
"Russell King (Oracle)" <linux@armlinux.org.uk>
Cc: Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Frank <Frank.Sae@motor-comm.com>,
Heiner Kallweit <hkallweit1@gmail.com>,
Vladimir Oltean <vladimir.oltean@nxp.com>,
Choong Yong Liang <yong.liang.choong@linux.intel.com>,
Chen-Yu Tsai <wens@csie.org>, Jisheng Zhang <jszhang@kernel.org>,
Furong Xu <0x1207@gmail.com>,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org,
Mingcong Bai <jeffbai@aosc.io>, Runhua He <hua@aosc.io>
Subject: Re: [PATCH net-next v2 2/3] net: stmmac: Add glue driver for Motorcomm YT6801 ethernet controller
Date: Tue, 18 Nov 2025 03:17:34 +0000 [thread overview]
Message-ID: <aRvlTra1DaPwnmU4@pie> (raw)
In-Reply-To: <f40bcb32b2bb47b83705706a0a326fc8e027ee00.camel@xry111.site>
On Sun, Nov 16, 2025 at 02:50:48PM +0800, Xi Ruoyao wrote:
> On Sat, 2025-11-15 at 11:46 +0000, Yao Zi wrote:
> > On Tue, Nov 11, 2025 at 12:32:56PM +0000, Russell King (Oracle) wrote:
> > > On Tue, Nov 11, 2025 at 10:52:51AM +0000, Yao Zi wrote:
> > > > + plat->bus_id = pci_dev_id(pdev);
> > > > + plat->phy_addr = -1;
> > > > + plat->phy_interface = PHY_INTERFACE_MODE_GMII;
> > > > + plat->clk_csr = STMMAC_CSR_20_35M;
> > >
> > > Could you include a comment indicating what the stmmac clock rate
> > > actually is (the rate which is used to derive this divider) ? As
> > > this is PCI, I'm guessing it's 33MHz, which fits with your divider
> > > value.
> >
> > The divider is taken from vendor driver, and the clock path isn't
> > mentioned in the datasheet, either. I don't think it's 33MHz since
> > it's
> > a PCIe chip, and there's no 33MHz clock supplied by PCIe.
> >
> > The datasheet[1] (Chinese website, requires login) mentions that the
> > controller requires a 25MHz external clock input/oscillator to
> > function,
> >
> > > 25MHz Crystal Input pin.
> > >
> > > If use external oscillator or clock from another device.
> > > 1. When connect an external 25MHz oscillator or clock from another
> > > device to XTAL_O pin, XTAL_I must be shorted to GND.
> > > 2. When connect an external 25MHz oscillator or clock from another
> > > device to XTAL_I pin, keep the XTAL_O floating.
> >
> > 25MHz fits in STMMAC_CSR_20_35M, too, so it's more likely the clock
> > source.
> >
> > I don't think this guess could be confirmed without vendor's help,
> > should the information be included as comment.
>
> I used the "beep" function of a multimeter to "probe" the connectivity
> of the two YT6801 chips on a XB612B0 V1.1 board. There are two 25 MHz
> oscillators on the board, each connected to a YT6801.
Sorry for not being clear here, I'm sure the controller requires an
oscillators to function (since the datasheet states so). What's unclear
here is whether the 20~35MHz clock provided for internal MDIO bus is
dervided from it.
Anyway, I would add a comment to mention this in v3. Thanks.
Best regards,
Yao Zi
> --
> Xi Ruoyao <xry111@xry111.site>
next prev parent reply other threads:[~2025-11-18 3:18 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-11 10:52 [PATCH net-next v2 0/3] Add DWMAC glue driver for Motorcomm YT6801 Yao Zi
2025-11-11 10:52 ` [PATCH net-next v2 1/3] net: phy: motorcomm: Support YT8531S PHY in YT6801 Ethernet controller Yao Zi
2025-11-11 10:52 ` [PATCH net-next v2 2/3] net: stmmac: Add glue driver for Motorcomm YT6801 ethernet controller Yao Zi
2025-11-11 11:07 ` Russell King (Oracle)
2025-11-15 11:27 ` Yao Zi
2025-11-11 12:32 ` Russell King (Oracle)
2025-11-15 11:46 ` Yao Zi
2025-11-16 6:50 ` Xi Ruoyao
2025-11-18 3:17 ` Yao Zi [this message]
2025-11-11 10:52 ` [PATCH net-next v2 3/3] MAINTAINERS: Assign myself as maintainer of Motorcomm DWMAC glue driver Yao Zi
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=aRvlTra1DaPwnmU4@pie \
--to=ziyao@disroot.org \
--cc=0x1207@gmail.com \
--cc=Frank.Sae@motor-comm.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=hkallweit1@gmail.com \
--cc=hua@aosc.io \
--cc=jeffbai@aosc.io \
--cc=jszhang@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=vladimir.oltean@nxp.com \
--cc=wens@csie.org \
--cc=xry111@xry111.site \
--cc=yong.liang.choong@linux.intel.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.