diff options
author | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
---|---|---|
committer | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
commit | af1a266670d040d2f4083ff309d732d648afba2a (patch) | |
tree | 2fc46203448ddcc6f81546d379abfaeb323575e9 /roms/u-boot/arch/arm/mach-exynos/soc.c | |
parent | e02cda008591317b1625707ff8e115a4841aa889 (diff) |
Change-Id: Iaf8d18082d3991dec7c0ebbea540f092188eb4ec
Diffstat (limited to 'roms/u-boot/arch/arm/mach-exynos/soc.c')
-rw-r--r-- | roms/u-boot/arch/arm/mach-exynos/soc.c | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/roms/u-boot/arch/arm/mach-exynos/soc.c b/roms/u-boot/arch/arm/mach-exynos/soc.c new file mode 100644 index 000000000..a07c87a2c --- /dev/null +++ b/roms/u-boot/arch/arm/mach-exynos/soc.c @@ -0,0 +1,36 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright (c) 2010 Samsung Electronics. + * Minkyu Kang <mk7.kang@samsung.com> + */ + +#include <common.h> +#include <cpu_func.h> +#include <asm/cache.h> +#include <asm/io.h> +#include <asm/system.h> + +#ifdef CONFIG_TARGET_ESPRESSO7420 +/* + * Exynos7420 uses CPU0 of Cluster-1 as boot CPU. Due to this, branch_if_master + * fails to identify as the boot CPU as the master CPU. As temporary workaround, + * setup the slave CPU boot address as "_main". + */ +extern void _main(void); +void *secondary_boot_addr = (void *)_main; +#endif /* CONFIG_TARGET_ESPRESSO7420 */ + +void reset_cpu(void) +{ +#ifdef CONFIG_CPU_V7A + writel(0x1, samsung_get_base_swreset()); +#endif +} + +#if !CONFIG_IS_ENABLED(SYS_DCACHE_OFF) +void enable_caches(void) +{ + /* Enable D-cache. I-cache is already enabled in start.S */ + dcache_enable(); +} +#endif |