9
0
Fork 0

tegra: start maincomplex execution at correct offset

Signed-off-by: Lucas Stach <dev@lynxeye.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
Lucas Stach 2013-09-29 21:59:31 +02:00 committed by Sascha Hauer
parent 5163280d65
commit 02568520ee
1 changed files with 3 additions and 8 deletions

View File

@ -19,6 +19,7 @@
#include <common.h>
#include <asm/barebox-arm-head.h>
#include <asm/barebox-arm.h>
#include <mach/lowlevel.h>
#include <mach/tegra20-car.h>
#include <mach/tegra20-pmc.h>
@ -194,13 +195,6 @@ void barebox_arm_reset_vector(void)
/* minimal initialization, OK for both ARMv4 and ARMv7 */
tegra_cpu_lowlevel_setup();
/*
* If we are already running on the main CPU complex jump straight
* to the maincomplex entry point.
*/
if (tegra_cpu_is_maincomplex())
tegra_maincomplex_entry();
/* get the number of cores in the main CPU complex of the current SoC */
num_cores = tegra_get_num_cores();
if (!num_cores)
@ -212,7 +206,8 @@ void barebox_arm_reset_vector(void)
stop_maincomplex_clocks(num_cores);
/* set start address for the main CPU complex processors */
writel(barebox_arm_head, TEGRA_EXCEPTION_VECTORS_BASE + 0x100);
writel(tegra_maincomplex_entry - get_runtime_offset(),
TEGRA_EXCEPTION_VECTORS_BASE + 0x100);
/* bring up main CPU complex */
start_cpu0_clocks();