pass the fork flags down to the emulation fork hook, so that emulation

code can use the information for setup
This commit is contained in:
jdolecek 2004-08-08 08:42:03 +00:00
parent bff77eedb1
commit 74436be135
5 changed files with 18 additions and 15 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: darwin_exec.c,v 1.37 2004/07/21 21:45:34 manu Exp $ */
/* $NetBSD: darwin_exec.c,v 1.38 2004/08/08 08:42:03 jdolecek Exp $ */
/*-
* Copyright (c) 2002 The NetBSD Foundation, Inc.
@ -38,7 +38,7 @@
#include "opt_compat_darwin.h" /* For COMPAT_DARWIN in mach_port.h */
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: darwin_exec.c,v 1.37 2004/07/21 21:45:34 manu Exp $");
__KERNEL_RCSID(0, "$NetBSD: darwin_exec.c,v 1.38 2004/08/08 08:42:03 jdolecek Exp $");
#include "opt_syscall_debug.h"
@ -78,7 +78,7 @@ __KERNEL_RCSID(0, "$NetBSD: darwin_exec.c,v 1.37 2004/07/21 21:45:34 manu Exp $"
extern const struct cdevsw wsdisplay_cdevsw;
static void darwin_e_proc_exec(struct proc *, struct exec_package *);
static void darwin_e_proc_fork(struct proc *, struct proc *);
static void darwin_e_proc_fork(struct proc *, struct proc *, int);
static void darwin_e_proc_exit(struct proc *);
static void darwin_e_proc_init(struct proc *, struct vmspace *);
@ -247,9 +247,10 @@ darwin_e_proc_exec(p, epp)
}
static void
darwin_e_proc_fork(p, parent)
darwin_e_proc_fork(p, parent, forkflags)
struct proc *p;
struct proc *parent;
int forkflags;
{
struct darwin_emuldata *ded1;
struct darwin_emuldata *ded2;

View File

@ -1,4 +1,4 @@
/* $NetBSD: irix_exec.c,v 1.37 2003/12/20 19:01:30 fvdl Exp $ */
/* $NetBSD: irix_exec.c,v 1.38 2004/08/08 08:42:03 jdolecek Exp $ */
/*-
* Copyright (c) 2001-2002 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: irix_exec.c,v 1.37 2003/12/20 19:01:30 fvdl Exp $");
__KERNEL_RCSID(0, "$NetBSD: irix_exec.c,v 1.38 2004/08/08 08:42:03 jdolecek Exp $");
#ifdef _KERNEL_OPT
#include "opt_syscall_debug.h"
@ -66,7 +66,7 @@ __KERNEL_RCSID(0, "$NetBSD: irix_exec.c,v 1.37 2003/12/20 19:01:30 fvdl Exp $");
extern const int native_to_svr4_signo[];
static void irix_e_proc_exec __P((struct proc *, struct exec_package *));
static void irix_e_proc_fork __P((struct proc *, struct proc *));
static void irix_e_proc_fork __P((struct proc *, struct proc *, int));
static void irix_e_proc_exit __P((struct proc *));
static void irix_e_proc_init __P((struct proc *, struct vmspace *));
@ -270,8 +270,9 @@ irix_e_proc_exit(p)
* fork() hook used to allocate per process structures
*/
static void
irix_e_proc_fork(p, parent)
irix_e_proc_fork(p, parent, forkflags)
struct proc *p, *parent;
int forkflags;
{
struct irix_emuldata *ied1;
struct irix_emuldata *ied2;

View File

@ -1,4 +1,4 @@
/* $NetBSD: mach_exec.c,v 1.53 2004/03/26 17:34:18 drochner Exp $ */
/* $NetBSD: mach_exec.c,v 1.54 2004/08/08 08:42:03 jdolecek Exp $ */
/*-
* Copyright (c) 2001-2003 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: mach_exec.c,v 1.53 2004/03/26 17:34:18 drochner Exp $");
__KERNEL_RCSID(0, "$NetBSD: mach_exec.c,v 1.54 2004/08/08 08:42:03 jdolecek Exp $");
#include "opt_syscall_debug.h"
@ -206,9 +206,10 @@ mach_e_proc_exec(p, epp)
}
void
mach_e_proc_fork(p, parent)
mach_e_proc_fork(p, parent, forkflags)
struct proc *p;
struct proc *parent;
int forkflags;
{
mach_e_proc_fork1(p, parent, 1);
return;

View File

@ -1,4 +1,4 @@
/* $NetBSD: mach_exec.h,v 1.26 2003/12/24 23:22:22 manu Exp $ */
/* $NetBSD: mach_exec.h,v 1.27 2004/08/08 08:42:03 jdolecek Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@ -74,7 +74,7 @@ int exec_mach_probe(char **);
void mach_e_proc_init(struct proc *, struct vmspace *);
void mach_e_proc_exit(struct proc *);
void mach_e_proc_exec(struct proc *, struct exec_package *);
void mach_e_proc_fork(struct proc *, struct proc *);
void mach_e_proc_fork(struct proc *, struct proc *, int);
void mach_e_proc_fork1(struct proc *, struct proc *, int);
void mach_e_lwp_fork(struct lwp *, struct lwp *);
void mach_e_lwp_exit(struct lwp *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: proc.h,v 1.192 2004/04/17 15:17:32 christos Exp $ */
/* $NetBSD: proc.h,v 1.193 2004/08/08 08:42:03 jdolecek Exp $ */
/*-
* Copyright (c) 1986, 1989, 1991, 1993
@ -115,7 +115,7 @@ struct emul {
/* Per-process hooks */
void (*e_proc_exec) __P((struct proc *,
struct exec_package *));
void (*e_proc_fork) __P((struct proc *, struct proc *));
void (*e_proc_fork) __P((struct proc *, struct proc *, int));
void (*e_proc_exit) __P((struct proc *));
void (*e_lwp_fork) __P((struct lwp *, struct lwp *));
void (*e_lwp_exit) __P((struct lwp *));