From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181184; cv=none; d=zohomail.com; s=zohoarc; b=SaGBkW1+Ld99UyHpt+U9KO/KE3ZydpcvORP0BCu6xGnkJAt0skuf4rdcUD/Zz8pSBiNZXam0pEFhppBbQflpAS6ErOqUgQMCwO/sy9A5hIRimvkYQLmiKK0HkMQGty1MczP0h5hH/NTAWTgatYerLu/H0i6uf6eaf8C2IG1+VMQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181184; 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=MfkED0IrnHcvVxnzg5hsG6B5M4yy9BCdt71Lks/pfDM=; b=WMfo+uknmQ0TNhJKQpNhuufOTxQIMw9aTPaXfkGgs5lVq7TRWxDEBFr17nZJjbt9RGLAv/ir2NV96gCANXyz0B/TywlJTBJskAk3gQGCOJdxMFAFOrVhD9OibQKeUhJNhQ5aFFX2IzyZJBrtU3TqkOloXxpKiF8aaVcN4hpRFrY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1586181184940596.6181986260144; Mon, 6 Apr 2020 06:53:04 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-264-A0pau-wYNlupDDQ1F4_ZgQ-1; Mon, 06 Apr 2020 09:52:11 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 6E5CB800D5B; Mon, 6 Apr 2020 13:52:06 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3DC5919C4F; Mon, 6 Apr 2020 13:52:06 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id E23F993A72; Mon, 6 Apr 2020 13:52:05 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036Dpchw018325 for ; Mon, 6 Apr 2020 09:51:38 -0400 Received: by smtp.corp.redhat.com (Postfix) id 893145C1BB; Mon, 6 Apr 2020 13:51:38 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id D33D05C1B0 for ; Mon, 6 Apr 2020 13:51:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181183; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=MfkED0IrnHcvVxnzg5hsG6B5M4yy9BCdt71Lks/pfDM=; b=azHiYdoBqFXoFl4rUbDGSl24ND5iHwJG6jj+brROkloN6nHsg+HUSKFnfjsIORrYVVeTyW V9pKtiYjOigXD22FfeyJ64+ie2NhfzK4xMoAu+ADYQzbLvOUlYDh9vlDsNg6Azp+iCQce9 2fM5HSPNAT1L4RmEYpVzAd8Y6nBU94k= X-MC-Unique: A0pau-wYNlupDDQ1F4_ZgQ-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 01/10] qemu: new capabilities flag pcie-root-port.hotplug Date: Mon, 6 Apr 2020 09:51:21 -0400 Message-Id: <20200406135130.3080946-2-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" This caps flag is set when the qemu binary supports the option "hotplug" for pcie-root-port, ioh3420 (Intel pcie-root-port) and xio3130-downstream (Intel pcie-downstream-port). If it's available, it's possible to disable hotplugging/unplugging devices on a particular port by adding ",hotplug=3Doff" to the qemu device commandline. This option first appears in qemu-5.0.0. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- Hi Pavel! These replies files were hand edited, but a proper regeneration from the actual qemu binaries would probably be better. If you still have a setup to easily generate those (or advice on how to do it in the simplest way possible) that would be appreciated! src/qemu/qemu_capabilities.c | 8 + src/qemu/qemu_capabilities.h | 1 + .../caps_2.10.0.aarch64.replies | 142 ++++++++++++-- .../caps_2.10.0.x86_64.replies | 154 ++++++++++++--- .../caps_2.11.0.x86_64.replies | 154 ++++++++++++--- .../caps_2.12.0.aarch64.replies | 158 ++++++++++++--- .../caps_2.12.0.x86_64.replies | 170 +++++++++++++--- .../caps_2.9.0.x86_64.replies | 154 ++++++++++++--- .../caps_3.0.0.x86_64.replies | 170 +++++++++++++--- .../caps_3.1.0.x86_64.replies | 170 +++++++++++++--- .../caps_4.0.0.aarch64.replies | 158 ++++++++++++--- .../caps_4.0.0.ppc64.replies | 150 +++++++++++++-- .../caps_4.0.0.riscv32.replies | 150 +++++++++++++-- .../caps_4.0.0.riscv64.replies | 150 +++++++++++++-- .../caps_4.0.0.x86_64.replies | 170 +++++++++++++--- .../caps_4.1.0.x86_64.replies | 162 +++++++++++++--- .../caps_4.2.0.aarch64.replies | 166 +++++++++++++--- .../caps_4.2.0.ppc64.replies | 150 +++++++++++++-- .../caps_4.2.0.x86_64.replies | 162 +++++++++++++--- .../caps_5.0.0.aarch64.replies | 166 +++++++++++++--- .../caps_5.0.0.ppc64.replies | 150 +++++++++++++-- .../caps_5.0.0.x86_64.replies | 181 +++++++++++++++--- .../caps_5.0.0.x86_64.xml | 1 + 23 files changed, 2713 insertions(+), 484 deletions(-) diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index 994f1fd179..211b3c0ee6 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -571,6 +571,7 @@ VIR_ENUM_IMPL(virQEMUCaps, =20 /* 360 */ "fsdev.multidevs", + "pcie-root-port.hotplug", ); =20 =20 @@ -1323,6 +1324,10 @@ static struct virQEMUCapsStringFlags virQEMUCapsDevi= cePropsVirtioNet[] =3D { { "failover", QEMU_CAPS_VIRTIO_NET_FAILOVER }, }; =20 +static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsPCIeRootPort[] = =3D { + { "hotplug", QEMU_CAPS_PCIE_ROOT_PORT_HOTPLUG }, +}; + static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsSpaprPCIHostBri= dge[] =3D { { "numa_node", QEMU_CAPS_SPAPR_PCI_HOST_BRIDGE_NUMA_NODE }, }; @@ -1564,6 +1569,9 @@ static virQEMUCapsObjectTypeProps virQEMUCapsDevicePr= ops[] =3D { { "nvdimm", virQEMUCapsDevicePropsNVDIMM, G_N_ELEMENTS(virQEMUCapsDevicePropsNVDIMM), QEMU_CAPS_DEVICE_NVDIMM }, + { "pcie-root-port", virQEMUCapsDevicePropsPCIeRootPort, + G_N_ELEMENTS(virQEMUCapsDevicePropsPCIeRootPort), + QEMU_CAPS_DEVICE_PCIE_ROOT_PORT }, }; =20 static struct virQEMUCapsStringFlags virQEMUCapsObjectPropsMemoryBackendFi= le[] =3D { diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index d247e19710..7b957d6185 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -552,6 +552,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for = syntax-check */ =20 /* 360 */ QEMU_CAPS_FSDEV_MULTIDEVS, /* fsdev.multidevs */ + QEMU_CAPS_PCIE_ROOT_PORT_HOTPLUG, /* pcie-root-port.hotplug */ =20 QEMU_CAPS_LAST /* this must always be the last item */ } virQEMUCapsFlags; diff --git a/tests/qemucapabilitiesdata/caps_2.10.0.aarch64.replies b/tests= /qemucapabilitiesdata/caps_2.10.0.aarch64.replies index 73a99a36ea..c75d4ab8a7 100644 --- a/tests/qemucapabilitiesdata/caps_2.10.0.aarch64.replies +++ b/tests/qemucapabilitiesdata/caps_2.10.0.aarch64.replies @@ -4895,10 +4895,120 @@ } =20 { - "execute": "query-machines", + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, "id": "libvirt-29" } =20 +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-29" +} + +{ + "execute": "query-machines", + "id": "libvirt-30" +} + { "return": [ { @@ -5163,12 +5273,12 @@ "cpu-max": 1 } ], - "id": "libvirt-29" + "id": "libvirt-30" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -5334,34 +5444,34 @@ "static": false } ], - "id": "libvirt-30" + "id": "libvirt-31" } =20 { "execute": "query-tpm-models", - "id": "libvirt-31" + "id": "libvirt-32" } =20 { "return": [ ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { "execute": "query-tpm-types", - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "return": [ ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-command-line-options", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6506,12 +6616,12 @@ "option": "drive" } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -6561,12 +6671,12 @@ "capability": "return-path" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -16289,12 +16399,12 @@ "meta-type": "object" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-gic-capabilities", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -16310,7 +16420,7 @@ "kernel": true } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_2.10.0.x86_64.replies b/tests/= qemucapabilitiesdata/caps_2.10.0.x86_64.replies index 8f96b4c567..d5deea9b3c 100644 --- a/tests/qemucapabilitiesdata/caps_2.10.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_2.10.0.x86_64.replies @@ -4448,10 +4448,120 @@ } =20 { - "execute": "query-machines", + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, "id": "libvirt-35" } =20 +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + +{ + "execute": "query-machines", + "id": "libvirt-36" +} + { "return": [ { @@ -4638,12 +4748,12 @@ "alias": "q35" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4978,36 +5088,36 @@ "migration-safe": true } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-models", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ "tpm-tis" ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-tpm-types", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "return": [ "passthrough" ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-command-line-options", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -6286,12 +6396,12 @@ "option": "drive" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -6341,12 +6451,12 @@ "capability": "return-path" } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -16069,7 +16179,7 @@ "meta-type": "object" } ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -16080,7 +16190,7 @@ "name": "host" } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -16259,7 +16369,7 @@ } } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -16440,7 +16550,7 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -16683,7 +16793,7 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -16697,7 +16807,7 @@ } } }, - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -16876,7 +16986,7 @@ } } }, - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -17057,7 +17167,7 @@ } } }, - "id": "libvirt-45" + "id": "libvirt-46" } =20 { @@ -17300,7 +17410,7 @@ } } }, - "id": "libvirt-45" + "id": "libvirt-46" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_2.11.0.x86_64.replies b/tests/= qemucapabilitiesdata/caps_2.11.0.x86_64.replies index d91f01b55d..75ca78f75e 100644 --- a/tests/qemucapabilitiesdata/caps_2.11.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_2.11.0.x86_64.replies @@ -4475,10 +4475,120 @@ } =20 { - "execute": "query-machines", + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, "id": "libvirt-35" } =20 +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + +{ + "execute": "query-machines", + "id": "libvirt-36" +} + { "return": [ { @@ -4665,12 +4775,12 @@ "cpu-max": 288 } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4984,24 +5094,24 @@ "migration-safe": true } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-models", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ "tpm-tis" ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-tpm-types", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -5009,12 +5119,12 @@ "passthrough", "emulator" ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-command-line-options", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -6309,12 +6419,12 @@ "option": "drive" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -6372,12 +6482,12 @@ "capability": "x-multifd" } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -16245,7 +16355,7 @@ "meta-type": "object" } ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -16256,7 +16366,7 @@ "name": "host" } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -16436,7 +16546,7 @@ } } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -16618,7 +16728,7 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -16863,7 +16973,7 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -16877,7 +16987,7 @@ } } }, - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -17057,7 +17167,7 @@ } } }, - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -17239,7 +17349,7 @@ } } }, - "id": "libvirt-45" + "id": "libvirt-46" } =20 { @@ -17484,7 +17594,7 @@ } } }, - "id": "libvirt-45" + "id": "libvirt-46" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.replies b/tests= /qemucapabilitiesdata/caps_2.12.0.aarch64.replies index 87414a9bca..b99913ed37 100644 --- a/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.replies +++ b/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.replies @@ -5251,12 +5251,122 @@ "id": "libvirt-28" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-29" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-29" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-29" + "id": "libvirt-30" } =20 { @@ -5310,7 +5420,7 @@ "type": "string" } ], - "id": "libvirt-29" + "id": "libvirt-30" } =20 { @@ -5318,7 +5428,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -5372,7 +5482,7 @@ "type": "string" } ], - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -5380,7 +5490,7 @@ "arguments": { "typename": "max-arm-cpu" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -5495,12 +5605,12 @@ "type": "child" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { "execute": "query-machines", - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -5797,7 +5907,7 @@ "cpu-max": 1 } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -5805,7 +5915,7 @@ "arguments": { "typename": "virt-2.12-machine" }, - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -5935,12 +6045,12 @@ "type": "bool" } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -6116,35 +6226,35 @@ "static": false } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-tpm-models", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "return": [ ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-types", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ "emulator" ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-command-line-options", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -7309,12 +7419,12 @@ "option": "drive" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -7376,12 +7486,12 @@ "capability": "dirty-bitmaps" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -18749,12 +18859,12 @@ "meta-type": "object" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-gic-capabilities", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -18770,7 +18880,7 @@ "kernel": false } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.replies b/tests/= qemucapabilitiesdata/caps_2.12.0.x86_64.replies index b4c243096b..1e3ba0885a 100644 --- a/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.replies @@ -4641,12 +4641,122 @@ "id": "libvirt-34" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-35" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -4700,7 +4810,7 @@ "type": "string" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -4708,7 +4818,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4758,7 +4868,7 @@ "type": "string" } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4766,7 +4876,7 @@ "arguments": { "typename": "max-x86_64-cpu" }, - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -5788,12 +5898,12 @@ "type": "bool" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-machines", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -5992,12 +6102,12 @@ "cpu-max": 255 } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -6511,12 +6621,12 @@ "migration-safe": true } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-tpm-models", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -6524,12 +6634,12 @@ "tpm-crb", "tpm-tis" ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-tpm-types", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -6537,12 +6647,12 @@ "passthrough", "emulator" ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { "execute": "query-command-line-options", - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -7829,12 +7939,12 @@ "option": "drive" } ], - "id": "libvirt-42" + "id": "libvirt-43" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -7896,12 +8006,12 @@ "capability": "dirty-bitmaps" } ], - "id": "libvirt-43" + "id": "libvirt-44" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -19269,12 +19379,12 @@ "meta-type": "object" } ], - "id": "libvirt-44" + "id": "libvirt-45" } =20 { "execute": "query-sev-capabilities", - "id": "libvirt-45" + "id": "libvirt-46" } =20 { @@ -19284,7 +19394,7 @@ "cert-chain": "AQAAAAAOAAAAQAAAAAOAAAAQAAAAAOAAAAQAAAAAOAAAAQAAAAAOAAA= ", "pdh": "AQAAAAAOAAAAQAAAAAOAAAAQAAAAAOAAAAQAAAAAOAAAAQAAAAAOAAAAQAAAAA= OAAA" }, - "id": "libvirt-45" + "id": "libvirt-46" } =20 { @@ -19295,7 +19405,7 @@ "name": "host" } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -19485,7 +19595,7 @@ } } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -19677,7 +19787,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -19932,7 +20042,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -19946,7 +20056,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -20136,7 +20246,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -20328,7 +20438,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { @@ -20583,7 +20693,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_2.9.0.x86_64.replies b/tests/q= emucapabilitiesdata/caps_2.9.0.x86_64.replies index 8f32313b46..5cff9c485b 100644 --- a/tests/qemucapabilitiesdata/caps_2.9.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_2.9.0.x86_64.replies @@ -3992,10 +3992,120 @@ } =20 { - "execute": "query-machines", + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, "id": "libvirt-35" } =20 +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + +{ + "execute": "query-machines", + "id": "libvirt-36" +} + { "return": [ { @@ -4172,12 +4282,12 @@ "cpu-max": 255 } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4459,36 +4569,36 @@ "migration-safe": true } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-models", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ "tpm-tis" ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-tpm-types", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "return": [ "passthrough" ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-command-line-options", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -5737,12 +5847,12 @@ "option": "drive" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -5784,12 +5894,12 @@ "capability": "release-ram" } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -15075,7 +15185,7 @@ "meta-type": "object" } ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -15086,7 +15196,7 @@ "name": "host" } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -15265,7 +15375,7 @@ } } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -15446,7 +15556,7 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -15687,7 +15797,7 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -15701,7 +15811,7 @@ } } }, - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -15880,7 +15990,7 @@ } } }, - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -16061,7 +16171,7 @@ } } }, - "id": "libvirt-45" + "id": "libvirt-46" } =20 { @@ -16302,7 +16412,7 @@ } } }, - "id": "libvirt-45" + "id": "libvirt-46" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_3.0.0.x86_64.replies b/tests/q= emucapabilitiesdata/caps_3.0.0.x86_64.replies index f25e5deb94..c683f672f7 100644 --- a/tests/qemucapabilitiesdata/caps_3.0.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_3.0.0.x86_64.replies @@ -4776,12 +4776,122 @@ } =20 =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-35" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -4831,7 +4941,7 @@ "type": "string" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -4839,7 +4949,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4889,7 +4999,7 @@ "type": "string" } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4897,7 +5007,7 @@ "arguments": { "typename": "max-x86_64-cpu" }, - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -5951,12 +6061,12 @@ "type": "bool" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-machines", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -6165,12 +6275,12 @@ "cpu-max": 255 } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -6607,12 +6717,12 @@ "migration-safe": true } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-tpm-models", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -6620,12 +6730,12 @@ "tpm-crb", "tpm-tis" ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-tpm-types", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -6633,12 +6743,12 @@ "passthrough", "emulator" ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { "execute": "query-command-line-options", - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -7937,12 +8047,12 @@ "option": "drive" } ], - "id": "libvirt-42" + "id": "libvirt-43" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -8012,12 +8122,12 @@ "capability": "late-block-activate" } ], - "id": "libvirt-43" + "id": "libvirt-44" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -19897,16 +20007,16 @@ "meta-type": "object" } ], - "id": "libvirt-44" + "id": "libvirt-45" } =20 { "execute": "query-sev-capabilities", - "id": "libvirt-45" + "id": "libvirt-46" } =20 { - "id": "libvirt-45", + "id": "libvirt-46", "error": { "class": "GenericError", "desc": "SEV feature is not available" @@ -19921,7 +20031,7 @@ "name": "host" } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -20114,7 +20224,7 @@ } } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -20309,7 +20419,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -20572,7 +20682,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -20586,7 +20696,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -20779,7 +20889,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -20974,7 +21084,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { @@ -21237,7 +21347,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_3.1.0.x86_64.replies b/tests/q= emucapabilitiesdata/caps_3.1.0.x86_64.replies index 256fa92af9..e0e1edddf1 100644 --- a/tests/qemucapabilitiesdata/caps_3.1.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_3.1.0.x86_64.replies @@ -4818,12 +4818,122 @@ "id": "libvirt-34" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-35" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -4884,7 +4994,7 @@ "type": "bool" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -4892,7 +5002,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4952,7 +5062,7 @@ "type": "bool" } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -4960,7 +5070,7 @@ "arguments": { "typename": "max-x86_64-cpu" }, - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -6062,12 +6172,12 @@ "type": "bool" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-machines", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -6286,12 +6396,12 @@ "cpu-max": 255 } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -6810,12 +6920,12 @@ "migration-safe": true } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-tpm-models", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -6823,12 +6933,12 @@ "tpm-crb", "tpm-tis" ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-tpm-types", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -6836,12 +6946,12 @@ "passthrough", "emulator" ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { "execute": "query-command-line-options", - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -8115,12 +8225,12 @@ "option": "drive" } ], - "id": "libvirt-42" + "id": "libvirt-43" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -8190,12 +8300,12 @@ "capability": "late-block-activate" } ], - "id": "libvirt-43" + "id": "libvirt-44" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -20380,16 +20490,16 @@ "meta-type": "object" } ], - "id": "libvirt-44" + "id": "libvirt-45" } =20 { "execute": "query-sev-capabilities", - "id": "libvirt-45" + "id": "libvirt-46" } =20 { - "id": "libvirt-45", + "id": "libvirt-46", "error": { "class": "GenericError", "desc": "SEV feature is not available" @@ -20404,7 +20514,7 @@ "name": "host" } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -20606,7 +20716,7 @@ } } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -20810,7 +20920,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -21085,7 +21195,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -21099,7 +21209,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -21301,7 +21411,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -21505,7 +21615,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { @@ -21780,7 +21890,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_4.0.0.aarch64.replies b/tests/= qemucapabilitiesdata/caps_4.0.0.aarch64.replies index 0eca77acca..ddd77ba48a 100644 --- a/tests/qemucapabilitiesdata/caps_4.0.0.aarch64.replies +++ b/tests/qemucapabilitiesdata/caps_4.0.0.aarch64.replies @@ -5718,12 +5718,122 @@ "id": "libvirt-29" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-30" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-30" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -5788,7 +5898,7 @@ "type": "bool" } ], - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -5796,7 +5906,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -5860,7 +5970,7 @@ "type": "bool" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -5868,7 +5978,7 @@ "arguments": { "typename": "max-arm-cpu" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -5983,12 +6093,12 @@ "type": "child" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-machines", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6330,7 +6440,7 @@ "cpu-max": 1 } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6338,7 +6448,7 @@ "arguments": { "typename": "virt-4.0-machine" }, - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -6473,12 +6583,12 @@ "type": "string" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -6669,34 +6779,34 @@ "static": false } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-models", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-types", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-command-line-options", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -7844,12 +7954,12 @@ "option": "drive" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -7923,12 +8033,12 @@ "capability": "x-ignore-shared" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -20015,12 +20125,12 @@ ] } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-gic-capabilities", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -20036,7 +20146,7 @@ "kernel": false } ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_4.0.0.ppc64.replies b/tests/qe= mucapabilitiesdata/caps_4.0.0.ppc64.replies index 84b5f06c5d..356e12aa01 100644 --- a/tests/qemucapabilitiesdata/caps_4.0.0.ppc64.replies +++ b/tests/qemucapabilitiesdata/caps_4.0.0.ppc64.replies @@ -5773,12 +5773,122 @@ "id": "libvirt-30" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-31" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-31" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -5843,7 +5953,7 @@ "type": "bool" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -5851,7 +5961,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -5915,12 +6025,12 @@ "type": "bool" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-machines", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6073,7 +6183,7 @@ "cpu-max": 1 } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6081,7 +6191,7 @@ "arguments": { "typename": "pseries-4.0-machine" }, - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -6280,12 +6390,12 @@ "type": "string" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -8481,34 +8591,34 @@ "static": false } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-models", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-types", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-command-line-options", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -9651,12 +9761,12 @@ "option": "drive" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -9730,12 +9840,12 @@ "capability": "x-ignore-shared" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -21793,7 +21903,7 @@ ] } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_4.0.0.riscv32.replies b/tests/= qemucapabilitiesdata/caps_4.0.0.riscv32.replies index 2b1d832c6b..2d63851d3a 100644 --- a/tests/qemucapabilitiesdata/caps_4.0.0.riscv32.replies +++ b/tests/qemucapabilitiesdata/caps_4.0.0.riscv32.replies @@ -3892,12 +3892,122 @@ "id": "libvirt-30" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-31" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-31" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -3962,7 +4072,7 @@ "type": "bool" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -3970,7 +4080,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -4034,12 +4144,12 @@ "type": "bool" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-machines", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -4076,7 +4186,7 @@ "cpu-max": 1 } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -4084,7 +4194,7 @@ "arguments": { "typename": "virt-machine" }, - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -4189,34 +4299,34 @@ "type": "bool" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-tpm-models", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "return": [ ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-types", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-command-line-options", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -5488,12 +5598,12 @@ "option": "drive" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -5567,12 +5677,12 @@ "capability": "x-ignore-shared" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -17851,12 +17961,12 @@ ] } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-machines", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -17893,5 +18003,5 @@ "cpu-max": 1 } ], - "id": "libvirt-40" + "id": "libvirt-41" } diff --git a/tests/qemucapabilitiesdata/caps_4.0.0.riscv64.replies b/tests/= qemucapabilitiesdata/caps_4.0.0.riscv64.replies index 8fd9646f53..4df475d7c0 100644 --- a/tests/qemucapabilitiesdata/caps_4.0.0.riscv64.replies +++ b/tests/qemucapabilitiesdata/caps_4.0.0.riscv64.replies @@ -3892,12 +3892,122 @@ "id": "libvirt-30" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-31" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-31a" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -3962,7 +4072,7 @@ "type": "bool" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -3970,7 +4080,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -4034,12 +4144,12 @@ "type": "bool" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-machines", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -4076,7 +4186,7 @@ "cpu-max": 1 } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -4084,7 +4194,7 @@ "arguments": { "typename": "virt-machine" }, - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -4189,34 +4299,34 @@ "type": "bool" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-tpm-models", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "return": [ ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-types", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-command-line-options", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -5488,12 +5598,12 @@ "option": "drive" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -5567,12 +5677,12 @@ "capability": "x-ignore-shared" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -17851,12 +17961,12 @@ ] } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-machines", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -17893,5 +18003,5 @@ "cpu-max": 1 } ], - "id": "libvirt-40" + "id": "libvirt-41" } diff --git a/tests/qemucapabilitiesdata/caps_4.0.0.x86_64.replies b/tests/q= emucapabilitiesdata/caps_4.0.0.x86_64.replies index 09112a207f..8ac67e0b75 100644 --- a/tests/qemucapabilitiesdata/caps_4.0.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_4.0.0.x86_64.replies @@ -5043,12 +5043,122 @@ "id": "libvirt-34" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-35" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -5113,7 +5223,7 @@ "type": "bool" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -5121,7 +5231,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -5185,7 +5295,7 @@ "type": "bool" } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -5193,7 +5303,7 @@ "arguments": { "typename": "max-x86_64-cpu" }, - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -6311,12 +6421,12 @@ "type": "bool" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-machines", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -6535,12 +6645,12 @@ "alias": "q35" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -7057,12 +7167,12 @@ "migration-safe": true } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-tpm-models", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -7070,12 +7180,12 @@ "tpm-crb", "tpm-tis" ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-tpm-types", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -7083,12 +7193,12 @@ "passthrough", "emulator" ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { "execute": "query-command-line-options", - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -8370,12 +8480,12 @@ "option": "drive" } ], - "id": "libvirt-42" + "id": "libvirt-43" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -8449,12 +8559,12 @@ "capability": "x-ignore-shared" } ], - "id": "libvirt-43" + "id": "libvirt-44" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -20919,16 +21029,16 @@ ] } ], - "id": "libvirt-44" + "id": "libvirt-45" } =20 { "execute": "query-sev-capabilities", - "id": "libvirt-45" + "id": "libvirt-46" } =20 { - "id": "libvirt-45", + "id": "libvirt-46", "error": { "class": "GenericError", "desc": "SEV feature is not available" @@ -20943,7 +21053,7 @@ "name": "host" } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -21147,7 +21257,7 @@ } } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -21353,7 +21463,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -21632,7 +21742,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -21646,7 +21756,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -21850,7 +21960,7 @@ } } }, - "id": "libvirt-48" + "id": "libvirt-49" } =20 { @@ -22056,7 +22166,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { @@ -22335,7 +22445,7 @@ } } }, - "id": "libvirt-49" + "id": "libvirt-50" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.replies b/tests/q= emucapabilitiesdata/caps_4.1.0.x86_64.replies index c143866dcc..5c3c706651 100644 --- a/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_4.1.0.x86_64.replies @@ -5336,12 +5336,122 @@ "id": "libvirt-34" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-35" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -5406,7 +5516,7 @@ "type": "bool" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -5414,7 +5524,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -5478,7 +5588,7 @@ "type": "int" } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -5486,7 +5596,7 @@ "arguments": { "typename": "max-x86_64-cpu" }, - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -6651,12 +6761,12 @@ "type": "bool" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-machines", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -6980,12 +7090,12 @@ "deprecated": false } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -8130,12 +8240,12 @@ "migration-safe": true } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-tpm-models", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -8143,12 +8253,12 @@ "tpm-crb", "tpm-tis" ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-tpm-types", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -8156,12 +8266,12 @@ "passthrough", "emulator" ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { "execute": "query-command-line-options", - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -9435,12 +9545,12 @@ "option": "drive" } ], - "id": "libvirt-42" + "id": "libvirt-43" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -9514,12 +9624,12 @@ "capability": "x-ignore-shared" } ], - "id": "libvirt-43" + "id": "libvirt-44" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -22104,16 +22214,16 @@ ] } ], - "id": "libvirt-44" + "id": "libvirt-45" } =20 { "execute": "query-sev-capabilities", - "id": "libvirt-45" + "id": "libvirt-46" } =20 { - "id": "libvirt-45", + "id": "libvirt-46", "error": { "class": "GenericError", "desc": "SEV feature is not available" @@ -22128,7 +22238,7 @@ "name": "host" } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -22336,7 +22446,7 @@ } } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -22350,7 +22460,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -22558,7 +22668,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_4.2.0.aarch64.replies b/tests/= qemucapabilitiesdata/caps_4.2.0.aarch64.replies index e5d5b53667..4d28047ebe 100644 --- a/tests/qemucapabilitiesdata/caps_4.2.0.aarch64.replies +++ b/tests/qemucapabilitiesdata/caps_4.2.0.aarch64.replies @@ -6090,12 +6090,122 @@ "id": "libvirt-29" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-30" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-30" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -6160,7 +6270,7 @@ "type": "bool" } ], - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -6168,7 +6278,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -6232,7 +6342,7 @@ "type": "bool" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -6240,7 +6350,7 @@ "arguments": { "typename": "max-arm-cpu" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -6427,12 +6537,12 @@ "type": "bool" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-machines", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6990,7 +7100,7 @@ "deprecated": false } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6998,7 +7108,7 @@ "arguments": { "typename": "virt-4.2-machine" }, - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -7151,12 +7261,12 @@ "type": "child" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -7347,34 +7457,34 @@ "static": false } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-models", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-types", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-command-line-options", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -8542,12 +8652,12 @@ "option": "drive" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -8625,12 +8735,12 @@ "capability": "validate-uuid" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -21201,12 +21311,12 @@ ] } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-gic-capabilities", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -21222,7 +21332,7 @@ "kernel": false } ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -21233,7 +21343,7 @@ "name": "host" } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -21263,7 +21373,7 @@ } } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -21277,11 +21387,11 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { - "id": "libvirt-43", + "id": "libvirt-44", "error": { "class": "GenericError", "desc": "Parameter 'migratable' is unexpected" diff --git a/tests/qemucapabilitiesdata/caps_4.2.0.ppc64.replies b/tests/qe= mucapabilitiesdata/caps_4.2.0.ppc64.replies index 2414105e25..95ec00a651 100644 --- a/tests/qemucapabilitiesdata/caps_4.2.0.ppc64.replies +++ b/tests/qemucapabilitiesdata/caps_4.2.0.ppc64.replies @@ -5895,12 +5895,122 @@ "id": "libvirt-30" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-31" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-31" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -5965,7 +6075,7 @@ "type": "bool" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -5973,7 +6083,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -6037,12 +6147,12 @@ "type": "bool" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-machines", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6304,7 +6414,7 @@ "deprecated": false } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6312,7 +6422,7 @@ "arguments": { "typename": "pseries-4.2-machine" }, - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -6511,12 +6621,12 @@ "type": "string" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -8712,34 +8822,34 @@ "static": false } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-models", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-types", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-command-line-options", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -9878,12 +9988,12 @@ "option": "drive" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -9961,12 +10071,12 @@ "capability": "validate-uuid" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -22195,7 +22305,7 @@ ] } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_4.2.0.x86_64.replies b/tests/q= emucapabilitiesdata/caps_4.2.0.x86_64.replies index b9481b6f85..c09ebb5460 100644 --- a/tests/qemucapabilitiesdata/caps_4.2.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_4.2.0.x86_64.replies @@ -5576,12 +5576,122 @@ "id": "libvirt-34" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-35" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -5646,7 +5756,7 @@ "type": "bool" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -5654,7 +5764,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -5718,7 +5828,7 @@ "type": "int" } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -5726,7 +5836,7 @@ "arguments": { "typename": "max-x86_64-cpu" }, - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -7280,12 +7390,12 @@ "type": "bool" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-machines", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -7677,12 +7787,12 @@ "deprecated": false } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -9065,12 +9175,12 @@ "migration-safe": true } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-tpm-models", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -9078,12 +9188,12 @@ "tpm-crb", "tpm-tis" ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-tpm-types", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -9091,12 +9201,12 @@ "passthrough", "emulator" ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { "execute": "query-command-line-options", - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -10382,12 +10492,12 @@ "option": "drive" } ], - "id": "libvirt-42" + "id": "libvirt-43" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -10465,12 +10575,12 @@ "capability": "validate-uuid" } ], - "id": "libvirt-43" + "id": "libvirt-44" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -23389,16 +23499,16 @@ ] } ], - "id": "libvirt-44" + "id": "libvirt-45" } =20 { "execute": "query-sev-capabilities", - "id": "libvirt-45" + "id": "libvirt-46" } =20 { - "id": "libvirt-45", + "id": "libvirt-46", "error": { "class": "GenericError", "desc": "SEV feature is not available" @@ -23413,7 +23523,7 @@ "name": "host" } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -23715,7 +23825,7 @@ } } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -23729,7 +23839,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -24031,7 +24141,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_5.0.0.aarch64.replies b/tests/= qemucapabilitiesdata/caps_5.0.0.aarch64.replies index a3136a0966..067cbb7e31 100644 --- a/tests/qemucapabilitiesdata/caps_5.0.0.aarch64.replies +++ b/tests/qemucapabilitiesdata/caps_5.0.0.aarch64.replies @@ -6476,12 +6476,122 @@ "id": "libvirt-29" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-30" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-30" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -6546,7 +6656,7 @@ "type": "bool" } ], - "id": "libvirt-30" + "id": "libvirt-31" } =20 { @@ -6554,7 +6664,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -6618,7 +6728,7 @@ "type": "bool" } ], - "id": "libvirt-31" + "id": "libvirt-32" } =20 { @@ -6626,7 +6736,7 @@ "arguments": { "typename": "max-arm-cpu" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -6826,12 +6936,12 @@ "type": "bool" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { "execute": "query-machines", - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -7411,7 +7521,7 @@ "deprecated": false } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -7419,7 +7529,7 @@ "arguments": { "typename": "virt-5.0-machine" }, - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -7557,12 +7667,12 @@ "type": "child" } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -7758,34 +7868,34 @@ "static": false } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-tpm-models", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "return": [ ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-types", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-command-line-options", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -8943,12 +9053,12 @@ "option": "drive" } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -9026,12 +9136,12 @@ "capability": "validate-uuid" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -21768,12 +21878,12 @@ ] } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-gic-capabilities", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -21789,7 +21899,7 @@ "kernel": false } ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -21800,7 +21910,7 @@ "name": "host" } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -21831,7 +21941,7 @@ } } }, - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -21845,11 +21955,11 @@ } } }, - "id": "libvirt-43" + "id": "libvirt-44" } =20 { - "id": "libvirt-43", + "id": "libvirt-44", "error": { "class": "GenericError", "desc": "Parameter 'migratable' is unexpected" diff --git a/tests/qemucapabilitiesdata/caps_5.0.0.ppc64.replies b/tests/qe= mucapabilitiesdata/caps_5.0.0.ppc64.replies index 9e54e1f9f6..8e754bfb80 100644 --- a/tests/qemucapabilitiesdata/caps_5.0.0.ppc64.replies +++ b/tests/qemucapabilitiesdata/caps_5.0.0.ppc64.replies @@ -6525,12 +6525,122 @@ "id": "libvirt-31" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-32" +} + +{ + "return": [ + { + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "name": "aer_log_max", + "type": "uint16" + }, + { + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "name": "slot", + "type": "uint16" + }, + { + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "name": "port", + "type": "uint8" + }, + { + "name": "mem-reserve", + "type": "size" + }, + { + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "name": "pref64-reserve", + "type": "size" + }, + { + "name": "rombar", + "type": "uint32" + }, + { + "name": "command_serr_enable", + "description": "on/off", + "type": "bool" + }, + { + "name": "romfile", + "type": "str" + }, + { + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "name": "chassis", + "type": "uint8" + }, + { + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "name": "pref32-reserve", + "type": "size" + }, + { + "name": "bus-reserve", + "type": "uint32" + }, + { + "name": "x-migrate-msix", + "type": "bool" + }, + { + "name": "disable-acs", + "type": "bool" + }, + { + "name": "io-reserve", + "type": "size" + } + ], + "id": "libvirt-32" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -6600,7 +6710,7 @@ "type": "bool" } ], - "id": "libvirt-32" + "id": "libvirt-33" } =20 { @@ -6608,7 +6718,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-33" + "id": "libvirt-34" } =20 { @@ -6677,12 +6787,12 @@ "type": "bool" } ], - "id": "libvirt-33" + "id": "libvirt-34" } =20 { "execute": "query-machines", - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -6952,7 +7062,7 @@ "deprecated": false } ], - "id": "libvirt-34" + "id": "libvirt-35" } =20 { @@ -6960,7 +7070,7 @@ "arguments": { "typename": "pseries-5.0-machine" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -7169,12 +7279,12 @@ "type": "string" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -9380,24 +9490,24 @@ "static": false } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { "execute": "query-tpm-models", - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "return": [ "tpm-spapr" ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-tpm-types", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -9405,12 +9515,12 @@ "passthrough", "emulator" ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-command-line-options", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -10487,12 +10597,12 @@ "option": "drive" } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -10570,12 +10680,12 @@ "capability": "validate-uuid" } ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -23336,7 +23446,7 @@ ] } ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_5.0.0.x86_64.replies b/tests/q= emucapabilitiesdata/caps_5.0.0.x86_64.replies index 95a7d62f5a..af2299a41e 100644 --- a/tests/qemucapabilitiesdata/caps_5.0.0.x86_64.replies +++ b/tests/qemucapabilitiesdata/caps_5.0.0.x86_64.replies @@ -6041,12 +6041,141 @@ "id": "libvirt-34" } =20 +{ + "execute": "device-list-properties", + "arguments": { + "typename": "pcie-root-port" + }, + "id": "libvirt-35" +} + +{ + "return": [ + { + "name": "romfile", + "type": "str" + }, + { + "default-value": -1, + "name": "addr", + "description": "Slot and optional function number, example: 06.0 or = 06", + "type": "int32" + }, + { + "name": "failover_pair_id", + "type": "str" + }, + { + "default-value": true, + "name": "x-pcie-lnksta-dllla", + "description": "on/off", + "type": "bool" + }, + { + "default-value": 1, + "name": "rombar", + "type": "uint32" + }, + { + "default-value": true, + "name": "x-pcie-extcap-init", + "description": "on/off", + "type": "bool" + }, + { + "default-value": false, + "name": "multifunction", + "description": "on/off", + "type": "bool" + }, + { + "default-value": 0, + "name": "port", + "type": "uint8" + }, + { + "default-value": 8, + "name": "aer_log_max", + "type": "uint16" + }, + { + "default-value": true, + "name": "hotplug", + "type": "bool" + }, + { + "default-value": 0, + "name": "slot", + "type": "uint16" + }, + { + "default-value": 0, + "name": "chassis", + "type": "uint8" + }, + { + "default-value": true, + "name": "power_controller_present", + "description": "on/off", + "type": "bool" + }, + { + "default-value": false, + "name": "disable-acs", + "type": "bool" + }, + { + "default-value": 18446744073709551615, + "name": "mem-reserve", + "type": "size" + }, + { + "default-value": 18446744073709551615, + "name": "pref64-reserve", + "type": "size" + }, + { + "default-value": 4294967295, + "name": "bus-reserve", + "type": "uint32" + }, + { + "default-value": "32", + "name": "x-width", + "description": "1/2/4/8/12/16/32", + "type": "PCIELinkWidth" + }, + { + "default-value": true, + "name": "x-migrate-msix", + "type": "bool" + }, + { + "default-value": 18446744073709551615, + "name": "io-reserve", + "type": "size" + }, + { + "default-value": "16", + "name": "x-speed", + "description": "2_5/5/8/16", + "type": "PCIELinkSpeed" + }, + { + "default-value": 18446744073709551615, + "name": "pref32-reserve", + "type": "size" + } + ], + "id": "libvirt-35" +} + { "execute": "qom-list-properties", "arguments": { "typename": "memory-backend-file" }, - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -6116,7 +6245,7 @@ "type": "bool" } ], - "id": "libvirt-35" + "id": "libvirt-36" } =20 { @@ -6124,7 +6253,7 @@ "arguments": { "typename": "memory-backend-memfd" }, - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -6193,7 +6322,7 @@ "type": "int" } ], - "id": "libvirt-36" + "id": "libvirt-37" } =20 { @@ -6201,7 +6330,7 @@ "arguments": { "typename": "max-x86_64-cpu" }, - "id": "libvirt-37" + "id": "libvirt-38" } =20 { @@ -7767,12 +7896,12 @@ "type": "bool" } ], - "id": "libvirt-37" + "id": "libvirt-38" } =20 { "execute": "query-machines", - "id": "libvirt-38" + "id": "libvirt-39" } =20 { @@ -8148,12 +8277,12 @@ "deprecated": false } ], - "id": "libvirt-38" + "id": "libvirt-39" } =20 { "execute": "query-cpu-definitions", - "id": "libvirt-39" + "id": "libvirt-40" } =20 { @@ -9665,12 +9794,12 @@ "migration-safe": true } ], - "id": "libvirt-39" + "id": "libvirt-40" } =20 { "execute": "query-tpm-models", - "id": "libvirt-40" + "id": "libvirt-41" } =20 { @@ -9678,12 +9807,12 @@ "tpm-crb", "tpm-tis" ], - "id": "libvirt-40" + "id": "libvirt-41" } =20 { "execute": "query-tpm-types", - "id": "libvirt-41" + "id": "libvirt-42" } =20 { @@ -9691,12 +9820,12 @@ "passthrough", "emulator" ], - "id": "libvirt-41" + "id": "libvirt-42" } =20 { "execute": "query-command-line-options", - "id": "libvirt-42" + "id": "libvirt-43" } =20 { @@ -10972,12 +11101,12 @@ "option": "drive" } ], - "id": "libvirt-42" + "id": "libvirt-43" } =20 { "execute": "query-migrate-capabilities", - "id": "libvirt-43" + "id": "libvirt-44" } =20 { @@ -11055,12 +11184,12 @@ "capability": "validate-uuid" } ], - "id": "libvirt-43" + "id": "libvirt-44" } =20 { "execute": "query-qmp-schema", - "id": "libvirt-44" + "id": "libvirt-45" } =20 { @@ -24788,16 +24917,16 @@ ] } ], - "id": "libvirt-44" + "id": "libvirt-45" } =20 { "execute": "query-sev-capabilities", - "id": "libvirt-45" + "id": "libvirt-46" } =20 { - "id": "libvirt-45", + "id": "libvirt-46", "error": { "class": "GenericError", "desc": "SEV feature is not available" @@ -24812,7 +24941,7 @@ "name": "host" } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -25115,7 +25244,7 @@ } } }, - "id": "libvirt-46" + "id": "libvirt-47" } =20 { @@ -25129,7 +25258,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { @@ -25432,7 +25561,7 @@ } } }, - "id": "libvirt-47" + "id": "libvirt-48" } =20 { diff --git a/tests/qemucapabilitiesdata/caps_5.0.0.x86_64.xml b/tests/qemuc= apabilitiesdata/caps_5.0.0.x86_64.xml index df3557d1ad..2f89f22c2b 100644 --- a/tests/qemucapabilitiesdata/caps_5.0.0.x86_64.xml +++ b/tests/qemucapabilitiesdata/caps_5.0.0.x86_64.xml @@ -228,6 +228,7 @@ + 4002091 0 43100241 --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181140; cv=none; d=zohomail.com; s=zohoarc; b=lAL336L7XKtgPlC8D3v1sVoCkGjjPSyXuFAF34qk2Pk0kIAFjBZlllKUXXBvQfSSj8HwuWiTShZH+VIng2FMXzMEsRSx2CJ3Fq0Z5+My1u+umBQK/+qIvxuHm4Un2gHZsTsGr66EoIqfF5dQogTJ8IXEe+nU72QWKjMjxlXxAmI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181140; 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=QFb+G21b7T7XU4FDmPit7qQGB6WetTC39Xcl7bqHasA=; b=HxaOnC46SenlcIHtPnXUUwJFyQ2iUPRhWMVe9n3lBCMJGwnTbU/F63mgWL+t/xCOX2ct/JRPzyN9GT1lBsNy1MdWgmUogJhLZ4X6raiivL5kcQDdlb/RRNJNHH/69jFLfeF7xB2emvHBktRPQvs3V1shw86LtqwqpwmWZe+HvRo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 158618114062682.43052843633757; Mon, 6 Apr 2020 06:52:20 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-196-WqngGBkCPBiiwFF_qP8ysQ-1; Mon, 06 Apr 2020 09:52:16 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C96BC18B9FCA; Mon, 6 Apr 2020 13:52:10 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8FDC25C1B0; Mon, 6 Apr 2020 13:52:10 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 2D7E618089CE; Mon, 6 Apr 2020 13:52:10 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036DpewJ018336 for ; Mon, 6 Apr 2020 09:51:40 -0400 Received: by smtp.corp.redhat.com (Postfix) id C8EF55C1BB; Mon, 6 Apr 2020 13:51:40 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7E3E95C1B0 for ; Mon, 6 Apr 2020 13:51:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181139; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=QFb+G21b7T7XU4FDmPit7qQGB6WetTC39Xcl7bqHasA=; b=UTxC/llJO5Ysu+z1Pq8gVWXu9ki/h+miQYSG9NgYM8W8FK415WIkY2apTjmlNvflqFwN83 lHzt9Uj//Kymh0ALyQxBy2E0g9iEzXVYhFlr1Mz4tcALcwO/xMo/OMcRjMsUsW+Pf07xcq Dk1CEkKMM6cQWS5YFW6535zENeAdV7E= X-MC-Unique: WqngGBkCPBiiwFF_qP8ysQ-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 02/10] conf: new attribute "hotplug" for pci controllers Date: Mon, 6 Apr 2020 09:51:22 -0400 Message-Id: <20200406135130.3080946-3-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" a element can now have a "hotplug" attribute in the subelement. This is intended to control whether or not the slot(s) of the controller support hotplugging/unplugging a device: The default value of hotplug is "on". Since support for configuring such an option is hypervisor-dependent (and will vary among different types of PCI controllers even on a single hypervisor), no validation is done in this patch - that validation will be done in the patch that wires support for the setting into the hypervisor. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- docs/formatdomain.html.in | 11 ++++ docs/schemas/domaincommon.rng | 5 ++ src/conf/domain_conf.c | 20 +++++- src/conf/domain_conf.h | 1 + .../pcie-root-port-nohotplug.xml | 35 ++++++++++ .../pcie-root-port-nohotplug.xml | 64 +++++++++++++++++++ tests/qemuxml2xmltest.c | 7 ++ 7 files changed, 142 insertions(+), 1 deletion(-) create mode 100644 tests/qemuxml2argvdata/pcie-root-port-nohotplug.xml create mode 100644 tests/qemuxml2xmloutdata/pcie-root-port-nohotplug.xml diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in index fbffb16866..341f7c78dc 100644 --- a/docs/formatdomain.html.in +++ b/docs/formatdomain.html.in @@ -4706,6 +4706,17 @@ which is visible to the virtual machine. If set, port must be between 0 and 255. +
hotplug
+
+ pcie-root-port and pcie-switch-downstream-port controllers can + also have a hotplug attribute in + the <target> subelement, which is used to + disable hotplug/unplug of devices on a particular + controller. The default setting of hotplug + is on; it should be set to off to + disable hotplug/unplug of devices on a particular controller. + Since 6.3.0 +
busNr
pci-expander-bus and pcie-expander-bus controllers can have an diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng index dcf2e09db8..7db32ec5c0 100644 --- a/docs/schemas/domaincommon.rng +++ b/docs/schemas/domaincommon.rng @@ -2475,6 +2475,11 @@ + + + + + diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 460f8064be..4c81579eaf 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -11035,6 +11035,7 @@ virDomainControllerDefParseXML(virDomainXMLOptionPt= r xmlopt, g_autofree char *port =3D NULL; g_autofree char *busNr =3D NULL; g_autofree char *targetIndex =3D NULL; + g_autofree char *hotplug =3D NULL; g_autofree char *ioeventfd =3D NULL; g_autofree char *portsStr =3D NULL; g_autofree char *iothread =3D NULL; @@ -11106,6 +11107,7 @@ virDomainControllerDefParseXML(virDomainXMLOptionPt= r xmlopt, chassis =3D virXMLPropString(cur, "chassis"); port =3D virXMLPropString(cur, "port"); busNr =3D virXMLPropString(cur, "busNr"); + hotplug =3D virXMLPropString(cur, "hotplug"); targetIndex =3D virXMLPropString(cur, "index"); processedTarget =3D true; } @@ -11342,6 +11344,17 @@ virDomainControllerDefParseXML(virDomainXMLOptionP= tr xmlopt, } def->opts.pciopts.numaNode =3D numaNode; } + if (hotplug) { + int val =3D virTristateSwitchTypeFromString(hotplug); + + if (val <=3D 0) { + virReportError(VIR_ERR_XML_ERROR, + _("PCI controller unrecognized hotplug sett= ing '%s'"), + hotplug); + goto error; + } + def->opts.pciopts.hotplug =3D val; + } break; case VIR_DOMAIN_CONTROLLER_TYPE_XENBUS: { g_autofree char *gntframes =3D virXMLPropString(node, "maxGrantFra= mes"); @@ -25333,7 +25346,8 @@ virDomainControllerDefFormat(virBufferPtr buf, def->opts.pciopts.port !=3D -1 || def->opts.pciopts.busNr !=3D -1 || def->opts.pciopts.targetIndex !=3D -1 || - def->opts.pciopts.numaNode !=3D -1) { + def->opts.pciopts.numaNode !=3D -1 || + def->opts.pciopts.hotplug !=3D VIR_TRISTATE_SWITCH_ABSENT) { virBufferAddLit(&childBuf, "opts.pciopts.chassisNr !=3D -1) virBufferAsprintf(&childBuf, " chassisNr=3D'%d'", @@ -25350,6 +25364,10 @@ virDomainControllerDefFormat(virBufferPtr buf, if (def->opts.pciopts.targetIndex !=3D -1) virBufferAsprintf(&childBuf, " index=3D'%d'", def->opts.pciopts.targetIndex); + if (def->opts.pciopts.hotplug !=3D VIR_TRISTATE_SWITCH_ABSENT)= { + virBufferAsprintf(&childBuf, " hotplug=3D'%s'", + virTristateSwitchTypeToString(def->opts.= pciopts.hotplug)); + } if (def->opts.pciopts.numaNode =3D=3D -1) { virBufferAddLit(&childBuf, "/>\n"); } else { diff --git a/src/conf/domain_conf.h b/src/conf/domain_conf.h index 2038b54c32..bd5aaeaef1 100644 --- a/src/conf/domain_conf.h +++ b/src/conf/domain_conf.h @@ -722,6 +722,7 @@ struct _virDomainPCIControllerOpts { * item in memory target config) -1 =3D=3D unspecified */ int numaNode; + virTristateSwitch hotplug; /* 'off' to prevent hotplug/unplug, default= 'on' */ }; =20 struct _virDomainUSBControllerOpts { diff --git a/tests/qemuxml2argvdata/pcie-root-port-nohotplug.xml b/tests/qe= muxml2argvdata/pcie-root-port-nohotplug.xml new file mode 100644 index 0000000000..8a01494470 --- /dev/null +++ b/tests/qemuxml2argvdata/pcie-root-port-nohotplug.xml @@ -0,0 +1,35 @@ + + guest + 11dbdcdd-4c3b-482b-8903-9bdb8c0a2774 + 2097152 + 2097152 + 2 + + hvm + + + /usr/bin/qemu-system-x86_64 + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/qemuxml2xmloutdata/pcie-root-port-nohotplug.xml b/tests/= qemuxml2xmloutdata/pcie-root-port-nohotplug.xml new file mode 100644 index 0000000000..2ecb99728d --- /dev/null +++ b/tests/qemuxml2xmloutdata/pcie-root-port-nohotplug.xml @@ -0,0 +1,64 @@ + + guest + 11dbdcdd-4c3b-482b-8903-9bdb8c0a2774 + 2097152 + 2097152 + 2 + + hvm + + + + destroy + restart + destroy + + /usr/bin/qemu-system-x86_64 + + + + +
+ + + + +
+ + + + +
+ + + +
+ + + + +
+ + + + +
+ + + + +
+ + + + +
+ + +
+ + + + + + diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c index b4c83fccca..4b40468d15 100644 --- a/tests/qemuxml2xmltest.c +++ b/tests/qemuxml2xmltest.c @@ -960,6 +960,13 @@ mymain(void) DO_TEST("pcie-root-port-model-ioh3420", QEMU_CAPS_DEVICE_IOH3420); =20 + DO_TEST("pcie-root-port-nohotplug", + QEMU_CAPS_DEVICE_PCIE_ROOT_PORT, + QEMU_CAPS_DEVICE_IOH3420, + QEMU_CAPS_DEVICE_X3130_UPSTREAM, + QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM, + QEMU_CAPS_PCIE_ROOT_PORT_HOTPLUG); + DO_TEST("pcie-switch-upstream-port", QEMU_CAPS_DEVICE_IOH3420, QEMU_CAPS_DEVICE_X3130_UPSTREAM, --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181117; cv=none; d=zohomail.com; s=zohoarc; b=KM7fsVPWL+tBUgQ0RB1bjJN/1xsdzE2wUfI4tewQxQY5EBANy8kJ9G2ObU/jAT19l/0GE6cT1A+pALAtdzM2kQtkkx1iuRew15hxXk4iq/BNj/Vs3P41IwQkZ270OZmeFfnxy6WI2u7Ktwh8MbgmeIv9bgOzTwYIJn1t9FUhDx8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181117; 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=6rFhLfrgq8Kmp37ifeNO10YmpWELXdWwlXpKSO+7+vo=; b=LTAHXGI/Q3OQwkeCQhVVb7albWb4IkzkWOyCetsE4JN4ciqpzbTihjEI4xW8qH8epU8a0asHLTq9muZOYgGox3yiOqpVGaep9eBv5wGgyOP1XinuIfpK0UgAWcWiZUiY076FbkCzXjfWrVzebnoSpMjhRcRqZfw4x9f7jt93UTg= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1586181117179297.38601828300875; Mon, 6 Apr 2020 06:51:57 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-96-wtKFt3JKNCusrawImj09Yg-1; Mon, 06 Apr 2020 09:51:52 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id F072E107ACC7; Mon, 6 Apr 2020 13:51:46 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 7559092FA6; Mon, 6 Apr 2020 13:51:45 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id B4DD993A63; Mon, 6 Apr 2020 13:51:43 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036Dpf5l018344 for ; Mon, 6 Apr 2020 09:51:41 -0400 Received: by smtp.corp.redhat.com (Postfix) id 53C815C28F; Mon, 6 Apr 2020 13:51:41 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 054A15C1B0 for ; Mon, 6 Apr 2020 13:51:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181115; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=6rFhLfrgq8Kmp37ifeNO10YmpWELXdWwlXpKSO+7+vo=; b=ZPsdfGoNqyzp6//WEw0uIyI88R53T3rh9Zfis6NpReyc6tK5MALlFhvXhmnshp5AMkdA9W v4yeJKKVk9MCyEKTtKGGKEczJ5OnV6vBkzgSFqWIv1M5JPK2wefeSbHEc5ez7u/JFgwT/k k4Yb49p+M4UST+FnW2WuwR5RSEsOazM= X-MC-Unique: wtKFt3JKNCusrawImj09Yg-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 03/10] qemu: hook up pcie-root-port hotplug='off' option Date: Mon, 6 Apr 2020 09:51:23 -0400 Message-Id: <20200406135130.3080946-4-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" If a pcie-root-port or pcie-downstream-port has hotplug=3D'off' in its subelement, and if the qemu binary supports the hotplug=3Dfalse option, then it will be added to the commandline for the pcie controller. This controller will then not allow any hotplug/unplug of devices while the guest is running (and the hotplug capability won't be advertised to the guest OS, so the guest OS also won't present unplugging of PCI devices as an option). For any PCI controllers other than pcie-downstream-port and pcie-root-port, of for qemu binaries that don't support the hotplug commandline option, an error will be logged during validation. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/qemu/qemu_command.c | 4 ++ src/qemu/qemu_validate.c | 31 +++++++++++++++ .../pcie-root-port-nohotplug.args | 39 +++++++++++++++++++ tests/qemuxml2argvtest.c | 7 ++++ 4 files changed, 81 insertions(+) create mode 100644 tests/qemuxml2argvdata/pcie-root-port-nohotplug.args diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index df90f5edf5..f619ef32be 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -3016,6 +3016,10 @@ qemuBuildControllerDevStr(const virDomainDef *domain= Def, virBufferAsprintf(&buf, "%s,port=3D0x%x,chassis=3D%d,id=3D%s", modelName, pciopts->port, pciopts->chassis, def->info.alias); + if (pciopts->hotplug !=3D VIR_TRISTATE_SWITCH_ABSENT) { + virBufferAsprintf(&buf, ",hotplug=3D%s", + virTristateSwitchTypeToString(pciopts->h= otplug)); + } break; case VIR_DOMAIN_CONTROLLER_MODEL_PCI_ROOT: virBufferAsprintf(&buf, "%s,index=3D%d,id=3D%s", diff --git a/src/qemu/qemu_validate.c b/src/qemu/qemu_validate.c index 6f94361b52..49f9af69db 100644 --- a/src/qemu/qemu_validate.c +++ b/src/qemu/qemu_validate.c @@ -2637,6 +2637,37 @@ qemuValidateDomainDeviceDefControllerPCI(const virDo= mainControllerDef *cont, virReportEnumRangeError(virDomainControllerModelPCI, cont->model); } =20 + /* hotplug */ + if (pciopts->hotplug !=3D VIR_TRISTATE_SWITCH_ABSENT) { + switch ((virDomainControllerModelPCI) cont->model) { + case VIR_DOMAIN_CONTROLLER_MODEL_PCIE_ROOT_PORT: + case VIR_DOMAIN_CONTROLLER_MODEL_PCIE_SWITCH_DOWNSTREAM_PORT: + if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_PCIE_ROOT_PORT_HOTPLUG= )) { + virReportError(VIR_ERR_CONFIG_UNSUPPORTED, + _("setting the hotplug property on a '%s' d= evice is not supported by this QEMU binary"), + modelName); + return -1; + } + break; + + case VIR_DOMAIN_CONTROLLER_MODEL_PCI_ROOT: + case VIR_DOMAIN_CONTROLLER_MODEL_PCI_BRIDGE: + case VIR_DOMAIN_CONTROLLER_MODEL_DMI_TO_PCI_BRIDGE: + case VIR_DOMAIN_CONTROLLER_MODEL_PCIE_SWITCH_UPSTREAM_PORT: + case VIR_DOMAIN_CONTROLLER_MODEL_PCI_EXPANDER_BUS: + case VIR_DOMAIN_CONTROLLER_MODEL_PCIE_EXPANDER_BUS: + case VIR_DOMAIN_CONTROLLER_MODEL_PCIE_ROOT: + case VIR_DOMAIN_CONTROLLER_MODEL_PCIE_TO_PCI_BRIDGE: + virReportControllerInvalidOption(cont, model, modelName, "hotp= lug"); + return -1; + + case VIR_DOMAIN_CONTROLLER_MODEL_PCI_DEFAULT: + case VIR_DOMAIN_CONTROLLER_MODEL_PCI_LAST: + default: + virReportEnumRangeError(virDomainControllerModelPCI, cont->mod= el); + } + } + /* QEMU device availability */ if (cap < 0) { virReportError(VIR_ERR_INTERNAL_ERROR, diff --git a/tests/qemuxml2argvdata/pcie-root-port-nohotplug.args b/tests/q= emuxml2argvdata/pcie-root-port-nohotplug.args new file mode 100644 index 0000000000..3a4904c24f --- /dev/null +++ b/tests/qemuxml2argvdata/pcie-root-port-nohotplug.args @@ -0,0 +1,39 @@ +LC_ALL=3DC \ +PATH=3D/bin \ +HOME=3D/tmp/lib/domain--1-guest \ +USER=3Dtest \ +LOGNAME=3Dtest \ +XDG_DATA_HOME=3D/tmp/lib/domain--1-guest/.local/share \ +XDG_CACHE_HOME=3D/tmp/lib/domain--1-guest/.cache \ +XDG_CONFIG_HOME=3D/tmp/lib/domain--1-guest/.config \ +QEMU_AUDIO_DRV=3Dnone \ +/usr/bin/qemu-system-x86_64 \ +-name guest \ +-S \ +-machine q35,accel=3Dtcg,usb=3Doff,dump-guest-core=3Doff \ +-m 2048 \ +-realtime mlock=3Doff \ +-smp 2,sockets=3D2,cores=3D1,threads=3D1 \ +-uuid 11dbdcdd-4c3b-482b-8903-9bdb8c0a2774 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=3Dcharmonitor,path=3D/tmp/lib/domain--1-guest/monitor.s= ock,\ +server,nowait \ +-mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dcontrol \ +-rtc base=3Dutc \ +-no-shutdown \ +-no-acpi \ +-device pcie-root-port,port=3D0x10,chassis=3D1,id=3Dpci.1,bus=3Dpcie.0,\ +multifunction=3Don,addr=3D0x2 \ +-device pcie-root-port,port=3D0x11,chassis=3D2,id=3Dpci.2,hotplug=3Doff,bu= s=3Dpcie.0,\ +addr=3D0x2.0x1 \ +-device ioh3420,port=3D0x12,chassis=3D3,id=3Dpci.3,hotplug=3Doff,bus=3Dpci= e.0,\ +addr=3D0x2.0x2 \ +-device x3130-upstream,id=3Dpci.4,bus=3Dpci.1,addr=3D0x0 \ +-device xio3130-downstream,port=3D0x0,chassis=3D5,id=3Dpci.5,hotplug=3Doff= ,bus=3Dpci.4,\ +addr=3D0x0 \ +-device xio3130-downstream,port=3D0x1,chassis=3D6,id=3Dpci.6,hotplug=3Don,= bus=3Dpci.4,\ +addr=3D0x1 \ +-device xio3130-downstream,port=3D0x2,chassis=3D7,id=3Dpci.7,bus=3Dpci.4,a= ddr=3D0x2 \ +-device xio3130-downstream,port=3D0x27,chassis=3D30,id=3Dpci.8,bus=3Dpci.4= ,addr=3D0x3 diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index fdeb3c2e65..9a10528251 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -2436,6 +2436,13 @@ mymain(void) DO_TEST("pcie-root-port-model-ioh3420", QEMU_CAPS_DEVICE_IOH3420); =20 + DO_TEST("pcie-root-port-nohotplug", + QEMU_CAPS_DEVICE_PCIE_ROOT_PORT, + QEMU_CAPS_DEVICE_IOH3420, + QEMU_CAPS_DEVICE_X3130_UPSTREAM, + QEMU_CAPS_DEVICE_XIO3130_DOWNSTREAM, + QEMU_CAPS_PCIE_ROOT_PORT_HOTPLUG); + DO_TEST("autoindex", QEMU_CAPS_DEVICE_PCI_BRIDGE, QEMU_CAPS_DEVICE_DMI_TO_PCI_BRIDGE, --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) client-ip=207.211.31.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181146; cv=none; d=zohomail.com; s=zohoarc; b=kyw9R3uAVeC1/DLkqui9oz/dVBgcXBBjKMUSx3L5V92ytTmiv1xI5AXPl3z5JvfiNUbdC/soPmLSU+6Q0Wvv1RU1hfGVscxw/GQilBGohWHho44t2zO1yhiNS4VEQ1BfqSlLEP5cBkfCSjEdwcqs5aBmzKhIUIL+1C5BNqTVSYs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181146; 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=ObU7NbeKVB5XTVDZ5Kbw8xHmqOGcNab5xfIiep32Rjs=; b=GsrAOAgMDJ/B/A+SYwx4PcKmgCGkHnRA6d7M9vTf69d38w8kGATeg1/546aHM0Myp7X0mBMq+/LqCNos2DY83HTA0Ql8JQX5SG1fQAM07kNTlOHX6X2enit2s4v7ZiEbE2v8JoIxppxgVpubrQtwaU/VrFACjag8v/jfcfQFp2E= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by mx.zohomail.com with SMTPS id 1586181146495614.2855978341339; Mon, 6 Apr 2020 06:52:26 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-233-A-14kHoxMvqenWh8DtIaaw-1; Mon, 06 Apr 2020 09:52:20 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id D0A4818B9FCF; Mon, 6 Apr 2020 13:52:14 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A55AF5DA7C; Mon, 6 Apr 2020 13:52:14 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 5429218089D7; Mon, 6 Apr 2020 13:52:14 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036DpfAP018351 for ; Mon, 6 Apr 2020 09:51:41 -0400 Received: by smtp.corp.redhat.com (Postfix) id CDCA05C28F; Mon, 6 Apr 2020 13:51:41 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 833815C1BB for ; Mon, 6 Apr 2020 13:51:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181145; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=ObU7NbeKVB5XTVDZ5Kbw8xHmqOGcNab5xfIiep32Rjs=; b=VlkgDn3jgFror7hZdvylHmOmtchh8j/qDCIC1mA8fiiTc3eY9fvmie9gqgjx6HvYHxEWu/ QZyC7uhdJexhsxFS4pqxes2dmCnvNOhQhsJcQrw+U5xK+2vyuH1enoI0TONc/tFlDs7x0R Ozg3R9NAaNWKW/EzI3CLG/scKC3VdMM= X-MC-Unique: A-14kHoxMvqenWh8DtIaaw-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 04/10] docs: mention hotplug='off' in news.xml Date: Mon, 6 Apr 2020 09:51:24 -0400 Message-Id: <20200406135130.3080946-5-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- docs/news.xml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/docs/news.xml b/docs/news.xml index 0d3f3386ec..4d0efd4219 100644 --- a/docs/news.xml +++ b/docs/news.xml @@ -44,6 +44,18 @@
+ + + qemu: support disabling hotplug/unplug of PCIe devices + + + libvirt can now set the "hotplug" option for pcie-root-ports + and pcie-switch-downstream-ports, which can be used to + disable hotplug/unplug of devices from these ports (default + behavior is for these controllers to accept all + hotplug/unplug attempts, but this is often undesireable). + +
--=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181122; cv=none; d=zohomail.com; s=zohoarc; b=jQEOID3ubk7LQZ3I8jvW21wb1vycQpiGtw8fvQ8Ek6lJAStcYpCRdoRHzQZ8tggYrwfkKLO09n+tzB3wV4FD7UqtHEpOzjf8khMxB6fgdnGucyKG0RYiagyPkxu+Yi2auoxMjpAVsDphQXZbUpSrNTLmMbfGGc314gglrI3OOD4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181122; 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=icXis0J7pFCjOtODlyPidSwzSqYq/Y2pEAJyfZmt0tc=; b=EtbbPNYOxMC6KDAwY9ap24iz8xtn31a10GES+rre2yE0J//rDpGZobNp0mgXrEPDdmf0alv6BUYEwJLj5pKSNNnFbm92bdjntcBtr8RwaBfqr+8Rq1WFYTAK4h4L0Ata+6IK6ZXZDnLJLPTTHCcchLNGpRJn0Hv/6uQy5EIMaZM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1586181122141557.986419936916; Mon, 6 Apr 2020 06:52:02 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-278-ZsQ_qJlZObC9r5NMwUSmqw-1; Mon, 06 Apr 2020 09:51:59 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id A7555107ACCA; Mon, 6 Apr 2020 13:51:51 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6937860BE0; Mon, 6 Apr 2020 13:51:51 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 0053A18089CD; Mon, 6 Apr 2020 13:51:50 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036DpgkS018357 for ; Mon, 6 Apr 2020 09:51:42 -0400 Received: by smtp.corp.redhat.com (Postfix) id 596655C1B0; Mon, 6 Apr 2020 13:51:42 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0A0165C1BB for ; Mon, 6 Apr 2020 13:51:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181120; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=icXis0J7pFCjOtODlyPidSwzSqYq/Y2pEAJyfZmt0tc=; b=CSLKWAFn4dHk2C+xddJwKXwHJodL0d7mzekiFK9Bz/CNg1UqSktdp9cmbzVC2A1c0Wgx76 ZuMcXgKgIcimmUh2LR5DtIGdmHulkIuFVhFQmcXNZkQHg1GDmdmYX69H72MdTZBvL8hflH h/qXfx0Aac4g0OzLZSvgveA2yCjSE0E= X-MC-Unique: ZsQ_qJlZObC9r5NMwUSmqw-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 05/10] conf: add new PCI_CONNECT flag AUTOASSIGN Date: Mon, 6 Apr 2020 09:51:25 -0400 Message-Id: <20200406135130.3080946-6-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" This new flag will be set for any controller that we decide can have devices assigned to it automatically during PCI device assignment. In the past PCI_CONNECT_TYPE_HOTPLUGGABLE was used for this purpose, but that is overloading that flag, and no longer technically correct; what we *really* want is to auto-assign devices to any pcie-root-port or pcie-switch-downstream-port regardless of whether or not that controller happens to have hotplug enabled. This patch just adds the flag, but doesn't use it at all. Note that the numbering of all the other flags was changed in order to insert the new flag near the beginning of the list; that doesn't cause any problem because the connect flags aren't stored anywhere between runs of libvirtd. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/conf/domain_addr.h | 41 +++++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 20 deletions(-) diff --git a/src/conf/domain_addr.h b/src/conf/domain_addr.h index dcb90618f8..40738ddb72 100644 --- a/src/conf/domain_addr.h +++ b/src/conf/domain_addr.h @@ -32,26 +32,27 @@ typedef enum { } virPCIDeviceAddressExtensionFlags; =20 typedef enum { - VIR_PCI_CONNECT_HOTPLUGGABLE =3D 1 << 0, /* is hotplug needed/supported= */ - - /* set for devices that can share a single slot in auto-assignment - * (by assigning one device to each of the 8 functions on the slot) - */ - VIR_PCI_CONNECT_AGGREGATE_SLOT =3D 1 << 1, - - /* kinds of devices as a bitmap so they can be combined (some PCI - * controllers permit connecting multiple types of devices) - */ - VIR_PCI_CONNECT_TYPE_PCI_DEVICE =3D 1 << 2, - VIR_PCI_CONNECT_TYPE_PCIE_DEVICE =3D 1 << 3, - VIR_PCI_CONNECT_TYPE_PCIE_ROOT_PORT =3D 1 << 4, - VIR_PCI_CONNECT_TYPE_PCIE_SWITCH_UPSTREAM_PORT =3D 1 << 5, - VIR_PCI_CONNECT_TYPE_PCIE_SWITCH_DOWNSTREAM_PORT =3D 1 << 6, - VIR_PCI_CONNECT_TYPE_DMI_TO_PCI_BRIDGE =3D 1 << 7, - VIR_PCI_CONNECT_TYPE_PCI_EXPANDER_BUS =3D 1 << 8, - VIR_PCI_CONNECT_TYPE_PCIE_EXPANDER_BUS =3D 1 << 9, - VIR_PCI_CONNECT_TYPE_PCI_BRIDGE =3D 1 << 10, - VIR_PCI_CONNECT_TYPE_PCIE_TO_PCI_BRIDGE =3D 1 << 11, + VIR_PCI_CONNECT_AUTOASSIGN =3D 1 << 0, /* okay to autoassign a device = to this controller */ + VIR_PCI_CONNECT_HOTPLUGGABLE =3D 1 << 1, /* is hotplug needed/supporte= d */ + + /* set for devices that can share a single slot in auto-assignment + * (by assigning one device to each of the 8 functions on the slot) + */ + VIR_PCI_CONNECT_AGGREGATE_SLOT =3D 1 << 2, + + /* kinds of devices as a bitmap so they can be combined (some PCI + * controllers permit connecting multiple types of devices) + */ + VIR_PCI_CONNECT_TYPE_PCI_DEVICE =3D 1 << 3, + VIR_PCI_CONNECT_TYPE_PCIE_DEVICE =3D 1 << 4, + VIR_PCI_CONNECT_TYPE_PCIE_ROOT_PORT =3D 1 << 5, + VIR_PCI_CONNECT_TYPE_PCIE_SWITCH_UPSTREAM_PORT =3D 1 << 6, + VIR_PCI_CONNECT_TYPE_PCIE_SWITCH_DOWNSTREAM_PORT =3D 1 << 7, + VIR_PCI_CONNECT_TYPE_DMI_TO_PCI_BRIDGE =3D 1 << 8, + VIR_PCI_CONNECT_TYPE_PCI_EXPANDER_BUS =3D 1 << 9, + VIR_PCI_CONNECT_TYPE_PCIE_EXPANDER_BUS =3D 1 << 10, + VIR_PCI_CONNECT_TYPE_PCI_BRIDGE =3D 1 << 11, + VIR_PCI_CONNECT_TYPE_PCIE_TO_PCI_BRIDGE =3D 1 << 12, } virDomainPCIConnectFlags; =20 /* a combination of all bits that describe the type of connections --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181124; cv=none; d=zohomail.com; s=zohoarc; b=NKvtAw+I+cCM/hzbLIadj24hcQJm5sSO0FeZEu1tXQEmcRvYaP0S2eNftJhVKNlWkYR0WQq+MsI67egK75A88koarKG+xzSs6OIVNykU/nmUQuvFvACjRM5FyyrUnV5fign7whkTcjop2gsFbdUjz7Bc3KsvCpJwjS2X/7zBARM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181124; 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=j3tNT8DqXY5TegaL8izMBIc1VeEAXppHCc/nrtbkTTg=; b=CU8mYc973FD7Slc8Hg1Y5rwylo8O1mjhqAjluUDF9Z2r+lyQ8Fpb5QjfxmgetUhgT34CEsWEId3l6O89zppWnjW5DTFAZKw5ljHPvCdYEAG6pGPcYbokZMu5lZP/WkVg+RB2lleFjat6nTifrq3kgwDfvbrXM9TqbSkkSIUj6xY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1586181124557297.00465333636555; Mon, 6 Apr 2020 06:52:04 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-375-U1VodWXPMmuiKTPHaR6woA-1; Mon, 06 Apr 2020 09:52:00 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 544C18017F3; Mon, 6 Apr 2020 13:51:55 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 278D55D9C5; Mon, 6 Apr 2020 13:51:55 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id D490F93A63; Mon, 6 Apr 2020 13:51:54 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036Dpg0Y018363 for ; Mon, 6 Apr 2020 09:51:42 -0400 Received: by smtp.corp.redhat.com (Postfix) id D3D845C1BB; Mon, 6 Apr 2020 13:51:42 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 891E55C1B0 for ; Mon, 6 Apr 2020 13:51:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181123; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=j3tNT8DqXY5TegaL8izMBIc1VeEAXppHCc/nrtbkTTg=; b=eVSd1CyBsbXx49qs1RAG+0hymurphrYAexfW0umuU2P1pDq6nUsOBi+08sgD8wB/l2wfBs LHVNyvNkGH+4flAENaOip9DDXQOxf+mh4VclAKokLJ2tFCg3Ptw3fp17MpTeyGkeQVablc 7qmUARBglCBL+sjNbN0FzwHjbZa4WYQ= X-MC-Unique: U1VodWXPMmuiKTPHaR6woA-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 06/10] conf/qemu: s/VIR_PCI_CONNECT_HOTPLUGGABLE/VIR_PCI_CONNECT_AUTOASSIGN/g Date: Mon, 6 Apr 2020 09:51:26 -0400 Message-Id: <20200406135130.3080946-7-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" When the HOTPLUGGABLE flag was originally added, it was set for all the PCI controllers that accepted hotplugged devices, and requested for all devices that were auto-assigned to a controller. While we're still autoassigning to the same list of controllers, those controllers may or may not support hotplug, so let's use the flag that fits what we're actually doing. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/conf/domain_addr.c | 18 +++++++++--------- src/qemu/qemu_domain_address.c | 14 +++++++------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/src/conf/domain_addr.c b/src/conf/domain_addr.c index e8629b3ed8..effc223a12 100644 --- a/src/conf/domain_addr.c +++ b/src/conf/domain_addr.c @@ -362,8 +362,8 @@ virDomainPCIAddressFlagsCompatible(virPCIDeviceAddressP= tr addr, * libvirt's assumptions about whether or not hotplug * capability will be required. */ - if (devFlags & VIR_PCI_CONNECT_HOTPLUGGABLE) - busFlags |=3D VIR_PCI_CONNECT_HOTPLUGGABLE; + if (devFlags & VIR_PCI_CONNECT_AUTOASSIGN) + busFlags |=3D VIR_PCI_CONNECT_AUTOASSIGN; /* if the device is a pci-bridge, allow manually * assigning to any bus that would also accept a * standard PCI device. @@ -419,8 +419,8 @@ virDomainPCIAddressFlagsCompatible(virPCIDeviceAddressP= tr addr, addrStr, addr->bus, connectStr); return false; } - if ((devFlags & VIR_PCI_CONNECT_HOTPLUGGABLE) && - !(busFlags & VIR_PCI_CONNECT_HOTPLUGGABLE)) { + if ((devFlags & VIR_PCI_CONNECT_AUTOASSIGN) && + !(busFlags & VIR_PCI_CONNECT_AUTOASSIGN)) { if (reportError) { virReportError(errType, _("The device at PCI address %s requires " @@ -509,7 +509,7 @@ virDomainPCIAddressBusSetModel(virDomainPCIAddressBusPt= r bus, */ switch (model) { case VIR_DOMAIN_CONTROLLER_MODEL_PCI_ROOT: - bus->flags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE | + bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | VIR_PCI_CONNECT_TYPE_PCI_BRIDGE | VIR_PCI_CONNECT_TYPE_PCI_EXPANDER_BUS); @@ -517,14 +517,14 @@ virDomainPCIAddressBusSetModel(virDomainPCIAddressBus= Ptr bus, bus->maxSlot =3D VIR_PCI_ADDRESS_SLOT_LAST; break; case VIR_DOMAIN_CONTROLLER_MODEL_PCI_BRIDGE: - bus->flags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE | + bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | VIR_PCI_CONNECT_TYPE_PCI_BRIDGE); bus->minSlot =3D 1; bus->maxSlot =3D VIR_PCI_ADDRESS_SLOT_LAST; break; case VIR_DOMAIN_CONTROLLER_MODEL_PCI_EXPANDER_BUS: - bus->flags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE | + bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | VIR_PCI_CONNECT_TYPE_PCI_BRIDGE); bus->minSlot =3D 0; @@ -555,7 +555,7 @@ virDomainPCIAddressBusSetModel(virDomainPCIAddressBusPt= r bus, case VIR_DOMAIN_CONTROLLER_MODEL_PCIE_TO_PCI_BRIDGE: /* Same as pci-bridge: 32 hotpluggable traditional PCI slots (0-31= ), * the first of which is not usable because of the SHPC */ - bus->flags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE | + bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | VIR_PCI_CONNECT_TYPE_PCI_BRIDGE); bus->minSlot =3D 1; @@ -566,7 +566,7 @@ virDomainPCIAddressBusSetModel(virDomainPCIAddressBusPt= r bus, /* provides one slot which is pcie, can be used by endpoint * devices, pcie-switch-upstream-ports or pcie-to-pci-bridges, * and is hotpluggable */ - bus->flags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE | + bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCIE_DEVICE | VIR_PCI_CONNECT_TYPE_PCIE_SWITCH_UPSTREAM_PORT | VIR_PCI_CONNECT_TYPE_PCIE_TO_PCI_BRIDGE); diff --git a/src/qemu/qemu_domain_address.c b/src/qemu/qemu_domain_address.c index ab6bce19f4..f853d2003d 100644 --- a/src/qemu/qemu_domain_address.c +++ b/src/qemu/qemu_domain_address.c @@ -580,7 +580,7 @@ qemuDomainDeviceCalculatePCIConnectFlags(virDomainDevic= eDefPtr dev, virDomainPCIConnectFlags virtioFl= ags) { virDomainPCIConnectFlags pciFlags =3D (VIR_PCI_CONNECT_TYPE_PCI_DEVICE= | - VIR_PCI_CONNECT_HOTPLUGGABLE); + VIR_PCI_CONNECT_AUTOASSIGN); =20 switch ((virDomainDeviceType)dev->type) { case VIR_DOMAIN_DEVICE_CONTROLLER: { @@ -1072,17 +1072,17 @@ qemuDomainFillDevicePCIConnectFlagsIterInit(virDoma= inDefPtr def, =20 if (qemuDomainHasPCIeRoot(def)) { data->pcieFlags =3D (VIR_PCI_CONNECT_TYPE_PCIE_DEVICE | - VIR_PCI_CONNECT_HOTPLUGGABLE); + VIR_PCI_CONNECT_AUTOASSIGN); } else { data->pcieFlags =3D (VIR_PCI_CONNECT_TYPE_PCI_DEVICE | - VIR_PCI_CONNECT_HOTPLUGGABLE); + VIR_PCI_CONNECT_AUTOASSIGN); } =20 if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_VIRTIO_PCI_DISABLE_LEGACY)) { data->virtioFlags =3D data->pcieFlags; } else { data->virtioFlags =3D (VIR_PCI_CONNECT_TYPE_PCI_DEVICE | - VIR_PCI_CONNECT_HOTPLUGGABLE); + VIR_PCI_CONNECT_AUTOASSIGN); } } =20 @@ -1736,7 +1736,7 @@ qemuDomainValidateDevicePCISlotsPIIX3(virDomainDefPtr= def, virPCIDeviceAddress tmp_addr; bool qemuDeviceVideoUsable =3D virQEMUCapsGet(qemuCaps, QEMU_CAPS_DEVI= CE_VIDEO_PRIMARY); g_autofree char *addrStr =3D NULL; - virDomainPCIConnectFlags flags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE + virDomainPCIConnectFlags flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE); =20 /* Verify that first IDE and USB controllers (if any) is on the PIIX3,= fn 1 */ @@ -2673,7 +2673,7 @@ qemuDomainAssignPCIAddresses(virDomainDefPtr def, * domain. */ virDomainDeviceInfo info =3D { - .pciConnectFlags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE | + .pciConnectFlags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE), .pciAddrExtFlags =3D VIR_PCI_ADDRESS_EXTENSION_NONE }; @@ -2714,7 +2714,7 @@ qemuDomainAssignPCIAddresses(virDomainDefPtr def, addrs->nbuses > max_idx + 1 && qemuDomainHasPCIeRoot(def)) { virDomainDeviceInfo info =3D { - .pciConnectFlags =3D (VIR_PCI_CONNECT_HOTPLUGGABLE | + .pciConnectFlags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCIE_DEVICE), .pciAddrExtFlags =3D VIR_PCI_ADDRESS_EXTENSION_NONE }; --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181149; cv=none; d=zohomail.com; s=zohoarc; b=XPg//jaB+J91wsiA77tzG32HRS0eaZmATFS9GrqFQ1oR+9AQ7r/CeC2nY9rObODlbun383U+tgdY8Tg6csSFRRLACPlHXl/zBTyU4PXYbybQkEdL9SM6RSWMqCLin0T0n7YX9QT776McHn/zm/E2GGJaeqp/TANRCErfD1702S8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181149; 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=QNBeLqrrzD22/AwM3ZtGcjC99ko6oGFDJAVuzlpyyhg=; b=YFMb6mA35vPw2g8jkgR937ccxgRbfnOIhbpuQa3tNQxJvpGcn3SGKj82dYSSm2ldL1I0OupNYrUcXUdZpg/YBuTMhuBh2ztVOVtlz9TCMCjZNL6I2+HqygteNFdAAJSqLcDfSghHvnBVDGgNE38inm6KAAiVqv+7aFELuEaUkcc= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1586181149659566.0149324141571; Mon, 6 Apr 2020 06:52:29 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-65-9LN7xZizOcSVoHICavrNDA-1; Mon, 06 Apr 2020 09:52:26 -0400 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 9468618B9FC2; Mon, 6 Apr 2020 13:52:18 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6DC465C1B0; Mon, 6 Apr 2020 13:52:18 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 2878993A73; Mon, 6 Apr 2020 13:52:18 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036DphYw018368 for ; Mon, 6 Apr 2020 09:51:43 -0400 Received: by smtp.corp.redhat.com (Postfix) id 5C8D25C28F; Mon, 6 Apr 2020 13:51:43 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0E7AB5C1B0 for ; Mon, 6 Apr 2020 13:51:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181148; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=QNBeLqrrzD22/AwM3ZtGcjC99ko6oGFDJAVuzlpyyhg=; b=bUuhBihW1gGmbS+UnHr/buGk1vsgEUi/P1+Xf93/DyW7Pgboa18wNIV6ja1btvbeRoJCn7 ilWWzsNsyAR6NMXyVDgekbpNL2rLu23zMQHg9SE/OENIAkZp6CLJ6lQuMX7PR2VahuZsYi qlYpOYAFl+OY/c/QOLRlSIKUpXpY1tY= X-MC-Unique: 9LN7xZizOcSVoHICavrNDA-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 07/10] conf: simplify logic when checking for AUTOASSIGN PCI addresses Date: Mon, 6 Apr 2020 09:51:27 -0400 Message-Id: <20200406135130.3080946-8-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Old behavior: If the address was manually provided by config, copy device AUTOASSIGN flag into the bus flag, and then later on in the function *always* check for a match of the flags (which will always match if the address came from config, since we just copied it). New behavior: Don't mess with the bus flags - just directly check if the AUTOASSIGN flag matches in bus and dev, but only make the check if the address didn't come from config (i.e. it was auto-assigned by libvirt). Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/conf/domain_addr.c | 27 ++++++++++----------------- 1 file changed, 10 insertions(+), 17 deletions(-) diff --git a/src/conf/domain_addr.c b/src/conf/domain_addr.c index effc223a12..429550e970 100644 --- a/src/conf/domain_addr.c +++ b/src/conf/domain_addr.c @@ -358,18 +358,22 @@ virDomainPCIAddressFlagsCompatible(virPCIDeviceAddres= sPtr addr, */ if (busFlags & VIR_PCI_CONNECT_TYPES_ENDPOINT) busFlags |=3D VIR_PCI_CONNECT_TYPES_ENDPOINT; - /* Also allow manual specification of bus to override - * libvirt's assumptions about whether or not hotplug - * capability will be required. - */ - if (devFlags & VIR_PCI_CONNECT_AUTOASSIGN) - busFlags |=3D VIR_PCI_CONNECT_AUTOASSIGN; /* if the device is a pci-bridge, allow manually * assigning to any bus that would also accept a * standard PCI device. */ if (devFlags & VIR_PCI_CONNECT_TYPE_PCI_BRIDGE) devFlags |=3D VIR_PCI_CONNECT_TYPE_PCI_DEVICE; + } else if ((devFlags & VIR_PCI_CONNECT_AUTOASSIGN) && + !(busFlags & VIR_PCI_CONNECT_AUTOASSIGN)) { + if (reportError) { + virReportError(errType, + _("The device at PCI address %s was auto-assign= ed " + "this address, but the PCI controller " + "with index=3D'%d' doesn't allow auto-assignm= ent"), + addrStr, addr->bus); + } + return false; } =20 /* If this bus doesn't allow the type of connection (PCI @@ -419,17 +423,6 @@ virDomainPCIAddressFlagsCompatible(virPCIDeviceAddress= Ptr addr, addrStr, addr->bus, connectStr); return false; } - if ((devFlags & VIR_PCI_CONNECT_AUTOASSIGN) && - !(busFlags & VIR_PCI_CONNECT_AUTOASSIGN)) { - if (reportError) { - virReportError(errType, - _("The device at PCI address %s requires " - "hotplug capability, but the PCI controller " - "with index=3D'%d' doesn't support hotplug"), - addrStr, addr->bus); - } - return false; - } return true; } =20 --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181153; cv=none; d=zohomail.com; s=zohoarc; b=CK9A2Q1S09jOy0pbGrTG7terezlT28X/xZZtVs6yE+Dc/gTQRmTk28qnIc7M0evX+56WOXw2eJcD9T0xUof8we1VIbUR7v1t8jQPsHocFMDlQzseiCKXcoCGC/wQgQOwOYCPTpVcoSlmb6A+I7tsZqbr3hiHsZbm7YXR9pKpYXs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181153; 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=j1sooogH6Col6kfbFsZoE+r0QI1LmqvQ6aYJ1XpcpE4=; b=kN/jHGNP0MzmnD3Wq6yf/+wAhD+kzPcmq6UrvLVgCQqllCrViWRcVj/ZXKJx+gm+eWfb1OloAnjvbZZvhDCWjRzgtKD0Iev2CymwCAb91sBnMjx/m7PgrIrCKlzD6tynOVgz3cdwpYSVKt++1zZfzg/1PI2mXkjRA6kfL6DAfls= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1586181153884725.5718586780481; Mon, 6 Apr 2020 06:52:33 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-430-LaisnrMYMiejVlQL-PcVTQ-1; Mon, 06 Apr 2020 09:52:29 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id D4DE618B9FD9; Mon, 6 Apr 2020 13:52:22 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A331560C84; Mon, 6 Apr 2020 13:52:22 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 5C65118089D0; Mon, 6 Apr 2020 13:52:22 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036Dphp6018379 for ; Mon, 6 Apr 2020 09:51:43 -0400 Received: by smtp.corp.redhat.com (Postfix) id D4ADC5C1BB; Mon, 6 Apr 2020 13:51:43 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 8A9975C1B0 for ; Mon, 6 Apr 2020 13:51:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181152; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=j1sooogH6Col6kfbFsZoE+r0QI1LmqvQ6aYJ1XpcpE4=; b=cwrNFJ9fc/71pd85LG1YbTe/bUHqEJJXFf0oay3JlhHtaaNhUYc/H9b7uqDKEQHPa7llcn 7nO4cf7kxFaWkMRPkDstm6zFEP4UUfc0qP4f/144SyCC3T2l0Y17jhkjy6lqxaHcLaHA67 /WYBBpCt2K9FJkCpEft3dbcsvBpJWiM= X-MC-Unique: LaisnrMYMiejVlQL-PcVTQ-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 08/10] qemu/conf: set HOTPLUGGABLE connect flag during PCI address set init Date: Mon, 6 Apr 2020 09:51:28 -0400 Message-Id: <20200406135130.3080946-9-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" virDomainPCIAddressBusSetModel() is called for each PCI controller when building an address set prior to assiging PCI addresses to devices. This patch adds a new argument, allowHotplug, to that function that can be set to false if we know for certain that a particular controller won't support hotplug The most interesting case is in qemuDomainPCIAddressSetCreate(), where the config of each existing controller is available while building the address set, so we can appropriately set allowHotplug =3D false when the user has "hotplug=3D'off'" in the config of a controller that normally would support hotplug. In all other cases, it is set to true or false in accordance with the capability of the controller model. So far we aren't doing anything with this bus flag in the address set. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/conf/domain_addr.c | 31 +++++++++++++++++++++---------- src/conf/domain_addr.h | 3 ++- src/qemu/qemu_domain_address.c | 10 +++++++--- 3 files changed, 30 insertions(+), 14 deletions(-) diff --git a/src/conf/domain_addr.c b/src/conf/domain_addr.c index 429550e970..b58989ac8b 100644 --- a/src/conf/domain_addr.c +++ b/src/conf/domain_addr.c @@ -495,31 +495,40 @@ virDomainPCIAddressValidate(virDomainPCIAddressSetPtr= addrs, =20 int virDomainPCIAddressBusSetModel(virDomainPCIAddressBusPtr bus, - virDomainControllerModelPCI model) + virDomainControllerModelPCI model, + bool allowHotplug) { /* set flags for what can be connected *downstream* from each * bus. */ + virDomainPCIConnectFlags hotplugFlag =3D 0; + + if (allowHotplug) + hotplugFlag =3D VIR_PCI_CONNECT_HOTPLUGGABLE; + switch (model) { case VIR_DOMAIN_CONTROLLER_MODEL_PCI_ROOT: bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | VIR_PCI_CONNECT_TYPE_PCI_BRIDGE | - VIR_PCI_CONNECT_TYPE_PCI_EXPANDER_BUS); + VIR_PCI_CONNECT_TYPE_PCI_EXPANDER_BUS | + hotplugFlag); bus->minSlot =3D 1; bus->maxSlot =3D VIR_PCI_ADDRESS_SLOT_LAST; break; case VIR_DOMAIN_CONTROLLER_MODEL_PCI_BRIDGE: bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | - VIR_PCI_CONNECT_TYPE_PCI_BRIDGE); + VIR_PCI_CONNECT_TYPE_PCI_BRIDGE | + hotplugFlag); bus->minSlot =3D 1; bus->maxSlot =3D VIR_PCI_ADDRESS_SLOT_LAST; break; case VIR_DOMAIN_CONTROLLER_MODEL_PCI_EXPANDER_BUS: bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | - VIR_PCI_CONNECT_TYPE_PCI_BRIDGE); + VIR_PCI_CONNECT_TYPE_PCI_BRIDGE | + hotplugFlag); bus->minSlot =3D 0; bus->maxSlot =3D VIR_PCI_ADDRESS_SLOT_LAST; break; @@ -550,7 +559,8 @@ virDomainPCIAddressBusSetModel(virDomainPCIAddressBusPt= r bus, * the first of which is not usable because of the SHPC */ bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCI_DEVICE | - VIR_PCI_CONNECT_TYPE_PCI_BRIDGE); + VIR_PCI_CONNECT_TYPE_PCI_BRIDGE | + hotplugFlag); bus->minSlot =3D 1; bus->maxSlot =3D VIR_PCI_ADDRESS_SLOT_LAST; break; @@ -562,7 +572,8 @@ virDomainPCIAddressBusSetModel(virDomainPCIAddressBusPt= r bus, bus->flags =3D (VIR_PCI_CONNECT_AUTOASSIGN | VIR_PCI_CONNECT_TYPE_PCIE_DEVICE | VIR_PCI_CONNECT_TYPE_PCIE_SWITCH_UPSTREAM_PORT | - VIR_PCI_CONNECT_TYPE_PCIE_TO_PCI_BRIDGE); + VIR_PCI_CONNECT_TYPE_PCIE_TO_PCI_BRIDGE | + hotplugFlag); bus->minSlot =3D 0; bus->maxSlot =3D 0; break; @@ -759,7 +770,7 @@ virDomainPCIAddressSetGrow(virDomainPCIAddressSetPtr ad= drs, * rest are of the requested type */ if (virDomainPCIAddressBusSetModel(&addrs->buses[i++], - VIR_DOMAIN_CONTROLLER_MODEL_DMI= _TO_PCI_BRIDGE) < 0) { + VIR_DOMAIN_CONTROLLER_MODEL_DMI= _TO_PCI_BRIDGE, false) < 0) { return -1; } } @@ -776,20 +787,20 @@ virDomainPCIAddressSetGrow(virDomainPCIAddressSetPtr = addrs, * will be allocated for the dummy PCIe device later on. */ if (virDomainPCIAddressBusSetModel(&addrs->buses[i], - VIR_DOMAIN_CONTROLLER_MODEL_PCI= E_ROOT_PORT) < 0) { + VIR_DOMAIN_CONTROLLER_MODEL_PCI= E_ROOT_PORT, true) < 0) { return -1; } addrs->buses[i].flags =3D VIR_PCI_CONNECT_TYPE_PCIE_TO_PCI_BRIDGE; i++; =20 if (virDomainPCIAddressBusSetModel(&addrs->buses[i++], - VIR_DOMAIN_CONTROLLER_MODEL_PCI= E_TO_PCI_BRIDGE) < 0) { + VIR_DOMAIN_CONTROLLER_MODEL_PCI= E_TO_PCI_BRIDGE, true) < 0) { return -1; } } =20 for (; i < addrs->nbuses; i++) { - if (virDomainPCIAddressBusSetModel(&addrs->buses[i], model) < 0) + if (virDomainPCIAddressBusSetModel(&addrs->buses[i], model, true) = < 0) return -1; } =20 diff --git a/src/conf/domain_addr.h b/src/conf/domain_addr.h index 40738ddb72..c1363c1490 100644 --- a/src/conf/domain_addr.h +++ b/src/conf/domain_addr.h @@ -148,7 +148,8 @@ bool virDomainPCIAddressValidate(virDomainPCIAddressSet= Ptr addrs, =20 =20 int virDomainPCIAddressBusSetModel(virDomainPCIAddressBusPtr bus, - virDomainControllerModelPCI model) + virDomainControllerModelPCI model, + bool allowHotplug) ATTRIBUTE_NONNULL(1); =20 bool virDomainPCIAddressBusIsFullyReserved(virDomainPCIAddressBusPtr bus) diff --git a/src/qemu/qemu_domain_address.c b/src/qemu/qemu_domain_address.c index f853d2003d..07431343ed 100644 --- a/src/qemu/qemu_domain_address.c +++ b/src/qemu/qemu_domain_address.c @@ -1652,6 +1652,7 @@ qemuDomainPCIAddressSetCreate(virDomainDefPtr def, for (i =3D 0; i < def->ncontrollers; i++) { virDomainControllerDefPtr cont =3D def->controllers[i]; size_t idx =3D cont->idx; + bool allowHotplug =3D false; =20 if (cont->type !=3D VIR_DOMAIN_CONTROLLER_TYPE_PCI) continue; @@ -1663,7 +1664,10 @@ qemuDomainPCIAddressSetCreate(virDomainDefPtr def, goto error; } =20 - if (virDomainPCIAddressBusSetModel(&addrs->buses[idx], cont->model= ) < 0) + if (cont->opts.pciopts.hotplug !=3D VIR_TRISTATE_SWITCH_OFF) + allowHotplug =3D true; + + if (virDomainPCIAddressBusSetModel(&addrs->buses[idx], cont->model= , allowHotplug) < 0) goto error; =20 /* Forward the information about isolation groups */ @@ -1681,7 +1685,7 @@ qemuDomainPCIAddressSetCreate(virDomainDefPtr def, * assigning addresses to devices. */ if (virDomainPCIAddressBusSetModel(&addrs->buses[0], - VIR_DOMAIN_CONTROLLER_MODEL_PCI= _ROOT) < 0) + VIR_DOMAIN_CONTROLLER_MODEL_PCI= _ROOT, true) < 0) goto error; } =20 @@ -1703,7 +1707,7 @@ qemuDomainPCIAddressSetCreate(virDomainDefPtr def, if (addrs->buses[i].model) continue; =20 - if (virDomainPCIAddressBusSetModel(&addrs->buses[i], defaultModel)= < 0) + if (virDomainPCIAddressBusSetModel(&addrs->buses[i], defaultModel,= true) < 0) goto error; =20 VIR_DEBUG("Auto-adding ", --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181161; cv=none; d=zohomail.com; s=zohoarc; b=Amd0ZbtL5iT8t12pbu9l4oxVDD7Gk2SXSzE8ABTg7M8cDvCHHsVswu+FXSPCBtuVLS93HjmIk/HmuxRLHlDuQIofME4w4PAJ91Nte/mBUOjZon8VK9BXwBvJXQPgBeHKidlumHpl/f6jBaq2iYrSrNHIbpH15d55lAS9yET99Ys= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181161; 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=rOY2gmQiADaJqB2fg7+0YKoW7vSr1SOoZ3WqtSi4hUU=; b=aw8nCcRVqwXb6z5S/uxCw7CfYyPRh5ENP0Hvh4v9tMltqDBEtbxmTfzRPY8F4XRYs3vcjxDiQQgkKGD3hVHay6z8MBZU3xyZ20ma4xZMdHyhMvj3u/D1vkWVU5jukBXkZSdD1D/5m/xork+KDJ1dGRBNjC0rqqjF1hgvtxTTyLI= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1586181161496767.038955029588; Mon, 6 Apr 2020 06:52:41 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-131-lN6LWIY-N3-gk3tcGPZKSg-1; Mon, 06 Apr 2020 09:52:33 -0400 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id B58901005509; Mon, 6 Apr 2020 13:52:26 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 85791A0A8D; Mon, 6 Apr 2020 13:52:26 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 35A5093A74; Mon, 6 Apr 2020 13:52:26 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036Dpihh018392 for ; Mon, 6 Apr 2020 09:51:44 -0400 Received: by smtp.corp.redhat.com (Postfix) id 5BDE75C1BB; Mon, 6 Apr 2020 13:51:44 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 0F4585C1B0 for ; Mon, 6 Apr 2020 13:51:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181160; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=rOY2gmQiADaJqB2fg7+0YKoW7vSr1SOoZ3WqtSi4hUU=; b=HRXB0jsBHoqYjI7i75TuP9glo0Dci6e+UC17M8J0m1nkGno0+U+lmA4FLwkucI71vnH2I/ b11vdCvf08n0eil6jfyYgFE4jKLWg8GXhwqdC/xfrXTKJzfOTIvGht7H6WRtT6tq2mk+lx lJNGu6EqKGk9eNyicmktj61pLYCauLk= X-MC-Unique: lN6LWIY-N3-gk3tcGPZKSg-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 09/10] conf: check HOTPLUGGABLE connect flag when validating a PCI address Date: Mon, 6 Apr 2020 09:51:29 -0400 Message-Id: <20200406135130.3080946-10-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The HOTPLUGGABLE flag is set for appropriates buses in a PCI address set, and thnis patch updates virDomainPCIAddressFlagsCompatible() to check the HOTPLUGGABLE flag when searching for a suitable bus/slot for a device. No devices request HOTPLUGGABLE though (yet), so there is no observable effect. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/conf/domain_addr.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/conf/domain_addr.c b/src/conf/domain_addr.c index b58989ac8b..580cf7e64d 100644 --- a/src/conf/domain_addr.c +++ b/src/conf/domain_addr.c @@ -376,6 +376,18 @@ virDomainPCIAddressFlagsCompatible(virPCIDeviceAddress= Ptr addr, return false; } =20 + if ((devFlags & VIR_PCI_CONNECT_HOTPLUGGABLE) && + !(busFlags & VIR_PCI_CONNECT_HOTPLUGGABLE)) { + if (reportError) { + virReportError(errType, + _("The device at PCI address %s requires " + "hotplug capability, but the PCI controller " + "with index=3D'%d' doesn't support hotplug"), + addrStr, addr->bus); + } + return false; + } + /* If this bus doesn't allow the type of connection (PCI * vs. PCIe) required by the device, or if the device requires * hot-plug and this bus doesn't have it, return false. --=20 2.25.2 From nobody Wed May 15 12:42:00 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1586181128; cv=none; d=zohomail.com; s=zohoarc; b=NtJ1XqpqoRSQkbpqylFVL82BLIhkM7FWviD6VWO18N3VcNYXY88+24hGZLa4qfQpMj4BKp9nkUI6t8IyYMpqQuWwKtnBQljFV6/xh+rUDFzSKat7mOLk/Y8HwXGZB5eRX6DMLm4GQtQCegKGwebBgyif0yT4JBpPBrbm4HGK7ZY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1586181128; 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=0VqjLvdQt1sdVFlWPUlxYQVgn6oNO/kFyysbrHGVAhY=; b=LSJa/o2RO/bomA9j2WEJC+ANcX9paVs77o3NypxdEbqiiRFAMQDrZu2Y17eC5TOYqiQi8x8Eg4yKe2bOeacCO5eFyj7YaclH9lOOcbtIrxm1KYj1drcoqUxXUn3CjvxkgSZTqUcvHiZqz1y1ioyPDXXgsbdBcqxnZy7CeULVX10= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1586181128495863.1472843369429; Mon, 6 Apr 2020 06:52:08 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-293-nM4icadrNKWBXaaBLKSbaQ-1; Mon, 06 Apr 2020 09:52:05 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 0790D18B9FC7; Mon, 6 Apr 2020 13:51:59 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id D422662697; Mon, 6 Apr 2020 13:51:58 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 9460318089CF; Mon, 6 Apr 2020 13:51:58 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 036DpiNj018404 for ; Mon, 6 Apr 2020 09:51:44 -0400 Received: by smtp.corp.redhat.com (Postfix) id D99FE5C1BB; Mon, 6 Apr 2020 13:51:44 +0000 (UTC) Received: from vhost2.laine.org (ovpn-112-243.phx2.redhat.com [10.3.112.243]) by smtp.corp.redhat.com (Postfix) with ESMTP id 8E25D5C1B0 for ; Mon, 6 Apr 2020 13:51:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1586181127; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=0VqjLvdQt1sdVFlWPUlxYQVgn6oNO/kFyysbrHGVAhY=; b=dDH9XFqyCHm8o/ndDgbHtJz2e9XKQ0FznjDctagJxa9qD7HtGwu3F/6OgyUvlIPhrKZRKB 829wHnCAy6yYL1nKEJppcfeFcndc3E4/gjZneOAea9Y5Ogst6a84fIY8vwvgkp54rsBnMT T54SC6gpmUM0CX+LXHelJdBZ23Y89Eo= X-MC-Unique: nM4icadrNKWBXaaBLKSbaQ-1 From: Laine Stump To: libvir-list@redhat.com Subject: [libvirt PATCH 10/10] conf: during PCI hotplug, require that the controller support hotplug Date: Mon, 6 Apr 2020 09:51:30 -0400 Message-Id: <20200406135130.3080946-11-laine@redhat.com> In-Reply-To: <20200406135130.3080946-1-laine@redhat.com> References: <20200406135130.3080946-1-laine@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Before this patch we would simply rely on QEMU failing to attach the device. Since we have a flag in the address set telling us which controllers support hotplug, we can fail the operation sooner. This also assures that when hotplugging with no provided PCI address, that we skip any controllers with hotplug=3D'off', and attempt to assign the device to a controller that not only supports hotplug, but also has it enabled. Signed-off-by: Laine Stump Reviewed-by: Michal Privoznik --- src/conf/domain_addr.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/conf/domain_addr.c b/src/conf/domain_addr.c index 580cf7e64d..5652bc9a33 100644 --- a/src/conf/domain_addr.c +++ b/src/conf/domain_addr.c @@ -931,6 +931,11 @@ virDomainPCIAddressEnsureAddr(virDomainPCIAddressSetPt= r addrs, if (!flags) return 0; =20 + /* This function is only called during hotplug, so we require hotplug + * support from the controller. + */ + flags |=3D VIR_PCI_CONNECT_HOTPLUGGABLE; + if (!(addrStr =3D virPCIDeviceAddressAsString(&dev->addr.pci))) return -1; =20 --=20 2.25.2