[tip: timers/core] lib: test_objpool: Avoid direct access to hrtimer clockbase

tip-bot2 for Thomas Weißschuh posted 1 patch 3 weeks, 2 days ago
lib/test_objpool.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[tip: timers/core] lib: test_objpool: Avoid direct access to hrtimer clockbase
Posted by tip-bot2 for Thomas Weißschuh 3 weeks, 2 days ago
The following commit has been merged into the timers/core branch of tip:

Commit-ID:     e8875795160b484f691938ce07a381e77821f947
Gitweb:        https://git.kernel.org/tip/e8875795160b484f691938ce07a381e77821f947
Author:        Thomas Weißschuh <thomas.weissschuh@linutronix.de>
AuthorDate:    Thu, 21 Aug 2025 15:28:11 +02:00
Committer:     Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Tue, 09 Sep 2025 12:27:18 +02:00

lib: test_objpool: Avoid direct access to hrtimer clockbase

The field timer->base->get_time is a private implementation detail and
should not be accessed outside of the hrtimer core.

Switch to the equivalent helper.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/all/20250821-hrtimer-cleanup-get_time-v2-4-3ae822e5bfbd@linutronix.de

---
 lib/test_objpool.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/test_objpool.c b/lib/test_objpool.c
index 8f68818..6a34a75 100644
--- a/lib/test_objpool.c
+++ b/lib/test_objpool.c
@@ -164,7 +164,7 @@ static enum hrtimer_restart ot_hrtimer_handler(struct hrtimer *hrt)
 	/* do bulk-testings for objects pop/push */
 	item->worker(item, 1);
 
-	hrtimer_forward(hrt, hrt->base->get_time(), item->hrtcycle);
+	hrtimer_forward_now(hrt, item->hrtcycle);
 	return HRTIMER_RESTART;
 }