Home | History | Annotate | Line # | Download | only in include
cpu.h revision 1.15
      1 /*	$NetBSD: cpu.h,v 1.15 2000/05/26 21:19:29 thorpej Exp $	*/
      2 /*	$OpenBSD: cpu.h,v 1.9 1998/01/28 13:46:10 pefo Exp $ */
      3 
      4 #ifndef _ARC_CPU_H_
      5 #define _ARC_CPU_H_
      6 
      7 /*
      8  *  Internal timer causes hard interrupt 5.
      9  */
     10 #define MIPS_INT_MASK_CLOCK	MIPS_INT_MASK_5
     11 
     12 #include <mips/cpu.h>
     13 #include <mips/cpuregs.h>
     14 
     15 #ifndef _LOCORE
     16 #if defined(_KERNEL) && !defined(_LKM)
     17 #include "opt_lockdebug.h"
     18 #endif
     19 
     20 #include <sys/sched.h>
     21 struct cpu_info {
     22 	struct schedstate_percpu ci_schedstate; /* scheduler state */
     23 #if defined(DIAGNOSTIC) || defined(LOCKDEBUG)
     24 	u_long ci_spin_locks;		/* # of spin locks held */
     25 	u_long ci_simple_locks;		/* # of simple locks held */
     26 #endif
     27 };
     28 
     29 #ifdef _KERNEL
     30 extern struct cpu_info cpu_info_store;
     31 
     32 #define	curcpu()	(&cpu_info_store)
     33 #define	cpu_number()	(0)
     34 #endif
     35 #endif /* !_LOCORE */
     36 
     37 /*
     38  * definitions of cpu-dependent requirements
     39  * referenced in generic code
     40  */
     41 #define	COPY_SIGCODE		/* copy sigcode above user stack in exec */
     42 
     43 #define	INT_MASK_REAL_DEV	MIPS3_HARD_INT_MASK	/* XXX */
     44 
     45 #ifndef _LOCORE
     46 struct tlb;
     47 extern void mips3_TLBWriteIndexedVPS __P((u_int index, struct tlb *tlb));
     48 #endif /* ! _LOCORE */
     49 
     50 #endif /* _ARC_CPU_H_ */
     51