aboutsummaryrefslogtreecommitdiffstats
path: root/arch/parisc/kernel/unaligned.c
diff options
context:
space:
mode:
authorJeff Garzik <jgarzik@pobox.com>2005-10-28 18:50:09 -0400
committerJeff Garzik <jgarzik@pobox.com>2005-10-28 18:50:09 -0400
commit9dfb7808fb05643b0d06df7411b94d9546696bf1 (patch)
treeaa1a9cc1e79ae66f6cbb0fe39d79a80ca76331e8 /arch/parisc/kernel/unaligned.c
parentc45154a3b1fecdbb51b5462c9f730b44e62b83a5 (diff)
parent20731945ae743034353a88c307920d1f16cf8ac8 (diff)
Merge branch 'master'
Diffstat (limited to 'arch/parisc/kernel/unaligned.c')
-rw-r--r--arch/parisc/kernel/unaligned.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/arch/parisc/kernel/unaligned.c b/arch/parisc/kernel/unaligned.c
index 62eea35bcd69..eaae8a021f9f 100644
--- a/arch/parisc/kernel/unaligned.c
+++ b/arch/parisc/kernel/unaligned.c
@@ -513,15 +513,18 @@ void handle_unaligned(struct pt_regs *regs)
513 register int flop=0; /* true if this is a flop */ 513 register int flop=0; /* true if this is a flop */
514 514
515 /* log a message with pacing */ 515 /* log a message with pacing */
516 if (user_mode(regs)) 516 if (user_mode(regs)) {
517 { 517 if (current->thread.flags & PARISC_UAC_SIGBUS) {
518 if (unaligned_count > 5 && jiffies - last_time > 5*HZ) 518 goto force_sigbus;
519 { 519 }
520
521 if (unaligned_count > 5 && jiffies - last_time > 5*HZ) {
520 unaligned_count = 0; 522 unaligned_count = 0;
521 last_time = jiffies; 523 last_time = jiffies;
522 } 524 }
523 if (++unaligned_count < 5) 525
524 { 526 if (!(current->thread.flags & PARISC_UAC_NOPRINT)
527 && ++unaligned_count < 5) {
525 char buf[256]; 528 char buf[256];
526 sprintf(buf, "%s(%d): unaligned access to 0x" RFMT " at ip=0x" RFMT "\n", 529 sprintf(buf, "%s(%d): unaligned access to 0x" RFMT " at ip=0x" RFMT "\n",
527 current->comm, current->pid, regs->ior, regs->iaoq[0]); 530 current->comm, current->pid, regs->ior, regs->iaoq[0]);
@@ -530,6 +533,7 @@ void handle_unaligned(struct pt_regs *regs)
530 show_regs(regs); 533 show_regs(regs);
531#endif 534#endif
532 } 535 }
536
533 if (!unaligned_enabled) 537 if (!unaligned_enabled)
534 goto force_sigbus; 538 goto force_sigbus;
535 } 539 }