linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Florian Fainelli <f.fainelli@gmail.com>
To: linux-arm-kernel@lists.infradead.org
Cc: rmk+kernel@armlinux.org.uk,
	Florian Fainelli <f.fainelli@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Will Deacon <will.deacon@arm.com>,
	Shaokun Zhang <zhangshaokun@hisilicon.com>,
	linux-kernel@vger.kernel.org (open list)
Subject: [PATCH v2 2/2] ARM: smp: Moved cpu_logical_map[] to smp.h
Date: Mon,  3 Jun 2019 16:18:30 -0700	[thread overview]
Message-ID: <20190603231830.24129-3-f.fainelli@gmail.com> (raw)
In-Reply-To: <20190603231830.24129-1-f.fainelli@gmail.com>

asm/smp.h is included by linux/smp.h and some drivers, in particular
irqchip drivers can access cpu_logical_map[] in order to perform SMP
affinity tasks. Make arm64 consistent with other architectures here.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
---
 arch/arm/include/asm/smp.h      | 6 ++++++
 arch/arm/include/asm/smp_plat.h | 5 -----
 2 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/arch/arm/include/asm/smp.h b/arch/arm/include/asm/smp.h
index 451ae684aaf4..112d78e82f35 100644
--- a/arch/arm/include/asm/smp.h
+++ b/arch/arm/include/asm/smp.h
@@ -20,6 +20,12 @@
 
 #define raw_smp_processor_id() (current_thread_info()->cpu)
 
+/*
+ * Logical CPU mapping.
+ */
+extern u32 __cpu_logical_map[];
+#define cpu_logical_map(cpu)	__cpu_logical_map[cpu]
+
 struct seq_file;
 
 /*
diff --git a/arch/arm/include/asm/smp_plat.h b/arch/arm/include/asm/smp_plat.h
index f2c36acf9886..ca6b91d400cf 100644
--- a/arch/arm/include/asm/smp_plat.h
+++ b/arch/arm/include/asm/smp_plat.h
@@ -66,11 +66,6 @@ static inline int cache_ops_need_broadcast(void)
 }
 #endif
 
-/*
- * Logical CPU mapping.
- */
-extern u32 __cpu_logical_map[];
-#define cpu_logical_map(cpu)	__cpu_logical_map[cpu]
 /*
  * Retrieve logical cpu index corresponding to a given MPIDR[23:0]
  *  - mpidr: MPIDR[23:0] to be used for the look-up
-- 
2.17.1


  parent reply	other threads:[~2019-06-03 23:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-03 23:18 [PATCH v2 0/2] ARM/ARM64: Move cpu_logical_map[] to smp.h Florian Fainelli
2019-06-03 23:18 ` [PATCH v2 1/2] arm64: smp: Moved " Florian Fainelli
2019-06-05 12:09   ` Will Deacon
2019-06-07 17:18     ` Florian Fainelli
2019-06-03 23:18 ` Florian Fainelli [this message]
2019-06-21  7:57   ` [PATCH v2 2/2] ARM: " Russell King - ARM Linux admin
2019-06-21 14:46     ` Florian Fainelli

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=20190603231830.24129-3-f.fainelli@gmail.com \
    --to=f.fainelli@gmail.com \
    --cc=catalin.marinas@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rmk+kernel@armlinux.org.uk \
    --cc=will.deacon@arm.com \
    --cc=zhangshaokun@hisilicon.com \
    /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).