[coreboot] [PATCH] RAMTOP fixes

Stefan Reinauer stepan at coresystems.de
Tue Apr 27 18:14:25 CEST 2010


On 4/27/10 5:37 PM, Myles Watson wrote:
>>> Index: cbv2/src/cpu/x86/lapic/lapic_cpu_init.c
>>> ===================================================================
>>> --- cbv2.orig/src/cpu/x86/lapic/lapic_cpu_init.c
>>> +++ cbv2/src/cpu/x86/lapic/lapic_cpu_init.c
>>> @@ -246,19 +246,15 @@ int start_cpu(device_t cpu)
>>>   index = ++last_cpu_index;
>>>
>>>   /* Find end of the new processors stack */
>>> -#if (CONFIG_RAMTOP>0x100000) && (CONFIG_RAMBASE < 0x100000) &&
>>> ((CONFIG_CONSOLE_VGA==1) || (CONFIG_PCI_ROM_RUN == 1))
>>> +#if (CONFIG_RAMTOP>0x100000) && (CONFIG_RAMBASE < 0x100000)
>>>   if(index<1) { // only keep bsp on low
>>> - stack_end = ((unsigned long)_estack) - (CONFIG_STACK_SIZE*index) -
>>> sizeof(struct cpu_info);
>>> + stack_end = ((unsigned long)_estack) - sizeof(struct cpu_info);
>>>
>>>
>>> Does this not break for multiple CPUs?
>>>       
>> No.  All of this logic was for putting the AP stacks above 1M when the
>> main stack was below 1M and you didn't want it to run into the VGA
>> area.  Do we have any multiprocessors that still use
>>     
> Sorry, I got interrupted.  It was supposed to be:
> Do we have any multiprocessors that still use CONFIG_RAMBASE < 1M?
>   
I think we should generally #define RAMBASE for x86 architectures to
(above) 1MB and remove it from Kconfig.

It will allow us to simplify CAR and make the different CPUs' CAR code
look more alike

Stefan


-- 
coresystems GmbH • Brahmsstr. 16 • D-79104 Freiburg i. Br.
      Tel.: +49 761 7668825 • Fax: +49 761 7664613
Email: info at coresystems.dehttp://www.coresystems.de/
Registergericht: Amtsgericht Freiburg • HRB 7656
Geschäftsführer: Stefan Reinauer • Ust-IdNr.: DE245674866





More information about the coreboot mailing list