From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 3/8] KVM: mark apic enabled on start up. Date: Sun, 05 Aug 2012 17:39:33 +0300 Message-ID: <501E85A5.9050108@redhat.com> References: <1344171513-4659-1-git-send-email-gleb@redhat.com> <1344171513-4659-4-git-send-email-gleb@redhat.com> <501E7FE3.3010405@redhat.com> <20120805141713.GO27579@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, mtosatti@redhat.com To: Gleb Natapov Return-path: Received: from mx1.redhat.com ([209.132.183.28]:9508 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754427Ab2HEOjf (ORCPT ); Sun, 5 Aug 2012 10:39:35 -0400 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q75EdZde031211 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 5 Aug 2012 10:39:35 -0400 In-Reply-To: <20120805141713.GO27579@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On 08/05/2012 05:17 PM, Gleb Natapov wrote: > On Sun, Aug 05, 2012 at 05:14:59PM +0300, Avi Kivity wrote: >> On 08/05/2012 03:58 PM, Gleb Natapov wrote: >> > According to SDM apic is enabled on start up. >> > >> > Signed-off-by: Gleb Natapov >> > --- >> > arch/x86/kvm/lapic.c | 3 ++- >> > 1 file changed, 2 insertions(+), 1 deletion(-) >> > >> > diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c >> > index 49f4ac0..c3f14fe 100644 >> > --- a/arch/x86/kvm/lapic.c >> > +++ b/arch/x86/kvm/lapic.c >> > @@ -1311,7 +1311,8 @@ int kvm_create_lapic(struct kvm_vcpu *vcpu) >> > HRTIMER_MODE_ABS); >> > apic->lapic_timer.timer.function = apic_timer_fn; >> > >> > - kvm_lapic_set_base(vcpu, APIC_DEFAULT_PHYS_BASE); >> > + kvm_lapic_set_base(vcpu, >> > + APIC_DEFAULT_PHYS_BASE | MSR_IA32_APICBASE_ENABLE); >> > >> >> I'm guessing that in practice this is a no-op since qemu reset involves >> programming this MSR. >> > Qemu is not the only userspace :) But this is here to avoid unneeded > jump label patching truth to be told. It's also correct, otherwise it wouldn't be here. But won't the patching happen anyway? since it starts software disabled? -- error compiling committee.c: too many arguments to function