From nobody Fri Apr 26 03:15:49 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1528866448554586.5479089674742; Tue, 12 Jun 2018 22:07:28 -0700 (PDT) Received: from localhost ([::1]:59980 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSy0E-0006Hm-Sd for importer@patchew.org; Wed, 13 Jun 2018 01:07:26 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49241) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSxyN-0005HR-6V for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSxyK-00029o-Fp for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:31 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:58880 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fSxyJ-000292-QW; Wed, 13 Jun 2018 01:05:28 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 589538A3B6; Wed, 13 Jun 2018 05:05:27 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-116-24.ams2.redhat.com [10.36.116.24]) by smtp.corp.redhat.com (Postfix) with ESMTP id 442142157F45; Wed, 13 Jun 2018 05:05:25 +0000 (UTC) From: Thomas Huth To: qemu-devel@nongnu.org, Paolo Bonzini Date: Wed, 13 Jun 2018 07:05:18 +0200 Message-Id: <1528866321-23886-2-git-send-email-thuth@redhat.com> In-Reply-To: <1528866321-23886-1-git-send-email-thuth@redhat.com> References: <1528866321-23886-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.2]); Wed, 13 Jun 2018 05:05:27 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.2]); Wed, 13 Jun 2018 05:05:27 +0000 (UTC) for IP:'10.11.54.6' DOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'thuth@redhat.com' RCPT:'' X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 66.187.233.73 Subject: [Qemu-devel] [PATCH 1/4] Replace '-machine accel=xyz' with '-accel xyz' X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Eduardo Habkost , Ben Warren , qemu-trivial@nongnu.org, Markus Armbruster , Stefan Hajnoczi , zhang.zhanghailiang@huawei.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" We've got a separate option to configure the accelerator nowadays. Use it in the source and examples to demonstrate that this is the preferred way of setting this option now. Signed-off-by: Thomas Huth Reviewed-by: Stefan Hajnoczi --- qemu-doc.texi | 3 +-- qemu-options.hx | 2 +- scripts/qtest.py | 2 +- tests/bios-tables-test.c | 2 +- tests/boot-serial-test.c | 2 +- tests/libqtest.c | 2 +- tests/migration-test.c | 8 ++++---- tests/migration/guestperf/engine.py | 2 +- tests/pnv-xscom-test.c | 2 +- tests/prom-env-test.c | 2 +- tests/pxe-test.c | 2 +- tests/qemu-iotests/172 | 2 +- tests/qemu-iotests/check | 2 +- tests/vmgenid-test.c | 2 +- 14 files changed, 17 insertions(+), 18 deletions(-) diff --git a/qemu-doc.texi b/qemu-doc.texi index cd05760..1c47e7c 100644 --- a/qemu-doc.texi +++ b/qemu-doc.texi @@ -2793,8 +2793,7 @@ which is the default. =20 @subsection -no-kvm (since 1.3.0) =20 -The ``-no-kvm'' argument is now a synonym for setting -``-machine accel=3Dtcg''. +The ``-no-kvm'' argument is now a synonym for setting ``-accel tcg''. =20 @subsection -vnc tls (since 2.5.0) =20 diff --git a/qemu-options.hx b/qemu-options.hx index c0d3951..451f7a6 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -3922,7 +3922,7 @@ STEXI Enable FIPS 140-2 compliance mode. ETEXI =20 -HXCOMM Deprecated by -machine accel=3Dtcg property +HXCOMM Deprecated by -accel tcg DEF("no-kvm", 0, QEMU_OPTION_no_kvm, "", QEMU_ARCH_I386) =20 DEF("msg", HAS_ARG, QEMU_OPTION_msg, diff --git a/scripts/qtest.py b/scripts/qtest.py index df0daf2..8c074a6 100644 --- a/scripts/qtest.py +++ b/scripts/qtest.py @@ -89,7 +89,7 @@ class QEMUQtestMachine(qemu.QEMUMachine): def _base_args(self): args =3D super(QEMUQtestMachine, self)._base_args() args.extend(['-qtest', 'unix:path=3D' + self._qtest_path, - '-machine', 'accel=3Dqtest']) + '-accel', 'qtest']) return args =20 def _pre_launch(self): diff --git a/tests/bios-tables-test.c b/tests/bios-tables-test.c index 4e24930..f41ec39 100644 --- a/tests/bios-tables-test.c +++ b/tests/bios-tables-test.c @@ -613,7 +613,7 @@ static void test_acpi_one(const char *params, test_data= *data) char *args; =20 /* Disable kernel irqchip to be able to override apic irq0. */ - args =3D g_strdup_printf("-machine %s,accel=3D%s,kernel-irqchip=3Doff " + args =3D g_strdup_printf("-machine %s,kernel-irqchip=3Doff -accel %s " "-net none -display none %s " "-drive id=3Dhd0,if=3Dnone,file=3D%s,format=3Dr= aw " "-device ide-hd,drive=3Dhd0 ", diff --git a/tests/boot-serial-test.c b/tests/boot-serial-test.c index 4d6815c..84a2aa9 100644 --- a/tests/boot-serial-test.c +++ b/tests/boot-serial-test.c @@ -175,7 +175,7 @@ static void test_machine(const void *data) * Make sure that this test uses tcg if available: It is used as a * fast-enough smoketest for that. */ - global_qtest =3D qtest_startf("%s %s -M %s,accel=3Dtcg:kvm " + global_qtest =3D qtest_startf("%s %s -M %s -accel tcg:kvm " "-chardev file,id=3Dserial0,path=3D%s " "-no-shutdown -serial chardev:serial0 %s", codeparam, code ? codetmp : "", diff --git a/tests/libqtest.c b/tests/libqtest.c index 098af6a..51481b0 100644 --- a/tests/libqtest.c +++ b/tests/libqtest.c @@ -209,7 +209,7 @@ QTestState *qtest_init_without_qmp_handshake(bool use_o= ob, "-qtest-log %s " "-chardev socket,path=3D%s,nowait,id=3Dc= har0 " "-mon chardev=3Dchar0,mode=3Dcontrol%s " - "-machine accel=3Dqtest " + "-accel qtest " "-display none " "%s", qemu_binary, socket_path, getenv("QTEST_LOG") ? "/dev/fd/2" : "/de= v/null", diff --git a/tests/migration-test.c b/tests/migration-test.c index 3a85446..2b96ff0 100644 --- a/tests/migration-test.c +++ b/tests/migration-test.c @@ -372,12 +372,12 @@ static void test_migrate_start(QTestState **from, QTe= stState **to, =20 if (strcmp(arch, "i386") =3D=3D 0 || strcmp(arch, "x86_64") =3D=3D 0) { init_bootfile_x86(bootpath); - cmd_src =3D g_strdup_printf("-machine accel=3D%s -m 150M" + cmd_src =3D g_strdup_printf("-accel %s -m 150M" " -name source,debug-threads=3Don" " -serial file:%s/src_serial" " -drive file=3D%s,format=3Draw", accel, tmpfs, bootpath); - cmd_dst =3D g_strdup_printf("-machine accel=3D%s -m 150M" + cmd_dst =3D g_strdup_printf("-accel %s -m 150M" " -name target,debug-threads=3Don" " -serial file:%s/dest_serial" " -drive file=3D%s,format=3Draw" @@ -389,7 +389,7 @@ static void test_migrate_start(QTestState **from, QTest= State **to, if (access("/sys/module/kvm_hv", F_OK)) { accel =3D "tcg"; } - cmd_src =3D g_strdup_printf("-machine accel=3D%s -m 256M" + cmd_src =3D g_strdup_printf("-accel %s -m 256M" " -name source,debug-threads=3Don" " -serial file:%s/src_serial" " -prom-env '" @@ -397,7 +397,7 @@ static void test_migrate_start(QTestState **from, QTest= State **to, "do i c@ 1 + i c! 1000 +loop .\" B\" 0 " "until'", accel, tmpfs, end_address, start_address); - cmd_dst =3D g_strdup_printf("-machine accel=3D%s -m 256M" + cmd_dst =3D g_strdup_printf("-accel %s -m 256M" " -name target,debug-threads=3Don" " -serial file:%s/dest_serial" " -incoming %s", diff --git a/tests/migration/guestperf/engine.py b/tests/migration/guestper= f/engine.py index 398e3f2..cf3d7c8 100644 --- a/tests/migration/guestperf/engine.py +++ b/tests/migration/guestperf/engine.py @@ -286,7 +286,7 @@ class Engine(object): cmdline =3D "'" + cmdline + "'" =20 argv =3D [ - "-machine", "accel=3Dkvm", + "-accel", "kvm", "-cpu", "host", "-kernel", self._kernel, "-initrd", self._initrd, diff --git a/tests/pnv-xscom-test.c b/tests/pnv-xscom-test.c index efb7c83..4f6686c 100644 --- a/tests/pnv-xscom-test.c +++ b/tests/pnv-xscom-test.c @@ -79,7 +79,7 @@ static void test_cfam_id(const void *data) { const PnvChip *chip =3D data; =20 - global_qtest =3D qtest_startf("-M powernv,accel=3Dtcg -cpu %s", + global_qtest =3D qtest_startf("-M powernv -accel tcg -cpu %s", chip->cpu_model); test_xscom_cfam_id(chip); qtest_quit(global_qtest); diff --git a/tests/prom-env-test.c b/tests/prom-env-test.c index 8c867e6..e066269 100644 --- a/tests/prom-env-test.c +++ b/tests/prom-env-test.c @@ -49,7 +49,7 @@ static void test_machine(const void *machine) /* The pseries firmware boots much faster without the default devices = */ extra_args =3D strcmp(machine, "pseries") =3D=3D 0 ? "-nodefaults" : "= "; =20 - global_qtest =3D qtest_startf("-M %s,accel=3Dtcg %s " + global_qtest =3D qtest_startf("-M %s -accel tcg %s " "-prom-env 'use-nvramrc?=3Dtrue' " "-prom-env 'nvramrc=3D%x %x l!' ", (const char *)machine, extra_args, diff --git a/tests/pxe-test.c b/tests/pxe-test.c index 6e36796..a8c4daa 100644 --- a/tests/pxe-test.c +++ b/tests/pxe-test.c @@ -64,7 +64,7 @@ static void test_pxe_one(const testdef_t *test, bool ipv6) char *args; =20 args =3D g_strdup_printf( - "-machine %s,accel=3Dkvm:tcg -nodefaults -boot order=3Dn " + "-machine %s -accel kvm:tcg -nodefaults -boot order=3Dn " "-netdev user,id=3D" NETNAME ",tftp=3D./,bootfile=3D%s,ipv4=3D%s,i= pv6=3D%s " "-device %s,bootindex=3D1,netdev=3D" NETNAME, test->machine, disk, ipv6 ? "off" : "on", ipv6 ? "on" : "off", diff --git a/tests/qemu-iotests/172 b/tests/qemu-iotests/172 index 02c5f79..93742a7 100755 --- a/tests/qemu-iotests/172 +++ b/tests/qemu-iotests/172 @@ -56,7 +56,7 @@ function do_run_qemu() done fi echo quit - ) | $QEMU -machine accel=3Dqtest -nographic -monitor stdio -serial non= e "$@" + ) | $QEMU -accel qtest -nographic -monitor stdio -serial none "$@" echo } =20 diff --git a/tests/qemu-iotests/check b/tests/qemu-iotests/check index aa94c6c..5ffbf5d 100755 --- a/tests/qemu-iotests/check +++ b/tests/qemu-iotests/check @@ -129,7 +129,7 @@ export CACHEMODE=3D"writeback" export QEMU_IO_OPTIONS=3D"" export QEMU_IO_OPTIONS_NO_FMT=3D"" export CACHEMODE_IS_DEFAULT=3Dtrue -export QEMU_OPTIONS=3D"-nodefaults -machine accel=3Dqtest" +export QEMU_OPTIONS=3D"-nodefaults -accel qtest" export VALGRIND_QEMU=3D export IMGKEYSECRET=3D export IMGOPTSSYNTAX=3Dfalse diff --git a/tests/vmgenid-test.c b/tests/vmgenid-test.c index 8d915c6..4324034 100644 --- a/tests/vmgenid-test.c +++ b/tests/vmgenid-test.c @@ -131,7 +131,7 @@ static void read_guid_from_monitor(QemuUUID *guid) static char disk[] =3D "tests/vmgenid-test-disk-XXXXXX"; =20 #define GUID_CMD(guid) \ - "-machine accel=3Dkvm:tcg " \ + "-accel kvm:tcg " \ "-device vmgenid,id=3Dtestvgid,guid=3D%s " \ "-drive id=3Dhd0,if=3Dnone,file=3D%s,format=3Draw " \ "-device ide-hd,drive=3Dhd0 ", guid, disk --=20 1.8.3.1 From nobody Fri Apr 26 03:15:49 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1528866556098164.17151062857965; Tue, 12 Jun 2018 22:09:16 -0700 (PDT) Received: from localhost ([::1]:59991 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSy1v-0007ot-FA for importer@patchew.org; Wed, 13 Jun 2018 01:09:11 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49253) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSxyO-0005HV-3p for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSxyM-0002Ba-DO for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:32 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:44840 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fSxyM-0002Al-67; Wed, 13 Jun 2018 01:05:30 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B4B5540122D7; Wed, 13 Jun 2018 05:05:29 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-116-24.ams2.redhat.com [10.36.116.24]) by smtp.corp.redhat.com (Postfix) with ESMTP id B3B652156601; Wed, 13 Jun 2018 05:05:27 +0000 (UTC) From: Thomas Huth To: qemu-devel@nongnu.org, Paolo Bonzini Date: Wed, 13 Jun 2018 07:05:19 +0200 Message-Id: <1528866321-23886-3-git-send-email-thuth@redhat.com> In-Reply-To: <1528866321-23886-1-git-send-email-thuth@redhat.com> References: <1528866321-23886-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.5]); Wed, 13 Jun 2018 05:05:29 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.5]); Wed, 13 Jun 2018 05:05:29 +0000 (UTC) for IP:'10.11.54.6' DOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'thuth@redhat.com' RCPT:'' X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 66.187.233.73 Subject: [Qemu-devel] [PATCH 2/4] Replace '-enable-kvm' with '-accel kvm' in docs and help texts X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Eduardo Habkost , Ben Warren , qemu-trivial@nongnu.org, Markus Armbruster , Stefan Hajnoczi , zhang.zhanghailiang@huawei.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" The preferred way to select the KVM accelerator is to use "-accel kvm" these days, so let's be consistent in our documentation and help texts. Signed-off-by: Thomas Huth Reviewed-by: Stefan Hajnoczi --- docs/COLO-FT.txt | 8 ++++---- docs/can.txt | 4 ++-- docs/multi-thread-compression.txt | 2 +- docs/multiseat.txt | 2 +- docs/specs/tpm.txt | 8 ++++---- hw/block/dataplane/virtio-blk.c | 4 ++-- hw/scsi/virtio-scsi-dataplane.c | 4 ++-- 7 files changed, 16 insertions(+), 16 deletions(-) diff --git a/docs/COLO-FT.txt b/docs/COLO-FT.txt index e289be2..d7c7dcd 100644 --- a/docs/COLO-FT.txt +++ b/docs/COLO-FT.txt @@ -113,16 +113,16 @@ by using 'x-colo-lost-heartbeat' command. =3D=3D Test procedure =3D=3D 1. Startup qemu Primary: -# qemu-kvm -enable-kvm -m 2048 -smp 2 -qmp stdio -vnc :7 -name primary \ - -device piix3-usb-uhci \ +# qemu-system-x86_64 -accel kvm -m 2048 -smp 2 -qmp stdio -name primary \ + -device piix3-usb-uhci -vnc :7 \ -device usb-tablet -netdev tap,id=3Dhn0,vhost=3Doff \ -device virtio-net-pci,id=3Dnet-pci0,netdev=3Dhn0 \ -drive if=3Dvirtio,id=3Dprimary-disk0,driver=3Dquorum,read-pattern=3Dfif= o,vote-threshold=3D1,\ children.0.file.filename=3D1.raw,\ children.0.driver=3Draw -S Secondary: -# qemu-kvm -enable-kvm -m 2048 -smp 2 -qmp stdio -vnc :7 -name secondary \ - -device piix3-usb-uhci \ +# qemu-system-x86_64 -accel kvm -m 2048 -smp 2 -qmp stdio -name secondary \ + -device piix3-usb-uhci -vnc :7 \ -device usb-tablet -netdev tap,id=3Dhn0,vhost=3Doff \ -device virtio-net-pci,id=3Dnet-pci0,netdev=3Dhn0 \ -drive if=3Dnone,id=3Dsecondary-disk0,file.filename=3D1.raw,driver=3Draw= ,node-name=3Dnode0 \ diff --git a/docs/can.txt b/docs/can.txt index a357105..7ba23b2 100644 --- a/docs/can.txt +++ b/docs/can.txt @@ -52,7 +52,7 @@ The ''kvaser_pci'' board/device model is compatible with = and has been tested wit The tested setup was Linux 4.9 kernel on the host and guest side. Example for qemu-system-x86_64: =20 - qemu-system-x86_64 -enable-kvm -kernel /boot/vmlinuz-4.9.0-4-amd64 \ + qemu-system-x86_64 -accel kvm -kernel /boot/vmlinuz-4.9.0-4-amd64 \ -initrd ramdisk.cpio \ -virtfs local,path=3Dshareddir,security_model=3Dnone,mount_tag=3Dsha= reddir \ -object can-bus,id=3Dcanbus0 \ @@ -104,4 +104,4 @@ Links to other resources Slides http://rtime.felk.cvut.cz/publications/public/rtlws2015-qemu-can-slid= es.pdf (5) Linux SocketCAN utilities - https://github.com/linux-can/can-utils/ \ No newline at end of file + https://github.com/linux-can/can-utils/ diff --git a/docs/multi-thread-compression.txt b/docs/multi-thread-compress= ion.txt index d0caaf7..bb88c6b 100644 --- a/docs/multi-thread-compression.txt +++ b/docs/multi-thread-compression.txt @@ -62,7 +62,7 @@ RAM: 128G NIC: Intel I350 (10/100/1000Mbps) Host OS: CentOS 7 64-bit Guest OS: RHEL 6.5 64-bit -Parameter: qemu-system-x86_64 -enable-kvm -smp 4 -m 4096 +Parameter: qemu-system-x86_64 -accel kvm -smp 4 -m 4096 /share/ia32e_rhel6u5.qcow -monitor stdio =20 There is no additional application is running on the guest when doing diff --git a/docs/multiseat.txt b/docs/multiseat.txt index 807518c..dc28cdb 100644 --- a/docs/multiseat.txt +++ b/docs/multiseat.txt @@ -18,7 +18,7 @@ or =20 Next put together the qemu command line (sdk/gtk): =20 -qemu -enable-kvm -usb $memory $disk $whatever \ +qemu -accel kvm -usb $memory $disk $whatever \ -display [ sdl | gtk ] \ -vga std \ -device usb-tablet diff --git a/docs/specs/tpm.txt b/docs/specs/tpm.txt index c230c4c..70ad4a0 100644 --- a/docs/specs/tpm.txt +++ b/docs/specs/tpm.txt @@ -98,7 +98,7 @@ QEMU files related to the TPM passthrough device: Command line to start QEMU with the TPM passthrough device using the host's hardware TPM /dev/tpm0: =20 -qemu-system-x86_64 -display sdl -enable-kvm \ +qemu-system-x86_64 -display sdl -accel kvm \ -m 1024 -boot d -bios bios-256k.bin -boot menu=3Don \ -tpmdev passthrough,id=3Dtpm0,path=3D/dev/tpm0 \ -device tpm-tis,tpmdev=3Dtpm0 test.img @@ -164,7 +164,7 @@ swtpm socket --tpmstate dir=3D/tmp/mytpm1 \ Command line to start QEMU with the TPM emulator device communicating with the swtpm: =20 -qemu-system-x86_64 -display sdl -enable-kvm \ +qemu-system-x86_64 -display sdl -accel kvm \ -m 1024 -boot d -bios bios-256k.bin -boot menu=3Don \ -chardev socket,id=3Dchrtpm,path=3D/tmp/mytpm1/swtpm-sock \ -tpmdev emulator,id=3Dtpm0,chardev=3Dchrtpm \ @@ -222,7 +222,7 @@ swtpm socket --tpmstate dir=3D/tmp/mytpm1 \ =20 In a 2nd terminal start the VM: =20 -qemu-system-x86_64 -display sdl -enable-kvm \ +qemu-system-x86_64 -display sdl -accel kvm \ -m 1024 -boot d -bios bios-256k.bin -boot menu=3Don \ -chardev socket,id=3Dchrtpm,path=3D/tmp/mytpm1/swtpm-sock \ -tpmdev emulator,id=3Dtpm0,chardev=3Dchrtpm \ @@ -255,7 +255,7 @@ swtpm socket --tpmstate dir=3D/tmp/mytpm1 \ In the 2nd terminal restore the state of the VM using the additonal '-incoming' option. =20 -qemu-system-x86_64 -display sdl -enable-kvm \ +qemu-system-x86_64 -display sdl -accel kvm \ -m 1024 -boot d -bios bios-256k.bin -boot menu=3Don \ -chardev socket,id=3Dchrtpm,path=3D/tmp/mytpm1/swtpm-sock \ -tpmdev emulator,id=3Dtpm0,chardev=3Dchrtpm \ diff --git a/hw/block/dataplane/virtio-blk.c b/hw/block/dataplane/virtio-bl= k.c index d648aeb..8c37bd3 100644 --- a/hw/block/dataplane/virtio-blk.c +++ b/hw/block/dataplane/virtio-blk.c @@ -190,8 +190,8 @@ int virtio_blk_data_plane_start(VirtIODevice *vdev) /* Set up guest notifier (irq) */ r =3D k->set_guest_notifiers(qbus->parent, nvqs, true); if (r !=3D 0) { - fprintf(stderr, "virtio-blk failed to set guest notifier (%d), " - "ensure -enable-kvm is set\n", r); + error_report("virtio-blk failed to set guest notifier (%d), " + "ensure -accel kvm is set.", r); goto fail_guest_notifiers; } =20 diff --git a/hw/scsi/virtio-scsi-dataplane.c b/hw/scsi/virtio-scsi-dataplan= e.c index 912e500..b995bab 100644 --- a/hw/scsi/virtio-scsi-dataplane.c +++ b/hw/scsi/virtio-scsi-dataplane.c @@ -142,8 +142,8 @@ int virtio_scsi_dataplane_start(VirtIODevice *vdev) /* Set up guest notifier (irq) */ rc =3D k->set_guest_notifiers(qbus->parent, vs->conf.num_queues + 2, t= rue); if (rc !=3D 0) { - fprintf(stderr, "virtio-scsi: Failed to set guest notifiers (%d), " - "ensure -enable-kvm is set\n", rc); + error_report("virtio-scsi: Failed to set guest notifiers (%d), " + "ensure -accel kvm is set.", rc); goto fail_guest_notifiers; } =20 --=20 1.8.3.1 From nobody Fri Apr 26 03:15:49 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1528866626134403.70581044113464; Tue, 12 Jun 2018 22:10:26 -0700 (PDT) Received: from localhost ([::1]:60002 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSy37-00008i-DP for importer@patchew.org; Wed, 13 Jun 2018 01:10:25 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49298) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSxyQ-0005Ih-FK for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:35 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSxyP-0002DD-19 for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:34 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:57128 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fSxyO-0002D2-Jg; Wed, 13 Jun 2018 01:05:32 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 2A6E087A80; Wed, 13 Jun 2018 05:05:32 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-116-24.ams2.redhat.com [10.36.116.24]) by smtp.corp.redhat.com (Postfix) with ESMTP id 16579201CB71; Wed, 13 Jun 2018 05:05:29 +0000 (UTC) From: Thomas Huth To: qemu-devel@nongnu.org, Paolo Bonzini Date: Wed, 13 Jun 2018 07:05:20 +0200 Message-Id: <1528866321-23886-4-git-send-email-thuth@redhat.com> In-Reply-To: <1528866321-23886-1-git-send-email-thuth@redhat.com> References: <1528866321-23886-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 13 Jun 2018 05:05:32 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.1]); Wed, 13 Jun 2018 05:05:32 +0000 (UTC) for IP:'10.11.54.6' DOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'thuth@redhat.com' RCPT:'' X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 66.187.233.73 Subject: [Qemu-devel] [PATCH 3/4] qemu-options: Improve the documentation of '-accel' and '-machine accel=...' X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Eduardo Habkost , Ben Warren , qemu-trivial@nongnu.org, Markus Armbruster , Stefan Hajnoczi , zhang.zhanghailiang@huawei.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Instead of repeating the same text for both options, let's rather change the '-machine accel' documentation to point to the preferred '-accel' option instead. And in the documenation of the -accel option, make it clear that you can use colons to specify multiple accelerators. Signed-off-by: Thomas Huth Reviewed-by: Stefan Hajnoczi --- qemu-options.hx | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/qemu-options.hx b/qemu-options.hx index 451f7a6..0ec9cac 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -30,8 +30,7 @@ ETEXI DEF("machine", HAS_ARG, QEMU_OPTION_machine, \ "-machine [type=3D]name[,prop[=3Dvalue][,...]]\n" " selects emulated machine ('-machine help' for list)\n" - " property accel=3Daccel1[:accel2[:...]] selects accele= rator\n" - " supported accelerators are kvm, xen, hax, hvf, whpx o= r tcg (default: tcg)\n" + " property accel=3Daccel1[:accel2[:...]] selects accele= rator (see -accel)\n" " kernel_irqchip=3Don|off|split controls accelerated ir= qchip support (default=3Doff)\n" " vmport=3Don|off|auto controls emulation of vmport (de= fault: auto)\n" " kvm_shadow_mem=3Dsize of KVM shadow MMU in bytes\n" @@ -66,10 +65,8 @@ of QEMU will support machine types from many previous ve= rsions. Supported machine properties are: @table @option @item accel=3D@var{accels1}[:@var{accels2}[:...]] -This is used to enable an accelerator. Depending on the target architectur= e, -kvm, xen, hax, hvf, whpx or tcg can be available. By default, tcg is used.= If there is -more than one accelerator specified, the next one is used if the previous = one -fails to initialize. +This can be used to enable an accelerator. See the preferred @code{-accel} +option for a list of available accelerators. @item kernel_irqchip=3Don|off Controls in-kernel irqchip support for the chosen accelerator when availab= le. @item gfx_passthru=3Don|off @@ -128,16 +125,17 @@ Select CPU model (@code{-cpu help} for list and addit= ional feature selection) ETEXI =20 DEF("accel", HAS_ARG, QEMU_OPTION_accel, - "-accel [accel=3D]accelerator[,thread=3Dsingle|multi]\n" + "-accel [accel=3D]accelerator[:accelerator[:...]][,thread=3Dsingle|mul= ti]\n" " select accelerator (kvm, xen, hax, hvf, whpx or tcg; = use 'help' for a list)\n" - " thread=3Dsingle|multi (enable multi-threaded TCG)", Q= EMU_ARCH_ALL) + " thread=3Dsingle|multi (enable multi-threaded TCG)\n",= QEMU_ARCH_ALL) STEXI @item -accel @var{name}[,prop=3D@var{value}[,...]] @findex -accel This is used to enable an accelerator. Depending on the target architectur= e, -kvm, xen, hax, hvf, whpx or tcg can be available. By default, tcg is used.= If there is -more than one accelerator specified, the next one is used if the previous = one -fails to initialize. +kvm, xen, hax, hvf, whpx or tcg can be available. By default, tcg is used. +Multiple accelerators can be specified by separating them with a colon. If +there is more than one accelerator specified, the next one is used if the +previous one fails to initialize. @table @option @item thread=3Dsingle|multi Controls number of TCG threads. When the TCG is multi-threaded there will = be one --=20 1.8.3.1 From nobody Fri Apr 26 03:15:49 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1528866472355830.1854470472316; Tue, 12 Jun 2018 22:07:52 -0700 (PDT) Received: from localhost ([::1]:59981 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSy0d-0006c4-In for importer@patchew.org; Wed, 13 Jun 2018 01:07:51 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49334) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fSxyT-0005Kj-1L for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fSxyR-0002HS-LB for qemu-devel@nongnu.org; Wed, 13 Jun 2018 01:05:36 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:60928 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fSxyR-0002Fx-2l; Wed, 13 Jun 2018 01:05:35 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 9823A400141C; Wed, 13 Jun 2018 05:05:34 +0000 (UTC) Received: from thh440s.redhat.com (ovpn-116-24.ams2.redhat.com [10.36.116.24]) by smtp.corp.redhat.com (Postfix) with ESMTP id 85F90201CB71; Wed, 13 Jun 2018 05:05:32 +0000 (UTC) From: Thomas Huth To: qemu-devel@nongnu.org, Paolo Bonzini Date: Wed, 13 Jun 2018 07:05:21 +0200 Message-Id: <1528866321-23886-5-git-send-email-thuth@redhat.com> In-Reply-To: <1528866321-23886-1-git-send-email-thuth@redhat.com> References: <1528866321-23886-1-git-send-email-thuth@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.6 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.7]); Wed, 13 Jun 2018 05:05:34 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.7]); Wed, 13 Jun 2018 05:05:34 +0000 (UTC) for IP:'10.11.54.6' DOMAIN:'int-mx06.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'thuth@redhat.com' RCPT:'' X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 66.187.233.73 Subject: [Qemu-devel] [RFC PATCH 4/4] qemu-options: Do not show -enable-kvm and -enable-hax in the docs anymore X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Eduardo Habkost , Ben Warren , qemu-trivial@nongnu.org, Markus Armbruster , Stefan Hajnoczi , zhang.zhanghailiang@huawei.com Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" We've got three ways of enabling an accelerator: -machine accel=3Dxyz, -accel xyz and -enable-xyz. For new QEMU users, this must be very confusing ("Which one do I have to use? Is there a difference between the options?"). While -enable-kvm was useful in the past, there is no real good reason for using it anymore today ("-accel kvm" is even less to type than "-enable-kvm"), so let's decrease the confusing amount of options in our documenation a little bit by removing the -enable-xyz here. Note that the option itself is neither removed nor marked as deprecated - since -enable-kvm is likely used in a lot of scripts and since its code is easy to maintain, we should keep it around to avoid to break old setups. Signed-off-by: Thomas Huth --- PS: I guess Paolo won't like this patch ... let's try it anyway ;-) qemu-options.hx | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/qemu-options.hx b/qemu-options.hx index 0ec9cac..f33a81e 100644 --- a/qemu-options.hx +++ b/qemu-options.hx @@ -3414,25 +3414,11 @@ STEXI Set the filename for the BIOS. ETEXI =20 -DEF("enable-kvm", 0, QEMU_OPTION_enable_kvm, \ - "-enable-kvm enable KVM full virtualization support\n", QEMU_ARCH_= ALL) -STEXI -@item -enable-kvm -@findex -enable-kvm -Enable KVM full virtualization support. This option is only available -if KVM support is enabled when compiling. -ETEXI +HXCOMM -accel kvm should be used instead, thus this is not documented anym= ore +DEF("enable-kvm", 0, QEMU_OPTION_enable_kvm, "", QEMU_ARCH_ALL) =20 -DEF("enable-hax", 0, QEMU_OPTION_enable_hax, \ - "-enable-hax enable HAX virtualization support\n", QEMU_ARCH_I386) -STEXI -@item -enable-hax -@findex -enable-hax -Enable HAX (Hardware-based Acceleration eXecution) support. This option -is only available if HAX support is enabled when compiling. HAX is only -applicable to MAC and Windows platform, and thus does not conflict with -KVM. -ETEXI +HXCOMM -accel hax should be used instead, thus this is not documented anym= ore +DEF("enable-hax", 0, QEMU_OPTION_enable_hax, "", QEMU_ARCH_I386) =20 DEF("xen-domid", HAS_ARG, QEMU_OPTION_xen_domid, "-xen-domid id specify xen guest domain id\n", QEMU_ARCH_ALL) --=20 1.8.3.1