From eafe07cea92006cd0c1788724e1097831c594754 Mon Sep 17 00:00:00 2001 From: Kelvin Lawson Date: Mon, 7 Jun 2010 21:13:25 +0100 Subject: [PATCH] TESTS: Function parameters cannot be named "data" when using Raisonance STM8 compiler. --- tests/kern1.c | 9 ++++++--- tests/kern3.c | 8 ++++---- tests/kern4.c | 8 ++++---- tests/mutex1.c | 18 ++++++++++++------ tests/mutex2.c | 9 ++++++--- tests/mutex3.c | 8 ++++---- tests/mutex4.c | 9 ++++++--- tests/mutex5.c | 9 ++++++--- tests/mutex6.c | 9 ++++++--- tests/mutex7.c | 9 ++++++--- tests/mutex8.c | 8 ++++---- tests/mutex9.c | 9 ++++++--- tests/queue2.c | 18 ++++++++++++------ tests/queue3.c | 18 ++++++++++++------ tests/queue5.c | 8 ++++---- tests/queue6.c | 9 ++++++--- tests/queue7.c | 8 ++++---- tests/queue9.c | 9 ++++++--- tests/sem1.c | 18 ++++++++++++------ tests/sem3.c | 8 ++++---- tests/sem4.c | 9 ++++++--- tests/sem5.c | 9 ++++++--- tests/sem6.c | 9 ++++++--- tests/sem7.c | 9 ++++++--- tests/sem8.c | 8 ++++---- tests/sem9.c | 8 ++++---- tests/timer2.c | 8 ++++---- 27 files changed, 166 insertions(+), 103 deletions(-) diff --git a/tests/kern1.c b/tests/kern1.c index 62a3d79..1695039 100644 --- a/tests/kern1.c +++ b/tests/kern1.c @@ -39,7 +39,7 @@ static uint8_t test_thread_stack[TEST_THREAD_STACK_SIZE]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -107,12 +107,15 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { + /* Compiler warnings */ + param = param; + /* Wait forever */ while (1) { diff --git a/tests/kern3.c b/tests/kern3.c index 18b8965..20304f8 100644 --- a/tests/kern3.c +++ b/tests/kern3.c @@ -47,7 +47,7 @@ static volatile int sleep_request[2]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -213,16 +213,16 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Thread ID (0 = low prio, 1 = high prio) + * @param[in] param Thread ID (0 = low prio, 1 = high prio) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { int thread_id; /* Pull out thread ID */ - thread_id = (int)data; + thread_id = (int)param; /* Run forever */ while (1) diff --git a/tests/kern4.c b/tests/kern4.c index 90bc027..909232e 100644 --- a/tests/kern4.c +++ b/tests/kern4.c @@ -50,7 +50,7 @@ static int volatile test_started; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -184,11 +184,11 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Thread ID (0 to 3) + * @param[in] param Thread ID (0 to 3) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { int thread_id, expected_thread; int time_error, thread_error; @@ -196,7 +196,7 @@ static void test_thread_func (uint32_t data) CRITICAL_STORE; /* Pull out thread ID */ - thread_id = (int)data; + thread_id = (int)param; /* Run forever */ while (1) diff --git a/tests/mutex1.c b/tests/mutex1.c index 0d37fb7..e3bc16a 100644 --- a/tests/mutex1.c +++ b/tests/mutex1.c @@ -48,8 +48,8 @@ static volatile int g_result; /* Forward declarations */ -static void test1_thread_func (uint32_t data); -static void test2_thread_func (uint32_t data); +static void test1_thread_func (uint32_t param); +static void test2_thread_func (uint32_t param); /** @@ -291,14 +291,17 @@ uint32_t test_start (void) * * Entry point for test thread 1. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test1_thread_func (uint32_t data) +static void test1_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* * Wait on mutex1 with no timeout. We are expecting to be woken up * by the main thread while blocking. @@ -327,14 +330,17 @@ static void test1_thread_func (uint32_t data) * * Entry point for test thread 2. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test2_thread_func (uint32_t data) +static void test2_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* * Wait on mutex1 with timeout. We are expecting to be woken up * by the main thread while blocking. diff --git a/tests/mutex2.c b/tests/mutex2.c index d71b411..9725f44 100644 --- a/tests/mutex2.c +++ b/tests/mutex2.c @@ -50,7 +50,7 @@ static volatile int g_result, g_owned; /* Forward declarations */ static void testCallback (POINTER cb_data); -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -296,14 +296,17 @@ static void testCallback (POINTER cb_data) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* * Take mutex2 so that main thread can test mutex APIs on a mutex * which it does not own. diff --git a/tests/mutex3.c b/tests/mutex3.c index 7a6f38b..f604430 100644 --- a/tests/mutex3.c +++ b/tests/mutex3.c @@ -47,7 +47,7 @@ static volatile uint8_t wake_cnt; static volatile uint8_t wake_order[4]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -246,16 +246,16 @@ uint32_t test_start (void) * four test threads, with the thread number/ID (1-4) passed as the entry * point parameter. * - * @param[in] data Thread number (1,2,3,4) + * @param[in] param Thread number (1,2,3,4) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t thread_id; /* Thread ID is passed through the function parameter */ - thread_id = (uint8_t)data; + thread_id = (uint8_t)param; /* * Wait for mutex1 to be posted. At creation of all test threads the mutex diff --git a/tests/mutex4.c b/tests/mutex4.c index 4b0ac2e..b478517 100644 --- a/tests/mutex4.c +++ b/tests/mutex4.c @@ -56,7 +56,7 @@ static volatile int g_failures; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -242,16 +242,19 @@ uint32_t test_start (void) * Entry point for test thread. The same thread entry point is used for all * four test threads. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint32_t loop_cnt; uint8_t status; CRITICAL_STORE; + /* Compiler warnings */ + param = param; + /* Run a Get/Put pair many times */ loop_cnt = NUM_TEST_LOOPS; while (loop_cnt--) diff --git a/tests/mutex5.c b/tests/mutex5.c index bcf99da..9aa18f2 100644 --- a/tests/mutex5.c +++ b/tests/mutex5.c @@ -48,7 +48,7 @@ static volatile int shared_data; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -255,14 +255,17 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* Repeatedly attempt to get the mutex and set shared_data to 1 */ while (1) { diff --git a/tests/mutex6.c b/tests/mutex6.c index a851fb3..ca2c2d6 100644 --- a/tests/mutex6.c +++ b/tests/mutex6.c @@ -52,7 +52,7 @@ static volatile int shared_data; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -246,14 +246,17 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* Repeatedly attempt to get the mutex and set shared_data to 1 */ while (1) { diff --git a/tests/mutex7.c b/tests/mutex7.c index 7cdfb05..9189dee 100644 --- a/tests/mutex7.c +++ b/tests/mutex7.c @@ -50,7 +50,7 @@ static volatile int shared_data; /* Forward declarations */ static void testCallback (POINTER cb_data); -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -210,14 +210,17 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* Block on the mutex */ if ((status = atomMutexGet (&mutex1, 0)) != ATOM_OK) { diff --git a/tests/mutex8.c b/tests/mutex8.c index 93ec3b0..14febb9 100644 --- a/tests/mutex8.c +++ b/tests/mutex8.c @@ -48,7 +48,7 @@ static volatile int pass_flag[3]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -192,17 +192,17 @@ uint32_t test_start (void) * * Entry point for test threads. * - * @param[in] data Thread ID (0-2) + * @param[in] param Thread ID (0-2) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; int thread_id; /* Pull out the passed thread ID */ - thread_id = (int)data; + thread_id = (int)param; /* * Wait on mutex1 with timeout. We are expecting to be woken up diff --git a/tests/mutex9.c b/tests/mutex9.c index be7090d..e509762 100644 --- a/tests/mutex9.c +++ b/tests/mutex9.c @@ -48,7 +48,7 @@ static volatile int shared_data; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -185,14 +185,17 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* Block on the mutex */ if ((status = atomMutexGet (&mutex1, 0)) != ATOM_OK) { diff --git a/tests/queue2.c b/tests/queue2.c index 986bce0..8528ade 100644 --- a/tests/queue2.c +++ b/tests/queue2.c @@ -53,8 +53,8 @@ static volatile int g_result; /* Forward declarations */ -static void test1_thread_func (uint32_t data); -static void test2_thread_func (uint32_t data); +static void test1_thread_func (uint32_t param); +static void test2_thread_func (uint32_t param); /** @@ -237,14 +237,17 @@ uint32_t test_start (void) * * Entry point for test thread 1. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test1_thread_func (uint32_t data) +static void test1_thread_func (uint32_t param) { uint8_t status, msg; + /* Compiler warnings */ + param = param; + /* * Wait on queue1 with no timeout. We are expecting to be woken up * by the main thread while blocking. @@ -273,14 +276,17 @@ static void test1_thread_func (uint32_t data) * * Entry point for test thread 2. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test2_thread_func (uint32_t data) +static void test2_thread_func (uint32_t param) { uint8_t status, msg; + /* Compiler warnings */ + param = param; + /* * Wait on queue1 with timeout. We are expecting to be woken up * by the main thread while blocking. diff --git a/tests/queue3.c b/tests/queue3.c index d501dd1..277a4e3 100644 --- a/tests/queue3.c +++ b/tests/queue3.c @@ -53,8 +53,8 @@ static volatile int g_result; /* Forward declarations */ -static void test1_thread_func (uint32_t data); -static void test2_thread_func (uint32_t data); +static void test1_thread_func (uint32_t param); +static void test2_thread_func (uint32_t param); /** @@ -269,14 +269,17 @@ uint32_t test_start (void) * * Entry point for test thread 1. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test1_thread_func (uint32_t data) +static void test1_thread_func (uint32_t param) { uint8_t status, msg; + /* Compiler warnings */ + param = param; + /* Set a test value for posting to the queue */ msg = 0x66; @@ -309,14 +312,17 @@ static void test1_thread_func (uint32_t data) * * Entry point for test thread 2. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test2_thread_func (uint32_t data) +static void test2_thread_func (uint32_t param) { uint8_t status, msg; + /* Compiler warnings */ + param = param; + /* Set a test value for posting to the queue */ msg = 0x66; diff --git a/tests/queue5.c b/tests/queue5.c index 09ae150..bf07960 100644 --- a/tests/queue5.c +++ b/tests/queue5.c @@ -53,7 +53,7 @@ static volatile uint8_t wake_cnt; static volatile uint8_t wake_order[4]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -263,17 +263,17 @@ uint32_t test_start (void) * four test threads, with the thread number/ID (1-4) passed as the entry * point parameter. * - * @param[in] data Thread number (1,2,3,4) + * @param[in] param Thread number (1,2,3,4) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t thread_id; uint8_t msg; /* Thread ID is passed through the function parameter */ - thread_id = (uint8_t)data; + thread_id = (uint8_t)param; /* * Wait for a message to appear on queue1. At creation of all test diff --git a/tests/queue6.c b/tests/queue6.c index 424a228..4de62f0 100644 --- a/tests/queue6.c +++ b/tests/queue6.c @@ -70,7 +70,7 @@ static volatile int g_result; /* Forward declarations */ -static void test1_thread_func (uint32_t data); +static void test1_thread_func (uint32_t param); /** @@ -215,15 +215,18 @@ uint32_t test_start (void) * * Entry point for test thread 1. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test1_thread_func (uint32_t data) +static void test1_thread_func (uint32_t param) { uint32_t msg; int num_entries, count, failures; + /* Compiler warnings */ + param = param; + /* Default to no errors */ failures = 0; diff --git a/tests/queue7.c b/tests/queue7.c index d29c184..5b249d8 100644 --- a/tests/queue7.c +++ b/tests/queue7.c @@ -53,7 +53,7 @@ static volatile int pass_flag[3]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -192,18 +192,18 @@ uint32_t test_start (void) * * Entry point for test threads. * - * @param[in] data Thread ID (0-2) + * @param[in] param Thread ID (0-2) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; uint8_t msg; int thread_id; /* Pull out the passed thread ID */ - thread_id = (int)data; + thread_id = (int)param; /* * Wait on queue1 with timeout. We are expecting to be woken up diff --git a/tests/queue9.c b/tests/queue9.c index 9eec258..1bc1034 100644 --- a/tests/queue9.c +++ b/tests/queue9.c @@ -62,7 +62,7 @@ static volatile int g_failures; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -237,17 +237,20 @@ uint32_t test_start (void) * Entry point for test thread. The same thread entry point is used for all * four test threads. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint32_t loop_cnt; uint8_t status; uint8_t msg; CRITICAL_STORE; + /* Compiler warnings */ + param = param; + /* Run a Put/Get pair many times */ loop_cnt = NUM_TEST_LOOPS; while (loop_cnt--) diff --git a/tests/sem1.c b/tests/sem1.c index 84c9b4e..b7b6335 100644 --- a/tests/sem1.c +++ b/tests/sem1.c @@ -45,8 +45,8 @@ static uint8_t test_thread_stack[NUM_TEST_THREADS][TEST_THREAD_STACK_SIZE]; /* Forward declarations */ -static void test1_thread_func (uint32_t data); -static void test2_thread_func (uint32_t data); +static void test1_thread_func (uint32_t param); +static void test2_thread_func (uint32_t param); /** @@ -298,14 +298,17 @@ uint32_t test_start (void) * * Entry point for test thread 1. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test1_thread_func (uint32_t data) +static void test1_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* * Wait on sem1 with no timeout. We are expecting to be woken up * by the main thread while blocking. @@ -337,13 +340,16 @@ static void test1_thread_func (uint32_t data) * * Entry point for test thread 2. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test2_thread_func (uint32_t data) +static void test2_thread_func (uint32_t param) { uint8_t status; + + /* Compiler warnings */ + param = param; /* * Wait on sem1 with timeout. We are expecting to be woken up diff --git a/tests/sem3.c b/tests/sem3.c index 3387aac..6648b39 100644 --- a/tests/sem3.c +++ b/tests/sem3.c @@ -49,7 +49,7 @@ static volatile uint8_t wake_order[4]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -242,16 +242,16 @@ uint32_t test_start (void) * four test threads, with the thread number/ID (1-4) passed as the entry * point parameter. * - * @param[in] data Thread number (1,2,3,4) + * @param[in] param Thread number (1,2,3,4) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t thread_id; /* Thread ID is passed through the function parameter */ - thread_id = (uint8_t)data; + thread_id = (uint8_t)param; /* * Wait for sem1 to be posted. At creation of all test threads diff --git a/tests/sem4.c b/tests/sem4.c index 2f986a7..419195c 100644 --- a/tests/sem4.c +++ b/tests/sem4.c @@ -55,7 +55,7 @@ static volatile int g_failures; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -231,16 +231,19 @@ uint32_t test_start (void) * Entry point for test thread. The same thread entry point is used for all * four test threads. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint32_t loop_cnt; uint8_t status; CRITICAL_STORE; + /* Compiler warnings */ + param = param; + /* Run a Get/Put pair many times */ loop_cnt = NUM_TEST_LOOPS; while (loop_cnt--) diff --git a/tests/sem5.c b/tests/sem5.c index 11b2c0e..dc87f9f 100644 --- a/tests/sem5.c +++ b/tests/sem5.c @@ -44,7 +44,7 @@ static uint8_t test_thread_stack[NUM_TEST_THREADS][TEST_THREAD_STACK_SIZE]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -193,14 +193,17 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* Block on sem1. Main thread will post when we should wake up. */ if ((status = atomSemGet (&sem1, 0)) != ATOM_OK) { diff --git a/tests/sem6.c b/tests/sem6.c index 4ee2927..851f9b8 100644 --- a/tests/sem6.c +++ b/tests/sem6.c @@ -48,7 +48,7 @@ static uint8_t test_thread_stack[NUM_TEST_THREADS][TEST_THREAD_STACK_SIZE]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -176,16 +176,19 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; int count; int failures; + /* Compiler warnings */ + param = param; + /* * Attempt to decrement sem1 ten times, which should happen immediately * each time. diff --git a/tests/sem7.c b/tests/sem7.c index 8c376cb..62fa16f 100644 --- a/tests/sem7.c +++ b/tests/sem7.c @@ -48,7 +48,7 @@ static volatile int shared_data; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -262,14 +262,17 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data Unused (optional thread entry parameter) + * @param[in] param Unused (optional thread entry parameter) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; + /* Compiler warnings */ + param = param; + /* Repeatedly attempt to get the mutex and set shared_data to 1 */ while (1) { diff --git a/tests/sem8.c b/tests/sem8.c index 149458f..432cf32 100644 --- a/tests/sem8.c +++ b/tests/sem8.c @@ -48,7 +48,7 @@ static volatile int test_running; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); static void testCallback (POINTER cb_data); @@ -221,17 +221,17 @@ uint32_t test_start (void) * * Entry point for test thread. * - * @param[in] data sleep_flag passed through here + * @param[in] param sleep_flag passed through here * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; int sleep_flag, count, failures; /* Were we requested to sleep occasionally? */ - sleep_flag = (int)data; + sleep_flag = (int)param; /* Run until the main thread sets the finish flag or we get an error */ failures = 0; diff --git a/tests/sem9.c b/tests/sem9.c index e9ae3db..d7a86d6 100644 --- a/tests/sem9.c +++ b/tests/sem9.c @@ -48,7 +48,7 @@ static volatile int pass_flag[3]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -185,17 +185,17 @@ uint32_t test_start (void) * * Entry point for test threads. * - * @param[in] data Thread ID (0-2) + * @param[in] param Thread ID (0-2) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t status; int thread_id; /* Pull out the passed thread ID */ - thread_id = (int)data; + thread_id = (int)param; /* * Wait on sem1 with timeout. We are expecting to be woken up diff --git a/tests/timer2.c b/tests/timer2.c index 47d0e6c..a606830 100644 --- a/tests/timer2.c +++ b/tests/timer2.c @@ -50,7 +50,7 @@ static volatile int g_failure_cnt[3]; /* Forward declarations */ -static void test_thread_func (uint32_t data); +static void test_thread_func (uint32_t param); /** @@ -157,17 +157,17 @@ uint32_t test_start (void) * three test threads, with the thread number/ID (1-3) passed as the entry * point parameter. * - * @param[in] data Thread number (1,2,3) + * @param[in] param Thread number (1,2,3) * * @return None */ -static void test_thread_func (uint32_t data) +static void test_thread_func (uint32_t param) { uint8_t thread_id; uint32_t start_time, end_time; /* Thread ID is passed through the function parameter */ - thread_id = (uint8_t)data; + thread_id = (uint8_t)param; /* * Sleep for 1 tick to ensure that the thread starts near