Re: [PATCH] KVM: SVM: document KVM_MEM_ENCRYPT_OP, let userspace detect if SEV is available
From: Brijesh Singh
Date: Fri Mar 20 2020 - 15:13:14 EST
On 3/20/20 12:42 PM, Paolo Bonzini wrote:
> Userspace has no way to query if SEV has been disabled with the
> sev module parameter of kvm-amd.ko. Actually it has one, but it
> is a hack: do ioctl(KVM_MEM_ENCRYPT_OP, NULL) and check if it
> returns EFAULT. Make it a little nicer by returning zero for
> SEV enabled and NULL argument, and while at it document the
> ioctl arguments.
>
> Cc: Brijesh Singh <brijesh.singh@xxxxxxx>
> Signed-off-by: Paolo Bonzini <pbonzini@xxxxxxxxxx>
thanks
Reviewed-by: Brijesh Singh <brijesh.singh@xxxxxxx>