mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 15:53:54 -06:00
Make qemu-config available for tools
To be able to use config files for blkdebug, we need to make these functions available in the tools. This involves moving two functions that can only be built in the context of the emulator. Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
b9f66d9695
commit
25920d6ad6
4 changed files with 20 additions and 21 deletions
|
@ -378,23 +378,6 @@ int qemu_global_option(const char *str)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static int qemu_add_one_global(QemuOpts *opts, void *opaque)
|
||||
{
|
||||
GlobalProperty *g;
|
||||
|
||||
g = qemu_mallocz(sizeof(*g));
|
||||
g->driver = qemu_opt_get(opts, "driver");
|
||||
g->property = qemu_opt_get(opts, "property");
|
||||
g->value = qemu_opt_get(opts, "value");
|
||||
qdev_prop_register_global(g);
|
||||
return 0;
|
||||
}
|
||||
|
||||
void qemu_add_globals(void)
|
||||
{
|
||||
qemu_opts_foreach(&qemu_global_opts, qemu_add_one_global, NULL, 0);
|
||||
}
|
||||
|
||||
struct ConfigWriteData {
|
||||
QemuOptsList *list;
|
||||
FILE *fp;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue