From 65a6d8dd3f322e91efa320f2811bec83dde36b6b Mon Sep 17 00:00:00 2001 From: Peter Maydell Date: Fri, 25 May 2018 14:27:54 +0100 Subject: Update Linux headers to 4.17-rc6 Update our copy of the Linux headers to upstream 4.17-rc6 (kernel commit 771c577c23bac90597c68). Signed-off-by: Peter Maydell Message-Id: <20180525132755.21839-6-peter.maydell@linaro.org> Reviewed-by: Michael S. Tsirkin Signed-off-by: Paolo Bonzini --- linux-headers/asm-x86/hyperv.h | 1 - linux-headers/asm-x86/kvm.h | 19 ++++++++++++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) delete mode 100644 linux-headers/asm-x86/hyperv.h (limited to 'linux-headers/asm-x86') diff --git a/linux-headers/asm-x86/hyperv.h b/linux-headers/asm-x86/hyperv.h deleted file mode 100644 index 01af4d8..0000000 --- a/linux-headers/asm-x86/hyperv.h +++ /dev/null @@ -1 +0,0 @@ -#include "standard-headers/asm-x86/hyperv.h" diff --git a/linux-headers/asm-x86/kvm.h b/linux-headers/asm-x86/kvm.h index f3a9604..c535c2f 100644 --- a/linux-headers/asm-x86/kvm.h +++ b/linux-headers/asm-x86/kvm.h @@ -354,8 +354,25 @@ struct kvm_xcrs { __u64 padding[16]; }; -/* definition of registers in kvm_run */ +#define KVM_SYNC_X86_REGS (1UL << 0) +#define KVM_SYNC_X86_SREGS (1UL << 1) +#define KVM_SYNC_X86_EVENTS (1UL << 2) + +#define KVM_SYNC_X86_VALID_FIELDS \ + (KVM_SYNC_X86_REGS| \ + KVM_SYNC_X86_SREGS| \ + KVM_SYNC_X86_EVENTS) + +/* kvm_sync_regs struct included by kvm_run struct */ struct kvm_sync_regs { + /* Members of this structure are potentially malicious. + * Care must be taken by code reading, esp. interpreting, + * data fields from them inside KVM to prevent TOCTOU and + * double-fetch types of vulnerabilities. + */ + struct kvm_regs regs; + struct kvm_sregs sregs; + struct kvm_vcpu_events events; }; #define KVM_X86_QUIRK_LINT0_REENABLED (1 << 0) -- cgit v1.1