summaryrefslogtreecommitdiffstats
path: root/sys/sparc64
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2008-03-14 19:41:48 +0000
committerjhb <jhb@FreeBSD.org>2008-03-14 19:41:48 +0000
commit9c113163fb2bb182d320f0228312c13601341163 (patch)
treec7c725651b1ad4c07a8fe93c253676ef3d6d5279 /sys/sparc64
parent33dfb1706b9985093bf2f15b13b6d6fcf86e117f (diff)
downloadFreeBSD-src-9c113163fb2bb182d320f0228312c13601341163.zip
FreeBSD-src-9c113163fb2bb182d320f0228312c13601341163.tar.gz
Add preliminary support for binding interrupts to CPUs:
- Add a new intr_event method ie_assign_cpu() that is invoked when the MI code wishes to bind an interrupt source to an individual CPU. The MD code may reject the binding with an error. If an assign_cpu function is not provided, then the kernel assumes the platform does not support binding interrupts to CPUs and fails all requests to do so. - Bind ithreads to CPUs on their next execution loop once an interrupt event is bound to a CPU. Only shared ithreads are bound. We currently leave private ithreads for drivers using filters + ithreads in the INTR_FILTER case unbound. - A new intr_event_bind() routine is used to bind an interrupt event to a CPU. - Implement binding on amd64 and i386 by way of the existing pic_assign_cpu PIC method. - For x86, provide a 'intr_bind(IRQ, cpu)' wrapper routine that looks up an interrupt source and binds its interrupt event to the specified CPU. MI code can currently (ab)use this by doing: intr_bind(rman_get_start(irq_res), cpu); however, I plan to add a truly MI interface (probably a bus_bind_intr(9)) where the implementation in the x86 nexus(4) driver would end up calling intr_bind() internally. Requested by: kmacy, gallatin, jeff Tested on: {amd64, i386} x {regular, INTR_FILTER}
Diffstat (limited to 'sys/sparc64')
-rw-r--r--sys/sparc64/sparc64/intr_machdep.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/sparc64/sparc64/intr_machdep.c b/sys/sparc64/sparc64/intr_machdep.c
index 735b4c0..091ed90 100644
--- a/sys/sparc64/sparc64/intr_machdep.c
+++ b/sys/sparc64/sparc64/intr_machdep.c
@@ -331,9 +331,9 @@ intr_controller_register(int vec, const struct intr_controller *ic,
*/
error = intr_event_create(&ie, iv, 0, intr_enable_eoi,
#ifdef INTR_FILTER
- ic->ic_eoi, ic->ic_disable, "vec%d:", vec);
+ ic->ic_eoi, ic->ic_disable, NULL, "vec%d:", vec);
#else
- "vec%d:", vec);
+ NULL, "vec%d:", vec);
#endif
if (error != 0)
return (error);
OpenPOWER on IntegriCloud