[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANiq72mVuPex3fLd5n8jMtU30QStLs=vhsChENdX1hGhA4KKpg@mail.gmail.com>
Date: Thu, 5 Jun 2025 19:22:51 +0200
From: Miguel Ojeda <miguel.ojeda.sandonis@...il.com>
To: Christian Schrefl <chrisi.schrefl@...il.com>
Cc: Sky <sky@...9.dev>, Miguel Ojeda <ojeda@...nel.org>, Alex Gaynor <alex.gaynor@...il.com>,
Boqun Feng <boqun.feng@...il.com>, Gary Guo <gary@...yguo.net>,
Björn Roy Baron <bjorn3_gh@...tonmail.com>,
Benno Lossin <benno.lossin@...ton.me>, Andreas Hindborg <a.hindborg@...nel.org>,
Alice Ryhl <aliceryhl@...gle.com>, Trevor Gross <tmgross@...ch.edu>,
Danilo Krummrich <dakr@...nel.org>, Gerald Wisböck <gerald.wisboeck@...ther.ink>,
Nathan Chancellor <nathan@...nel.org>, Nick Desaulniers <nick.desaulniers+lkml@...il.com>,
Bill Wendling <morbo@...gle.com>, Justin Stitt <justinstitt@...gle.com>, linux-kernel@...r.kernel.org,
rust-for-linux@...r.kernel.org, llvm@...ts.linux.dev
Subject: Re: [PATCH v4 1/3] rust: add UnsafePinned type
On Thu, Jun 5, 2025 at 7:03 PM Christian Schrefl
<chrisi.schrefl@...il.com> wrote:
>
> The upstream rust PR [0] that changes this was just merged. So now `UnsafePinned` includes
> `UnsafeCell` semantics. It's probably best to also change this in the kernel docs.
> Though it's still the case that removing the guarantee is simpler than adding it back later,
> so let me know what you all think.
Since upstream's will imply `UnsafeCell`, then I assume they will not
take it away, and thus we should just document it the same way, so
that eventually we can just alias the upstream one.
But that last part can only happen in a long time, when our minimum
upgrades past 1.89, since otherwise we would lose the `UnsafeCell`
with an alias.
If we really wanted a type that does not do that, then we could have
another one, with a different name.
Thanks!
(By the way, please try to trim unneeded quotes in replies; otherwise,
threads become harder to read in clients such as lore.kernel.org, and
it also becomes harder to reply)
Cheers,
Miguel
Powered by blists - more mailing lists