On 15/03/21 16:55, Vitaly Kuznetsov wrote:
I think we should instead write 0 to the page in kvm_gen_update_masterclock.
We can do that but we will also need to invalidate
hv->tsc_ref.tsc_sequence to prevent MSR based clocksource
(HV_X64_MSR_TIME_REF_COUNT -> get_time_ref_counter()) from using stale
hv->tsc_ref.tsc_scale/tsc_offset values (in case we had them
calculated).
Yes, we're talking about the same thing (invalidating tsc_sequence is
done by writing 0 to it).
Paolo
Also, we can't really disable TSC page for nested scenario when guest
opted for reenlightenment (PATCH4) but we're not going to update the
page anyway so there's not much different.