aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2013-05-18 15:35:44 -0400
committerHelge Deller <deller@gmx.de>2013-05-24 16:35:26 -0400
commitd0c3be806a3fe7f4abdb0f7e7287addb55e73f35 (patch)
tree13c96d75c8b8f30ab1eac74f5a0f28903fc7078f /arch
parentfbb46caa1bd2d99079a24f8a6ae0b33655e42fae (diff)
parisc: show number of FPE and unaligned access handler calls in /proc/interrupts
Show number of floating point assistant and unaligned access fixup handler in /proc/interrupts file. Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'arch')
-rw-r--r--arch/parisc/include/asm/hardirq.h2
-rw-r--r--arch/parisc/kernel/irq.c8
-rw-r--r--arch/parisc/kernel/traps.c1
-rw-r--r--arch/parisc/kernel/unaligned.c3
4 files changed, 14 insertions, 0 deletions
diff --git a/arch/parisc/include/asm/hardirq.h b/arch/parisc/include/asm/hardirq.h
index c19f7138ba48..4c6dd8da1e5d 100644
--- a/arch/parisc/include/asm/hardirq.h
+++ b/arch/parisc/include/asm/hardirq.h
@@ -28,6 +28,8 @@ typedef struct {
28 unsigned int irq_resched_count; 28 unsigned int irq_resched_count;
29 unsigned int irq_call_count; 29 unsigned int irq_call_count;
30#endif 30#endif
31 unsigned int irq_unaligned_count;
32 unsigned int irq_fpassist_count;
31 unsigned int irq_tlb_count; 33 unsigned int irq_tlb_count;
32} ____cacheline_aligned irq_cpustat_t; 34} ____cacheline_aligned irq_cpustat_t;
33 35
diff --git a/arch/parisc/kernel/irq.c b/arch/parisc/kernel/irq.c
index 55237a70e197..9c2d953f3de5 100644
--- a/arch/parisc/kernel/irq.c
+++ b/arch/parisc/kernel/irq.c
@@ -188,6 +188,14 @@ int arch_show_interrupts(struct seq_file *p, int prec)
188 seq_printf(p, "%10u ", irq_stats(j)->irq_call_count); 188 seq_printf(p, "%10u ", irq_stats(j)->irq_call_count);
189 seq_puts(p, " Function call interrupts\n"); 189 seq_puts(p, " Function call interrupts\n");
190#endif 190#endif
191 seq_printf(p, "%*s: ", prec, "UAH");
192 for_each_online_cpu(j)
193 seq_printf(p, "%10u ", irq_stats(j)->irq_unaligned_count);
194 seq_puts(p, " Unaligned access handler traps\n");
195 seq_printf(p, "%*s: ", prec, "FPA");
196 for_each_online_cpu(j)
197 seq_printf(p, "%10u ", irq_stats(j)->irq_fpassist_count);
198 seq_puts(p, " Floating point assist traps\n");
191 seq_printf(p, "%*s: ", prec, "TLB"); 199 seq_printf(p, "%*s: ", prec, "TLB");
192 for_each_online_cpu(j) 200 for_each_online_cpu(j)
193 seq_printf(p, "%10u ", irq_stats(j)->irq_tlb_count); 201 seq_printf(p, "%10u ", irq_stats(j)->irq_tlb_count);
diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c
index fe41a98043bb..04e47c6a4562 100644
--- a/arch/parisc/kernel/traps.c
+++ b/arch/parisc/kernel/traps.c
@@ -646,6 +646,7 @@ void notrace handle_interruption(int code, struct pt_regs *regs)
646 case 14: 646 case 14:
647 /* Assist Exception Trap, i.e. floating point exception. */ 647 /* Assist Exception Trap, i.e. floating point exception. */
648 die_if_kernel("Floating point exception", regs, 0); /* quiet */ 648 die_if_kernel("Floating point exception", regs, 0); /* quiet */
649 __inc_irq_stat(irq_fpassist_count);
649 handle_fpe(regs); 650 handle_fpe(regs);
650 return; 651 return;
651 652
diff --git a/arch/parisc/kernel/unaligned.c b/arch/parisc/kernel/unaligned.c
index 234e3682cf09..d7c0acb35ec2 100644
--- a/arch/parisc/kernel/unaligned.c
+++ b/arch/parisc/kernel/unaligned.c
@@ -27,6 +27,7 @@
27#include <linux/signal.h> 27#include <linux/signal.h>
28#include <linux/ratelimit.h> 28#include <linux/ratelimit.h>
29#include <asm/uaccess.h> 29#include <asm/uaccess.h>
30#include <asm/hardirq.h>
30 31
31/* #define DEBUG_UNALIGNED 1 */ 32/* #define DEBUG_UNALIGNED 1 */
32 33
@@ -454,6 +455,8 @@ void handle_unaligned(struct pt_regs *regs)
454 struct siginfo si; 455 struct siginfo si;
455 register int flop=0; /* true if this is a flop */ 456 register int flop=0; /* true if this is a flop */
456 457
458 __inc_irq_stat(irq_unaligned_count);
459
457 /* log a message with pacing */ 460 /* log a message with pacing */
458 if (user_mode(regs)) { 461 if (user_mode(regs)) {
459 if (current->thread.flags & PARISC_UAC_SIGBUS) { 462 if (current->thread.flags & PARISC_UAC_SIGBUS) {