diff options
Diffstat (limited to 'sys/compat/linux/common')
| -rw-r--r-- | sys/compat/linux/common/linux_misc.c | 19 | ||||
| -rw-r--r-- | sys/compat/linux/common/linux_sysctl.c | 7 |
2 files changed, 6 insertions, 20 deletions
diff --git a/sys/compat/linux/common/linux_misc.c b/sys/compat/linux/common/linux_misc.c index 7712e6697fa..3c2b96b0341 100644 --- a/sys/compat/linux/common/linux_misc.c +++ b/sys/compat/linux/common/linux_misc.c @@ -1,4 +1,4 @@ -/* $NetBSD: linux_misc.c,v 1.201 2008/06/24 11:18:15 ad Exp $ */ +/* $NetBSD: linux_misc.c,v 1.202 2008/11/12 12:36:10 ad Exp $ */ /*- * Copyright (c) 1995, 1998, 1999, 2008 The NetBSD Foundation, Inc. @@ -57,11 +57,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: linux_misc.c,v 1.201 2008/06/24 11:18:15 ad Exp $"); - -#if defined(_KERNEL_OPT) -#include "opt_ptrace.h" -#endif +__KERNEL_RCSID(0, "$NetBSD: linux_misc.c,v 1.202 2008/11/12 12:36:10 ad Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -1040,13 +1036,9 @@ linux_sys_ptrace(struct lwp *l, const struct linux_sys_ptrace_args *uap, registe syscallarg(T) addr; syscallarg(T) data; } */ -#if defined(PTRACE) || defined(_LKM) const int *ptr; int request; int error; -#ifdef _LKM -#define sys_ptrace (*sysent[SYS_ptrace].sy_call) -#endif ptr = linux_ptrace_request_map; request = SCARG(uap, request); @@ -1062,13 +1054,13 @@ linux_sys_ptrace(struct lwp *l, const struct linux_sys_ptrace_args *uap, registe /* * Linux ptrace(PTRACE_CONT, pid, 0, 0) means actually * to continue where the process left off previously. - * The same thing is achieved by addr == (void *) 1 + * The same thing is achieved by addr == (void *) 1 * on NetBSD, so rewrite 'addr' appropriately. */ if (request == LINUX_PTRACE_CONT && SCARG(uap, addr)==0) SCARG(&pta, addr) = (void *) 1; - error = sys_ptrace(l, &pta, retval); + error = sysent[SYS_ptrace].sy_call(l, &pta, retval); if (error) return error; switch (request) { @@ -1088,9 +1080,6 @@ linux_sys_ptrace(struct lwp *l, const struct linux_sys_ptrace_args *uap, registe ptr++; return LINUX_SYS_PTRACE_ARCH(l, uap, retval); -#else - return ENOSYS; -#endif /* PTRACE || _LKM */ } int diff --git a/sys/compat/linux/common/linux_sysctl.c b/sys/compat/linux/common/linux_sysctl.c index 4c990917642..23839c1775d 100644 --- a/sys/compat/linux/common/linux_sysctl.c +++ b/sys/compat/linux/common/linux_sysctl.c @@ -1,4 +1,4 @@ -/* $NetBSD: linux_sysctl.c,v 1.36 2008/06/18 12:24:18 tsutsui Exp $ */ +/* $NetBSD: linux_sysctl.c,v 1.37 2008/11/12 12:36:10 ad Exp $ */ /*- * Copyright (c) 2003 The NetBSD Foundation, Inc. @@ -34,7 +34,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: linux_sysctl.c,v 1.36 2008/06/18 12:24:18 tsutsui Exp $"); +__KERNEL_RCSID(0, "$NetBSD: linux_sysctl.c,v 1.37 2008/11/12 12:36:10 ad Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -65,9 +65,6 @@ char linux_release[128] = "2.0.38"; char linux_version[128] = "#0 Sun Nov 11 11:11:11 MET 2000"; #endif -#ifndef _LKM -static -#endif struct sysctlnode linux_sysctl_root = { .sysctl_flags = SYSCTL_VERSION| CTLFLAG_ROOT|CTLTYPE_NODE|CTLFLAG_READWRITE, |
