Devicetree
 help / color / mirror / Atom feed
From: "Kathpalia, Tanmay" <tanmay.kathpalia@altera.com>
To: "NG, TZE YEE" <tze.yee.ng@altera.com>,
	Adrian Hunter <adrian.hunter@intel.com>,
	linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	devicetree@vger.kernel.org, Ulf Hansson <ulfh@kernel.org>
Subject: Re: [PATCH v4 2/3] dt-bindings: mmc: cdns,sd6hc: add SD6HC DDR50 read-path tuning
Date: Wed, 2 Dec 2026 13:52:45 +0530	[thread overview]
Message-ID: <4b3bfdc1-2eae-496d-9a1d-38b1f34fbb67@altera.com> (raw)
In-Reply-To: <8bf3eddc-305b-4538-a49a-60e2da2f9b8e@altera.com>


On 25-11-2026 12:56, NG, TZE YEE wrote:
>
>
> On 23/11/2026 3:05 am, Kathpalia, Tanmay wrote:
>>
>> On 19-11-2026 15:15, tze.yee.ng@altera.com wrote:
>>> From: Tze Yee Ng <tze.yee.ng@altera.com>
>>>
>>> DDR50 has no CMD19 tuning, so the SD6HC read path must be centred by
>>> static, board/SoC-characterised PHY settings. Add two optional SD6HC
>>> properties for the extended-read DDR modes (SD DDR50 and eMMC DDR52):
>>>
>>
>> I went through the Cadence SD/eMMC DLL PHY IP user guide (IP6185,
>> rev 1.03) to understand how the delay applies to each of the read
>> strobes, so that is why this comes up on v4.
>>
>> The guide marks phony DQS "not used for SD/eMMC" (Fig 2.1), lists
>> use_lpbk_dqs and use_ext_lpbk_dqs as "Mandatory setting for SD/eMMC",
>> and says external loopback needs no 1/4 cycle delay on the slave DLL.
>>
>> Either strobe can capture a DDR read if its edge lands inside the
>> card's valid data window, but the delay has to be chosen for that
>> strobe. The delay is what moves the edge into the window, and the two
>> strobes should not take the same value.
>>
>> External loopback goes out through the pads and the board and comes
>> back, so most of the round-trip delay is already in the strobe. It
>> should need little or no extra delay.
>>
>> Phony DQS is generated inside the PHY, so none of that round trip is
>> in it. It likely needs a larger delay to meet data that did travel
>> through the pads, the board and the card.
>>
>> Questions:
>> 1. Do DDR50 and DDR52 work with the defaults (loopback DQS, read
>>     delay 0)? If not, what fails?
>> 2. Did you sweep the read DQS delay with loopback selected?
>
> Hi Tanmay,
>
> Your model of the two strobes is right and matches what we measured: the
> delay has to be chosen per strobe, and the two strobes don't share a
> value. Loopback carries most of the round-trip, so its eye sits high in
> the delay range; the fabricated phony strobe carries none of it and
> centres much lower. So I'm not disputing the guide, which loopback 
> stays the driver default, and cdns,ddr-no-lpbk-dqs is only a per-board 
> opt-out for boards where loopback isn't usable. To your two questions:
>
> 1) Defaults (loopback, read delay 0): no, DDR50/DDR52 don't work on the
>    Agilex5 SoCDK. Uncentred, the strobe times out on reads, and the
>    write CRC-status token (sampled on the same read strobe) mis-samples
>    too. Centring via cdns,ddr-read-dqs-delay is mandatory regardless of
>    source.
>
> 2) Yes, I swept read_dqs_delay with loopback selected before choosing
>    phony:
>
>    - Soldered-down (013b/b0): loopback passes only in a narrow window at
>      the top of the delay line (~[208,255], ceiling-clipped) and hangs
>      below it. Phony passes across a wide mid-range window (~[64,128])
>      and fails gracefully. Loopback works but has no margin, so phony
>      was chosen for robustness.
>
>    - Modular SoM (longer SD flight time): with loopback, reads time out
>      across the whole sweep - the strobe never gates, so more delay
>      can't fix it. Only phony, with its assertion timing re-centred for
>      the SoM flight time, passes cleanly and survives a cold power
>      cycle.
>
> So loopback isn't broken in general and I'm keeping it as the default;
> the DT properties exist because these boards' IO either gives loopback
> no margin (soldered) or can't gate it at all (modular), so they select
> the phony read path and centre it with read_dqs_delay.
>

Thanks for the sweeps.

Reviewed-by: Tanmay Kathpalia <tanmay.kathpalia@altera.com>


  reply	other threads:[~2026-12-02  8:22 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-19  9:45 [PATCH v4 0/3] mmc: sdhci-cadence: SD6HC DDR50/DDR52 read-path tuning and fixes tze.yee.ng
2026-11-19  9:45 ` [PATCH v4 1/3] mmc: sdhci-cadence: abort failed tuning command on SD6HC tze.yee.ng
2026-11-19  9:53   ` sashiko-bot
2026-12-02  7:50   ` Adrian Hunter
2026-11-19  9:45 ` [PATCH v4 2/3] dt-bindings: mmc: cdns,sd6hc: add SD6HC DDR50 read-path tuning tze.yee.ng
2026-11-22 16:03   ` Krzysztof Kozlowski
2026-11-22 19:05   ` Kathpalia, Tanmay
2026-11-25  7:26     ` NG, TZE YEE
2026-12-02  8:22       ` Kathpalia, Tanmay [this message]
2026-11-19  9:45 ` [PATCH v4 3/3] mmc: sdhci-cadence6: tune SD6HC DDR50/DDR52 read path tze.yee.ng
2026-11-22 19:06   ` Kathpalia, Tanmay
2026-11-25  7:48     ` NG, TZE YEE
2026-12-02  8:12       ` Kathpalia, Tanmay
2026-12-02  7:50   ` Adrian Hunter
2026-11-22 16:03 ` [PATCH v4 0/3] mmc: sdhci-cadence: SD6HC DDR50/DDR52 read-path tuning and fixes Krzysztof Kozlowski
2026-11-25  6:38   ` NG, TZE YEE

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=4b3bfdc1-2eae-496d-9a1d-38b1f34fbb67@altera.com \
    --to=tanmay.kathpalia@altera.com \
    --cc=adrian.hunter@intel.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=robh@kernel.org \
    --cc=tze.yee.ng@altera.com \
    --cc=ulfh@kernel.org \
    /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