linux/arch/arm/mach-mvebu
Thomas Petazzoni 0e2be4c112 ARM: mvebu: fix SMP boot for Armada 38x and Armada 375 Z1 in big endian
The SMP boot on Armada 38x and Armada 375 Z1 is currently broken in
big-endian configurations, and this commit fixes it for both
platforms.

For Armada 375 Z1, the problem was in the
armada_375_smp_cpu1_enable_code part of the code that gets copied to
the Crypto SRAM as a work-around for an issue of the Z1 stepping. This
piece of code was not switching the CPU core to big-endian, and not
endian-swapping the value read from the Resume Address register (the
value is stored little-endian). Due to the introduction of the
conditional 'rev r1, r1' instruction, the offset between the 'ldr r0,
[pc, #4]' instruction and the value it was looking is different
between LE and BE configurations. To solve this, we instead use one
'adr' instruction followed by one 'ldr'.

For Armada 38x, the problem was simply that the CPU core was not
switched to big endian in the secondary CPU startup function.

This change was tested in LE and BE configurations on Armada 385,
Armada 375 Z1 and Armada 375 A0.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Link: https://lkml.kernel.org/r/1404228186-21203-1-git-send-email-thomas.petazzoni@free-electrons.com
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
2014-07-01 17:02:26 +00:00
..
include/mach ARM: mvebu: Simplify headers and make local 2014-02-22 21:19:59 +00:00
armada-370-xp.h irqchip: irq-armada-370-xp: Use cpu notifier to initialize secondary CPUs 2014-05-08 14:42:00 +00:00
board-v7.c ARM: mvebu: update L2/PCIe deadlock workaround after L2CC cleanup 2014-06-30 17:38:43 +00:00
board.h ARM: Kirkwood: t5325: Remove platform device to instantiate audio 2014-05-08 16:23:28 +00:00
coherency_ll.S ARM: mvebu: returns ll_get_cpuid() to ll_get_coherency_cpumask() 2014-05-22 14:26:30 +00:00
coherency.c ARM: mvebu: coherency: fix registration of PCI bus notifier when !PCI 2014-05-22 14:17:46 +00:00
coherency.h ARM: mvebu: Remove the unused argument of set_cpu_coherent() 2014-05-08 16:18:52 +00:00
common.h ARM: mvebu: add function to set the resume boot address for Armada 375 2014-05-08 16:08:14 +00:00
cpu-reset.c ARM: mvebu: start using the CPU reset driver 2014-04-24 05:24:03 +00:00
dove.c bus: mvebu: pass the coherency availability information at init time 2014-04-24 05:00:36 +00:00
headsmp-a9.S ARM: mvebu: fix SMP boot for Armada 38x and Armada 375 Z1 in big endian 2014-07-01 17:02:26 +00:00
headsmp.S ARM: mvebu: Split low level functions to manipulate HW coherency 2014-05-08 16:18:54 +00:00
hotplug.c ARM: mvebu: fix some sparse warnings 2013-11-24 03:27:54 +00:00
Kconfig ARM: mvebu: select ARM_CPU_SUSPEND for Marvell EBU v7 platforms 2014-06-20 20:38:14 +00:00
kirkwood-pm.c ARM: mvebu: Simplify headers and make local 2014-02-22 21:19:59 +00:00
kirkwood-pm.h ARM: mvebu: Move kirkwood DT boards into mach-mvebu 2014-02-22 21:19:55 +00:00
kirkwood.c ARM: Kirkwood: t5325: Remove platform device to instantiate audio 2014-05-08 16:23:28 +00:00
kirkwood.h ARM: mvebu: Simplify headers and make local 2014-02-22 21:19:59 +00:00
Makefile ARM: mvebu: fix cpuidle implementation to work on big-endian systems 2014-06-30 18:15:11 +00:00
mvebu-soc-id.c ARM: SoC updates for 3.16 (part 1) 2014-06-02 16:15:12 -07:00
mvebu-soc-id.h ARM: mvebu: add Armada 375 A0 revision definition 2014-05-08 16:40:14 +00:00
platsmp-a9.c ARM: mvebu: conditionalize Armada 375 SMP workaround 2014-05-08 16:40:15 +00:00
platsmp.c ARM: mvebu: Remove the unused argument of set_cpu_coherent() 2014-05-08 16:18:52 +00:00
pmsu_ll.S ARM: mvebu: fix cpuidle implementation to work on big-endian systems 2014-06-30 18:15:11 +00:00
pmsu.c ARM: mvebu: fix cpuidle implementation to work on big-endian systems 2014-06-30 18:15:11 +00:00
pmsu.h arm: mvebu: Add initial support for power managmement service unit 2012-11-21 16:49:36 +01:00
system-controller.c ARM: mvebu: add function to set the resume boot address for Armada 375 2014-05-08 16:08:14 +00:00