powerpc/smp: Use cpu_to_chip_id() to find core siblings
authorOliver O'Halloran <oohall@gmail.com>
Thu, 29 Jun 2017 07:12:53 +0000 (17:12 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Thu, 31 Aug 2017 04:26:50 +0000 (14:26 +1000)
commite3d8b67e2c60dcd35661d34df249f20d20463f0c
tree86fe1701ebde845efae026d512b4a9abba944b0b
parent197267d0356004a31c4d6b6336598f5dff3301e1
powerpc/smp: Use cpu_to_chip_id() to find core siblings

When building the CPU scheduler topology the kernel uses the ibm,chipid
property from the devicetree to group logical CPUs. Currently the DT
search for this property is open-coded in smp.c and this functionality
is a duplication of what's in cpu_to_chip_id() already. This patch
removes the existing search in favor of that.

It's worth mentioning that the semantics of the search are different
in cpu_to_chip_id(). When there is no ibm,chipid in the CPUs node it
will also search /cpus and / for the property, but this should not
effect the output topology.

Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/smp.c