diff options
Diffstat (limited to 'virt/kvm/assigned-dev.c')
-rw-r--r-- | virt/kvm/assigned-dev.c | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/virt/kvm/assigned-dev.c b/virt/kvm/assigned-dev.c index f4c7f591b5d8..8db43701016f 100644 --- a/virt/kvm/assigned-dev.c +++ b/virt/kvm/assigned-dev.c | |||
@@ -983,36 +983,6 @@ long kvm_vm_ioctl_assigned_device(struct kvm *kvm, unsigned ioctl, | |||
983 | goto out; | 983 | goto out; |
984 | break; | 984 | break; |
985 | } | 985 | } |
986 | #ifdef KVM_CAP_IRQ_ROUTING | ||
987 | case KVM_SET_GSI_ROUTING: { | ||
988 | struct kvm_irq_routing routing; | ||
989 | struct kvm_irq_routing __user *urouting; | ||
990 | struct kvm_irq_routing_entry *entries; | ||
991 | |||
992 | r = -EFAULT; | ||
993 | if (copy_from_user(&routing, argp, sizeof(routing))) | ||
994 | goto out; | ||
995 | r = -EINVAL; | ||
996 | if (routing.nr >= KVM_MAX_IRQ_ROUTES) | ||
997 | goto out; | ||
998 | if (routing.flags) | ||
999 | goto out; | ||
1000 | r = -ENOMEM; | ||
1001 | entries = vmalloc(routing.nr * sizeof(*entries)); | ||
1002 | if (!entries) | ||
1003 | goto out; | ||
1004 | r = -EFAULT; | ||
1005 | urouting = argp; | ||
1006 | if (copy_from_user(entries, urouting->entries, | ||
1007 | routing.nr * sizeof(*entries))) | ||
1008 | goto out_free_irq_routing; | ||
1009 | r = kvm_set_irq_routing(kvm, entries, routing.nr, | ||
1010 | routing.flags); | ||
1011 | out_free_irq_routing: | ||
1012 | vfree(entries); | ||
1013 | break; | ||
1014 | } | ||
1015 | #endif /* KVM_CAP_IRQ_ROUTING */ | ||
1016 | #ifdef __KVM_HAVE_MSIX | 986 | #ifdef __KVM_HAVE_MSIX |
1017 | case KVM_ASSIGN_SET_MSIX_NR: { | 987 | case KVM_ASSIGN_SET_MSIX_NR: { |
1018 | struct kvm_assigned_msix_nr entry_nr; | 988 | struct kvm_assigned_msix_nr entry_nr; |