提交 d7ec244f 编写于 作者: P Peter Krempa

qemu: command: Shuffle around formatting of alias for RNG device backend

Move the alias name right after the object type for rng-egd backend so
that we can later use the JSON to commandline generator to create the
command line.
上级 98e982b4
......@@ -6200,7 +6200,7 @@ qemuBuildRNGBackendArgs(virCommandPtr cmd,
virCommandAddArgList(cmd, "-chardev", backend, NULL);
virCommandAddArg(cmd, "-object");
virCommandAddArgFormat(cmd, "rng-egd,chardev=char%s,id=obj%s",
virCommandAddArgFormat(cmd, "rng-egd,id=obj%s,chardev=char%s",
dev->info.alias, dev->info.alias);
break;
......
......@@ -4,5 +4,5 @@ LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test QEMU_AUDIO_DRV=none \
-monitor unix:/tmp/test-monitor,server,nowait -no-acpi -boot c -usb \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3 \
-chardev socket,id=charrng0,host=1.2.3.4,port=1234 \
-object rng-egd,chardev=charrng0,id=objrng0 \
-object rng-egd,id=objrng0,chardev=charrng0 \
-device virtio-rng-pci,rng=objrng0,id=rng0,bus=pci.0,addr=0x4
......@@ -6,5 +6,5 @@ LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test QEMU_AUDIO_DRV=none \
-object rng-random,id=objrng0,filename=/dev/random \
-device virtio-rng-pci,rng=objrng0,id=rng0,bus=pci.0,addr=0x7 \
-chardev socket,id=charrng1,host=1.2.3.4,port=1234 \
-object rng-egd,chardev=charrng1,id=objrng1 \
-object rng-egd,id=objrng1,chardev=charrng1 \
-device virtio-rng-pci,rng=objrng1,id=rng1,bus=pci.0,addr=0x4
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册