From 49d71a01abeefa000a4cd7a556052d826b096d49 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Sat, 20 Jul 2013 10:12:44 +0000 Subject: Renamed or added prefix to all hernel configuration options. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/kernel_3_dev@6010 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- test/testbmk.c | 16 ++++++++-------- test/testdyn.c | 34 +++++++++++++++++----------------- test/testevt.c | 16 ++++++++-------- test/testheap.c | 8 ++++---- test/testmbox.c | 8 ++++---- test/testmsg.c | 8 ++++---- test/testmtx.c | 20 ++++++++++---------- test/testpools.c | 8 ++++---- test/testqueues.c | 8 ++++---- test/testsem.c | 18 +++++++++--------- test/testthd.c | 4 ++-- 11 files changed, 74 insertions(+), 74 deletions(-) (limited to 'test') diff --git a/test/testbmk.c b/test/testbmk.c index 5e423f34d..ce8b8d51e 100644 --- a/test/testbmk.c +++ b/test/testbmk.c @@ -57,7 +57,7 @@ */ static semaphore_t sem1; -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) static mutex_t mtx1; #endif @@ -575,7 +575,7 @@ ROMCONST struct testcase testbmk11 = { bmk11_execute }; -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /** * @page test_benchmarks_012 Mutexes lock/unlock performance * @@ -648,7 +648,7 @@ static void bmk13_execute(void) { test_print("--- Semaph: "); test_printn(sizeof(semaphore_t)); test_println(" bytes"); -#if CH_USE_EVENTS || defined(__DOXYGEN__) +#if CH_CFG_USE_EVENTS || defined(__DOXYGEN__) test_print("--- EventS: "); test_printn(sizeof(event_source_t)); test_println(" bytes"); @@ -656,22 +656,22 @@ static void bmk13_execute(void) { test_printn(sizeof(event_listener_t)); test_println(" bytes"); #endif -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) test_print("--- Mutex : "); test_printn(sizeof(mutex_t)); test_println(" bytes"); #endif -#if CH_USE_CONDVARS || defined(__DOXYGEN__) +#if CH_CFG_USE_CONDVARS || defined(__DOXYGEN__) test_print("--- CondV.: "); test_printn(sizeof(condition_variable_t)); test_println(" bytes"); #endif -#if CH_USE_QUEUES || defined(__DOXYGEN__) +#if CH_CFG_USE_QUEUES || defined(__DOXYGEN__) test_print("--- Queue : "); test_printn(sizeof(GenericQueue)); test_println(" bytes"); #endif -#if CH_USE_MAILBOXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MAILBOXES || defined(__DOXYGEN__) test_print("--- MailB.: "); test_printn(sizeof(mailbox_t)); test_println(" bytes"); @@ -701,7 +701,7 @@ ROMCONST struct testcase * ROMCONST patternbmk[] = { &testbmk9, &testbmk10, &testbmk11, -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) &testbmk12, #endif &testbmk13, diff --git a/test/testdyn.c b/test/testdyn.c index 3f157686d..31fd0c005 100644 --- a/test/testdyn.c +++ b/test/testdyn.c @@ -31,9 +31,9 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_DYNAMIC - * - @p CH_USE_HEAP - * - @p CH_USE_MEMPOOLS + * - @p CH_CFG_USE_DYNAMIC + * - @p CH_CFG_USE_HEAP + * - @p CH_CFG_USE_MEMPOOLS * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -49,11 +49,11 @@ * @brief Dynamic thread APIs test header file */ -#if CH_USE_DYNAMIC || defined(__DOXYGEN__) -#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__) +#if CH_CFG_USE_DYNAMIC || defined(__DOXYGEN__) +#if (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP) || defined(__DOXYGEN__) static memory_heap_t heap1; #endif -#if CH_USE_MEMPOOLS || defined(__DOXYGEN__) +#if CH_CFG_USE_MEMPOOLS || defined(__DOXYGEN__) static memory_pool_t mp1; #endif @@ -74,7 +74,7 @@ static msg_t thread(void *p) { return 0; } -#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__) +#if (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP) || defined(__DOXYGEN__) static void dyn1_setup(void) { chHeapObjectInit(&heap1, test.buffer, sizeof(union test_buffers)); @@ -120,9 +120,9 @@ ROMCONST struct testcase testdyn1 = { NULL, dyn1_execute }; -#endif /* (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) */ +#endif /* (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP) */ -#if CH_USE_MEMPOOLS || defined(__DOXYGEN__) +#if CH_CFG_USE_MEMPOOLS || defined(__DOXYGEN__) /** * @page test_dynamic_002 Threads creation from Memory Pool * @@ -176,9 +176,9 @@ ROMCONST struct testcase testdyn2 = { NULL, dyn2_execute }; -#endif /* CH_USE_MEMPOOLS */ +#endif /* CH_CFG_USE_MEMPOOLS */ -#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP && CH_USE_REGISTRY) || \ +#if (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP && CH_CFG_USE_REGISTRY) || \ defined(__DOXYGEN__) /** * @page test_dynamic_003 Registry and References test @@ -241,21 +241,21 @@ ROMCONST struct testcase testdyn3 = { NULL, dyn3_execute }; -#endif /* CH_USE_HEAP && CH_USE_REGISTRY */ -#endif /* CH_USE_DYNAMIC */ +#endif /* CH_CFG_USE_HEAP && CH_CFG_USE_REGISTRY */ +#endif /* CH_CFG_USE_DYNAMIC */ /** * @brief Test sequence for dynamic APIs. */ ROMCONST struct testcase * ROMCONST patterndyn[] = { -#if CH_USE_DYNAMIC || defined(__DOXYGEN__) -#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__) +#if CH_CFG_USE_DYNAMIC || defined(__DOXYGEN__) +#if (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP) || defined(__DOXYGEN__) &testdyn1, #endif -#if CH_USE_MEMPOOLS || defined(__DOXYGEN__) +#if CH_CFG_USE_MEMPOOLS || defined(__DOXYGEN__) &testdyn2, #endif -#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP && CH_USE_REGISTRY) || \ +#if (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP && CH_CFG_USE_REGISTRY) || \ defined(__DOXYGEN__) &testdyn3, #endif diff --git a/test/testevt.c b/test/testevt.c index 80bc18ae7..bb9381139 100644 --- a/test/testevt.c +++ b/test/testevt.c @@ -30,8 +30,8 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_EVENTS - * - @p CH_USE_EVENTS_TIMEOUT + * - @p CH_CFG_USE_EVENTS + * - @p CH_CFG_USE_EVENTS_TIMEOUT * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -47,7 +47,7 @@ * @brief Events test header file */ -#if CH_USE_EVENTS || defined(__DOXYGEN__) +#if CH_CFG_USE_EVENTS || defined(__DOXYGEN__) #define ALLOWED_DELAY MS2ST(5) @@ -228,7 +228,7 @@ ROMCONST struct testcase testevt2 = { evt2_execute }; -#if CH_USE_EVENTS_TIMEOUT || defined(__DOXYGEN__) +#if CH_CFG_USE_EVENTS_TIMEOUT || defined(__DOXYGEN__) /** * @page test_events_003 Events timeout * @@ -275,20 +275,20 @@ ROMCONST struct testcase testevt3 = { NULL, evt3_execute }; -#endif /* CH_USE_EVENTS_TIMEOUT */ +#endif /* CH_CFG_USE_EVENTS_TIMEOUT */ /** * @brief Test sequence for events. */ ROMCONST struct testcase * ROMCONST patternevt[] = { -#if CH_USE_EVENTS || defined(__DOXYGEN__) +#if CH_CFG_USE_EVENTS || defined(__DOXYGEN__) &testevt1, &testevt2, -#if CH_USE_EVENTS_TIMEOUT || defined(__DOXYGEN__) +#if CH_CFG_USE_EVENTS_TIMEOUT || defined(__DOXYGEN__) &testevt3, #endif #endif NULL }; -#endif /* CH_USE_EVENTS */ +#endif /* CH_CFG_USE_EVENTS */ diff --git a/test/testheap.c b/test/testheap.c index 667b64cb2..d257a4362 100644 --- a/test/testheap.c +++ b/test/testheap.c @@ -30,7 +30,7 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_HEAP + * - @p CH_CFG_USE_HEAP * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -44,7 +44,7 @@ * @brief Heap header file */ -#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__) +#if (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP) || defined(__DOXYGEN__) #define SIZE 16 @@ -146,13 +146,13 @@ ROMCONST struct testcase testheap1 = { heap1_execute }; -#endif /* CH_USE_HEAP.*/ +#endif /* CH_CFG_USE_HEAP.*/ /** * @brief Test sequence for heap. */ ROMCONST struct testcase * ROMCONST patternheap[] = { -#if (CH_USE_HEAP && !CH_USE_MALLOC_HEAP) || defined(__DOXYGEN__) +#if (CH_CFG_USE_HEAP && !CH_CFG_USE_MALLOC_HEAP) || defined(__DOXYGEN__) &testheap1, #endif NULL diff --git a/test/testmbox.c b/test/testmbox.c index c9d554e16..0ba52aa09 100644 --- a/test/testmbox.c +++ b/test/testmbox.c @@ -33,7 +33,7 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_MAILBOXES + * - @p CH_CFG_USE_MAILBOXES * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -47,7 +47,7 @@ * @brief Mailboxes header file */ -#if CH_USE_MAILBOXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MAILBOXES || defined(__DOXYGEN__) #define ALLOWED_DELAY MS2ST(5) #define MB_SIZE 5 @@ -226,13 +226,13 @@ ROMCONST struct testcase testmbox1 = { mbox1_execute }; -#endif /* CH_USE_MAILBOXES */ +#endif /* CH_CFG_USE_MAILBOXES */ /** * @brief Test sequence for mailboxes. */ ROMCONST struct testcase * ROMCONST patternmbox[] = { -#if CH_USE_MAILBOXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MAILBOXES || defined(__DOXYGEN__) &testmbox1, #endif NULL diff --git a/test/testmsg.c b/test/testmsg.c index 7a1ef1175..30d7f24dd 100644 --- a/test/testmsg.c +++ b/test/testmsg.c @@ -31,7 +31,7 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_MESSAGES + * - @p CH_CFG_USE_MESSAGES * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -45,7 +45,7 @@ * @brief Messages header file */ -#if CH_USE_MESSAGES || defined(__DOXYGEN__) +#if CH_CFG_USE_MESSAGES || defined(__DOXYGEN__) /** * @page test_msg_001 Messages Server loop @@ -95,13 +95,13 @@ ROMCONST struct testcase testmsg1 = { msg1_execute }; -#endif /* CH_USE_MESSAGES */ +#endif /* CH_CFG_USE_MESSAGES */ /** * @brief Test sequence for messages. */ ROMCONST struct testcase * ROMCONST patternmsg[] = { -#if CH_USE_MESSAGES || defined(__DOXYGEN__) +#if CH_CFG_USE_MESSAGES || defined(__DOXYGEN__) &testmsg1, #endif NULL diff --git a/test/testmtx.c b/test/testmtx.c index caaf91409..c775cb51b 100644 --- a/test/testmtx.c +++ b/test/testmtx.c @@ -33,8 +33,8 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_MUTEXES - * - @p CH_USE_CONDVARS + * - @p CH_CFG_USE_MUTEXES + * - @p CH_CFG_USE_CONDVARS * - @p CH_DBG_THREADS_PROFILING * . * In case some of the required options are not enabled then some or all tests @@ -56,7 +56,7 @@ * @brief Mutexes and CondVars test header file */ -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) #define ALLOWED_DELAY 5 @@ -67,7 +67,7 @@ */ static MUTEX_DECL(m1); static MUTEX_DECL(m2); -#if CH_USE_CONDVARS || defined(__DOXYGEN__) +#if CH_CFG_USE_CONDVARS || defined(__DOXYGEN__) static CONDVAR_DECL(c1); #endif @@ -463,7 +463,7 @@ ROMCONST struct testcase testmtx5 = { mtx5_execute }; -#if CH_USE_CONDVARS || defined(__DOXYGEN__) +#if CH_CFG_USE_CONDVARS || defined(__DOXYGEN__) /** * @page test_mtx_006 Condition Variable signal test * @@ -573,7 +573,7 @@ static msg_t thread11(void *p) { chMtxLock(&m2); chMtxLock(&m1); -#if CH_USE_CONDVARS_TIMEOUT || defined(__DOXYGEN__) +#if CH_CFG_USE_CONDVARS_TIMEOUT || defined(__DOXYGEN__) chCondWaitTimeout(&c1, TIME_INFINITE); #else chCondWait(&c1); @@ -610,14 +610,14 @@ ROMCONST struct testcase testmtx8 = { NULL, mtx8_execute }; -#endif /* CH_USE_CONDVARS */ -#endif /* CH_USE_MUTEXES */ +#endif /* CH_CFG_USE_CONDVARS */ +#endif /* CH_CFG_USE_MUTEXES */ /** * @brief Test sequence for mutexes. */ ROMCONST struct testcase * ROMCONST patternmtx[] = { -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) &testmtx1, #if CH_DBG_THREADS_PROFILING || defined(__DOXYGEN__) &testmtx2, @@ -625,7 +625,7 @@ ROMCONST struct testcase * ROMCONST patternmtx[] = { #endif &testmtx4, &testmtx5, -#if CH_USE_CONDVARS || defined(__DOXYGEN__) +#if CH_CFG_USE_CONDVARS || defined(__DOXYGEN__) &testmtx6, &testmtx7, &testmtx8, diff --git a/test/testpools.c b/test/testpools.c index 6ff669227..18063e111 100644 --- a/test/testpools.c +++ b/test/testpools.c @@ -30,7 +30,7 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_MEMPOOLS + * - @p CH_CFG_USE_MEMPOOLS * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -44,7 +44,7 @@ * @brief Memory Pools test header file */ -#if CH_USE_MEMPOOLS || defined(__DOXYGEN__) +#if CH_CFG_USE_MEMPOOLS || defined(__DOXYGEN__) static MEMORYPOOL_DECL(mp1, THD_WA_SIZE(THREADS_STACK_SIZE), NULL); @@ -104,13 +104,13 @@ ROMCONST struct testcase testpools1 = { pools1_execute }; -#endif /* CH_USE_MEMPOOLS */ +#endif /* CH_CFG_USE_MEMPOOLS */ /* * @brief Test sequence for pools. */ ROMCONST struct testcase * ROMCONST patternpools[] = { -#if CH_USE_MEMPOOLS || defined(__DOXYGEN__) +#if CH_CFG_USE_MEMPOOLS || defined(__DOXYGEN__) &testpools1, #endif NULL diff --git a/test/testqueues.c b/test/testqueues.c index 7f682ef8e..d19ca5e00 100644 --- a/test/testqueues.c +++ b/test/testqueues.c @@ -35,7 +35,7 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_QUEUES (and dependent options) + * - @p CH_CFG_USE_QUEUES (and dependent options) * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -50,7 +50,7 @@ * @brief I/O Queues test header file */ -#if CH_USE_QUEUES || defined(__DOXYGEN__) +#if CH_CFG_USE_QUEUES || defined(__DOXYGEN__) #define TEST_QUEUES_SIZE 4 @@ -230,13 +230,13 @@ ROMCONST struct testcase testqueues2 = { NULL, queues2_execute }; -#endif /* CH_USE_QUEUES */ +#endif /* CH_CFG_USE_QUEUES */ /** * @brief Test sequence for queues. */ ROMCONST struct testcase * ROMCONST patternqueues[] = { -#if CH_USE_QUEUES || defined(__DOXYGEN__) +#if CH_CFG_USE_QUEUES || defined(__DOXYGEN__) &testqueues1, &testqueues2, #endif diff --git a/test/testsem.c b/test/testsem.c index b27540059..9483a75d6 100644 --- a/test/testsem.c +++ b/test/testsem.c @@ -30,7 +30,7 @@ * *

