summaryrefslogtreecommitdiffstats
path: root/drivers/misc/sgi-gru/gruprocfs.c
diff options
context:
space:
mode:
authorJack Steiner <steiner@sgi.com>2009-06-18 01:28:19 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2009-06-18 22:03:59 +0200
commitcd1334f03f7b799bc6893b511daf2080e8f73863 (patch)
tree468d9bc99e19aa7895321927eaf30c4dae55166f /drivers/misc/sgi-gru/gruprocfs.c
parentkexec: sysrq: simplify sysrq-c handler (diff)
downloadlinux-cd1334f03f7b799bc6893b511daf2080e8f73863.tar.xz
linux-cd1334f03f7b799bc6893b511daf2080e8f73863.zip
gru: bug fixes for GRU exception handling
Bug fixes for GRU exception handling. Additional fields from the CBR must be returned to the user to allow the user to correctly diagnose GRU exceptions. Handle endcase in TFH TLB miss handling. Verify that TFH actually indicates a pending exception. Signed-off-by: Jack Steiner <steiner@sgi.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/misc/sgi-gru/gruprocfs.c')
-rw-r--r--drivers/misc/sgi-gru/gruprocfs.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/misc/sgi-gru/gruprocfs.c b/drivers/misc/sgi-gru/gruprocfs.c
index ee74821b171c..c46c1c5f0c73 100644
--- a/drivers/misc/sgi-gru/gruprocfs.c
+++ b/drivers/misc/sgi-gru/gruprocfs.c
@@ -84,6 +84,8 @@ static int statistics_show(struct seq_file *s, void *p)
printstat(s, tlb_dropin_fail_range_active);
printstat(s, tlb_dropin_fail_idle);
printstat(s, tlb_dropin_fail_fmm);
+ printstat(s, tlb_dropin_fail_no_exception);
+ printstat(s, tlb_dropin_fail_no_exception_war);
printstat(s, mmu_invalidate_range);
printstat(s, mmu_invalidate_page);
printstat(s, mmu_clear_flush_young);
@@ -158,8 +160,7 @@ static ssize_t options_write(struct file *file, const char __user *userbuf,
unsigned long val;
char buf[80];
- if (copy_from_user
- (buf, userbuf, count < sizeof(buf) ? count : sizeof(buf)))
+ if (strncpy_from_user(buf, userbuf, sizeof(buf) - 1) < 0)
return -EFAULT;
buf[count - 1] = '\0';
if (!strict_strtoul(buf, 10, &val))