| #
cfe872eb |
| 22-Sep-2025 |
Miguel Ojeda <ojeda@kernel.org> |
Merge tag 'rust-timekeeping-v6.18' of https://github.com/Rust-for-Linux/linux into rust-next
Pull timekeeping updates from Andreas Hindborg:
- Add methods on 'HrTimer' that can only be called with
Merge tag 'rust-timekeeping-v6.18' of https://github.com/Rust-for-Linux/linux into rust-next
Pull timekeeping updates from Andreas Hindborg:
- Add methods on 'HrTimer' that can only be called with exclusive access to an unarmed timer, or form timer callback context.
- Add arithmetic operations to 'Instant' and 'Delta'.
- Add a few convenience and access methods to 'HrTimer' and 'Instant'.
* tag 'rust-timekeeping-v6.18' of https://github.com/Rust-for-Linux/linux: rust: time: Implement basic arithmetic operations for Delta rust: time: Implement Add<Delta>/Sub<Delta> for Instant rust: hrtimer: Add HrTimer::expires() rust: time: Add Instant::from_ktime() rust: hrtimer: Add forward_now() to HrTimer and HrTimerCallbackContext rust: hrtimer: Add HrTimerCallbackContext and ::forward() rust: hrtimer: Add HrTimer::raw_forward() and forward() rust: hrtimer: Add HrTimerInstant rust: hrtimer: Document the return value for HrTimerHandle::cancel()
show more ...
|
| #
4b014749 |
| 21-Aug-2025 |
Lyude Paul <lyude@redhat.com> |
rust: hrtimer: Add HrTimer::expires()
Add a simple callback for retrieving the current expiry time for an HrTimer. In rvkms, we use the HrTimer expiry value in order to calculate the approximate vbl
rust: hrtimer: Add HrTimer::expires()
Add a simple callback for retrieving the current expiry time for an HrTimer. In rvkms, we use the HrTimer expiry value in order to calculate the approximate vblank timestamp during each emulated vblank interrupt.
Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Link: https://lore.kernel.org/r/20250821193259.964504-8-lyude@redhat.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
ac0a7bd2 |
| 21-Aug-2025 |
Lyude Paul <lyude@redhat.com> |
rust: hrtimer: Add forward_now() to HrTimer and HrTimerCallbackContext
Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Reviewed-by: Andreas Hi
rust: hrtimer: Add forward_now() to HrTimer and HrTimerCallbackContext
Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Link: https://lore.kernel.org/r/20250821193259.964504-6-lyude@redhat.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
3f2a5ba7 |
| 21-Aug-2025 |
Lyude Paul <lyude@redhat.com> |
rust: hrtimer: Add HrTimerCallbackContext and ::forward()
With Linux's hrtimer API, there's a number of methods that can only be called in two situations:
* When we have exclusive access to the hrt
rust: hrtimer: Add HrTimerCallbackContext and ::forward()
With Linux's hrtimer API, there's a number of methods that can only be called in two situations:
* When we have exclusive access to the hrtimer and it is not currently active * When we're within the context of an hrtimer callback context
This commit handles the second situation and implements hrtimer_forward() support in the context of a timer callback. We do this by introducing a HrTimerCallbackContext type which is provided to users during the RawHrTimerCallback::run() callback, and then add a forward() function to the type.
Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Link: https://lore.kernel.org/r/20250821193259.964504-5-lyude@redhat.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
3efb9ce9 |
| 21-Aug-2025 |
Lyude Paul <lyude@redhat.com> |
rust: hrtimer: Add HrTimer::raw_forward() and forward()
Within the hrtimer API there are quite a number of functions that can only be safely called from one of two contexts:
* When we have exclusiv
rust: hrtimer: Add HrTimer::raw_forward() and forward()
Within the hrtimer API there are quite a number of functions that can only be safely called from one of two contexts:
* When we have exclusive access to the hrtimer and the timer is not active. * When we're within the hrtimer's callback context as it is being executed.
This commit adds bindings for hrtimer_forward() for the first such context, along with HrTimer::raw_forward() for later use in implementing the hrtimer_forward() in the latter context.
Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Link: https://lore.kernel.org/r/20250821193259.964504-4-lyude@redhat.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
0e2aab67 |
| 21-Aug-2025 |
Lyude Paul <lyude@redhat.com> |
rust: hrtimer: Add HrTimerInstant
Since we want to add HrTimer methods that can accept Instants, we will want to make sure that for each method we are using the correct Clocksource for the given HrT
rust: hrtimer: Add HrTimerInstant
Since we want to add HrTimer methods that can accept Instants, we will want to make sure that for each method we are using the correct Clocksource for the given HrTimer. This would get a bit overly-verbose, so add a simple HrTimerInstant type-alias to handle this for us.
Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Link: https://lore.kernel.org/r/20250821193259.964504-3-lyude@redhat.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
a984da24 |
| 21-Aug-2025 |
Lyude Paul <lyude@redhat.com> |
rust: hrtimer: Document the return value for HrTimerHandle::cancel()
Just a drive-by fix I noticed: we don't actually document what the return value from cancel() does, so do that.
Signed-off-by: L
rust: hrtimer: Document the return value for HrTimerHandle::cancel()
Just a drive-by fix I noticed: we don't actually document what the return value from cancel() does, so do that.
Signed-off-by: Lyude Paul <lyude@redhat.com> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com> Link: https://lore.kernel.org/r/20250821193259.964504-2-lyude@redhat.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
9e293d47 |
| 12-Aug-2025 |
Martin KaFai Lau <martin.lau@kernel.org> |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf
Cross merge bpf/master after 6.17-rc1.
No conflict.
Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
|
| #
8d2b0853 |
| 11-Aug-2025 |
Thomas Zimmermann <tzimmermann@suse.de> |
Merge drm/drm-fixes into drm-misc-fixes
Updating drm-misc-fixes to the state of v6.17-rc1. Begins a new release cycle.
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
|
| #
0074281b |
| 07-Aug-2025 |
Bartosz Golaszewski <bartosz.golaszewski@linaro.org> |
Merge commit '6e64f4580381e32c06ee146ca807c555b8f73e24' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux into gpio/for-next
|
| #
ab93e0dd |
| 06-Aug-2025 |
Dmitry Torokhov <dmitry.torokhov@gmail.com> |
Merge branch 'next' into for-linus
Prepare input updates for 6.17 merge window.
|
| #
a7bee4e7 |
| 04-Aug-2025 |
Dmitry Torokhov <dmitry.torokhov@gmail.com> |
Merge tag 'ib-mfd-gpio-input-pwm-v6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd into next
Merge an immutable branch between MFD, GPIO, Input and PWM to resolve conflicts for the mer
Merge tag 'ib-mfd-gpio-input-pwm-v6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd into next
Merge an immutable branch between MFD, GPIO, Input and PWM to resolve conflicts for the merge window pull request.
show more ...
|
| #
352af6a0 |
| 03-Aug-2025 |
Linus Torvalds <torvalds@linux-foundation.org> |
Merge tag 'rust-6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/ojeda/linux
Pull Rust updates from Miguel Ojeda: "Toolchain and infrastructure:
- Enable a set of Clippy lints: 'ptr_as_pt
Merge tag 'rust-6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/ojeda/linux
Pull Rust updates from Miguel Ojeda: "Toolchain and infrastructure:
- Enable a set of Clippy lints: 'ptr_as_ptr', 'ptr_cast_constness', 'as_ptr_cast_mut', 'as_underscore', 'cast_lossless' and 'ref_as_ptr'
These are intended to avoid type casts with the 'as' operator, which are quite powerful, into restricted variants that are less powerful and thus should help to avoid mistakes
- Remove the 'author' key now that most instances were moved to the plural one in the previous cycle
'kernel' crate:
- New 'bug' module: add 'warn_on!' macro which reuses the existing 'BUG'/'WARN' infrastructure, i.e. it respects the usual sysctls and kernel parameters:
warn_on!(value == 42);
To avoid duplicating the assembly code, the same strategy is followed as for the static branch code in order to share the assembly between both C and Rust
This required a few rearrangements on C arch headers -- the existing C macros should still generate the same outputs, thus no functional change expected there
- 'workqueue' module: add delayed work items, including a 'DelayedWork' struct, a 'impl_has_delayed_work!' macro and an 'enqueue_delayed' method, e.g.:
/// Enqueue the struct for execution on the system workqueue, /// where its value will be printed 42 jiffies later. fn print_later(value: Arc<MyStruct>) { let _ = workqueue::system().enqueue_delayed(value, 42); }
- New 'bits' module: add support for 'bit' and 'genmask' functions, with runtime- and compile-time variants, e.g.:
static_assert!(0b00010000 == bit_u8(4)); static_assert!(0b00011110 == genmask_u8(1..=4));
assert!(checked_bit_u32(u32::BITS).is_none());
- 'uaccess' module: add 'UserSliceReader::strcpy_into_buf', which reads NUL-terminated strings from userspace into a '&CStr'
Introduce 'UserPtr' newtype, similar in purpose to '__user' in C, to minimize mistakes handling userspace pointers, including mixing them up with integers and leaking them via the 'Debug' trait. Add it to the prelude, too
- Start preparations for the replacement of our custom 'CStr' type with the analogous type in the 'core' standard library. This will take place across several cycles to make it easier. For this one, it includes a new 'fmt' module, using upstream method names and some other cleanups
Replace 'fmt!' with a re-export, which helps Clippy lint properly, and clean up the found 'uninlined-format-args' instances
- 'dma' module:
- Clarify wording and be consistent in 'coherent' nomenclature
- Convert the 'read!()' and 'write!()' macros to return a 'Result'
- Add 'as_slice()', 'write()' methods in 'CoherentAllocation'
- Expose 'count()' and 'size()' in 'CoherentAllocation' and add the corresponding type invariants
- Implement 'CoherentAllocation::dma_handle_with_offset()'
- 'time' module:
- Make 'Instant' generic over clock source. This allows the compiler to assert that arithmetic expressions involving the 'Instant' use 'Instants' based on the same clock source
- Make 'HrTimer' generic over the timer mode. 'HrTimer' timers take a 'Duration' or an 'Instant' when setting the expiry time, depending on the timer mode. With this change, the compiler can check the type matches the timer mode
- Add an abstraction for 'fsleep'. 'fsleep' is a flexible sleep function that will select an appropriate sleep method depending on the requested sleep time
- Avoid 64-bit divisions on 32-bit hardware when calculating timestamps
- Seal the 'HrTimerMode' trait. This prevents users of the 'HrTimerMode' from implementing the trait on their own types
- Pass the correct timer mode ID to 'hrtimer_start_range_ns()'
- 'list' module: remove 'OFFSET' constants, allowing to remove pointer arithmetic; now 'impl_list_item!' invokes 'impl_has_list_links!' or 'impl_has_list_links_self_ptr!'. Other simplifications too
- 'types' module: remove 'ForeignOwnable::PointedTo' in favor of a constant, which avoids exposing the type of the opaque pointer, and require 'into_foreign' to return non-null
Remove the 'Either<L, R>' type as well. It is unused, and we want to encourage the use of custom enums for concrete use cases
- 'sync' module: implement 'Borrow' and 'BorrowMut' for 'Arc' types to allow them to be used in generic APIs
- 'alloc' module: implement 'Borrow' and 'BorrowMut' for 'Box<T, A>'; and 'Borrow', 'BorrowMut' and 'Default' for 'Vec<T, A>'
- 'Opaque' type: add 'cast_from' method to perform a restricted cast that cannot change the inner type and use it in callers of 'container_of!'. Rename 'raw_get' to 'cast_into' to match it
- 'rbtree' module: add 'is_empty' method
- 'sync' module: new 'aref' submodule to hold 'AlwaysRefCounted' and 'ARef', which are moved from the too general 'types' module which we want to reduce or eventually remove. Also fix a safety comment in 'static_lock_class'
'pin-init' crate:
- Add 'impl<T, E> [Pin]Init<T, E> for Result<T, E>', so results are now (pin-)initializers
- Add 'Zeroable::init_zeroed()' that delegates to 'init_zeroed()'
- New 'zeroed()', a safe version of 'mem::zeroed()' and also provide it via 'Zeroable::zeroed()'
- Implement 'Zeroable' for 'Option<&T>', 'Option<&mut T>' and for 'Option<[unsafe] [extern "abi"] fn(...args...) -> ret>' for '"Rust"' and '"C"' ABIs and up to 20 arguments
- Changed blanket impls of 'Init' and 'PinInit' from 'impl<T, E> [Pin]Init<T, E> for T' to 'impl<T> [Pin]Init<T> for T'
- Renamed 'zeroed()' to 'init_zeroed()'
- Upstream dev news: improve CI more to deny warnings, use '--all-targets'. Check the synchronization status of the two '-next' branches in upstream and the kernel
MAINTAINERS:
- Add Vlastimil Babka, Liam R. Howlett, Uladzislau Rezki and Lorenzo Stoakes as reviewers (thanks everyone)
And a few other cleanups and improvements"
* tag 'rust-6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/ojeda/linux: (76 commits) rust: Add warn_on macro arm64/bug: Add ARCH_WARN_ASM macro for BUG/WARN asm code sharing with Rust riscv/bug: Add ARCH_WARN_ASM macro for BUG/WARN asm code sharing with Rust x86/bug: Add ARCH_WARN_ASM macro for BUG/WARN asm code sharing with Rust rust: kernel: move ARef and AlwaysRefCounted to sync::aref rust: sync: fix safety comment for `static_lock_class` rust: types: remove `Either<L, R>` rust: kernel: use `core::ffi::CStr` method names rust: str: add `CStr` methods matching `core::ffi::CStr` rust: str: remove unnecessary qualification rust: use `kernel::{fmt,prelude::fmt!}` rust: kernel: add `fmt` module rust: kernel: remove `fmt!`, fix clippy::uninlined-format-args scripts: rust: emit path candidates in panic message scripts: rust: replace length checks with match rust: list: remove nonexistent generic parameter in link rust: bits: add support for bits/genmask macros rust: list: remove OFFSET constants rust: list: add `impl_list_item!` examples rust: list: use fully qualified path ...
show more ...
|
|
Revision tags: v6.16, v6.16-rc7, v6.16-rc6 |
|
| #
23b128bb |
| 11-Jul-2025 |
Lyude Paul <lyude@redhat.com> |
rust: time: Pass correct timer mode ID to hrtimer_start_range_ns
While rebasing rvkms I noticed that timers I was setting seemed to have pretty random timer values that amounted slightly over 2x the
rust: time: Pass correct timer mode ID to hrtimer_start_range_ns
While rebasing rvkms I noticed that timers I was setting seemed to have pretty random timer values that amounted slightly over 2x the time value I set each time. After a lot of debugging, I finally managed to figure out why: it seems that since we moved to Instant and Delta, we mistakenly began passing the clocksource ID to hrtimer_start_range_ns, when we should be passing the timer mode instead. Presumably, this works fine for simple relative timers - but immediately breaks on other types of timers.
So, fix this by passing the ID for the timer mode instead.
Signed-off-by: Lyude Paul <lyude@redhat.com> Acked-by: Andreas Hindborg <a.hindborg@kernel.org> Reviewed-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Fixes: e0c0ab04f678 ("rust: time: Make HasHrTimer generic over HrTimerMode") Link: https://lore.kernel.org/r/20250710225129.670051-1-lyude@redhat.com [ Removed cast, applied `rustfmt`, fixed `Fixes:` tag. - Miguel ] Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
show more ...
|
| #
77580e80 |
| 16-Jul-2025 |
Miguel Ojeda <ojeda@kernel.org> |
Merge tag 'rust-timekeeping-for-v6.17' of https://github.com/Rust-for-Linux/linux into rust-next
Pull timekeeping updates from Andreas Hindborg:
- Make 'Instant' generic over clock source. This al
Merge tag 'rust-timekeeping-for-v6.17' of https://github.com/Rust-for-Linux/linux into rust-next
Pull timekeeping updates from Andreas Hindborg:
- Make 'Instant' generic over clock source. This allows the compiler to assert that arithmetic expressions involving the 'Instant' use 'Instants' based on the same clock source.
- Make 'HrTimer' generic over the timer mode. 'HrTimer' timers take a 'Duration' or an 'Instant' when setting the expiry time, depending on the timer mode. With this change, the compiler can check the type matches the timer mode.
- Add an abstraction for 'fsleep'. 'fsleep' is a flexible sleep function that will select an appropriate sleep method depending on the requested sleep time.
- Avoid 64-bit divisions on 32-bit hardware when calculating timestamps.
- Seal the 'HrTimerMode' trait. This prevents users of the 'HrTimerMode' from implementing the trait on their own types.
* tag 'rust-timekeeping-for-v6.17' of https://github.com/Rust-for-Linux/linux: rust: time: Add wrapper for fsleep() function rust: time: Seal the HrTimerMode trait rust: time: Remove Ktime in hrtimer rust: time: Make HasHrTimer generic over HrTimerMode rust: time: Add HrTimerExpires trait rust: time: Replace HrTimerMode enum with trait-based mode types rust: time: Add ktime_get() to ClockSource trait rust: time: Make Instant generic over ClockSource rust: time: Replace ClockId enum with ClockSource trait rust: time: Avoid 64-bit integer division on 32-bit architectures
show more ...
|
|
Revision tags: v6.16-rc5, v6.16-rc4 |
|
| #
64fb810b |
| 24-Jun-2025 |
Alice Ryhl <aliceryhl@google.com> |
rust: types: rename Opaque::raw_get to cast_into
In the previous patch we added Opaque::cast_from() that performs the opposite operation to Opaque::raw_get(). For consistency with this naming, renam
rust: types: rename Opaque::raw_get to cast_into
In the previous patch we added Opaque::cast_from() that performs the opposite operation to Opaque::raw_get(). For consistency with this naming, rename raw_get() to cast_from().
There are a few other options such as calling cast_from() something closer to raw_get() rather than renaming this method. However, I could not find a great naming scheme that works with raw_get(). The previous version of this patch used from_raw(), but functions of that name typically have a different signature, so that's not a great option.
Suggested-by: Danilo Krummrich <dakr@kernel.org> Signed-off-by: Alice Ryhl <aliceryhl@google.com> Acked-by: Benno Lossin <lossin@kernel.org> Acked-by: Andreas Hindborg <a.hindborg@kernel.org> Acked-by: Boqun Feng <boqun.feng@gmail.com> Reviewed-by: Danilo Krummrich <dakr@kernel.org> Acked-by: Danilo Krummrich <dakr@kernel.org> Link: https://lore.kernel.org/r/20250624-opaque-from-raw-v2-2-e4da40bdc59c@google.com [ Removed `HrTimer::raw_get` change. - Miguel ] Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
show more ...
|
|
Revision tags: v6.16-rc3 |
|
| #
fc38b7ff |
| 18-Jun-2025 |
FUJITA Tomonori <fujita.tomonori@gmail.com> |
rust: time: Seal the HrTimerMode trait
Prevent downstream crates or drivers from implementing `HrTimerMode` for arbitrary types, which could otherwise leads to unsupported behavior.
Introduce a `pr
rust: time: Seal the HrTimerMode trait
Prevent downstream crates or drivers from implementing `HrTimerMode` for arbitrary types, which could otherwise leads to unsupported behavior.
Introduce a `private::Sealed` trait and implement it for all types that implement `HrTimerMode`.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Reviewed-by: Boqun Feng <boqun.feng@gmail.com> Link: https://lore.kernel.org/r/20250617232806.3950141-1-fujita.tomonori@gmail.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
|
Revision tags: v6.16-rc2 |
|
| #
69f66cf4 |
| 10-Jun-2025 |
FUJITA Tomonori <fujita.tomonori@gmail.com> |
rust: time: Remove Ktime in hrtimer
Remove the use of `Ktime` from the hrtimer code, which was originally introduced as a temporary workaround. The hrtimer has now been fully converted to use the `I
rust: time: Remove Ktime in hrtimer
Remove the use of `Ktime` from the hrtimer code, which was originally introduced as a temporary workaround. The hrtimer has now been fully converted to use the `Instant` and `Delta` types instead.
Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Link: https://lore.kernel.org/r/20250610132823.3457263-6-fujita.tomonori@gmail.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
e0c0ab04 |
| 10-Jun-2025 |
FUJITA Tomonori <fujita.tomonori@gmail.com> |
rust: time: Make HasHrTimer generic over HrTimerMode
Add a `TimerMode` associated type to the `HasHrTimer` trait to represent the operational mode of the timer, such as absolute or relative expirati
rust: time: Make HasHrTimer generic over HrTimerMode
Add a `TimerMode` associated type to the `HasHrTimer` trait to represent the operational mode of the timer, such as absolute or relative expiration. This new type must implement the `HrTimerMode` trait, which defines how expiration values are interpreted.
Update the `start()` method to accept an `expires` parameter of type `<Self::TimerMode as HrTimerMode>::Expires` instead of the fixed `Ktime`. This enables different timer modes to provide strongly typed expiration values, such as `Instant<C>` or `Delta`.
The `impl_has_hr_timer` macro is also extended to allow specifying the `HrTimerMode`. In the following example, it guarantees that the `start()` method for `Foo` only accepts `Instant<Monotonic>`. Using a `Delta` or an `Instant` with a different clock source will result in a compile-time error:
struct Foo { #[pin] timer: HrTimer<Self>, }
impl_has_hr_timer! { impl HasHrTimer<Self> for Foo { mode : AbsoluteMode<Monotonic>, field : self.timer } }
This design eliminates runtime mismatches between expires types and clock sources, and enables stronger type-level guarantees throughout hrtimer.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Link: https://lore.kernel.org/r/20250610132823.3457263-5-fujita.tomonori@gmail.com [ changed conversion method names to `as_*` - Andreas ] Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
d9fc00dc |
| 10-Jun-2025 |
FUJITA Tomonori <fujita.tomonori@gmail.com> |
rust: time: Add HrTimerExpires trait
Introduce the `HrTimerExpires` trait to represent types that can be used as expiration values for high-resolution timers. Define a required method, `into_nanos()
rust: time: Add HrTimerExpires trait
Introduce the `HrTimerExpires` trait to represent types that can be used as expiration values for high-resolution timers. Define a required method, `into_nanos()`, which returns the expiration time as a raw nanosecond value suitable for use with C's hrtimer APIs.
Also extend the `HrTimerMode` to use the `HrTimerExpires` trait.
This refactoring is a preparation for enabling hrtimer code to work uniformly with both absolute and relative expiration modes.
Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Link: https://lore.kernel.org/r/20250610132823.3457263-4-fujita.tomonori@gmail.com [ changed conversion method names to `as_*` - Andreas ] Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
ced9ccd2 |
| 10-Jun-2025 |
FUJITA Tomonori <fujita.tomonori@gmail.com> |
rust: time: Replace HrTimerMode enum with trait-based mode types
Replace the `HrTimerMode` enum with a trait-based approach that uses zero-sized types to represent each mode of operation. Each mode
rust: time: Replace HrTimerMode enum with trait-based mode types
Replace the `HrTimerMode` enum with a trait-based approach that uses zero-sized types to represent each mode of operation. Each mode now implements the `HrTimerMode` trait.
This refactoring is a preparation for replacing raw `Ktime` in HrTimer with the `Instant` and `Delta` types, and for making `HrTimer` generic over a `ClockSource`.
Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Link: https://lore.kernel.org/r/20250610132823.3457263-3-fujita.tomonori@gmail.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
1664a671 |
| 10-Jun-2025 |
FUJITA Tomonori <fujita.tomonori@gmail.com> |
rust: time: Replace ClockId enum with ClockSource trait
Replace the ClockId enum with a trait-based abstraction called ClockSource. This change enables expressing clock sources as types and leveragi
rust: time: Replace ClockId enum with ClockSource trait
Replace the ClockId enum with a trait-based abstraction called ClockSource. This change enables expressing clock sources as types and leveraging the Rust type system to enforce clock correctness at compile time.
This also sets the stage for future generic abstractions over Instant types such as Instant<C>.
Reviewed-by: Andreas Hindborg <a.hindborg@kernel.org> Reviewed-by: Boqun Feng <boqun.feng@gmail.com> Signed-off-by: FUJITA Tomonori <fujita.tomonori@gmail.com> Link: https://lore.kernel.org/r/20250610093258.3435874-2-fujita.tomonori@gmail.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
show more ...
|
| #
e9ef810d |
| 31-Jul-2025 |
Jiri Kosina <jkosina@suse.com> |
Merge branch 'for-6.17/amd-sfh' into for-linus
- add support for operating modes (Basavaraj Natikar)
|
| #
61b8c39d |
| 07-Jul-2025 |
Sebastian Reichel <sebastian.reichel@collabora.com> |
Merge tag 'pm-runtime-6.17-rc1'
Runtime PM updates related to autosuspend for 6.17
Make several autosuspend functions mark last busy stamp and update the documentation accordingly (Sakari Ailus).
Merge tag 'pm-runtime-6.17-rc1'
Runtime PM updates related to autosuspend for 6.17
Make several autosuspend functions mark last busy stamp and update the documentation accordingly (Sakari Ailus).
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
show more ...
|
| #
c833e8cc |
| 23-Jun-2025 |
Namhyung Kim <namhyung@kernel.org> |
Merge tag 'v6.16-rc3' into perf-tools-next
To get the fixes in libbpf and perf tools.
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
|