Il 03/09/2012 04:56, Matthew Ogilvie ha scritto: > Although I haven't found any specs that say so, on real hardware > I have a test program that shows if you mask off the slave > interrupt (say IRQ14) in the IMR after it has already been raised, > the master (IRQ2) gets canceled (that is, IRQ2 acts like it is level > triggered). Without this patch, qemu delivers a > spurious interrupt (IRQ15) instead when running the test program. > > Signed-off-by: Matthew Ogilvie <mmogilvi_q...@miniinfo.net>
Nice testing, thanks! KVM's i8259 emulation can be patched at arch/x86/kvm/i8259.c in the Linux tree. You can write a test for kvm-unit-tests. These tests can be written in C, including interrupt handlers (see lib/x86/isr.h). The git tree is at git://git.kernel.org/pub/scm/virt/kvm/kvm-unit-tests.git. Paolo