I'm reading the start.S assembly code for the Zircon Kernel (Fuchsia OS):
https://fuchsia.googlesource.com/fuchsia/+/master/zircon/kernel/arch/arm64/start.S
There's this line:
.text
FUNCTION(_start)
I think this is the first thing ever that get executed on the kernel. However, for it to be true, _start
should be global. I couldn't determine if it is or not.
There's this other line:
// This symbol is used by image.S
.global IMAGE_ELF_ENTRY
IMAGE_ELF_ENTRY = _start
that suggests something like it.
What is FUNCTION
on FUNCTION(_start)
? I tried searching for "assembly FUNCTION macro" but found nothing related to this.
It looks like this is the first code run, but I could not determine where it branches to real kernel code (C++ code) so I'm in doubt.