case TARGET_NR_fork:
ret = get_errno(do_fork(cpu_env, SIGCHLD, 0));
break;
+#ifdef TARGET_NR_waitpid
case TARGET_NR_waitpid:
{
int status;
tput32(arg2, status);
}
break;
+#endif
case TARGET_NR_creat:
p = lock_user_string(arg1);
ret = get_errno(creat(p, arg2));
unlock_user(p3, arg3, 0);
break;
}
+#ifdef TARGET_NR_umount
case TARGET_NR_umount:
p = lock_user_string(arg1);
ret = get_errno(umount(p));
unlock_user(p, arg1, 0);
break;
+#endif
case TARGET_NR_stime:
{
time_t host_time;
case TARGET_NR_pause:
ret = get_errno(pause());
break;
+#ifdef TARGET_NR_utime
case TARGET_NR_utime:
{
struct utimbuf tbuf, *host_tbuf;
unlock_user(p, arg1, 0);
}
break;
+#endif
case TARGET_NR_utimes:
{
struct timeval *tvp, tv[2];
case TARGET_NR_prof:
goto unimplemented;
#endif
+#ifdef TARGET_NR_signal
case TARGET_NR_signal:
goto unimplemented;
-
+#endif
case TARGET_NR_acct:
p = lock_user_string(arg1);
ret = get_errno(acct(path(p)));
case TARGET_NR_setsid:
ret = get_errno(setsid());
break;
+#ifdef TARGET_NR_sigaction
case TARGET_NR_sigaction:
{
#if !defined(TARGET_MIPS)
#endif
}
break;
+#endif
case TARGET_NR_rt_sigaction:
{
struct target_sigaction *act;
ret = target_set;
}
break;
+#ifdef TARGET_NR_sigprocmask
case TARGET_NR_sigprocmask:
{
int how = arg1;
}
}
break;
+#endif
case TARGET_NR_rt_sigprocmask:
{
int how = arg1;
}
}
break;
+#ifdef TARGET_NR_sigpending
case TARGET_NR_sigpending:
{
sigset_t set;
}
}
break;
+#endif
case TARGET_NR_rt_sigpending:
{
sigset_t set;
}
}
break;
+#ifdef TARGET_NR_sigsuspend
case TARGET_NR_sigsuspend:
{
sigset_t set;
ret = get_errno(sigsuspend(&set));
}
break;
+#endif
case TARGET_NR_rt_sigsuspend:
{
sigset_t set;
ret = get_errno(sys_rt_sigqueueinfo(arg1, arg2, &uinfo));
}
break;
+#ifdef TARGET_NR_sigreturn
case TARGET_NR_sigreturn:
/* NOTE: ret is eax, so not transcoding must be done */
ret = do_sigreturn(cpu_env);
break;
+#endif
case TARGET_NR_rt_sigreturn:
/* NOTE: ret is eax, so not transcoding must be done */
ret = do_rt_sigreturn(cpu_env);
unlock_user(p, arg1, 0);
}
break;
+#ifdef TARGET_NR_uselib
case TARGET_NR_uselib:
goto unimplemented;
+#endif
+#ifdef TARGET_NR_swapon
case TARGET_NR_swapon:
p = lock_user_string(arg1);
ret = get_errno(swapon(p, arg2));
unlock_user(p, arg1, 0);
break;
+#endif
case TARGET_NR_reboot:
goto unimplemented;
+#ifdef TARGET_NR_readdir
case TARGET_NR_readdir:
goto unimplemented;
+#endif
+#ifdef TARGET_NR_mmap
case TARGET_NR_mmap:
#if defined(TARGET_I386) || defined(TARGET_ARM) || defined(TARGET_M68K)
{
arg6));
#endif
break;
+#endif
#ifdef TARGET_NR_mmap2
case TARGET_NR_mmap2:
#if defined(TARGET_SPARC) || defined(TARGET_MIPS)
case TARGET_NR_mprotect:
ret = get_errno(target_mprotect(arg1, arg2, arg3));
break;
+#ifdef TARGET_NR_mremap
case TARGET_NR_mremap:
ret = get_errno(target_mremap(arg1, arg2, arg3, arg4, arg5));
break;
+#endif
/* ??? msync/mlock/munlock are broken for softmmu. */
+#ifdef TARGET_NR_msync
case TARGET_NR_msync:
ret = get_errno(msync(g2h(arg1), arg2, arg3));
break;
+#endif
+#ifdef TARGET_NR_mlock
case TARGET_NR_mlock:
ret = get_errno(mlock(g2h(arg1), arg2));
break;
+#endif
+#ifdef TARGET_NR_munlock
case TARGET_NR_munlock:
ret = get_errno(munlock(g2h(arg1), arg2));
break;
+#endif
+#ifdef TARGET_NR_mlockall
case TARGET_NR_mlockall:
ret = get_errno(mlockall(arg1));
break;
+#endif
+#ifdef TARGET_NR_munlockall
case TARGET_NR_munlockall:
ret = get_errno(munlockall());
break;
+#endif
case TARGET_NR_truncate:
p = lock_user_string(arg1);
ret = get_errno(truncate(p, arg2));
case TARGET_NR_ioperm:
goto unimplemented;
#endif
+#ifdef TARGET_NR_socketcall
case TARGET_NR_socketcall:
ret = do_socketcall(arg1, arg2);
break;
-
+#endif
#ifdef TARGET_NR_accept
case TARGET_NR_accept:
ret = do_accept(arg1, arg2, arg3);
}
}
break;
+#ifdef TARGET_NR_swapoff
case TARGET_NR_swapoff:
p = lock_user_string(arg1);
ret = get_errno(swapoff(p));
unlock_user(p, arg1, 0);
break;
+#endif
case TARGET_NR_sysinfo:
{
struct target_sysinfo *target_value;
}
}
break;
+#ifdef TARGET_NR_ipc
case TARGET_NR_ipc:
ret = do_ipc(arg1, arg2, arg3, arg4, arg5, arg6);
break;
+#endif
case TARGET_NR_fsync:
ret = get_errno(fsync(arg1));
break;
#endif
case TARGET_NR_adjtimex:
goto unimplemented;
+#ifdef TARGET_NR_create_module
case TARGET_NR_create_module:
+#endif
case TARGET_NR_init_module:
case TARGET_NR_delete_module:
+#ifdef TARGET_NR_get_kernel_syms
case TARGET_NR_get_kernel_syms:
+#endif
goto unimplemented;
case TARGET_NR_quotactl:
goto unimplemented;
break;
case TARGET_NR_bdflush:
goto unimplemented;
+#ifdef TARGET_NR_sysfs
case TARGET_NR_sysfs:
goto unimplemented;
+#endif
case TARGET_NR_personality:
ret = get_errno(personality(arg1));
break;
+#ifdef TARGET_NR_afs_syscall
case TARGET_NR_afs_syscall:
goto unimplemented;
+#endif
case TARGET_NR__llseek:
{
#if defined (__x86_64__)
}
break;
#endif /* TARGET_NR_getdents64 */
+#ifdef TARGET_NR__newselect
case TARGET_NR__newselect:
ret = do_select(arg1, arg2, arg3, arg4, arg5);
break;
+#endif
+#ifdef TARGET_NR_poll
case TARGET_NR_poll:
{
struct target_pollfd *target_pfd;
unlock_user(target_pfd, arg1, ret);
}
break;
+#endif
case TARGET_NR_flock:
/* NOTE: the flock constant seems to be the same for every
Linux platform */
}
}
break;
+#ifdef TARGET_NR_query_module
case TARGET_NR_query_module:
goto unimplemented;
+#endif
+#ifdef TARGET_NR_nfsservctl
case TARGET_NR_nfsservctl:
goto unimplemented;
+#endif
case TARGET_NR_prctl:
switch (arg1)
{
case TARGET_NR_gettid:
ret = get_errno(gettid());
break;
+#ifdef TARGET_NR_readahead
case TARGET_NR_readahead:
goto unimplemented;
+#endif
#ifdef TARGET_NR_setxattr
case TARGET_NR_setxattr:
case TARGET_NR_lsetxattr: