diff options
| author | Alice Ryhl <aliceryhl@google.com> | 2025-12-18 08:25:13 +0000 |
|---|---|---|
| committer | Boqun Feng <boqun.feng@gmail.com> | 2026-01-09 19:01:40 +0800 |
| commit | 09248ed8cdb6345afc883c02aecd79dfbd9c2a9c (patch) | |
| tree | bad3473cd049a6a743193f9874e88ab39f004503 /tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git | |
| parent | 8a581130b1cbc17c702298b8325e3df98c792760 (diff) | |
rust: sync: Implement Unpin for ARef
The default implementation of Unpin for ARef<T> is conditional on T
being Unpin due to its PhantomData<T> field. However, this is overly
strict as pointers to T are legal to move even if T itself cannot move.
Since commit 66f1ea83d9f8 ("rust: lock: Add a Pin<&mut T> accessor")
this causes build failures when combined with a Mutex that contains an
field ARef<T>, because almost any type that ARef is used with is !Unpin.
Reviewed-by: Daniel Almeida <daniel.almeida@collabora.com>
Signed-off-by: Alice Ryhl <aliceryhl@google.com>
Reviewed-by: Alexandre Courbot <acourbot@nvidia.com>
Reviewed-by: Benno Lossin <lossin@kernel.org>
Signed-off-by: Boqun Feng <boqun.feng@gmail.com>
Link: https://patch.msgid.link/20251218-unpin-for-aref-v2-1-30d77129cbc6@google.com
Diffstat (limited to 'tools/perf/lib/Documentation/tutorial/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions
