[haiku-commits] Re: r41328 - haiku/trunk/src/system/kernel/arch/x86

  • From: Fredrik Holmqvist <fredrik.holmqvist@xxxxxxxxx>
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Fri, 6 May 2011 20:01:35 +0200

2011/5/5  <mmlr@xxxxxxxx>:
> +static void
> +pic_disable()
> +{
> +       // Mask off all interrupts on master and slave
> +       out8(0xff, PIC_MASTER_MASK);
> +       out8(0xff, PIC_SLAVE_MASK);
> +}

From my understanding this should only be done on systems with a real
PIC and should be checked beforehand with a flag in the MADT table,
but since the PIC hasn't been used in ages I think it could safely be
skipped.

>        // prefer the ioapic over the normal pic
>        dprintf("using ioapic for interrupt routing\n");
>        sCurrentPIC = &ioapicController;

sCurrentPIC should be set to &ioapicController before ACPI init, as it
will install an interrupt handler with the pic interrupt functions
otherwise.

> Modified: haiku/trunk/src/system/kernel/arch/x86/irq_routing_table.cpp

The scanning in this file can probably be rewritten much better. The
difference between INT and EXTINT is that INT's are internal (to the
APIC IIRC) and EXTINT are external. I think we should just mess with
EXTINT. Also it currently only finds PCI root bridges,not PCI-E.

I plan on writing some printing code for _PRS functions, let me know
if I can help.

/Fredrik Holmqvist, TQH

Other related posts: