QemuOpts: add -set option

One use case will be file for drives (no filename quoting issues), i.e.

	-drive id=test,if=virtio
	-set drive.test.file=/vmdisk/test-virtio.img

It will work for any other option (assuming handled by QemuOpts) though.
Except for id= for obvious reasons ;).

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
This commit is contained in:
Gerd Hoffmann 2009-07-31 12:25:36 +02:00 committed by Anthony Liguori
parent 7282a0331f
commit d058fe03e5
4 changed files with 52 additions and 1 deletions

4
vl.c
View file

@ -4966,6 +4966,10 @@ int main(int argc, char **argv, char **envp)
case QEMU_OPTION_drive:
drive_add(NULL, "%s", optarg);
break;
case QEMU_OPTION_set:
if (qemu_set_option(optarg) != 0)
exit(1);
break;
case QEMU_OPTION_mtdblock:
drive_add(optarg, MTD_ALIAS);
break;