The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Inochi Amaoto <inochiama@gmail.com>
To: Andrew Rembrandt <kernel@rembrandt.dev>,
	 Inochi Amaoto <inochiama@gmail.com>
Cc: Yixun Lan <dlan@kernel.org>,
	linux-riscv@lists.infradead.org,  spacemit@lists.linux.dev,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] riscv: dts: spacemit: k3-pico-itx: Fix non-functional ethernet TX timing
Date: Wed, 10 Jun 2026 07:14:56 +0800	[thread overview]
Message-ID: <aiid4Y6x6Dbbwszf@inochi.infowork> (raw)
In-Reply-To: <aihYftGNcpUd4UUR@mcmanus>

On Tue, Jun 09, 2026 at 08:24:46PM +0200, Andrew Rembrandt wrote:
> On Tue, Jun 09, 2026 at 01:37:56 pm Inochi Amaoto wrote:
> > You should set tx-internal-delay-ps of the phy instead of
> > the controller. This is a phy in "rgmii-id" mode.
> Thanks for the review. I don't think that works on this board, but
> please let me know if I'm missing something.
> 
> The PHY is a Realtek RTL8211F. Its driver only toggles the chip's fixed
> ~2ns delay on/off from phy-mode, and per the datasheet that's a hardware
> limit, not a driver one -- the RTL8211F has no tunable delay, so a ps
> value on the PHY node has nothing to act on.
> 
> The only configurable delay element on K3 is the SoC RGMII delay line,
> and dwmac-spacemit programs it from tx-/rx-internal-delay-ps read off
> the controller node (spacemit_dwmac_probe()), so that is where the
> property has to live to take effect. This is the MAC "fine tuning ...
> values expected here are small" case described in
> Documentation/devicetree/bindings/net/ethernet-controller.yaml: the
> RTL8211F supplies the fixed ~2ns via rgmii-id and the MAC adds a 400ps
> trim on top. Ideally the PHY would own the delay, but as Andrew Lunn
> noted reviewing dwmac-meson8b, that requires the PHY to implement a
> configurable delay, which not all do.
> 
> The already-merged k1-bananapi-f3 does the same thing: eth1 combines
> phy-mode = "rgmii-id" with tx-internal-delay-ps = <250> on the
> controller node (via the K1 EMAC rather than dwmac, but the same DT
> pattern).
> 
> Would you be OK keeping it on the controller given the above? 

Yes, it is good for me.


> For v2 I can add an explicit rx-internal-delay-ps = <0> to match 
> the other SpacemiT boards (k1-bananapi-f3 included) and spell this
> reasoning out in the commit message.
> 

Do not do this, just leave the rx-internal-delay-ps untouched.

For this patch

Reviewed-by: Inochi Amaoto <inochiama@gmail.com>

Regards,
Inochi.

  reply	other threads:[~2026-06-09 23:15 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-08 18:23 [PATCH] riscv: dts: spacemit: k3-pico-itx: Fix non-functional ethernet TX timing Andrew Rembrandt
2026-06-09  5:37 ` Inochi Amaoto
2026-06-09 18:24   ` Andrew Rembrandt
2026-06-09 23:14     ` Inochi Amaoto [this message]
2026-06-10  9:05       ` Andrew Rembrandt
2026-06-11  7:29         ` E Shattow
2026-07-10  2:25           ` Yixun Lan
2026-07-10 14:34             ` E Shattow
2026-07-18  9:07               ` Andrew Rembrandt
2026-07-19 10:28                 ` Yixun Lan
2026-07-19 16:06                   ` E Shattow
2026-07-07  7:15 ` Yixun Lan
2026-07-14  9:08 ` Yixun Lan

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=aiid4Y6x6Dbbwszf@inochi.infowork \
    --to=inochiama@gmail.com \
    --cc=dlan@kernel.org \
    --cc=kernel@rembrandt.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=spacemit@lists.linux.dev \
    /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