summaryrefslogtreecommitdiff
path: root/arch/arm/kernel
diff options
context:
space:
mode:
authorSudeep Holla <sudeep.holla@arm.com>2014-01-08 17:24:21 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-01-25 16:49:29 (GMT)
commit02f8b9bcfa032827a7ddd78ea5eb3a8393ec037c (patch)
tree4b93abe8c651c59f087d4342c5e9899e3cce020f /arch/arm/kernel
parent81fd649b0a6340d0e311deedc5dd156c36873450 (diff)
downloadlinux-fsl-qoriq-02f8b9bcfa032827a7ddd78ea5eb3a8393ec037c.tar.xz
ARM: 7934/1: DT/kernel: fix arch_match_cpu_phys_id to avoid erroneous match
commit e44ef891e9e68b6ce7d3fd3bac73b7d5433050ae upstream. The MPIDR contains specific bitfields(MPIDR.Aff{2..0}) which uniquely identify a CPU, in addition to some non-identifying information and reserved bits. The ARM cpu binding defines the 'reg' property to only contain the affinity bits, and any cpu nodes with other bits set in their 'reg' entry are skipped. As such it is not necessary to mask the phys_id with MPIDR_HWID_BITMASK, and doing so could lead to matching erroneous CPU nodes in the device tree. This patch removes the masking of the physical identifier. Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Sudeep Holla <sudeep.holla@arm.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/arm/kernel')
-rw-r--r--arch/arm/kernel/devtree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/kernel/devtree.c b/arch/arm/kernel/devtree.c
index f35906b..41960fb 100644
--- a/arch/arm/kernel/devtree.c
+++ b/arch/arm/kernel/devtree.c
@@ -171,7 +171,7 @@ void __init arm_dt_init_cpu_maps(void)
bool arch_match_cpu_phys_id(int cpu, u64 phys_id)
{
- return (phys_id & MPIDR_HWID_BITMASK) == cpu_logical_map(cpu);
+ return phys_id == cpu_logical_map(cpu);
}
/**