Skip to main content

calibrate

Function calibrate 

Source
pub fn calibrate(known_interval_ns: u64, tsc_delta: u64)
Expand description

Refine TSC frequency after timer calibration.

known_interval_ns : duration of the reference interval in nanoseconds. tsc_delta : TSC ticks measured over that interval.

Example: if the APIC timer calibration measured 10 ms (10_000_000 ns) and tsc_delta = 20_000_000 cycles → TSC runs at 2 GHz.