From f94a577a72115bb3c2e2bde28ad844fcc7faca23 Mon Sep 17 00:00:00 2001 From: fsmp Date: Mon, 5 May 1997 22:56:37 +0000 Subject: Code to handle SMP/APIC_IO mapping of ISA INTs to APIC pins above IRQ15. - doesn't break my system. - NOT yet verified on the affected motherboard. Submitted by: "John S. Dyson" --- sys/kern/subr_smp.c | 39 +++++++++++++++++++++++++++++++++------ 1 file changed, 33 insertions(+), 6 deletions(-) (limited to 'sys/kern/subr_smp.c') diff --git a/sys/kern/subr_smp.c b/sys/kern/subr_smp.c index ea2f991..8f26040 100644 --- a/sys/kern/subr_smp.c +++ b/sys/kern/subr_smp.c @@ -22,7 +22,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: mp_machdep.c,v 1.6 1997/05/01 19:27:58 fsmp Exp $ + * $Id: mp_machdep.c,v 1.7 1997/05/03 17:42:01 fsmp Exp $ */ #include "opt_smp.h" @@ -889,8 +889,8 @@ get_isa_apic_irq(int isaIRQ) /* * */ -int -get_isa_apic_mask(int isaMASK) +u_int +get_isa_apic_mask(u_int isaMASK) { int apicpin, isairq; @@ -966,17 +966,44 @@ get_pci_apic_irq(int pciBus, int pciDevice, int pciInt) #undef INTTYPE +/* + * Reprogram the MB chipset to NOT redirect a PCI INTerrupt + */ int undirect_pci_irq(int rirq) { #if defined(READY) - printf("Freeing irq %d for ISA cards.\n", rirq); + printf("Freeing redirected PCI irq %d.\n", rirq); + /** FIXME: tickle the MB redirector chip */ + return ???; +#else + printf("Freeing (NOT implemented) redirected PCI irq %d.\n", rirq); + return 0; +#endif /* READY */ +} + + +/* + * Reprogram the MB chipset to NOT redirect an ISA INTerrupt. + * + * XXX FIXME: + * Exactly what this means is unclear at this point. It is a solution + * for motherboards that redirect the MBIRQ0 pin. Generically a motherboard + * could route any of the ISA INTs to upper (>15) IRQ values. But most would + * NOT be redirected via MBIRQ0, thus "undirect()ing" them would NOT be an + * option. + */ +int +undirect_isa_irq(int rirq) +{ +#if defined(READY) + printf("Freeing redirected ISA irq %d.\n", rirq); /** FIXME: tickle the MB redirector chip */ return ???; #else - printf("Freeing (NOT implemented) irq %d for ISA cards.\n", rirq); + printf("Freeing (NOT implemented) redirected ISA irq %d.\n", rirq); return 0; -#endif /* READY */ +#endif /* READY */ } -- cgit v1.1