diff options
author | Christian Borntraeger <borntraeger@de.ibm.com> | 2014-03-06 10:01:38 -0500 |
---|---|---|
committer | Christian Borntraeger <borntraeger@de.ibm.com> | 2014-03-17 06:06:51 -0400 |
commit | 2955c83f72801245afd0fe5c560cc75b82bea9aa (patch) | |
tree | dfb63b55c26af70604c8f175a8c11af557906ac4 /arch | |
parent | fed495d25e0137028c37678a14cd1d8466c02dd3 (diff) |
KVM: s390: Optimize ucontrol path
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>
CC: stable@vger.kernel.org
Diffstat (limited to 'arch')
-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 62683576f8e2..7337c577e949 100644 --- a/arch/s390/kvm/kvm-s390.c +++ b/arch/s390/kvm/kvm-s390.c | |||
@@ -896,7 +896,8 @@ static int vcpu_post_run(struct kvm_vcpu *vcpu, int exit_reason) | |||
896 | 896 | ||
897 | if (rc == 0) { | 897 | if (rc == 0) { |
898 | if (kvm_is_ucontrol(vcpu->kvm)) | 898 | if (kvm_is_ucontrol(vcpu->kvm)) |
899 | rc = -EOPNOTSUPP; | 899 | /* Don't exit for host interrupts. */ |
900 | rc = vcpu->arch.sie_block->icptcode ? -EOPNOTSUPP : 0; | ||
900 | else | 901 | else |
901 | rc = kvm_handle_sie_intercept(vcpu); | 902 | rc = kvm_handle_sie_intercept(vcpu); |
902 | } | 903 | } |