diff options
Diffstat (limited to 'test/smp/regression/threadx_timer_information_test.c')
| -rw-r--r-- | test/smp/regression/threadx_timer_information_test.c | 84 |
1 files changed, 42 insertions, 42 deletions
diff --git a/test/smp/regression/threadx_timer_information_test.c b/test/smp/regression/threadx_timer_information_test.c index 4dbc3c9b..7954de2c 100644 --- a/test/smp/regression/threadx_timer_information_test.c +++ b/test/smp/regression/threadx_timer_information_test.c @@ -48,8 +48,8 @@ CHAR *pointer; /* Put system definition stuff in here, e.g. thread creates and other assorted create information. */ - status = tx_thread_create(&thread_0, "thread 0", thread_0_entry, 1, - pointer, TEST_STACK_SIZE_PRINTF, + status = tx_thread_create(&thread_0, "thread 0", thread_0_entry, 1, + pointer, TEST_STACK_SIZE_PRINTF, 16, 16, 3, TX_AUTO_START); pointer = pointer + TEST_STACK_SIZE_PRINTF; @@ -119,7 +119,7 @@ TX_TIMER_INTERNAL **list_head; /* Application timer error. */ printf("ERROR #4\n"); test_control_return(1); - } + } /* Deactivate the timer. */ status = tx_timer_deactivate(&timer_0); @@ -143,7 +143,7 @@ TX_TIMER_INTERNAL **list_head; /* Application timer error. */ printf("ERROR #6\n"); test_control_return(1); - } + } /* Modify the timer. */ status = tx_timer_change(&timer_0, 100, 1); @@ -194,12 +194,12 @@ TX_TIMER_INTERNAL **list_head; /* Check for successful completion. */ if ((status != TX_SUCCESS) || (active != TX_TRUE) || (remaining_ticks != 1) || (reschedule_ticks != 1) || (next_timer != &timer_1)) { - + /* Application timer error. */ printf("ERROR #10\n"); test_control_return(1); - } - + } + /* Now, deactivate timer 0 to get another path through the info get service. */ status = tx_timer_deactivate(&timer_0); status += tx_timer_info_get(&timer_0, &name, &active, &remaining_ticks, &reschedule_ticks, &next_timer); @@ -207,26 +207,26 @@ TX_TIMER_INTERNAL **list_head; /* Check for successful completion. */ if ((status != TX_SUCCESS) || (active != TX_FALSE) || (remaining_ticks != 1) || (reschedule_ticks != 1) || (next_timer != &timer_1)) { - + /* Application timer error. */ printf("ERROR #11\n"); test_control_return(1); - } + } - /* Change timer 0 to a large value and get the information again. */ + /* Change timer 0 to a large value and get the information again. */ status = tx_timer_change(&timer_0, 100, 200); status += tx_timer_activate(&timer_0); - + status += tx_timer_info_get(&timer_0, &name, &active, &remaining_ticks, &reschedule_ticks, &next_timer); /* Check for successful completion. */ if ((status != TX_SUCCESS) || (active != TX_TRUE) || (remaining_ticks != 100) || (reschedule_ticks != 200) || (next_timer != &timer_1)) { - + /* Application timer error. */ printf("ERROR #12\n"); test_control_return(1); - } + } #ifdef TX_TIMER_ENABLE_PERFORMANCE_INFO @@ -236,7 +236,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_PTR_ERROR) { - + /* Application timer error. */ printf("ERROR #13\n"); test_control_return(1); @@ -245,30 +245,30 @@ TX_TIMER_INTERNAL **list_head; /* Now get the performance information. */ status = tx_timer_performance_info_get(&timer_0, TX_NULL, TX_NULL, TX_NULL, TX_NULL, TX_NULL); status += tx_timer_performance_info_get(&timer_0, &activates, &reactivates, &deactivates, &expirations, &expiration_adjusts); - + /* Check for successful completion. */ - if ((status != TX_SUCCESS) || (activates != timer_0.tx_timer_performance_activate_count) || (reactivates != timer_0.tx_timer_performance_reactivate_count) || + if ((status != TX_SUCCESS) || (activates != timer_0.tx_timer_performance_activate_count) || (reactivates != timer_0.tx_timer_performance_reactivate_count) || (deactivates != timer_0.tx_timer_performance_deactivate_count) || (expirations != timer_0.tx_timer_performance_expiration_count) || (expiration_adjusts != timer_0.tx_timer_performance__expiration_adjust_count)) { - + /* Application timer error. */ printf("ERROR #14\n"); test_control_return(1); - } + } /* Now get the system performance information. */ status = tx_timer_performance_system_info_get(TX_NULL, TX_NULL, TX_NULL, TX_NULL, TX_NULL); status += tx_timer_performance_system_info_get(&activates, &reactivates, &deactivates, &expirations, &expiration_adjusts); - + /* Check for successful completion. */ - if ((status != TX_SUCCESS) || (activates != _tx_timer_performance_activate_count) || (reactivates != _tx_timer_performance_reactivate_count) || + if ((status != TX_SUCCESS) || (activates != _tx_timer_performance_activate_count) || (reactivates != _tx_timer_performance_reactivate_count) || (deactivates != _tx_timer_performance_deactivate_count) || (expirations != _tx_timer_performance_expiration_count) || (expiration_adjusts != _tx_timer_performance__expiration_adjust_count)) { - + /* Application timer error. */ printf("ERROR #15\n"); test_control_return(1); - } + } #else @@ -278,7 +278,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #16\n"); test_control_return(1); @@ -290,7 +290,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #17\n"); test_control_return(1); @@ -302,7 +302,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #18\n"); test_control_return(1); @@ -314,7 +314,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #19\n"); test_control_return(1); @@ -326,7 +326,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #20\n"); test_control_return(1); @@ -338,7 +338,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #21\n"); test_control_return(1); @@ -350,7 +350,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #22\n"); test_control_return(1); @@ -362,7 +362,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #23\n"); test_control_return(1); @@ -374,7 +374,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #24\n"); test_control_return(1); @@ -386,7 +386,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #25\n"); test_control_return(1); @@ -398,7 +398,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #26\n"); test_control_return(1); @@ -410,7 +410,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #27\n"); test_control_return(1); @@ -422,7 +422,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if (status != TX_FEATURE_NOT_ENABLED) { - + /* Application timer error. */ printf("ERROR #28\n"); test_control_return(1); @@ -432,18 +432,18 @@ TX_TIMER_INTERNAL **list_head; /* Test timer that is in the process of expiration - on temporary "expired" list. */ TX_MEMSET(&timer_2, 0, (sizeof(TX_TIMER))); - + /* Setup fake timer and test for no-reactivate condition. */ timer_2.tx_timer_id = TX_TIMER_ID; timer_2.tx_timer_internal.tx_timer_internal_list_head = (TX_TIMER_INTERNAL **) &list_head; list_head = (struct TX_TIMER_INTERNAL_STRUCT **) &(timer_2.tx_timer_internal); - timer_2.tx_timer_internal.tx_timer_internal_remaining_ticks = 10; + timer_2.tx_timer_internal.tx_timer_internal_remaining_ticks = 10; status = tx_timer_info_get(&timer_2, TX_NULL, TX_NULL, &remaining_ticks, &reschedule_ticks, TX_NULL); /* Check for error. */ if ((status != TX_SUCCESS) || (remaining_ticks != 0) || (reschedule_ticks != 0)) { - + /* Application timer error. */ printf("ERROR #28a\n"); test_control_return(1); @@ -453,13 +453,13 @@ TX_TIMER_INTERNAL **list_head; timer_2.tx_timer_id = TX_TIMER_ID; timer_2.tx_timer_internal.tx_timer_internal_list_head = (TX_TIMER_INTERNAL **) &list_head; list_head = (struct TX_TIMER_INTERNAL_STRUCT **) &(timer_2.tx_timer_internal); - timer_2.tx_timer_internal.tx_timer_internal_remaining_ticks = TX_TIMER_ENTRIES * 2; + timer_2.tx_timer_internal.tx_timer_internal_remaining_ticks = TX_TIMER_ENTRIES * 2; status = tx_timer_info_get(&timer_2, TX_NULL, TX_NULL, &remaining_ticks, &reschedule_ticks, TX_NULL); /* Check for error. */ if ((status != TX_SUCCESS) || (remaining_ticks != TX_TIMER_ENTRIES) || (reschedule_ticks != 0)) { - + /* Application timer error. */ printf("ERROR #28a\n"); test_control_return(1); @@ -473,7 +473,7 @@ TX_TIMER_INTERNAL **list_head; timer_2.tx_timer_id = TX_TIMER_ID; timer_2.tx_timer_internal.tx_timer_internal_list_head = (TX_TIMER_INTERNAL **) &list_head; list_head = (struct TX_TIMER_INTERNAL_STRUCT **) &(timer_2.tx_timer_internal); - timer_2.tx_timer_internal.tx_timer_internal_remaining_ticks = 13; + timer_2.tx_timer_internal.tx_timer_internal_remaining_ticks = 13; _tx_timer_expired_timer_ptr = &timer_2.tx_timer_internal; status = tx_timer_info_get(&timer_2, TX_NULL, TX_NULL, &remaining_ticks, &reschedule_ticks, TX_NULL); _tx_timer_expired_timer_ptr = TX_NULL; @@ -484,7 +484,7 @@ TX_TIMER_INTERNAL **list_head; /* Check for error. */ if ((status != TX_SUCCESS) || (remaining_ticks != 0) || (reschedule_ticks != 0)) { - + /* Application timer error. */ printf("ERROR #28b\n"); test_control_return(1); |
