banan-os/kernel/arch/i386/Syscall.S

19 lines
249 B
ArmAsm
Raw Normal View History

.global sys_fork_trampoline
sys_fork_trampoline:
subl $4, %esp
pushl %ebx
pushl %ebp
call read_ip
testl %eax, %eax
je .done
subl $8, %esp
pushl %eax
pushl %esp
call sys_fork
addl $16, %esp
.done:
popl %ebp
popl %ebx
addl $4, %esp
ret