linux_old1/arch/arm/mach-vexpress
Lorenzo Pieralisi 525d4015e6 ARM: vexpress: refine MCPM smp operations override criteria
Current vexpress smp init code detects whether to override the
default smp ops with MCPM smp ops by matching the "cci-400"
compatible string, in that MCPM requires control over CCI ports
to manage low-power states entry/exit.

The "cci-400" compatible string check is a necessary but not
sufficient condition for MCPM to work, because the cci-400
can be made visible to the kernel, but firmware can nonetheless
disable non-secure CCI ports control, while still allowing PMU
access; if booted in non-secure world, the kernel would still
blindly override smp operations with MCPM operations, resulting
in kernel faults when the CCI ports programming interface is
accessed from non-secure world.

This means that the "cci-400" compatible string check would
result in a false positive in systems that eg boot in HYP mode,
where CCI ports non-secure access is explicitly not allowed,
and it is reported in the respective device tree nodes with
CCI ports marked as disabled.

Refactor the smp operations initialization to make sure that
the kernel is actually allowed to take control over CCI ports
(by enabling MCPM smp operations) before overriding default
vexpress smp operations.

Cc: Liviu Dudau <liviu.dudau@arm.com>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Acked-by: Nicolas Pitre <nico@linaro.org>
Tested-by: Jon Medhurst <tixy@linaro.org>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
2016-10-17 14:27:54 +01:00
..
Kconfig ARM: do away with ARCH_[WANT_OPTIONAL|REQUIRE]_GPIOLIB 2016-06-03 12:18:13 -07:00
Makefile ARM: vexpress/mps2: introduce MPS2 platform 2016-04-26 12:50:01 +02:00
Makefile.boot ARM: vexpress/mps2: introduce MPS2 platform 2016-04-26 12:50:01 +02:00
core.h ARM: use const and __initconst for smp_operations 2015-12-01 22:17:45 +01:00
dcscb.c ARM: vexpress: migrate DCSCB to the new MCPM backend abstraction 2015-04-03 12:52:48 -07:00
dcscb_setup.S ARM: vexpress/dcscb: handle platform coherency exit/setup and CCI 2013-05-29 15:50:35 -04:00
hotplug.c ARM: vexpress/hotplug: fix missing core.h include 2016-06-13 09:55:51 +01:00
platsmp.c ARM: vexpress: refine MCPM smp operations override criteria 2016-10-17 14:27:54 +01:00
spc.c ARM: SoC cleanups for v4.8 2016-08-01 18:21:13 -04:00
spc.h ARM: vexpress/TC2: Implement MCPM power_down_finish() 2013-11-25 14:12:14 -08:00
tc2_pm.c irqchip/gic: Ensure gic_cpu_if_up/down() programs correct GIC instance 2015-08-04 14:14:06 +02:00
v2m-mps2.c ARM: vexpress/mps2: introduce MPS2 platform 2016-04-26 12:50:01 +02:00
v2m.c ARM: vexpress: Remove non-DT code 2014-11-28 16:08:16 +01:00