nyan: tegra124: Set up dynamic cbmem.
BUG=None TEST=Built and booted into ramstage on nyan. After this change, ramstage gets past setting up cbmem and fails when trying to load a payload. BRANCH=None Change-Id: I65403ecb65c7e1a45d61b1ead9460a73d85f750a Signed-off-by: Gabe Black <gabeblack@google.com> Reviewed-on: https://chromium-review.googlesource.com/173542 Reviewed-by: Ronald Minnich <rminnich@chromium.org> Tested-by: Ronald Minnich <rminnich@chromium.org> Commit-Queue: Ronald Minnich <rminnich@chromium.org>
This commit is contained in:
parent
e142b9572a
commit
b6e1a70103
4 changed files with 31 additions and 0 deletions
|
|
@ -19,12 +19,15 @@
|
|||
|
||||
#include <arch/stages.h>
|
||||
#include <cbfs.h>
|
||||
#include <cbmem.h>
|
||||
#include <console/console.h>
|
||||
|
||||
void main(void)
|
||||
{
|
||||
void *entry;
|
||||
|
||||
cbmem_initialize_empty();
|
||||
|
||||
entry = cbfs_load_stage(CBFS_DEFAULT_MEDIA, "fallback/coreboot_ram");
|
||||
stage_exit(entry);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ config SOC_NVIDIA_TEGRA124
|
|||
select HAVE_UART_SPECIAL
|
||||
select BOOTBLOCK_CONSOLE
|
||||
select EARLY_CONSOLE
|
||||
select DYNAMIC_CBMEM
|
||||
select ARM_BOOTBLOCK_CUSTOM
|
||||
select ARM_BOOTBLOCK_ARMV4
|
||||
select ARM_ROMSTAGE_ARMV7
|
||||
|
|
|
|||
|
|
@ -21,6 +21,7 @@ bootblock-$(CONFIG_CONSOLE_SERIAL_UART) += uart.c
|
|||
endif
|
||||
|
||||
romstage-y += cbfs.c
|
||||
romstage-y += cbmem.c
|
||||
romstage-y += dma.c
|
||||
romstage-y += monotonic_timer.c
|
||||
romstage-y += spi.c
|
||||
|
|
@ -30,6 +31,7 @@ romstage-$(CONFIG_CONSOLE_SERIAL_UART) += uart.c
|
|||
endif
|
||||
|
||||
ramstage-y += cbfs.c
|
||||
ramstage-y += cbmem.c
|
||||
ramstage-y += dma.c
|
||||
ramstage-y += monotonic_timer.c
|
||||
ramstage-y += spi.c
|
||||
|
|
|
|||
25
src/soc/nvidia/tegra124/cbmem.c
Normal file
25
src/soc/nvidia/tegra124/cbmem.c
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
/*
|
||||
* This file is part of the coreboot project.
|
||||
*
|
||||
* Copyright 2013 Google Inc.
|
||||
*
|
||||
* 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
|
||||
*/
|
||||
|
||||
#include <cbmem.h>
|
||||
|
||||
void *cbmem_top(void)
|
||||
{
|
||||
return (void *)(CONFIG_SYS_SDRAM_BASE + (CONFIG_DRAM_SIZE_MB << 20UL));
|
||||
}
|
||||
Loading…
Reference in a new issue