summaryrefslogtreecommitdiff
path: root/rust/kernel/alloc/allocator
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw@amazon.co.uk>2026-06-04 10:35:16 +0100
committerThomas Gleixner <tglx@kernel.org>2026-06-05 14:25:03 +0200
commitc51100f9e26857f2b2376d5cd657a15f52b9e05c (patch)
treeb9630f53aca5f8fb6c3b25c7fb87f3db7380968d /rust/kernel/alloc/allocator
parentca1ec8bfac8c95d0fed9e3611ea21400d1f37262 (diff)
clocksource/hyperv: Implement read_snapshot() for TSC page clocksource
Implement the read_snapshot() callback for the Hyper-V TSC page clock- source. This returns the derived 10MHz reference time (for timekeeping) while also providing the raw TSC value that was used to compute it. When the TSC page is valid, hv_read_tsc_page_tsc() atomically captures both values from a single RDTSC inside the sequence-counter protected read. When the TSC page is invalid (sequence == 0), the hw_csid and hw_cycles are set to zero indicating no value is available. This enables ktime_get_snapshot_id() to provide the raw TSC to consumers like KVM's master clock when running nested guests under Hyper-V. Signed-off-by: David Woodhouse <dwmw@amazon.co.uk> Signed-off-by: Thomas Gleixner <tglx@kernel.org> Assisted-by: Kiro:claude-opus-4.6-1m Reviewed-by: Michael Kelley <mhklinux@outlook.com> Link: https://patch.msgid.link/20260604095755.64849-2-dwmw2@infradead.org
Diffstat (limited to 'rust/kernel/alloc/allocator')
0 files changed, 0 insertions, 0 deletions