aboutsummaryrefslogtreecommitdiffstats
path: root/test/rt
diff options
context:
space:
mode:
authorGiovanni Di Sirio <gdisirio@gmail.com>2016-04-03 09:27:34 +0000
committerGiovanni Di Sirio <gdisirio@gmail.com>2016-04-03 09:27:34 +0000
commit88fc433e5dfc3ddc3948d27b78be2e531113fa1e (patch)
treec271cde02df11bbd992e59a58c28ad3adfbecd81 /test/rt
parenta5156a2f8fa55401d16405acfb51dc8b6999b484 (diff)
downloadChibiOS-88fc433e5dfc3ddc3948d27b78be2e531113fa1e.tar.gz
ChibiOS-88fc433e5dfc3ddc3948d27b78be2e531113fa1e.tar.bz2
ChibiOS-88fc433e5dfc3ddc3948d27b78be2e531113fa1e.zip
MISRA-related fixes.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@9229 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'test/rt')
-rw-r--r--test/rt/testbuild/chconf.h68
1 files changed, 68 insertions, 0 deletions
diff --git a/test/rt/testbuild/chconf.h b/test/rt/testbuild/chconf.h
index 8d5d2cd21..091c93e7c 100644
--- a/test/rt/testbuild/chconf.h
+++ b/test/rt/testbuild/chconf.h
@@ -41,14 +41,18 @@
* @brief System time counter resolution.
* @note Allowed values are 16 or 32 bits.
*/
+#if !defined(CH_CFG_ST_RESOLUTION) || defined(__DOXIGEN__)
#define CH_CFG_ST_RESOLUTION 32
+#endif
/**
* @brief System tick frequency.
* @details Frequency of the system timer that drives the system ticks. This
* setting also defines the system tick time unit.
*/
+#if !defined(CH_CFG_ST_FREQUENCY) || defined(__DOXIGEN__)
#define CH_CFG_ST_FREQUENCY 1000
+#endif
/**
* @brief Time delta constant for the tick-less mode.
@@ -58,7 +62,9 @@
* The value one is not valid, timeouts are rounded up to
* this value.
*/
+#if !defined(CH_CFG_ST_TIMEDELTA) || defined(__DOXIGEN__)
#define CH_CFG_ST_TIMEDELTA 0
+#endif
/** @} */
@@ -81,7 +87,9 @@
* @note The round robin preemption is not supported in tickless mode and
* must be set to zero in that case.
*/
+#if !defined(CH_CFG_TIME_QUANTUM) || defined(__DOXIGEN__)
#define CH_CFG_TIME_QUANTUM 20
+#endif
/**
* @brief Managed RAM size.
@@ -94,7 +102,9 @@
* provide the @p __heap_base__ and @p __heap_end__ symbols.
* @note Requires @p CH_CFG_USE_MEMCORE.
*/
+#if !defined(CH_CFG_MEMCORE_SIZE) || defined(__DOXIGEN__)
#define CH_CFG_MEMCORE_SIZE 0x20000
+#endif
/**
* @brief Idle thread automatic spawn suppression.
@@ -103,7 +113,9 @@
* function becomes the idle thread and must implement an
* infinite loop.
*/
+#if !defined(CH_CFG_NO_IDLE_THREAD) || defined(__DOXIGEN__)
#define CH_CFG_NO_IDLE_THREAD FALSE
+#endif
/** @} */
@@ -122,7 +134,9 @@
* @note This is not related to the compiler optimization options.
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_OPTIMIZE_SPEED) || defined(__DOXIGEN__)
#define CH_CFG_OPTIMIZE_SPEED TRUE
+#endif
/** @} */
@@ -140,7 +154,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_TM) || defined(__DOXIGEN__)
#define CH_CFG_USE_TM TRUE
+#endif
/**
* @brief Threads registry APIs.
@@ -148,7 +164,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_REGISTRY) || defined(__DOXIGEN__)
#define CH_CFG_USE_REGISTRY TRUE
+#endif
/**
* @brief Threads synchronization APIs.
@@ -157,7 +175,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_WAITEXIT) || defined(__DOXIGEN__)
#define CH_CFG_USE_WAITEXIT TRUE
+#endif
/**
* @brief Semaphores APIs.
@@ -165,7 +185,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_SEMAPHORES) || defined(__DOXIGEN__)
#define CH_CFG_USE_SEMAPHORES TRUE
+#endif
/**
* @brief Semaphores queuing mode.
@@ -176,7 +198,9 @@
* requirements.
* @note Requires @p CH_CFG_USE_SEMAPHORES.
*/
+#if !defined(CH_CFG_USE_SEMAPHORES_PRIORITY) || defined(__DOXIGEN__)
#define CH_CFG_USE_SEMAPHORES_PRIORITY FALSE
+#endif
/**
* @brief Mutexes APIs.
@@ -184,7 +208,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_MUTEXES) || defined(__DOXIGEN__)
#define CH_CFG_USE_MUTEXES TRUE
+#endif
/**
* @brief Enables recursive behavior on mutexes.
@@ -194,7 +220,9 @@
* @note The default is @p FALSE.
* @note Requires @p CH_CFG_USE_MUTEXES.
*/
+#if !defined(CH_CFG_USE_MUTEXES_RECURSIVE) || defined(__DOXIGEN__)
#define CH_CFG_USE_MUTEXES_RECURSIVE FALSE
+#endif
/**
* @brief Conditional Variables APIs.
@@ -204,7 +232,9 @@
* @note The default is @p TRUE.
* @note Requires @p CH_CFG_USE_MUTEXES.
*/
+#if !defined(CH_CFG_USE_CONDVARS) || defined(__DOXIGEN__)
#define CH_CFG_USE_CONDVARS TRUE
+#endif
/**
* @brief Conditional Variables APIs with timeout.
@@ -214,7 +244,9 @@
* @note The default is @p TRUE.
* @note Requires @p CH_CFG_USE_CONDVARS.
*/
+#if !defined(CH_CFG_USE_CONDVARS_TIMEOUT) || defined(__DOXIGEN__)
#define CH_CFG_USE_CONDVARS_TIMEOUT TRUE
+#endif
/**
* @brief Events Flags APIs.
@@ -222,7 +254,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_EVENTS) || defined(__DOXIGEN__)
#define CH_CFG_USE_EVENTS TRUE
+#endif
/**
* @brief Events Flags APIs with timeout.
@@ -232,7 +266,9 @@
* @note The default is @p TRUE.
* @note Requires @p CH_CFG_USE_EVENTS.
*/
+#if !defined(CH_CFG_USE_EVENTS_TIMEOUT) || defined(__DOXIGEN__)
#define CH_CFG_USE_EVENTS_TIMEOUT TRUE
+#endif
/**
* @brief Synchronous Messages APIs.
@@ -241,7 +277,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_MESSAGES) || defined(__DOXIGEN__)
#define CH_CFG_USE_MESSAGES TRUE
+#endif
/**
* @brief Synchronous Messages queuing mode.
@@ -252,7 +290,9 @@
* requirements.
* @note Requires @p CH_CFG_USE_MESSAGES.
*/
+#if !defined(CH_CFG_USE_MESSAGES_PRIORITY) || defined(__DOXIGEN__)
#define CH_CFG_USE_MESSAGES_PRIORITY FALSE
+#endif
/**
* @brief Mailboxes APIs.
@@ -262,7 +302,9 @@
* @note The default is @p TRUE.
* @note Requires @p CH_CFG_USE_SEMAPHORES.
*/
+#if !defined(CH_CFG_USE_MAILBOXES) || defined(__DOXIGEN__)
#define CH_CFG_USE_MAILBOXES TRUE
+#endif
/**
* @brief Core Memory Manager APIs.
@@ -271,7 +313,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_MEMCORE) || defined(__DOXIGEN__)
#define CH_CFG_USE_MEMCORE TRUE
+#endif
/**
* @brief Heap Allocator APIs.
@@ -283,7 +327,9 @@
* @p CH_CFG_USE_SEMAPHORES.
* @note Mutexes are recommended.
*/
+#if !defined(CH_CFG_USE_HEAP) || defined(__DOXIGEN__)
#define CH_CFG_USE_HEAP TRUE
+#endif
/**
* @brief Memory Pools Allocator APIs.
@@ -292,7 +338,9 @@
*
* @note The default is @p TRUE.
*/
+#if !defined(CH_CFG_USE_MEMPOOLS) || defined(__DOXIGEN__)
#define CH_CFG_USE_MEMPOOLS TRUE
+#endif
/**
* @brief Dynamic Threads APIs.
@@ -303,7 +351,9 @@
* @note Requires @p CH_CFG_USE_WAITEXIT.
* @note Requires @p CH_CFG_USE_HEAP and/or @p CH_CFG_USE_MEMPOOLS.
*/
+#if !defined(CH_CFG_USE_DYNAMIC) || defined(__DOXIGEN__)
#define CH_CFG_USE_DYNAMIC TRUE
+#endif
/** @} */
@@ -319,7 +369,9 @@
*
* @note The default is @p FALSE.
*/
+#if !defined(CH_DBG_STATISTICS) || defined(__DOXIGEN__)
#define CH_DBG_STATISTICS FALSE
+#endif
/**
* @brief Debug option, system state check.
@@ -328,7 +380,9 @@
*
* @note The default is @p FALSE.
*/
+#if !defined(CH_DBG_SYSTEM_STATE_CHECK) || defined(__DOXIGEN__)
#define CH_DBG_SYSTEM_STATE_CHECK FALSE
+#endif
/**
* @brief Debug option, parameters checks.
@@ -337,7 +391,9 @@
*
* @note The default is @p FALSE.
*/
+#if !defined(CH_DBG_ENABLE_CHECKS) || defined(__DOXIGEN__)
#define CH_DBG_ENABLE_CHECKS FALSE
+#endif
/**
* @brief Debug option, consistency checks.
@@ -347,7 +403,9 @@
*
* @note The default is @p FALSE.
*/
+#if !defined(CH_DBG_ENABLE_ASSERTS) || defined(__DOXIGEN__)
#define CH_DBG_ENABLE_ASSERTS FALSE
+#endif
/**
* @brief Debug option, trace buffer.
@@ -356,14 +414,18 @@
*
* @note The default is @p CH_DBG_TRACE_MASK_NONE.
*/
+#if !defined(CH_DBG_TRACE_MASK) || defined(__DOXIGEN__)
#define CH_DBG_TRACE_MASK CH_DBG_TRACE_MASK_NONE
+#endif
/**
* @brief Trace buffer entries.
* @note The trace buffer is only allocated if @p CH_DBG_TRACE_MASK is
* different from @p CH_DBG_TRACE_MASK_NONE.
*/
+#if !defined(CH_DBG_TRACE_BUFFER_SIZE) || defined(__DOXIGEN__)
#define CH_DBG_TRACE_BUFFER_SIZE 128
+#endif
/**
* @brief Debug option, stack checks.
@@ -375,7 +437,9 @@
* @note The default failure mode is to halt the system with the global
* @p panic_msg variable set to @p NULL.
*/
+#if !defined(CH_DBG_ENABLE_STACK_CHECK) || defined(__DOXIGEN__)
#define CH_DBG_ENABLE_STACK_CHECK FALSE
+#endif
/**
* @brief Debug option, stacks initialization.
@@ -385,7 +449,9 @@
*
* @note The default is @p FALSE.
*/
+#if !defined(CH_DBG_FILL_THREADS) || defined(__DOXIGEN__)
#define CH_DBG_FILL_THREADS FALSE
+#endif
/**
* @brief Debug option, threads profiling.
@@ -396,7 +462,9 @@
* @note This debug option is not currently compatible with the
* tickless mode.
*/
+#if !defined(CH_DBG_THREADS_PROFILING) || defined(__DOXIGEN__)
#define CH_DBG_THREADS_PROFILING FALSE
+#endif
/** @} */