Get rid of #ifdef __sparc__ in uvm code - as noted by cgd back 1996,

now that we have __HAVE_CPU_VMSPACE_EXEC/cpu_vmspace_exec().
This commit is contained in:
martin 2011-07-30 19:29:12 +00:00
parent 884fa40622
commit 95377927e5
6 changed files with 14 additions and 17 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: cpu.h,v 1.91 2011/01/24 10:05:22 martin Exp $ */
/* $NetBSD: cpu.h,v 1.92 2011/07/30 19:29:12 martin Exp $ */
/*
* Copyright (c) 1992, 1993
@ -213,7 +213,7 @@ void qcopy(const void *, void *, size_t);
void qzero(void *, size_t);
/* trap.c */
void kill_user_windows(struct lwp *);
void cpu_vmspace_exec(struct lwp *, vaddr_t, vaddr_t);
int rwindow_save(struct lwp *);
/* cons.c */

View File

@ -1,4 +1,4 @@
/* $NetBSD: types.h,v 1.60 2011/07/17 23:29:10 dyoung Exp $ */
/* $NetBSD: types.h,v 1.61 2011/07/30 19:29:12 martin Exp $ */
/*
* Copyright (c) 1992, 1993
@ -121,6 +121,7 @@ typedef volatile unsigned char __cpu_simple_lock_t;
#define __HAVE_SYSCALL_INTERN
#define __GENERIC_SOFT_INTERRUPTS_ALL_LEVELS
#define __HAVE_CPU_DATA_FIRST
#define __HAVE_CPU_VMSPACE_EXEC
#ifdef SUN4U
#define __HAVE_DEVICE_REGISTER_POSTCONFIG

View File

@ -1,4 +1,4 @@
/* $NetBSD: trap.c,v 1.187 2011/04/18 00:26:12 rmind Exp $ */
/* $NetBSD: trap.c,v 1.188 2011/07/30 19:29:12 martin Exp $ */
/*
* Copyright (c) 1996
@ -49,7 +49,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.187 2011/04/18 00:26:12 rmind Exp $");
__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.188 2011/07/30 19:29:12 martin Exp $");
#include "opt_ddb.h"
#include "opt_compat_svr4.h"
@ -750,7 +750,7 @@ rwindow_save(struct lwp *l)
* the registers into the new process after the exec.
*/
void
kill_user_windows(struct lwp *l)
cpu_vmspace_exec(struct lwp *l, vaddr_t start, vaddr_t end)
{
struct pcb *pcb = lwp_getpcb(l);

View File

@ -1,4 +1,4 @@
/* $NetBSD: cpu.h,v 1.97 2011/07/20 12:06:00 macallan Exp $ */
/* $NetBSD: cpu.h,v 1.98 2011/07/30 19:29:12 martin Exp $ */
/*
* Copyright (c) 1992, 1993
@ -373,7 +373,7 @@ void switchtoctx_us(int);
void switchtoctx_usiii(int);
void next_tick(long);
/* trap.c */
void kill_user_windows(struct lwp *);
void cpu_vmspace_exec(struct lwp *, vaddr_t, vaddr_t);
int rwindow_save(struct lwp *);
/* cons.c */
int cnrom(void);

View File

@ -1,4 +1,4 @@
/* $NetBSD: trap.c,v 1.167 2011/07/12 07:51:34 mrg Exp $ */
/* $NetBSD: trap.c,v 1.168 2011/07/30 19:29:12 martin Exp $ */
/*
* Copyright (c) 1996-2002 Eduardo Horvath. All rights reserved.
@ -50,7 +50,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.167 2011/07/12 07:51:34 mrg Exp $");
__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.168 2011/07/30 19:29:12 martin Exp $");
#include "opt_ddb.h"
#include "opt_multiprocessor.h"
@ -975,7 +975,7 @@ rwindow_save(struct lwp *l)
* the registers into the new process after the exec.
*/
void
kill_user_windows(struct lwp *l)
cpu_vmspace_exec(struct lwp *l, vaddr_t start, vaddr_t end)
{
struct pcb *pcb = lwp_getpcb(l);

View File

@ -1,4 +1,4 @@
/* $NetBSD: uvm_map.c,v 1.300 2011/07/05 14:03:07 yamt Exp $ */
/* $NetBSD: uvm_map.c,v 1.301 2011/07/30 19:29:12 martin Exp $ */
/*
* Copyright (c) 1997 Charles D. Cranor and Washington University.
@ -66,7 +66,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: uvm_map.c,v 1.300 2011/07/05 14:03:07 yamt Exp $");
__KERNEL_RCSID(0, "$NetBSD: uvm_map.c,v 1.301 2011/07/30 19:29:12 martin Exp $");
#include "opt_ddb.h"
#include "opt_uvmhist.h"
@ -4186,10 +4186,6 @@ uvmspace_exec(struct lwp *l, vaddr_t start, vaddr_t end)
struct vmspace *nvm, *ovm = p->p_vmspace;
struct vm_map *map = &ovm->vm_map;
#ifdef __sparc__
/* XXX cgd 960926: the sparc #ifdef should be a MD hook */
kill_user_windows(l); /* before stack addresses go away */
#endif
#ifdef __HAVE_CPU_VMSPACE_EXEC
cpu_vmspace_exec(l, start, end);
#endif