linker script: hax :/
[coreboot.git] / src / arch / x86 / init / bootblock.ld
index bde0430059aeb815481cd93d0387157600fad496..9c8485af6869d4d5d51e720b3c09657e15d47ba3 100644 (file)
@@ -25,13 +25,8 @@ OUTPUT_ARCH(i386)
 TARGET(binary)
 SECTIONS
 {
-       . = CONFIG_ROMBASE;
+       . = ROMSTAGE_BASE;
 
-       /* cut _start into last 64k */
-       _x = .;
-       . = (_x < CONFIG_ROMBASE) ? (CONFIG_ROMBASE) : _x;
-
-       /* This section might be better named .setup */
        .rom . : {
                _rom = .;
                *(.rom.text);
@@ -51,5 +46,13 @@ SECTIONS
                *(.eh_frame);
        }
 
-       _bogus = ASSERT((SIZEOF(.bss) + SIZEOF(.data)) == 0 || CONFIG_AMD_AGESA, "Do not use global variables in romstage");
+       . = CONFIG_DCACHE_RAM_BASE;
+       .car.data . (NOLOAD) : {
+               *(.car.global_data);
+               *(.car.cbmem_console);
+       }
+
+       _bogus = ASSERT((SIZEOF(.car.data) <= CONFIG_DCACHE_RAM_SIZE), "Cache as RAM area is too full");
+/*     _bogus = ASSERT((SIZEOF(.bss) + SIZEOF(.data)) == 0 || CONFIG_AMD_AGESA, "Do not use global variables in romstage");
+ */
 }