From: Glauber Costa Subject: Re: [RFC] Do clock adjustments over migration Date: Thu, 15 Oct 2009 19:53:45 -0300 Message-ID: <20091015225345.GN8092@mothafucka.localdomain> References: <1255626925-3140-1-git-send-email-glommer@redhat.com> <20091015200816.GC11656@amt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: kvm@vger.kernel.org, avi@redhat.com, quintela@redhat.com To: Marcelo Tosatti Return-path: Received: from mx1.redhat.com ([209.132.183.28]:56943 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1763187AbZJOWyO (ORCPT ); Thu, 15 Oct 2009 18:54:14 -0400 Received: from int-mx04.intmail.prod.int.phx2.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.17]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n9FMrmGh026683 for ; Thu, 15 Oct 2009 18:53:48 -0400 Content-Disposition: inline In-Reply-To: <20091015200816.GC11656@amt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: On Thu, Oct 15, 2009 at 05:08:16PM -0300, Marcelo Tosatti wrote: > On Thu, Oct 15, 2009 at 01:15:25PM -0400, Glauber Costa wrote: > > Hey, > > > > This patch is a proposal only. Among other things, it relies on a patch > > Juan is yet to send, and I also would want to give it a bit more testing. > > It shows my indented use of the new ioctl interface I've been proposing. > > > > First of all, we have to save the kvmclock msrs. This is per-cpu, and we > > were failing to do it so far. > > > > The ioctls are issued in pre-save and post-load sections of a new vmstate > > handler. I am not doing it in the cpu vmstate handler, because this has to > > be done once per VM, not cpu. What I basically do is to grab the time > > from GET ioctl, pass on through migration, and then do a SET on the other > > side. Should be straighforward. > > > > Please let me hear your thoughts. And don't get me started with this > > "you can't hear thoughts" thing! > > > > Otherwise looks good. > Also, note that, in vmstate table for kvmclock, I am using U64, instead of UINT64. This is unexistant on current qemu, I had to patch it. Juan said he's planning on sending it to qemu-devel today or tomorrow.