mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-09 22:14:36 -04:00
KVM: SVM: Add support for KVM_SEV_SEND_CANCEL command
After completion of SEND_START, but before SEND_FINISH, the source VMM can issue the SEND_CANCEL command to stop a migration. This is necessary so that a cancelled migration can restart with a new target later. Reviewed-by: Nathan Tempelman <natet@google.com> Reviewed-by: Brijesh Singh <brijesh.singh@amd.com> Signed-off-by: Steve Rutherford <srutherford@google.com> Message-Id: <20210412194408.2458827-1-srutherford@google.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
committed by
Paolo Bonzini
parent
fddecf6a23
commit
5569e2e7a6
@@ -73,6 +73,7 @@ enum sev_cmd {
|
||||
SEV_CMD_SEND_UPDATE_DATA = 0x041,
|
||||
SEV_CMD_SEND_UPDATE_VMSA = 0x042,
|
||||
SEV_CMD_SEND_FINISH = 0x043,
|
||||
SEV_CMD_SEND_CANCEL = 0x044,
|
||||
|
||||
/* Guest migration commands (incoming) */
|
||||
SEV_CMD_RECEIVE_START = 0x050,
|
||||
@@ -392,6 +393,15 @@ struct sev_data_send_finish {
|
||||
u32 handle; /* In */
|
||||
} __packed;
|
||||
|
||||
/**
|
||||
* struct sev_data_send_cancel - SEND_CANCEL command parameters
|
||||
*
|
||||
* @handle: handle of the VM to process
|
||||
*/
|
||||
struct sev_data_send_cancel {
|
||||
u32 handle; /* In */
|
||||
} __packed;
|
||||
|
||||
/**
|
||||
* struct sev_data_receive_start - RECEIVE_START command parameters
|
||||
*
|
||||
|
||||
@@ -1674,6 +1674,8 @@ enum sev_cmd_id {
|
||||
KVM_SEV_CERT_EXPORT,
|
||||
/* Attestation report */
|
||||
KVM_SEV_GET_ATTESTATION_REPORT,
|
||||
/* Guest Migration Extension */
|
||||
KVM_SEV_SEND_CANCEL,
|
||||
|
||||
KVM_SEV_NR_MAX,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user