mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 19:32:19 +00:00
qemuBuildVhostuserCommandLine: Unify -netdev creation
Currently, what we do for vhost-user network is generate the following part of command line: -netdev type=vhost-user,id=hostnet0,chardev=charnet0 There's no need for 'type=' it is the default. Drop it. Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
parent
0c61cf3158
commit
b093e85224
@ -7828,7 +7828,7 @@ qemuBuildVhostuserCommandLine(virQEMUDriverPtr driver,
|
|||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
virBufferAsprintf(&netdev_buf, "type=vhost-user,id=host%s,chardev=char%s",
|
virBufferAsprintf(&netdev_buf, "vhost-user,id=host%s,chardev=char%s",
|
||||||
net->info.alias, net->info.alias);
|
net->info.alias, net->info.alias);
|
||||||
|
|
||||||
if (queues > 1) {
|
if (queues > 1) {
|
||||||
|
@ -20,17 +20,17 @@ QEMU_AUDIO_DRV=none \
|
|||||||
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
|
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
|
||||||
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
|
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
|
||||||
-chardev socket,id=charnet0,path=/tmp/vhost0.sock,server \
|
-chardev socket,id=charnet0,path=/tmp/vhost0.sock,server \
|
||||||
-netdev type=vhost-user,id=hostnet0,chardev=charnet0 \
|
-netdev vhost-user,id=hostnet0,chardev=charnet0 \
|
||||||
-device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:ee:96:6b,bus=pci.0,\
|
-device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:ee:96:6b,bus=pci.0,\
|
||||||
addr=0x3 \
|
addr=0x3 \
|
||||||
-chardev socket,id=charnet1,path=/tmp/vhost1.sock \
|
-chardev socket,id=charnet1,path=/tmp/vhost1.sock \
|
||||||
-netdev type=vhost-user,id=hostnet1,chardev=charnet1 \
|
-netdev vhost-user,id=hostnet1,chardev=charnet1 \
|
||||||
-device virtio-net-pci,netdev=hostnet1,id=net1,mac=52:54:00:ee:96:6c,bus=pci.0,\
|
-device virtio-net-pci,netdev=hostnet1,id=net1,mac=52:54:00:ee:96:6c,bus=pci.0,\
|
||||||
addr=0x4 \
|
addr=0x4 \
|
||||||
-netdev socket,listen=:2015,id=hostnet2 \
|
-netdev socket,listen=:2015,id=hostnet2 \
|
||||||
-device rtl8139,netdev=hostnet2,id=net2,mac=52:54:00:95:db:c0,bus=pci.0,\
|
-device rtl8139,netdev=hostnet2,id=net2,mac=52:54:00:95:db:c0,bus=pci.0,\
|
||||||
addr=0x5 \
|
addr=0x5 \
|
||||||
-chardev socket,id=charnet3,path=/tmp/vhost2.sock \
|
-chardev socket,id=charnet3,path=/tmp/vhost2.sock \
|
||||||
-netdev type=vhost-user,id=hostnet3,chardev=charnet3,queues=4 \
|
-netdev vhost-user,id=hostnet3,chardev=charnet3,queues=4 \
|
||||||
-device virtio-net-pci,mq=on,vectors=10,netdev=hostnet3,id=net3,\
|
-device virtio-net-pci,mq=on,vectors=10,netdev=hostnet3,id=net3,\
|
||||||
mac=52:54:00:ee:96:6d,bus=pci.0,addr=0x6
|
mac=52:54:00:ee:96:6d,bus=pci.0,addr=0x6
|
||||||
|
@ -20,11 +20,11 @@ QEMU_AUDIO_DRV=none \
|
|||||||
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
|
-drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \
|
||||||
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
|
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
|
||||||
-chardev socket,id=charnet0,path=/tmp/vhost0.sock,server \
|
-chardev socket,id=charnet0,path=/tmp/vhost0.sock,server \
|
||||||
-netdev type=vhost-user,id=hostnet0,chardev=charnet0 \
|
-netdev vhost-user,id=hostnet0,chardev=charnet0 \
|
||||||
-device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:ee:96:6b,bus=pci.0,\
|
-device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:ee:96:6b,bus=pci.0,\
|
||||||
addr=0x3 \
|
addr=0x3 \
|
||||||
-chardev socket,id=charnet1,path=/tmp/vhost1.sock \
|
-chardev socket,id=charnet1,path=/tmp/vhost1.sock \
|
||||||
-netdev type=vhost-user,id=hostnet1,chardev=charnet1 \
|
-netdev vhost-user,id=hostnet1,chardev=charnet1 \
|
||||||
-device virtio-net-pci,netdev=hostnet1,id=net1,mac=52:54:00:ee:96:6c,bus=pci.0,\
|
-device virtio-net-pci,netdev=hostnet1,id=net1,mac=52:54:00:ee:96:6c,bus=pci.0,\
|
||||||
addr=0x4 \
|
addr=0x4 \
|
||||||
-netdev socket,listen=:2015,id=hostnet2 \
|
-netdev socket,listen=:2015,id=hostnet2 \
|
||||||
|
Loading…
x
Reference in New Issue
Block a user