linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Doug Anderson <dianders@chromium.org>
To: Shawn Lin <shawn.lin@rock-chips.com>
Cc: Brian Norris <briannorris@chromium.org>,
	Kishon Vijay Abraham I <kishon@ti.com>,
	Heiko Stuebner <heiko@sntech.de>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"open list:ARM/Rockchip SoC..."
	<linux-rockchip@lists.infradead.org>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	Brian Norris <computersforpeace@gmail.com>
Subject: Re: [PATCH 3/4] phy: rockchip-emmc: configure default output tap delay
Date: Mon, 16 May 2016 08:12:57 -0700	[thread overview]
Message-ID: <CAD=FV=Xq3=B0NC7of-h_q8vCUDGz=33MU4vjY6EyQxQS+CC8=Q@mail.gmail.com> (raw)
In-Reply-To: <52567d92-d1d3-f089-65c2-a30f3a00386b@rock-chips.com>

Hi,

On Sun, May 15, 2016 at 9:15 PM, Shawn Lin <shawn.lin@rock-chips.com> wrote:
> Hi Doug,
>
>
> On 2016/5/14 6:25, Doug Anderson wrote:
>>
>> Hi,
>>
>> On Thu, May 12, 2016 at 3:43 PM, Brian Norris <briannorris@chromium.org>
>> wrote:
>>>
>>> The output tap delay controls helps maintain the hold requirements for
>>> eMMC. The exact value is dependent on the SoC and other factors, though
>>> it isn't really an exact science. But the default of 0 is not very good,
>>> as it doesn't give the eMMC much hold time, so let's bump up to 4
>>> (approx 90 degree phase?). If we need to configure this any further
>>> (e.g., based on board or speed factors), we may need to consider a
>>> device tree representation.
>>
>>
>> As I understand it, this solves much the same problem as my patch in
>> <https://patchwork.kernel.org/patch/9085581/>, but for the eMMC port
>> on rk3399 (which doesn't use dw_mmc).  As argued in that patch and
>> also in the discussion from
>> <https://patchwork.kernel.org/patch/9030621/>, if we eventually end up
>> needing to put something in the device tree we need to be really
>> careful.  Specifically to get the exact right value here I think you
>> need to consider the input clock, speed mode, and any SoC-specific
>> delays differences between the clock and the data lines.  That would
>> imply that, if anything, the device tree data would only contain
>> information about the SoC-specific delay differences and all other
>> work to set this value would involve coordination between the PHY and
>> the SDHCI controller.
>>
>>
>> However, as also discussed previously, we don't appear to need to be
>> very exact about the value here.  It seems like setting this to 4 (~90
>> degrees?) is a much better starting point than leaving it at the
>> default of 0.
>
>
> The value, 4, is based on real silicon test observed from the
> oscilloscope, and of course it meets the requirement of speed modes.
> For arasan't phy, its phase is very accurate, so the real timing of
> the value you set almost won't vary too much for different Socs.
>
> So explicitly assigning 4 here looks sane currently except for crazy
> PCB layout...

Great to hear.  So we can probably just use your email as the basis of
the commit message?  How about this for the commit text then:

The output tap delay controls helps maintain the hold requirements for
eMMC.  The value, 4, is based on real silicon test observed from the
oscilloscope, and of course it meets the requirement of speed modes.
For arasan't phy, its phase is very accurate, so the real timing of
the value you set won't vary too much for different SoCs.

If / when we find an instance of a crazy PCB layout that needs a value
different than 4, we will figure out how to best specify that,
possibly using the device tree in some way.

-Doug

  reply	other threads:[~2016-05-16 15:13 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-12 22:43 [PATCH 1/4] phy: rockchip-emmc: give DLL some extra time to be ready Brian Norris
2016-05-12 22:43 ` [PATCH 2/4] phy: rockchip-emmc: configure frequency range and drive impedance Brian Norris
2016-05-13  1:02   ` Shawn Lin
2016-05-13 18:46     ` Doug Anderson
2016-05-13 21:04       ` Brian Norris
2016-05-24  4:51       ` Doug Anderson
2016-05-13 21:09   ` [PATCH v2 " Brian Norris
2016-05-13 22:04     ` Doug Anderson
2016-06-16 23:36     ` Heiko Stuebner
2016-06-20 13:11   ` [PATCH " Kishon Vijay Abraham I
2016-05-12 22:43 ` [PATCH 3/4] phy: rockchip-emmc: configure default output tap delay Brian Norris
2016-05-13 22:25   ` Doug Anderson
2016-05-16  4:15     ` Shawn Lin
2016-05-16 15:12       ` Doug Anderson [this message]
2016-06-16 23:36   ` Heiko Stuebner
2016-06-20 13:11   ` Kishon Vijay Abraham I
2016-05-12 22:43 ` [PATCH 4/4] phy: rockchip-emmc: reindent the register definitions Brian Norris
2016-05-13 22:26   ` Doug Anderson
2016-06-16 23:37   ` Heiko Stuebner
2016-06-20 13:12   ` Kishon Vijay Abraham I
2016-05-13 22:01 ` [PATCH 1/4] phy: rockchip-emmc: give DLL some extra time to be ready Doug Anderson
2016-06-16 23:35 ` Heiko Stuebner
2016-06-20 13:11 ` Kishon Vijay Abraham I
2016-06-20 16:19   ` Brian Norris
2016-06-20 16:25     ` Doug Anderson
2016-06-20 16:50       ` Brian Norris

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='CAD=FV=Xq3=B0NC7of-h_q8vCUDGz=33MU4vjY6EyQxQS+CC8=Q@mail.gmail.com' \
    --to=dianders@chromium.org \
    --cc=briannorris@chromium.org \
    --cc=computersforpeace@gmail.com \
    --cc=heiko@sntech.de \
    --cc=kishon@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=shawn.lin@rock-chips.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).