From patchwork Wed Jan 16 16:49:15 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Roth X-Patchwork-Id: 212899 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 2058E2C007A for ; Thu, 17 Jan 2013 04:58:18 +1100 (EST) Received: from localhost ([::1]:55444 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TvWHK-0004nS-Jg for incoming@patchwork.ozlabs.org; Wed, 16 Jan 2013 11:55:54 -0500 Received: from eggs.gnu.org ([208.118.235.92]:49276) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TvWGv-0004Fm-OK for qemu-devel@nongnu.org; Wed, 16 Jan 2013 11:55:32 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TvWGn-00071u-60 for qemu-devel@nongnu.org; Wed, 16 Jan 2013 11:55:29 -0500 Received: from mail-ie0-f181.google.com ([209.85.223.181]:59915) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TvWGn-00071h-2S; Wed, 16 Jan 2013 11:55:21 -0500 Received: by mail-ie0-f181.google.com with SMTP id 16so2927610iea.12 for ; Wed, 16 Jan 2013 08:55:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references; bh=1aR9SXGUFsG/f6NpTheMiJXfBmEhjZYUIe816nmM/jI=; b=Wm5NS1pavAHAZFD+MAqYP8yCmeYpMbPQT4Cz52K10t05HJjHVACVzC5LPXx+4DDXa7 SaluI1X7W8/+1yBX1woTJPrIp6QttkLQLmIoEtrD6VW+l+1ivfL36EL2fH42u/JjcyWc Apm4UWl8cPpQq9GYUxCj1FYIPrgXzBCMpwn70etFBnbLtEf87y5VIS1eeVqXsuVcaT+C 4j83kMR/HF0UES7gNqVKMEWWTKftx92p/I9t0JigxPuwBQFOytDc9mYSG4kWg0msGi1u uBKcgbGLKvZgSbwe5hxNxgv+NyvYte2S5nEFfKy+Lf9zPMfZtKRIVDzOxHIxPTncm4qc dC0A== X-Received: by 10.50.179.73 with SMTP id de9mr1235169igc.85.1358355320371; Wed, 16 Jan 2013 08:55:20 -0800 (PST) Received: from localhost ([32.97.110.59]) by mx.google.com with ESMTPS id kf2sm5189934igc.0.2013.01.16.08.55.19 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Wed, 16 Jan 2013 08:55:19 -0800 (PST) From: Michael Roth To: qemu-devel@nongnu.org Date: Wed, 16 Jan 2013 10:49:15 -0600 Message-Id: <1358354963-9070-14-git-send-email-mdroth@linux.vnet.ibm.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1358354963-9070-1-git-send-email-mdroth@linux.vnet.ibm.com> References: <1358354963-9070-1-git-send-email-mdroth@linux.vnet.ibm.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 209.85.223.181 Cc: aliguori@us.ibm.com, qemu-stable@nongnu.org Subject: [Qemu-devel] [PATCH 13/21] qxl+vnc: register a vm state change handler for dummy spice_server X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Uri Lublin When qxl + vnc are used, a dummy spice_server is initialized. The spice_server has to be told when the VM runstate changes, which is what this patch does. Without it, from qxl_send_events(), the following error message is shown: qxl_send_events: spice-server bug: guest stopped, ignoring Cc: qemu-stable@nongnu.org Signed-off-by: Uri Lublin Signed-off-by: Gerd Hoffmann (cherry picked from commit 938b8a36b65e44c44ca29245437f8d7ac0f826e8) Signed-off-by: Michael Roth --- ui/spice-core.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ui/spice-core.c b/ui/spice-core.c index 261c6f2..59ce5f6 100644 --- a/ui/spice-core.c +++ b/ui/spice-core.c @@ -732,6 +732,8 @@ int qemu_spice_add_interface(SpiceBaseInstance *sin) */ spice_server = spice_server_new(); spice_server_init(spice_server, &core_interface); + qemu_add_vm_change_state_handler(vm_change_state_handler, + &spice_server); } return spice_server_add_interface(spice_server, sin);