[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH] xen: preserve native TSC speed during migration between identical hosts
>>> On 24.05.17 at 16:25, <olaf@xxxxxxxxx> wrote: > @@ -2024,6 +2029,13 @@ void tsc_set_info(struct domain *d, > d->arch.vtsc_offset = get_s_time() - elapsed_nsec; > d->arch.tsc_khz = gtsc_khz ?: cpu_khz; > set_time_scale(&d->arch.vtsc_to_ns, d->arch.tsc_khz * 1000); > + if (!opt_vtsc_tolerance) { > + tolerated = d->arch.tsc_khz == cpu_khz; > + } else { Leaving aside the question of whether we want anything like this, there are multiple coding style issues here (braces on their own lines, blanks inside the parentheses of control statements). > + khz_diff = cpu_khz > d->arch.tsc_khz ? > + cpu_khz - d->arch.tsc_khz : d->arch.tsc_khz - cpu_khz; > + tolerated = khz_diff <= opt_vtsc_tolerance; > + } These assignments to tolerated also suggest it wants to be bool. Finally I don't think a host wide option will do. If it is to be of use (considering that it used wrong may break applications), it needs to be per-domain, and its value needs to be migrated (perhaps in the form of a low/high pair of TSC frequency values). Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |