[RTEMS Project] #2477: Remove <rtems/debug.h>
RTEMS trac
trac at rtems.org
Wed Nov 25 08:30:22 UTC 2015
#2477: Remove <rtems/debug.h>
-----------------------------+------------------
Reporter: sebastian.huber | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: 4.12
Component: General | Version: 4.12
Severity: normal | Keywords:
-----------------------------+------------------
RTEMS has an API for dynamic debug support in <rtems/debug.h>. This
feature is sparely used:
{{{
cpukit/sapi/src/debug.c: rtems_debug_disable( RTEMS_DEBUG_ALL_MASK );
cpukit/sapi/src/debug.c:void rtems_debug_enable (
cpukit/sapi/src/debug.c: rtems_debug_control to_be_enabled
cpukit/sapi/src/debug.c:void rtems_debug_disable (
cpukit/sapi/src/debug.c: rtems_debug_control to_be_disabled
cpukit/sapi/src/debug.c:bool rtems_debug_is_enabled(
cpukit/sapi/src/debug.c: rtems_debug_control level
cpukit/rtems/include/rtems/rtems/regionimpl.h: if (
rtems_debug_is_enabled( RTEMS_DEBUG_REGION ) ) \
cpukit/score/include/rtems/debug.h:typedef uint32_t rtems_debug_control;
cpukit/score/include/rtems/debug.h:SCORE_EXTERN rtems_debug_control
_Debug_Level;
cpukit/score/include/rtems/debug.h:void rtems_debug_enable(
cpukit/score/include/rtems/debug.h: rtems_debug_control to_be_enabled
cpukit/score/include/rtems/debug.h:void rtems_debug_disable(
cpukit/score/include/rtems/debug.h: rtems_debug_control to_be_disabled
cpukit/score/include/rtems/debug.h:bool rtems_debug_is_enabled(
cpukit/score/include/rtems/debug.h: rtems_debug_control level
c/src/lib/libbsp/shared/bootcard.c: * - rtems_debug_enable(
RTEMS_DEBUG_ALL_MASK );
c/src/lib/libbsp/shared/bootcard.c: rtems_debug_enable(
RTEMS_DEBUG_ALL_MASK );
c/src/lib/libbsp/shared/include/bootcard.h: * - rtems_debug_enable(
RTEMS_DEBUG_ALL_MASK )
testsuites/sptests/spregion_err01/init.c: puts( "TA1 -
rtems_debug_disable - RTEMS_DEBUG_REGION" );
testsuites/sptests/spregion_err01/init.c: rtems_debug_disable(
RTEMS_DEBUG_REGION );
testsuites/sptests/spregion_err01/init.c: puts( "TA1 - rtems_debug_enable
- RTEMS_DEBUG_REGION" );
testsuites/sptests/spregion_err01/init.c: rtems_debug_enable(
RTEMS_DEBUG_REGION );
testsuites/sptests/sp10/init.c: puts( "Init - rtems_debug_is_enabled - is
0x1 set? No" );
testsuites/sptests/sp10/init.c: is_set = rtems_debug_is_enabled( 0x1 );
testsuites/sptests/sp10/init.c: puts( "Init - rtems_debug_enable - set
0x1" );
testsuites/sptests/sp10/init.c: rtems_debug_enable(0x1);
testsuites/sptests/sp10/init.c: puts( "Init - rtems_debug_is_enabled - is
0x1 set? Yes" );
testsuites/sptests/sp10/init.c: is_set = rtems_debug_is_enabled( 0x1 );
testsuites/sptests/sp10/init.c: puts( "Init - rtems_debug_disable - clear
0x1" );
testsuites/sptests/sp10/init.c: rtems_debug_disable(0x1);
testsuites/sptests/sp10/init.c: puts( "Init - rtems_debug_is_enabled - is
0x1 set? No" );
testsuites/sptests/sp10/init.c: is_set = rtems_debug_is_enabled( 0x1 );
}}}
The only user is the Classic Region and it is only active in case
RTEMS_DEBUG is defined. Due to the heap protection support which is also
available in case RTEMS_DEBUG is defined, the expensive heap walks are
superfluous.
We should remove this API entirely to simplify the code base.
--
Ticket URL: <http://devel.rtems.org/ticket/2477>
RTEMS Project <http://www.rtems.org/>
RTEMS Project
More information about the bugs
mailing list