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