[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 18/38] ivshmem: Leave INTx alone when using MSI-
From: |
Paolo Bonzini |
Subject: |
Re: [Qemu-devel] [PATCH 18/38] ivshmem: Leave INTx alone when using MSI-X |
Date: |
Tue, 1 Mar 2016 18:30:05 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 |
On 01/03/2016 18:14, Marc-André Lureau wrote:
> > + /*
> > + * Note: we don't use INTx with IVSHMEM_MSI at all, so this is a
> > + * bald-faced lie then. But it's a backwards compatible lie.
> > + */
> > pci_config_set_interrupt_pin(pci_conf, 1);
>
> I am not sure how much of a problem this is. Apparently, other devices
> claim interrupt and msi (ich, hda, pvscsi)
>
> Better ask someone more familiar with PCI details.
The interrupt pin is read-only and just helps the OS figure out which
interrupt is routed to intx. If you return early from
ivshmem_update_irq if IVSHMEM_MSI, you should skip this line too.
I think it's better to leave this line in and check
if (msix_enabled(pci_dev)) {
return;
}
in ivshmem_update_irq instead. This matches what xhci does, for example.
Paolo