This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git
The following commit(s) were added to refs/heads/master by this push:
new 416c315f9 ostest: sync hrtimer ostest with hrtimer updates
416c315f9 is described below
commit 416c315f928110b37f9b7a362f4dd2f2d89b0cac
Author: wangchengdong <[email protected]>
AuthorDate: Tue Jan 6 12:16:22 2026 +0800
ostest: sync hrtimer ostest with hrtimer updates
Update the hrtimer ostest to reflect recent changes in the hrtimer
implementation.
Signed-off-by: Chengdong Wang <[email protected]>
---
testing/ostest/hrtimer.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/testing/ostest/hrtimer.c b/testing/ostest/hrtimer.c
index 9b2d61430..fcbe1f5d9 100644
--- a/testing/ostest/hrtimer.c
+++ b/testing/ostest/hrtimer.c
@@ -120,19 +120,23 @@ static void hrtimer_test_init(FAR struct hrtimer_test_s
*hrtimer_test,
*
* Input Parameters:
* hrtimer - Pointer to the expired HRTimer instance
+ * expired - The expired value of hrtimer
*
* Returned Value:
* Timer period in nanoseconds (NSEC_PER_50MS)
*
****************************************************************************/
-static uint32_t test_hrtimer_callback(FAR hrtimer_t *hrtimer)
+static uint64_t
+test_hrtimer_callback(FAR hrtimer_t *hrtimer, uint64_t expired)
{
struct timespec ts;
uint32_t diff;
uint64_t now;
int ret;
+ UNUSED(expired);
+
FAR struct hrtimer_test_s *test =
(FAR struct hrtimer_test_s *)hrtimer;
@@ -207,9 +211,7 @@ void hrtimer_test(void)
/* Initialize the high-resolution timer */
- hrtimer_init(&hrtimer_test.timer,
- test_hrtimer_callback,
- NULL);
+ hrtimer_init(&hrtimer_test.timer, test_hrtimer_callback);
/* Start the timer with 500ms relative timeout */