From 5bb95411baef26791aca6bd81183720cdc9be599 Mon Sep 17 00:00:00 2001 From: Alexander van der Grinten Date: Sat, 23 Nov 2024 23:05:56 +0100 Subject: [PATCH] scripts/vm-util: Fix fstrings for Python < 3.12 --- scripts/vm-util.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/vm-util.py b/scripts/vm-util.py index 6146cf955..76c1d2aa0 100755 --- a/scripts/vm-util.py +++ b/scripts/vm-util.py @@ -98,7 +98,7 @@ def parse_device(yml, *, bus_id=None, device_id=None): if devtype == 'pci-bridge': qemu_pci_bridges += 1 - args += ['-device', f'pci-bridge,id={yml['name']},chassis_nr={qemu_pci_bridges}'] + args += ['-device', f"pci-bridge,id={yml['name']},chassis_nr={qemu_pci_bridges}"] for i, device in enumerate(yml.get('devices', [])): args += parse_device(device, bus_id=yml['name'], device_id=i) @@ -106,7 +106,7 @@ def parse_device(yml, *, bus_id=None, device_id=None): multifunction_property_set = False for i, func in enumerate(yml.get('functions', [])): - properties = f'vfio-pci,host={func['host']}' + properties = f"vfio-pci,host={func['host']}" if bus_id: properties += f',bus={bus_id}' if i == 0: @@ -115,7 +115,7 @@ def parse_device(yml, *, bus_id=None, device_id=None): properties += f',addr={device_id:02x}.{i}' args += ['-device', properties] elif devtype == 'pci-device': - args += ['-device', f'vfio-pci,host={yml['host']},id={yml['name']}'] + args += ['-device', f"vfio-pci,host={yml['host']},id={yml['name']}"] else: print(f"error: unsupported device-spec device kind {devtype}") sys.exit(1)