public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stefano Babic <sbabic@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] mx31: Improve the handling of unidentified silicon version
Date: Wed, 15 Jun 2011 14:17:34 +0200	[thread overview]
Message-ID: <4DF8A2DE.3040501@denx.de> (raw)
In-Reply-To: <4DF89C84.7090605@freescale.com>

On 06/15/2011 01:50 PM, Fabio Estevam wrote:
> Hi Stefano,
> 

Hi Fabio,

> Let me try to explain the problem I see with the current silicon
> detection mechanism:
> 
> On my board (srev=0x28), which is a TO2.0 silicon I get:
> 
> CPU:   Freescale i.MX31 rev 2.0 at 531 MHz.Reset cause: WDOG
> 
> On Felix?s MX31ADS board (srev=0x20) (unknown chip version) he gets:
> 
> CPU:   Freescale i.MX31 rev 2.0 unknown at 531 MHz.Reset cause: WDOG
> 
> Reading rev 2.0 on Felix?s case is misleading IMHO as we tend to
> think that we have a TO2.0 silicon on his board even though we get a
> "unknown" string.

Ok, so only reading the code we can know that version number + "unknown"
give us the value of the srev register. We can explicitely expand the
output to make things clearer.

>>> if (srev == mx31_cpu_type[i].srev) return mx31_cpu_type[i].v;
>>> 
>>> -	return srev | 0x8000; +	return 0x8000;
>> 
>> IMHO in the case the revision is not recognized, it is better to
>> print the value of the srev register, as it is done now.
> 
> Yes, agreed, but we should print srev as an hex number instead of a
> string as done today
> 
> If you agree I can implement the following logic:
> 
> When the chip version is detected let?s just leave as it is today:
> 
> CPU:   Freescale i.MX31 rev 2.0 at 531 MHz.Reset cause: WDOG
> 
> When the chip version is not valid, then we print:
> 
> CPU:   Freescale i.MX31 (unknown rev, srev=0x20) at 531 MHz.Reset
> cause: WDOG

Agree with your proposal.

Best regards,
Stefano Babic

-- 
=====================================================================
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
=====================================================================

  parent reply	other threads:[~2011-06-15 12:17 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-14 16:31 [U-Boot] [PATCH] mx31: Improve the handling of unidentified silicon version Fabio Estevam
2011-06-14 22:46 ` Graeme Russ
2011-06-15  5:28 ` Wolfgang Denk
2011-06-15  5:29 ` Stefano Babic
2011-06-15 11:50   ` Fabio Estevam
2011-06-15 12:08     ` Graeme Russ
2011-06-15 12:17       ` Fabio Estevam
2011-06-15 12:12     ` Wolfgang Denk
2011-06-15 12:33       ` Graeme Russ
2011-06-15 12:49         ` Wolfgang Denk
2011-06-15 13:00           ` Graeme Russ
2011-06-15 12:17     ` Stefano Babic [this message]
2011-06-15 12:47       ` Wolfgang Denk
2011-06-15 13:02         ` 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=4DF8A2DE.3040501@denx.de \
    --to=sbabic@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