[driver-discuss] interrupt enable/disable

Paul Durrant pdurrant at gmail.com
Tue May 22 03:26:30 PDT 2007


On 22/05/07, Paul Durrant <pdurrant at gmail.com> wrote:
> > - Send  "echo ::interrupts | mdb -k" output before and after calling
> >    block enable/disable calls.
>
> Ok - I'll get this info. shortly. Thanks,
>

Interrupts are working at this point:

# echo ::interrupts | mdb -k
IRQ  Vect IPL Bus    Trg Type   CPU Share APIC/INT# ISR(s)
4    0xb0 12  ISA    Edg Fixed  1   1     0x0/0x4   asyintr
6    0x41 5   ISA    Edg Fixed  1   1     0x0/0x6   fdc_intr
9    0x81 9   PCI    Lvl Fixed  1   1     0x0/0x9   acpi_wrapper_isr
14   0x42 5   ISA    Edg Fixed  1   1     0x0/0xe   ata_intr
16   0x21 1   PCI    Lvl Fixed  1   1     0x0/0x10  uhci_intr
18   0x23 1   PCI    Lvl Fixed  1   1     0x0/0x12  uhci_intr
19   0x22 1   PCI    Lvl Fixed  1   1     0x0/0x13  uhci_intr
23   0x20 1   PCI    Lvl Fixed  0   1     0x0/0x17  ehci_intr
64   0x60 6   PCI    Lvl Fixed  0   1     0x2/0x0   e1000g_intr
88   0x40 5   PCI    Edg MSI    0   1     -         mpt_intr
89   0x62 6   PCIe   Edg MSI    0   1     -         sfxge_intr_msi
90   0x63 6   PCIe   Edg MSI    0   1     -         sfxge_intr_msi
160  0xa0 0          Edg IPI    all 0     -         poke_cpu
192  0xc0 13         Edg IPI    all 1     -         xc_serv
208  0xd0 14         Edg IPI    all 1     -         kcpc_hw_overflow_intr
209  0xd1 14         Edg IPI    all 1     -         cbe_fire
210  0xd3 14         Edg IPI    all 1     -         cbe_fire
224  0xe0 15         Edg IPI    all 1     -         xc_serv
225  0xe1 15         Edg IPI    all 1     -         apic_error_intr

I now issue an ioctl to my driver that calls block disable (and does
nothing else).

# echo ::interrupts | mdb -k
IRQ  Vect IPL Bus    Trg Type   CPU Share APIC/INT# ISR(s)
4    0xb0 12  ISA    Edg Fixed  1   1     0x0/0x4   asyintr
6    0x41 5   ISA    Edg Fixed  1   1     0x0/0x6   fdc_intr
9    0x81 9   PCI    Lvl Fixed  1   1     0x0/0x9   acpi_wrapper_isr
14   0x42 5   ISA    Edg Fixed  1   1     0x0/0xe   ata_intr
16   0x21 1   PCI    Lvl Fixed  1   1     0x0/0x10  uhci_intr
18   0x23 1   PCI    Lvl Fixed  1   1     0x0/0x12  uhci_intr
19   0x22 1   PCI    Lvl Fixed  1   1     0x0/0x13  uhci_intr
23   0x20 1   PCI    Lvl Fixed  0   1     0x0/0x17  ehci_intr
64   0x60 6   PCI    Lvl Fixed  0   1     0x2/0x0   e1000g_intr
88   0x40 5   PCI    Edg MSI    0   1     -         mpt_intr
160  0xa0 0          Edg IPI    all 0     -         poke_cpu
192  0xc0 13         Edg IPI    all 1     -         xc_serv
208  0xd0 14         Edg IPI    all 1     -         kcpc_hw_overflow_intr
209  0xd1 14         Edg IPI    all 1     -         cbe_fire
210  0xd3 14         Edg IPI    all 1     -         cbe_fire
224  0xe0 15         Edg IPI    all 1     -         xc_serv
225  0xe1 15         Edg IPI    all 1     -         apic_error_intr

So, the interrupt vectors are gone; which seems reasonable. I now
issue another ioctl to call block enable.

# echo ::interrupts | mdb -k
IRQ  Vect IPL Bus    Trg Type   CPU Share APIC/INT# ISR(s)
4    0xb0 12  ISA    Edg Fixed  1   1     0x0/0x4   asyintr
6    0x41 5   ISA    Edg Fixed  1   1     0x0/0x6   fdc_intr
9    0x81 9   PCI    Lvl Fixed  1   1     0x0/0x9   acpi_wrapper_isr
14   0x42 5   ISA    Edg Fixed  1   1     0x0/0xe   ata_intr
16   0x21 1   PCI    Lvl Fixed  1   1     0x0/0x10  uhci_intr
18   0x23 1   PCI    Lvl Fixed  1   1     0x0/0x12  uhci_intr
19   0x22 1   PCI    Lvl Fixed  1   1     0x0/0x13  uhci_intr
23   0x20 1   PCI    Lvl Fixed  0   1     0x0/0x17  ehci_intr
64   0x60 6   PCI    Lvl Fixed  0   1     0x2/0x0   e1000g_intr
88   0x40 5   PCI    Edg MSI    0   1     -         mpt_intr
89   0x61 6   PCIe   Edg MSI    1   1     -         sfxge_intr_msi
90   0x62 6   PCIe   Edg MSI    1   1     -         sfxge_intr_msi
160  0xa0 0          Edg IPI    all 0     -         poke_cpu
192  0xc0 13         Edg IPI    all 1     -         xc_serv
208  0xd0 14         Edg IPI    all 1     -         kcpc_hw_overflow_intr
209  0xd1 14         Edg IPI    all 1     -         cbe_fire
210  0xd3 14         Edg IPI    all 1     -         cbe_fire
224  0xe0 15         Edg IPI    all 1     -         xc_serv
225  0xe1 15         Edg IPI    all 1     -         apic_error_intr
#

So two vectors have re-appeared, but they're shifted by 1 i.e. they
now start at 0x61 rather than 0x62. So, maybe my lack of interrupts is
due to the MSI address no longer hitting the correct vector because it
has not been re-programmed? (I don't know what stage the MSI base is
programmed). Seems a bit odd that the vectors would shift though;
since I would have thought they were reserved at allocation time
rather than enable time.
BTW; if I disable and re-enable again the vectors stay at 0x61. If a
tear down and re-allocate the interrupt handles they move back to 0x62
and the h/w starts interrupting again.

  Paul

-- 
Paul Durrant
http://www.linkedin.com/in/pdurrant



More information about the driver-discuss mailing list