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] [PATCH]xl: Add missing start_time entry when create and

To: Dan Magenheimer <dan.magenheimer@xxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH]xl: Add missing start_time entry when create and restore VMs
From: Yang Hongyang <yanghy@xxxxxxxxxxxxxx>
Date: Sat, 15 May 2010 09:54:23 +0800
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Fri, 14 May 2010 18:54:38 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <181d8804-a9f0-4707-a2bc-514132a13c29@default>
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: <4BED3507.2010307@xxxxxxxxxxxxxx> <181d8804-a9f0-4707-a2bc-514132a13c29@default>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.9) Gecko/20100415 Thunderbird/3.0.4
On 05/14/2010 11:47 PM, Dan Magenheimer wrote:
>> + vments[5] = libxl_sprintf(ctx, "%lu.%d", 
>> start_time.tv_sec,(int)start_time.tv_usec/10000);
>> + vments[i++] = libxl_sprintf(ctx, 
>> "%lu.%d",start_time.tv_sec,(int)start_time.tv_usec/10000);
> 
> I don't think these work as intended.  For example, if
> tv_usec is 10000, I think you want xxx.01 printed, not
> xxx.1.  Maybe you want %lu.%02d?

Ah sorry, you're right, I'll fix that, Thank you.

> 
> And in any case, is there a reason to limit the precision
> to two digits?  Why not %lu.%06d?
> 

I see no reason too. But the current start_time is limit to
two digits(vms created from 'xm create'). So I limit the
precision to two digits.

> 


-- 
Regards
Yang Hongyang

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