Link: https://lore.kernel.org/r/20260217200002.683975158@linuxfoundation.org Tested-by: Florian Fainelli <florian.fainelli@broadcom.com> Tested-by: Takeshi Ogasawara <takeshi.ogasawara@futuring-girl.com> Tested-by: Peter Schneider <pschneider1968@googlemail.com> Tested-by: Jon Hunter <jonathanh@nvidia.com> Tested-by: Salvatore Bonaccorso <carnil@debian.org> Tested-by: Brett A C Sheffield <bacs@librecast.net> Tested-by: Mark Brown <broonie@kernel.org> Tested-by: Luna Jernberg <droidbittin@gmail.com> Tested-by: Ronald Warsow <rwarsow@gmx.de> Tested-by: Justin M. Forbes <jforbes@fedoraproject.org> Tested-by: Ron Economos <re@w6rz.net> Tested-by: Miguel Ojeda <ojeda@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
34 lines
800 B
ArmAsm
34 lines
800 B
ArmAsm
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
/*
|
|
* Copyright (c) 2003 ARM Limited
|
|
* Copyright (c) u-boot contributors
|
|
* Copyright (c) 2012 Pavel Machek <pavel@denx.de>
|
|
*/
|
|
#include <linux/linkage.h>
|
|
#include <linux/init.h>
|
|
#include <asm/page.h>
|
|
#include <asm/assembler.h>
|
|
|
|
.arch armv7-a
|
|
.arm
|
|
|
|
ENTRY(secondary_trampoline)
|
|
/* CPU1 will always fetch from 0x0 when it is brought out of reset.
|
|
* Thus, we can just subtract the PAGE_OFFSET to get the physical
|
|
* address of &cpu1start_addr. This would not work for platforms
|
|
* where the physical memory does not start at 0x0.
|
|
*/
|
|
ARM_BE8(setend be)
|
|
adr r0, 1f
|
|
ldmia r0, {r1, r2}
|
|
sub r2, r2, #PAGE_OFFSET
|
|
ldr r3, [r2]
|
|
ldr r4, [r3]
|
|
ARM_BE8(rev r4, r4)
|
|
bx r4
|
|
|
|
.align
|
|
1: .long .
|
|
.long socfpga_cpu1start_addr
|
|
ENTRY(secondary_trampoline_end)
|