public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] ARM relocation, probably trivial mistake
@ 2010-09-30 13:57 Reinhard Meyer
  2010-09-30 14:08 ` Stefano Babic
  2010-09-30 15:38 ` Heiko Schocher
  0 siblings, 2 replies; 113+ messages in thread
From: Reinhard Meyer @ 2010-09-30 13:57 UTC (permalink / raw)
  To: u-boot

Hello,

after enabling relocation I get the following output:

U-Boot 2010.09-00106-g6e135b9-dirty (Sep 30 2010 - 16:57:43)

U-Boot code: 21F00000 -> 21F3C140  BSS: -> 21F7D700
CPU: AT91SAM9XE
Crystal frequency:   18.432 MHz
CPU clock        :  198.656 MHz
Master clock     :   99.328 MHz
I2C:   ready
monitor len: 0007D700 <<<< this must be wrong, the binary is short of 256k large
ramsize: 04000000 <<<< correct
Top of RAM usable for U-Boot at: 24000000 <<<< correct
Reserving 501k for U-Boot at: 23f82000
Reserving 143k for malloc() at: 23f5e100
Reserving 24 Bytes for Board Info at: 23f5e0e8
Reserving 88 Bytes for Global Data at: 23f5e090
New Stack Pointer is: 23f5e088
RAM Configuration:
Bank #0: 20000000 64 MiB <<< correct
relocation Offset is: 02082000 <<<< could be right

<<< system hangs here >>>

Details: initial bootstrap loads u-boot to RAM at 21f00000
(1MiB short of 32 MiB which is the minimum RAM populated)

I have set the following values:
#define	CONFIG_SKIP_LOWLEVEL_INIT
#define CONFIG_SKIP_RELOCATE_UBOOT
/*#define	CONFIG_SYS_ARM_WITHOUT_RELOC*/
#define	CONFIG_SYS_NO_ICACHE
#define	CONFIG_SYS_NO_DCACHE

and

/* SDRAM: min 32, upto 128 MB */
#define CONFIG_NR_DRAM_BANKS		1
#define PHYS_SDRAM			0x20000000
#define PHYS_SDRAM_MAX_SIZE		0x08000000
#define CONFIG_SYS_MEMTEST_START	PHYS_SDRAM
#define CONFIG_SYS_MEMTEST_END		0x21e00000
#define CONFIG_SYS_LOAD_ADDR		(PHYS_SDRAM+0x01000000)	/* 16 MB into RAM */
#define	CONFIG_SYS_SDRAM_BASE		PHYS_SDRAM
#define	CONFIG_SYS_INIT_SP_ADDR		(CONFIG_SYS_SDRAM_BASE + 0x1000 - CONFIG_SYS_GBL_DATA_SIZE)

and in config.mk:

TEXT_BASE = 0x21f00000

and

int dram_init(void)
{
	gd->ram_size =
		get_ram_size((void*)PHYS_SDRAM, PHYS_SDRAM_MAX_SIZE);
	return 0;
}

void dram_init_banksize(void)
{
	gd->bd->bi_dram[0].start = PHYS_SDRAM;
	gd->bd->bi_dram[0].size =
		get_ram_size((void*)PHYS_SDRAM, PHYS_SDRAM_MAX_SIZE);
}

I do probably have a simple misunderstanding of the concept.

1. should CONFIG_SKIP_RELOCATE_UBOOT be not defined anymore?

2. TEXT_BASE must be the address where the u-boot is loaded
by 1st loader and startet, right?

With Best Regards,
Reinhard

^ permalink raw reply	[flat|nested] 113+ messages in thread

end of thread, other threads:[~2010-10-05  7:26 UTC | newest]

