diff options
author | Masahiro Yamada <yamada.masahiro@socionext.com> | 2016-04-21 05:43:18 (GMT) |
---|---|---|
committer | Masahiro Yamada <yamada.masahiro@socionext.com> | 2016-04-24 00:54:08 (GMT) |
commit | 9d0c2ceb35be7016977560a92fc67e3e704e5c9f (patch) | |
tree | 67f17e8bbc13a293b7d24f7789a3fb0692c1e284 /arch/arm/mach-uniphier/arm64/smp_kick_cpus.c | |
parent | 881aa5a79a94a65500959428328f348a18d3d9fe (diff) | |
download | u-boot-fsl-qoriq-9d0c2ceb35be7016977560a92fc67e3e704e5c9f.tar.xz |
ARM: uniphier: add PH1-LD20 SoC support
This is the first ARMv8 SoC from Socionext Inc.
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'arch/arm/mach-uniphier/arm64/smp_kick_cpus.c')
-rw-r--r-- | arch/arm/mach-uniphier/arm64/smp_kick_cpus.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/arch/arm/mach-uniphier/arm64/smp_kick_cpus.c b/arch/arm/mach-uniphier/arm64/smp_kick_cpus.c new file mode 100644 index 0000000..64412e0 --- /dev/null +++ b/arch/arm/mach-uniphier/arm64/smp_kick_cpus.c @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2016 Masahiro Yamada <yamada.masahiro@socionext.com> + * + * SPDX-License-Identifier: GPL-2.0+ + */ + +#include <common.h> +#include <mapmem.h> +#include <linux/io.h> +#include <linux/sizes.h> + +#define UNIPHIER_SMPCTRL_ROM_RSV0 0x59801200 + +void uniphier_smp_setup(void); +void uniphier_secondary_startup(void); + +void uniphier_smp_kick_all_cpus(void) +{ + void __iomem *rom_boot_rsv0; + + rom_boot_rsv0 = map_sysmem(UNIPHIER_SMPCTRL_ROM_RSV0, SZ_8); + + writeq((u64)uniphier_secondary_startup, rom_boot_rsv0); + readq(rom_boot_rsv0); /* relax */ + + unmap_sysmem(rom_boot_rsv0); + + uniphier_smp_setup(); + + asm("sev"); /* Bring up all secondary CPUs from Boot ROM into U-Boot */ +} |