diff options
| author | Lyude Paul <[email protected]> | 2025-07-10 22:51:13 +0000 |
|---|---|---|
| committer | Miguel Ojeda <[email protected]> | 2025-07-16 22:55:35 +0000 |
| commit | 23b128bba76776541dc09efaf3acf6242917e1f0 (patch) | |
| tree | 88549dff21d1c65d1b738307246c571986b16249 /scripts/rustdoc_test_gen.rs | |
| parent | Merge tag 'rust-timekeeping-for-v6.17' of https://github.com/Rust-for-Linux/l... (diff) | |
| download | kernel-23b128bba76776541dc09efaf3acf6242917e1f0.tar.gz kernel-23b128bba76776541dc09efaf3acf6242917e1f0.zip | |
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 <[email protected]>
Acked-by: Andreas Hindborg <[email protected]>
Reviewed-by: FUJITA Tomonori <[email protected]>
Fixes: e0c0ab04f678 ("rust: time: Make HasHrTimer generic over HrTimerMode")
Link: https://lore.kernel.org/r/[email protected]
[ Removed cast, applied `rustfmt`, fixed `Fixes:` tag. - Miguel ]
Signed-off-by: Miguel Ojeda <[email protected]>
Diffstat (limited to 'scripts/rustdoc_test_gen.rs')
0 files changed, 0 insertions, 0 deletions
