Rust for Linux List
 help / color / mirror / Atom feed
From: "Gary Guo" <gary@garyguo.net>
To: "Miguel Ojeda" <ojeda@kernel.org>
Cc: "Boqun Feng" <boqun@kernel.org>, "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>,
	"Daniel Almeida" <daniel.almeida@collabora.com>,
	"Tamir Duberstein" <tamird@kernel.org>,
	"Alexandre Courbot" <acourbot@nvidia.com>,
	"Onur Özkan" <work@onurozkan.dev>,
	rust-for-linux@vger.kernel.org,
	"Joshua Liebow-Feeser" <joshlf@google.com>,
	"Jack Wrenn" <jswrenn@google.com>
Subject: Re: [PATCH] rust: zerocopy: update to v0.8.54
Date: Thu, 09 Jul 2026 22:58:25 +0100	[thread overview]
Message-ID: <DJUDLC05V895.2BR44YV9G2WAD@garyguo.net> (raw)
In-Reply-To: <20260709211311.142544-1-ojeda@kernel.org>

On Thu Jul 9, 2026 at 10:13 PM BST, Miguel Ojeda wrote:
> Update our vendored copy of `zerocopy` (and `zerocopy-derive`) to v0.8.54.
> 
> It is a very small delta from v0.8.52, and most importantly it resolves
> the unexpected lack of inlining [1] which triggered a modpost error
> under `CONFIG_CC_OPTIMIZE_FOR_SIZE=y` reported by Alexandre using Gary's
> suggestion [2]:
> 
>     ERROR: modpost: "_RNvMNtCs5wX7wwEUCR9_8zerocopy6layoutNtB2_8SizeInfo24try_to_nonzero_elem_size" [drivers/gpu/nova-core.ko] undefined!
>     ERROR: modpost: "_RNvNtCs5wX7wwEUCR9_8zerocopy4util18padding_needed_for" [drivers/gpu/nova-core.ko] undefined!
> 
> It also resolves `most_traits` being unexpectedly documented [3] that I
> reported and adds a missing SPDX license identifier [4] that I requested
> to match the kernel version.
> 
> The following script may be used to check for the remaining differences:
> 
>     for path in $(cd rust/zerocopy-derive/ && find . -type f ! -name README.md); do
>         curl --silent --show-error --location \
>             https://github.com/google/zerocopy/raw/v0.8.54/zerocopy/zerocopy-derive/src/$path |
>             git diff --no-index - rust/zerocopy-derive/$path &&
>             echo $path: OK
>     done
> 
>     for path in $(cd rust/zerocopy/ && find . -type f ! -name README.md); do
>         curl --silent --show-error --location \
>             https://github.com/google/zerocopy/raw/v0.8.54/zerocopy/$path |
>             git diff --no-index - rust/zerocopy/$path &&
>             echo $path: OK
>     done
> 
> Cc: Joshua Liebow-Feeser <joshlf@google.com>
> Cc: Jack Wrenn <jswrenn@google.com>
> Reported-by: Alexandre Courbot <acourbot@nvidia.com>
> Link: https://lore.kernel.org/rust-for-linux/20260708-zerocopy-export-v1-1-2bfc355853c6@nvidia.com/ [1]
> Suggested-by: Gary Guo <gary@garyguo.net>
> Link: https://lore.kernel.org/rust-for-linux/DJT6235B3DOV.222XR5O6VHG4M@garyguo.net/ [2]
> Link: https://github.com/google/zerocopy/issues/3466 [3]
> Link: https://github.com/google/zerocopy/issues/3457 [4]
> Signed-off-by: Miguel Ojeda <ojeda@kernel.org>

Reviewed-by: Gary Guo <gary@garyguo.net>

> ---
> This goes on top of the v0.8.52 one:
> 
>   https://lore.kernel.org/rust-for-linux/20260625231919.692444-1-ojeda@kernel.org/
> 
> I may land both in `rust-fixes`, especially if someone else can confirm
> it works for them (I reproduced Alexandre's issue and this does indeed
> solve it).
> 
>  rust/Makefile                   |  2 +-
>  rust/zerocopy-derive/README.md  | 12 ++++++------
>  rust/zerocopy-derive/lib.rs     |  2 +-
>  rust/zerocopy/README.md         | 12 ++++++------
>  rust/zerocopy/rustdoc/style.css |  1 -
>  rust/zerocopy/src/byteorder.rs  |  1 +
>  rust/zerocopy/src/layout.rs     |  2 ++
>  rust/zerocopy/src/lib.rs        |  1 -
>  rust/zerocopy/src/util/mod.rs   |  6 ++++++
>  9 files changed, 23 insertions(+), 16 deletions(-)


  reply	other threads:[~2026-07-09 21:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-09 21:13 [PATCH] rust: zerocopy: update to v0.8.54 Miguel Ojeda
2026-07-09 21:58 ` Gary Guo [this message]
2026-07-10  6:10 ` Alexandre Courbot
2026-07-10  7:49 ` Alice Ryhl
2026-07-10 16:46 ` 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=DJUDLC05V895.2BR44YV9G2WAD@garyguo.net \
    --to=gary@garyguo.net \
    --cc=a.hindborg@kernel.org \
    --cc=acourbot@nvidia.com \
    --cc=aliceryhl@google.com \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun@kernel.org \
    --cc=dakr@kernel.org \
    --cc=daniel.almeida@collabora.com \
    --cc=joshlf@google.com \
    --cc=jswrenn@google.com \
    --cc=lossin@kernel.org \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=tamird@kernel.org \
    --cc=tmgross@umich.edu \
    --cc=work@onurozkan.dev \
    /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