diff options
-rw-r--r-- | sys/alpha/linux/syscalls.master | 4 | ||||
-rw-r--r-- | sys/amd64/linux32/syscalls.master | 4 | ||||
-rw-r--r-- | sys/compat/linux/linux_misc.c | 9 | ||||
-rw-r--r-- | sys/compat/linux/linux_sysproto.h | 36 | ||||
-rw-r--r-- | sys/i386/linux/syscalls.master | 4 |
5 files changed, 57 insertions, 0 deletions
diff --git a/sys/alpha/linux/syscalls.master b/sys/alpha/linux/syscalls.master index 250ede35efb7..d9dff459f230 100644 --- a/sys/alpha/linux/syscalls.master +++ b/sys/alpha/linux/syscalls.master @@ -31,9 +31,13 @@ #include <sys/param.h> #include <sys/sysent.h> #include <sys/sysproto.h> +#include <compat/linux/linux_sysproto.h> #include <alpha/linux/linux.h> #include <alpha/linux/linux_proto.h> +; Isn't pretty, but there seems to be no other way to trap nosys +#define nosys linux_nosys + ; #ifdef's, etc. may be included, and are copied to the output files. 0 UNIMPL diff --git a/sys/amd64/linux32/syscalls.master b/sys/amd64/linux32/syscalls.master index 07ce1d1bf054..78b361e2ba48 100644 --- a/sys/amd64/linux32/syscalls.master +++ b/sys/amd64/linux32/syscalls.master @@ -25,9 +25,13 @@ #include <sys/param.h> #include <sys/sysent.h> #include <sys/sysproto.h> +#include <compat/linux/linux_sysproto.h> #include <amd64/linux32/linux.h> #include <amd64/linux32/linux32_proto.h> +; Isn't pretty, but there seems to be no other way to trap nosys +#define nosys linux_nosys + ; #ifdef's, etc. may be included, and are copied to the output files. 0 UNIMPL setup diff --git a/sys/compat/linux/linux_misc.c b/sys/compat/linux/linux_misc.c index 40762cbab995..7bbeaff0c999 100644 --- a/sys/compat/linux/linux_misc.c +++ b/sys/compat/linux/linux_misc.c @@ -74,6 +74,8 @@ __FBSDID("$FreeBSD$"); #include "opt_compat.h" +#include <compat/linux/linux_sysproto.h> + #ifdef COMPAT_LINUX32 #include <machine/../linux32/linux.h> #include <machine/../linux32/linux32_proto.h> @@ -1392,3 +1394,10 @@ linux_getsid(struct thread *td, struct linux_getsid_args *args) bsd.pid = args->pid; return getsid(td, &bsd); } + +int +linux_nosys(struct thread *td, struct nosys_args *ignore) +{ + + return (ENOSYS); +} diff --git a/sys/compat/linux/linux_sysproto.h b/sys/compat/linux/linux_sysproto.h new file mode 100644 index 000000000000..69f1577dc457 --- /dev/null +++ b/sys/compat/linux/linux_sysproto.h @@ -0,0 +1,36 @@ +/*- + * Copyright (c) 2005 Travis Poppe + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer + * in this position and unchanged. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * $FreeBSD$ + */ + +#ifndef LINUX_SYSPROTO +#define LINUX_SYSPROTO + +int linux_nosys(struct thread *, struct nosys_args *); + +#endif diff --git a/sys/i386/linux/syscalls.master b/sys/i386/linux/syscalls.master index ae9e52af6835..4d05eaa77a2e 100644 --- a/sys/i386/linux/syscalls.master +++ b/sys/i386/linux/syscalls.master @@ -25,9 +25,13 @@ #include <sys/param.h> #include <sys/sysent.h> #include <sys/sysproto.h> +#include <compat/linux/linux_sysproto.h> #include <i386/linux/linux.h> #include <i386/linux/linux_proto.h> +; Isn't pretty, but there seems to be no other way to trap nosys +#define nosys linux_nosys + ; #ifdef's, etc. may be included, and are copied to the output files. 0 UNIMPL setup |