From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup Date: Wed, 19 Dec 2007 16:53:08 +0200 Message-ID: <47693054.20501@qumranet.com> References: <47680173.6060606@qumranet.com> <20071218221930.GA26109@elte.hu> <4768BB43.1000609@qumranet.com> <4768FE27.7020305@qumranet.com> <47690304.1090903@qumranet.com> <20071219140624.GF21282@elte.hu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel , linux-kernel , Avi Kivity To: Ingo Molnar Return-path: In-Reply-To: <20071219140624.GF21282-X9Un+BFzKDI@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Ingo Molnar wrote: > * Avi Kivity wrote: > > >> Avi Kivity wrote: >> >>> Testing shows wrmsr and rdtsc function normally. >>> >>> I'll try pinning the vcpus to cpus and see if that helps. >>> >>> >> It does. >> > > do we let the guest read the physical CPU's TSC? That would be trouble. > > vmx (and svm) allow us to add an offset to the physical tsc. We set it on startup to -tsc (so that an rdtsc on boot would return 0), and massage it on vcpu migration so that guest rdtsc is monotonic. The net effect is that tsc on a vcpu can experience large forward jumps and changes in rate, but no negative jumps. -- error compiling committee.c: too many arguments to function ------------------------------------------------------------------------- SF.Net email is sponsored by: Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace