public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Rui Sousa <rui.sousa@laposte.net>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] TEXT_BASE problem
Date: Sat, 11 Nov 2006 10:54:21 +0100	[thread overview]
Message-ID: <200611111054.21624.rui.sousa@laposte.net> (raw)
In-Reply-To: <758219511.20061110184900@sch.bme.hu>

On Friday 10 November 2006 18:49, Foldesi Tamas wrote:
> Hi everybody,

Hi Foldesi,

>         I'm new here, greetings to everybody.
> I built a board for AT91RM9200 based on the DK; the main difference
> is, that I have no paralell flash, only serial. I had my fights with
> this, mainly because of some data aborts tring to cp to the flash, but
> now that is over. Sincs I have 64M ram on the board I'd like to move
> u-boot to 0x23f00000 from 0x21f00000. I did that I think, because I
> altered the code of the dataflashloader, and I set the TEXT_BASE in
> board/at91rm9200dk/config.mk. Still, I receive Data abort while
> running MTEST, because of some spourius data around (0x21eddb..).
> Before moving u-boot, I had the same problem - I had to change the
> mtest range, so it doesn't destroy anything around there. Help me, how
> could anything be under 0x21f00000, when TEXT_BASE is set?

U-boot code and data are above TEXT_BASE but the stack, memory heap and
global variables area is just bellow TEXT_BASE.

from lib_arm/board.c:

gd = (gd_t*)(_armboot_start - CFG_MALLOC_LEN - sizeof(gd_t));
...
mem_malloc_init (_armboot_start - CFG_MALLOC_LEN);

and from cpu/arm920t/start.S:

stack_setup:
        ldr     r0, _TEXT_BASE          /* upper 128 KiB: relocated uboot   */
        sub     r0, r0, #CFG_MALLOC_LEN /* malloc area                      */
        sub     r0, r0, #CFG_GBL_DATA_SIZE /* bdinfo                        */
#ifdef CONFIG_USE_IRQ
        sub     r0, r0, #(CONFIG_STACKSIZE_IRQ+CONFIG_STACKSIZE_FIQ)
#endif
        sub     sp, r0, #12             /* leave 3 words for abort-stack    */

and remember that the stack grows down. I'm not sure if there is a hard lower 
limit, but my guess is no.

> I used MD 
> to display data there, and I got some frangments of the bootup text
> referring to my flash information like "Area 0: ...". What is wrong?
> Thanks
>
> Thomas Foldesi

Rui

  reply	other threads:[~2006-11-11  9:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-10 17:49 [U-Boot-Users] TEXT_BASE problem Foldesi Tamas
2006-11-11  9:54 ` Rui Sousa [this message]
  -- strict thread matches above, loose matches on Subject: below --
2006-11-10 13:20 Foldesi Tamas

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=200611111054.21624.rui.sousa@laposte.net \
    --to=rui.sousa@laposte.net \
    --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