[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v5 12/15] add QERR_BASE_NOT_FOUND
From: |
Stefan Hajnoczi |
Subject: |
[Qemu-devel] [PATCH v5 12/15] add QERR_BASE_NOT_FOUND |
Date: |
Fri, 13 Jan 2012 13:14:14 +0000 |
From: Marcelo Tosatti <address@hidden>
This qerror will be raised when a given streaming base (backing file)
cannot be found.
Signed-off-by: Marcelo Tosatti <address@hidden>
Signed-off-by: Stefan Hajnoczi <address@hidden>
---
qapi-schema.json | 1 +
qerror.c | 4 ++++
qerror.h | 3 +++
3 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/qapi-schema.json b/qapi-schema.json
index b4f6b15..b778639 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -1335,6 +1335,7 @@
# If streaming is already active on this device, DeviceInUse
# If @device does not exist, DeviceNotFound
# If image streaming is not supported by this device, NotSupported
+# If @base does not exist, BaseNotFound
#
# Since: 1.1
##
diff --git a/qerror.c b/qerror.c
index feb3d35..272243491 100644
--- a/qerror.c
+++ b/qerror.c
@@ -49,6 +49,10 @@ static const QErrorStringTable qerror_table[] = {
.desc = "Device '%(device)' can't go on a %(bad_bus_type) bus",
},
{
+ .error_fmt = QERR_BASE_NOT_FOUND,
+ .desc = "Base '%(base)' not found",
+ },
+ {
.error_fmt = QERR_BLOCK_FORMAT_FEATURE_NOT_SUPPORTED,
.desc = "Block format '%(format)' used by device '%(name)' does
not support feature '%(feature)'",
},
diff --git a/qerror.h b/qerror.h
index 095ba9d..4351fe3 100644
--- a/qerror.h
+++ b/qerror.h
@@ -54,6 +54,9 @@ QError *qobject_to_qerror(const QObject *obj);
#define QERR_BAD_BUS_FOR_DEVICE \
"{ 'class': 'BadBusForDevice', 'data': { 'device': %s, 'bad_bus_type': %s
} }"
+#define QERR_BASE_NOT_FOUND \
+ "{ 'class': 'BaseNotFound', 'data': { 'base': %s } }"
+
#define QERR_BLOCK_FORMAT_FEATURE_NOT_SUPPORTED \
"{ 'class': 'BlockFormatFeatureNotSupported', 'data': { 'format': %s,
'name': %s, 'feature': %s } }"
--
1.7.7.3
- [Qemu-devel] [PATCH v5 05/15] block: rate-limit streaming operations, (continued)
- [Qemu-devel] [PATCH v5 07/15] qmp: add block_job_set_speed command, Stefan Hajnoczi, 2012/01/13
- [Qemu-devel] [PATCH v5 14/15] docs: describe live block operations, Stefan Hajnoczi, 2012/01/13
- [Qemu-devel] [PATCH v5 11/15] block: add bdrv_find_backing_image, Stefan Hajnoczi, 2012/01/13
- [Qemu-devel] [PATCH v5 10/15] blockdev: make image streaming safe across hotplug, Stefan Hajnoczi, 2012/01/13
- [Qemu-devel] [PATCH v5 12/15] add QERR_BASE_NOT_FOUND,
Stefan Hajnoczi <=
- [Qemu-devel] [PATCH v5 08/15] qmp: add block_job_cancel command, Stefan Hajnoczi, 2012/01/13
- [Qemu-devel] [PATCH v5 06/15] qmp: add block_stream command, Stefan Hajnoczi, 2012/01/13
- [Qemu-devel] [PATCH v5 13/15] block: add support for partial streaming, Stefan Hajnoczi, 2012/01/13
[Qemu-devel] [PATCH v5 15/15] test: add image streaming test cases, Stefan Hajnoczi, 2012/01/13