Re: [PATCH 6/7] rust: workqueue: add Work::cancel_work_sync()
John Hubbard <[email protected]>
| Newsgroups | org.kernel.vger.rust-for-linux,dev.linux.lists.driver-core,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On 8/7/26 4:49 AM, Danilo Krummrich wrote: > On Fri Aug 7, 2026 at 3:37 AM CEST, John Hubbard wrote: >> This seems to expose a way for driver writers to leak work items, >> doesn't it? > > Yes, I forgot about this for a second; this should be on ScopedWork only (at > least without further effort to make it work properly for Work too). > > Since you explicitly mention "driver writers", note that unbounded work > shouldn't really have any (valid) use-cases within drivers. So drivers should > either use ScopedQueue or ScopedWork. Yes, agreed. Perhaps I shouldn't have used "drivers" as the example. I was just trying to show that this exposes an API that will leak refcounts. thanks, -- John Hubbard