]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: s390: Fix program check on interrupt delivery handling
authorChristian Borntraeger <borntraeger@de.ibm.com>
Fri, 25 Jul 2008 13:51:54 +0000 (15:51 +0200)
committerAvi Kivity <avi@qumranet.com>
Sun, 27 Jul 2008 08:36:05 +0000 (11:36 +0300)
commitfa1eefd161f7dbd9f2bb274d09f6ff39a21da6e0
tree2d453cdd9c9f6e83caf404c2982701fb1a91c994
parenta3149ba4ea514b0b6be37304e3649cb0fe309b9b
KVM: s390: Fix program check on interrupt delivery handling

The current interrupt handling on s390 misbehaves on an error case. On s390
each cpu has the prefix area (lowcore) for interrupt delivery. This memory
must always be available. If we fail to access the prefix area for a guest
on interrupt delivery the configuration is completely unusable. There is no
point in sending another program interrupt to an inaccessible lowcore.
Furthermore, we should not bug the host kernel, because this can be triggered
by userspace. I think the guest kernel itself can not trigger the problem, as
SET PREFIX and SIGNAL PROCESSOR SET PREFIX both check that the memory is
available and sane. As this is a userspace bug (e.g. setting the wrong guest
offset, unmapping guest memory) we should kill the userspace process instead
of BUGing the host kernel.
In the long term we probably should notify the userspace process about this
problem.

Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
arch/s390/kvm/interrupt.c