diff options
Diffstat (limited to 'arch/s390/kvm/diag.c')
-rw-r--r-- | arch/s390/kvm/diag.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/s390/kvm/diag.c b/arch/s390/kvm/diag.c index 3a74d8af0d69..78d967f180f4 100644 --- a/arch/s390/kvm/diag.c +++ b/arch/s390/kvm/diag.c | |||
@@ -107,14 +107,13 @@ static int __diag_ipl_functions(struct kvm_vcpu *vcpu) | |||
107 | 107 | ||
108 | static int __diag_virtio_hypercall(struct kvm_vcpu *vcpu) | 108 | static int __diag_virtio_hypercall(struct kvm_vcpu *vcpu) |
109 | { | 109 | { |
110 | int ret, idx; | 110 | int ret; |
111 | 111 | ||
112 | /* No virtio-ccw notification? Get out quickly. */ | 112 | /* No virtio-ccw notification? Get out quickly. */ |
113 | if (!vcpu->kvm->arch.css_support || | 113 | if (!vcpu->kvm->arch.css_support || |
114 | (vcpu->run->s.regs.gprs[1] != KVM_S390_VIRTIO_CCW_NOTIFY)) | 114 | (vcpu->run->s.regs.gprs[1] != KVM_S390_VIRTIO_CCW_NOTIFY)) |
115 | return -EOPNOTSUPP; | 115 | return -EOPNOTSUPP; |
116 | 116 | ||
117 | idx = srcu_read_lock(&vcpu->kvm->srcu); | ||
118 | /* | 117 | /* |
119 | * The layout is as follows: | 118 | * The layout is as follows: |
120 | * - gpr 2 contains the subchannel id (passed as addr) | 119 | * - gpr 2 contains the subchannel id (passed as addr) |
@@ -125,7 +124,6 @@ static int __diag_virtio_hypercall(struct kvm_vcpu *vcpu) | |||
125 | vcpu->run->s.regs.gprs[2], | 124 | vcpu->run->s.regs.gprs[2], |
126 | 8, &vcpu->run->s.regs.gprs[3], | 125 | 8, &vcpu->run->s.regs.gprs[3], |
127 | vcpu->run->s.regs.gprs[4]); | 126 | vcpu->run->s.regs.gprs[4]); |
128 | srcu_read_unlock(&vcpu->kvm->srcu, idx); | ||
129 | 127 | ||
130 | /* | 128 | /* |
131 | * Return cookie in gpr 2, but don't overwrite the register if the | 129 | * Return cookie in gpr 2, but don't overwrite the register if the |