mirror of
https://github.com/limine-bootloader/limine
synced 2024-12-05 22:52:36 +03:00
489450d602
Fixes a problem that sometimes occured due to a specific relocation being used for the misaligned variable.
26 lines
341 B
Plaintext
26 lines
341 B
Plaintext
.section .data
|
|
|
|
.align 3
|
|
stack_at_first_entry:
|
|
.quad 0
|
|
|
|
.section .text
|
|
|
|
.global menu
|
|
.extern _menu
|
|
|
|
menu:
|
|
adrp x8, stack_at_first_entry
|
|
ldr x9, [x8, :lo12:stack_at_first_entry]
|
|
cbz x9, 1f
|
|
mov sp, x9
|
|
b 2f
|
|
1:
|
|
mov x9, sp
|
|
str x9, [x8, :lo12:stack_at_first_entry]
|
|
2:
|
|
mov x30, xzr
|
|
mov x29, xzr
|
|
|
|
b _menu
|