public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stefan Roese <sr@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] PPC405EX(r) ECC and SDRAM Initialization Clean-ups
Date: Mon, 28 Apr 2008 17:29:34 +0200	[thread overview]
Message-ID: <200804281729.34880.sr@denx.de> (raw)
In-Reply-To: <C43ADE83.EDBC%gerickson@nuovations.com>

On Monday 28 April 2008, Grant Erickson wrote:
> The primary goal of this patch is to unify some of the low-level SDRAM and
> ECC initialization code for the PPC4xx processors that use a common DDR2
> SDRAM controller.
>
> In particular, in the case of the 405EX[r], it must initialize SDRAM before
> a primordial stack is available since OCM doesn't exist and the data cache
> doesn't work for such a purpose. As a consequence, the ECC (and SDRAM)
> initialization code must be stack-free.

We need to investigate here, why exactly the init-RAM in d-cache is currently 
not working on 405EX. Any ideas on this are very welcome. I'll try to dig 
into this in the a few days too.

> This patch creates such a stack-free ecc_init() routine that should,
> nonetheless, still be compatible from a C runtime environment.
>
> In addition, the patch cleans-up the Kilauea and Makalu SDRAM
> initialization code by polling SDRAM0_MCSTAT[MIC] as recommended by AMCC
> AN2131 rather than just waiting some arbitrary period of time. Also, the
> final controller initialization is generalized by ORing in
> SDRAM_MCOPT2_DCEN_ENABLE rather than just slamming 0x28000000 into the
> register. This is to make way for a future patch that uses CFG_SDRAM0_*
> values for boards that use such low-level initialization so they might
> share this SDRAM init code. Finally, while neither Kilauea nor Makalu have
> ECC memory, code is added to init.S for each to demonstrate how ecc_init()
> would be called if it were available as a reference.
>
> Signed-off-by: Grant Erickson <gerickson@nuovations.com>
>
> ---
>  board/amcc/kilauea/init.S |   53
> +++++++++++++++++++++++++++++++++++++++------

The patch is line-wrapped. Please use git-send-email is possible.

>  board/amcc/makalu/init.S  |   53
> +++++++++++++++++++++++++++++++++++++++------
>  cpu/ppc4xx/Makefile       |    1 +
>  cpu/ppc4xx/sdram.c        |   47 +++------------------------------------
>  4 files changed, 97 insertions(+), 57 deletions(-)

The ECC code seems to be missing.

I'll wait with further review until the missing ECC code is included. :)

Thanks.

Best regards,
Stefan

=====================================================================
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: office at denx.de
=====================================================================

      reply	other threads:[~2008-04-28 15:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-28  8:53 [U-Boot-Users] [PATCH] PPC405EX(r) ECC and SDRAM Initialization Clean-ups Grant Erickson
2008-04-28 15:29 ` Stefan Roese [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=200804281729.34880.sr@denx.de \
    --to=sr@denx.de \
    --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