From: Magnus Damm <magnus.damm@gmail.com>
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 06/06] ARM: shmobile: Remove emev2_get_core_count()
Date: Tue, 12 Feb 2013 15:45:34 +0000 [thread overview]
Message-ID: <20130212154534.13067.45412.sendpatchset@w520> (raw)
In-Reply-To: <20130212154438.13067.77359.sendpatchset@w520>
From: Magnus Damm <damm@opensource.se>
Reduce the number of lines of code in smp-emev2.c
by getting rid of the emev2_get_core_count() function.
Signed-off-by: Magnus Damm <damm@opensource.se>
---
arch/arm/mach-shmobile/smp-emev2.c | 21 ++++++++-------------
1 file changed, 8 insertions(+), 13 deletions(-)
--- 0007/arch/arm/mach-shmobile/smp-emev2.c
+++ work/arch/arm/mach-shmobile/smp-emev2.c 2013-02-12 23:51:54.000000000 +0900
@@ -50,18 +50,6 @@ static void modify_scu_cpu_psr(unsigned
}
-static unsigned int __init emev2_get_core_count(void)
-{
- if (!scu_base) {
- scu_base = ioremap(EMEV2_SCU_BASE, PAGE_SIZE);
- emev2_clock_init(); /* need ioremapped SMU */
- }
-
- WARN_ON_ONCE(!scu_base);
-
- return scu_base ? scu_get_core_count(scu_base) : 1;
-}
-
static void __cpuinit emev2_secondary_init(unsigned int cpu)
{
gic_secondary_init(0);
@@ -93,7 +81,14 @@ static void __init emev2_smp_prepare_cpu
static void __init emev2_smp_init_cpus(void)
{
- unsigned int ncores = emev2_get_core_count();
+ unsigned int ncores;
+
+ if (!scu_base) {
+ scu_base = ioremap(EMEV2_SCU_BASE, PAGE_SIZE);
+ emev2_clock_init(); /* need ioremapped SMU */
+ }
+
+ ncores = scu_base ? scu_get_core_count(scu_base) : 1;
shmobile_smp_init_cpus(ncores);
}
WARNING: multiple messages have this Message-ID (diff)
From: magnus.damm@gmail.com (Magnus Damm)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 06/06] ARM: shmobile: Remove emev2_get_core_count()
Date: Wed, 13 Feb 2013 00:45:34 +0900 [thread overview]
Message-ID: <20130212154534.13067.45412.sendpatchset@w520> (raw)
In-Reply-To: <20130212154438.13067.77359.sendpatchset@w520>
From: Magnus Damm <damm@opensource.se>
Reduce the number of lines of code in smp-emev2.c
by getting rid of the emev2_get_core_count() function.
Signed-off-by: Magnus Damm <damm@opensource.se>
---
arch/arm/mach-shmobile/smp-emev2.c | 21 ++++++++-------------
1 file changed, 8 insertions(+), 13 deletions(-)
--- 0007/arch/arm/mach-shmobile/smp-emev2.c
+++ work/arch/arm/mach-shmobile/smp-emev2.c 2013-02-12 23:51:54.000000000 +0900
@@ -50,18 +50,6 @@ static void modify_scu_cpu_psr(unsigned
}
-static unsigned int __init emev2_get_core_count(void)
-{
- if (!scu_base) {
- scu_base = ioremap(EMEV2_SCU_BASE, PAGE_SIZE);
- emev2_clock_init(); /* need ioremapped SMU */
- }
-
- WARN_ON_ONCE(!scu_base);
-
- return scu_base ? scu_get_core_count(scu_base) : 1;
-}
-
static void __cpuinit emev2_secondary_init(unsigned int cpu)
{
gic_secondary_init(0);
@@ -93,7 +81,14 @@ static void __init emev2_smp_prepare_cpu
static void __init emev2_smp_init_cpus(void)
{
- unsigned int ncores = emev2_get_core_count();
+ unsigned int ncores;
+
+ if (!scu_base) {
+ scu_base = ioremap(EMEV2_SCU_BASE, PAGE_SIZE);
+ emev2_clock_init(); /* need ioremapped SMU */
+ }
+
+ ncores = scu_base ? scu_get_core_count(scu_base) : 1;
shmobile_smp_init_cpus(ncores);
}
next prev parent reply other threads:[~2013-02-12 15:45 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-12 15:44 [PATCH 00/06] ARM: shmobile: Trivial SMP cleanups Magnus Damm
2013-02-12 15:44 ` Magnus Damm
2013-02-12 15:44 ` [PATCH 01/06] ARM: shmobile: Remove unused headers from hotplug.c Magnus Damm
2013-02-12 15:44 ` Magnus Damm
2013-02-12 15:44 ` [PATCH 02/06] ARM: shmobile: Remove partial CPU Hotplug from EMEV2 Magnus Damm
2013-02-12 15:44 ` Magnus Damm
2013-02-12 15:45 ` [PATCH 03/06] ARM: shmobile: Move EMEV2 CPU boot vector setup code Magnus Damm
2013-02-12 15:45 ` Magnus Damm
2013-02-12 15:45 ` [PATCH 04/06] ARM: shmobile: Remove sh73a0_get_core_count() Magnus Damm
2013-02-12 15:45 ` Magnus Damm
2013-02-12 15:45 ` [PATCH 05/06] ARM: shmobile: Remove r8a7779_get_core_count() Magnus Damm
2013-02-12 15:45 ` Magnus Damm
2013-02-12 15:45 ` Magnus Damm [this message]
2013-02-12 15:45 ` [PATCH 06/06] ARM: shmobile: Remove emev2_get_core_count() Magnus Damm
2013-02-12 22:16 ` [PATCH 00/06] ARM: shmobile: Trivial SMP cleanups Simon Horman
2013-02-12 22:16 ` Simon Horman
2013-02-13 0:47 ` Magnus Damm
2013-02-13 0:47 ` Magnus Damm
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=20130212154534.13067.45412.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.