All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Jander <david.jander@protonic.nl>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] ARM: MX5: Fix broken leftover TO-2 errata workaround
Date: Thu, 14 Jul 2011 14:30:02 +0200	[thread overview]
Message-ID: <20110714143002.28eb3dc2@archvile> (raw)
In-Reply-To: <4E1EDDBC.4010109@denx.de>

On Thu, 14 Jul 2011 14:14:52 +0200
Stefano Babic <sbabic@denx.de> wrote:

> On 07/14/2011 01:56 PM, David Jander wrote:
> > This check was broken. r3 does not contain the silicon revision anymore, so
> > we need to reload it.
> > 
> > Signed-off-by: David Jander <david@protonic.nl>
> > ---
> 
> Hi David,
> 
> >  arch/arm/cpu/armv7/mx5/lowlevel_init.S |    4 +++-
> >  1 files changed, 3 insertions(+), 1 deletions(-)
> > 
> > diff --git a/arch/arm/cpu/armv7/mx5/lowlevel_init.S
> > b/arch/arm/cpu/armv7/mx5/lowlevel_init.S index ee4150d..6bb398f 100644
> > --- a/arch/arm/cpu/armv7/mx5/lowlevel_init.S
> > +++ b/arch/arm/cpu/armv7/mx5/lowlevel_init.S
> > @@ -39,7 +39,9 @@
> >  	orr r0, r0, #(1 << 23)		/* disable write allocate
> > combine */ orr r0, r0, #(1 << 22)		/* disable write allocate
> > */ 
> > -	cmp r3, #0x10    /* r3 contains the silicon rev */
> > +	ldr r1, =0x0
> > +	ldr r3, [r1, #ROM_SI_REV]
> > +	cmp r3, #0x10
> 
> You have to protect the code related to TO2 with CONFIG_MX51. As I can
> see, the macro is called for MX.53, too, and the test produces wrong
> results.

Wow, you are right! So this code was actually broken in more ways than I
initially thought :-)
Ok, will fix it (again).
Btw, may I congratulate you for your good work in improving u-boot code
quality? It is starting to get to a level only known from LKML ;-)
Clearly the code was not reviewed as well when this was initially submitted.

Best regards,

-- 
David Jander
Protonic Holland.

  reply	other threads:[~2011-07-14 12:30 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-14 11:56 [U-Boot] [PATCH] ARM: MX5: Fix broken leftover TO-2 errata workaround David Jander
2011-07-14 12:14 ` Stefano Babic
2011-07-14 12:30   ` David Jander [this message]
2011-07-14 12:39     ` Stefano Babic

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=20110714143002.28eb3dc2@archvile \
    --to=david.jander@protonic.nl \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.