int semop(int id, struct sembuf *buf, size_t n)
{
-#ifdef __NR_semop
- return syscall3(__NR_semop, id, (long)buf, n);
+#ifndef SYS_ipc
+ return syscall(SYS_semop, id, buf, n);
#else
- return syscall5(__NR_ipc, IPCOP_semop, id, n, 0, (long)buf);
+ return syscall(SYS_ipc, IPCOP_semop, id, n, 0, buf);
#endif
}