From nobody Thu Nov 13 03:18:54 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1576515139; cv=none; d=zohomail.com; s=zohoarc; b=RJWr6PLYshlJ/4HcNGvkSM1qAR8+3X3rPaqUxYFOkqtq+zRDCivQg0HLQpZTlzJ0kEyc+1eGNc3hJVlOdbLzQya1OQ2CDDbh81EjZTrIziDDuTUZ+i22+a4hviE1IwtRWzOC4oX5+uVjjQdQY2M+pP7o93YP4iorJY7djo9D9Q4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1576515139; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=pjbTZJVQkWoecdrgqsxX2UzKvVamT9j+zNM3ivmXyv0=; b=KTya6EH2AYUuMzDcjT5IeTvXIUNW9Vrtq3ucSd09PjazJjM1mAvFE++ENeztofiMouH5kq0PgEn+VqlfK1Bw8nuRAIn1PyirIrGxIIe/hH8+zQqo+t4EW9hY6IHbtDNqIZiG+OM7KDVEkbvrIpkVVgjvw7DQPLbUo10xIBifBSE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1576515139539109.3994118739082; Mon, 16 Dec 2019 08:52:19 -0800 (PST) Received: from localhost ([::1]:56862 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1igtbV-0007TN-Ue for importer@patchew.org; Mon, 16 Dec 2019 11:52:17 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:56703) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1igtF7-0004zx-Ta for qemu-devel@nongnu.org; Mon, 16 Dec 2019 11:29:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1igtF6-0007Oa-Te for qemu-devel@nongnu.org; Mon, 16 Dec 2019 11:29:09 -0500 Received: from mail-wr1-x443.google.com ([2a00:1450:4864:20::443]:33011) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1igtF6-0007N0-NR for qemu-devel@nongnu.org; Mon, 16 Dec 2019 11:29:08 -0500 Received: by mail-wr1-x443.google.com with SMTP id b6so8071166wrq.0 for ; Mon, 16 Dec 2019 08:29:08 -0800 (PST) Received: from 640k.lan ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id q68sm19962334wme.14.2019.12.16.08.29.06 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 16 Dec 2019 08:29:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=pjbTZJVQkWoecdrgqsxX2UzKvVamT9j+zNM3ivmXyv0=; b=Y8IFiy+eT1SteUHtWczyl6GHl2CI3iEysPHnG5JRyIpsM6WMrQVhuohLDzlFnhCV62 dg6izOUGj3fzHCLh/mcGRQm+YXu9J7MEK+CjbeG19NZ3j4ngGMyPtR4sN4NZ0kEWGukX eg7S1h/iH2A5vHZ2lqpnG5NtXDislmFyOujAS5p/vqFFe9w9T+WOeEiFylTJbRVfzuwp cQT6ToUv2VMK5fPmyHGjGHVBcxovnCJcgkEoE641gDBJffeJzqZrPIYUo56+pXozGidC D4FmmcPClXeU4W4vrk/VGaBtsE4KWcN8c7EszCRzMguasuJGdbqCnYgTz/KnHPsYAd83 heMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=pjbTZJVQkWoecdrgqsxX2UzKvVamT9j+zNM3ivmXyv0=; b=bDP3wNWUHbpW1+RaRlg9CXWwPb+5Ln4bO2rDSHDAa5nW/knkdKhhaU5CpeRItK/1/2 Zq3k+AD+hm5vJdqD0XG3kgtu2qzJ5+dX701upp21z0D0VhW75fpygTtkvwQtfgK6sZfs +AK24XOnZ2GMRALF7JskSHrTavXwof6KcLT9wHmjG5Pn3rKoU0fIGAMFeTh1WP6xr5M7 YTL9HQJgHYO8uPixC2XqZsYXKyTT6E+HEjEUFOLvKETIIdqFDa1FW5wH4jU3yEsqxsaV HQ06+e0lThEI3zFPUUyqiq9p097i/A9lsOlPSqVkL3ZMDODDFBRIuza48Slv0Jm8iXtS s7eQ== X-Gm-Message-State: APjAAAUVEDuq50tgzF7atRJOJ2qc61o5FhdTTzB6mi7oCm2oqHMHT5GE 5Ubsb3Yuao4f08H+DHZ9Z+ov4Ibz X-Google-Smtp-Source: APXvYqxFzQz3KzrPXQa+UM1slSEDO1diog/8M6VnDnnhX3qo6PMbkYitU/G0OovAiGTFGAGlgdj8zg== X-Received: by 2002:adf:f20b:: with SMTP id p11mr30482915wro.195.1576513747579; Mon, 16 Dec 2019 08:29:07 -0800 (PST) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PULL 20/62] vl: warn for unavailable accelerators, clarify messages Date: Mon, 16 Dec 2019 17:28:04 +0100 Message-Id: <1576513726-53700-21-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1576513726-53700-1-git-send-email-pbonzini@redhat.com> References: <1576513726-53700-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::443 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) So far, specifying an accelerator that was not compiled in did not result in an error; fix that. While at it, clarify the mysterious "Back to TCG" message. Reviewed-by: Marc-Andr=C3=A9 Lureau Signed-off-by: Paolo Bonzini --- vl.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/vl.c b/vl.c index 9bd27e1..46e4ec3 100644 --- a/vl.c +++ b/vl.c @@ -2848,6 +2848,8 @@ static int do_configure_accelerator(void *opaque, Qem= uOpts *opts, Error **errp) int ret; =20 if (!ac) { + *p_init_failed =3D true; + error_report("invalid accelerator %s", acc); return 0; } ret =3D accel_init_machine(ac, current_machine); @@ -2902,6 +2904,9 @@ static void configure_accelerators(const char *progna= me) */ if (accel_find(*tmp)) { qemu_opts_parse_noisily(qemu_find_opts("accel"), *tmp, tru= e); + } else { + init_failed =3D true; + error_report("invalid accelerator %s", *tmp); } } } else { @@ -2921,7 +2926,7 @@ static void configure_accelerators(const char *progna= me) =20 if (init_failed) { AccelClass *ac =3D ACCEL_GET_CLASS(current_machine->accelerator); - error_report("Back to %s accelerator", ac->name); + error_report("falling back to %s", ac->name); } =20 if (use_icount && !(tcg_enabled() || qtest_enabled())) { --=20 1.8.3.1