Preconditions

* The module requires the following kernel options: - * - @p CH_USE_SEMAPHORES + * - @p CH_CFG_USE_SEMAPHORES * . * In case some of the required options are not enabled then some or all tests * may be skipped. @@ -47,7 +47,7 @@ * @brief Semaphores test header file */ -#if CH_USE_SEMAPHORES || defined(__DOXYGEN__) +#if CH_CFG_USE_SEMAPHORES || defined(__DOXYGEN__) #define ALLOWED_DELAY MS2ST(5) @@ -65,7 +65,7 @@ static SEMAPHORE_DECL(sem1, 0); * Five threads with randomized priorities are enqueued to a semaphore then * awakened one at time.
* The test expects that the threads reach their goal in FIFO order or - * priority order depending on the CH_USE_SEMAPHORES_PRIORITY configuration + * priority order depending on the CH_CFG_USE_SEMAPHORES_PRIORITY configuration * setting. */ @@ -94,7 +94,7 @@ static void sem1_execute(void) { chSemSignal(&sem1); chSemSignal(&sem1); test_wait_threads(); -#if CH_USE_SEMAPHORES_PRIORITY +#if CH_CFG_USE_SEMAPHORES_PRIORITY test_assert_sequence(1, "ADCEB"); #else test_assert_sequence(1, "ABCDE"); @@ -188,7 +188,7 @@ ROMCONST struct testcase testsem2 = { sem2_execute }; -#if CH_USE_SEMSW || defined(__DOXYGEN__) +#if CH_CFG_USE_SEMSW || defined(__DOXYGEN__) /** * @page test_sem_003 Atomic signal-wait test * @@ -232,7 +232,7 @@ ROMCONST struct testcase testsem3 = { NULL, sem3_execute }; -#endif /* CH_USE_SEMSW */ +#endif /* CH_CFG_USE_SEMSW */ /** * @page test_sem_004 Binary Wait and Signal @@ -284,16 +284,16 @@ ROMCONST struct testcase testsem4 = { NULL, sem4_execute }; -#endif /* CH_USE_SEMAPHORES */ +#endif /* CH_CFG_USE_SEMAPHORES */ /** * @brief Test sequence for semaphores. */ ROMCONST struct testcase * ROMCONST patternsem[] = { -#if CH_USE_SEMAPHORES || defined(__DOXYGEN__) +#if CH_CFG_USE_SEMAPHORES || defined(__DOXYGEN__) &testsem1, &testsem2, -#if CH_USE_SEMSW || defined(__DOXYGEN__) +#if CH_CFG_USE_SEMSW || defined(__DOXYGEN__) &testsem3, #endif &testsem4, diff --git a/test/testthd.c b/test/testthd.c index 9916ca253..af71a2041 100644 --- a/test/testthd.c +++ b/test/testthd.c @@ -119,7 +119,7 @@ ROMCONST struct testcase testthd2 = { *

Description

* A series of priority changes are performed on the current thread in order * to verify that the priority change happens as expected.
- * If the @p CH_USE_MUTEXES option is enabled then the priority changes are + * If the @p CH_CFG_USE_MUTEXES option is enabled then the priority changes are * also tested under priority inheritance boosted priority state. */ @@ -138,7 +138,7 @@ static void thd3_execute(void) { test_assert(4, chThdGetPriority() == prio, "unexpected priority level"); -#if CH_USE_MUTEXES || defined(__DOXYGEN__) +#if CH_CFG_USE_MUTEXES || defined(__DOXYGEN__) /* Simulates a priority boost situation (p_prio > p_realprio).*/ chSysLock(); chThdSelf()->p_prio += 2; -- cgit v1.2.3