diff mbox

[2/2] qxl: clear irq on reset

Message ID 1390214659-12296-2-git-send-email-alevy@redhat.com
State New
Headers show

Commit Message

Alon Levy Jan. 20, 2014, 10:44 a.m. UTC
Without this we occasionally trigger an assert at
hw/pci/pci.c:pcibus_reset that asserts the irq_count is zero on reset.

This has become a problem with the new drm driver for linux, since doing
a reboot from console causes a race between console updates that set the
irq and the reset assertion that the irq is clear.

Signed-off-by: Alon Levy <alevy@redhat.com>
---
 hw/display/qxl.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Gerd Hoffmann Jan. 21, 2014, 10:56 a.m. UTC | #1
On Mo, 2014-01-20 at 12:44 +0200, Alon Levy wrote:
> Without this we occasionally trigger an assert at
> hw/pci/pci.c:pcibus_reset that asserts the irq_count is zero on reset.
> 
> This has become a problem with the new drm driver for linux, since
> doing
> a reboot from console causes a race between console updates that set
> the
> irq and the reset assertion that the irq is clear.
> 

Added to spice patch queue.

thanks,
  Gerd
diff mbox

Patch

diff --git a/hw/display/qxl.c b/hw/display/qxl.c
index f6af470..e164d96 100644
--- a/hw/display/qxl.c
+++ b/hw/display/qxl.c
@@ -1126,6 +1126,7 @@  static void qxl_reset_state(PCIQXLDevice *d)
     d->num_free_res = 0;
     d->last_release = NULL;
     memset(&d->ssd.dirty, 0, sizeof(d->ssd.dirty));
+    qxl_update_irq(d);
 }
 
 static void qxl_soft_reset(PCIQXLDevice *d)