]> rtime.felk.cvut.cz Git - lisovros/qemu_apohw.git/commitdiff
add QERR_BASE_NOT_FOUND
authorMarcelo Tosatti <mtosatti@redhat.com>
Wed, 18 Jan 2012 14:40:52 +0000 (14:40 +0000)
committerKevin Wolf <kwolf@redhat.com>
Thu, 26 Jan 2012 13:49:18 +0000 (14:49 +0100)
This qerror will be raised when a given streaming base (backing file)
cannot be found.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Acked-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
qapi-schema.json
qerror.c
qerror.h

index 3f72c2cfd4d939f87b042b6e0884812e1895f88b..80debe679a64577bd104d853cdd3093a8c5cef0f 100644 (file)
 #          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
 ##
index 2c60e10631cf93daf3484ce2bd47233f88079fff..637eca793c1fe1a134440240e6d30efdbbe3c1e7 100644 (file)
--- a/qerror.c
+++ b/qerror.c
@@ -51,6 +51,10 @@ static const QErrorStringTable qerror_table[] = {
         .error_fmt = QERR_BAD_BUS_FOR_DEVICE,
         .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)'",
index b530bc8806f58f966b47277b866f3d752958a39c..8c36ddb7e100c44d11ce43fd4adf98f44ad21f1a 100644 (file)
--- a/qerror.h
+++ b/qerror.h
@@ -57,6 +57,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 } }"