Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kqueue1 syscall missing in i386 emulation?



On Sat, Nov 05, 2011 at 08:43:43AM -0400, Andreas Wrede wrote:
> I am trying to build packages under pkg_comp in a current/i386 emulated 
> environment.
> 
> in the i386 chroot, ftp will fail:
> 
>   6175      1 ktrace   EMUL  "netbsd32
> [snip]
>   6175      1 ftp      RET   netbsd32_read 0
>   6175      1 ftp      CALL  netbsd32_dup(3)
>   6175      1 ftp      RET   netbsd32_dup 4
>   6175      1 ftp      CALL  netbsd32_close(3)
>   6175      1 ftp      RET   netbsd32_close 0
>   6175      1 ftp      CALL  netbsd32___fstat50(4,0xffffc26c)
>   6175      1 ftp      RET   netbsd32___fstat50 0
>   6175      1 ftp      CALL  # filler
>   6175      1 ftp      RET   # filler -1 errno 78 Function not implemented
>   6175      1 ftp      PSIG  SIGSYS SIG_DFL: code=SI_NOINFO
>   6175      1 ftp      NAMI  "ftp.core"

Can you try the following patch ?

You do need to regenerate netbsd32 syscalls files:
    cd /usr/src/sys/compat/netbsd32 && make

Thanks.

-- 
Nicolas Joly

Projects and Developments in Bioinformatics
Institut Pasteur, Paris.
Index: sys/compat/netbsd32/netbsd32_netbsd.c
===================================================================
RCS file: /cvsroot/src/sys/compat/netbsd32/netbsd32_netbsd.c,v
retrieving revision 1.173
diff -u -p -r1.173 netbsd32_netbsd.c
--- sys/compat/netbsd32/netbsd32_netbsd.c       31 Aug 2011 16:50:32 -0000      
1.173
+++ sys/compat/netbsd32/netbsd32_netbsd.c       20 Oct 2011 13:42:35 -0000
@@ -2605,6 +2605,19 @@ netbsd32_dup3(struct lwp *l, const struc
        return sys_dup3(l, &ua, retval);
 }
 
+int
+netbsd32_kqueue1(struct lwp *l, const struct netbsd32_kqueue1_args *uap,
+                register_t *retval)
+{
+       /* {
+               syscallarg(int) flags;
+       } */
+       struct sys_kqueue1_args ua;
+
+       NETBSD32TO64_UAP(flags);
+       return sys_kqueue1(l, &ua, retval);
+}
+
 /*
  * MI indirect system call support.
  * Only used if the MD netbsd32_syscall.c doesn't intercept the calls.
Index: sys/compat/netbsd32/syscalls.master
===================================================================
RCS file: /cvsroot/src/sys/compat/netbsd32/syscalls.master,v
retrieving revision 1.87
diff -u -p -r1.87 syscalls.master
--- sys/compat/netbsd32/syscalls.master 31 Aug 2011 16:50:32 -0000      1.87
+++ sys/compat/netbsd32/syscalls.master 20 Oct 2011 13:42:35 -0000
@@ -973,3 +973,4 @@
                            netbsd32_voidp pref); }
 453    STD             { int|netbsd32||pipe2(netbsd32_intp fildes, int flags); 
}
 454    STD             { int|netbsd32||dup3(int from, int to, int flags); }
+455    STD             { int|netbsd32||kqueue1(int flags); }


Home | Main Index | Thread Index | Old Index