|
|
|
|
|
|
|
|
|
|
xen-devel
Re: [Xen-devel] Re: [PATCH][v4] PV extension of HVM(hybrid) support in X
On 03/01/2010 07:36 PM, Sheng Yang wrote:
static u64 pvclock_get_nsec_offset(struct pvclock_shadow_time *shadow)
{
u64 delta = native_read_tsc() - shadow->tsc_timestamp;
return scale_delta(delta, shadow->tsc_to_nsec_mul, shadow-
tsc_shift);
}
tsc_timestamp take the vcpu beginning at 0, so that's the assumption.
Why would it be 0? Xen sets tsc_timestamp to the current tsc when it
updates the time parameters, which is whenever the vcpu is scheduled on
a pcpu (and other times). There's no expectation that the tsc starts
from 0, since that won't ever be the case.
J
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|
|
|