[PATCH 0/8] hrtimer: Remove hrtimer_clock_base::get_time

Thomas Weißschuh posted 8 patches 1 month, 3 weeks ago
There is a newer version of this series
drivers/media/rc/pwm-ir-tx.c   |  5 +----
include/linux/hrtimer.h        | 14 +++++---------
include/linux/hrtimer_defs.h   |  2 --
kernel/sched/core.c            |  2 +-
kernel/time/hrtimer.c          | 34 +++++++++++++++++++++++++---------
kernel/time/itimer.c           |  3 +--
kernel/time/posix-timers.c     |  5 ++---
kernel/time/timer_list.c       |  2 --
lib/test_objpool.c             |  2 +-
scripts/gdb/linux/timerlist.py |  2 --
sound/core/hrtimer.c           |  2 +-
11 files changed, 37 insertions(+), 36 deletions(-)
[PATCH 0/8] hrtimer: Remove hrtimer_clock_base::get_time
Posted by Thomas Weißschuh 1 month, 3 weeks ago
The get_time() callbacks always need to match the bases clockid.
Instead of maintaining that association twice in hrtimer_bases,
use a helper.

Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
---
Thomas Weißschuh (8):
      posix-timers: Avoid direct access to hrtimer clockbase
      timers/itimer: Avoid direct access to hrtimer clockbase
      sched/core: Avoid direct access to hrtimer clockbase
      lib: test_objpool: Avoid direct access to hrtimer clockbase
      ALSA: hrtimer: Avoid direct access to hrtimer clockbase
      media: pwm-ir-tx: Avoid direct access to hrtimer clockbase
      hrtimer: Use hrtimer_cb_get_time() helper
      hrtimer: Remove hrtimer_clock_base::get_time

 drivers/media/rc/pwm-ir-tx.c   |  5 +----
 include/linux/hrtimer.h        | 14 +++++---------
 include/linux/hrtimer_defs.h   |  2 --
 kernel/sched/core.c            |  2 +-
 kernel/time/hrtimer.c          | 34 +++++++++++++++++++++++++---------
 kernel/time/itimer.c           |  3 +--
 kernel/time/posix-timers.c     |  5 ++---
 kernel/time/timer_list.c       |  2 --
 lib/test_objpool.c             |  2 +-
 scripts/gdb/linux/timerlist.py |  2 --
 sound/core/hrtimer.c           |  2 +-
 11 files changed, 37 insertions(+), 36 deletions(-)
---
base-commit: 8f5ae30d69d7543eee0d70083daf4de8fe15d585
change-id: 20250728-hrtimer-cleanup-get_time-8ac9d797a685

Best regards,
-- 
Thomas Weißschuh <thomas.weissschuh@linutronix.de>

Re: [PATCH 0/8] hrtimer: Remove hrtimer_clock_base::get_time
Posted by Peter Zijlstra 1 month, 3 weeks ago
On Tue, Aug 12, 2025 at 08:08:08AM +0200, Thomas Weißschuh wrote:
> The get_time() callbacks always need to match the bases clockid.
> Instead of maintaining that association twice in hrtimer_bases,
> use a helper.
> 
> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
> ---
> Thomas Weißschuh (8):
>       posix-timers: Avoid direct access to hrtimer clockbase
>       timers/itimer: Avoid direct access to hrtimer clockbase
>       sched/core: Avoid direct access to hrtimer clockbase
>       lib: test_objpool: Avoid direct access to hrtimer clockbase
>       ALSA: hrtimer: Avoid direct access to hrtimer clockbase
>       media: pwm-ir-tx: Avoid direct access to hrtimer clockbase
>       hrtimer: Use hrtimer_cb_get_time() helper
>       hrtimer: Remove hrtimer_clock_base::get_time
> 
>  drivers/media/rc/pwm-ir-tx.c   |  5 +----
>  include/linux/hrtimer.h        | 14 +++++---------
>  include/linux/hrtimer_defs.h   |  2 --
>  kernel/sched/core.c            |  2 +-
>  kernel/time/hrtimer.c          | 34 +++++++++++++++++++++++++---------
>  kernel/time/itimer.c           |  3 +--
>  kernel/time/posix-timers.c     |  5 ++---
>  kernel/time/timer_list.c       |  2 --
>  lib/test_objpool.c             |  2 +-
>  scripts/gdb/linux/timerlist.py |  2 --
>  sound/core/hrtimer.c           |  2 +-
>  11 files changed, 37 insertions(+), 36 deletions(-)

Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org>