public inbox for linux-tegra@vger.kernel.org
 help / color / mirror / Atom feed
From: Thierry Reding <thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: David Ung <davidu-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
Cc: airlied-cv59FeDIM0c@public.gmane.org,
	linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	tbergstrom-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org,
	swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org
Subject: Re: [PATCH V2] gpu: drm: tegra: Adjust dsi phy timing
Date: Fri, 5 Dec 2014 23:41:52 +0100	[thread overview]
Message-ID: <20141205224151.GB21777@mithrandir> (raw)
In-Reply-To: <1417570823-19977-1-git-send-email-davidu-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 2024 bytes --]

The subject prefix should be "drm/tegra: dsi:". Also make sure to use
the proper case. "dsi" should be "DSI" and "phy" should be "PHY". Also
the DSI PHY is typically referred to as D-PHY, so a better subject would
be:

	drm/tegra: dsi: Adjust D-PHY timing

One more comment below:

On Tue, Dec 02, 2014 at 05:40:23PM -0800, David Ung wrote:
> Fix DSI PHY HS Trail setting on Tegra.
> It is found that HS Trail is off -12% during compliance testing
> 
> Signed-off-by: David Ung <davidu-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
> ---
>  drivers/gpu/drm/tegra/mipi-phy.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/tegra/mipi-phy.c b/drivers/gpu/drm/tegra/mipi-phy.c
> index 486d19d..974bc68 100644
> --- a/drivers/gpu/drm/tegra/mipi-phy.c
> +++ b/drivers/gpu/drm/tegra/mipi-phy.c
> @@ -34,7 +34,7 @@ int mipi_dphy_timing_get_default(struct mipi_dphy_timing *timing,
>  	timing->hszero = 145 + 5 * period;
>  	timing->hssettle = 85 + 6 * period;
>  	timing->hsskip = 40;
> -	timing->hstrail = max(8 * period, 60 + 4 * period);
> +	timing->hstrail = 3 * period * 8 + max(8 * period, 60 + 4 * period);
>  	timing->init = 100000;
>  	timing->lpx = 60;
>  	timing->taget = 5 * timing->lpx;

Back when I wrote this code I envisioned that this could eventually be a
generic set of helpers that could be used across different DSI drivers.
As such, mipi_dphy_timing_get_default() obtains the default timings as
given by the D-PHY specification. Therefore you should be adjusting this
within the driver code rather than the default timings. And then make it
something like:

	/* comment explaining why this is needed */
	timing.hstrail += 3 * period * 8;

That said, most of this code is in flux right now, so I probably have to
manually apply the patch. It would still be good to respin with these
comments addressed so that I can adopt the commit message and comment
explaining why this is necessary or what the consequences are.

Thierry

[-- Attachment #2: Type: application/pgp-signature, Size: 836 bytes --]

      parent reply	other threads:[~2014-12-05 22:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-03  1:40 [PATCH V2] gpu: drm: tegra: Adjust dsi phy timing David Ung
     [not found] ` <CAOw6vbJmq1QtPPeWeE=mjgD1RjCeYGO=zdKR3vMn9AZaTOOc_w@mail.gmail.com>
     [not found]   ` <CAOw6vbJmq1QtPPeWeE=mjgD1RjCeYGO=zdKR3vMn9AZaTOOc_w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-12-05 22:17     ` Thierry Reding
     [not found]       ` <CAOw6vb+B_AkA6NLuaRhFLrLuTEW0m02ptrkL0sOp6Ov=eJ34XA@mail.gmail.com>
     [not found]         ` <CAOw6vb+B_AkA6NLuaRhFLrLuTEW0m02ptrkL0sOp6Ov=eJ34XA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-12-08 10:24           ` Thierry Reding
     [not found] ` <1417570823-19977-1-git-send-email-davidu-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2014-12-05 22:41   ` Thierry Reding [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=20141205224151.GB21777@mithrandir \
    --to=thierry.reding-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=airlied-cv59FeDIM0c@public.gmane.org \
    --cc=davidu-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org \
    --cc=linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org \
    --cc=tbergstrom-DDmLM1+adcrQT0dZR+AlfA@public.gmane.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