[5/5] sparc32 stack bounds checking

From: William Lee Irwin III
Date: Sat Apr 17 2004 - 00:44:49 EST


Index: wli-2.6.5-mm6/arch/sparc/kernel/process.c
===================================================================
--- wli-2.6.5-mm6.orig/arch/sparc/kernel/process.c 2004-04-14 23:21:03.000000000 -0700
+++ wli-2.6.5-mm6/arch/sparc/kernel/process.c 2004-04-16 10:38:51.000000000 -0700
@@ -318,7 +318,7 @@
fp = (unsigned long) _ksp;
do {
/* Bogus frame pointer? */
- if (fp < (task_base + sizeof(struct task_struct)) ||
+ if (fp < (task_base + sizeof(struct thread_info)) ||
fp >= (task_base + (PAGE_SIZE << 1)))
break;
rw = (struct reg_window *) fp;
@@ -710,7 +710,7 @@
fp = task->thread_info->ksp + bias;
do {
/* Bogus frame pointer? */
- if (fp < (task_base + sizeof(struct task_struct)) ||
+ if (fp < (task_base + sizeof(struct thread_info)) ||
fp >= (task_base + (2 * PAGE_SIZE)))
break;
rw = (struct reg_window *) fp;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/