From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Roedel, Joerg" Subject: Re: [PATCH] KVM: svm: Fix erratum 383 check for 32-bit hosts Date: Wed, 26 May 2010 09:45:39 +0200 Message-ID: <20100526074538.GB23190@amd.com> References: <4BFCC995.5000303@web.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Cc: Avi Kivity , Marcelo Tosatti , kvm To: Jan Kiszka Return-path: Received: from tx2ehsobe003.messaging.microsoft.com ([65.55.88.13]:33242 "EHLO TX2EHSOBE006.bigfish.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751820Ab0EZHpw (ORCPT ); Wed, 26 May 2010 03:45:52 -0400 Content-Disposition: inline In-Reply-To: <4BFCC995.5000303@web.de> Sender: kvm-owner@vger.kernel.org List-ID: On Wed, May 26, 2010 at 03:11:17AM -0400, Jan Kiszka wrote: > From: Jan Kiszka > > This overflow should have left the check broken behind for 32-bit hosts. The check itself should work but it gives a compile warning for me (at least in my small userspace test I did ;) Good catch, thanks. > Signed-off-by: Jan Kiszka Acked-by: Joerg Roedel > --- > arch/x86/kvm/svm.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c > index 3c03c36..fd32791 100644 > --- a/arch/x86/kvm/svm.c > +++ b/arch/x86/kvm/svm.c > @@ -1460,7 +1460,7 @@ static bool is_erratum_383(void) > /* Bit 62 may or may not be set for this mce */ > value &= ~(1ULL << 62); > > - if (value != 0xb600000000010015) > + if (value != 0xb600000000010015ULL) > return false; > > /* Clear MCi_STATUS registers */ > -- > 1.6.0.2 >