Skip to content

Commit

Permalink
tools headers svm: Sync svm headers with the kernel sources
Browse files Browse the repository at this point in the history
To pick the changes in:

  8c29f01 ("x86/sev: Add SEV-SNP guest feature negotiation support")

That triggers:

  CC      /tmp/build/perf-tools/arch/x86/util/kvm-stat.o
  CC      /tmp/build/perf-tools/util/header.o
  LD      /tmp/build/perf-tools/arch/x86/util/perf-in.o
  LD      /tmp/build/perf-tools/arch/x86/perf-in.o
  LD      /tmp/build/perf-tools/arch/perf-in.o
  LD      /tmp/build/perf-tools/util/perf-in.o
  LD      /tmp/build/perf-tools/perf-in.o
  LINK    /tmp/build/perf-tools/perf

But this time causes no changes in tooling results, as the introduced
SVM_VMGEXIT_TERM_REQUEST exit reason wasn't added to SVM_EXIT_REASONS,
that is used in kvm-stat.c.

And addresses this perf build warning:

  Warning: Kernel ABI header at 'tools/arch/x86/include/uapi/asm/svm.h' differs from latest version at 'arch/x86/include/uapi/asm/svm.h'
  diff -u tools/arch/x86/include/uapi/asm/svm.h arch/x86/include/uapi/asm/svm.h

Cc: Adrian Hunter <[email protected]>
Cc: Borislav Petkov (AMD) <[email protected]>
Cc: Ian Rogers <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Nikunj A Dadhania <[email protected]>
Link: http://lore.kernel.org/lkml/
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
  • Loading branch information
acmel committed Mar 2, 2023
1 parent 3de34f8 commit a98c071
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tools/arch/x86/include/uapi/asm/svm.h
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,12 @@
#define SVM_VMGEXIT_AP_CREATE 1
#define SVM_VMGEXIT_AP_DESTROY 2
#define SVM_VMGEXIT_HV_FEATURES 0x8000fffd
#define SVM_VMGEXIT_TERM_REQUEST 0x8000fffe
#define SVM_VMGEXIT_TERM_REASON(reason_set, reason_code) \
/* SW_EXITINFO1[3:0] */ \
(((((u64)reason_set) & 0xf)) | \
/* SW_EXITINFO1[11:4] */ \
((((u64)reason_code) & 0xff) << 4))
#define SVM_VMGEXIT_UNSUPPORTED_EVENT 0x8000ffff

/* Exit code reserved for hypervisor/software use */
Expand Down

0 comments on commit a98c071

Please sign in to comment.