[coreboot] global variables in romstage

Stefan Reinauer stefan.reinauer at coresystems.de
Sat Aug 14 12:24:11 CEST 2010

 On 8/14/10 11:50 AM, Carl-Daniel Hailfinger wrote:
> On 14.08.2010 11:40, Stefan Reinauer wrote:
>>  On 8/12/10 9:27 PM, Patrick Georgi wrote:
>>> 1. [...]
>>> This one looks for the size of .bss and .data (initialized and
>>> uninitialized globals) and breaks the build if it finds any. It doesn't
>>> tell, which global variables are involved.
>>> 2. Add .bss and .data to /DISCARD/.
>>> [...]
>> I prefer option one, too, as
>> - it catches all global variables, not just the used ones. We want to be
>> sure that no such code sneaks in even if it's not used.
>> - it provides a clear error message on what is wrong, inszead of the
>> more cryptic one saying that a variable is defined in a discarded section.
> Should we move some of the section checking of v3 to v4 as well? I will
> soon have a bit more free time and plan to get up to speed on coreboot
> development again.
util/sectionchecker/sectionchecker ?

Looks nice. I think this might be a way to go.

What are the advantages over the two suggestions above?


More information about the coreboot mailing list