]> Pileus Git - ~andy/linux/commit
xen/pciback: Allocate IRQ handler for device that is shared with guest.
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Tue, 19 Jul 2011 22:56:39 +0000 (18:56 -0400)
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Wed, 20 Jul 2011 00:58:31 +0000 (20:58 -0400)
commit0513fe9e5b54e47e37217ea078dd870e3825e02d
treebec70fca92b64ea535539fc243b746c3a1ab7fd3
parenta2be65fd363831502afdf0babdf48149b3959cde
xen/pciback: Allocate IRQ handler for device that is shared with guest.

If the device that is to be shared with a guest is a level device and
the IRQ is shared with the initial domain we need to take actions.
Mainly we install a dummy IRQ handler that will ACK on the interrupt
line so as to not have the initial domain disable the interrupt line.

This dummy IRQ handler is not enabled when the device MSI/MSI-X lines
are set, nor for edge interrupts. And also not for level interrupts
that are not shared amongst devices. Lastly, if the user passes
to the guest all of the PCI devices on the shared line the we won't
install the dummy handler either.

There is also SysFS instrumentation to check its state and turn
IRQ ACKing on/off if necessary.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
drivers/xen/xen-pciback/conf_space_capability_msi.c
drivers/xen/xen-pciback/conf_space_header.c
drivers/xen/xen-pciback/pci_stub.c
drivers/xen/xen-pciback/pciback.h
drivers/xen/xen-pciback/pciback_ops.c