Re: [PATCH v3 4/9] rust: workqueue: add low-level workqueue bindings

From: Alice Ryhl
Date: Mon Jul 17 2023 - 09:53:23 EST


Boqun Feng <boqun.feng@xxxxxxxxx> writes:
>> +// SAFETY: Kernel workqueues are usable from any thread.
>> +unsafe impl Send for Queue {}
>> +unsafe impl Sync for Queue {}
>
> I don't think "usable from any thread" is the accurate wording here, it
> sounds to me that there are types that cannot be used for a particular
> type of threads ;-)
>
> Maybe
>
> // SAFETY: Accesses to workqueues used by [`Queue`] are
> // thread-safe.
>
> ?

Sure, I'll make that change in the next version.

Alice