Statistics
| Branch: | Revision:

root / util / qemu-option.c @ feature-archipelago

History | View | Annotate | Download (30.1 kB)

# Date Author Comment
7cc07ab8 02/21/2014 11:10 pm Kevin Wolf

qemu-option: has_help_option() and is_valid_option_list()

has_help_option() checks if any help option ('help' or '?') occurs
anywhere in an option string, so that things like 'cluster_size=4k,help'
are recognised.

is_valid_option_list() ensures that the option list doesn't have options...

84d18f06 02/17/2014 06:57 pm Markus Armbruster

Use error_is_set() only when necessary

error_is_set(&var) is the same as var != NULL, but it takes
whole-program analysis to figure that out. Unnecessarily hard for
optimizers, static checkers, and human readers. Dumb it down to
obvious.

Gets rid of several dozen Coverity false positives....

87ea75d5 01/06/2014 10:02 pm Peter Crosthwaite

qemu-option: Remove qemu_opts_create_nofail

This is a boiler-plate _nofail variant of qemu_opts_create. Remove and
use error_abort in call sites.

null/0 arguments needs to be added for the id and fail_if_exists fields
in affected callsites due to argument inconsistency between the normal and...

326642bc 10/11/2013 05:50 pm Kevin Wolf

blockdev: Separate ID generation from DriveInfo creation

blockdev-add shouldn't automatically generate IDs, but will keep most of
the DriveInfo creation code.

Signed-off-by: Kevin Wolf <>
Reviewed-by: Max Reitz <>
Reviewed-by: Wenchao Xia <>...

d4ca092a 08/30/2013 04:28 pm Max Reitz

option: Add assigned flag to QEMUOptionParameter

Adds an "assigned" flag to QEMUOptionParameter which is cleared at the
beginning of parse_option_parameters and set on (successful)
set_option_parameter and set_option_parameter_int.

Signed-off-by: Max Reitz <>...

cb77d192 08/12/2013 05:15 pm Markus Armbruster

qemu-option: Guard against qemu_opts_set_defaults() misuse

Commit 6d4cd40 fixed qemu_opts_set_defaults() for an existing corner
case, but broke it for another one that can't be reached in current
code.

Quote from its commit message:

I believe [opts_parse()] attempts to do the following:...
e8cd45c7 07/30/2013 03:33 am Vasilis Liaskovitis

qdev: Add SIZE type to qdev properties

This patch adds a 'SIZE' type property to qdev.

Signed-off-by: Ian Molton <>
Signed-off-by: Vasilis Liaskovitis <>
Signed-off-by: Hu Tao <>...

0dd6c526 07/26/2013 10:10 pm Kevin Wolf

QemuOpts: Add qemu_opt_unset()

Signed-off-by: Kevin Wolf <>
Reviewed-by: Eric Blake <>

6d4cd408 07/09/2013 09:38 pm Markus Armbruster

qemu-option: Fix qemu_opts_set_defaults() for corner cases

Commit 4f6dd9a changed the initialization of opts in opts_parse() to
this:

if (defaults) {
if (!id && !QTAILQ_EMPTY(&list->head)) {
opts = qemu_opts_find(list, NULL);
} else {...
96bc97eb 07/09/2013 09:38 pm Markus Armbruster

qemu-option: Fix qemu_opts_find() for null id arguments

Crashes when the first list member has an ID. Admittedly nonsensical
reproducer:

$ qemu-system-x86_64 -nodefaults -machine id=foo -machine ""

Signed-off-by: Markus Armbruster <>
Reviewed-by: Peter Maydell <>...

a86b35f9 06/19/2013 10:10 pm Markus Armbruster

qemu-option: check_params() is now unused, drop it

Signed-off-by: Markus Armbruster <>
Reviewed-by: Anthony Liguori <>
Message-id:
Signed-off-by: Anthony Liguori <>

376609cc 03/15/2013 05:07 pm Kevin Wolf

qemu-option: Add qemu_opts_absorb_qdict()

This adds a function that adds all entries of a QDict to a QemuOpts if
the keys are known, and leaves only the rest in the QDict.

This way a single QDict of -drive options can be processed in multiple
places (generic block layer, block driver, backing file block driver,...

7216ae3d 02/11/2013 04:13 pm Markus Armbruster

qemu-option: Disable two helpful messages that got broken recently

commit 8be7e7e4 and commit ec7b2ccb messed up the ordering of error
message and the helpful explanation that should follow it, like this:

$ qemu-system-x86_64 --nodefaults -S --vnc :0 --chardev null,id=,...
c64f50d1 01/30/2013 12:14 pm Markus Armbruster

g_strdup(NULL) returns NULL; simplify

Signed-off-by: Markus Armbruster <>
Reviewed-by: Eric Blake <>
Signed-off-by: Stefan Hajnoczi <>

baacf047 01/12/2013 07:42 pm Paolo Bonzini

build: move libqemuutil.a components to util/

Signed-off-by: Paolo Bonzini <>