mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-17 15:27:36 +00:00
Unspammed includes in <machine/cpufunc.h> in the !SMP case. Partially
unspammed them in the SMP case.
This commit is contained in:
parent
f93b86166a
commit
2a32c15f45
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=42410
@ -30,7 +30,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cpufunc.h,v 1.81 1998/08/17 08:57:05 dfr Exp $
|
||||
* $Id: cpufunc.h,v 1.82 1999/01/08 16:29:57 bde Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -40,15 +40,6 @@
|
||||
#ifndef _MACHINE_CPUFUNC_H_
|
||||
#define _MACHINE_CPUFUNC_H_
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <machine/lock.h>
|
||||
|
||||
#if defined(SWTCH_OPTIM_STATS)
|
||||
extern int tlb_flush_count;
|
||||
#endif
|
||||
|
||||
#define readb(va) (*(volatile u_int8_t *) (va))
|
||||
#define readw(va) (*(volatile u_int16_t *) (va))
|
||||
#define readl(va) (*(volatile u_int32_t *) (va))
|
||||
@ -59,6 +50,14 @@ extern int tlb_flush_count;
|
||||
|
||||
#ifdef __GNUC__
|
||||
|
||||
#ifdef SMP
|
||||
#include <machine/lock.h> /* XXX */
|
||||
#endif
|
||||
|
||||
#ifdef SWTCH_OPTIM_STATS
|
||||
extern int tlb_flush_count; /* XXX */
|
||||
#endif
|
||||
|
||||
static __inline void
|
||||
breakpoint(void)
|
||||
{
|
||||
@ -69,13 +68,17 @@ static __inline void
|
||||
disable_intr(void)
|
||||
{
|
||||
__asm __volatile("cli" : : : "memory");
|
||||
#ifdef SMP
|
||||
MPINTR_LOCK();
|
||||
#endif
|
||||
}
|
||||
|
||||
static __inline void
|
||||
enable_intr(void)
|
||||
{
|
||||
#ifdef SMP
|
||||
MPINTR_UNLOCK();
|
||||
#endif
|
||||
__asm __volatile("sti");
|
||||
}
|
||||
|
||||
|
@ -34,12 +34,15 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
|
||||
* $Id: intr_machdep.c,v 1.14 1998/09/06 22:41:41 tegge Exp $
|
||||
* $Id: intr_machdep.c,v 1.15 1998/12/04 22:54:46 archie Exp $
|
||||
*/
|
||||
|
||||
#include "opt_auto_eoi.h"
|
||||
|
||||
#include <sys/param.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
#include <sys/systm.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <machine/ipl.h>
|
||||
|
@ -34,12 +34,15 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
|
||||
* $Id: intr_machdep.c,v 1.14 1998/09/06 22:41:41 tegge Exp $
|
||||
* $Id: intr_machdep.c,v 1.15 1998/12/04 22:54:46 archie Exp $
|
||||
*/
|
||||
|
||||
#include "opt_auto_eoi.h"
|
||||
|
||||
#include <sys/param.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
#include <sys/systm.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <machine/ipl.h>
|
||||
|
@ -29,7 +29,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id$
|
||||
* $Id: adwlib.c,v 1.1 1998/10/07 03:20:46 gibbs Exp $
|
||||
*/
|
||||
/*
|
||||
* Ported from:
|
||||
@ -43,7 +43,8 @@
|
||||
* code retain the above copyright notice and this comment without
|
||||
* modification.
|
||||
*/
|
||||
#include <sys/queue.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/systm.h>
|
||||
|
||||
#include <machine/bus_pio.h>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cy.c,v 1.81 1998/12/19 16:28:57 bde Exp $
|
||||
* $Id: cy.c,v 1.82 1998/12/24 14:17:57 bde Exp $
|
||||
*/
|
||||
|
||||
#include "opt_compat.h"
|
||||
@ -86,6 +86,9 @@
|
||||
|
||||
#include <machine/clock.h>
|
||||
#include <machine/ipl.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
|
||||
#include <i386/isa/isa_device.h>
|
||||
#include <i386/isa/cyreg.h>
|
||||
|
@ -27,7 +27,7 @@
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cy.c,v 1.81 1998/12/19 16:28:57 bde Exp $
|
||||
* $Id: cy.c,v 1.82 1998/12/24 14:17:57 bde Exp $
|
||||
*/
|
||||
|
||||
#include "opt_compat.h"
|
||||
@ -86,6 +86,9 @@
|
||||
|
||||
#include <machine/clock.h>
|
||||
#include <machine/ipl.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
|
||||
#include <i386/isa/isa_device.h>
|
||||
#include <i386/isa/cyreg.h>
|
||||
|
@ -30,7 +30,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cpufunc.h,v 1.81 1998/08/17 08:57:05 dfr Exp $
|
||||
* $Id: cpufunc.h,v 1.82 1999/01/08 16:29:57 bde Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -40,15 +40,6 @@
|
||||
#ifndef _MACHINE_CPUFUNC_H_
|
||||
#define _MACHINE_CPUFUNC_H_
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <machine/lock.h>
|
||||
|
||||
#if defined(SWTCH_OPTIM_STATS)
|
||||
extern int tlb_flush_count;
|
||||
#endif
|
||||
|
||||
#define readb(va) (*(volatile u_int8_t *) (va))
|
||||
#define readw(va) (*(volatile u_int16_t *) (va))
|
||||
#define readl(va) (*(volatile u_int32_t *) (va))
|
||||
@ -59,6 +50,14 @@ extern int tlb_flush_count;
|
||||
|
||||
#ifdef __GNUC__
|
||||
|
||||
#ifdef SMP
|
||||
#include <machine/lock.h> /* XXX */
|
||||
#endif
|
||||
|
||||
#ifdef SWTCH_OPTIM_STATS
|
||||
extern int tlb_flush_count; /* XXX */
|
||||
#endif
|
||||
|
||||
static __inline void
|
||||
breakpoint(void)
|
||||
{
|
||||
@ -69,13 +68,17 @@ static __inline void
|
||||
disable_intr(void)
|
||||
{
|
||||
__asm __volatile("cli" : : : "memory");
|
||||
#ifdef SMP
|
||||
MPINTR_LOCK();
|
||||
#endif
|
||||
}
|
||||
|
||||
static __inline void
|
||||
enable_intr(void)
|
||||
{
|
||||
#ifdef SMP
|
||||
MPINTR_UNLOCK();
|
||||
#endif
|
||||
__asm __volatile("sti");
|
||||
}
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: cy.c,v 1.81 1998/12/19 16:28:57 bde Exp $
|
||||
* $Id: cy.c,v 1.82 1998/12/24 14:17:57 bde Exp $
|
||||
*/
|
||||
|
||||
#include "opt_compat.h"
|
||||
@ -86,6 +86,9 @@
|
||||
|
||||
#include <machine/clock.h>
|
||||
#include <machine/ipl.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
|
||||
#include <i386/isa/isa_device.h>
|
||||
#include <i386/isa/cyreg.h>
|
||||
|
@ -34,12 +34,15 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
|
||||
* $Id: intr_machdep.c,v 1.14 1998/09/06 22:41:41 tegge Exp $
|
||||
* $Id: intr_machdep.c,v 1.15 1998/12/04 22:54:46 archie Exp $
|
||||
*/
|
||||
|
||||
#include "opt_auto_eoi.h"
|
||||
|
||||
#include <sys/param.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
#include <sys/systm.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <machine/ipl.h>
|
||||
|
@ -34,12 +34,15 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)isa.c 7.2 (Berkeley) 5/13/91
|
||||
* $Id: intr_machdep.c,v 1.14 1998/09/06 22:41:41 tegge Exp $
|
||||
* $Id: intr_machdep.c,v 1.15 1998/12/04 22:54:46 archie Exp $
|
||||
*/
|
||||
|
||||
#include "opt_auto_eoi.h"
|
||||
|
||||
#include <sys/param.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
#include <sys/systm.h>
|
||||
#include <sys/syslog.h>
|
||||
#include <machine/ipl.h>
|
||||
|
@ -31,7 +31,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* from: @(#)com.c 7.5 (Berkeley) 5/16/91
|
||||
* $Id: sio.c,v 1.220 1998/12/27 12:35:48 phk Exp $
|
||||
* $Id: sio.c,v 1.221 1999/01/07 14:14:23 yokota Exp $
|
||||
*/
|
||||
|
||||
#include "opt_comconsole.h"
|
||||
@ -70,6 +70,9 @@
|
||||
|
||||
#include <machine/clock.h>
|
||||
#include <machine/ipl.h>
|
||||
#ifndef SMP
|
||||
#include <machine/lock.h>
|
||||
#endif
|
||||
|
||||
#include <i386/isa/isa.h>
|
||||
#include <i386/isa/isa_device.h>
|
||||
|
Loading…
Reference in New Issue
Block a user