diff options
author | Christian Borntraeger <borntraeger@de.ibm.com> | 2020-01-30 19:18:28 +0300 |
---|---|---|
committer | Christian Borntraeger <borntraeger@de.ibm.com> | 2020-02-27 21:47:12 +0300 |
commit | 72f218208fa63806ebcfca7e793b095d346ee0a4 (patch) | |
tree | 8920305e4cb7924aba137d00602f35e4b868f096 /arch/s390 | |
parent | 3adae0b4ca64c08a6c05a54be0becf9d127d39dc (diff) | |
download | linux-72f218208fa63806ebcfca7e793b095d346ee0a4.tar.xz |
KVM: s390: protvirt: do not inject interrupts after start
As PSW restart is handled by the ultravisor (and we only get a start
notification) we must re-check the PSW after a start before injecting
interrupts.
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
Diffstat (limited to 'arch/s390')
-rw-r--r-- | arch/s390/kvm/kvm-s390.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c index 66ba6ca714fb..fed025ea6f62 100644 --- a/arch/s390/kvm/kvm-s390.c +++ b/arch/s390/kvm/kvm-s390.c @@ -4516,6 +4516,13 @@ int kvm_s390_vcpu_start(struct kvm_vcpu *vcpu) kvm_s390_clear_cpuflags(vcpu, CPUSTAT_STOPPED); /* + * The real PSW might have changed due to a RESTART interpreted by the + * ultravisor. We block all interrupts and let the next sie exit + * refresh our view. + */ + if (kvm_s390_pv_cpu_is_protected(vcpu)) + vcpu->arch.sie_block->gpsw.mask &= ~PSW_INT_MASK; + /* * Another VCPU might have used IBS while we were offline. * Let's play safe and flush the VCPU at startup. */ |