Changeset 3437 for trunk

Show
Ignore:
Timestamp:
07/24/08 01:22:59 (2 months ago)
Author:
mjones
Message:

This patch fixes the kernel EBDA mislocation problem. Thank you, Yinghai.

The change in tables.c protects the legacy x86 BIOS data segment
(0x400-0x4ff) from being used for storing coreboot tables. Some
bytes from the segment are used by the kernel and should not be
garbled.

The change in coreboot_table.c is not strictly necessary. It removes
some redundancy and confusion.

Signed-off-by: Roman Kononov <kononov@…>
Acked-by: Marc Jones <marc.jones@…>

Location:
trunk/coreboot-v2/src/arch/i386/boot
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/coreboot-v2/src/arch/i386/boot/coreboot_table.c

    r3396 r3437  
    403403        unsigned long rom_table_start, unsigned long rom_table_end) 
    404404{ 
    405         unsigned long table_size; 
    406405        struct lb_header *head; 
    407406        struct lb_memory *mem; 
     
    446445 
    447446        /* Record the pirq table, acpi tables, and maybe the mptable */ 
    448         table_size=rom_table_end-rom_table_start; 
    449447        lb_add_memory_range(mem, LB_MEM_TABLE,  
    450                 rom_table_start, table_size<0x10000?0x10000:table_size); 
     448                rom_table_start, rom_table_end-rom_table_start); 
    451449 
    452450        /* Note: 
  • trunk/coreboot-v2/src/arch/i386/boot/tables.c

    r3057 r3437  
    7373        /* Don't write anything in the traditional x86 BIOS data segment, 
    7474         * for example the linux kernel smp need to use 0x467 to pass reset vector 
     75         * or use 0x40e/0x413 for EBDA finding... 
    7576         */ 
    76         if(new_low_table_end>0x467){ 
     77        if(new_low_table_end>0x400){ 
    7778                unsigned mptable_size; 
    7879                unsigned mpc_start;