aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm64/kernel/cpuinfo.c
diff options
context:
space:
mode:
authorSudeep Holla <sudeep.holla@arm.com>2015-01-08 05:42:34 -0500
committerCatalin Marinas <catalin.marinas@arm.com>2015-01-15 06:55:07 -0500
commit5d425c18653731af62831d30a4fa023d532657a9 (patch)
tree0dff152cf14260f272bf30d8d28269c10935e90f /arch/arm64/kernel/cpuinfo.c
parent26a945caf381225c9a1e68f14826a884c08ea9cb (diff)
arm64: kernel: add support for cpu cache information
This patch adds support for cacheinfo on ARM64. On ARMv8, the cache hierarchy can be identified through Cache Level ID (CLIDR) register while the cache geometry is provided by Cache Size ID (CCSIDR) register. Since the architecture doesn't provide any way of detecting the cpus sharing particular cache, device tree is used for the same purpose. Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> Cc: Will Deacon <will.deacon@arm.com> Cc: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Diffstat (limited to 'arch/arm64/kernel/cpuinfo.c')
-rw-r--r--arch/arm64/kernel/cpuinfo.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/arch/arm64/kernel/cpuinfo.c b/arch/arm64/kernel/cpuinfo.c
index 07d435cf2eea..49782282a027 100644
--- a/arch/arm64/kernel/cpuinfo.c
+++ b/arch/arm64/kernel/cpuinfo.c
@@ -231,15 +231,3 @@ void __init cpuinfo_store_boot_cpu(void)
231 231
232 boot_cpu_data = *info; 232 boot_cpu_data = *info;
233} 233}
234
235u64 __attribute_const__ icache_get_ccsidr(void)
236{
237 u64 ccsidr;
238
239 WARN_ON(preemptible());
240
241 /* Select L1 I-cache and read its size ID register */
242 asm("msr csselr_el1, %1; isb; mrs %0, ccsidr_el1"
243 : "=r"(ccsidr) : "r"(1L));
244 return ccsidr;
245}