Skip to contentSkip to conversation

Set TEXT_BASE via <project>.h file?

U-Boot A. Geisreiter 2 participants 5 messages Jan 28, 2010

lore
Share & tools
lore
#0 lore raw

Hi,

I have a question to the TEXT_BASE setting in the config.mk file. Is it possible to set TEXT_BASE via a setting in the <project>.h file?

Thanks,
Andreas

#1 lore raw

Hi Andreas,

Quoted 4 lines · A. Geisreiter

Hi,

I have a question to the TEXT_BASE setting in the config.mk file. Is it possible to set TEXT_BASE via a setting in the <project>.h file?

yes, it is.

In my <project>.h I set:
#define CONFIG_TEXT_BASE 0x40020000
(depending on some CONFIG_MK_... variable)

and in config.mk:
TEXT_BASE=$(CONFIG_TEXT_BASE)

Of course there may be other possibilities, but I found this one to work after setting TEXT_BASE directly in <project>.h failed.

Regards,
Wolfgang

#2 lore raw

Hi Wolfgang,

Thanks for the fast response.
I have tried you're suggestion, but than U-Boot doesn't start. But I don't get an compiler error. What could be the problem?
I work with an PXA270 CPU and TEXT_BASE defines the base address of the RAM copy monitor code.

Regards,
Andreas

-----Urspr?ngliche Nachricht-----
Von: Wolfgang Wegner [mailto:wolfgang at leila.ping.de]
Gesendet: Donnerstag, 28. Januar 2010 12:53
An: A. Geisreiter
Cc: u-boot at lists.denx.de
Betreff: Re: [U-Boot] Set TEXT_BASE via <project>.h file?

Hi Andreas,

Quoted 4 lines · A. Geisreiter

Hi,

I have a question to the TEXT_BASE setting in the config.mk file. Is it possible to set TEXT_BASE via a setting in the <project>.h file?

yes, it is.

In my <project>.h I set:
#define CONFIG_TEXT_BASE 0x40020000
(depending on some CONFIG_MK_... variable)

and in config.mk:
TEXT_BASE=$(CONFIG_TEXT_BASE)

Of course there may be other possibilities, but I found this one to work after setting TEXT_BASE directly in <project>.h failed.

Regards,
Wolfgang

#3 lore raw

Hi Andreas,

Quoted 7 lines · A. Geisreiter

Hi Wolfgang,

Thanks for the fast response.
I have tried you're suggestion, but than U-Boot doesn't start. But I don't get an compiler error. What could be the problem?
I work with an PXA270 CPU and TEXT_BASE defines the base address of the RAM copy monitor code.

remote diagnosis is always difficult. ;-)
Did you issue a "make mrproper", re-configure and the rebuild? For Coldfire targets I had some problems that all objects originating from C sources were correctly rebuilt after changing <project>.h, but not the objects originating from assembler sources. In the case of Coldfire, TEXT_BASE is also used in the assembler CPU startup code, so this would lead to the exact problem you describe...

Currently I have no other ideas.

Regards,
Wolfgang

#4 lore raw

Hi Wolfgang,

Quoted 2 lines
Quoted 2 lines

Thanks for the fast response.
I have tried you're suggestion, but then U-Boot doesn't start. But I

don't

Quoted 2 lines
Quoted 2 lines

get an compiler error. What could be the problem?
I work with an PXA270 CPU and TEXT_BASE defines the base address of the

RAM

Quoted 11 lines
Quoted 1 line

copy monitor code.

remote diagnosis is always difficult. ;-)
Did you issue a "make mrproper", re-configure and the rebuild? For Coldfire targets I had some problems that all objects originating from C sources were correctly rebuilt after changing <project>.h, but not the objects originating from assembler sources. In the case of Coldfire, TEXT_BASE is also used in the assembler CPU startup code, so this would lead to the exact problem you describe...

Currently I have no other ideas.

"make mrproper" sadly also not help. So I must search a little bit, but thanks for your help.

Regards,
Andreas