ptp-sync 0.0.2

Synchronize the system-wide real-time clock based on a source PTP clock
Documentation
1
2
3
4
5
6
7
8
9
10
//! Synchronize the system-wide real-time clock based on KVM's paravirtualized PTP clock.

use anyhow::Context;

fn main() -> ::anyhow::Result<()> {
    ::ptp_sync::ClockSyncer::with_kvm_clock()
        .context("failed to initialize ClockSyncer")?
        .sync()
        .context("failed to synchronize system clock")
}