Skip to content

Commit 391df72

Browse files
committed
tools headers kvm: Sync kvm headers with the kernel sources
To pick up the changes from: 290a6bb ("arm64: KVM: Add UAPI notes for swapped registers") No tools changes are caused by this. This addresses these tools/perf build warnings: Cc: Adrian Hunter <[email protected]> Cc: Andrew Jones <[email protected]> Cc: Jiri Olsa <[email protected]> Cc: Marc Zyngier <[email protected]> Cc: Namhyung Kim <[email protected]> Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
1 parent 71dd652 commit 391df72

File tree

1 file changed

+10
-2
lines changed
  • tools/arch/arm64/include/uapi/asm

1 file changed

+10
-2
lines changed

tools/arch/arm64/include/uapi/asm/kvm.h

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -220,10 +220,18 @@ struct kvm_vcpu_events {
220220
#define KVM_REG_ARM_PTIMER_CVAL ARM64_SYS_REG(3, 3, 14, 2, 2)
221221
#define KVM_REG_ARM_PTIMER_CNT ARM64_SYS_REG(3, 3, 14, 0, 1)
222222

223-
/* EL0 Virtual Timer Registers */
223+
/*
224+
* EL0 Virtual Timer Registers
225+
*
226+
* WARNING:
227+
* KVM_REG_ARM_TIMER_CVAL and KVM_REG_ARM_TIMER_CNT are not defined
228+
* with the appropriate register encodings. Their values have been
229+
* accidentally swapped. As this is set API, the definitions here
230+
* must be used, rather than ones derived from the encodings.
231+
*/
224232
#define KVM_REG_ARM_TIMER_CTL ARM64_SYS_REG(3, 3, 14, 3, 1)
225-
#define KVM_REG_ARM_TIMER_CNT ARM64_SYS_REG(3, 3, 14, 3, 2)
226233
#define KVM_REG_ARM_TIMER_CVAL ARM64_SYS_REG(3, 3, 14, 0, 2)
234+
#define KVM_REG_ARM_TIMER_CNT ARM64_SYS_REG(3, 3, 14, 3, 2)
227235

228236
/* KVM-as-firmware specific pseudo-registers */
229237
#define KVM_REG_ARM_FW (0x0014 << KVM_REG_ARM_COPROC_SHIFT)

0 commit comments

Comments
 (0)