]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemu: Extend the capabilities with tpm-crb device
authorStefan Berger <stefanb@linux.vnet.ibm.com>
Thu, 26 Apr 2018 17:42:17 +0000 (13:42 -0400)
committerJohn Ferlan <jferlan@redhat.com>
Thu, 3 May 2018 15:28:42 +0000 (11:28 -0400)
QEMU on x86_64 (since v2.12) can support tpm-crb devices.
Introduce qemu capabilities for this device.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
Reviewed-by: John Ferlan <jferlan@redhat.com>
src/qemu/qemu_capabilities.c
src/qemu/qemu_capabilities.h
tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml

index aa8d350f51a934f57ead1a9168d75decdbb7e175..7b2e863cd2edf16b5b8a4d0e86c6c6a8fab252fa 100644 (file)
@@ -474,6 +474,7 @@ VIR_ENUM_IMPL(virQEMUCaps, QEMU_CAPS_LAST,
               "query-cpus-fast",
               "disk-write-cache",
               "nbd-tls",
+              "tpm-crb",
     );
 
 
@@ -2344,6 +2345,10 @@ const struct tpmTypeToCaps virQEMUCapsTPMModelsToCaps[] = {
         .type = VIR_DOMAIN_TPM_MODEL_TIS,
         .caps = QEMU_CAPS_DEVICE_TPM_TIS,
     },
+    {
+        .type = VIR_DOMAIN_TPM_MODEL_CRB,
+        .caps = QEMU_CAPS_DEVICE_TPM_CRB,
+    },
 };
 
 static int
index 2afe7ef5809f3abdd4c9af991da78e750de7a2e4..8da18a8063becc6e09879eabf524af2f6d79dfee 100644 (file)
@@ -458,6 +458,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check */
     QEMU_CAPS_QUERY_CPUS_FAST, /* query-cpus-fast command */
     QEMU_CAPS_DISK_WRITE_CACHE, /* qemu block frontends support write-cache param */
     QEMU_CAPS_NBD_TLS, /* NBD server supports TLS transport */
+    QEMU_CAPS_DEVICE_TPM_CRB, /* -device tpm-crb */
 
     QEMU_CAPS_LAST /* this must always be the last item */
 } virQEMUCapsFlags;
index 0b18dd00f9b0136b781feb51c6a7f947dabf5b22..7c346e5a5cda22e1a6d2ae3026e30cbfc71cfba1 100644 (file)
   <flag name='query-cpus-fast'/>
   <flag name='disk-write-cache'/>
   <flag name='nbd-tls'/>
+  <flag name='tpm-crb'/>
   <version>2011090</version>
   <kvmVersion>0</kvmVersion>
   <microcodeVersion>390060</microcodeVersion>