rust-for-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Philipp Stanner <phasta@mailbox.org>
To: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>,
	Philipp Stanner <phasta@kernel.org>
Cc: "Miguel Ojeda" <ojeda@kernel.org>,
	"Alex Gaynor" <alex.gaynor@gmail.com>,
	"Boqun Feng" <boqun.feng@gmail.com>,
	"Gary Guo" <gary@garyguo.net>,
	"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
	"Benno Lossin" <lossin@kernel.org>,
	"Andreas Hindborg" <a.hindborg@kernel.org>,
	"Alice Ryhl" <aliceryhl@google.com>,
	"Trevor Gross" <tmgross@umich.edu>,
	"Danilo Krummrich" <dakr@kernel.org>,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	"Viresh Kumar" <viresh.kumar@linaro.org>,
	"Tamir Duberstein" <tamird@gmail.com>,
	rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] rust: lib: Add necessary unsafes for container_of
Date: Mon, 17 Nov 2025 07:36:36 +0100	[thread overview]
Message-ID: <7146fee26e0d24d0998e9a9199d9ef3ba842e0a8.camel@mailbox.org> (raw)
In-Reply-To: <CANiq72m_wGhXqu9es=zOcDbK4UqAiSbn5bBLhjDewXV3=4ckmA@mail.gmail.com>

On Fri, 2025-11-14 at 21:21 +0100, Miguel Ojeda wrote:
> On Fri, Nov 14, 2025 at 3:00 PM Philipp Stanner <phasta@kernel.org> wrote:
> > 
> > Add unsafe blocks to container_of to fix the issue.
> 
> The root issue is that we missed unsafe blocks on the list macros
> because imported declarative macros from another crate do not respect
> `unsafe_op_in_unsafe_fn` (or Edition 2024):
> 
>     https://github.com/rust-lang/rust/issues/112504
> 
> I have added it to our list at:
> 
>     https://github.com/Rust-for-Linux/linux/issues/355
> 
> And tagged it with the Rust for Linux label there.

So shall we in the mean time merge a fix as suggested by Alice, IOW a
version 2 of this patch here?

P.


  reply	other threads:[~2025-11-17  6:36 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-14 14:00 [PATCH] rust: lib: Add necessary unsafes for container_of Philipp Stanner
2025-11-14 14:14 ` Alice Ryhl
2025-11-17  8:24   ` Philipp Stanner
2025-11-17  8:59     ` Miguel Ojeda
2025-11-14 20:21 ` Miguel Ojeda
2025-11-17  6:36   ` Philipp Stanner [this message]
2025-11-17  6: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=7146fee26e0d24d0998e9a9199d9ef3ba842e0a8.camel@mailbox.org \
    --to=phasta@mailbox.org \
    --cc=a.hindborg@kernel.org \
    --cc=alex.gaynor@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=dakr@kernel.org \
    --cc=gary@garyguo.net \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lossin@kernel.org \
    --cc=miguel.ojeda.sandonis@gmail.com \
    --cc=ojeda@kernel.org \
    --cc=phasta@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=tamird@gmail.com \
    --cc=tmgross@umich.edu \
    --cc=viresh.kumar@linaro.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).