From: Magnus Damm <magnus.damm@gmail.com>
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 02/06] ARM: shmobile: Add SCU boot function using argument
Date: Mon, 10 Jun 2013 09:19:46 +0000 [thread overview]
Message-ID: <20130610091946.18944.39252.sendpatchset@w520> (raw)
In-Reply-To: <20130610091925.18944.68117.sendpatchset@w520>
From: Magnus Damm <damm@opensource.se>
Add a shmoible_boot_scu function that assumes that the base address
of the SCU is passed in r0. This code is free from inline virtual
to physical address conversion.
Signed-off-by: Magnus Damm <damm@opensource.se>
---
arch/arm/mach-shmobile/headsmp-scu.S | 13 +++++++++++++
arch/arm/mach-shmobile/include/mach/common.h | 1 +
2 files changed, 14 insertions(+)
--- 0001/arch/arm/mach-shmobile/headsmp-scu.S
+++ work/arch/arm/mach-shmobile/headsmp-scu.S 2013-06-10 17:44:41.000000000 +0900
@@ -51,6 +51,19 @@ ENTRY(shmobile_secondary_vector_scu)
2: .long shmobile_scu_base - PAGE_OFFSET + PLAT_PHYS_OFFSET
ENDPROC(shmobile_secondary_vector_scu)
+ENTRY(shmobile_boot_scu)
+ @ r0 = SCU base address
+ mrc p15, 0, r1, c0, c0, 5 @ read MIPDR
+ and r1, r1, #3 @ mask out cpu ID
+ lsl r1, r1, #3 @ we will shift by cpu_id * 8 bits
+ ldr r2, [r0, #8] @ SCU Power Status Register
+ mov r3, #3
+ bic r2, r2, r3, lsl r1 @ Clear bits of our CPU (Run Mode)
+ str r2, [r0, #8] @ write back
+
+ b shmobile_invalidate_start
+ENDPROC(shmobile_boot_scu)
+
.text
.globl shmobile_scu_base
shmobile_scu_base:
--- 0004/arch/arm/mach-shmobile/include/mach/common.h
+++ work/arch/arm/mach-shmobile/include/mach/common.h 2013-06-10 16:32:25.000000000 +0900
@@ -11,6 +11,7 @@ extern void shmobile_boot_vector(void);
extern unsigned long shmobile_boot_fn;
extern unsigned long shmobile_boot_arg;
extern void shmobile_secondary_vector_scu(void);
+extern void shmobile_boot_scu(void);
struct clk;
extern int shmobile_clk_init(void);
extern void shmobile_handle_irq_intc(struct pt_regs *);
next prev parent reply other threads:[~2013-06-10 9:19 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-10 9:19 [PATCH 00/06] ARM: shmobile: SMP virt_to_phys() conversion Magnus Damm
2013-06-10 9:19 ` [PATCH 01/06] ARM: shmobile: Add SMP boot function and argument Magnus Damm
2013-06-12 14:09 ` Simon Horman
2013-06-10 9:19 ` Magnus Damm [this message]
2013-06-12 14:09 ` [PATCH 02/06] ARM: shmobile: Add SCU boot function using argument Simon Horman
2013-06-10 9:19 ` [PATCH 03/06] ARM: shmobile: r8a7779 SMP with SCU boot fn and args Magnus Damm
2013-06-12 14:09 ` Simon Horman
2013-06-10 9:20 ` [PATCH 04/06] ARM: shmobile: sh73a0 " Magnus Damm
2013-06-12 14:09 ` Simon Horman
2013-06-10 9:20 ` [PATCH 05/06] ARM: shmobile: EMEV2 " Magnus Damm
2013-06-12 14:09 ` Simon Horman
2013-06-10 9:20 ` [PATCH 06/06] ARM: shmobile: Remove old SCU boot code Magnus Damm
2013-06-12 14:10 ` 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=20130610091946.18944.39252.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).