[PATCH 1/9] score: Remove fatal is internal indicator
Sebastian Huber
sebastian.huber at embedded-brains.de
Fri Dec 9 08:45:29 UTC 2016
The fatal is internal indicator is redundant since the fatal source and
error code uniquely identify a fatal error. Keep the fatal user
extension is internal parameter for backward compatibility and set it to
false always.
Update #2825.
---
c/src/lib/libbsp/powerpc/shared/startup/panic.c | 2 --
cpukit/libcsupport/src/gxx_wrappers.c | 12 ++------
cpukit/libcsupport/src/malloc_initialize.c | 6 +---
cpukit/posix/src/pthreadinitthreads.c | 1 -
cpukit/rtems/src/taskinitusers.c | 3 +-
cpukit/sapi/Makefile.am | 2 +-
cpukit/sapi/include/rtems/fatal.h | 17 ++++++-----
cpukit/sapi/src/exshutdown.c | 2 +-
cpukit/sapi/src/fatal.c | 2 +-
cpukit/sapi/src/fatal2.c | 35 -----------------------
cpukit/sapi/src/posixapi.c | 2 +-
cpukit/score/cpu/nios2/nios2-context-initialize.c | 2 +-
cpukit/score/cpu/nios2/nios2-isr-get-level.c | 2 +-
cpukit/score/cpu/nios2/nios2-isr-set-level.c | 2 +-
cpukit/score/cpu/powerpc/ppc-isr-vector-install.c | 6 +---
cpukit/score/include/rtems/score/interr.h | 7 +----
cpukit/score/include/rtems/score/smpimpl.h | 2 +-
cpukit/score/include/rtems/score/userext.h | 4 +--
cpukit/score/include/rtems/score/userextimpl.h | 4 +--
cpukit/score/src/heap.c | 2 +-
cpukit/score/src/interr.c | 12 ++++----
cpukit/score/src/isr.c | 1 -
cpukit/score/src/mpci.c | 19 ++----------
cpukit/score/src/objectinitializeinformation.c | 1 -
cpukit/score/src/objectmp.c | 19 ++----------
cpukit/score/src/thread.c | 6 +---
cpukit/score/src/threaddispatch.c | 2 --
cpukit/score/src/threadhandler.c | 6 +---
cpukit/score/src/threadmp.c | 6 +---
cpukit/score/src/threadqenqueue.c | 7 +----
cpukit/score/src/threadrestart.c | 6 +---
cpukit/score/src/userextiterate.c | 2 +-
cpukit/score/src/wkspace.c | 12 ++------
testsuites/libtests/devnullfatal01/testcase.h | 1 -
testsuites/psxtests/psxfatal01/testcase.h | 1 -
testsuites/psxtests/psxfatal02/testcase.h | 1 -
testsuites/psxtests/psxfatal_support/init.c | 11 ++-----
testsuites/sptests/spfatal01/testcase.h | 1 -
testsuites/sptests/spfatal02/testcase.h | 1 -
testsuites/sptests/spfatal03/testcase.h | 1 -
testsuites/sptests/spfatal04/testcase.h | 1 -
testsuites/sptests/spfatal05/testcase.h | 1 -
testsuites/sptests/spfatal06/testcase.h | 1 -
testsuites/sptests/spfatal07/testcase.h | 1 -
testsuites/sptests/spfatal08/testcase.h | 1 -
testsuites/sptests/spfatal09/testcase.h | 1 -
testsuites/sptests/spfatal10/testcase.h | 1 -
testsuites/sptests/spfatal11/testcase.h | 1 -
testsuites/sptests/spfatal12/testcase.h | 1 -
testsuites/sptests/spfatal13/testcase.h | 1 -
testsuites/sptests/spfatal14/testcase.h | 1 -
testsuites/sptests/spfatal15/testcase.h | 1 -
testsuites/sptests/spfatal16/testcase.h | 1 -
testsuites/sptests/spfatal17/testcase.h | 1 -
testsuites/sptests/spfatal18/testcase.h | 1 -
testsuites/sptests/spfatal19/testcase.h | 1 -
testsuites/sptests/spfatal20/testcase.h | 1 -
testsuites/sptests/spfatal24/testcase.h | 1 -
testsuites/sptests/spfatal25/testcase.h | 1 -
testsuites/sptests/spfatal27/testcase.h | 1 -
testsuites/sptests/spfatal28/testcase.h | 3 +-
testsuites/sptests/spfatal29/testcase.h | 1 -
testsuites/sptests/spfatal_support/init.c | 17 ++++-------
testsuites/sptests/spinternalerror01/init.c | 10 ++-----
testsuites/sptests/sptimecounter01/init.c | 2 +-
65 files changed, 59 insertions(+), 225 deletions(-)
delete mode 100644 cpukit/sapi/src/fatal2.c
diff --git a/c/src/lib/libbsp/powerpc/shared/startup/panic.c b/c/src/lib/libbsp/powerpc/shared/startup/panic.c
index bff7aeb..9b0aa75 100644
--- a/c/src/lib/libbsp/powerpc/shared/startup/panic.c
+++ b/c/src/lib/libbsp/powerpc/shared/startup/panic.c
@@ -23,7 +23,6 @@ void BSP_panic(char *s)
}
#define THESRC _Internal_errors_What_happened.the_source
-#define ISITNL _Internal_errors_What_happened.is_internal
#define THEERR _Internal_errors_What_happened.the_error
void _BSP_Fatal_error(unsigned int v)
@@ -36,7 +35,6 @@ void _BSP_Fatal_error(unsigned int v)
printk("%s\n",_RTEMS_version);
printk("FATAL ERROR:\n");
- printk("Internal error: %s\n", ISITNL? "Yes":"No");
printk("Environment:");
switch (THESRC) {
case INTERNAL_ERROR_CORE:
diff --git a/cpukit/libcsupport/src/gxx_wrappers.c b/cpukit/libcsupport/src/gxx_wrappers.c
index 82f4bdb..545c3af 100644
--- a/cpukit/libcsupport/src/gxx_wrappers.c
+++ b/cpukit/libcsupport/src/gxx_wrappers.c
@@ -137,11 +137,7 @@ int rtems_gxx_setspecific(__gthread_key_t key, const void *ptr)
#endif
if ( eno != 0 ) {
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_GXX_KEY_ADD_FAILED
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_GXX_KEY_ADD_FAILED );
}
return 0;
@@ -175,11 +171,7 @@ void rtems_gxx_mutex_init (__gthread_mutex_t *mutex)
status
);
#endif
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_GXX_MUTEX_INIT_FAILED
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_GXX_MUTEX_INIT_FAILED );
}
#ifdef DEBUG_GXX_WRAPPERS
printk( "gxx_wrappers: mutex init complete =%X\n", *mutex );
diff --git a/cpukit/libcsupport/src/malloc_initialize.c b/cpukit/libcsupport/src/malloc_initialize.c
index 60fe2d9..e262c0f 100644
--- a/cpukit/libcsupport/src/malloc_initialize.c
+++ b/cpukit/libcsupport/src/malloc_initialize.c
@@ -50,11 +50,7 @@ void RTEMS_Malloc_Initialize(
}
if ( init_or_extend == _Heap_Initialize ) {
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_NO_MEMORY_FOR_HEAP
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_NO_MEMORY_FOR_HEAP );
}
}
}
diff --git a/cpukit/posix/src/pthreadinitthreads.c b/cpukit/posix/src/pthreadinitthreads.c
index ff11e8a..3cfb92d 100644
--- a/cpukit/posix/src/pthreadinitthreads.c
+++ b/cpukit/posix/src/pthreadinitthreads.c
@@ -87,7 +87,6 @@ void _POSIX_Threads_Initialize_user_threads_body(void)
if ( thread_entry == NULL ) {
_Terminate(
INTERNAL_ERROR_CORE,
- false,
INTERNAL_ERROR_POSIX_INIT_THREAD_ENTRY_IS_NULL
);
}
diff --git a/cpukit/rtems/src/taskinitusers.c b/cpukit/rtems/src/taskinitusers.c
index 81b6c04..5104639 100644
--- a/cpukit/rtems/src/taskinitusers.c
+++ b/cpukit/rtems/src/taskinitusers.c
@@ -89,13 +89,12 @@ void _RTEMS_tasks_Initialize_user_tasks_body( void )
&id
);
if ( !rtems_is_status_successful( return_value ) )
- _Terminate( INTERNAL_ERROR_RTEMS_API, true, return_value );
+ _Terminate( INTERNAL_ERROR_RTEMS_API, return_value );
entry_point = user_tasks[ index ].entry_point;
if ( entry_point == NULL ) {
_Terminate(
INTERNAL_ERROR_CORE,
- false,
INTERNAL_ERROR_RTEMS_INIT_TASK_ENTRY_IS_NULL
);
}
diff --git a/cpukit/sapi/Makefile.am b/cpukit/sapi/Makefile.am
index 4e85062..50d065b 100644
--- a/cpukit/sapi/Makefile.am
+++ b/cpukit/sapi/Makefile.am
@@ -34,7 +34,7 @@ libsapi_a_SOURCES = src/extension.c src/extensioncreate.c \
src/getversionstring.c \
src/chainappendnotify.c src/chaingetnotify.c src/chaingetwait.c \
src/chainprependnotify.c src/rbheap.c src/interrtext.c \
- src/fatal2.c src/fatalsrctext.c
+ src/fatalsrctext.c
libsapi_a_SOURCES += src/chainprotected.c
libsapi_a_SOURCES += src/cpucounterconverter.c
libsapi_a_SOURCES += src/delayticks.c
diff --git a/cpukit/sapi/include/rtems/fatal.h b/cpukit/sapi/include/rtems/fatal.h
index b4b3b0f..03cfafa 100644
--- a/cpukit/sapi/include/rtems/fatal.h
+++ b/cpukit/sapi/include/rtems/fatal.h
@@ -73,17 +73,20 @@ void rtems_fatal_error_occurred(
) RTEMS_NO_RETURN;
/**
- * @brief Invokes the internal error handler with is internal set to false.
+ * @brief Terminates the system.
*
- * @param[in] source is the fatal source.
- * @param[in] error is the fatal code.
+ * @param[in] fatal_source The fatal source.
+ * @param[in] error_code The error code.
*
* @see _Terminate().
*/
-void rtems_fatal(
- rtems_fatal_source source,
- rtems_fatal_code error
-) RTEMS_NO_RETURN;
+RTEMS_INLINE_ROUTINE void rtems_fatal(
+ rtems_fatal_source fatal_source,
+ rtems_fatal_code error_code
+)
+{
+ _Terminate( fatal_source, error_code );
+}
/**
* @brief Returns a text for a fatal source.
diff --git a/cpukit/sapi/src/exshutdown.c b/cpukit/sapi/src/exshutdown.c
index 9306eaf..4f70091 100644
--- a/cpukit/sapi/src/exshutdown.c
+++ b/cpukit/sapi/src/exshutdown.c
@@ -18,7 +18,7 @@
void rtems_shutdown_executive( uint32_t result )
{
- _Terminate( RTEMS_FATAL_SOURCE_EXIT, false, result );
+ _Terminate( RTEMS_FATAL_SOURCE_EXIT, result );
/***************************************************************
***************************************************************
diff --git a/cpukit/sapi/src/fatal.c b/cpukit/sapi/src/fatal.c
index 684e878..4a0314a 100644
--- a/cpukit/sapi/src/fatal.c
+++ b/cpukit/sapi/src/fatal.c
@@ -30,7 +30,7 @@ void rtems_fatal_error_occurred(
uint32_t the_error
)
{
- _Terminate( INTERNAL_ERROR_RTEMS_API, FALSE, the_error );
+ _Terminate( INTERNAL_ERROR_RTEMS_API, the_error );
/* will not return from this routine */
}
diff --git a/cpukit/sapi/src/fatal2.c b/cpukit/sapi/src/fatal2.c
deleted file mode 100644
index faa9cdb..0000000
--- a/cpukit/sapi/src/fatal2.c
+++ /dev/null
@@ -1,35 +0,0 @@
-/**
- * @file
- *
- * @brief Invokes the internal error handler with is internal set to false.
- *
- * @ingroup ClassicFatal
- */
-
-/*
- * Copyright (c) 2012 embedded brains GmbH. All rights reserved.
- *
- * embedded brains GmbH
- * Obere Lagerstr. 30
- * 82178 Puchheim
- * Germany
- * <rtems at embedded-brains.de>
- *
- * The license and distribution terms for this file may be
- * found in the file LICENSE in this distribution or at
- * http://www.rtems.org/license/LICENSE.
- */
-
-#if HAVE_CONFIG_H
- #include "config.h"
-#endif
-
-#include <rtems/fatal.h>
-
-void rtems_fatal(
- rtems_fatal_source source,
- rtems_fatal_code error
-)
-{
- _Terminate( source, false, error );
-}
diff --git a/cpukit/sapi/src/posixapi.c b/cpukit/sapi/src/posixapi.c
index d1de103..e7d34fd 100644
--- a/cpukit/sapi/src/posixapi.c
+++ b/cpukit/sapi/src/posixapi.c
@@ -25,5 +25,5 @@ void _POSIX_Fatal_error( POSIX_Fatal_domain domain, int eno )
{
uint32_t code = ( domain << 8 ) | ( ( uint32_t ) eno & 0xffU );
- _Terminate( INTERNAL_ERROR_POSIX_API, false, code );
+ _Terminate( INTERNAL_ERROR_POSIX_API, code );
}
diff --git a/cpukit/score/cpu/nios2/nios2-context-initialize.c b/cpukit/score/cpu/nios2/nios2-context-initialize.c
index 5313327..7468bec 100644
--- a/cpukit/score/cpu/nios2/nios2-context-initialize.c
+++ b/cpukit/score/cpu/nios2/nios2-context-initialize.c
@@ -62,7 +62,7 @@ void _CPU_Context_Initialize(
if ( !ok ) {
/* The task stack allocator must ensure that the stack area is valid */
- _Terminate( INTERNAL_ERROR_CORE, false, 0xdeadbeef );
+ _Terminate( INTERNAL_ERROR_CORE, 0xdeadbeef );
}
}
}
diff --git a/cpukit/score/cpu/nios2/nios2-isr-get-level.c b/cpukit/score/cpu/nios2/nios2-isr-get-level.c
index dad4053..9380437 100644
--- a/cpukit/score/cpu/nios2/nios2-isr-get-level.c
+++ b/cpukit/score/cpu/nios2/nios2-isr-get-level.c
@@ -48,7 +48,7 @@ uint32_t _CPU_ISR_Get_level( void )
break;
default:
/* FIXME */
- _Terminate( INTERNAL_ERROR_CORE, false, 0xdeadbeef );
+ _Terminate( INTERNAL_ERROR_CORE, 0xdeadbeef );
break;
}
diff --git a/cpukit/score/cpu/nios2/nios2-isr-set-level.c b/cpukit/score/cpu/nios2/nios2-isr-set-level.c
index 422f990..9eb8dec 100644
--- a/cpukit/score/cpu/nios2/nios2-isr-set-level.c
+++ b/cpukit/score/cpu/nios2/nios2-isr-set-level.c
@@ -48,7 +48,7 @@ uint32_t _Nios2_ISR_Set_level( uint32_t new_level, uint32_t status )
break;
default:
/* FIXME */
- _Terminate( INTERNAL_ERROR_CORE, false, 0xdeadbeef );
+ _Terminate( INTERNAL_ERROR_CORE, 0xdeadbeef );
break;
}
diff --git a/cpukit/score/cpu/powerpc/ppc-isr-vector-install.c b/cpukit/score/cpu/powerpc/ppc-isr-vector-install.c
index eab211f..7d75fd8 100644
--- a/cpukit/score/cpu/powerpc/ppc-isr-vector-install.c
+++ b/cpukit/score/cpu/powerpc/ppc-isr-vector-install.c
@@ -31,9 +31,5 @@ void _CPU_ISR_install_vector(
proc_ptr *old_handler
)
{
- _Terminate(
- INTERNAL_ERROR_CORE,
- false,
- INTERNAL_ERROR_CPU_ISR_INSTALL_VECTOR
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_CPU_ISR_INSTALL_VECTOR );
}
diff --git a/cpukit/score/include/rtems/score/interr.h b/cpukit/score/include/rtems/score/interr.h
index 0bd1eec..b030a22 100644
--- a/cpukit/score/include/rtems/score/interr.h
+++ b/cpukit/score/include/rtems/score/interr.h
@@ -182,8 +182,6 @@ typedef CPU_Uint32ptr Internal_errors_t;
typedef struct {
/** This is the source of the error. */
Internal_errors_Source the_source;
- /** This indicates if the error is internal of external. */
- bool is_internal;
/** This is the error code. */
Internal_errors_t the_error;
} Internal_errors_Information;
@@ -225,16 +223,13 @@ extern Internal_errors_Information _Internal_errors_What_happened;
*
* @param[in] the_source The fatal source indicating the subsystem the fatal
* condition originated in.
- * @param[in] is_internal Indicates if the fatal condition was generated
- * internally to the executive.
* @param[in] the_error The fatal error code. This value must be interpreted
* with respect to the source.
*
- * @see rtems_fatal_error_occurred() and rtems_fatal().
+ * @see rtems_fatal() and _Internal_error().
*/
void _Terminate(
Internal_errors_Source the_source,
- bool is_internal,
Internal_errors_t the_error
) RTEMS_NO_RETURN;
diff --git a/cpukit/score/include/rtems/score/smpimpl.h b/cpukit/score/include/rtems/score/smpimpl.h
index 7f2de5f..1651a5e 100644
--- a/cpukit/score/include/rtems/score/smpimpl.h
+++ b/cpukit/score/include/rtems/score/smpimpl.h
@@ -84,7 +84,7 @@ typedef enum {
static inline void _SMP_Fatal( SMP_Fatal_code code )
{
- _Terminate( RTEMS_FATAL_SOURCE_SMP, false, code );
+ _Terminate( RTEMS_FATAL_SOURCE_SMP, code );
}
/**
diff --git a/cpukit/score/include/rtems/score/userext.h b/cpukit/score/include/rtems/score/userext.h
index e626f2f..61de992 100644
--- a/cpukit/score/include/rtems/score/userext.h
+++ b/cpukit/score/include/rtems/score/userext.h
@@ -195,8 +195,8 @@ typedef void( *User_extensions_thread_exitted_extension )(
*
* @param[in] source The fatal source indicating the subsystem the fatal
* condition originated in.
- * @param[in] is_internal Indicates if the fatal condition was generated
- * internally to the executive.
+ * @param[in] is_internal This parameter is always false and provide only for
+ * backward compatibility reasons.
* @param[in] code The fatal error code. This value must be interpreted with
* respect to the source.
*/
diff --git a/cpukit/score/include/rtems/score/userextimpl.h b/cpukit/score/include/rtems/score/userextimpl.h
index e6692c8..6684c4a 100644
--- a/cpukit/score/include/rtems/score/userextimpl.h
+++ b/cpukit/score/include/rtems/score/userextimpl.h
@@ -166,7 +166,6 @@ void _User_extensions_Thread_exitted_visitor(
typedef struct {
Internal_errors_Source source;
- bool is_internal;
Internal_errors_t error;
} User_extensions_Fatal_context;
@@ -300,11 +299,10 @@ static inline void _User_extensions_Thread_exitted( Thread_Control *executing )
static inline void _User_extensions_Fatal(
Internal_errors_Source source,
- bool is_internal,
Internal_errors_t error
)
{
- User_extensions_Fatal_context ctx = { source, is_internal, error };
+ User_extensions_Fatal_context ctx = { source, error };
_User_extensions_Iterate(
&ctx,
diff --git a/cpukit/score/src/heap.c b/cpukit/score/src/heap.c
index 3fddb1a..402f631 100644
--- a/cpukit/score/src/heap.c
+++ b/cpukit/score/src/heap.c
@@ -157,7 +157,7 @@
)
{
/* FIXME */
- _Terminate( INTERNAL_ERROR_CORE, false, 0xdeadbeef );
+ _Terminate( INTERNAL_ERROR_CORE, 0xdeadbeef );
}
#endif
diff --git a/cpukit/score/src/interr.c b/cpukit/score/src/interr.c
index 8740027..5993eb9 100644
--- a/cpukit/score/src/interr.c
+++ b/cpukit/score/src/interr.c
@@ -28,16 +28,14 @@ System_state_Codes _System_state_Current;
Internal_errors_Information _Internal_errors_What_happened;
void _Terminate(
- Internal_errors_Source the_source,
- bool is_internal,
- Internal_errors_t the_error
+ Internal_errors_Source the_source,
+ Internal_errors_t the_error
)
{
- _User_extensions_Fatal( the_source, is_internal, the_error );
+ _User_extensions_Fatal( the_source, the_error );
- _Internal_errors_What_happened.the_source = the_source;
- _Internal_errors_What_happened.is_internal = is_internal;
- _Internal_errors_What_happened.the_error = the_error;
+ _Internal_errors_What_happened.the_source = the_source;
+ _Internal_errors_What_happened.the_error = the_error;
_System_state_Set( SYSTEM_STATE_TERMINATED );
diff --git a/cpukit/score/src/isr.c b/cpukit/score/src/isr.c
index 1ae6e59..aaa0513 100644
--- a/cpukit/score/src/isr.c
+++ b/cpukit/score/src/isr.c
@@ -51,7 +51,6 @@ void _ISR_Handler_initialization( void )
if ( !_Stack_Is_enough( stack_size ) )
_Terminate(
INTERNAL_ERROR_CORE,
- true,
INTERNAL_ERROR_INTERRUPT_STACK_TOO_SMALL
);
diff --git a/cpukit/score/src/mpci.c b/cpukit/score/src/mpci.c
index 2f0a2de..e495eb4 100644
--- a/cpukit/score/src/mpci.c
+++ b/cpukit/score/src/mpci.c
@@ -95,11 +95,7 @@ static void _MPCI_Handler_initialization( void )
users_mpci_table = _Configuration_MP_table->User_mpci_table;
if ( _System_state_Is_multiprocessing && !users_mpci_table )
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_NO_MPCI
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_NO_MPCI );
_MPCI_table = users_mpci_table;
@@ -191,11 +187,7 @@ MP_packet_Prefix *_MPCI_Get_packet ( void )
(*_MPCI_table->get_packet)( &the_packet );
if ( the_packet == NULL )
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_OUT_OF_PACKETS
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_OUT_OF_PACKETS );
/*
* Put in a default timeout that will be used for
@@ -375,11 +367,7 @@ void _MPCI_Receive_server(
the_function = _MPCI_Packet_processors[ the_packet->the_class ];
if ( !the_function )
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_BAD_PACKET
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_BAD_PACKET );
(*the_function)( the_packet );
}
@@ -463,7 +451,6 @@ void _MPCI_Internal_packets_Process_packet (
_Terminate(
INTERNAL_ERROR_CORE,
- true,
INTERNAL_ERROR_INCONSISTENT_MP_INFORMATION
);
}
diff --git a/cpukit/score/src/objectinitializeinformation.c b/cpukit/score/src/objectinitializeinformation.c
index dc8a106..92a561a 100644
--- a/cpukit/score/src/objectinitializeinformation.c
+++ b/cpukit/score/src/objectinitializeinformation.c
@@ -76,7 +76,6 @@ void _Objects_Do_initialize_information(
if ( information->auto_extend && maximum_per_allocation == 0) {
_Terminate(
INTERNAL_ERROR_CORE,
- true,
INTERNAL_ERROR_UNLIMITED_AND_MAXIMUM_IS_0
);
}
diff --git a/cpukit/score/src/objectmp.c b/cpukit/score/src/objectmp.c
index b97a9d5..4e6a838 100644
--- a/cpukit/score/src/objectmp.c
+++ b/cpukit/score/src/objectmp.c
@@ -165,11 +165,7 @@ void _Objects_MP_Handler_early_initialization(void)
maximum_nodes = _Configuration_MP_table->maximum_nodes;
if ( node < 1 || node > maximum_nodes )
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_INVALID_NODE
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_INVALID_NODE );
_Objects_Local_node = node;
_Objects_Maximum_nodes = maximum_nodes;
@@ -246,12 +242,7 @@ bool _Objects_MP_Allocate_and_open (
if ( is_fatal_error == false )
return false;
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_OUT_OF_GLOBAL_OBJECTS
- );
-
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_OUT_OF_GLOBAL_OBJECTS );
}
_Objects_MP_Open( information, the_global_object, the_name, the_id );
@@ -291,11 +282,7 @@ void _Objects_MP_Close (
} else {
_Objects_MP_Global_release( &lock_context );
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_INVALID_GLOBAL_ID
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_INVALID_GLOBAL_ID );
}
}
diff --git a/cpukit/score/src/thread.c b/cpukit/score/src/thread.c
index a0ba61d..1fcc639 100644
--- a/cpukit/score/src/thread.c
+++ b/cpukit/score/src/thread.c
@@ -84,11 +84,7 @@ void _Thread_Handler_initialization(void)
if ( rtems_configuration_get_stack_allocate_hook() == NULL ||
rtems_configuration_get_stack_free_hook() == NULL)
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_BAD_STACK_HOOK
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_BAD_STACK_HOOK );
if ( stack_allocate_init_hook != NULL )
(*stack_allocate_init_hook)( rtems_configuration_get_stack_space_size() );
diff --git a/cpukit/score/src/threaddispatch.c b/cpukit/score/src/threaddispatch.c
index 4f89475..6bce046 100644
--- a/cpukit/score/src/threaddispatch.c
+++ b/cpukit/score/src/threaddispatch.c
@@ -156,7 +156,6 @@ void _Thread_Do_dispatch( Per_CPU_Control *cpu_self, ISR_Level level )
) {
_Terminate(
INTERNAL_ERROR_CORE,
- false,
INTERNAL_ERROR_BAD_THREAD_DISPATCH_ENVIRONMENT
);
}
@@ -241,7 +240,6 @@ void _Thread_Dispatch_direct( Per_CPU_Control *cpu_self )
if ( cpu_self->thread_dispatch_disable_level != 1 ) {
_Terminate(
INTERNAL_ERROR_CORE,
- 0,
INTERNAL_ERROR_BAD_THREAD_DISPATCH_DISABLE_LEVEL
);
}
diff --git a/cpukit/score/src/threadhandler.c b/cpukit/score/src/threadhandler.c
index a8d6580..721dcf4 100644
--- a/cpukit/score/src/threadhandler.c
+++ b/cpukit/score/src/threadhandler.c
@@ -96,9 +96,5 @@ void _Thread_Handler( void )
_User_extensions_Thread_exitted( executing );
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_THREAD_EXITTED
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_THREAD_EXITTED );
}
diff --git a/cpukit/score/src/threadmp.c b/cpukit/score/src/threadmp.c
index 22078a7..59f393f 100644
--- a/cpukit/score/src/threadmp.c
+++ b/cpukit/score/src/threadmp.c
@@ -173,11 +173,7 @@ Thread_Control *_Thread_MP_Allocate_proxy (
_Thread_MP_Proxies_release( &lock_context );
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_OUT_OF_PROXIES
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_OUT_OF_PROXIES );
/*
* NOTE: The following return ensures that the compiler will
diff --git a/cpukit/score/src/threadqenqueue.c b/cpukit/score/src/threadqenqueue.c
index cea1886..a96fbfc 100644
--- a/cpukit/score/src/threadqenqueue.c
+++ b/cpukit/score/src/threadqenqueue.c
@@ -372,11 +372,7 @@ void _Thread_queue_Deadlock_status( Thread_Control *the_thread )
void _Thread_queue_Deadlock_fatal( Thread_Control *the_thread )
{
- _Terminate(
- INTERNAL_ERROR_CORE,
- false,
- INTERNAL_ERROR_THREAD_QUEUE_DEADLOCK
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_THREAD_QUEUE_DEADLOCK );
}
static void _Thread_queue_Timeout(
@@ -525,7 +521,6 @@ Status_Control _Thread_queue_Enqueue_sticky(
if ( cpu_self->thread_dispatch_disable_level != 1 ) {
_Terminate(
INTERNAL_ERROR_CORE,
- false,
INTERNAL_ERROR_THREAD_QUEUE_ENQUEUE_STICKY_FROM_BAD_STATE
);
}
diff --git a/cpukit/score/src/threadrestart.c b/cpukit/score/src/threadrestart.c
index 54491d8..4295bc4 100644
--- a/cpukit/score/src/threadrestart.c
+++ b/cpukit/score/src/threadrestart.c
@@ -136,11 +136,7 @@ static void _Thread_Make_zombie( Thread_Control *the_thread )
{
#if defined(RTEMS_SCORE_THREAD_ENABLE_RESOURCE_COUNT)
if ( _Thread_Owns_resources( the_thread ) ) {
- _Terminate(
- INTERNAL_ERROR_CORE,
- false,
- INTERNAL_ERROR_RESOURCE_IN_USE
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_RESOURCE_IN_USE );
}
#endif
diff --git a/cpukit/score/src/userextiterate.c b/cpukit/score/src/userextiterate.c
index 6cb8774..6e14376 100644
--- a/cpukit/score/src/userextiterate.c
+++ b/cpukit/score/src/userextiterate.c
@@ -129,7 +129,7 @@ void _User_extensions_Fatal_visitor(
if ( callout != NULL ) {
const User_extensions_Fatal_context *ctx = arg;
- (*callout)( ctx->source, ctx->is_internal, ctx->error );
+ (*callout)( ctx->source, false, ctx->error );
}
}
diff --git a/cpukit/score/src/wkspace.c b/cpukit/score/src/wkspace.c
index b53138d..ae48e44 100644
--- a/cpukit/score/src/wkspace.c
+++ b/cpukit/score/src/wkspace.c
@@ -134,11 +134,7 @@ void _Workspace_Handler_initialization(
}
if ( remaining > 0 ) {
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_TOO_LITTLE_WORKSPACE
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_TOO_LITTLE_WORKSPACE );
}
_Heap_Protection_set_delayed_free_fraction( &_Workspace_Area, 1 );
@@ -204,11 +200,7 @@ void *_Workspace_Allocate_or_fatal_error(
#endif
if ( memory == NULL )
- _Terminate(
- INTERNAL_ERROR_CORE,
- true,
- INTERNAL_ERROR_WORKSPACE_ALLOCATION
- );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_WORKSPACE_ALLOCATION );
return memory;
}
diff --git a/testsuites/libtests/devnullfatal01/testcase.h b/testsuites/libtests/devnullfatal01/testcase.h
index 14675da..1060d50 100644
--- a/testsuites/libtests/devnullfatal01/testcase.h
+++ b/testsuites/libtests/devnullfatal01/testcase.h
@@ -10,7 +10,6 @@
#define FATAL_ERROR_TEST_NAME "/DEV/NULL 1"
#define FATAL_ERROR_DESCRIPTION "/dev/null already registered"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_TOO_MANY
#define TESTS_USE_PRINTK
diff --git a/testsuites/psxtests/psxfatal01/testcase.h b/testsuites/psxtests/psxfatal01/testcase.h
index b400fa6..a88ef48 100644
--- a/testsuites/psxtests/psxfatal01/testcase.h
+++ b/testsuites/psxtests/psxfatal01/testcase.h
@@ -28,7 +28,6 @@ posix_initialization_threads_table POSIX_Initialization_threads[] = {
#define FATAL_ERROR_DESCRIPTION \
"POSIX API Init thread create failure - NULL entry"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR \
INTERNAL_ERROR_POSIX_INIT_THREAD_ENTRY_IS_NULL
diff --git a/testsuites/psxtests/psxfatal02/testcase.h b/testsuites/psxtests/psxfatal02/testcase.h
index 7c10715..facf731 100644
--- a/testsuites/psxtests/psxfatal02/testcase.h
+++ b/testsuites/psxtests/psxfatal02/testcase.h
@@ -33,7 +33,6 @@ posix_initialization_threads_table POSIX_Initialization_threads[] = {
#define FATAL_ERROR_DESCRIPTION \
"POSIX API Init thread create failure -- no memory for stack"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_POSIX_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR ((POSIX_FD_PTHREAD << 8) | EAGAIN)
void force_error(void)
diff --git a/testsuites/psxtests/psxfatal_support/init.c b/testsuites/psxtests/psxfatal_support/init.c
index 0f995dc..bc48b95 100644
--- a/testsuites/psxtests/psxfatal_support/init.c
+++ b/testsuites/psxtests/psxfatal_support/init.c
@@ -77,13 +77,8 @@ void Fatal_extension(
printk( ")\n" );
}
- if ( is_internal != FATAL_ERROR_EXPECTED_IS_INTERNAL )
- {
- if ( is_internal == TRUE )
- printk( "ERROR==> Fatal Extension is internal set to TRUE expected FALSE\n" );
- else
- printk( "ERROR==> Fatal Extension is internal set to FALSE expected TRUE\n" );
- }
+ if ( is_internal )
+ printk( "ERROR==> Fatal Extension is internal set to true expected false\n" );
if ( error != FATAL_ERROR_EXPECTED_ERROR ) {
printk( "ERROR==> Fatal Error Expected (");
@@ -95,7 +90,7 @@ void Fatal_extension(
if (
source == FATAL_ERROR_EXPECTED_SOURCE
- && is_internal == FATAL_ERROR_EXPECTED_IS_INTERNAL
+ && !is_internal
&& error == FATAL_ERROR_EXPECTED_ERROR
) {
TEST_END();
diff --git a/testsuites/sptests/spfatal01/testcase.h b/testsuites/sptests/spfatal01/testcase.h
index 9ac322a..01710dc 100644
--- a/testsuites/sptests/spfatal01/testcase.h
+++ b/testsuites/sptests/spfatal01/testcase.h
@@ -25,7 +25,6 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_TEST_NAME "1"
#define FATAL_ERROR_DESCRIPTION "Classic API Init task create failure"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_UNSATISFIED
void force_error()
diff --git a/testsuites/sptests/spfatal02/testcase.h b/testsuites/sptests/spfatal02/testcase.h
index bd9ac67..8ed2f44 100644
--- a/testsuites/sptests/spfatal02/testcase.h
+++ b/testsuites/sptests/spfatal02/testcase.h
@@ -25,7 +25,6 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_TEST_NAME "2"
#define FATAL_ERROR_DESCRIPTION "Classic API Init task start failure"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR \
INTERNAL_ERROR_RTEMS_INIT_TASK_ENTRY_IS_NULL
diff --git a/testsuites/sptests/spfatal03/testcase.h b/testsuites/sptests/spfatal03/testcase.h
index 7b98cc3..90ed053 100644
--- a/testsuites/sptests/spfatal03/testcase.h
+++ b/testsuites/sptests/spfatal03/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_TEST_NAME "3"
#define FATAL_ERROR_DESCRIPTION "Core Mutex obtain in critical section"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR \
INTERNAL_ERROR_BAD_THREAD_DISPATCH_DISABLE_LEVEL
diff --git a/testsuites/sptests/spfatal04/testcase.h b/testsuites/sptests/spfatal04/testcase.h
index 98429b4..323a777 100644
--- a/testsuites/sptests/spfatal04/testcase.h
+++ b/testsuites/sptests/spfatal04/testcase.h
@@ -26,7 +26,6 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_DESCRIPTION \
"Classic API call rtems_fatal_error_occurred"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR 0xdead
void force_error()
diff --git a/testsuites/sptests/spfatal05/testcase.h b/testsuites/sptests/spfatal05/testcase.h
index 8900aef..933b7a5 100644
--- a/testsuites/sptests/spfatal05/testcase.h
+++ b/testsuites/sptests/spfatal05/testcase.h
@@ -34,7 +34,6 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_TEST_NAME "5"
#define FATAL_ERROR_DESCRIPTION "Core fall out of a task"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_THREAD_EXITTED
rtems_task EmptyTask( rtems_task_argument unused );
diff --git a/testsuites/sptests/spfatal06/testcase.h b/testsuites/sptests/spfatal06/testcase.h
index db823da..8ec1627 100644
--- a/testsuites/sptests/spfatal06/testcase.h
+++ b/testsuites/sptests/spfatal06/testcase.h
@@ -33,7 +33,6 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_DESCRIPTION \
"Core initialize with invalid stack hook"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_BAD_STACK_HOOK
void *New_stack_allocate_hook(size_t unused);
diff --git a/testsuites/sptests/spfatal07/testcase.h b/testsuites/sptests/spfatal07/testcase.h
index 7cc9a5f..4db2cf1 100644
--- a/testsuites/sptests/spfatal07/testcase.h
+++ b/testsuites/sptests/spfatal07/testcase.h
@@ -33,7 +33,6 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_DESCRIPTION \
"Core Configuration Invalid ISR stack size"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR \
INTERNAL_ERROR_INTERRUPT_STACK_TOO_SMALL
diff --git a/testsuites/sptests/spfatal08/testcase.h b/testsuites/sptests/spfatal08/testcase.h
index 12c8d4e..03e7ca5 100644
--- a/testsuites/sptests/spfatal08/testcase.h
+++ b/testsuites/sptests/spfatal08/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_TEST_NAME "8"
#define FATAL_ERROR_DESCRIPTION "Core workspace too small"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_WORKSPACE_ALLOCATION
void force_error()
diff --git a/testsuites/sptests/spfatal09/testcase.h b/testsuites/sptests/spfatal09/testcase.h
index 7e9b10f..07b03af 100644
--- a/testsuites/sptests/spfatal09/testcase.h
+++ b/testsuites/sptests/spfatal09/testcase.h
@@ -15,7 +15,6 @@
#define FATAL_ERROR_TEST_NAME "9"
#define FATAL_ERROR_DESCRIPTION "Bad heap address to malloc"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_NO_MEMORY_FOR_HEAP
void force_error()
diff --git a/testsuites/sptests/spfatal10/testcase.h b/testsuites/sptests/spfatal10/testcase.h
index ae1e99e..df4125e 100644
--- a/testsuites/sptests/spfatal10/testcase.h
+++ b/testsuites/sptests/spfatal10/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_TEST_NAME "10"
#define FATAL_ERROR_DESCRIPTION "asserting with non-NULL strings..."
#define FATAL_ERROR_EXPECTED_SOURCE RTEMS_FATAL_SOURCE_ASSERT
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR_CHECK spfatal10_is_expected_error
#define ASSERT_FILE "testcase.h"
diff --git a/testsuites/sptests/spfatal11/testcase.h b/testsuites/sptests/spfatal11/testcase.h
index 3efa7e5..ddd37a6 100644
--- a/testsuites/sptests/spfatal11/testcase.h
+++ b/testsuites/sptests/spfatal11/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_TEST_NAME "11"
#define FATAL_ERROR_DESCRIPTION "asserting with NULL strings..."
#define FATAL_ERROR_EXPECTED_SOURCE RTEMS_FATAL_SOURCE_ASSERT
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR_CHECK spfatal11_is_expected_error
#define ASSERT_FILE "testcase.h"
diff --git a/testsuites/sptests/spfatal12/testcase.h b/testsuites/sptests/spfatal12/testcase.h
index 0aac3b1..8b3d409 100644
--- a/testsuites/sptests/spfatal12/testcase.h
+++ b/testsuites/sptests/spfatal12/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_DESCRIPTION \
"_Heap_Initialize fails during RTEMS initialization"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_TOO_LITTLE_WORKSPACE
void force_error()
diff --git a/testsuites/sptests/spfatal13/testcase.h b/testsuites/sptests/spfatal13/testcase.h
index b99ff4d..6f82689 100644
--- a/testsuites/sptests/spfatal13/testcase.h
+++ b/testsuites/sptests/spfatal13/testcase.h
@@ -12,7 +12,6 @@
#define FATAL_ERROR_DESCRIPTION \
"Configuration of unlimited and maximum of 0"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_UNLIMITED_AND_MAXIMUM_IS_0
/*
diff --git a/testsuites/sptests/spfatal14/testcase.h b/testsuites/sptests/spfatal14/testcase.h
index 4aded0a..3dcd030 100644
--- a/testsuites/sptests/spfatal14/testcase.h
+++ b/testsuites/sptests/spfatal14/testcase.h
@@ -12,7 +12,6 @@
#define FATAL_ERROR_TEST_NAME "14"
#define FATAL_ERROR_DESCRIPTION "fail to open stdout"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR 0x55544431
#define CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS 1
diff --git a/testsuites/sptests/spfatal15/testcase.h b/testsuites/sptests/spfatal15/testcase.h
index d1527fd..742b5b9 100644
--- a/testsuites/sptests/spfatal15/testcase.h
+++ b/testsuites/sptests/spfatal15/testcase.h
@@ -11,7 +11,6 @@
#define FATAL_ERROR_TEST_NAME "15"
#define FATAL_ERROR_DESCRIPTION "fail to open stderr"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR 0x55544432
#define CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS 2
diff --git a/testsuites/sptests/spfatal16/testcase.h b/testsuites/sptests/spfatal16/testcase.h
index 743b2be..412f20e 100644
--- a/testsuites/sptests/spfatal16/testcase.h
+++ b/testsuites/sptests/spfatal16/testcase.h
@@ -16,7 +16,6 @@
#define FATAL_ERROR_TEST_NAME "16"
#define FATAL_ERROR_DESCRIPTION "termios sem create #1"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_TOO_MANY
#define CONFIGURE_APPLICATION_PREREQUISITE_DRIVERS \
diff --git a/testsuites/sptests/spfatal17/testcase.h b/testsuites/sptests/spfatal17/testcase.h
index 78f1b40..2f1046a 100644
--- a/testsuites/sptests/spfatal17/testcase.h
+++ b/testsuites/sptests/spfatal17/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_TEST_NAME "17"
#define FATAL_ERROR_DESCRIPTION "termios sem create #2"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_TOO_MANY
#define CONFIGURE_APPLICATION_PREREQUISITE_DRIVERS \
diff --git a/testsuites/sptests/spfatal18/testcase.h b/testsuites/sptests/spfatal18/testcase.h
index cb42543..eab617c 100644
--- a/testsuites/sptests/spfatal18/testcase.h
+++ b/testsuites/sptests/spfatal18/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_TEST_NAME "18"
#define FATAL_ERROR_DESCRIPTION "termios sem create #3"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_TOO_MANY
#define CONFIGURE_APPLICATION_PREREQUISITE_DRIVERS \
diff --git a/testsuites/sptests/spfatal19/testcase.h b/testsuites/sptests/spfatal19/testcase.h
index daa53b9..16ef09d 100644
--- a/testsuites/sptests/spfatal19/testcase.h
+++ b/testsuites/sptests/spfatal19/testcase.h
@@ -14,7 +14,6 @@
#define FATAL_ERROR_TEST_NAME "19"
#define FATAL_ERROR_DESCRIPTION "termios sem create #4"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_TOO_MANY
#define CONFIGURE_APPLICATION_PREREQUISITE_DRIVERS \
diff --git a/testsuites/sptests/spfatal20/testcase.h b/testsuites/sptests/spfatal20/testcase.h
index 1000f8f..863982a 100644
--- a/testsuites/sptests/spfatal20/testcase.h
+++ b/testsuites/sptests/spfatal20/testcase.h
@@ -11,7 +11,6 @@
#define FATAL_ERROR_DESCRIPTION \
"rtems_termios_initialize cannot create semaphore"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_TOO_MANY
#define CONFIGURE_APPLICATION_PREREQUISITE_DRIVERS \
diff --git a/testsuites/sptests/spfatal24/testcase.h b/testsuites/sptests/spfatal24/testcase.h
index 87cbe53..19a7547 100644
--- a/testsuites/sptests/spfatal24/testcase.h
+++ b/testsuites/sptests/spfatal24/testcase.h
@@ -13,7 +13,6 @@
#define FATAL_ERROR_TEST_NAME "GXX KEY ADD FAILURE"
#define FATAL_ERROR_DESCRIPTION "GXX KEY ADD FAILURE"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_GXX_KEY_ADD_FAILED
void force_error()
diff --git a/testsuites/sptests/spfatal25/testcase.h b/testsuites/sptests/spfatal25/testcase.h
index fb800bf..c2c97e4 100644
--- a/testsuites/sptests/spfatal25/testcase.h
+++ b/testsuites/sptests/spfatal25/testcase.h
@@ -12,7 +12,6 @@
#define FATAL_ERROR_TEST_NAME "GXX MUTEX INIT FAILED"
#define FATAL_ERROR_DESCRIPTION "GXX MUTEX INIT FAILED"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_GXX_MUTEX_INIT_FAILED
void force_error()
diff --git a/testsuites/sptests/spfatal27/testcase.h b/testsuites/sptests/spfatal27/testcase.h
index 29ef327..a7b26bd 100644
--- a/testsuites/sptests/spfatal27/testcase.h
+++ b/testsuites/sptests/spfatal27/testcase.h
@@ -15,7 +15,6 @@
#define FATAL_ERROR_TEST_NAME "27"
#define FATAL_ERROR_DESCRIPTION "libio init no posix key left"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_RTEMS_API
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR RTEMS_UNSATISFIED
#define CONFIGURE_MAXIMUM_POSIX_KEYS (-1)
diff --git a/testsuites/sptests/spfatal28/testcase.h b/testsuites/sptests/spfatal28/testcase.h
index 9741760..fda4122 100644
--- a/testsuites/sptests/spfatal28/testcase.h
+++ b/testsuites/sptests/spfatal28/testcase.h
@@ -15,7 +15,6 @@
#define FATAL_ERROR_TEST_NAME "28"
#define FATAL_ERROR_DESCRIPTION "delete a task with a semaphore in use"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_RESOURCE_IN_USE
#define CONFIGURE_MAXIMUM_SEMAPHORES 1
@@ -38,6 +37,6 @@ void force_error()
sc = rtems_task_delete(RTEMS_SELF);
rtems_test_assert(sc == RTEMS_SUCCESSFUL);
#else
- _Terminate( INTERNAL_ERROR_CORE, false, INTERNAL_ERROR_RESOURCE_IN_USE );
+ _Terminate( INTERNAL_ERROR_CORE, INTERNAL_ERROR_RESOURCE_IN_USE );
#endif
}
diff --git a/testsuites/sptests/spfatal29/testcase.h b/testsuites/sptests/spfatal29/testcase.h
index 096a66a..63f74f8 100644
--- a/testsuites/sptests/spfatal29/testcase.h
+++ b/testsuites/sptests/spfatal29/testcase.h
@@ -15,7 +15,6 @@
#define FATAL_ERROR_TEST_NAME "29"
#define FATAL_ERROR_DESCRIPTION "yield in interrupt context"
#define FATAL_ERROR_EXPECTED_SOURCE INTERNAL_ERROR_CORE
-#define FATAL_ERROR_EXPECTED_IS_INTERNAL FALSE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_BAD_THREAD_DISPATCH_DISABLE_LEVEL
#define CONFIGURE_MAXIMUM_TIMERS 1
diff --git a/testsuites/sptests/spfatal_support/init.c b/testsuites/sptests/spfatal_support/init.c
index 319dbd2..aa49a30 100644
--- a/testsuites/sptests/spfatal_support/init.c
+++ b/testsuites/sptests/spfatal_support/init.c
@@ -80,17 +80,10 @@ void Fatal_extension(
printk( ")\n" );
}
- if ( is_internal != FATAL_ERROR_EXPECTED_IS_INTERNAL )
- {
- if ( is_internal == TRUE )
- printk(
- "ERROR==> Fatal Extension is internal set to TRUE expected FALSE\n"
- );
- else
- printk(
- "ERROR==> Fatal Extension is internal set to FALSE expected TRUE\n"
- );
- }
+ if ( is_internal )
+ printk(
+ "ERROR==> Fatal Extension is internal set to true expected false\n"
+ );
#ifdef FATAL_ERROR_EXPECTED_ERROR
if ( error != FATAL_ERROR_EXPECTED_ERROR ) {
@@ -104,7 +97,7 @@ void Fatal_extension(
if (
source == FATAL_ERROR_EXPECTED_SOURCE
- && is_internal == FATAL_ERROR_EXPECTED_IS_INTERNAL
+ && !is_internal
&& is_expected_error( error )
) {
TEST_END();
diff --git a/testsuites/sptests/spinternalerror01/init.c b/testsuites/sptests/spinternalerror01/init.c
index e864db1..6201aff 100644
--- a/testsuites/sptests/spinternalerror01/init.c
+++ b/testsuites/sptests/spinternalerror01/init.c
@@ -26,13 +26,11 @@ const char rtems_test_name[] = "SPINTERNALERROR 1";
#define FATAL_SOURCE 0xdeadbeef
-#define FATAL_IS_INTERNAL false
-
#define FATAL_ERROR 0x600df00d
void boot_card( const char *cmdline )
{
- _Terminate( FATAL_SOURCE, FATAL_IS_INTERNAL, FATAL_ERROR );
+ _Terminate( FATAL_SOURCE, FATAL_ERROR );
}
static void fatal_extension(
@@ -43,11 +41,7 @@ static void fatal_extension(
{
TEST_BEGIN();
- if (
- source == FATAL_SOURCE
- && is_internal == FATAL_IS_INTERNAL
- && error == FATAL_ERROR
- ) {
+ if ( source == FATAL_SOURCE && !is_internal && error == FATAL_ERROR ) {
TEST_END();
}
}
diff --git a/testsuites/sptests/sptimecounter01/init.c b/testsuites/sptests/sptimecounter01/init.c
index 9e396de..179590d 100644
--- a/testsuites/sptests/sptimecounter01/init.c
+++ b/testsuites/sptests/sptimecounter01/init.c
@@ -151,7 +151,7 @@ void boot_card(const char *cmdline)
TEST_END();
- _Terminate(RTEMS_FATAL_SOURCE_EXIT, false, 0);
+ _Terminate(RTEMS_FATAL_SOURCE_EXIT, 0);
}
#define CONFIGURE_APPLICATION_DOES_NOT_NEED_CLOCK_DRIVER
--
1.8.4.5
More information about the devel
mailing list