History | View | Annotate | Download (3.1 kB)
monitor: move include files to include/monitor/
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
qapi: move include files to include/qobject/
error, qerror: pass desc string to error calls
This commit changes all QERR_ macros to contain a human message (ie.the desc string found in qerr_table[]) instead of a json dictionaryin string format.
Before this commit, error_set() and qerror_report() would receive...
qerror: drop qerror_table and qerror_format()
They are unused since last commit.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>Reviewed-by: Markus Armbruster <armbru@redhat.com>
error, qerror: drop QDict member
Used to store error information, but it's unused now.
error, qerror: add ErrorClass argument to error functions
The new argument is added to functions qerror_report() and error_set().It's stored in Error and QError. qerror_report_err() is also updated totake care of it.
The QERR_ macros are changed to contain a place holder value for the...
qerror: qerror_table: don't use C99 struct initializers
This allows for changing QERR_ macros to initialize two struct membersat the same time. See next commit for more details.
qerror: drop QERR_SOCKET_CONNECT_IN_PROGRESS
Unused since last commit.
error: don't delay error message construction
Today, the error message is only constructed when it's used. This commitchanges that to construct the error message when the error object isbuilt (ie. when the error is reported).
This simplifies the Error object....
qerror: don't delay error message construction
Today, the error message is only constructed when it's used. This commitchanges qerror to construct the error message when the error object isbuilt (ie. when the error is reported).
This eliminates the need of storing a pointer to qerror_table[], which...
qerror: qerror_format(): return an allocated string
Simplifies current and future users.
qerror: QError: drop file, linenr, func
They have never been fully used and conflict with future errorimprovements.
Also makes qerror_report() a proper function, as there's no pointin having it as a macro anymore.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>...
qerror: avoid passing qerr pointer
Helps dropping/modifying qerror functions.
qerror: drop qerror_abort()
qerror_abort() depends on the 'file', 'func' and 'linenr' members ofQError. However, these members are going to be dropped by the nextcommit, so let's drop qerror_abort() in favor of printing an errormessage to stderr plus a call to abort()....
qerror: reduce public exposure
qerror will be dropped in a near future, let's reduce its publicexposure by making functions only used in qerror.c static.
qerror: QERR_DEVICE_ENCRYPTED: change error message
Match what HMP commands print on DeviceEncrypted errors.
qerror: QERR_AMBIGUOUS_PATH: drop %(object) from human msg
Actually, renames it to 'object'. This must be what the original authormeant to write, as there's no 'object' in the error's data member.
qerror: introduce QERR_INVALID_OPTION_GROUP
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>Reviewed-By: Laszlo Ersek <lersek@redhat.com>
qerror: add five qerror strings
Add five new qerror strings, they are about listen/connect socket: QERR_SOCKET_CONNECT_IN_PROGRESS QERR_SOCKET_CONNECT_FAILED QERR_SOCKET_LISTEN_FAILED QERR_SOCKET_BIND_FAILED QERR_SOCKET_CREATE_FAILED
Reviewed-by: Michael Roth <mdroth@linux.vnet.ibm.com>...
qerror: fix QERR_PROPERTY_VALUE_OUT_OF_RANGE description
Fix a typo in the description for QERR_PROPERTY_VALUE_OUT_OF_RANGE where"'" was used instead of ")".
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>...
qdev: add blocksize property type
Storage interfaces like virtio-blk can be configured with block sizeinformation so that the guest can take advantage of efficient I/Orequest sizes.
According to the SCSI Block Commands (SBC) standard a device's blocksize is "almost always greater than one byte and may be a multiple of...
QError: Introduce new errors for the migration command
The new errors are QERR_MIGRATION_ACTIVE and QERR_MIGRATION_NOT_SUPPORTED,which are going to be used by the QAPI converted migration command.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
qdev: print error message before aborting
qdev_prop_set_* functions are always called by machine init functionsthat should know what they're doing, so they abort on error. Still,an assert(!errp) does not aid debugging. Print an error before aborting....
qom: use object_resolve_path_type for links
This allows to restrict partial matches to objects of the expectedtype. It will let people use bare names to reference driveseven though their name might be the same as a device's (e.g.-drive id=hd0,if=none,... -device ...,drive=hd0,id=hd0)....
qom: add new command to search for types
This adds a command that allows searching for types that implement a property.This allows you to do things like search for all available PCIDevices. In thefuture, we'll also have a standard interface for things with a BlockDriverState...
add QERR_BASE_NOT_FOUND
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>...
qmp: add block_stream command
Add the block_stream command, which starts copy backing file contentsinto the image file. Also add the BLOCK_JOB_COMPLETED QMP event whichis emitted when image streaming completes. Later patches add controlover the background copy speed, cancelation, and querying running...
qerror: add check-qerror.sh to verify alphabetical order
We're supposed to keep qerror definitions and table entries inalphabetical order. In practice this is not checked.
I haven't found a nice way to integrate this into the makefile yet butwe can at least have this script which verifies that qerrors are in...
qerror: restore alphabetical order over qerrors
Over time these must have gotten out of order. Put everything back inalphabetical order.
This is purely a clean up. In practice nothing depends on the order.
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>...
block: use proper qerrors in qmp_block_resize
Let's report specific errors so that management tools and users canidentify the problem.
Two new qerrors are needed: * QERR_DEVICE_HAS_NO_MEDIUM for ENOMEDIUM * QERR_DEVICE_IS_READ_ONLY for EACCES
qom: introduce QERR_PROPERTY_VALUE_OUT_OF_RANGE
This will be used when reject invalid values for integer fields thatare less than 64-bits wide.
Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
qom: add new dynamic property infrastructure based on Visitors (v2)
qdev properties are settable only during construction and static to classes.This isn't flexible enough for QOM.
This patch introduces a property interface for qdev that provides dynamic...
Merge remote-tracking branch 'stefanha/trivial-patches-next' into staging
Fix spelling in comments, documentation and messages
accidently->accidentallyannother->anotherchoosen->chosenconsideres->considersdecriptor->descriptordevelopement->developmentparamter->parameterpreceed->precedepreceeding->precedingpriviledge->privilege...
guest agent: add RPC blacklist command-line option
This adds a command-line option, -b/--blacklist, that accepts acomma-seperated list of RPCs to disable, or prints a list ofavailable RPCs if passed "?".
In consequence this also adds general blacklisting and RPC listing...
QError: Introduce QERR_IO_ERROR
Merge remote-tracking branch 'kwolf/for-anthony' into staging
Merge remote-tracking branch 'aneesh/1.0-fixes' into staging
hmp/qmp: add block_set_io_throttle
Signed-off-by: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>Signed-off-by: Kevin Wolf <kwolf@redhat.com>
hw/9pfs: use migration blockers to prevent live migration when virtfs export path is mounted
Now when you try to migrate with VirtFS export path mounted, you get a proper QMP error:
(qemu) migrate tcp:localhost:4444Migration is disabled when VirtFS export path '/tmp/' is mounted in the guest using mount_tag 'v_tmp'...
fix spelling in main directory
Signed-off-by: Dong Xu Wang <wdongxu@linux.vnet.ibm.com>Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
qed: add migration blocker (v2)
Now when you try to migrate with qed, you get:
(qemu) migrate tcp:localhost:1025Block format 'qed' used by device 'ide0-hd0' does not support feature 'live migration'(qemu)
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
ivshmem: use migration blockers to prevent live migration in peer mode (v2)
Now when you try to migrate with ivshmem, you get a proper QMP error:
(qemu) migrate tcp:localhost:1025Migration is disabled when using feature 'peer mode' in device 'ivshmem'(qemu)...
qerror: Add a user string for QERR_FEATURE_DISABLED
Missing from commit 821601ea5b.
qerror: add qerror_report_err()
This provides a bridge between Error (new error mechanism) and QError (old errormechanism). Errors can be propagated whereas QError cannot.
The minor evilness avoids layering violations. Since QError should go away RSN,...
Monitor/QMP: Don't allow cont on bad VM state
We have two states where issuing cont before system_reset cancause problems: RSTATE_SHUTDOWN (when -no-shutdown is used) andRSTATE_PANICKED (which only happens with kvm).
This commit fixes that by doing the following when state is...
Use glib memory allocation and free functions
qemu_malloc/qemu_free no longer exist after this commit.
Introduce a 'client_add' monitor command accepting an open FD
Allow client connections for VNC and socket based characterdevices to be passed in over the monitor using SCM_RIGHTS.
One intended usage scenario is to start QEMU with VNC on aUNIX domain socket. An unprivileged user which cannot access...
qerror: add QERR_JSON_PARSE_ERROR to qerror.c
Missing from previous addition of error to qerror.h. Needed forqerror_format() and friends.
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>Signed-off-by: Luiz Capitulino <lcapitulino@gmail.com>
guest agent: add guest agent RPCs/commands
This adds the initial set of QMP/QAPI commands provided by the guestagent:
guest-syncguest-pingguest-infoguest-shutdownguest-file-openguest-file-readguest-file-writeguest-file-seekguest-file-flushguest-file-close...
Merge remote-tracking branch 'qmp/for-anthony' into staging
QError: Introduce qerror_format_desc()
Refactor non-QError-specific bits out of qerror_human() into generalfunction that can be used by the error_get_pretty() analogue in thenew error-propagation framework.
QError: Introduce qerror_format()
Will be used by new error propagation framework to convert Error objectsinto human-readable form.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
QMP: QError: New QERR_UNSUPPORTED
New QERR_UNSUPPORTED for unsupported commands or requests.
qerror: Add QERR_UNKNOWN_BLOCK_FORMAT_FEATURE
Signed-off-by: Kevin Wolf <kwolf@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>
pci: allow devices being tagged as not hotpluggable.
This patch adds a field to PCIDeviceInfo to tag devices as beingnot hotpluggable. Any attempt to plug-in or -out such a devicewill throw an error.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Use GCC_FMT_ATTR (format checking)
Signed-off-by: Stefan Weil <weil@mail.berlios.de>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
migration: Accept 'cont' only after successful incoming migration
When a 'cont' is issued on a VM that's just waiting for an incomingmigration, the VM reboots and boots into the guest, possibly corruptingits storage since it could be shared with another VM running elsewhere....
QError: Enhance QERR_DEVICE_NOT_ACTIVE's user desc
The 'by the guest' part is misleading, it could be disabled bythe host too.
We will likely need more surgery if we care for the distinction,just dropping the problematic part is good enough for now.
QError: Introduce QERR_QMP_EXTRA_MEMBER
Fix qtypes' licenses
- Change from GPL to LGPL- Add license text when missing- Minor cosmetic changes to make all headers look the same
QError: Improve QERR_QMP_BAD_INPUT_OBJECT desc
QError: New QERR_QMP_BAD_INPUT_OBJECT_MEMBER
error: New QERR_DEVICE_IN_USE
Signed-off-by: Markus Armbruster <armbru@redhat.com>Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
error: Put error definitions back in alphabetical order
Add suitable comments to help keerp them in order.
error: New QERR_DUPLICATE_ID
error: New QERR_INVALID_PARAMETER_VALUE
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>
error: Trim includes in qerror.c
QError: New QERR_DEVICE_NOT_ENCRYPTED
Signed-off-by: Shahar Havivi <shaharh@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
error: New QERR_BUS_NOT_FOUND
error: New QERR_DEVICE_MULTIPLE_BUSSES
error: New QERR_DEVICE_NO_BUS
error: New QERR_BAD_BUS_FOR_DEVICE
error: New QERR_BUS_NO_HOTPLUG
error: New QERR_DEVICE_INIT_FAILED
error: New QERR_NO_BUS_FOR_DEVICE
error: New QERR_PROPERTY_VALUE_IN_USE
error: New QERR_PROPERTY_VALUE_NOT_FOUND
error: Polish human-readable error descriptions
Also put error definitions in alphabetical order
error: New QERR_PROPERTY_NOT_FOUND
error: New QERR_PROPERTY_VALUE_BAD
error: Replace qemu_error() by error_report()
error_report() terminates the message with a newline. Strip it itfrom its arguments.
This fixes a few error messages lacking a newline:net_handle_fd_param()'s "No file descriptor named %s found", andtap_open()'s "vnet_hdr=1 requested, but no kernel support for...
error: Infrastructure to track locations for error reporting
New struct Location holds a location. So far, the only location isLOC_NONE, so this doesn't do anything useful yet.
Passing the current location all over the place would be toocumbersome. Hide it away in static cur_loc instead, and provide...
error: Move qemu_error & friends into their own header
Revert "QError: New QERR_INVALID_CPU_INDEX"
This reverts commit 64a34bb14c0e358a6b2f14805e59ef25bf62d6d5.
Signed-off-by: Markus Armbruster <armbru@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
QError: New QERR_INVALID_CPU_INDEX
QError: New QERR_OPEN_FILE_FAILED
QError: New QERR_FD_NOT_SUPPLIED
New QERR_INVALID_PARAMETER
QError: New QERR_TOO_MANY_FILES
QMP: add human-readable description to error response
QError: New QERR_VNC_SERVER_FAILED
QError: New QERR_FD_NOT_FOUND
QError: New QERR_DEVICE_NOT_REMOVABLE
QError: New QERR_INVALID_BLOCK_FORMAT
QError: New QERR_SET_PASSWD_FAILED
QError: Put error definitions in alphabetical order
Also fix the odd typoe and clean up whitespace.
QError: New QERR_DEVICE_LOCKED
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>