PCI: add routines for debugging and handling lost interrupts