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]
Date:   Mon, 13 Jan 2020 16:21:32 +0800
From:   Yang Weijiang <weijiang.yang@...el.com>
To:     Sean Christopherson <sean.j.christopherson@...el.com>
Cc:     Yang Weijiang <weijiang.yang@...el.com>, kvm@...r.kernel.org,
        linux-kernel@...r.kernel.org, pbonzini@...hat.com,
        jmattson@...gle.com, yu.c.zhang@...ux.intel.com,
        alazar@...defender.com, edwin.zhai@...el.com
Subject: Re: [RESEND PATCH v10 05/10] x86: spp: Introduce user-space SPP
 IOCTLs

On Fri, Jan 10, 2020 at 10:10:53AM -0800, Sean Christopherson wrote:
> On Thu, Jan 02, 2020 at 02:13:14PM +0800, Yang Weijiang wrote:
> > User application, e.g., QEMU or VMI, must initialize SPP
> > before gets/sets SPP subpages, the dynamic initialization is to
> > reduce the extra storage cost if the SPP feature is not not used.
> > 
> > Co-developed-by: He Chen <he.chen@...ux.intel.com>
> > Signed-off-by: He Chen <he.chen@...ux.intel.com>
> > Co-developed-by: Zhang Yi <yi.z.zhang@...ux.intel.com>
> > Signed-off-by: Zhang Yi <yi.z.zhang@...ux.intel.com>
> > Signed-off-by: Yang Weijiang <weijiang.yang@...el.com>
> > ---
> >  arch/x86/include/asm/kvm_host.h |  4 ++
> >  arch/x86/kvm/mmu/spp.c          | 44 +++++++++++++++
> >  arch/x86/kvm/mmu/spp.h          |  9 ++++
> >  arch/x86/kvm/vmx/vmx.c          | 15 ++++++
> >  arch/x86/kvm/x86.c              | 95 ++++++++++++++++++++++++++++++++-
> >  include/uapi/linux/kvm.h        |  3 ++
> >  6 files changed, 169 insertions(+), 1 deletion(-)
> > 
> > diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
> > index f5145b86d620..c7a9f03f39a7 100644
> > --- a/arch/x86/include/asm/kvm_host.h
> > +++ b/arch/x86/include/asm/kvm_host.h
> > @@ -1238,6 +1238,10 @@ struct kvm_x86_ops {
> >  
> >  	bool (*apic_init_signal_blocked)(struct kvm_vcpu *vcpu);
> >  	int (*enable_direct_tlbflush)(struct kvm_vcpu *vcpu);
> > +
> > +	int (*init_spp)(struct kvm *kvm);
> > +	int (*flush_subpages)(struct kvm *kvm, u64 gfn, u32 npages);
> > +	int (*get_inst_len)(struct kvm_vcpu *vcpu);
> 
> If this is necessary, which hopefully it isn't, then get_insn_len() to be
> consistent with other KVM nomenclature.
>
Yep, will change it.

> A comment for the series overall, it needs a lot of work to properly order
> code between patches.  E.g. this patch introduces get_inst_len() without
> any justification in the changelog and without a user.  At best it's
> confusing, at worst this series will be impossible to bisect.

I'll double check the patch and add more comments on some confusing
points. Meanwhile, will re-order some code to make the serial testable,
thanks a lot for your careful review!

Powered by blists - more mailing lists