arm: versatile: don't mark pen as __INIT
authorMark Rutland <mark.rutland@arm.com>
Mon, 10 Jun 2013 15:07:24 +0000 (16:07 +0100)
committerJon Medhurst <tixy@linaro.org>
Mon, 1 Jul 2013 10:04:36 +0000 (11:04 +0100)
commitbba0859a996589e9673717864d104a7603687941
treeff785c5eb37816b133bb0df4f14174b8236bdd2f
parent49428cc5c3413d8a955923e55c36515e02426d8a
arm: versatile: don't mark pen as __INIT

When booting fewer cores than are physically present on a versatile
platform (e.g. when passing maxcpus=N on the command line), some
secondary cores may remain in the holding pen, which is marked __INIT.
Late in the boot process, the memory comprising the holding pen will be
released to the kernel for more general use, and may be overwritten with
arbitrary data, which can cause the held secondaries to start behaving
unpredictably. This can lead to all manner of odd behaviour from the
kernel.

Instead don't mark the section as __INIT. This means we can't reuse the
pen memory, but we won't get secondaries corrupting the rest of the
kernel.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Acked-by: Pawel Moll <pawel.moll@arm.com>
Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
arch/arm/plat-versatile/headsmp.S