summaryrefslogtreecommitdiffstats
path: root/cpukit
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2007-09-28 15:03:48 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2007-09-28 15:03:48 +0000
commit11d617593f7c3b245b8d210e5b56ccbe64819fb7 (patch)
treeeb658ea103f8ef5537f61b4639ef1779d571f5ce /cpukit
parentUpdate. (diff)
downloadrtems-11d617593f7c3b245b8d210e5b56ccbe64819fb7.tar.bz2
2007-09-28 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/stackchk/check.c: Eliminate output with little information. Always print a blown message using the same routine. Now works with GNAT RTS -fstack-checking if you have patch for the RTEMS specific support in your GCC version.
Diffstat (limited to 'cpukit')
-rw-r--r--cpukit/ChangeLog7
-rw-r--r--cpukit/libmisc/stackchk/check.c23
2 files changed, 20 insertions, 10 deletions
diff --git a/cpukit/ChangeLog b/cpukit/ChangeLog
index 1485afdeca..37a4b5ae00 100644
--- a/cpukit/ChangeLog
+++ b/cpukit/ChangeLog
@@ -1,3 +1,10 @@
+2007-09-28 Joel Sherrill <joel.sherrill@oarcorp.com>
+
+ * libmisc/stackchk/check.c: Eliminate output with little information.
+ Always print a blown message using the same routine. Now works with
+ GNAT RTS -fstack-checking if you have patch for the RTEMS specific
+ support in your GCC version.
+
2007-09-17 Joel Sherrill <joel.sherrill@oarcorp.com>
* posix/src/semaphorecreatesupp.c: Fixed warning.
diff --git a/cpukit/libmisc/stackchk/check.c b/cpukit/libmisc/stackchk/check.c
index 11bbcecead..a127079fec 100644
--- a/cpukit/libmisc/stackchk/check.c
+++ b/cpukit/libmisc/stackchk/check.c
@@ -64,11 +64,9 @@ static inline boolean Stack_check_Frame_pointer_in_range(
#if defined(__GNUC__)
if ( sp < the_stack->area ) {
- printk( "Stack Pointer Too Low!\n" );
return FALSE;
}
if ( sp > (the_stack->area + the_stack->size) ) {
- printk( "Stack Pointer Too High!\n" );
return FALSE;
}
#else
@@ -225,16 +223,14 @@ void Stack_check_report_blown_task(
#if defined(RTEMS_MULTIPROCESSING)
if (rtems_configuration_get_user_multiprocessing_table()) {
printk(
- "; node=%d\n",
+ "; node=%d",
rtems_configuration_get_user_multiprocessing_table()->node
);
}
- #else
- printk( "\n" );
#endif
printk(
- " stack covers range 0x%p - 0x%p (%d bytes)\n",
+ "\n stack covers range 0x%p - 0x%p (%d bytes)\n",
stack->area,
stack->area + stack->size - 1,
stack->size
@@ -305,10 +301,17 @@ boolean rtems_stack_checker_is_blown( void )
));
}
- if ( !sp_ok || !pattern_ok ) {
- return TRUE;
- }
- return FALSE;
+ /*
+ * The Stack Pointer and the Pattern Area are OK so return FALSE.
+ */
+ if ( sp_ok && pattern_ok )
+ return FALSE;
+
+ /*
+ * Let's report as much as we can.
+ */
+ Stack_check_report_blown_task( _Thread_Executing, pattern_ok );
+ return TRUE;
}
/*