mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-23 10:15:57 +01:00
This allows add.c to run unmodified on both! For that to work, use int main on baremetal, and pass the return value to the final exit.
12 lines
166 B
ArmAsm
12 lines
166 B
ArmAsm
.global mystart
|
|
mystart:
|
|
/* = NEON setup */
|
|
mov x1, #(0x3 << 20)
|
|
msr cpacr_el1, x1
|
|
isb
|
|
|
|
ldr x0, =stack_top
|
|
mov sp, x0
|
|
bl main
|
|
bl exit
|