qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] virtio-pci: Clear IRQ at reset


From: Fam Zheng
Subject: Re: [Qemu-devel] [PATCH] virtio-pci: Clear IRQ at reset
Date: Thu, 12 Mar 2015 15:58:26 +0800
User-agent: Mutt/1.5.23 (2014-03-12)

On Thu, 03/12 08:22, Michael S. Tsirkin wrote:
> On Thu, Mar 12, 2015 at 02:40:55PM +0800, Fam Zheng wrote:
> > Currently we could leave PCI IRQ asserted even after reset, it is safer
> > to clear it.
> > 
> > In the case that a buggy driver has disabled MSI-X unintentially, we may
> > have already injected IRQ in previous virtio_pci_notify, which will not
> > be cleared by guest because it doesn't expect it (i.e. no irq handler).
> > However the driver may eventually notice the unresponsiveness and reset
> > the device, at that point, clearing the irq is meaningful.
> > 
> > Signed-off-by: Fam Zheng <address@hidden>
> 
> I don't get it. interrupts are de-asserted
> in pci core:
> 
> static void pci_do_device_reset(PCIDevice *dev)
> {   
>     int r;
>     
>     pci_device_deassert_intx(dev);
> 
> ...
> }
> 
> why isn't this sufficient?

Becuase it's not called by virtio_pci_reset.

Fam



reply via email to

[Prev in Thread] Current Thread [Next in Thread]