1 .. SPDX-License-Identifier: GPL-2.0 2 3 Paravirtualized time support for arm64 4 ====================================== 5 6 Arm specification DEN0057/A defines a standard 7 support for AArch64 guests: 8 9 https://developer.arm.com/docs/den0057/a 10 11 KVM/arm64 implements the stolen time part of t 12 some hypervisor service calls to support a par 13 view of the amount of time stolen from its exe 14 15 Two new SMCCC compatible hypercalls are define 16 17 * PV_TIME_FEATURES: 0xC5000020 18 * PV_TIME_ST: 0xC5000021 19 20 These are only available in the SMC64/HVC64 ca 21 paravirtualized time is not available to 32 bi 22 the PV_TIME_FEATURES hypercall should be probe 23 ARCH_FEATURES mechanism before calling it. 24 25 PV_TIME_FEATURES 26 27 ============= ======== ================ 28 Function ID: (uint32) 0xC5000020 29 PV_call_id: (uint32) The function to 30 Currently only P 31 Return value: (int64) NOT_SUPPORTED (- 32 PV-time feature 33 ============= ======== ================ 34 35 PV_TIME_ST 36 37 ============= ======== ================ 38 Function ID: (uint32) 0xC5000021 39 Return value: (int64) IPA of the stole 40 VCPU. On failure 41 NOT_SUPPORTED (- 42 ============= ======== ================ 43 44 The IPA returned by PV_TIME_ST should be mappe 45 with inner and outer write back caching attrib 46 domain. A total of 16 bytes from the IPA retur 47 meaningfully filled by the hypervisor (see str 48 49 PV_TIME_ST returns the structure for the calli 50 51 Stolen Time 52 ----------- 53 54 The structure pointed to by the PV_TIME_ST hyp 55 56 +-------------+-------------+-------------+--- 57 | Field | Byte Length | Byte Offset | De 58 +=============+=============+=============+=== 59 | Revision | 4 | 0 | Mu 60 +-------------+-------------+-------------+--- 61 | Attributes | 4 | 4 | Mu 62 +-------------+-------------+-------------+--- 63 | Stolen time | 8 | 8 | St 64 | | | | na 65 | | | | mu 66 | | | | wa 67 | | | | ru 68 +-------------+-------------+-------------+--- 69 70 All values in the structure are stored little- 71 72 The structure will be updated by the hyperviso 73 will be present within a reserved region of th 74 guest. The guest should not attempt to write i 75 structure per VCPU of the guest. 76 77 It is advisable that one or more 64k pages are 78 these structures and not used for other purpos 79 the region using 64k pages and avoids conflict 80 81 For the user space interface see 82 :ref:`Documentation/virt/kvm/devices/vcpu.rst
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.