From patchwork Wed Apr 27 18:29:22 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cole Robinson X-Patchwork-Id: 66823 Delivered-To: patch@linaro.org Received: by 10.140.93.198 with SMTP id d64csp2345815qge; Wed, 27 Apr 2016 11:32:28 -0700 (PDT) X-Received: by 10.28.16.136 with SMTP id 130mr5378581wmq.23.1461781948578; Wed, 27 Apr 2016 11:32:28 -0700 (PDT) Return-Path: Received: from mx6-phx2.redhat.com (mx6-phx2.redhat.com. [209.132.183.39]) by mx.google.com with ESMTPS id d64si32186752wma.108.2016.04.27.11.32.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Apr 2016 11:32:28 -0700 (PDT) Received-SPF: pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.39 as permitted sender) client-ip=209.132.183.39; Authentication-Results: mx.google.com; spf=pass (google.com: domain of libvir-list-bounces@redhat.com designates 209.132.183.39 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by mx6-phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u3RITf1v029312; Wed, 27 Apr 2016 14:29:41 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id u3RITT0g004049 for ; Wed, 27 Apr 2016 14:29:29 -0400 Received: from colepc.redhat.com (ovpn-113-44.phx2.redhat.com [10.3.113.44]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u3RITRjP002489; Wed, 27 Apr 2016 14:29:29 -0400 From: Cole Robinson To: libvirt-list@redhat.com Date: Wed, 27 Apr 2016 14:29:22 -0400 Message-Id: <0989da590757549b851c1e36c9f9bac2354e7ae5.1461781613.git.crobinso@redhat.com> In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 2/3] qemu: caps: introduce QEMU_CAPS_NEC_USB_XHCI_PORTS 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: , MIME-Version: 1.0 Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com Reports whether we support -device nec-usb-xhci,p3=XXX value, which has been available since qemu 1.3.0 --- src/qemu/qemu_capabilities.c | 7 ++++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_1.2.2-1.replies | 11 +++++++ tests/qemucapabilitiesdata/caps_1.3.1-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.3.1-1.replies | 29 +++++++++++++++++ tests/qemucapabilitiesdata/caps_1.4.2-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.4.2-1.replies | 29 +++++++++++++++++ tests/qemucapabilitiesdata/caps_1.5.3-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.5.3-1.replies | 29 +++++++++++++++++ tests/qemucapabilitiesdata/caps_1.6.0-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.6.0-1.replies | 29 +++++++++++++++++ tests/qemucapabilitiesdata/caps_1.6.50-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.6.50-1.replies | 29 +++++++++++++++++ tests/qemucapabilitiesdata/caps_2.1.1-1.caps | 1 + tests/qemucapabilitiesdata/caps_2.1.1-1.replies | 33 +++++++++++++++++++ tests/qemucapabilitiesdata/caps_2.4.0-1.caps | 1 + tests/qemucapabilitiesdata/caps_2.4.0-1.replies | 41 ++++++++++++++++++++++++ tests/qemucapabilitiesdata/caps_2.5.0-1.caps | 1 + tests/qemucapabilitiesdata/caps_2.5.0-1.replies | 41 ++++++++++++++++++++++++ tests/qemucapabilitiesdata/caps_2.6.0-1.caps | 1 + tests/qemucapabilitiesdata/caps_2.6.0-1.replies | 41 ++++++++++++++++++++++++ 21 files changed, 329 insertions(+) -- 2.7.4 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c index de54788..188ddd1 100644 --- a/src/qemu/qemu_capabilities.c +++ b/src/qemu/qemu_capabilities.c @@ -325,6 +325,7 @@ VIR_ENUM_IMPL(virQEMUCaps, QEMU_CAPS_LAST, "pxb", "pxb-pcie", /* 220 */ + "nec-usb-xhci-ports", ); @@ -1683,6 +1684,10 @@ static struct virQEMUCapsStringFlags virQEMUCapsObjectPropsICH9[] = { { "disable_s4", QEMU_CAPS_ICH9_DISABLE_S4 }, }; +static struct virQEMUCapsStringFlags virQEMUCapsObjectPropsUSBNECXHCI[] = { + { "p3", QEMU_CAPS_NEC_USB_XHCI_PORTS }, +}; + struct virQEMUCapsObjectTypeProps { const char *type; struct virQEMUCapsStringFlags *props; @@ -1746,6 +1751,8 @@ static struct virQEMUCapsObjectTypeProps virQEMUCapsObjectProps[] = { ARRAY_CARDINALITY(virQEMUCapsObjectPropsVirtioBalloon) }, { "virtio-balloon-device", virQEMUCapsObjectPropsVirtioBalloon, ARRAY_CARDINALITY(virQEMUCapsObjectPropsVirtioBalloon) }, + { "nec-usb-xhci", virQEMUCapsObjectPropsUSBNECXHCI, + ARRAY_CARDINALITY(virQEMUCapsObjectPropsUSBNECXHCI) }, }; diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h index 83b8be3..b4b75a5 100644 --- a/src/qemu/qemu_capabilities.h +++ b/src/qemu/qemu_capabilities.h @@ -356,6 +356,7 @@ typedef enum { /* 220 */ QEMU_CAPS_DEVICE_PXB_PCIE, /* -device pxb-pcie */ + QEMU_CAPS_NEC_USB_XHCI_PORTS, /* -device nec-usb-xhci.p3 ports settin */ QEMU_CAPS_LAST /* this must always be the last item */ } virQEMUCapsFlags; diff --git a/tests/qemucapabilitiesdata/caps_1.2.2-1.replies b/tests/qemucapabilitiesdata/caps_1.2.2-1.replies index fbddf3d..2aa13f1 100644 --- a/tests/qemucapabilitiesdata/caps_1.2.2-1.replies +++ b/tests/qemucapabilitiesdata/caps_1.2.2-1.replies @@ -1668,6 +1668,17 @@ } } + +{ + "return": [ + { + "name": "msi", + "type": "uint32" + } + ] +} + + { "return": [ { diff --git a/tests/qemucapabilitiesdata/caps_1.3.1-1.caps b/tests/qemucapabilitiesdata/caps_1.3.1-1.caps index 8c237ef..7c12521 100644 --- a/tests/qemucapabilitiesdata/caps_1.3.1-1.caps +++ b/tests/qemucapabilitiesdata/caps_1.3.1-1.caps @@ -128,4 +128,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_1.3.1-1.replies b/tests/qemucapabilitiesdata/caps_1.3.1-1.replies index 2542b67..d130ad7 100644 --- a/tests/qemucapabilitiesdata/caps_1.3.1-1.replies +++ b/tests/qemucapabilitiesdata/caps_1.3.1-1.replies @@ -1849,6 +1849,35 @@ { "return": [ { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ + "return": [ + { "name": "xenpv" }, { diff --git a/tests/qemucapabilitiesdata/caps_1.4.2-1.caps b/tests/qemucapabilitiesdata/caps_1.4.2-1.caps index fe98a57..528f2fe 100644 --- a/tests/qemucapabilitiesdata/caps_1.4.2-1.caps +++ b/tests/qemucapabilitiesdata/caps_1.4.2-1.caps @@ -129,4 +129,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_1.4.2-1.replies b/tests/qemucapabilitiesdata/caps_1.4.2-1.replies index 46c3292..93e705f 100644 --- a/tests/qemucapabilitiesdata/caps_1.4.2-1.replies +++ b/tests/qemucapabilitiesdata/caps_1.4.2-1.replies @@ -1897,6 +1897,35 @@ { "return": [ { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ + "return": [ + { "name": "xenpv" }, { diff --git a/tests/qemucapabilitiesdata/caps_1.5.3-1.caps b/tests/qemucapabilitiesdata/caps_1.5.3-1.caps index 6e9ec3e..9f4b8cd 100644 --- a/tests/qemucapabilitiesdata/caps_1.5.3-1.caps +++ b/tests/qemucapabilitiesdata/caps_1.5.3-1.caps @@ -138,4 +138,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_1.5.3-1.replies b/tests/qemucapabilitiesdata/caps_1.5.3-1.replies index 37a735f..878d5ef 100644 --- a/tests/qemucapabilitiesdata/caps_1.5.3-1.replies +++ b/tests/qemucapabilitiesdata/caps_1.5.3-1.replies @@ -1968,6 +1968,35 @@ { "return": [ { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ + "return": [ + { "name": "pc-q35-1.4", "cpu-max": 255 }, diff --git a/tests/qemucapabilitiesdata/caps_1.6.0-1.caps b/tests/qemucapabilitiesdata/caps_1.6.0-1.caps index da371a4..b0ec7a9 100644 --- a/tests/qemucapabilitiesdata/caps_1.6.0-1.caps +++ b/tests/qemucapabilitiesdata/caps_1.6.0-1.caps @@ -144,4 +144,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_1.6.0-1.replies b/tests/qemucapabilitiesdata/caps_1.6.0-1.replies index 8932702..070bc62 100644 --- a/tests/qemucapabilitiesdata/caps_1.6.0-1.replies +++ b/tests/qemucapabilitiesdata/caps_1.6.0-1.replies @@ -2030,6 +2030,35 @@ { "return": [ { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ + "return": [ + { "name": "xenpv", "cpu-max": 1 }, diff --git a/tests/qemucapabilitiesdata/caps_1.6.50-1.caps b/tests/qemucapabilitiesdata/caps_1.6.50-1.caps index 1e2fb6a..bf9b53f 100644 --- a/tests/qemucapabilitiesdata/caps_1.6.50-1.caps +++ b/tests/qemucapabilitiesdata/caps_1.6.50-1.caps @@ -144,4 +144,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_1.6.50-1.replies b/tests/qemucapabilitiesdata/caps_1.6.50-1.replies index b9bb9a3..0a37e12 100644 --- a/tests/qemucapabilitiesdata/caps_1.6.50-1.replies +++ b/tests/qemucapabilitiesdata/caps_1.6.50-1.replies @@ -1994,6 +1994,35 @@ { "return": [ { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ + "return": [ + { "name": "xenpv", "cpu-max": 1 }, diff --git a/tests/qemucapabilitiesdata/caps_2.1.1-1.caps b/tests/qemucapabilitiesdata/caps_2.1.1-1.caps index 8175743..f0c141a 100644 --- a/tests/qemucapabilitiesdata/caps_2.1.1-1.caps +++ b/tests/qemucapabilitiesdata/caps_2.1.1-1.caps @@ -162,4 +162,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_2.1.1-1.replies b/tests/qemucapabilitiesdata/caps_2.1.1-1.replies index fabda55..02f1f4e 100644 --- a/tests/qemucapabilitiesdata/caps_2.1.1-1.replies +++ b/tests/qemucapabilitiesdata/caps_2.1.1-1.replies @@ -2450,6 +2450,39 @@ } { + "return": [ + { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "superspeed-ports-first", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ "return": [ { "name": "pc-1.3", diff --git a/tests/qemucapabilitiesdata/caps_2.4.0-1.caps b/tests/qemucapabilitiesdata/caps_2.4.0-1.caps index 2cdf961..32e9304 100644 --- a/tests/qemucapabilitiesdata/caps_2.4.0-1.caps +++ b/tests/qemucapabilitiesdata/caps_2.4.0-1.caps @@ -174,4 +174,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_2.4.0-1.replies b/tests/qemucapabilitiesdata/caps_2.4.0-1.replies index 299fdfc..fd17a0b 100644 --- a/tests/qemucapabilitiesdata/caps_2.4.0-1.replies +++ b/tests/qemucapabilitiesdata/caps_2.4.0-1.replies @@ -2969,6 +2969,47 @@ } { + "return": [ + { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "superspeed-ports-first", + "type": "on/off" + }, + { + "name": "force-pcie-endcap", + "type": "on/off" + }, + { + "name": "streams", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ "return": [ { "name": "pc-i440fx-2.4", diff --git a/tests/qemucapabilitiesdata/caps_2.5.0-1.caps b/tests/qemucapabilitiesdata/caps_2.5.0-1.caps index ecaa165..d572971 100644 --- a/tests/qemucapabilitiesdata/caps_2.5.0-1.caps +++ b/tests/qemucapabilitiesdata/caps_2.5.0-1.caps @@ -175,4 +175,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_2.5.0-1.replies b/tests/qemucapabilitiesdata/caps_2.5.0-1.replies index 7b692b5..f25b105 100644 --- a/tests/qemucapabilitiesdata/caps_2.5.0-1.replies +++ b/tests/qemucapabilitiesdata/caps_2.5.0-1.replies @@ -2989,6 +2989,47 @@ } { + "return": [ + { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "superspeed-ports-first", + "type": "on/off" + }, + { + "name": "force-pcie-endcap", + "type": "on/off" + }, + { + "name": "streams", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ "return": [ { "name": "pc-i440fx-2.4", diff --git a/tests/qemucapabilitiesdata/caps_2.6.0-1.caps b/tests/qemucapabilitiesdata/caps_2.6.0-1.caps index e243f8a..75e7919 100644 --- a/tests/qemucapabilitiesdata/caps_2.6.0-1.caps +++ b/tests/qemucapabilitiesdata/caps_2.6.0-1.caps @@ -180,4 +180,5 @@ + diff --git a/tests/qemucapabilitiesdata/caps_2.6.0-1.replies b/tests/qemucapabilitiesdata/caps_2.6.0-1.replies index 8a4c3fe..d80fe31 100644 --- a/tests/qemucapabilitiesdata/caps_2.6.0-1.replies +++ b/tests/qemucapabilitiesdata/caps_2.6.0-1.replies @@ -2995,6 +2995,47 @@ } { + "return": [ + { + "name": "msi", + "type": "on/off" + }, + { + "name": "msix", + "type": "on/off" + }, + { + "name": "superspeed-ports-first", + "type": "on/off" + }, + { + "name": "force-pcie-endcap", + "type": "on/off" + }, + { + "name": "streams", + "type": "on/off" + }, + { + "name": "intrs", + "type": "uint32" + }, + { + "name": "slots", + "type": "uint32" + }, + { + "name": "2", + "type": "uint32" + }, + { + "name": "p3", + "type": "uint32" + } + ] +} + +{ "return": [ { "name": "pc-i440fx-2.4",