Only define machdep sysctls if CPU_MAXID is not defined by machine/cpu.h.

This lets mips ports have additional machdep sysctl.  Define CPUISMIPS3
for MIPS1+MIPS2 as cpu_arch >= 3 to support mips4.  Add cpu_intr()
prototype so this is defined in one place.
This commit is contained in:
jeffs 2000-07-11 06:34:57 +00:00
parent 6b28794054
commit f6812b853b
1 changed files with 6 additions and 3 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: cpu.h,v 1.41 2000/05/30 02:05:36 nisimura Exp $ */
/* $NetBSD: cpu.h,v 1.42 2000/07/11 06:34:57 jeffs Exp $ */
/*-
* Copyright (c) 1992, 1993
@ -45,6 +45,7 @@
* Exported definitions unique to NetBSD/mips cpu support.
*/
#ifndef CPU_MAXID /* platform can override */
/*
* CTL_MACHDEP definitions.
*/
@ -59,7 +60,7 @@
{ "booted_kernel", CTLTYPE_STRING }, \
{ "root_device", CTLTYPE_STRING }, \
}
#endif
#ifdef _KERNEL
#ifndef _LOCORE
@ -80,7 +81,7 @@
#else /* run-time test */
extern int cpu_arch;
#define CPUISMIPS3 (cpu_arch == 3)
#define CPUISMIPS3 (cpu_arch >= 3)
#endif /* run-time test */
/*
@ -90,6 +91,8 @@ extern int cpu_arch;
#define cpu_wait(p) /* nothing */
#define cpu_swapout(p) panic("cpu_swapout: can't get here");
void cpu_intr __P((u_int32_t, u_int32_t, u_int32_t, u_int32_t));
/*
* Arguments to hardclock and gatherstats encapsulate the previous
* machine state in an opaque clockframe.