From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH] KVM: Fix MAXPHYADDR calculation when cpuid does not support it Date: Sun, 11 Apr 2010 16:55:49 +0300 Message-ID: <4BC1D4E5.6070100@redhat.com> References: <1270989212-3117-1-git-send-email-avi@redhat.com> <4BC1CF54.4020804@cs.helsinki.fi> <4BC1CFBC.5060406@redhat.com> <4BC1D005.5090203@cs.helsinki.fi> <4BC1D26E.9080706@cs.helsinki.fi> <4BC1D339.20704@redhat.com> <4BC1D443.4010702@cs.helsinki.fi> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Marcelo Tosatti , kvm@vger.kernel.org To: Pekka Enberg Return-path: Received: from mx1.redhat.com ([209.132.183.28]:20293 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751875Ab0DKN4B (ORCPT ); Sun, 11 Apr 2010 09:56:01 -0400 In-Reply-To: <4BC1D443.4010702@cs.helsinki.fi> Sender: kvm-owner@vger.kernel.org List-ID: On 04/11/2010 04:53 PM, Pekka Enberg wrote: > Avi Kivity wrote: >> On 04/11/2010 04:45 PM, Pekka Enberg wrote: >>> Pekka Enberg wrote: >>>> Avi Kivity wrote: >>>>>> Hmm, doesn't seem to work here. I still that triple fault in guest. >>>>> >>>>> Can you add a printk to see what value is returned and why? >>>> >>>> Argh, it's a off-by one bug in my userspace tool... So the CPU >>>> really does support 0x80000008 and I'm just an idiot. :-) >>> >>> So to explain this a bit more: I'm setting 0x80000000 to 0x80000008 >>> but failing to install an entry for 0x80000008. I don't quite >>> understand why kvm_find_cpuid_entry() doesn't return NULL in this case? >> >> cpuid is defined to return the highest entry if it doesn't find a match. > > OK, then it's a bug of my own doing and we don't need to do anything > in the kernel. I think the patch is nevertheless correct, not sure why it worked so far. -- error compiling committee.c: too many arguments to function