lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZruLs4+EE5xHCAcp@ls.amr.corp.intel.com>
Date: Tue, 13 Aug 2024 09:37:07 -0700
From: Isaku Yamahata <isaku.yamahata@...el.com>
To: Rick Edgecombe <rick.p.edgecombe@...el.com>
Cc: seanjc@...gle.com, pbonzini@...hat.com, kvm@...r.kernel.org,
	kai.huang@...el.com, isaku.yamahata@...il.com,
	tony.lindgren@...ux.intel.com, xiaoyao.li@...el.com,
	linux-kernel@...r.kernel.org,
	Isaku Yamahata <isaku.yamahata@...el.com>
Subject: Re: [PATCH 08/25] KVM: TDX: Add place holder for TDX VM specific
 mem_enc_op ioctl

On Mon, Aug 12, 2024 at 03:48:03PM -0700,
Rick Edgecombe <rick.p.edgecombe@...el.com> wrote:

> diff --git a/arch/x86/kvm/vmx/tdx.c b/arch/x86/kvm/vmx/tdx.c
> index b1c885ce8c9c..de14e80d8f3a 100644
> --- a/arch/x86/kvm/vmx/tdx.c
> +++ b/arch/x86/kvm/vmx/tdx.c
> @@ -2,6 +2,7 @@
>  #include <linux/cpu.h>
>  #include <asm/tdx.h>
>  #include "capabilities.h"
> +#include "x86_ops.h"
>  #include "tdx.h"
>  
>  #undef pr_fmt
> @@ -29,6 +30,37 @@ static void __used tdx_guest_keyid_free(int keyid)
>  	ida_free(&tdx_guest_keyid_pool, keyid);
>  }
>  
> +int tdx_vm_ioctl(struct kvm *kvm, void __user *argp)
> +{
> +	struct kvm_tdx_cmd tdx_cmd;
> +	int r;
> +
> +	if (copy_from_user(&tdx_cmd, argp, sizeof(struct kvm_tdx_cmd)))
> +		return -EFAULT;
> +
> +	/*
> +	 * Userspace should never set @error. It is used to fill

nitpick: @hw_error

-- 
Isaku Yamahata <isaku.yamahata@...el.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