qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH v3 00/35]: add new error format


From: Luiz Capitulino
Subject: [Qemu-devel] [PATCH v3 00/35]: add new error format
Date: Fri, 10 Aug 2012 14:43:38 -0300

v3

 o rebase on top of master
 o replace 'valid_encryption_key' with 'encryption_key_missing', fixes
   a bug found by Markus
 o minor changes (changelogs, white-space fix and others)

Only the following patches have changed:

 o [PATCH 11/35] qmp: query-block: add 'encryption_key_missing' field
 o [PATCH 12/35] hmp: hmp_cont(): don't rely on QERR_DEVICE_ENCRYPTED
 o [PATCH 15/35] migration: don't rely on any QERR_SOCKET_*
 o [PATCH 29/35] qmp: switch to the new error format on the wire
 o [PATCH 35/35] docs: writing-qmp-commands.txt: update error section

This series implements the 'Plan for error handling in QMP' as described
by Anthony in this email:

    http://lists.gnu.org/archive/html/qemu-devel/2012-07/msg03764.html

Basically, this replaces almost all error classes by GenericError (the
exception are a few error classes used by libvirt) and drops the error
data memeber. This also adds a free form string to error_set().

On the wire, we go from:

    { "error": { "class": "DeviceNotRemovable",
                 "data": { "device": "virtio0" },
                 "desc": "Device 'virtio0' is not removable" } }

to:

     { "error": { "class": "GenericError",
                  "desc": "Device 'virtio0' is not removable" } }

Internally, we go from:

  void error_set(Error **err, const char *fmt, ...);

to:

  void error_set(Error **err, ErrorClass err_class, const char *fmt, ...);

 Makefile.objs                 |   1 +
 QMP/qmp-spec.txt              |  10 +-
 block.c                       |   1 +
 block_int.h                   |   1 +
 configure                     |  10 -
 docs/writing-qmp-commands.txt |  47 ++--
 error.c                       |  93 +-------
 error.h                       |  34 +--
 error_int.h                   |  29 ---
 hmp.c                         |  69 ++----
 hmp.h                         |   1 +
 migration-tcp.c               |  22 +-
 monitor.c                     |  83 ++-----
 nbd.c                         |   2 +-
 qapi-schema.json              |  94 +++-----
 qapi/qmp-core.h               |   1 +
 qapi/qmp-dispatch.c           |  11 +-
 qemu-char.c                   |   2 +-
 qemu-ga.c                     |   5 +-
 qemu-sockets.c                |  14 +-
 qemu_socket.h                 |   4 +-
 qerror.c                      | 516 ++----------------------------------------
 qerror.h                      | 168 ++++++--------
 qmp-commands.hx               |   4 +-
 scripts/qapi-types.py         |  17 +-
 ui/vnc.c                      |   2 +-
 26 files changed, 268 insertions(+), 973 deletions(-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]