Thread overview: 113+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-30 13:57 [U-Boot] ARM relocation, probably trivial mistake Reinhard Meyer
2010-09-30 14:08 ` Stefano Babic
2010-09-30 14:20   ` Reinhard Meyer
2010-09-30 15:39     ` Heiko Schocher
2010-09-30 16:06       ` Reinhard Meyer
2010-09-30 15:38 ` Heiko Schocher
2010-09-30 17:43   ` Wolfgang Denk
2010-10-01  5:25     ` Heiko Schocher
2010-10-01  5:40       ` Albert ARIBAUD
2010-10-01  5:53         ` Heiko Schocher
2010-10-01  6:39           ` Reinhard Meyer
2010-10-01  6:57             ` Heiko Schocher
2010-10-01  8:45               ` Wolfgang Denk
2010-10-01  7:01             ` Albert ARIBAUD
2010-10-01  7:42               ` [U-Boot] ARM relocation, probably trivial mistake - back to original problem Reinhard Meyer
2010-10-01  8:27                 ` Heiko Schocher
2010-10-01 10:44                   ` Reinhard Meyer
2010-10-01 10:55                     ` Wolfgang Denk
2010-10-01 11:03                       ` Reinhard Meyer
2010-10-01 11:21                         ` Wolfgang Denk
2010-10-01 11:37                           ` Reinhard Meyer
2010-10-01 11:59                             ` Wolfgang Denk
2010-10-01 12:22                               ` Reinhard Meyer
2010-10-01 12:47                                 ` Reinhard Meyer
2010-10-01 12:55                                   ` Wolfgang Denk
2010-10-01 14:55                                     ` Reinhard Meyer
2010-10-02  8:53                                       ` Heiko Schocher
2010-10-01 15:47                                     ` Steve Sakoman
2010-10-02  7:15                                       ` [U-Boot] ARM relocation, question to Heiko Reinhard Meyer
     [not found]                                         ` <4CA6E517.9040701@fr<1286167382.22760.19.camel@ptyser-laptop>
2010-10-02  7:53                                         ` Albert ARIBAUD
2010-10-02  8:10                                           ` Reinhard Meyer
2010-10-02  8:26                                             ` Albert ARIBAUD
2010-10-03 18:04                                               ` Wolfgang Denk
2010-10-02  9:08                                             ` Heiko Schocher
2010-10-02  9:29                                               ` Albert ARIBAUD
2010-10-03 18:05                                                 ` Wolfgang Denk
2010-10-02 10:17                                               ` Joakim Tjernlund
2010-10-02 16:21                                                 ` J. William Campbell
2010-10-02 18:33                                                   ` Reinhard Meyer
2010-10-03 18:22                                                     ` Wolfgang Denk
2010-10-02 20:39                                                   ` Reinhard Meyer
2010-10-02 21:09                                                     ` Albert ARIBAUD
2010-10-02 23:07                                                       ` Graeme Russ
2010-10-03  7:10                                                         ` Albert ARIBAUD
2010-10-03  8:44                                                           ` Graeme Russ
2010-10-03  8:58                                                             ` Albert ARIBAUD
2010-10-03 15:36                                                               ` J. William Campbell
2010-10-03 16:47                                                                 ` Albert ARIBAUD
2010-10-03 17:54                                                                   ` Albert ARIBAUD
2010-10-03 18:43                                                                 ` Wolfgang Denk
2010-10-04  5:41                                                       ` Heiko Schocher
2010-10-03 18:29                                                     ` Wolfgang Denk
2010-10-03 19:26                                                       ` J. William Campbell
2010-10-04  5:52                                                       ` Heiko Schocher
2010-10-03 18:14                                                   ` Wolfgang Denk
2010-10-03 18:54                                                     ` J. William Campbell
2010-10-03 19:52                                                       ` Albert ARIBAUD
2010-10-03 18:03                                             ` Wolfgang Denk
2010-10-03 18:34                                               ` Albert ARIBAUD
2010-10-03 18:45                                                 ` Wolfgang Denk
2010-10-04  6:08                                                 ` Heiko Schocher
2010-10-04  6:40                                                   ` Albert ARIBAUD
2010-10-04  7:27                                                     ` Reinhard Meyer
2010-10-04  8:28                                                       ` Albert ARIBAUD
2010-10-04  8:57                                                         ` Heiko Schocher
2010-10-04  9:27                                                           ` Albert ARIBAUD
2010-10-04 10:01                                                             ` Joakim Tjernlund
2010-10-04  9:58                                                         ` Graeme Russ
2010-10-04 14:17                                                           ` Albert ARIBAUD
2010-10-04 14:25                                                             ` Rogan Dawes
2010-10-04 15:24                                                               ` Albert ARIBAUD
2010-10-04 16:31                                                                 ` Stefan Roese
2010-10-04 21:31                                                                   ` Albert ARIBAUD
2010-10-04  7:44                                                     ` Albert ARIBAUD
2010-10-04  4:43                                               ` Peter Tyser
2010-10-04  6:08                                                 ` Wolfgang Denk
2010-10-04  7:36                                                 ` Joakim Tjernlund
2010-10-04  8:08                                                   ` Albert ARIBAUD
2010-10-04  8:28                                                     ` Joakim Tjernlund
2010-10-04  8:33                                                       ` Albert ARIBAUD
     [not found]                                                         ` <OF05779DA1.EF3C4954-ONC12577B2.00307A0D-C12577B2.0030B9C0@tran <4CAA1613.80002@comcast.net>
2010-10-04  8:52                                                         ` Joakim Tjernlund
2010-10-04  9:10                                                           ` Albert ARIBAUD
2010-10-04 10:13                                                             ` Wolfgang Denk
2010-10-04 15:28                                                               ` J. William Campbell
2010-10-04 15:52                                                                 ` Albert ARIBAUD
2010-10-04 17:06                                                                 ` Wolfgang Denk
2010-10-04 17:59                                                                   ` J. William Campbell
2010-10-04 18:43                                                                     ` Joakim Tjernlund
2010-10-04 21:10                                                                       ` Wolfgang Denk
2010-10-05  7:26                                                                         ` Joakim Tjernlund
2010-10-04 17:04                                                               ` Graeme Russ
2010-10-04 17:14                                                                 ` Wolfgang Denk
2010-10-04  8:27                                                   ` Wolfgang Denk
2010-10-02  8:49                                     ` [U-Boot] ARM relocation, probably trivial mistake - back to original problem Heiko Schocher
2010-10-01 12:49                                 ` Wolfgang Denk
2010-10-01 14:48                                   ` Reinhard Meyer
2010-10-04  7:44                                     ` [U-Boot] AT91 clock and timer cleanups (was: ARM relocation, probably trivial mistake - back to original problem) Reinhard Meyer
2010-10-04  8:32                                       ` Wolfgang Denk
2010-10-04  8:42                                         ` [U-Boot] AT91 clock and timer cleanups Reinhard Meyer
2010-10-04  8:49                                           ` Wolfgang Denk
2010-10-04  8:52                                             ` Reinhard Meyer
2010-10-04  9:03                                               ` Wolfgang Denk
2010-10-04  9:12                                                 ` Reinhard Meyer
2010-10-04 14:58                                                   ` Reinhard Meyer
2010-10-04 17:00                                                     ` Wolfgang Denk
2010-10-04 17:15                                                       ` Reinhard Meyer
2010-10-04 17:32                                                         ` Wolfgang Denk
2010-10-04 19:22                                                           ` Reinhard Meyer
2010-10-01  8:48                 ` [U-Boot] ARM relocation, probably trivial mistake - back to original problem Wolfgang Denk
2010-10-01  9:50                   ` Reinhard Meyer
2010-10-01  8:03             ` [U-Boot] ARM relocation, probably trivial mistake Wolfgang Denk
2010-10-01  7:51           ` Wolfgang Denk
2010-10-01  8:28             ` Heiko Schocher

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox