From mboxrd@z Thu Jan 1 00:00:00 1970 From: Greg KH Subject: Re: [stable-3.4] possibly revert "KVM: X86 emulator: fix source operand decoding..." Date: Thu, 12 Sep 2013 09:55:59 -0700 Message-ID: <20130912165559.GE11614@kroah.com> References: <20130904164415.GA23288@windriver.com> <522EFCF1.6070909@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Paul Gortmaker , gleb@redhat.com, kvm@vger.kernel.org, stable-commits@vger.kernel.org To: Paolo Bonzini Return-path: Received: from mail.linuxfoundation.org ([140.211.169.12]:56040 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753636Ab3ILQ4A (ORCPT ); Thu, 12 Sep 2013 12:56:00 -0400 Content-Disposition: inline In-Reply-To: <522EFCF1.6070909@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Tue, Sep 10, 2013 at 01:05:21PM +0200, Paolo Bonzini wrote: > Il 04/09/2013 18:44, Paul Gortmaker ha scritto: > > Hi Greg, > >=20 > > The 3.4.44+ cherry pick: > >=20 > > ---------------- > > commit 5b5b30580218eae22609989546bac6e44d0eda6e > > Author: Gleb Natapov > > Date: Wed Apr 24 13:38:36 2013 +0300 > >=20 > > KVM: X86 emulator: fix source operand decoding for 8bit mov[zs]= x instructions > > =20 > > commit 660696d1d16a71e15549ce1bf74953be1592bcd3 upstream. > > =20 > > Source operand for one byte mov[zs]x is decoded incorrectly if = it is in > > high byte register. Fix that. > > =20 > > Signed-off-by: Gleb Natapov > > Signed-off-by: Greg Kroah-Hartman > > ---------------- > >=20 > > introduces the following: > >=20 > > arch/x86/kvm/emulate.c: In function =E2=80=98decode_operand=E2=80=99= : > > arch/x86/kvm/emulate.c:3974:4: warning: passing argument 1 of =E2=80= =98decode_register=E2=80=99 makes integer from pointer without a cast [= enabled by default] > > arch/x86/kvm/emulate.c:789:14: note: expected =E2=80=98u8=E2=80=99 = but argument is of type =E2=80=98struct x86_emulate_ctxt *=E2=80=99 > > arch/x86/kvm/emulate.c:3974:4: warning: passing argument 2 of =E2=80= =98decode_register=E2=80=99 makes pointer from integer without a cast [= enabled by default] > > arch/x86/kvm/emulate.c:789:14: note: expected =E2=80=98long unsigne= d int *=E2=80=99 but argument is of type =E2=80=98u8=E2=80=99 > >=20 > > Based on the severity of the warnings above, I'm reasonably sure th= ere will > > be some kind of runtime regressions due to this, but I stopped to i= nvestigate > > the warnings as soon as I saw them, before any run time testing. > >=20 > > It happens because mainline v3.7-rc1~113^2~40 (dd856efafe60) does t= his: > >=20 > > -static void *decode_register(u8 modrm_reg, unsigned long *regs, > > +static void *decode_register(struct x86_emulate_ctxt *ctxt, u8 mod= rm_reg, > >=20 > > Since 660696d1d16a71e1 was only applied to stable 3.4, 3.8, and 3.9= -- and > > the prerequisite above is in 3.7+, the issue should be limited to 3= =2E4.44+ >=20 > Right, the fix is not important to have for 3.4 kernels. Thanks for letting me know, I've now reverted it. greg k-h