Subject: ext_intr thoughts
To: None <port-powerpc@netbsd.org>
From: Tim Rightnour <root@garbled.net>
List: port-powerpc
Date: 04/27/2007 00:04:12
Looking at all the ext_intr() routines, they all seem to be more or less
indentical, except:

each one needs a struct intrsource that has all the interrupt sources/handlers
each one needs an int imen;
each one needs a get_irq(), mask_irq() and eoi_irq() function.

Based on this.. I think we could write just one, but we need to do two things:

1) for the openpic+ISA case, we want to register the ext_intr routine with isa
irq bits as the handler for irq 0.

2) when we initially install the ext_intr handler, we want to specify which set
of routines to use.

What I'm not sure of, is how we can make just one routine, and have it do the
right thing.  Any ideas here?  (ie, register it once as the primary external
interrupt handler, and then register it again, but this time as the isa handler
for the cascaded openpic interrupt)

---
Tim Rightnour <root@garbled.net>
NetBSD: Free multi-architecture OS http://www.netbsd.org/
Genecys: Open Source 3D MMORPG: http://www.genecys.org/