Commit Graph

43 Commits

Author SHA1 Message Date
Luiz Capitulino 41836a9f7e Fix qtypes' licenses
- Change from GPL to LGPL
- Add license text when missing
- Minor cosmetic changes to make all headers look the same

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
2010-05-19 12:45:54 -03:00
Luiz Capitulino 7dfb61238a QError: New QERR_QMP_BAD_INPUT_OBJECT_MEMBER
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
2010-04-26 11:17:02 -03:00
Markus Armbruster 5124eb5927 error: New QERR_DEVICE_IN_USE
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
2010-04-18 23:46:49 +02:00
Markus Armbruster 985a3e52f0 error: New QERR_INVALID_PARAMETER_VALUE
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
2010-04-18 23:46:48 +02:00
Markus Armbruster 7bc8401712 error: New QERR_DUPLICATE_ID
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
2010-04-18 23:46:48 +02:00
Markus Armbruster 9d494c4b4e error: Put error definitions back in alphabetical order
Add suitable comments to help keerp them in order.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
2010-04-18 23:46:48 +02:00
Markus Armbruster 0167f772d1 error: Move qerror_report() from qemu-error.[ch] to qerror.[ch]
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2010-03-27 14:30:38 +01:00
Shahar Havivi 25b28f01d8 QError: New QERR_DEVICE_NOT_ENCRYPTED
Signed-off-by: Shahar Havivi <shaharh@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2010-03-17 10:41:05 -05:00
Markus Armbruster fab5767f90 error: New QERR_NO_BUS_FOR_DEVICE 2010-03-16 17:45:34 +01:00
Markus Armbruster 4d9a1a1521 error: New QERR_DEVICE_INIT_FAILED 2010-03-16 17:45:34 +01:00
Markus Armbruster 8eae73b5d7 error: New QERR_BUS_NO_HOTPLUG 2010-03-16 17:45:34 +01:00
Markus Armbruster 56e9f56309 error: New QERR_BAD_BUS_FOR_DEVICE 2010-03-16 17:45:34 +01:00
Markus Armbruster 07574baf7b error: New QERR_DEVICE_NO_BUS 2010-03-16 17:45:34 +01:00
Markus Armbruster 1ae7871840 error: New QERR_DEVICE_MULTIPLE_BUSSES 2010-03-16 17:45:34 +01:00
Markus Armbruster 7bbd823701 error: New QERR_BUS_NOT_FOUND 2010-03-16 17:45:34 +01:00
Markus Armbruster 84745d68e7 error: New QERR_PROPERTY_VALUE_NOT_FOUND 2010-03-16 17:45:26 +01:00
Markus Armbruster 9c5eff958d error: New QERR_PROPERTY_VALUE_IN_USE 2010-03-16 17:45:26 +01:00
Markus Armbruster 06b4a703e0 error: New QERR_PROPERTY_VALUE_BAD 2010-03-16 17:01:08 +01:00
Markus Armbruster c58a35f8e3 error: New QERR_PROPERTY_NOT_FOUND 2010-03-16 17:01:08 +01:00
Markus Armbruster fc5469d87b error: Polish human-readable error descriptions
Also put error definitions in alphabetical order
2010-03-16 17:01:08 +01:00
Markus Armbruster 827b08139c error: Infrastructure to track locations for error reporting
New struct Location holds a location.  So far, the only location is
LOC_NONE, so this doesn't do anything useful yet.

Passing the current location all over the place would be too
cumbersome.  Hide it away in static cur_loc instead, and provide
accessors.  Print it in error_report().

Store it in QError, and print it in qerror_print().

Store it in QemuOpt, for use by qemu_opts_foreach().  This makes
error_report() do the right thing when it runs within
qemu_opts_foreach().

We may still have to store it in other data structures holding user
input for better error messages.  Left for another day.
2010-03-16 16:58:32 +01:00
Markus Armbruster f34e568853 Revert "QError: New QERR_INVALID_CPU_INDEX"
This reverts commit 64a34bb14c.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2010-02-03 12:39:01 -06:00
Markus Armbruster 64a34bb14c QError: New QERR_INVALID_CPU_INDEX
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2010-01-26 14:55:11 -06:00
Markus Armbruster 3da2c80814 QError: New QERR_OPEN_FILE_FAILED
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2010-01-26 14:55:10 -06:00
Markus Armbruster bd9d30640c Fix recently added QERR_ definitions
Commits c7c338c4, 41471a23, 7a046f5f and a488be27 used
lower_case_with_underscores for class values.  Existing usage
CamelCase.  ChangeToThatForConsistency.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12 07:59:39 -06:00
Markus Armbruster 77e595e7c6 QMP: add human-readable description to error response
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:36 -06:00
Markus Armbruster a488be27e5 QError: New QERR_TOO_MANY_FILES
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:36 -06:00
Markus Armbruster 7a046f5f14 New QERR_INVALID_PARAMETER
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:36 -06:00
Markus Armbruster 41471a2338 QError: New QERR_FD_NOT_SUPPLIED
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:36 -06:00
Markus Armbruster c7c338c497 QError: New QERR_FD_NOT_FOUND
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:35 -06:00
Markus Armbruster a6906e31a8 QError: New QERR_VNC_SERVER_FAILED
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:35 -06:00
Markus Armbruster 7a84cb23c0 QError: New QERR_SET_PASSWD_FAILED
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:34 -06:00
Markus Armbruster 17901e7532 QError: New QERR_INVALID_BLOCK_FORMAT
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:34 -06:00
Markus Armbruster 5cfe026475 QError: New QERR_DEVICE_NOT_REMOVABLE
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:34 -06:00
Markus Armbruster b086838090 QError: New QERR_DEVICE_LOCKED
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:33 -06:00
Markus Armbruster e16a181222 QError: Put error definitions in alphabetical order
Also fix the odd typoe and clean up whitespace.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:33 -06:00
Luiz Capitulino 0df37c411c QError: new class for device encrypted errors
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 16:34:32 -06:00
Luiz Capitulino f6d855c50d QError: Add class for invalid passwords
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07 14:04:19 -06:00
Luiz Capitulino 4b9d46834d QError: Add errors needed by QMP
Only QERR_QMP_BAD_INPUT_OBJECT is QMP specific, the others can
be used in different contexts by other subsystems.

Please, note that QERR_JSON_PARSING signals any parsing error
from the json parser. We will need it until the parser gets
updated to use QError.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-03 09:41:22 -06:00
Luiz Capitulino 82a60711dd QError: Add QERR_KVM_MISSING_CAP
New class for KVM unavailable features errors.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-03 09:41:21 -06:00
Luiz Capitulino 055f6122a6 QError: Add QERR_DEVICE_NOT_ACTIVE
New class for device not active errors.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-03 09:41:21 -06:00
Luiz Capitulino 357b6156f9 QError: Add QERR_DEVICE_NOT_FOUND
New class for device not found errors.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-03 09:41:20 -06:00
Luiz Capitulino 9f9daf9a63 Introduce QError
QError is a high-level data type which represents an exception
in QEMU, it stores the following error information:

- class          Error class name (eg. "ServiceUnavailable")
- description    A detailed error description, which can contain
                 references to run-time error data
- filename       The file name of where the error occurred
- line number    The exact line number of the error
- function       The function name of where the error occurred
- run-time data  Any run-time error data

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-03 09:41:20 -06:00