aboutsummaryrefslogtreecommitdiff
path: root/sys/ia64/ia64/mp_machdep.c
diff options
context:
space:
mode:
authorAttilio Rao <attilio@FreeBSD.org>2011-06-26 17:30:46 +0000
committerAttilio Rao <attilio@FreeBSD.org>2011-06-26 17:30:46 +0000
commitcfdfd32d342a93bf60fbb3f926484c40aec480df (patch)
tree6b6a95fc14a52b97aeaad545de8ade163f7f4aef /sys/ia64/ia64/mp_machdep.c
parentde138ec703c3f7d8ed73ba94068d571b2ee7a87c (diff)
parent9134df8b6f936328aa7a2daed7af14905c8b69a1 (diff)
downloadsrc-cfdfd32d342a93bf60fbb3f926484c40aec480df.tar.gz
src-cfdfd32d342a93bf60fbb3f926484c40aec480df.zip
MFC
Notes
Notes: svn path=/projects/largeSMP/; revision=223572
Diffstat (limited to 'sys/ia64/ia64/mp_machdep.c')
-rw-r--r--sys/ia64/ia64/mp_machdep.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/sys/ia64/ia64/mp_machdep.c b/sys/ia64/ia64/mp_machdep.c
index 3af81efd0e32..0d8f241b1b15 100644
--- a/sys/ia64/ia64/mp_machdep.c
+++ b/sys/ia64/ia64/mp_machdep.c
@@ -77,6 +77,7 @@ void ia64_ap_startup(void);
struct ia64_ap_state ia64_ap_state;
int ia64_ipi_ast;
+int ia64_ipi_hardclock;
int ia64_ipi_highfp;
int ia64_ipi_nmi;
int ia64_ipi_preempt;
@@ -108,6 +109,16 @@ ia64_ih_ast(struct thread *td, u_int xiv, struct trapframe *tf)
}
static u_int
+ia64_ih_hardclock(struct thread *td, u_int xiv, struct trapframe *tf)
+{
+
+ PCPU_INC(md.stats.pcs_nhardclocks);
+ CTR1(KTR_SMP, "IPI_HARDCLOCK, cpuid=%d", PCPU_GET(cpuid));
+ hardclockintr();
+ return (0);
+}
+
+static u_int
ia64_ih_highfp(struct thread *td, u_int xiv, struct trapframe *tf)
{
@@ -233,10 +244,11 @@ ia64_ap_startup(void)
CTR1(KTR_SMP, "SMP: cpu%d launched", PCPU_GET(cpuid));
- /* Mask interval timer interrupts on APs. */
- ia64_set_itv(0x10000);
+ cpu_initclocks();
+
ia64_set_tpr(0);
ia64_srlz_d();
+
ia64_enable_intr();
sched_throw(NULL);
@@ -411,6 +423,8 @@ cpu_mp_unleash(void *dummy)
/* Allocate XIVs for IPIs */
ia64_ipi_ast = ia64_xiv_alloc(PI_DULL, IA64_XIV_IPI, ia64_ih_ast);
+ ia64_ipi_hardclock = ia64_xiv_alloc(PI_REALTIME, IA64_XIV_IPI,
+ ia64_ih_hardclock);
ia64_ipi_highfp = ia64_xiv_alloc(PI_AV, IA64_XIV_IPI, ia64_ih_highfp);
ia64_ipi_preempt = ia64_xiv_alloc(PI_SOFT, IA64_XIV_IPI,
ia64_ih_preempt);