linux/arch/arm/mach-tegra
Russell King 6ebbf2ce43 ARM: convert all "mov.* pc, reg" to "bx reg" for ARMv6+
ARMv6 and greater introduced a new instruction ("bx") which can be used
to return from function calls.  Recent CPUs perform better when the
"bx lr" instruction is used rather than the "mov pc, lr" instruction,
and this sequence is strongly recommended to be used by the ARM
architecture manual (section A.4.1.1).

We provide a new macro "ret" with all its variants for the condition
code which will resolve to the appropriate instruction.

Rather than doing this piecemeal, and miss some instances, change all
the "mov pc" instances to use the new macro, with the exception of
the "movs" instruction and the kprobes code.  This allows us to detect
the "mov pc, lr" case and fix it up - and also gives us the possibility
of deploying this for other registers depending on the CPU selection.

Reported-by: Will Deacon <will.deacon@arm.com>
Tested-by: Stephen Warren <swarren@nvidia.com> # Tegra Jetson TK1
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr> # mioa701_bootresume.S
Tested-by: Andrew Lunn <andrew@lunn.ch> # Kirkwood
Tested-by: Shawn Guo <shawn.guo@freescale.com>
Tested-by: Tony Lindgren <tony@atomide.com> # OMAPs
Tested-by: Gregory CLEMENT <gregory.clement@free-electrons.com> # Armada XP, 375, 385
Acked-by: Sekhar Nori <nsekhar@ti.com> # DaVinci
Acked-by: Christoffer Dall <christoffer.dall@linaro.org> # kvm/hyp
Acked-by: Haojian Zhuang <haojian.zhuang@gmail.com> # PXA3xx
Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> # Xen
Tested-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> # ARMv7M
Tested-by: Simon Horman <horms+renesas@verge.net.au> # Shmobile
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2014-07-18 12:29:04 +01:00
..
apbio.c tree-wide: use reinit_completion instead of INIT_COMPLETION 2013-11-15 09:32:21 +09:00
apbio.h ARM: tegra: apbio access using dma for tegra20 only 2012-07-06 11:48:56 -06:00
board-paz00.c ARM: tegra: remove obsolete gpio entries 2014-04-11 09:28:16 +02:00
board.h ARM: tegra: delete stale header content 2013-09-17 13:44:21 -06:00
common.h Revert "ARM: tegra: add cpu_disable for hotplug" 2013-07-19 10:00:37 -06:00
cpuidle-tegra20.c ARM: tegra: disable LP2 cpuidle state if PCIe is enabled 2013-08-13 12:07:56 -06:00
cpuidle-tegra30.c ARM: tegra: don't pass CPU ID to tegra_{set,clear}_cpu_in_lp2 2013-06-05 11:44:58 -06:00
cpuidle-tegra114.c ARM: tegra: cpuidle: use firmware for power down 2014-02-18 13:46:50 -07:00
cpuidle.c ARM: tegra: enable CPU idle for Tegra124 2013-10-18 16:28:09 -06:00
cpuidle.h ARM: tegra: disable LP2 cpuidle state if PCIe is enabled 2013-08-13 12:07:56 -06:00
flowctrl.c ARM: tegra: add LP1 support code for Tegra124 2013-10-18 16:28:10 -06:00
flowctrl.h ARM: tegra: shut off the CPU rail when the last CPU in suspend 2013-07-19 10:08:07 -06:00
fuse.c ARM: tegra: SoC-specific core code changes 2013-12-26 11:02:25 -08:00
fuse.h ARM: tegra: add Tegra124 SoC support 2013-10-18 16:28:07 -06:00
headsmp.S ARM: tegra: do v7_invalidate_l1 only when CPU is Cortex-A9 2013-07-19 10:08:04 -06:00
hotplug.c ARM: tegra: CPU hotplug support for Tegra124 2013-10-18 16:28:08 -06:00
io.c ARM: tegra: don't include iomap.h from debug-macro.S 2012-11-16 12:22:17 -07:00
iomap.h ARM: tegra: use section-sized static mappings for LPAE too 2013-12-04 12:25:25 -07:00
irammap.h ARM: tegra: move resume vector define to irammap.h 2013-09-17 13:44:22 -06:00
irq.c ARM: tegra114: Reprogram GIC CPU interface to bypass IRQ on CPU PM entry 2013-07-19 10:07:14 -06:00
irq.h ARM: tegra: irq: add wake up handling 2013-04-03 14:31:32 -06:00
Kconfig ARM: use menuconfig for sub-arch menus 2014-06-17 17:09:48 +02:00
Makefile ARM: tegra: remove tegra EMC scaling driver 2014-02-25 10:58:06 -07:00
platsmp.c ARM: tegra: don't timeout if CPU is powergated 2014-02-12 12:10:58 -07:00
pm-tegra20.c ARM: tegra: add LP1 suspend support for Tegra20 2013-08-12 13:30:11 -06:00
pm-tegra30.c ARM: tegra: add LP1 suspend support for Tegra30 2013-08-12 13:30:11 -06:00
pm.c arm, pm, vmpressure: add missing slab.h includes 2014-02-03 13:24:01 -05:00
pm.h ARM: l2c: tegra: convert to common l2c310 early resume functionality 2014-05-30 00:50:12 +01:00
pmc.c ARM: tegra: Support reboot modes 2014-05-07 09:58:03 -06:00
pmc.h ARM: tegra: remove common.c 2013-09-17 13:44:21 -06:00
powergate.c ARM: tegra: Export I/O rail functions 2014-02-25 13:16:32 -07:00
reset-handler.S ARM: l2c: tegra: convert to common l2c310 early resume functionality 2014-05-30 00:50:12 +01:00
reset.c ARM: tegra: set CPU reset handler using firmware 2013-12-13 12:50:31 -07:00
reset.h ARM: tegra: add common LP1 suspend support 2013-08-12 13:29:24 -06:00
sleep-tegra20.S ARM: convert all "mov.* pc, reg" to "bx reg" for ARMv6+ 2014-07-18 12:29:04 +01:00
sleep-tegra30.S ARM: convert all "mov.* pc, reg" to "bx reg" for ARMv6+ 2014-07-18 12:29:04 +01:00
sleep.h ARM: l2c: tegra: convert to common l2c310 early resume functionality 2014-05-30 00:50:12 +01:00
sleep.S ARM: convert all "mov.* pc, reg" to "bx reg" for ARMv6+ 2014-07-18 12:29:04 +01:00
tegra20_speedo.c ARM: tegra: Add speedo-based process identification 2012-11-15 14:34:20 -07:00
tegra30_speedo.c ARM: tegra: Tegra30 speedo-based process identification 2012-11-15 14:36:59 -07:00
tegra114_speedo.c ARM: tegra: add speedo-based process id for Tegra114 2013-03-19 11:52:06 -06:00
tegra.c ARM: l2c: tegra: convert to generic l2c OF initialisation 2014-05-30 00:50:15 +01:00