From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50294) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V2eBe-0006Hx-TX for qemu-devel@nongnu.org; Fri, 26 Jul 2013 05:19:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V2eBe-0008Oz-0a for qemu-devel@nongnu.org; Fri, 26 Jul 2013 05:19:46 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59270) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V2eBd-0008O0-OX for qemu-devel@nongnu.org; Fri, 26 Jul 2013 05:19:45 -0400 Message-ID: <51F23F17.7050500@redhat.com> Date: Fri, 26 Jul 2013 11:19:19 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1374396185-10870-1-git-send-email-pingfank@linux.vnet.ibm.com> <20130725120530.GJ21033@stefanha-thinkpad.redhat.com> <51F11AFB.9040008@siemens.com> <1A5D30F9703985AD026648F0@nimrod.local> <20130726084345.GE31438@stefanha-thinkpad.redhat.com> <5C76DA22418E161C26FCDF26@nimrod.local> In-Reply-To: <5C76DA22418E161C26FCDF26@nimrod.local> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC 0/8] arm AioContext with its own timer stuff List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alex Bligh Cc: Kevin Wolf , Anthony Liguori , Stefan Hajnoczi , qemu-devel@nongnu.org, Liu Ping Fan , Stefan Hajnoczi , Jan Kiszka Il 26/07/2013 11:08, Alex Bligh ha scritto: > > > --On 26 July 2013 10:43:45 +0200 Stefan Hajnoczi > wrote: > >> block.c and block/qed.c use vm_clock because block drivers should not do >> guest I/O while the vm is stopped. This is especially true during live >> migration where it's important to hand off the image file from the >> source host to the destination host with good cache consistency. The >> source host is not allowed to modify the image file anymore once the >> destination host has resumed the guest. >> >> Block jobs use rt_clock because they aren't considered guest I/O. > > That's going to be 'interesting' if qemu-img uses a block driver that > uses a timer, as I don't think the vm timer is running when qemu-img > is running. Yes, it is, see stubs/cpu-get-clock.c: #include "qemu-common.h" #include "qemu/timer.h" int64_t cpu_get_clock(void) { return get_clock_realtime(); } vm_clock becomes a synonym of rt_clock basically. Paolo