From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Tokarev Subject: Re: 2.6.35-rc1 regression with pvclock and smp guests Date: Wed, 29 Sep 2010 12:12:57 +0400 Message-ID: <4CA2F509.80008@msgid.tls.msk.ru> References: <4C4D4B8B.80006@amd.com> <4C4DDB00.50203@xutrox.com> <4C4F48D0.8090609@xutrox.com> <4C500872.1020809@redhat.com> <4C536F80.5090205@xutrox.com> <4C538CCE.1010104@redhat.com> <4C540EC9.1010008@xutrox.com> <4C54512B.6000307@xutrox.com> <4C54B7DE.4060901@redhat.com> <20100802144300.GD14448@mothafucka.localdomain> <4C5729F6.2050605@redhat.com> <4C573A20.6030001@xutrox.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Arjan Koers <0h61vkll2ly8@xutrox.com>, Zachary Amsden , Glauber Costa , Avi Kivity , Andre Przywara To: kvm@vger.kernel.org Return-path: Received: from isrv.corpit.ru ([86.62.121.231]:56573 "EHLO isrv.corpit.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754378Ab0I2IM7 (ORCPT ); Wed, 29 Sep 2010 04:12:59 -0400 In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: Ping? ;) 28.09.2010 15:16, Michael Tokarev wrote: > Arjan Koers <0h61vkll2ly8 xutrox.com> writes: > >> Move a printk that's using the clock before it's ready >> >> Fix a hang during SMP kernel boot on KVM that showed up >> after commit 489fb490dbf8dab0249ad82b56688ae3842a79e8 >> (2.6.35) and 59aab522154a2f17b25335b63c1cf68a51fb6ae0 >> (2.6.34.1). The problem only occurs when >> CONFIG_PRINTK_TIME is set. >> >> Signed-off-by: Arjan Koers <0h61vkll2ly8 xutrox.com> >> >> diff --git a/arch/x86/kernel/kvmclock.c b/arch/x86/kernel/kvmclock.c >> index feaeb0d..71bf2df 100644 >> --- a/arch/x86/kernel/kvmclock.c >> +++ b/arch/x86/kernel/kvmclock.c >> @@ -125,12 +125,15 @@ static struct clocksource kvm_clock = { >> static int kvm_register_clock(char *txt) >> { >> int cpu = smp_processor_id(); >> - int low, high; >> + int low, high, ret; >> + >> low = (int)__pa(&per_cpu(hv_clock, cpu)) | 1; >> high = ((u64)__pa(&per_cpu(hv_clock, cpu)) >> 32); >> + ret = native_write_msr_safe(MSR_KVM_SYSTEM_TIME, low, high); >> printk(KERN_INFO "kvm-clock: cpu %d, msr %x:%x, %s\n", >> cpu, high, low, txt); >> - return native_write_msr_safe(MSR_KVM_SYSTEM_TIME, low, high); >> + >> + return ret; >> } >> >> #ifdef CONFIG_X86_LOCAL_APIC > > Folks, should this be sent to -stable kernel? It is not in any > upstream kernel as far as I can see (not in linus tree too), but > this is quite an issue and is hitting people.... > > The discussion were stalled quite a while ago too -- this email has > Date: Mon, 02 Aug 2010 23:35:28 +0200. > > Thanks! > > /mjt