platform_bionic/libc/arch-sh/syscalls/eventfd.S
David 'Digit' Turner defd162212 libc: add <sys/eventfd.h> and corresponding implementations.
Change-Id: Ide040884c456190226e580513099fdb8377e015b
2010-09-28 09:20:37 +02:00

32 lines
545 B
ArmAsm

/* autogenerated by gensyscalls.py */
#include <sys/linux-syscalls.h>
.text
.type eventfd, @function
.globl eventfd
.align 4
eventfd:
/* invoke trap */
mov.l 0f, r3 /* trap num */
trapa #(2 + 0x10)
/* check return value */
cmp/pz r0
bt __NR_eventfd2_end
/* keep error number */
sts.l pr, @-r15
mov.l 1f, r1
jsr @r1
mov r0, r4
lds.l @r15+, pr
__NR_eventfd2_end:
rts
nop
.align 2
0: .long __NR_eventfd2
1: .long __set_syscall_errno