This is an automated email from the ASF dual-hosted git repository. acassis pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git
commit ef75aca232a161506a2460ac263fc347424a7bbf Author: ouyangxiangzhen <[email protected]> AuthorDate: Fri Mar 6 09:39:29 2026 +0800 ostest/hrtimer: Simplify the log output. This commit removed unnecessary printf. Assisted-By: mimo-v2.6-pro Signed-off-by: ouyangxiangzhen <[email protected]> --- testing/ostest/hrtimer.c | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/testing/ostest/hrtimer.c b/testing/ostest/hrtimer.c index 742796827..8490234e3 100644 --- a/testing/ostest/hrtimer.c +++ b/testing/ostest/hrtimer.c @@ -681,22 +681,17 @@ static void hrtimer_test_cancel_sync(FAR hrtimer_test_t *param) param->count = 0; - for (idx = 0; idx < HRTIMER_TEST_CSECTION; ) + printf("hrtimer_test_cancel_sync: synchronous cancellation test\n"); + + for (idx = 0; idx < HRTIMER_TEST_CSECTION; idx++) { param->state = 0; hrtimer_start(¶m->timer, hrtimer_test_callback_crita, 0, HRTIMER_MODE_REL); - hrtimer_cancel_sync(¶m->timer); param->state = 1; hrtimer_start(¶m->timer, hrtimer_test_callback_critb, 0, HRTIMER_MODE_REL); - - if (++idx % (HRTIMER_TEST_CSECTION / 4) == 0) - { - printf("hrtimer_test_cancel_sync: passed %u times\n", idx); - } - hrtimer_cancel_sync(¶m->timer); } } @@ -725,6 +720,8 @@ static void hrtimer_test_cancel_periodic(FAR hrtimer_test_t *param) param->count = 0; + printf("hrtimer_test_cancel_periodic:periodic timer cancellation test\n"); + for (idx = 0; idx < HRTIMER_TEST_CSECTION; idx++) { irqstate_t flags = spin_lock_irqsave(lock); @@ -757,12 +754,6 @@ static void hrtimer_test_cancel_periodic(FAR hrtimer_test_t *param) hrtimer_test_ndelay(10000); ASSERT(count == param->count); - - if (++idx % (HRTIMER_TEST_CSECTION / 4) == 0) - { - printf("hrtimer_test_cancel_periodic: passed %u times, count = %" - PRIu64 "\n", idx, param->count); - } } hrtimer_cancel_sync(¶m->timer);
