WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] common time reference between domU and dom0

To: Keir Fraser <keir@xxxxxxx>
Subject: Re: [Xen-devel] common time reference between domU and dom0
From: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
Date: Fri, 10 Dec 2010 10:51:15 +0000
Cc: James Harper <james.harper@xxxxxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Fri, 10 Dec 2010 02:54:24 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C927B534.C5BA%keir@xxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <AEC6C66638C05B468B556EA548C1A77D01BB8980@trantor> <C927B534.C5BA%keir@xxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.20 (2009-06-14)
At 10:45 +0000 on 10 Dec (1291977908), Keir Fraser wrote:
> On 10/12/2010 10:20, "James Harper" <james.harper@xxxxxxxxxxxxxxxx> wrote:
> 
> >> On 10/12/2010 08:23, "James Harper" <james.harper@xxxxxxxxxxxxxxxx>
> > wrote:
> >> 
> >>>> 
> >>>> System time, as exposed to guests by Xen, should be good enough.
> >>>> 
> >>> 
> >>> How is this exposed for HVM systems?
> >> 
> >> Given all HVM guest time sources are trapped to the hypervisor,
> > including
> >> TSC, you may as well just use the HVMOP_get_time hypercall.
> >> 
> > 
> > Is that a new call? I don't see it mentioned in 4.0-testing anywhere.
> 
> Yeah I think it's in 4.1 only.
> 
> > Is there a fallback if HVMOP_get_time doesn't exist?
> 
> Switch on vtsc (might be default) and just use RDTSC? Might be good enough.

IIRC HVMOP_get_time was added because from Windows drivers you can't
tell what the Windows kernel has done to the TSC so you can't use it to
get system time yourself.  It seems to me that exposing the TSC offset
alongside the rest of the shared info would fix that but maybe you'd be
as well off backporting HVMOP_get_time instead.

Tim.

-- 
Tim Deegan <Tim.Deegan@xxxxxxxxxx>
Principal Software Engineer, Xen Platform Team
Citrix Systems UK Ltd.  (Company #02937203, SL9 0BG)

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel