This commit was manufactured by cvs2svn to create tag
[linux-2.6.git] / arch / um / kernel / skas / syscall_user.c
index b7fd594..34fd5f9 100644 (file)
 #include "sysdep/ptrace.h"
 #include "sysdep/sigcontext.h"
 
+/* XXX Bogus */
+#define ERESTARTSYS    512
+#define ERESTARTNOINTR 513
+#define ERESTARTNOHAND 514
 
 void handle_syscall(union uml_pt_regs *regs)
 {
@@ -18,12 +22,15 @@ void handle_syscall(union uml_pt_regs *regs)
 
        index = record_syscall_start(UPT_SYSCALL_NR(regs));
 
-       syscall_trace(regs, 0);
+       syscall_trace(regs, 1);
        result = execute_syscall(regs);
 
        REGS_SET_SYSCALL_RETURN(regs->skas.regs, result);
+       if((result == -ERESTARTNOHAND) || (result == -ERESTARTSYS) || 
+          (result == -ERESTARTNOINTR))
+               do_signal(result);
 
-       syscall_trace(regs, 1);
+       syscall_trace(regs, 0);
        record_syscall_end(index, result);
 }