1 .. SPDX-License-Identifier: GPL-2.0
3 PTP_KVM support for arm/arm64
4 =============================
6 PTP_KVM is used for high precision time sync between host and guests.
7 It relies on transferring the wall clock and counter value from the
8 host to the guest using a KVM-specific hypercall.
10 * ARM_SMCCC_VENDOR_HYP_KVM_PTP_FUNC_ID: 0x86000001
12 This hypercall uses the SMC32/HVC32 calling convention:
14 ARM_SMCCC_VENDOR_HYP_KVM_PTP_FUNC_ID
15 ============== ======== =====================================
16 Function ID: (uint32) 0x86000001
17 Arguments: (uint32) KVM_PTP_VIRT_COUNTER(0)
18 KVM_PTP_PHYS_COUNTER(1)
19 Return Values: (int32) NOT_SUPPORTED(-1) on error, or
20 (uint32) Upper 32 bits of wall clock time (r0)
21 (uint32) Lower 32 bits of wall clock time (r1)
22 (uint32) Upper 32 bits of counter (r2)
23 (uint32) Lower 32 bits of counter (r3)
24 Endianness: No Restrictions.
25 ============== ======== =====================================