From: jszhang@marvell.com (Jisheng Zhang)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/2] arm: berlin: use non-self-cleared reset register to reset cpu
Date: Tue, 7 Jul 2015 15:10:34 +0800 [thread overview]
Message-ID: <1436253035-371-2-git-send-email-jszhang@marvell.com> (raw)
In-Reply-To: <1436253035-371-1-git-send-email-jszhang@marvell.com>
In Berlin SoCs, there are two kinds of cpu reset control registers: the
first one's corresponding bits will be self-cleared after some cycles,
while the second one's bits won't. Previously the first kind of reset
control register is used, this patch uses the second kind one to prepare
for the next hotplug commit.
Signed-off-by: Jisheng Zhang <jszhang@marvell.com>
---
arch/arm/mach-berlin/platsmp.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-berlin/platsmp.c b/arch/arm/mach-berlin/platsmp.c
index 34a3753..bde327b 100644
--- a/arch/arm/mach-berlin/platsmp.c
+++ b/arch/arm/mach-berlin/platsmp.c
@@ -17,7 +17,7 @@
#include <asm/smp_plat.h>
#include <asm/smp_scu.h>
-#define CPU_RESET 0x00
+#define CPU_RESET 0x20
#define RESET_VECT 0x00
#define SW_RESET_ADDR 0x94
@@ -31,6 +31,8 @@ static inline void berlin_perform_reset_cpu(unsigned int cpu)
u32 val;
val = readl(cpu_ctrl + CPU_RESET);
+ val &= ~BIT(cpu_logical_map(cpu));
+ writel(val, cpu_ctrl + CPU_RESET);
val |= BIT(cpu_logical_map(cpu));
writel(val, cpu_ctrl + CPU_RESET);
}
--
2.1.4
next prev parent reply other threads:[~2015-07-07 7:10 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-07 7:10 [PATCH 0/2] arm: berlin: add cpu hotplug support Jisheng Zhang
2015-07-07 7:10 ` Jisheng Zhang [this message]
2015-07-07 7:10 ` [PATCH 2/2] arm: berlin: add CPU " Jisheng Zhang
2015-07-07 7:28 ` [PATCH 0/2] arm: berlin: add cpu " Sebastian Hesselbarth
2015-07-07 7:38 ` Jisheng Zhang
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=1436253035-371-2-git-send-email-jszhang@marvell.com \
--to=jszhang@marvell.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).