Remove safepri and use IPL_SAFEPRI instead. This may be defined in a MD
header file (if not, a value of 0 is assmued).
This commit is contained in:
parent
c476e7cf03
commit
f96ef7b3c5
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.237 2011/12/15 14:25:12 phx Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.238 2012/07/27 05:36:09 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -48,7 +48,7 @@
|
||||
#include "opt_m68k_arch.h"
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.237 2011/12/15 14:25:12 phx Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.238 2012/07/27 05:36:09 matt Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
@ -138,11 +138,6 @@ int machineid;
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem = MAXMEM; /* max supported memory, changes to actual */
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
extern int freebufspace;
|
||||
extern u_int lowram;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: intr.c,v 1.32 2010/12/20 00:25:27 matt Exp $ */
|
||||
/* $NetBSD: intr.c,v 1.33 2012/07/27 05:36:09 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994-1998 Mark Brinicombe.
|
||||
@ -36,7 +36,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.32 2010/12/20 00:25:27 matt Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.33 2012/07/27 05:36:09 matt Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
@ -50,7 +50,6 @@ __KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.32 2010/12/20 00:25:27 matt Exp $");
|
||||
#include <arm/arm32/machdep.h>
|
||||
|
||||
u_int spl_masks[NIPL];
|
||||
int safepri = IPL_NONE;
|
||||
|
||||
extern u_int irqmasks[];
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: psl.h,v 1.18 2009/01/29 20:54:52 nonaka Exp $ */
|
||||
/* $NetBSD: psl.h,v 1.19 2012/07/27 05:36:09 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1995 Mark Brinicombe.
|
||||
@ -62,6 +62,8 @@
|
||||
#define splsched() raisespl(IPL_SCHED)
|
||||
#define splhigh() raisespl(IPL_HIGH)
|
||||
|
||||
#define IPL_SAFEPRI IPL_NONE /* for kern_sleepq.c */
|
||||
|
||||
#ifdef _KERNEL
|
||||
#ifndef _LOCORE
|
||||
int raisespl (int);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.173 2011/12/12 19:03:08 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.174 2012/07/27 05:36:10 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -39,7 +39,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.173 2011/12/12 19:03:08 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.174 2012/07/27 05:36:10 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_compat_netbsd.h"
|
||||
@ -113,11 +113,6 @@ void * msgbufaddr;
|
||||
vaddr_t msgbufpa;
|
||||
|
||||
int physmem = MAXMEM; /* max supported memory, changes to actual */
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
extern int freebufspace;
|
||||
extern u_int lowram;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.62 2012/02/12 16:34:07 matt Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.63 2012/07/27 05:36:10 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -39,7 +39,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.62 2012/02/12 16:34:07 matt Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.63 2012/07/27 05:36:10 matt Exp $");
|
||||
|
||||
#include "opt_bufcache.h"
|
||||
#include "opt_ddb.h"
|
||||
@ -120,11 +120,6 @@ struct vm_map *phys_map = NULL;
|
||||
*/
|
||||
/*int maxmem;*/ /* max memory per process */
|
||||
int physmem = MAXMEM; /* max supported memory, changes to actual */
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
extern u_int lowram;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.224 2011/12/12 19:03:09 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.225 2012/07/27 05:36:10 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -39,7 +39,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.224 2011/12/12 19:03:09 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.225 2012/07/27 05:36:10 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_compat_netbsd.h"
|
||||
@ -130,11 +130,6 @@ vaddr_t bootinfo_va;
|
||||
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem = MAXMEM; /* max supported memory, changes to actual */
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
extern u_int lowram;
|
||||
extern short exframesize[];
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: intr.c,v 1.18 2010/12/20 00:25:33 matt Exp $ */
|
||||
/* $NetBSD: intr.c,v 1.19 2012/07/27 05:36:10 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994-1998 Mark Brinicombe.
|
||||
@ -36,7 +36,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.18 2010/12/20 00:25:33 matt Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.19 2012/07/27 05:36:10 matt Exp $");
|
||||
|
||||
#include "opt_irqstats.h"
|
||||
#include "opt_cputypes.h"
|
||||
@ -106,7 +106,6 @@ void set_spl_masks(void);
|
||||
|
||||
u_int spl_masks[_SPL_LEVELS + 1];
|
||||
u_int spl_smasks[_SPL_LEVELS];
|
||||
int safepri = _SPL_0;
|
||||
|
||||
#ifdef __HAVE_FAST_SOFTINTS
|
||||
/* Handle software interrupts */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: intr.h,v 1.16 2012/06/10 13:15:24 skrll Exp $ */
|
||||
/* $NetBSD: intr.h,v 1.17 2012/07/27 05:36:10 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1997 Mark Brinicombe.
|
||||
@ -49,6 +49,8 @@
|
||||
|
||||
#define NIPL 8
|
||||
|
||||
#define IPL_SAFEPRI _SPL_0
|
||||
|
||||
#define IST_UNUSABLE -1 /* interrupt cannot be used */
|
||||
#define IST_NONE 0 /* none (dummy) */
|
||||
#define IST_PULSE 1 /* pulsed */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.89 2011/12/12 19:03:10 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.90 2012/07/27 05:36:10 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2000 The NetBSD Foundation, Inc.
|
||||
@ -31,7 +31,7 @@
|
||||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.89 2011/12/12 19:03:10 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.90 2012/07/27 05:36:10 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_kgdb.h"
|
||||
@ -104,11 +104,6 @@ struct vm_map *phys_map = NULL;
|
||||
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem; /* set by locore */
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
extern u_int lowram;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: psl.h,v 1.14 2009/05/06 21:37:40 mhitch Exp $ */
|
||||
/* $NetBSD: psl.h,v 1.15 2012/07/27 05:36:11 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1982, 1986, 1993
|
||||
@ -69,6 +69,8 @@
|
||||
|
||||
#if defined(_KERNEL) && !defined(_LOCORE)
|
||||
|
||||
#define IPL_SAFEPRI PSL_LOWIPL /* for kern_sleepq.c */
|
||||
|
||||
/*
|
||||
* spl functions; platform-specific code must define spl0 and splx().
|
||||
*/
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.343 2012/01/27 18:52:57 para Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.344 2012/07/27 05:36:11 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -74,7 +74,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.343 2012/01/27 18:52:57 para Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.344 2012/07/27 05:36:11 matt Exp $");
|
||||
|
||||
#include "opt_adb.h"
|
||||
#include "opt_ddb.h"
|
||||
@ -193,12 +193,6 @@ struct vm_map *phys_map = NULL;
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem = MAXMEM; /* max supported memory, changes to actual */
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
/*
|
||||
* Extent maps to manage all memory space, including I/O ranges. Allocate
|
||||
* storage for 8 regions in each, initially. Later, iomem_malloc_safe
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.150 2011/12/12 19:03:10 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.151 2012/07/27 05:36:11 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -39,7 +39,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.150 2011/12/12 19:03:10 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.151 2012/07/27 05:36:11 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_m060sp.h"
|
||||
@ -126,12 +126,6 @@ paddr_t msgbufpa; /* PA of message buffer */
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem; /* size of physical memory */
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
/*
|
||||
* The driver for the ethernet chip appropriate to the
|
||||
* platform (lance or i82586) will use this variable
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.98 2011/12/12 19:03:11 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.99 2012/07/27 05:36:11 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -39,7 +39,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.98 2011/12/12 19:03:11 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.99 2012/07/27 05:36:11 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_compat_netbsd.h"
|
||||
@ -112,11 +112,6 @@ struct vm_map *phys_map = NULL;
|
||||
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem = MAXMEM; /* max supported memory, changes to actual */
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
extern paddr_t avail_start, avail_end;
|
||||
extern int end, *esym;
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.106 2011/12/12 19:03:11 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.107 2012/07/27 05:36:11 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1998 Darrin B. Jewell
|
||||
@ -40,7 +40,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.106 2011/12/12 19:03:11 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.107 2012/07/27 05:36:11 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_kgdb.h"
|
||||
@ -132,12 +132,6 @@ paddr_t msgbufpa; /* PA of message buffer */
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem; /* size of physical memory */
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
extern u_int lowram;
|
||||
extern short exframesize[];
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: intr.h,v 1.11 2008/04/28 20:23:36 martin Exp $ */
|
||||
/* $NetBSD: intr.h,v 1.12 2012/07/27 05:36:11 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1998 The NetBSD Foundation, Inc.
|
||||
@ -61,6 +61,12 @@
|
||||
|
||||
#define IPL_ZS IPL_HIGH
|
||||
|
||||
/*
|
||||
* IPL_SAFEPRI is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
#define IPL_SAFEPRI 0
|
||||
|
||||
#if defined(_KERNEL) && !defined(_LOCORE)
|
||||
void *
|
||||
sparc_softintr_establish(int level, void (*fun)(void *), void *arg);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.319 2012/05/21 14:15:18 martin Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.320 2012/07/27 05:36:12 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc.
|
||||
@ -71,7 +71,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.319 2012/05/21 14:15:18 martin Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.320 2012/07/27 05:36:12 matt Exp $");
|
||||
|
||||
#include "opt_compat_netbsd.h"
|
||||
#include "opt_compat_sunos.h"
|
||||
@ -145,12 +145,6 @@ int physmem;
|
||||
|
||||
kmutex_t fpu_mtx;
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = 0;
|
||||
|
||||
/*
|
||||
* dvmamap24 is used to manage DVMA memory for devices that have the upper
|
||||
* eight address bits wired to all-ones (e.g. `le' and `ie')
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: intr.h,v 1.30 2011/04/13 03:24:28 mrg Exp $ */
|
||||
/* $NetBSD: intr.h,v 1.31 2012/07/27 05:36:12 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1998 The NetBSD Foundation, Inc.
|
||||
@ -56,6 +56,12 @@
|
||||
#define IPL_PAUSE 13 /* pause cpu */
|
||||
#define IPL_FDSOFT PIL_FDSOFT /* floppy */
|
||||
|
||||
/*
|
||||
* IPL_SAFEPRI is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
#define IPL_SAFEPRI IPL_NONE
|
||||
|
||||
#ifndef _LOCORE
|
||||
void fpusave_lwp(struct lwp *, bool);
|
||||
#endif /* _LOCORE */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.267 2012/05/21 14:15:18 martin Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.268 2012/07/27 05:36:12 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1996, 1997, 1998 The NetBSD Foundation, Inc.
|
||||
@ -71,7 +71,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.267 2012/05/21 14:15:18 martin Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.268 2012/07/27 05:36:12 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_multiprocessor.h"
|
||||
@ -169,12 +169,6 @@ extern void *msgbufaddr;
|
||||
#define MAX_DMA_SEGS 20
|
||||
#endif
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = 0;
|
||||
|
||||
void dumpsys(void);
|
||||
void stackdump(void);
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.72 2012/01/27 18:53:03 para Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.73 2012/07/27 05:36:12 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1982, 1986, 1990, 1993
|
||||
@ -149,7 +149,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.72 2012/01/27 18:53:03 para Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.73 2012/07/27 05:36:12 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_kgdb.h"
|
||||
@ -241,12 +241,6 @@ void * msgbufaddr;
|
||||
/* Virtual page frame for /dev/mem (see mem.c) */
|
||||
vaddr_t vmmap;
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
/* Soft copy of the enable register. */
|
||||
volatile u_short enable_reg_soft = ENABLE_REG_SOFT_UNDEF;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.204 2011/12/12 19:03:12 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.205 2012/07/27 05:36:12 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1982, 1986, 1990, 1993
|
||||
@ -78,7 +78,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.204 2011/12/12 19:03:12 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.205 2012/07/27 05:36:12 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_kgdb.h"
|
||||
@ -159,12 +159,6 @@ void * msgbufaddr;
|
||||
/* Virtual page frame for /dev/mem (see mem.c) */
|
||||
vaddr_t vmmap;
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
/* Our private scratch page for dumping the MMU. */
|
||||
static vaddr_t dumppage;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.131 2011/12/12 19:03:12 mrg Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.132 2012/07/27 05:36:12 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -38,7 +38,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.131 2011/12/12 19:03:12 mrg Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.132 2012/07/27 05:36:12 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_kgdb.h"
|
||||
@ -119,12 +119,6 @@ void * msgbufaddr;
|
||||
/* Virtual page frame for /dev/mem (see mem.c) */
|
||||
vaddr_t vmmap;
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
u_char cpu_machine_id = 0;
|
||||
const char *cpu_string = NULL;
|
||||
int cpu_has_vme = 0;
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: machdep.c,v 1.183 2012/05/16 07:32:30 isaki Exp $ */
|
||||
/* $NetBSD: machdep.c,v 1.184 2012/07/27 05:36:12 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1988 University of Utah.
|
||||
@ -39,7 +39,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.183 2012/05/16 07:32:30 isaki Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.184 2012/07/27 05:36:12 matt Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_kgdb.h"
|
||||
@ -124,12 +124,6 @@ extern int end, *esym;
|
||||
int maxmem; /* max memory per process */
|
||||
int physmem = MAXMEM; /* max supported memory, changes to actual */
|
||||
|
||||
/*
|
||||
* safepri is a safe priority for sleep to set for a spin-wait
|
||||
* during autoconfiguration or after a panic.
|
||||
*/
|
||||
int safepri = PSL_LOWIPL;
|
||||
|
||||
/* prototypes for local functions */
|
||||
void identifycpu(void);
|
||||
void initcpu(void);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: kern_sleepq.c,v 1.46 2012/02/19 21:06:54 rmind Exp $ */
|
||||
/* $NetBSD: kern_sleepq.c,v 1.47 2012/07/27 05:36:13 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2006, 2007, 2008, 2009 The NetBSD Foundation, Inc.
|
||||
@ -35,11 +35,12 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_sleepq.c,v 1.46 2012/02/19 21:06:54 rmind Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_sleepq.c,v 1.47 2012/07/27 05:36:13 matt Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/kernel.h>
|
||||
#include <sys/cpu.h>
|
||||
#include <sys/intr.h>
|
||||
#include <sys/pool.h>
|
||||
#include <sys/proc.h>
|
||||
#include <sys/resourcevar.h>
|
||||
@ -48,6 +49,19 @@ __KERNEL_RCSID(0, "$NetBSD: kern_sleepq.c,v 1.46 2012/02/19 21:06:54 rmind Exp $
|
||||
#include <sys/sleepq.h>
|
||||
#include <sys/ktrace.h>
|
||||
|
||||
/*
|
||||
* for sleepq_abort:
|
||||
* During autoconfiguration or after a panic, a sleep will simply lower the
|
||||
* priority briefly to allow interrupts, then return. The priority to be
|
||||
* used (IPL_SAFEPRI) is machine-dependent, thus this value is initialized and
|
||||
* maintained in the machine-dependent layers. This priority will typically
|
||||
* be 0, or the lowest priority that is safe for use on the interrupt stack;
|
||||
* it can be made higher to block network software interrupts after panics.
|
||||
*/
|
||||
#ifndef IPL_SAFEPRI
|
||||
#define IPL_SAFEPRI 0
|
||||
#endif
|
||||
|
||||
static int sleepq_sigtoerror(lwp_t *, int);
|
||||
|
||||
/* General purpose sleep table, used by mtsleep() and condition variables. */
|
||||
@ -396,11 +410,10 @@ sleepq_sigtoerror(lwp_t *l, int sig)
|
||||
int
|
||||
sleepq_abort(kmutex_t *mtx, int unlock)
|
||||
{
|
||||
extern int safepri;
|
||||
int s;
|
||||
|
||||
s = splhigh();
|
||||
splx(safepri);
|
||||
splx(IPL_SAFEPRI);
|
||||
splx(s);
|
||||
if (mtx != NULL && unlock != 0)
|
||||
mutex_exit(mtx);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: kern_synch.c,v 1.301 2012/04/21 22:38:25 rmind Exp $ */
|
||||
/* $NetBSD: kern_synch.c,v 1.302 2012/07/27 05:36:13 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1999, 2000, 2004, 2006, 2007, 2008, 2009
|
||||
@ -69,7 +69,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_synch.c,v 1.301 2012/04/21 22:38:25 rmind Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_synch.c,v 1.302 2012/07/27 05:36:13 matt Exp $");
|
||||
|
||||
#include "opt_kstack.h"
|
||||
#include "opt_perfctrs.h"
|
||||
@ -137,20 +137,6 @@ static struct evcnt kpreempt_ev_crit __cacheline_aligned;
|
||||
static struct evcnt kpreempt_ev_klock __cacheline_aligned;
|
||||
static struct evcnt kpreempt_ev_immed __cacheline_aligned;
|
||||
|
||||
/*
|
||||
* During autoconfiguration or after a panic, a sleep will simply lower the
|
||||
* priority briefly to allow interrupts, then return. The priority to be
|
||||
* used (safepri) is machine-dependent, thus this value is initialized and
|
||||
* maintained in the machine-dependent layers. This priority will typically
|
||||
* be 0, or the lowest priority that is safe for use on the interrupt stack;
|
||||
* it can be made higher to block network software interrupts after panics.
|
||||
*/
|
||||
#ifdef IPL_SAFEPRI
|
||||
int safepri = IPL_SAFEPRI;
|
||||
#else
|
||||
int safepri;
|
||||
#endif
|
||||
|
||||
void
|
||||
synch_init(void)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user