[libvirt] [PATCH] virterror: Add error message for unsupported operations.
Eric Blake
eblake at redhat.com
Thu Aug 9 13:38:23 UTC 2012
On 08/09/2012 07:31 AM, Peter Krempa wrote:
> This patch introduces a new error code VIR_ERR_OPERATION_UNSUPPORTED to
> mark error messages regarding operations that failed due to lack of
> support on the hypervisor or other than libvirt issues.
>
> The code is first used in reporting error if qemu does not support block
> IO tuning variables yielding error message:
> error: Unable to get block I/O throttle parameters
> error: Operation not supported: block_io_throttle field
> 'total_bytes_sec' missing in qemu's output
>
> instead of:
> error: Unable to get block I/O throttle parameters
> error: internal error cannot read total_bytes_sec
> ---
In the past, we have used VIR_ERR_CONFIG_UNSUPPORTED for messages about
a qemu binary that doesn't support something; would that be any better
than inventing a new error here? Or are all of those errors worth
switching over to this new code?
As written, your patch seems fine, but only if we agree that a new error
is the way to go.
--
Eric Blake eblake at redhat.com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120809/c4060871/attachment-0001.sig>
More information about the libvir-list
mailing list