From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:41156) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RSToO-00050H-W1 for qemu-devel@nongnu.org; Mon, 21 Nov 2011 08:21:34 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RSToO-0005Rx-3x for qemu-devel@nongnu.org; Mon, 21 Nov 2011 08:21:28 -0500 Received: from lo.gmane.org ([80.91.229.12]:49326) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RSToN-0005RV-UO for qemu-devel@nongnu.org; Mon, 21 Nov 2011 08:21:28 -0500 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1RSToL-0003qn-Nu for qemu-devel@nongnu.org; Mon, 21 Nov 2011 14:21:25 +0100 Received: from 93-34-207-114.ip51.fastwebnet.it ([93.34.207.114]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 21 Nov 2011 14:21:25 +0100 Received: from pbonzini by 93-34-207-114.ip51.fastwebnet.it with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 21 Nov 2011 14:21:25 +0100 From: Paolo Bonzini Date: Mon, 21 Nov 2011 14:21:14 +0100 Message-ID: References: <1321368671-1134-1-git-send-email-stefano.stabellini@eu.citrix.com> <4EC27D0D.3040204@codemonkey.ws> <4EC671AF.5030805@codemonkey.ws> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit In-Reply-To: <4EC671AF.5030805@codemonkey.ws> Subject: Re: [Qemu-devel] [PATCH 1/4] xen: introduce mc146818rtcxen List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: xen-devel@lists.xensource.com On 11/18/2011 03:54 PM, Anthony Liguori wrote: > > The Right Solution would be to modify the RTC emulation such that it did > a qemu_get_clock() during read of the CMOS registers in order to ensure > the time was up to date (instead of using 1 second timers). True, but you also have to handle UIP and the UF/AF interrupts. Basically you have to track the various pieces of state and trigger a timer when the routine would do something interesting. It's not hard, but it's also a decent amount of programming. Paolo From mboxrd@z Thu Jan 1 00:00:00 1970 From: Paolo Bonzini Subject: Re: [PATCH 1/4] xen: introduce mc146818rtcxen Date: Mon, 21 Nov 2011 14:21:14 +0100 Message-ID: References: <1321368671-1134-1-git-send-email-stefano.stabellini@eu.citrix.com> <4EC27D0D.3040204@codemonkey.ws> <4EC671AF.5030805@codemonkey.ws> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4EC671AF.5030805@codemonkey.ws> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org Sender: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org To: qemu-devel@nongnu.org Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On 11/18/2011 03:54 PM, Anthony Liguori wrote: > > The Right Solution would be to modify the RTC emulation such that it did > a qemu_get_clock() during read of the CMOS registers in order to ensure > the time was up to date (instead of using 1 second timers). True, but you also have to handle UIP and the UF/AF interrupts. Basically you have to track the various pieces of state and trigger a timer when the routine would do something interesting. It's not hard, but it's also a decent amount of programming. Paolo