PERFORCE change 112981 for review
Paolo Pisati
piso at FreeBSD.org
Tue Jan 16 10:18:59 UTC 2007
http://perforce.freebsd.org/chv.cgi?CH=112981
Change 112981 by piso at piso_newluxor on 2007/01/16 10:18:52
Move spin lock acquisition for the callout path into the
interrupt scanning function, and add the callout_init() call
that ought to be there.
Affected files ...
.. //depot/projects/soc2006/intr_filter/powerpc/powerpc/intr_machdep.c#26 edit
Differences ...
==== //depot/projects/soc2006/intr_filter/powerpc/powerpc/intr_machdep.c#26 (text+ko) ====
@@ -123,6 +123,7 @@
panic("intr_init: unable to allocate interrupt handler array");
mtx_init(&ppc_intrs_lock, "intr table", NULL, MTX_SPIN);
+ callout_init(&stray_callout_handle, 1);
irq_enable = irq_e;
@@ -286,7 +287,9 @@
for (; i < ppc_nintrs; ) {
j = i++;
+ mtx_lock_spin(&ppc_intrs_lock);
intr = ppc_intrs[j];
+ mtx_unlock_spin(&ppc_intrs_lock);
if (intr != NULL && intr->event != NULL)
return (intr->event);
}
@@ -297,11 +300,9 @@
void
intr_callout_reset(void)
{
-
- mtx_lock_spin(&ppc_intrs_lock);
+
callout_reset(&stray_callout_handle, hz, &stray_detection,
- &walk_intr_ppc);
- mtx_unlock_spin(&ppc_intrs_lock);
+ &walk_intr_ppc);
}
void
More information about the p4-projects
mailing list