Commit de8e5d74 authored by Christian Borntraeger's avatar Christian Borntraeger

KVM: Disable compat ioctl for s390

We never had a 31bit QEMU/kuli running. We would need to review several
ioctls to check if this creates holes, bugs or whatever to make it work.
Lets just disable compat support for KVM on s390.
Signed-off-by: default avatarChristian Borntraeger <borntraeger@de.ibm.com>
Acked-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
parent 658b6eda
...@@ -43,3 +43,7 @@ config HAVE_KVM_ARCH_TLB_FLUSH_ALL ...@@ -43,3 +43,7 @@ config HAVE_KVM_ARCH_TLB_FLUSH_ALL
config KVM_GENERIC_DIRTYLOG_READ_PROTECT config KVM_GENERIC_DIRTYLOG_READ_PROTECT
bool bool
config KVM_COMPAT
def_bool y
depends on COMPAT && !S390
...@@ -92,7 +92,7 @@ struct dentry *kvm_debugfs_dir; ...@@ -92,7 +92,7 @@ struct dentry *kvm_debugfs_dir;
static long kvm_vcpu_ioctl(struct file *file, unsigned int ioctl, static long kvm_vcpu_ioctl(struct file *file, unsigned int ioctl,
unsigned long arg); unsigned long arg);
#ifdef CONFIG_COMPAT #ifdef CONFIG_KVM_COMPAT
static long kvm_vcpu_compat_ioctl(struct file *file, unsigned int ioctl, static long kvm_vcpu_compat_ioctl(struct file *file, unsigned int ioctl,
unsigned long arg); unsigned long arg);
#endif #endif
...@@ -2052,7 +2052,7 @@ static int kvm_vcpu_release(struct inode *inode, struct file *filp) ...@@ -2052,7 +2052,7 @@ static int kvm_vcpu_release(struct inode *inode, struct file *filp)
static struct file_operations kvm_vcpu_fops = { static struct file_operations kvm_vcpu_fops = {
.release = kvm_vcpu_release, .release = kvm_vcpu_release,
.unlocked_ioctl = kvm_vcpu_ioctl, .unlocked_ioctl = kvm_vcpu_ioctl,
#ifdef CONFIG_COMPAT #ifdef CONFIG_KVM_COMPAT
.compat_ioctl = kvm_vcpu_compat_ioctl, .compat_ioctl = kvm_vcpu_compat_ioctl,
#endif #endif
.mmap = kvm_vcpu_mmap, .mmap = kvm_vcpu_mmap,
...@@ -2342,7 +2342,7 @@ static long kvm_vcpu_ioctl(struct file *filp, ...@@ -2342,7 +2342,7 @@ static long kvm_vcpu_ioctl(struct file *filp,
return r; return r;
} }
#ifdef CONFIG_COMPAT #ifdef CONFIG_KVM_COMPAT
static long kvm_vcpu_compat_ioctl(struct file *filp, static long kvm_vcpu_compat_ioctl(struct file *filp,
unsigned int ioctl, unsigned long arg) unsigned int ioctl, unsigned long arg)
{ {
...@@ -2434,7 +2434,7 @@ static int kvm_device_release(struct inode *inode, struct file *filp) ...@@ -2434,7 +2434,7 @@ static int kvm_device_release(struct inode *inode, struct file *filp)
static const struct file_operations kvm_device_fops = { static const struct file_operations kvm_device_fops = {
.unlocked_ioctl = kvm_device_ioctl, .unlocked_ioctl = kvm_device_ioctl,
#ifdef CONFIG_COMPAT #ifdef CONFIG_KVM_COMPAT
.compat_ioctl = kvm_device_ioctl, .compat_ioctl = kvm_device_ioctl,
#endif #endif
.release = kvm_device_release, .release = kvm_device_release,
...@@ -2721,7 +2721,7 @@ static long kvm_vm_ioctl(struct file *filp, ...@@ -2721,7 +2721,7 @@ static long kvm_vm_ioctl(struct file *filp,
return r; return r;
} }
#ifdef CONFIG_COMPAT #ifdef CONFIG_KVM_COMPAT
struct compat_kvm_dirty_log { struct compat_kvm_dirty_log {
__u32 slot; __u32 slot;
__u32 padding1; __u32 padding1;
...@@ -2768,7 +2768,7 @@ static long kvm_vm_compat_ioctl(struct file *filp, ...@@ -2768,7 +2768,7 @@ static long kvm_vm_compat_ioctl(struct file *filp,
static struct file_operations kvm_vm_fops = { static struct file_operations kvm_vm_fops = {
.release = kvm_vm_release, .release = kvm_vm_release,
.unlocked_ioctl = kvm_vm_ioctl, .unlocked_ioctl = kvm_vm_ioctl,
#ifdef CONFIG_COMPAT #ifdef CONFIG_KVM_COMPAT
.compat_ioctl = kvm_vm_compat_ioctl, .compat_ioctl = kvm_vm_compat_ioctl,
#endif #endif
.llseek = noop_llseek, .llseek = noop_llseek,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment