]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Ensure the boot CPU is CPU 0 on arm64
authorandrew <andrew@FreeBSD.org>
Mon, 7 Dec 2020 17:54:49 +0000 (17:54 +0000)
committerandrew <andrew@FreeBSD.org>
Mon, 7 Dec 2020 17:54:49 +0000 (17:54 +0000)
commitddb51dedb559301e730f268c3ad2e8c7a1e40c7e
tree824eec25808b157efa818ef783605c4b6bad9eb5
parent8e94ad1f1f8d82348c4fc7bef4de83a05151fb5d
Ensure the boot CPU is CPU 0 on arm64

We assume the boot CPU is always CPU 0 on arm64. To allow for this reserve
cpuid 0 for the boot CPU in the ACPI and FDT cases but otherwise start the
CPU as normal. We then check for the boot CPU in start_cpu and return as if
it was started.

While here extract the FDT CPU init code into a new function to simplify
cpu_mp_start and return FALSE from start_cpu when the CPU fails to start.

Reviewed by: mmel
Sponsored by: Innovate UK
Differential Revision: https://reviews.freebsd.org/D27497
sys/arm64/arm64/mp_machdep.c