summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include/asm/tlb.h
diff options
context:
space:
mode:
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>2016-07-13 15:06:39 +0530
committerMichael Ellerman <mpe@ellerman.id.au>2016-08-01 11:15:10 +1000
commit9d4dab11585ab2ef25d5d2a00a23b25b552c4080 (patch)
treeaa01fd4e59855c0cfa7fe79ee6c69a4f738798d9 /arch/powerpc/include/asm/tlb.h
parent13dce033637b8e4d3266667c4df4d72fc37dc0a9 (diff)
downloadlinux-0-day-9d4dab11585ab2ef25d5d2a00a23b25b552c4080.tar.gz
linux-0-day-9d4dab11585ab2ef25d5d2a00a23b25b552c4080.tar.xz
powerpc/mm: Drop multiple definition of mm_is_core_local
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/include/asm/tlb.h')
-rw-r--r--arch/powerpc/include/asm/tlb.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/arch/powerpc/include/asm/tlb.h b/arch/powerpc/include/asm/tlb.h
index 20733fa518ae1..f6f68f73e8581 100644
--- a/arch/powerpc/include/asm/tlb.h
+++ b/arch/powerpc/include/asm/tlb.h
@@ -46,5 +46,18 @@ static inline void __tlb_remove_tlb_entry(struct mmu_gather *tlb, pte_t *ptep,
#endif
}
+#ifdef CONFIG_SMP
+static inline int mm_is_core_local(struct mm_struct *mm)
+{
+ return cpumask_subset(mm_cpumask(mm),
+ topology_sibling_cpumask(smp_processor_id()));
+}
+#else
+static inline int mm_is_core_local(struct mm_struct *mm)
+{
+ return 1;
+}
+#endif
+
#endif /* __KERNEL__ */
#endif /* __ASM_POWERPC_TLB_H */