8659e4072e
Use the value of CONSOLE_PRERAM_BUFFER_SIZE to determine if we can do CBMEM console in bootblock and romstage. Kconfig forces it to zero if _BASE is unset or we cannot do CAR migration on x86. Add CBMEM console to bootblock, except for x86. Only one of bootblock and romstage clears the pre-RAM buffer. To start with empty console log on S3 wakeup, ramstage now clears previous contents of CBMEM buffer if there was no pre-RAM buffer. Unify Kconfig variable naming. TODO: ARM configurations do not define PRERAM_BUFFER_BASE values. Change-Id: I70d82da629529dbfd7bc9491223abd703cbc0115 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: http://review.coreboot.org/7862 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin <adurbin@google.com>
62 lines
1.5 KiB
Text
62 lines
1.5 KiB
Text
/*
|
|
* This file is part of the coreboot project.
|
|
*
|
|
* Copyright (C) 2006 Advanced Micro Devices, Inc.
|
|
* Copyright (C) 2008-2010 coresystems GmbH
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation; version 2 of the License.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program; if not, write to the Free Software
|
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
|
*/
|
|
|
|
/* We use ELF as output format. So that we can debug the code in some form. */
|
|
OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
|
|
OUTPUT_ARCH(arm)
|
|
INCLUDE ldoptions
|
|
|
|
PHDRS
|
|
{
|
|
to_load PT_LOAD;
|
|
}
|
|
|
|
ENTRY(_start)
|
|
TARGET(binary)
|
|
SECTIONS
|
|
{
|
|
. = CONFIG_BOOTBLOCK_BASE;
|
|
|
|
.bootblock . : {
|
|
*(.text._start);
|
|
KEEP(*(.id));
|
|
*(.text);
|
|
*(.text.*);
|
|
*(.rodata);
|
|
*(.rodata.*);
|
|
*(.data);
|
|
*(.data.*);
|
|
*(.bss);
|
|
*(.bss.*);
|
|
*(.sbss);
|
|
*(.sbss.*);
|
|
} : to_load = 0xff
|
|
|
|
preram_cbmem_console = CONFIG_CONSOLE_PRERAM_BUFFER_BASE;
|
|
verstage_preram_cbmem_console = CONFIG_CONSOLE_PRERAM_BUFFER_BASE;
|
|
|
|
/DISCARD/ : {
|
|
*(.comment)
|
|
*(.note)
|
|
*(.comment.*)
|
|
*(.note.*)
|
|
*(.ARM.*)
|
|
}
|
|
}
|