summaryrefslogtreecommitdiff
path: root/arch/s390/kernel/smp.c
diff options
context:
space:
mode:
authorHeiko Carstens <heiko.carstens@de.ibm.com>2015-12-08 14:10:12 +0100
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2015-12-18 14:59:31 +0100
commit3dbc78d3a179d99611111d2d86d4283f1f4f82b4 (patch)
tree7a3bd42badb069791b161b3ef8514b9ea7c8a6bf /arch/s390/kernel/smp.c
parente527aec434b59745654d3b34a3aa7ce3392a85a5 (diff)
s390/smp: save timestamp on external calls
This is supposed to make debugging easier: if within a dump we can see that an external call or emergency signal IPI is pending but all cpus are idle, we have no idea for how long the interrupt is outstanding. Therefore save a timestamp into the per cpu pcpu array of the target cpu whenever such an IPI is sent. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390/kernel/smp.c')
-rw-r--r--arch/s390/kernel/smp.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/s390/kernel/smp.c b/arch/s390/kernel/smp.c
index 9da95d8dfc62..654c36ec0c60 100644
--- a/arch/s390/kernel/smp.c
+++ b/arch/s390/kernel/smp.c
@@ -66,6 +66,7 @@ static DEFINE_PER_CPU(struct cpu *, cpu_device);
struct pcpu {
struct _lowcore *lowcore; /* lowcore page(s) for the cpu */
unsigned long ec_mask; /* bit mask for ec_xxx functions */
+ unsigned long ec_clk; /* sigp timestamp for ec_xxx */
signed char state; /* physical cpu state */
signed char polarization; /* physical polarization */
u16 address; /* physical cpu address */
@@ -174,6 +175,7 @@ static void pcpu_ec_call(struct pcpu *pcpu, int ec_bit)
if (test_and_set_bit(ec_bit, &pcpu->ec_mask))
return;
order = pcpu_running(pcpu) ? SIGP_EXTERNAL_CALL : SIGP_EMERGENCY_SIGNAL;
+ pcpu->ec_clk = get_tod_clock_fast();
pcpu_sigp_retry(pcpu, order, 0);
}