aboutsummaryrefslogtreecommitdiff
path: root/hw/display/qxl.c
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2015-05-12 11:54:34 +0200
committerGerd Hoffmann <kraxel@redhat.com>2015-05-29 09:56:01 +0200
commit641381c1fcd66ea8de07ecfcd733089da26cbba9 (patch)
treefdea004f85ee6034b334e5dc30f65afa9c870f7e /hw/display/qxl.c
parente95e203c085b7731746e39c9b9f8bd2f6eaa0cd6 (diff)
spice: don't update mm_time when spice-server is stopped.
Skip mm_time updates (in qxl device memory) in case the guest is stopped. Guest isn't able to look anyway, and it causes problems with migration. Also make sure the initial state for spice server is stopped. Reported-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/display/qxl.c')
-rw-r--r--hw/display/qxl.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/display/qxl.c b/hw/display/qxl.c
index 8f40dfb8ac..b220e2d5d2 100644
--- a/hw/display/qxl.c
+++ b/hw/display/qxl.c
@@ -504,6 +504,10 @@ static void interface_set_mm_time(QXLInstance *sin, uint32_t mm_time)
{
PCIQXLDevice *qxl = container_of(sin, PCIQXLDevice, ssd.qxl);
+ if (!qemu_spice_display_is_running(&qxl->ssd)) {
+ return;
+ }
+
trace_qxl_interface_set_mm_time(qxl->id, mm_time);
qxl->shadow_rom.mm_clock = cpu_to_le32(mm_time);
qxl->rom->mm_clock = cpu_to_le32(mm_time);