diff options
Diffstat (limited to 'arch/ia64/kvm/kvm-ia64.c')
-rw-r--r-- | arch/ia64/kvm/kvm-ia64.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/arch/ia64/kvm/kvm-ia64.c b/arch/ia64/kvm/kvm-ia64.c index 29afd9a252ff..9b109f25e49c 100644 --- a/arch/ia64/kvm/kvm-ia64.c +++ b/arch/ia64/kvm/kvm-ia64.c | |||
@@ -144,6 +144,7 @@ int kvm_arch_hardware_enable(void *garbage) | |||
144 | VP_INIT_ENV : VP_INIT_ENV_INITALIZE, | 144 | VP_INIT_ENV : VP_INIT_ENV_INITALIZE, |
145 | __pa(kvm_vm_buffer), KVM_VM_BUFFER_BASE, &tmp_base); | 145 | __pa(kvm_vm_buffer), KVM_VM_BUFFER_BASE, &tmp_base); |
146 | if (status != 0) { | 146 | if (status != 0) { |
147 | spin_unlock(&vp_lock); | ||
147 | printk(KERN_WARNING"kvm: Failed to Enable VT Support!!!!\n"); | 148 | printk(KERN_WARNING"kvm: Failed to Enable VT Support!!!!\n"); |
148 | return -EINVAL; | 149 | return -EINVAL; |
149 | } | 150 | } |
@@ -979,11 +980,13 @@ long kvm_arch_vm_ioctl(struct file *filp, | |||
979 | r = -EFAULT; | 980 | r = -EFAULT; |
980 | if (copy_from_user(&irq_event, argp, sizeof irq_event)) | 981 | if (copy_from_user(&irq_event, argp, sizeof irq_event)) |
981 | goto out; | 982 | goto out; |
983 | r = -ENXIO; | ||
982 | if (irqchip_in_kernel(kvm)) { | 984 | if (irqchip_in_kernel(kvm)) { |
983 | __s32 status; | 985 | __s32 status; |
984 | status = kvm_set_irq(kvm, KVM_USERSPACE_IRQ_SOURCE_ID, | 986 | status = kvm_set_irq(kvm, KVM_USERSPACE_IRQ_SOURCE_ID, |
985 | irq_event.irq, irq_event.level); | 987 | irq_event.irq, irq_event.level); |
986 | if (ioctl == KVM_IRQ_LINE_STATUS) { | 988 | if (ioctl == KVM_IRQ_LINE_STATUS) { |
989 | r = -EFAULT; | ||
987 | irq_event.status = status; | 990 | irq_event.status = status; |
988 | if (copy_to_user(argp, &irq_event, | 991 | if (copy_to_user(argp, &irq_event, |
989 | sizeof irq_event)) | 992 | sizeof irq_event)) |
@@ -1379,7 +1382,7 @@ static void kvm_release_vm_pages(struct kvm *kvm) | |||
1379 | int i, j; | 1382 | int i, j; |
1380 | unsigned long base_gfn; | 1383 | unsigned long base_gfn; |
1381 | 1384 | ||
1382 | slots = rcu_dereference(kvm->memslots); | 1385 | slots = kvm_memslots(kvm); |
1383 | for (i = 0; i < slots->nmemslots; i++) { | 1386 | for (i = 0; i < slots->nmemslots; i++) { |
1384 | memslot = &slots->memslots[i]; | 1387 | memslot = &slots->memslots[i]; |
1385 | base_gfn = memslot->base_gfn; | 1388 | base_gfn = memslot->base_gfn; |
@@ -1535,8 +1538,10 @@ long kvm_arch_vcpu_ioctl(struct file *filp, | |||
1535 | goto out; | 1538 | goto out; |
1536 | 1539 | ||
1537 | if (copy_to_user(user_stack, stack, | 1540 | if (copy_to_user(user_stack, stack, |
1538 | sizeof(struct kvm_ia64_vcpu_stack))) | 1541 | sizeof(struct kvm_ia64_vcpu_stack))) { |
1542 | r = -EFAULT; | ||
1539 | goto out; | 1543 | goto out; |
1544 | } | ||
1540 | 1545 | ||
1541 | break; | 1546 | break; |
1542 | } | 1547 | } |