zephyr/arch
Andy Ross b651aa9f7d arch/x86/zefi: Fix entry-nop hack for EFI entry
commit 5e9c583c24 ("arch/x86_64: Terrible, awful hackery to
bootstrap entry") introduced a terrible trick which begins execution
at the bottom of .locore with a jump, which then gets replaced with
NOP instructions for the benefit of 16 bit real mode startup of the
other CPUs later on.

But I forgot that EFI enters in 64 bit code natively, and so never
hits that path.  And moving it to the 64 bit setup code doesn't work,
because at that point when we are NOT loaded from EFI, we already have
the Zephyr page tables in place that disallow writes to .locore.

So do it in the EFI loader, which while sort of a weird place, has the
benefit of being in C instead of assembly.

Really all this code needs to go away.  A proper x86 entry
architecture would enter somewhere in the main blob, and .locore
should be a tiny stub we copy in at runtime.

Fixes #36107

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2021-06-14 08:22:34 -04:00
..
arc cmake: Support coverage flags on all archs 2021-06-10 18:01:36 -04:00
arm cmake: Support coverage flags on all archs 2021-06-10 18:01:36 -04:00
arm64 cmake: Support coverage flags on all archs 2021-06-10 18:01:36 -04:00
common cmake: Support coverage flags on all archs 2021-06-10 18:01:36 -04:00
nios2 arch: nios2: Fix 10.4 violations 2021-04-10 09:59:37 -04:00
posix cmake: Support coverage flags on all archs 2021-06-10 18:01:36 -04:00
riscv RISC-V: Round up pre-populated stack frame to arch stack alignment 2021-06-11 16:13:01 +02:00
sparc SPARC: add the Flush windows software trap 2021-05-28 06:32:36 -05:00
x86 arch/x86/zefi: Fix entry-nop hack for EFI entry 2021-06-14 08:22:34 -04:00
xtensa xtensa: fix booting secondary cores on the dummy thread 2021-05-03 17:13:01 -04:00
CMakeLists.txt cmake: fix include directories to work with out-of-tree arch 2020-08-05 08:06:07 -04:00
Kconfig kernel: mmu: z_backing_store* to k_mem_paging_backing_store* 2021-05-28 11:33:22 -04:00