linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 0/2] Add read_poll_timeout_atomic support
@ 2025-08-21  3:57 FUJITA Tomonori
  2025-08-21  3:57 ` [PATCH v1 1/2] rust: add udelay() function FUJITA Tomonori
  2025-08-21  3:57 ` [PATCH v1 2/2] rust: Add read_poll_timeout_atomic function FUJITA Tomonori
  0 siblings, 2 replies; 22+ messages in thread
From: FUJITA Tomonori @ 2025-08-21  3:57 UTC (permalink / raw)
  To: a.hindborg, alex.gaynor, ojeda
  Cc: aliceryhl, anna-maria, bjorn3_gh, boqun.feng, dakr, frederic,
	gary, jstultz, linux-kernel, lossin, lyude, rust-for-linux, sboyd,
	tglx, tmgross, acourbot, daniel.almeida

Add a helper function, read_poll_timeout_atomic() to poll periodically
until a condition is met or a timeout is reached.

Unlike read_poll_timeout(), read_poll_timeout_atomic() performs
busy-wait so it can be used in an atomic context.

This patchset can be applied on top of the read_poll_timeout patchset (v3) [1].

[1] https://lore.kernel.org/lkml/20250821002055.3654160-1-fujita.tomonori@gmail.com/

FUJITA Tomonori (2):
  rust: add udelay() function
  rust: Add read_poll_timeout_atomic function

 rust/helpers/time.c       |  5 +++
 rust/kernel/io/poll.rs    | 90 ++++++++++++++++++++++++++++++++++++++-
 rust/kernel/time/delay.rs | 34 +++++++++++++++
 3 files changed, 128 insertions(+), 1 deletion(-)


base-commit: a3b971f57db41ef1c68f842cd3c2c00b3df54ce4
-- 
2.43.0


^ permalink raw reply	[flat|nested] 22+ messages in thread

end of thread, other threads:[~2025-08-27 12:36 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-21  3:57 [PATCH v1 0/2] Add read_poll_timeout_atomic support FUJITA Tomonori
2025-08-21  3:57 ` [PATCH v1 1/2] rust: add udelay() function FUJITA Tomonori
2025-08-26  9:09   ` Andreas Hindborg
2025-08-26 11:59     ` FUJITA Tomonori
2025-08-26 18:03       ` Miguel Ojeda
2025-08-27  7:12         ` Andreas Hindborg
2025-08-26 12:44   ` Daniel Almeida
2025-08-27  2:43     ` FUJITA Tomonori
2025-08-21  3:57 ` [PATCH v1 2/2] rust: Add read_poll_timeout_atomic function FUJITA Tomonori
2025-08-26 14:02   ` Daniel Almeida
2025-08-27  0:35     ` FUJITA Tomonori
2025-08-27  4:32       ` FUJITA Tomonori
2025-08-26 14:12   ` Danilo Krummrich
2025-08-26 16:59     ` Daniel Almeida
2025-08-26 17:15       ` Danilo Krummrich
2025-08-27  0:14     ` FUJITA Tomonori
2025-08-27  9:00       ` Danilo Krummrich
2025-08-27 10:29         ` Danilo Krummrich
2025-08-27 12:14           ` Daniel Almeida
2025-08-27 12:19             ` Danilo Krummrich
2025-08-27 12:22               ` Daniel Almeida
2025-08-27 12:36                 ` Danilo Krummrich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).