|
|
51d9a2 |
From c535cdd9ab6e9be03beaf412c74495b4eb267ffc Mon Sep 17 00:00:00 2001
|
|
|
51d9a2 |
Message-Id: <c535cdd9ab6e9be03beaf412c74495b4eb267ffc@dist-git>
|
|
|
51d9a2 |
From: Peter Krempa <pkrempa@redhat.com>
|
|
|
51d9a2 |
Date: Thu, 19 Jul 2018 15:03:48 +0200
|
|
|
51d9a2 |
Subject: [PATCH] qemu: capabilities: Add capability for werror/rerror for
|
|
|
51d9a2 |
'usb-device' frontend
|
|
|
51d9a2 |
MIME-Version: 1.0
|
|
|
51d9a2 |
Content-Type: text/plain; charset=UTF-8
|
|
|
51d9a2 |
Content-Transfer-Encoding: 8bit
|
|
|
51d9a2 |
|
|
|
51d9a2 |
Support for specifying it with the -device frontend was added recently.
|
|
|
51d9a2 |
Add a capability for it.
|
|
|
51d9a2 |
|
|
|
51d9a2 |
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
|
|
|
51d9a2 |
Reviewed-by: Ján Tomko <jtomko@redhat.com>
|
|
|
51d9a2 |
(cherry picked from commit a087a8e60ad62a719165e3c2c9970480b9531062)
|
|
|
51d9a2 |
|
|
|
51d9a2 |
https://bugzilla.redhat.com/show_bug.cgi?id=1475770
|
|
|
51d9a2 |
Signed-off-by: Erik Skultety <eskultet@redhat.com>
|
|
|
51d9a2 |
Reviewed-by: Ján Tomko <jtomko@redhat.com>
|
|
|
51d9a2 |
---
|
|
|
51d9a2 |
src/qemu/qemu_capabilities.c | 2 ++
|
|
|
51d9a2 |
src/qemu/qemu_capabilities.h | 1 +
|
|
|
51d9a2 |
tests/qemucapabilitiesdata/caps_3.0.0.x86_64.xml | 1 +
|
|
|
51d9a2 |
3 files changed, 4 insertions(+)
|
|
|
51d9a2 |
|
|
|
51d9a2 |
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
|
|
|
51d9a2 |
index 883ca5dab7..0f0020cf7d 100644
|
|
|
51d9a2 |
--- a/src/qemu/qemu_capabilities.c
|
|
|
51d9a2 |
+++ b/src/qemu/qemu_capabilities.c
|
|
|
51d9a2 |
@@ -502,6 +502,7 @@ VIR_ENUM_IMPL(virQEMUCaps, QEMU_CAPS_LAST,
|
|
|
51d9a2 |
"sev-guest",
|
|
|
51d9a2 |
"machine.pseries.cap-hpt-max-page-size",
|
|
|
51d9a2 |
"machine.pseries.cap-htm",
|
|
|
51d9a2 |
+ "usb-storage.werror",
|
|
|
51d9a2 |
);
|
|
|
51d9a2 |
|
|
|
51d9a2 |
|
|
|
51d9a2 |
@@ -1241,6 +1242,7 @@ static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsUSBStorage[] = {
|
|
|
51d9a2 |
{ "removable", QEMU_CAPS_USB_STORAGE_REMOVABLE },
|
|
|
51d9a2 |
{ "share-rw", QEMU_CAPS_DISK_SHARE_RW },
|
|
|
51d9a2 |
{ "write-cache", QEMU_CAPS_DISK_WRITE_CACHE },
|
|
|
51d9a2 |
+ { "werror", QEMU_CAPS_USB_STORAGE_WERROR },
|
|
|
51d9a2 |
};
|
|
|
51d9a2 |
|
|
|
51d9a2 |
static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsKVMPit[] = {
|
|
|
51d9a2 |
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h
|
|
|
51d9a2 |
index a048a1cf02..1fa0ebfea3 100644
|
|
|
51d9a2 |
--- a/src/qemu/qemu_capabilities.h
|
|
|
51d9a2 |
+++ b/src/qemu/qemu_capabilities.h
|
|
|
51d9a2 |
@@ -486,6 +486,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */
|
|
|
51d9a2 |
QEMU_CAPS_SEV_GUEST, /* -object sev-guest,... */
|
|
|
51d9a2 |
QEMU_CAPS_MACHINE_PSERIES_CAP_HPT_MAX_PAGE_SIZE, /* -machine pseries.cap-hpt-max-page-size */
|
|
|
51d9a2 |
QEMU_CAPS_MACHINE_PSERIES_CAP_HTM, /* -machine pseries.cap-htm */
|
|
|
51d9a2 |
+ QEMU_CAPS_USB_STORAGE_WERROR, /* -device usb-storage,werror=..,rerror=.. */
|
|
|
51d9a2 |
|
|
|
51d9a2 |
QEMU_CAPS_LAST /* this must always be the last item */
|
|
|
51d9a2 |
} virQEMUCapsFlags;
|
|
|
51d9a2 |
diff --git a/tests/qemucapabilitiesdata/caps_3.0.0.x86_64.xml b/tests/qemucapabilitiesdata/caps_3.0.0.x86_64.xml
|
|
|
51d9a2 |
index 07e3de8677..d7c25c65dd 100644
|
|
|
51d9a2 |
--- a/tests/qemucapabilitiesdata/caps_3.0.0.x86_64.xml
|
|
|
51d9a2 |
+++ b/tests/qemucapabilitiesdata/caps_3.0.0.x86_64.xml
|
|
|
51d9a2 |
@@ -209,6 +209,7 @@
|
|
|
51d9a2 |
<flag name='mch'/>
|
|
|
51d9a2 |
<flag name='mch.extended-tseg-mbytes'/>
|
|
|
51d9a2 |
<flag name='sev-guest'/>
|
|
|
51d9a2 |
+ <flag name='usb-storage.werror'/>
|
|
|
51d9a2 |
<version>2012050</version>
|
|
|
51d9a2 |
<kvmVersion>0</kvmVersion>
|
|
|
51d9a2 |
<microcodeVersion>437827</microcodeVersion>
|
|
|
51d9a2 |
--
|
|
|
51d9a2 |
2.18.0
|
|
|
51d9a2 |
|