summaryrefslogtreecommitdiffstats
path: root/include/sysemu/sev.h
diff options
context:
space:
mode:
authorDavid Gibson2020-12-04 02:51:51 +0100
committerDavid Gibson2021-02-08 06:57:38 +0100
commite0292d7c62673546c01d5c6b245735fdfef81840 (patch)
tree299d7c5c221b67eede72de51c7c7ec6a83b90d08 /include/sysemu/sev.h
parentconfidential guest support: Move side effect out of machine_set_memory_encryp... (diff)
downloadqemu-e0292d7c62673546c01d5c6b245735fdfef81840.tar.gz
qemu-e0292d7c62673546c01d5c6b245735fdfef81840.tar.xz
qemu-e0292d7c62673546c01d5c6b245735fdfef81840.zip
confidential guest support: Rework the "memory-encryption" property
Currently the "memory-encryption" property is only looked at once we get to kvm_init(). Although protection of guest memory from the hypervisor isn't something that could really ever work with TCG, it's not conceptually tied to the KVM accelerator. In addition, the way the string property is resolved to an object is almost identical to how a QOM link property is handled. So, create a new "confidential-guest-support" link property which sets this QOM interface link directly in the machine. For compatibility we keep the "memory-encryption" property, but now implemented in terms of the new property. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Reviewed-by: Greg Kurz <groug@kaod.org> Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Diffstat (limited to 'include/sysemu/sev.h')
-rw-r--r--include/sysemu/sev.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/sysemu/sev.h b/include/sysemu/sev.h
index 7335e59867..3b5b1aacf1 100644
--- a/include/sysemu/sev.h
+++ b/include/sysemu/sev.h
@@ -16,7 +16,7 @@
#include "sysemu/kvm.h"
-int sev_guest_init(const char *id);
+int sev_kvm_init(ConfidentialGuestSupport *cgs);
int sev_encrypt_flash(uint8_t *ptr, uint64_t len, Error **errp);
int sev_inject_launch_secret(const char *hdr, const char *secret,
uint64_t gpa, Error **errp);