Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

KVM: s390: only deliver service interrupt with payload

Routine __inject_service() may set both the SERVICE and SERVICE_EV
pending bits, and in the case of a pure service event the corresponding
trip through __deliver_service_ev() will clear the SERVICE_EV bit only.
This necessitates an additional trip through __deliver_service() for
the other pending interrupt bit, however it is possible that the
external interrupt parameters are zero and there is nothing to be
delivered to the guest.

To avoid sending empty data to the guest, let's only write out the SCLP
data when there is something for the guest to do, otherwise bail out.

Signed-off-by: Eric Farman <farman@linux.ibm.com>
Acked-by: Christian Borntraeger <borntraeger@linux.ibm.com>
Signed-off-by: Christian Borntraeger <borntraeger@linux.ibm.com>
Signed-off-by: Janosch Frank <frankja@linux.ibm.com>

authored by

Eric Farman and committed by
Janosch Frank
2623c96f 11439c46

+3
+3
arch/s390/kvm/interrupt.c
··· 956 956 set_bit(IRQ_PEND_EXT_SERVICE, &fi->masked_irqs); 957 957 spin_unlock(&fi->lock); 958 958 959 + if (!ext.ext_params) 960 + return 0; 961 + 959 962 VCPU_EVENT(vcpu, 4, "deliver: sclp parameter 0x%x", 960 963 ext.ext_params); 961 964 vcpu->stat.deliver_service_signal++;