Rust timekeeping for v6.16 From: Andreas Hindborg <[email protected]>
Andreas Hindborg
reviewerHi Miguel,
Please pull these changes for Rust timekeeping.
This PR morphs the rust hrtimer subsystem into the rust timekeeping subsystem covering delay, sleep timekeeping, and timers.
We also add the Delta and Instant types to replace Ktime. We add Ktime locally for htrimer while we rework hrtimer to use the new types.
In this iteration, Instant does not prevent subtracting instants based on different clock sources. We plan to add this via generics in the next cycle.
The commits were in linux-next since next-20250501.
The following changes since commit 9c32cda43eb78f78c73aee4aa344b777714e259b:
Linux 6.15-rc3 (2025-04-20 13:43:47 -0700)
are available in the Git repository at:
https://github.com/rust-for-linux/linux.git tags/rust-timekeeping-for-v6.16-v2
for you to fetch changes up to 679185904972421c570a1c337a8266835045012d:
MAINTAINERS: rust: Add a new section for all of the time stuff (2025-04-29 15:35:25 +0200)
Best regards,
Andreas
----------------------------------------------------------------
Rust timekeeping changes for v6.16
- Morph the rust hrtimer subsystem into the rust timekeeping subsystem, covering delay, sleep, timekeeping, timers. This new subsystem has all the relevant timekeeping C maintainers listed in the entry.
- Replace Ktime with Delta and Instant types to represent a duration of time and a point in time.
- Temporarily add Ktime to hrtimer module to allow hrtimer to delay converting to Instant and Delta.
----------------------------------------------------------------
FUJITA Tomonori (5):
rust: hrtimer: Add Ktime temporarily
rust: time: Add PartialEq/Eq/PartialOrd/Ord trait to Ktime
rust: time: Introduce Delta type
rust: time: Introduce Instant type
MAINTAINERS: rust: Add a new section for all of the time stuff
MAINTAINERS | 11 ++- rust/kernel/time.rs | 167 +++++++++++++++++++++++++++--------- rust/kernel/time/hrtimer.rs | 18 +++- rust/kernel/time/hrtimer/arc.rs | 2 +- rust/kernel/time/hrtimer/pin.rs | 2 +- rust/kernel/time/hrtimer/pin_mut.rs | 4 +- rust/kernel/time/hrtimer/tbox.rs | 2 +- 7 files changed, 157 insertions(+), 49 deletions(-)
Miguel Ojeda
AppliedQuoted 2 lines · Andreas Hindborg
https://github.com/rust-for-linux/linux.git tags/rust-timekeeping-for-v6.16-v2
Something strange happened in the Subject line, but apart from that, it looks fine.
Merged into rust-next -- thank you!
Cheers,
Miguel