mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Boqun Feng <boqun.feng@gmail.com>
To: FUJITA Tomonori <fujita.tomonori@gmail.com>
Cc: a.hindborg@kernel.org, alex.gaynor@gmail.com, ojeda@kernel.org,
	aliceryhl@google.com, anna-maria@linutronix.de,
	bjorn3_gh@protonmail.com, dakr@kernel.org, frederic@kernel.org,
	gary@garyguo.net, jstultz@google.com,
	linux-kernel@vger.kernel.org, lossin@kernel.org,
	lyude@redhat.com, rust-for-linux@vger.kernel.org,
	sboyd@kernel.org, tglx@linutronix.de, tmgross@umich.edu
Subject: Re: [PATCH v3 0/3] rust: time: Introduce typed clock sources and generalize Instant
Date: Sun, 8 Jun 2025 19:55:33 -0700	[thread overview]
Message-ID: <aEZNJYjK97tAZlUu@Mac.home> (raw)
In-Reply-To: <20250609010415.3302835-1-fujita.tomonori@gmail.com>

On Mon, Jun 09, 2025 at 10:04:10AM +0900, FUJITA Tomonori wrote:
> This patch series introduces a type-safe abstraction over clock
> sources. The goal is to remove the need for runtime clock selection
> (via ClockId) and instead leverage Rust's type system to statically
> associate the Instant type with a specific clock.
> 
> This approach enables compile-time enforcement of clock correctness
> across the APIs of Instant type.
> 

Reviewed-by: Boqun Feng <boqun.feng@gmail.com>

Thanks a lot!

Regards,
Boqun

> v3:
> - rebased on 6.16-rc1
> v2: https://lore.kernel.org/rust-for-linux/20250504042436.237756-1-fujita.tomonori@gmail.com/
> - removed most of changes to hrtimer code 
> v1: https://lore.kernel.org/rust-for-linux/20250413105629.162349-1-fujita.tomonori@gmail.com/
> 
> FUJITA Tomonori (3):
>   rust: time: Replace ClockId enum with ClockSource trait
>   rust: time: Make Instant generic over ClockSource
>   rust: time: Add ktime_get() to ClockSource trait
> 
>  rust/helpers/helpers.c      |   1 +
>  rust/helpers/time.c         |  18 ++++
>  rust/kernel/time.rs         | 201 ++++++++++++++++++++++--------------
>  rust/kernel/time/hrtimer.rs |   6 +-
>  4 files changed, 148 insertions(+), 78 deletions(-)
>  create mode 100644 rust/helpers/time.c
> 
> 
> base-commit: 19272b37aa4f83ca52bdf9c16d5d81bdd1354494
> -- 
> 2.43.0
> 

      parent reply	other threads:[~2025-06-09  2:55 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-09  1:04 FUJITA Tomonori
2025-06-09  1:04 ` [PATCH v3 1/3] rust: time: Replace ClockId enum with ClockSource trait FUJITA Tomonori
2025-06-09  1:04 ` [PATCH v3 2/3] rust: time: Make Instant generic over ClockSource FUJITA Tomonori
2025-06-09  1:04 ` [PATCH v3 3/3] rust: time: Add ktime_get() to ClockSource trait FUJITA Tomonori
2025-06-10  8:01   ` Andreas Hindborg
2025-06-10  8:15     ` FUJITA Tomonori
2025-06-10  9:34       ` Andreas Hindborg
2025-06-09  2:55 ` Boqun Feng [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aEZNJYjK97tAZlUu@Mac.home \
    --to=boqun.feng@gmail.com \
    --cc=a.hindborg@kernel.org \
    --cc=alex.gaynor@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=anna-maria@linutronix.de \
    --cc=bjorn3_gh@protonmail.com \
    --cc=dakr@kernel.org \
    --cc=frederic@kernel.org \
    --cc=fujita.tomonori@gmail.com \
    --cc=gary@garyguo.net \
    --cc=jstultz@google.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lossin@kernel.org \
    --cc=lyude@redhat.com \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=sboyd@kernel.org \
    --cc=tglx@linutronix.de \
    --cc=tmgross@umich.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®