From patchwork Wed Jan 15 02:39:42 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Marek_Marczykowski-G=C3=B3recki?= X-Patchwork-Id: 11333197 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1D41992A for ; Wed, 15 Jan 2020 02:41:31 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id EE0EF222C3 for ; Wed, 15 Jan 2020 02:41:30 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="gw2ErxTX" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EE0EF222C3 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=invisiblethingslab.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1irYbf-0004ug-RX; Wed, 15 Jan 2020 02:40:31 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1irYbe-0004u5-G4 for xen-devel@lists.xenproject.org; Wed, 15 Jan 2020 02:40:30 +0000 X-Inumbo-ID: 5c30353a-3740-11ea-b89f-bc764e2007e4 Received: from out2-smtp.messagingengine.com (unknown [66.111.4.26]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 5c30353a-3740-11ea-b89f-bc764e2007e4; Wed, 15 Jan 2020 02:40:15 +0000 (UTC) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 2FA1E221FC; Tue, 14 Jan 2020 21:40:15 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Tue, 14 Jan 2020 21:40:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm1; bh=hFatBVEceU0YzlJ8V5KA/QLgh7H6lFP0ti2NWesmG X0=; b=gw2ErxTX2wC7Qd44F0v3kByzrr/MP6mymoJOOIof7Vn3oNlWMpMVb2b91 dtP7VrYn6NQOzpAAQ/d5wKinR/zhOKX0S+/2sbc7jSCzkK3CA0oJdKHLhOwgrMsh UzpnZ0WZbyLwUuPMPGoRl3va0U4QGYzK3fgnl3yb3pDo/4RHCFqchFaJ8teGQXKY VF6NlB/cDVGI3dqBQ8a1qw9WswCPW50mKnY7hNSHCS6xvHa6aaCb2X1eyjnGeD5o GR4nEi6Q3EnfbETelHnQm6gDsaK9KuCiHLmC3BTJYqFUbeKvijPwi914REVPBW4k 8WyqHoFjrQqegr9Tka5X/S7UFCgug== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedrtddvgdegkecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkofgjfhggtgfgsehtkeertdertdejnecuhfhrohhmpeforghrvghk ucforghrtgiihihkohifshhkihdqifpkrhgvtghkihcuoehmrghrmhgrrhgvkhesihhnvh hishhisghlvghthhhinhhgshhlrggsrdgtohhmqeenucfkphepledurdeihedrfeegrdef feenucfrrghrrghmpehmrghilhhfrhhomhepmhgrrhhmrghrvghksehinhhvihhsihgslh gvthhhihhnghhslhgrsgdrtghomhenucevlhhushhtvghrufhiiigvpedt X-ME-Proxy: Received: from localhost.localdomain (ip5b412221.dynamic.kabel-deutschland.de [91.65.34.33]) by mail.messagingengine.com (Postfix) with ESMTPA id 17C7E3060783; Tue, 14 Jan 2020 21:40:14 -0500 (EST) From: =?utf-8?q?Marek_Marczykowski-G=C3=B3recki?= To: xen-devel@lists.xenproject.org Date: Wed, 15 Jan 2020 03:39:42 +0100 Message-Id: <763f8aec657f880b29e495d4158db49c2afddbbe.1579055705.git-series.marmarek@invisiblethingslab.com> X-Mailer: git-send-email 2.21.0 In-Reply-To: References: MIME-Version: 1.0 Subject: [Xen-devel] [PATCH v4 03/16] libxl: fix qemu-trad cmdline for no sdl/vnc case X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Wei Liu , Wei Liu , Jason Andryuk , Ian Jackson , =?utf-8?q?Marek_Marczykowski-G=C3=B3recki?= , Anthony PERARD Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" When qemu is running in stubdomain, any attempt to initialize vnc/sdl there will crash it (on failed attempt to load a keymap from a file). If vfb is present, all those cases are skipped. But since b053f0c4c9e533f3d97837cf897eb920b8355ed3 "libxl: do not start dom0 qemu for stubdomain when not needed" it is possible to create a stubdomain without vfb and contrary to the comment -vnc none do trigger VNC initialization code (just skips exposing it externally). Change the implicit SDL avoiding method to -nographics option, used when none of SDL or VNC is enabled. Signed-off-by: Marek Marczykowski-Górecki Reviewed-by: Jason Andryuk Acked-by: Ian Jackson Acked-by: Wei Liu --- Changes in v2: - typo in qemu option Changes in v3: - add missing { } --- tools/libxl/libxl_dm.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/tools/libxl/libxl_dm.c b/tools/libxl/libxl_dm.c index e92e412..558cb41 100644 --- a/tools/libxl/libxl_dm.c +++ b/tools/libxl/libxl_dm.c @@ -718,14 +718,15 @@ static int libxl__build_device_model_args_old(libxl__gc *gc, if (libxl_defbool_val(vnc->findunused)) { flexarray_append(dm_args, "-vncunused"); } - } else + } else if (!sdl) { /* * VNC is not enabled by default by qemu-xen-traditional, - * however passing -vnc none causes SDL to not be - * (unexpectedly) enabled by default. This is overridden by - * explicitly passing -sdl below as required. + * however skipping -vnc causes SDL to be + * (unexpectedly) enabled by default. If undesired, disable graphics at + * all. */ - flexarray_append_pair(dm_args, "-vnc", "none"); + flexarray_append(dm_args, "-nographic"); + } if (sdl) { flexarray_append(dm_args, "-sdl");