Rust for Linux List
 help / color / mirror / Atom feed
From: Andreas Hindborg <a.hindborg@kernel.org>
To: "FUJITA Tomonori" <fujita.tomonori@gmail.com>
Cc: <lyude@redhat.com>,  <rust-for-linux@vger.kernel.org>,
	<boqun.feng@gmail.com>,  <frederic@kernel.org>,
	 <tglx@linutronix.de>, <anna-maria@linutronix.de>,
	 <jstultz@google.com>,  <sboyd@kernel.org>, <ojeda@kernel.org>,
	 <alex.gaynor@gmail.com>,  <gary@garyguo.net>,
	<bjorn3_gh@protonmail.com>,  <lossin@kernel.org>,
	<aliceryhl@google.com>,  <tmgross@umich.edu>,  <dakr@kernel.org>,
	<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] rust: time: Pass correct timer mode ID to hrtimer_start_range_ns
Date: Fri, 11 Jul 2025 08:49:01 +0200	[thread overview]
Message-ID: <87ecuni5nm.fsf@kernel.org> (raw)
In-Reply-To: <20250711.153729.1327324726276230605.fujita.tomonori@gmail.com> (FUJITA Tomonori's message of "Fri, 11 Jul 2025 15:37:29 +0900")

"FUJITA Tomonori" <fujita.tomonori@gmail.com> writes:

> On Fri, 11 Jul 2025 08:18:37 +0200
> Andreas Hindborg <a.hindborg@kernel.org> wrote:
>
>> "Lyude Paul" <lyude@redhat.com> writes:
>>
>>> 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>
>>> Cc: FUJITA Tomonori <fujita.tomonori@gmail.com>
>>> Fixes: fcc1dd8c8656 ("rust: time: Make HasHrTimer generic over HrTimerMode")
>>
>> Wow, thanks! Miguel, can you take this through rust-fixes?
>
> I think that this patch fixes the commit in timekeeping-next.
>
> `fcc1dd8c8656` doesn't match to the commit in the current
> timekeeping-next (this patch might have been made against the tree
> before it was rebased).

Maybe Miguel can put the correct hash when he applies the patch.


Best regards,
Andreas Hindborg



  reply	other threads:[~2025-07-11  6:49 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <U1GgPfpPwSjzh5jPpFlN22bT2BSjlaH8vLHYY6hAt_vJ5w4irwIYRPV46r73Cs5Dx73Ikz5ku7_qPWrl8Tntfw==@protonmail.internalid>
2025-07-10 22:51 ` [PATCH] rust: time: Pass correct timer mode ID to hrtimer_start_range_ns Lyude Paul
2025-07-11  6:18   ` Andreas Hindborg
2025-07-11  6:37     ` FUJITA Tomonori
2025-07-11  6:49       ` Andreas Hindborg [this message]
2025-07-11  9:53         ` Miguel Ojeda
2025-07-11  6:28   ` FUJITA Tomonori
2025-07-17  0:05   ` Miguel Ojeda

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=87ecuni5nm.fsf@kernel.org \
    --to=a.hindborg@kernel.org \
    --cc=alex.gaynor@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=anna-maria@linutronix.de \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun.feng@gmail.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