qemu : with network adapter_type equal to "virtio-net-pci", fix the speed to 10000 and duplex to full.

The values are actually fake.
	(https://github.com/GNS3/gns3-gui/issues/3476)
This commit is contained in:
Raizo62 2023-06-03 11:48:55 +02:00
parent 088ae699de
commit 0b6436d2cb

View File

@ -2150,6 +2150,8 @@ class QemuVM(BaseNode):
else:
# newer QEMU networking syntax
device_string = "{},mac={}".format(adapter_type, mac)
if adapter_type == "virtio-net-pci":
device_string = "{},speed=10000,duplex=full".format(device_string)
bridge_id = math.floor(pci_device_id / 32)
if bridge_id > 0:
if pci_bridges_created < bridge_id: