Fix stack alignment and shadow space for EntryPoint call

This commit is contained in:
2026-06-16 11:39:31 +02:00
parent d1aa3cf481
commit f6f37494cd

View File

@@ -467,9 +467,11 @@ ApEnterLongMode:
/* Save the pointer to PROCESSOR_START_BLOCK */
movq %rdi, %rcx
pushq %rdi
/* Call the EntryPoint routine */
/* Allocate 32 bytes of shadow space */
subq $32, %rsp
/* Fetch the EntryPoint address and call the routine */
movq PROCESSOR_START_BLOCK_EntryPoint(%rdi), %rax
call *%rax