aboutsummaryrefslogtreecommitdiff
path: root/target-s390x
diff options
context:
space:
mode:
authorThomas Huth <thuth@linux.vnet.ibm.com>2014-05-07 09:45:21 +0200
committerCornelia Huck <cornelia.huck@de.ibm.com>2014-06-10 09:50:27 +0200
commit6449a41a4d4082ddb0a6e156c7e8932fe7d60fbf (patch)
tree6c2ac2134f16d6cbcb059a43b8aea893f0ab50da /target-s390x
parenta2689242b10a7bbc9a952659a2a5cc04a86d10e1 (diff)
s390x/kvm: Log unmanageable program interruptions
The kernel only drops to userspace if an endless program interrupt loop has been detected. Let's print an error message in this case to inform the user about the crash and stop the affected CPU with a panic event, just like it is already done for the external interruption loop detection. Signed-off-by: Thomas Huth <thuth@linux.vnet.ibm.com> Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Diffstat (limited to 'target-s390x')
-rw-r--r--target-s390x/kvm.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/target-s390x/kvm.c b/target-s390x/kvm.c
index be703bd87b..9adda1b46b 100644
--- a/target-s390x/kvm.c
+++ b/target-s390x/kvm.c
@@ -83,6 +83,7 @@
#define DIAG_KVM_BREAKPOINT 0x501
#define ICPT_INSTRUCTION 0x04
+#define ICPT_PROGRAM 0x08
#define ICPT_EXT_INT 0x14
#define ICPT_WAITPSW 0x1c
#define ICPT_SOFT_INTERCEPT 0x24
@@ -966,6 +967,11 @@ static int handle_intercept(S390CPU *cpu)
case ICPT_INSTRUCTION:
r = handle_instruction(cpu, run);
break;
+ case ICPT_PROGRAM:
+ unmanageable_intercept(cpu, "program interrupt",
+ offsetof(LowCore, program_new_psw));
+ r = EXCP_HALTED;
+ break;
case ICPT_EXT_INT:
unmanageable_intercept(cpu, "external interrupt",
offsetof(LowCore, external_new_psw));