diff options
author | Christian Borntraeger <borntraeger@de.ibm.com> | 2014-03-06 16:01:38 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-05-06 07:59:24 -0700 |
commit | 6d807fb1a3280648dffbdb78751d762d07048b5a (patch) | |
tree | a1786c627f507f02465d1b41564fb786e1e2a0df /arch/s390 | |
parent | 0149df238fd66b16e3aab4d1750342a7750150a6 (diff) | |
download | linux-stable-6d807fb1a3280648dffbdb78751d762d07048b5a.tar.gz linux-stable-6d807fb1a3280648dffbdb78751d762d07048b5a.tar.bz2 linux-stable-6d807fb1a3280648dffbdb78751d762d07048b5a.zip |
KVM: s390: Optimize ucontrol path
commit 2955c83f72801245afd0fe5c560cc75b82bea9aa upstream.
Since commit 7c470539c95630c1f2a10f109e96f249730b75eb
(s390/kvm: avoid automatic sie reentry) we will run through the C code
of KVM on host interrupts instead of just reentering the guest. This
will result in additional ucontrol exits (at least HZ per second). Let
handle a 0 intercept in the kernel and dont return to userspace,
even if in ucontrol mode.
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/s390')
-rw-r--r-- | arch/s390/kvm/kvm-s390.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c index e0676f390d57..95f4a976c160 100644 --- a/arch/s390/kvm/kvm-s390.c +++ b/arch/s390/kvm/kvm-s390.c @@ -753,7 +753,8 @@ static int vcpu_post_run(struct kvm_vcpu *vcpu, int exit_reason) if (rc == 0) { if (kvm_is_ucontrol(vcpu->kvm)) - rc = -EOPNOTSUPP; + /* Don't exit for host interrupts. */ + rc = vcpu->arch.sie_block->icptcode ? -EOPNOTSUPP : 0; else rc = kvm_handle_sie_intercept(vcpu); } |