Skip to main content

Module boot_timer

Module boot_timer 

Source
Expand description

Boot-timer — squib-internal latency device.

Per 14-virtio-and-devices.md § 4.8: a trivial virtio device with no queues. The device exposes a 4-byte config-space register at offset 0x100; on guest read, the register returns (now_monotonic_ns − boot_start_ns) truncated to u32 microseconds (saturating at u32::MAX ≈ 71 minutes).

boot_start_ns is captured at the same point the kernel-load completes, so the value the guest reads after init runs is “time from the moment the kernel got control to the moment Linux first scheduled userspace.” Used by the boot.rs criterion benchmark in 71-performance-budgets.md § 7.

Structs§

BootTimerDevice
virtio-boot-timer device.