HomeFreeBSD

hyperv: Register Hyper-V timer early enough for TSC freq calibration

Description

hyperv: Register Hyper-V timer early enough for TSC freq calibration

The i8254 simulation in Hyper-V is kinda broken and is not available
in Generation 2 Hyper-V VMs, so Hyper-V timer must be registered early
enough so that it can be used to do the TSC freq calibration.

This fixes the notorious warning like this:
calcru: runtime went backwards from 50 usec to 25 usec for pid 0 (kernel)

Submitted by: Dexuan Cui <decui microsoft com>
Reviewed by: kib, sephe
Tested by: kib, sephe
MFC after: 1 week
Sponsored by: Microsoft OSTC
Differential Revision: https://reviews.freebsd.org/D5778

Details

Provenance
sepheAuthored on
Reviewer
kib
Differential Revision
D5778: hyperv: register hv_timecounter in SI_SUB_HYPERVISOR
Parents
rS297480: MFC r297335:
Branches
Unknown
Tags
Unknown