diff options
author | Takuya ASADA <syuu@cvs.openbsd.org> | 2010-09-11 11:29:51 +0000 |
---|---|---|
committer | Takuya ASADA <syuu@cvs.openbsd.org> | 2010-09-11 11:29:51 +0000 |
commit | af8cab657ccebdedb57110926c79dbb4b51f4664 (patch) | |
tree | 957100f6bb371ec45c9bd8564a97d938724c5257 /sys/arch/mips64 | |
parent | 4547a29bb5bafa8c3d8068937641164a9e24f967 (diff) |
move machine dependent GET_CPU_INFO(), getcurcpu(), setcurcpu() to arch/sgi. ok miod@
Diffstat (limited to 'sys/arch/mips64')
-rw-r--r-- | sys/arch/mips64/include/asm.h | 7 | ||||
-rw-r--r-- | sys/arch/mips64/include/cpu.h | 6 | ||||
-rw-r--r-- | sys/arch/mips64/mips64/cp0access.S | 16 |
3 files changed, 6 insertions, 23 deletions
diff --git a/sys/arch/mips64/include/asm.h b/sys/arch/mips64/include/asm.h index c8c2b368a41..5b97ab7848c 100644 --- a/sys/arch/mips64/include/asm.h +++ b/sys/arch/mips64/include/asm.h @@ -1,4 +1,4 @@ -/* $OpenBSD: asm.h,v 1.11 2010/04/28 16:20:28 syuu Exp $ */ +/* $OpenBSD: asm.h,v 1.12 2010/09/11 11:29:49 syuu Exp $ */ /* * Copyright (c) 2001-2002 Opsycon AB (www.opsycon.se / www.opsycon.com) @@ -298,10 +298,7 @@ x: ; \ dsll reg, reg, 59 #ifdef MULTIPROCESSOR -#define GET_CPU_INFO(ci, tmp) \ - LOAD_XKPHYS(ci, CCA_CACHED); \ - mfc0 tmp, COP_0_LLADDR; \ - or ci, ci, tmp +#define GET_CPU_INFO(ci, tmp) HW_GET_CPU_INFO(ci, tmp) #else /* MULTIPROCESSOR */ #define GET_CPU_INFO(ci, tmp) \ LA ci, cpu_info_primary diff --git a/sys/arch/mips64/include/cpu.h b/sys/arch/mips64/include/cpu.h index 692aed0c0da..fc3d17a015e 100644 --- a/sys/arch/mips64/include/cpu.h +++ b/sys/arch/mips64/include/cpu.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.h,v 1.59 2010/08/30 08:52:10 syuu Exp $ */ +/* $OpenBSD: cpu.h,v 1.60 2010/09/11 11:29:49 syuu Exp $ */ /*- * Copyright (c) 1992, 1993 @@ -434,8 +434,8 @@ extern struct cpu_info *cpu_info_list; #ifdef MULTIPROCESSOR #define MAXCPUS 4 -extern struct cpu_info *getcurcpu(void); -extern void setcurcpu(struct cpu_info *); +#define getcurcpu() hw_getcurcpu() +#define setcurcpu(ci) hw_setcurcpu(ci) extern struct cpu_info *get_cpu_info(int); #define curcpu() getcurcpu() #define CPU_IS_PRIMARY(ci) ((ci)->ci_flags & CPUF_PRIMARY) diff --git a/sys/arch/mips64/mips64/cp0access.S b/sys/arch/mips64/mips64/cp0access.S index 3321ae85ea7..32866dce285 100644 --- a/sys/arch/mips64/mips64/cp0access.S +++ b/sys/arch/mips64/mips64/cp0access.S @@ -1,4 +1,4 @@ -/* $OpenBSD: cp0access.S,v 1.13 2010/04/28 16:20:28 syuu Exp $ */ +/* $OpenBSD: cp0access.S,v 1.14 2010/09/11 11:29:50 syuu Exp $ */ /* * Copyright (c) 2001-2003 Opsycon AB (www.opsycon.se / www.opsycon.com) @@ -192,17 +192,3 @@ LEAF(cp0_setperfctrl, 0) j ra nop END(cp0_setperfctrl) - -#ifdef MULTIPROCESSOR -LEAF(getcurcpu, 0) - GET_CPU_INFO(v0, v1) - jr ra - nop -END(getcurcpu) - -LEAF(setcurcpu, 0) - mtc0 a0, COP_0_LLADDR - j ra - nop -END(setcurcpu) -#endif |