From mboxrd@z Thu Jan 1 00:00:00 1970 From: Radim =?utf-8?B?S3LEjW3DocWZ?= Subject: Re: [PATCH v2 2/2] x86: svm: make wbinvd faster Date: Mon, 2 Mar 2015 20:05:34 +0100 Message-ID: <20150302190534.GA2494@potion.brq.redhat.com> References: <20150302180030.25137.83460.stgit@joelvmguard2.amd.com> <20150302180446.25137.93897.stgit@joelvmguard2.amd.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Gleb Natapov , Paolo Bonzini , kvm@vger.kernel.org, David Kaplan , Joerg Roedel , linux-kernel@vger.kernel.org, Borislav Petkov To: Joel Schopp Return-path: Content-Disposition: inline In-Reply-To: <20150302180446.25137.93897.stgit@joelvmguard2.amd.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org 2015-03-02 12:04-0600, Joel Schopp: > From: David Kaplan > No need to re-decode WBINVD since we know what it is from the interce= pt. >=20 > Signed-off-by: David Kaplan > [extracted from larger unlrelated patch, forward ported, tested] > Signed-off-by: Joel Schopp > --- Reviewed-by: Radim Kr=C4=8Dm=C3=A1=C5=99 > diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c > @@ -2774,6 +2774,13 @@ static int skinit_interception(struct vcpu_svm= *svm) > return 1; > } > =20 > +static int wbinvd_interception(struct vcpu_svm *svm) > +{ > + kvm_emulate_wbinvd(&svm->vcpu); > + return 1; > +} > + > + (Squashing these lines would have been a nice improvement.) > static int xsetbv_interception(struct vcpu_svm *svm) > { > u64 new_bv =3D kvm_read_edx_eax(&svm->vcpu);