From: Avi Kivity <a...@redhat.com> So we can extend it later.
Signed-off-by: Avi Kivity <a...@redhat.com> diff --git a/Documentation/kvm/api.txt b/Documentation/kvm/api.txt index f504e0b..36594ba 100644 --- a/Documentation/kvm/api.txt +++ b/Documentation/kvm/api.txt @@ -608,8 +608,8 @@ page of a blob (32- or 64-bit, depending on the vcpu mode) to guest memory. struct kvm_xen_hvm_config { + __u32 flags; __u32 msr; - __u32 pad1; __u64 blob_addr_32; __u64 blob_addr_64; __u8 blob_size_32; diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index 7203bca..93ed656 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -2542,6 +2542,9 @@ long kvm_arch_vm_ioctl(struct file *filp, if (copy_from_user(&kvm->arch.xen_hvm_config, argp, sizeof(struct kvm_xen_hvm_config))) goto out; + r = -EINVAL; + if (kvm->arch.xen_hvm_config.flags) + goto out; r = 0; break; } diff --git a/include/linux/kvm.h b/include/linux/kvm.h index cf2b011..6ed1a12 100644 --- a/include/linux/kvm.h +++ b/include/linux/kvm.h @@ -494,8 +494,8 @@ struct kvm_x86_mce { #ifdef KVM_CAP_XEN_HVM struct kvm_xen_hvm_config { + __u32 flags; __u32 msr; - __u32 pad1; __u64 blob_addr_32; __u64 blob_addr_64; __u8 blob_size_32; -- To unsubscribe from this list: send the line "unsubscribe kvm-commits" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html