Linux kernel -stable discussions
 help / color / mirror / Atom feed
From: Danilo Krummrich <dakr@kernel.org>
To: Christian Schrefl <chrisi.schrefl@gmail.com>
Cc: "Luis Chamberlain" <mcgrof@kernel.org>,
	"Russ Weight" <russ.weight@linux.dev>,
	"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" <benno.lossin@proton.me>,
	"Andreas Hindborg" <a.hindborg@kernel.org>,
	"Alice Ryhl" <aliceryhl@google.com>,
	"Trevor Gross" <tmgross@umich.edu>,
	linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org,
	stable@vger.kernel.org
Subject: Re: [PATCH] rust: fix building firmware abstraction on 32bit arm
Date: Fri, 11 Apr 2025 16:17:06 +0200	[thread overview]
Message-ID: <Z_kkYsLNiZ_t4z5b@cassiopeiae> (raw)
In-Reply-To: <99070274-4891-411a-89e1-420ca4d5d0fb@gmail.com>

On Fri, Apr 11, 2025 at 03:47:28PM +0200, Christian Schrefl wrote:
> On 11.04.25 12:35 PM, Danilo Krummrich wrote:
> > On Fri, Apr 11, 2025 at 09:14:48AM +0200, Christian Schrefl wrote:
> > I did a test build with multi_v7_defconfig and I can't reproduce this issue.
> > 
> Interesting, I've it seems this is only an issue on 6.13 with my arm patches applied.
> 
> It seems that it works on v6.14 and v6.15-rc1 but the error occurs on ffd294d346d1 (tag: v6.13)
> with my 32-bit arm patches applied.

That makes sense, commit 1bae8729e50a ("rust: map `long` to `isize` and `char`
to `u8`") changed FwFunc to take a *const u8, which previously was *const i8.

> >> diff --git a/rust/kernel/firmware.rs b/rust/kernel/firmware.rs
> >> index f04b058b09b2d2397e26344d0e055b3aa5061432..1d6284316f2a4652ef3f76272670e5e29b0ff924 100644
> >> --- a/rust/kernel/firmware.rs
> >> +++ b/rust/kernel/firmware.rs
> >> @@ -5,14 +5,18 @@
> >>  //! C header: [`include/linux/firmware.h`](srctree/include/linux/firmware.h)
> >>  
> >>  use crate::{bindings, device::Device, error::Error, error::Result, str::CStr};
> >> -use core::ptr::NonNull;
> >> +use core::{ffi, ptr::NonNull};
> > 
> > The change itself seems to be fine anyways, but I think we should use crate::ffi
> > instead.
> Right, I just did what RA recommended without thinking about it much.
> 
> I guess this patch isn't really needed. Should I still send a V2 using `crate::ffi`?

Yes, please. I think it's still an improvement.

  reply	other threads:[~2025-04-11 14:17 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-11  7:14 [PATCH] rust: fix building firmware abstraction on 32bit arm Christian Schrefl
2025-04-11  8:37 ` Benno Lossin
2025-04-11 10:35 ` Danilo Krummrich
2025-04-11 13:47   ` Christian Schrefl
2025-04-11 14:17     ` Danilo Krummrich [this message]
2025-04-11 12:45 ` Benno Lossin
2025-04-11 14:15   ` Miguel Ojeda
2025-04-11 14:18     ` Miguel Ojeda
2025-04-12 10:01     ` Benno Lossin
2025-04-14 14:05       ` Alice Ryhl
2025-04-14 14:52         ` Benno Lossin

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=Z_kkYsLNiZ_t4z5b@cassiopeiae \
    --to=dakr@kernel.org \
    --cc=a.hindborg@kernel.org \
    --cc=alex.gaynor@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=benno.lossin@proton.me \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=chrisi.schrefl@gmail.com \
    --cc=gary@garyguo.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mcgrof@kernel.org \
    --cc=ojeda@kernel.org \
    --cc=russ.weight@linux.dev \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=tmgross@umich.edu \
    /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