[U-Boot] [PATCH] driver/mxc_i2c: Move static data structure to global_data
York Sun
yorksun at freescale.com
Tue Feb 11 22:02:19 CET 2014
On 02/11/2014 12:57 PM, Wolfgang Denk wrote:
> Dear York,
>
> In message <52FA8205.1090206 at freescale.com> you wrote:
>>
>>> So ideally keep this data on the stack, and if there is no way around
>>> it, in the global data structure.
>>
>> Agreed. I tried to use global data at first, which upsets Tom. Tom suggested to
>> use linker script. I guess he was under the impression I was using SPL. Let me
>> try harder to use stack.
>
> well, to do something with the linker script, you need some memory
> somewhere you can use for this purpose. Your example showed SRAM. so
> if you do have SRAM on that board - why do you not use it for stack
> and GD? Where is your steck and GD right now?
>
The initial stack and GD are in SRAM. Of course they are moved to SDRAM after
initialization. I intend to spare SRAM for other purpose after relocation.
I am scratching my head trying to figure out how to put this variable "srdata"
in mxc_i2c.c into stack. Please give me some guidance if you have the idea on
top of your head.
York
More information about the U-Boot
mailing list