public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Eric Nelson <eric.nelson@boundarydevices.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH V2] Add Boundary Devices Nitrogen6X boards
Date: Sun, 10 Mar 2013 07:15:03 -0700	[thread overview]
Message-ID: <513C9567.2050909@boundarydevices.com> (raw)
In-Reply-To: <513BD8AA.4060000@boundarydevices.com>

Hi Troy,

On 03/09/2013 05:49 PM, Troy Kisky wrote:
> On 3/9/2013 5:04 PM, Eric Nelson wrote:
>> diff --git a/board/boundary/nitrogen6x/nitrogen6x.c
>> b/board/boundary/nitrogen6x/nitrogen6x.c
>> new file mode 100644
>> index 0000000..147bd91
>> --- /dev/null
>> +++ b/board/boundary/nitrogen6x/nitrogen6x.c
>> @@ -0,0 +1,895 @@
>> +int dram_init(void)
>> +{
>> +    gd->ram_size = get_ram_size((void *)PHYS_SDRAM, PHYS_SDRAM_SIZE);
>
> This will hang a solo if
>
> PHYS_SDRAM_SIZE is bigger than actual memory size
>
> which makes calling get_ram_size pretty useless.
>

Since the DDR size must be known in the memory configuration
file, this is equivalent to saying:

	get_ram_size() will hang if we run the **wrong**
	U-Boot binary on the device

I think this is true for other reasons as well (SATA?).

The DDR size in this translated from the boards.cfg file,
which defines CONFIG_DDR_MB for each configuration
and nitrogen6x.h, which uses it to define PHYS_SDRAM_SIZE

+#define PHYS_SDRAM_SIZE	(CONFIG_DDR_MB * 1024 * 1024)

But your point about calling get_ram_size() being useless
is probably true.

Testing for RAM that we need to configure doesn't add anything.

Regards,


Eric

  parent reply	other threads:[~2013-03-10 14:15 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-10  0:04 [U-Boot] [PATCH V2] Add Boundary Devices Nitrogen6X boards Eric Nelson
2013-03-10  0:49 ` Troy Kisky
2013-03-10  8:02   ` Wolfgang Denk
2013-03-10 14:15   ` Eric Nelson [this message]
2013-03-10  7:59 ` Wolfgang Denk
2013-03-10 15:09   ` Eric Nelson
2013-03-10 15:45     ` Wolfgang Denk
2013-03-10 16:25       ` Eric Nelson
2013-03-10 22:03         ` Wolfgang Denk
2013-03-10 23:36           ` Eric Nelson
2013-03-11 11:15             ` Wolfgang Denk
2013-03-11 12:04               ` Stefano Babic
2013-03-11 13:18                 ` Fabio Estevam
2013-03-11 13:44                   ` Stefano Babic
2013-03-11 13:54                     ` Fabio Estevam
2013-03-11 14:02                     ` Eric Nelson
2013-03-11 14:30                       ` Stefano Babic
2013-03-11 14:39                         ` Tom Rini
2013-03-11 13:37               ` Eric Nelson
2013-03-11 16:48                 ` Wolfgang Denk

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=513C9567.2050909@boundarydevices.com \
    --to=eric.nelson@boundarydevices.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