[U-Boot] [Patch v2 1/2] common/board_f: Preserve global data for mpc85xx and mpc86xx

York Sun yorksun at freescale.com
Thu May 1 02:05:47 CEST 2014


On 04/30/2014 05:02 PM, Scott Wood wrote:
> On Wed, 2014-04-30 at 17:01 -0700, York Sun wrote:
>>>>> BTW, I see x86 also skips "gd = new_gd" in board_init_r(), so I wonder
>>>>> what is going on with gd on x86, and whether it makes sense to lump it
>>>>> in with CONFIG_SYS_EARLY_GD.
>>>>>
>>>>
>>>> Maybe x86 maintainers can chime in? If we define such macro, it should probably
>>>> sit right above board_init_f() so it can be seen easily. There is no other place
>>>> it is needed, yet.
>>>
>>> I was thinking it would be set the same way other CONFIG symbols are
>>> set.
>>>
>>
>> That will be in include/common.h for cross-platform macros.
> 
> No, it's in the particular board files (or better, arch/subarch files
> included by board files) that need this.  The point is to not have a big
> ifdef list, rather than to just move the big ifdef list.
> 

I got your idea. You are suggesting to define this macro in each arch which it
needs to preserve gd. So we won't have a list. It is neat but may be easy to miss.

York



More information about the U-Boot mailing list