public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Eric Nelson <eric@nelint.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/2] arm: imx6: Add DDR3 calibration code for MX6 Q/D/DL
Date: Wed, 16 Dec 2015 08:00:38 -0700	[thread overview]
Message-ID: <56717C96.1030203@nelint.com> (raw)
In-Reply-To: <1450276807-8960-1-git-send-email-marex@denx.de>

Hi Marek,

On 12/16/2015 07:40 AM, Marek Vasut wrote:
> Add DDR3 calibration code for i.MX6Q, i.MX6D and i.MX6DL. This code
> fine-tunes the behavior of the MMDC controller in order to improve
> the signal integrity and memory stability.
> 

I'm glad to see that others are interested in this.

I've been working on something similar, but struggling to have time
to finish and clean it up:
	https://github.com/ericnelsonaz/u-boot/tree/memcal-pass1

My aim is/was a bit different though, and aims to be a replacement for
the DDR stress tool, which is cumbersome to use.

To do that, I put together a pseudo-board with Kconfig options for
the serial console, memory bus width, and such.

> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Stefano Babic <sbabic@denx.de>
> ---
>  arch/arm/cpu/armv7/mx6/ddr.c            | 559 ++++++++++++++++++++++++++++++++
>  arch/arm/include/asm/arch-mx6/mx6-ddr.h |   5 +
>  2 files changed, 564 insertions(+)
> 
> diff --git a/arch/arm/cpu/armv7/mx6/ddr.c b/arch/arm/cpu/armv7/mx6/ddr.c
> index 6b039e4..194411f 100644
> --- a/arch/arm/cpu/armv7/mx6/ddr.c
> +++ b/arch/arm/cpu/armv7/mx6/ddr.c
> @@ -13,6 +13,565 @@
>  #include <asm/io.h>
>  #include <asm/types.h>
>  

I'll review this in detail later, but off-hand, I think this could use
a new CONFIG_ variable to exclude it from boards that don't use it.

It also shouldn't be difficult to support i.MX6SL and LPDDR here.

> +#if defined(CONFIG_MX6QDL) || defined(CONFIG_MX6Q) || defined(CONFIG_MX6D)
> +
> +static int wait_for_bit(void *reg, const uint32_t mask, bool set)
> +{
> +	unsigned int timeout = 1000;
> +	u32 val;
> +

Regards,


Eric

  parent reply	other threads:[~2015-12-16 15:00 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-12-16 14:40 [U-Boot] [PATCH 1/2] arm: imx6: Add DDR3 calibration code for MX6 Q/D/DL Marek Vasut
2015-12-16 14:40 ` [U-Boot] [PATCH 2/2] arm: imx6: Enable DDR calibration on Novena Marek Vasut
2015-12-20 19:46   ` Eric Nelson
     [not found]   ` <567702A6.9070107@cox.net>
2015-12-22  1:26     ` Marek Vasut
2015-12-22  8:30       ` Nikolay Dimitrov
2015-12-22 14:56         ` Marek Vasut
2015-12-16 15:00 ` Eric Nelson [this message]
2015-12-16 15:33   ` [U-Boot] [PATCH 1/2] arm: imx6: Add DDR3 calibration code for MX6 Q/D/DL Marek Vasut
2015-12-16 16:28     ` Eric Nelson
2015-12-16 16:50       ` Marek Vasut
2015-12-16 17:07         ` Eric Nelson
2015-12-16 17:11           ` Marek Vasut
2015-12-17 15:39   ` Tim Harvey
2015-12-17 15:48     ` Eric Nelson
2015-12-17 15:36 ` Tim Harvey
2015-12-17 15:40   ` Marek Vasut
2015-12-17 16:15     ` Tim Harvey
2015-12-17 16:17       ` Marek Vasut
2015-12-17 21:32 ` Nikolay Dimitrov
2015-12-17 22:11   ` Marek Vasut
2015-12-20 19:31 ` Eric Nelson
2015-12-22  1:52   ` Marek Vasut
2015-12-22 15:37     ` Eric Nelson
2016-01-14  2:10       ` Marek Vasut
2016-01-14  2:37         ` Eric Nelson
2016-01-14  2:50           ` Marek Vasut
2016-01-14  2:52             ` Eric Nelson
2016-01-14  3:06               ` Marek Vasut
2016-01-14 14:25                 ` Tim Harvey
2016-01-24 10:47                   ` Stefano Babic
2016-01-24 16:01                     ` Marek Vasut
2016-01-24 17:03                       ` Stefano Babic
2016-01-24 17:11                         ` Marek Vasut
2016-01-24 17:18                           ` Stefano Babic
2016-01-24 17:22                             ` Marek Vasut
2016-01-24 19:33                               ` Tom Rini
2016-01-24 22:07                                 ` Marek Vasut
2016-01-24 22:21                                   ` Tom Rini
2016-01-24 23:00                                     ` Marek Vasut
2016-01-24 23:30                                       ` Tom Rini
2016-01-24 23:55                                         ` Marek Vasut
2016-01-31 17:25                                         ` Marek Vasut
2016-06-02 13:20                                           ` Tim Harvey
2016-06-02 14:23                                             ` Stefano Babic
2016-06-02 15:25                                               ` Tim Harvey
2015-12-22  4:13   ` Tim Harvey
2015-12-22 14:47     ` Eric Nelson

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=56717C96.1030203@nelint.com \
    --to=eric@nelint.com \
    --cc=u-boot@lists.denx.de \
    /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