From: Magnus Damm <magnus.damm@gmail.com>
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 04/07] ARM: shmobile: Use shared SCU SMP boot code on emev2
Date: Wed, 31 Jul 2013 07:07:40 +0000 [thread overview]
Message-ID: <20130731070740.14444.10398.sendpatchset@w520> (raw)
In-Reply-To: <20130731070702.14444.64961.sendpatchset@w520>
From: Magnus Damm <damm@opensource.se>
Use shared SCU code on emev2 for SMP boot.
Signed-off-by: Magnus Damm <damm@opensource.se>
---
arch/arm/mach-shmobile/Makefile | 2 +-
arch/arm/mach-shmobile/smp-emev2.c | 19 ++++++++++---------
2 files changed, 11 insertions(+), 10 deletions(-)
--- 0004/arch/arm/mach-shmobile/Makefile
+++ work/arch/arm/mach-shmobile/Makefile 2013-07-31 11:58:03.000000000 +0900
@@ -34,7 +34,7 @@ endif
smp-y := platsmp.o headsmp.o
smp-$(CONFIG_ARCH_SH73A0) += smp-sh73a0.o headsmp-scu.o platsmp-scu.o
smp-$(CONFIG_ARCH_R8A7779) += smp-r8a7779.o headsmp-scu.o platsmp-scu.o
-smp-$(CONFIG_ARCH_EMEV2) += smp-emev2.o headsmp-scu.o
+smp-$(CONFIG_ARCH_EMEV2) += smp-emev2.o headsmp-scu.o platsmp-scu.o
# IRQ objects
obj-$(CONFIG_ARCH_SH7372) += entry-intc.o
--- 0001/arch/arm/mach-shmobile/smp-emev2.c
+++ work/arch/arm/mach-shmobile/smp-emev2.c 2013-07-31 11:58:39.000000000 +0900
@@ -34,6 +34,12 @@
static int emev2_boot_secondary(unsigned int cpu, struct task_struct *idle)
{
+ int ret;
+
+ ret = shmobile_smp_scu_boot_secondary(cpu, idle);
+ if (ret)
+ return ret;
+
arch_send_wakeup_ipi_mask(cpumask_of(cpu_logical_map(cpu)));
return 0;
}
@@ -42,21 +48,16 @@ static void __init emev2_smp_prepare_cpu
{
void __iomem *smu;
- /* setup EMEV2 specific SCU base, enable */
- shmobile_scu_base = ioremap(EMEV2_SCU_BASE, PAGE_SIZE);
- scu_enable(shmobile_scu_base);
-
- /* Tell ROM loader about our vector (in headsmp-scu.S, headsmp.S) */
+ /* Tell ROM loader about our vector (in headsmp.S) */
smu = ioremap(EMEV2_SMU_BASE, PAGE_SIZE);
if (smu) {
iowrite32(__pa(shmobile_boot_vector), smu + SMU_GENERAL_REG0);
iounmap(smu);
}
- shmobile_boot_fn = virt_to_phys(shmobile_boot_scu);
- shmobile_boot_arg = (unsigned long)shmobile_scu_base;
- /* enable cache coherency on booting CPU */
- scu_power_mode(shmobile_scu_base, SCU_PM_NORMAL);
+ /* setup EMEV2 specific SCU bits */
+ shmobile_scu_base = ioremap(EMEV2_SCU_BASE, PAGE_SIZE);
+ shmobile_smp_scu_prepare_cpus(max_cpus);
}
struct smp_operations emev2_smp_ops __initdata = {
next prev parent reply other threads:[~2013-07-31 7:07 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-31 7:07 [PATCH 00/07] ARM: shmobile: sh73a0, r8a7779 and emev2 SMP SCU rework Magnus Damm
2013-07-31 7:07 ` [PATCH 01/07] ARM: shmobile: Introduce shared SCU SMP boot code Magnus Damm
2013-07-31 7:07 ` [PATCH 02/07] ARM: shmobile: Use shared SCU SMP boot code on sh73a0 Magnus Damm
2013-07-31 7:07 ` [PATCH 03/07] ARM: shmobile: Use shared SCU SMP boot code on r8a7779 Magnus Damm
2013-07-31 7:07 ` Magnus Damm [this message]
2013-07-31 7:07 ` [PATCH 05/07] ARM: shmobile: Add shared SCU CPU Hotplug code Magnus Damm
2013-07-31 7:07 ` [PATCH 06/07] ARM: shmobile: Use shared SCU CPU Hotplug code on sh73a0 Magnus Damm
2013-07-31 7:08 ` [PATCH 07/07] ARM: shmobile: Use shared SCU CPU Hotplug code on r8a7779 Magnus Damm
2013-08-01 7:34 ` [PATCH 00/07] ARM: shmobile: sh73a0, r8a7779 and emev2 SMP SCU rework Simon Horman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130731070740.14444.10398.sendpatchset@w520 \
--to=magnus.damm@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).