summaryrefslogtreecommitdiffstats
path: root/sys/arm
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/arm
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/arm')
-rw-r--r--sys/arm/arm/intr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/arm/arm/intr.c b/sys/arm/arm/intr.c
index c991220..fbaa96c 100644
--- a/sys/arm/arm/intr.c
+++ b/sys/arm/arm/intr.c
@@ -92,10 +92,10 @@ arm_setup_irqhandler(const char *name, driver_filter_t *filt,
#ifdef INTR_FILTER
error = intr_event_create(&event, (void *)irq, 0,
(void (*)(void *))arm_unmask_irq, intr_eoi_src,
- intr_disab_eoi_src, "intr%d:", irq);
+ intr_disab_eoi_src, NULL, "intr%d:", irq);
#else
error = intr_event_create(&event, (void *)irq, 0,
- (void (*)(void *))arm_unmask_irq, "intr%d:", irq);
+ (void (*)(void *))arm_unmask_irq, NULL, "intr%d:", irq);
#endif
if (error)
return;
OpenPOWER on IntegriCloud