From: "Danilo Krummrich" <dakr@kernel.org>
To: "Alice Ryhl" <aliceryhl@google.com>
Cc: "Tejun Heo" <tj@kernel.org>, "Miguel Ojeda" <ojeda@kernel.org>,
"Lai Jiangshan" <jiangshanlai@gmail.com>,
"Boqun Feng" <boqun.feng@gmail.com>,
"Gary Guo" <gary@garyguo.net>,
"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
"Andreas Hindborg" <a.hindborg@kernel.org>,
"Trevor Gross" <tmgross@umich.edu>,
"Daniel Almeida" <daniel.almeida@collabora.com>,
"Tamir Duberstein" <tamird@gmail.com>,
rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org,
"Benno Lossin" <lossin@kernel.org>
Subject: Re: [PATCH v3] workqueue: rust: add delayed work items
Date: Fri, 11 Jul 2025 16:07:04 +0200 [thread overview]
Message-ID: <DB9A8OPZK3DZ.YVQPQQSD12MU@kernel.org> (raw)
In-Reply-To: <20250711-workqueue-delay-v3-1-3fe17b18b9d1@google.com>
Hi Alice,
On Fri Jul 11, 2025 at 9:59 AM CEST, Alice Ryhl wrote:
> This patch is being sent for use in the various Rust GPU drivers that
> are under development. It provides the additional feature of work items
> that are executed after a delay.
I thought I commented on this in a previous version already, but apparently I
haven't (was it a different thread maybe?).
For drivers, we should also support 'scoped' work items and worqueues, where
'scoped' means limit the lifetime to the driver being bound to a device.
For better understanding, in C one would call this devm_alloc_workqueue(), which
would guarantee that the workqueue is terminated on device unbind. Similar for
individual work items on shared workqueues (such as the system ones), which
would be canceled synchronously on driver unbind.
This is very useful for drivers, since it allows to provide a &Device<Bound>
within the work's callback, which allows drivers to access device resources
safely and directly without additional overhead.
next prev parent reply other threads:[~2025-07-11 14:07 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-11 7:59 [PATCH v3] workqueue: rust: add delayed work items Alice Ryhl
2025-07-11 14:07 ` Danilo Krummrich [this message]
2025-07-11 14:17 ` Boqun Feng
2025-07-14 10:45 ` Alice Ryhl
2025-07-16 22:49 ` 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=DB9A8OPZK3DZ.YVQPQQSD12MU@kernel.org \
--to=dakr@kernel.org \
--cc=a.hindborg@kernel.org \
--cc=aliceryhl@google.com \
--cc=bjorn3_gh@protonmail.com \
--cc=boqun.feng@gmail.com \
--cc=daniel.almeida@collabora.com \
--cc=gary@garyguo.net \
--cc=jiangshanlai@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lossin@kernel.org \
--cc=ojeda@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=tamird@gmail.com \
--cc=tj@kernel.org \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.