[RFC v2: vf-token 3/7] conf: vf-token flag

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Define PCI address extension flag for vf-token

Signed-off-by: Vivek Kashyap <vivek.kashyap@xxxxxxxxxxxxxxx>
---
 src/conf/domain_addr.h         | 1 +
 src/qemu/qemu_domain_address.c | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/src/conf/domain_addr.h b/src/conf/domain_addr.h
index e72fb48847..29e7257177 100644
--- a/src/conf/domain_addr.h
+++ b/src/conf/domain_addr.h
@@ -29,6 +29,7 @@
 typedef enum {
     VIR_PCI_ADDRESS_EXTENSION_NONE = 0, /* no extension */
     VIR_PCI_ADDRESS_EXTENSION_ZPCI = 1 << 0, /* zPCI support */
+    VIR_PCI_ADDRESS_EXTENSION_VFTOKEN = 1 << 1, /* VF token support */
 } virPCIDeviceAddressExtensionFlags;
 
 typedef enum {
diff --git a/src/qemu/qemu_domain_address.c b/src/qemu/qemu_domain_address.c
index 099778b2a8..3be5acbc9e 100644
--- a/src/qemu/qemu_domain_address.c
+++ b/src/qemu/qemu_domain_address.c
@@ -575,6 +575,9 @@ qemuDomainDeviceCalculatePCIAddressExtensionFlags(virQEMUCaps *qemuCaps,
         extFlags |= VIR_PCI_ADDRESS_EXTENSION_ZPCI;
     }
 
+    if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_VFIO_VFTOKEN))
+        extFlags |= VIR_PCI_ADDRESS_EXTENSION_VFTOKEN;
+
     return extFlags;
 }
 
-- 
2.25.1
_______________________________________________
Devel mailing list -- devel@xxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxx




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux