diff options
author | Gerd Hoffmann <kraxel@redhat.com> | 2014-11-04 13:59:59 +0100 |
---|---|---|
committer | Gerd Hoffmann <kraxel@redhat.com> | 2014-12-16 14:15:29 +0100 |
commit | 0b2824e5e48a787be3edbfc897244b4621e5bd61 (patch) | |
tree | 5fcabf22c523190cf19655638eeb327370d46308 /hw/display/qxl.c | |
parent | dfa9c2a0f4d0a0c8b2c1449ecdbb1297427e1560 (diff) |
spice: use bottom half instead of refresh timer for cursor updates
Calling directly doesn't work due to the qxl-render code running in
spice server thread context. Meanwhile bottom half scheduling is
thread-safe though, so we can use that to kick a cursor update in
main i/o thread context.
Cc: Marc-André Lureau <marcandre.lureau@gmail.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/display/qxl.c')
-rw-r--r-- | hw/display/qxl.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/hw/display/qxl.c b/hw/display/qxl.c index b540dd656c..5151bac32d 100644 --- a/hw/display/qxl.c +++ b/hw/display/qxl.c @@ -1861,10 +1861,6 @@ static void display_refresh(DisplayChangeListener *dcl) if (qxl->mode == QXL_MODE_VGA) { qemu_spice_display_refresh(&qxl->ssd); - } else { - qemu_mutex_lock(&qxl->ssd.lock); - qemu_spice_cursor_refresh_unlocked(&qxl->ssd); - qemu_mutex_unlock(&qxl->ssd.lock); } } @@ -2025,6 +2021,7 @@ static int qxl_init_common(PCIQXLDevice *qxl) qxl_reset_state(qxl); qxl->update_area_bh = qemu_bh_new(qxl_render_update_area_bh, qxl); + qxl->ssd.cursor_bh = qemu_bh_new(qemu_spice_cursor_refresh_bh, &qxl->ssd); return 0; } |