rust-for-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Joel Fernandes <joelagnelf@nvidia.com>
To: Alexandre Courbot <acourbot@nvidia.com>,
	linux-kernel@vger.kernel.org, rust-for-linux@vger.kernel.org,
	dri-devel@lists.freedesktop.org, dakr@kernel.org
Cc: Alistair Popple <apopple@nvidia.com>,
	Miguel Ojeda <ojeda@kernel.org>,
	Alex Gaynor <alex.gaynor@gmail.com>,
	Boqun Feng <boqun.feng@gmail.com>, Gary Guo <gary@garyguo.net>,
	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>,
	David Airlie <airlied@gmail.com>, Simona Vetter <simona@ffwll.ch>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	John Hubbard <jhubbard@nvidia.com>, Timur Tabi <ttabi@nvidia.com>,
	joel@joelfernandes.org, Elle Rhumsaa <elle@weathered-steel.dev>,
	Yury Norov <yury.norov@gmail.com>,
	Daniel Almeida <daniel.almeida@collabora.com>,
	Andrea Righi <arighi@nvidia.com>,
	nouveau@lists.freedesktop.org
Subject: Re: [PATCH v5 0/9] Introduce bitfield and move register macro to rust/kernel/
Date: Fri, 3 Oct 2025 11:26:30 -0400	[thread overview]
Message-ID: <4f6ac8e8-3dee-46c3-b3a6-992bdb0225f8@nvidia.com> (raw)
In-Reply-To: <DD7G18DF6PJ2.2E1N4DXGT83KL@nvidia.com>

On 10/1/2025 9:26 PM, Alexandre Courbot wrote:
> On Thu Oct 2, 2025 at 10:24 AM JST, Alexandre Courbot wrote:
>> On Tue Sep 30, 2025 at 11:45 PM JST, Joel Fernandes wrote:
>>> Hello!
>>>
>>> These patches extract and enhance the bitfield support in the register macro in
>>> nova to define Rust structures with bitfields. It then moves out the bitfield
>>> support into the kenrel crate and further enhances it. This is extremely useful
>>> as it allows clean Rust structure definitions without requiring explicit masks
>>> and shifts.
>>
>> The extraction and move in themselves (patches 1-4 and maybe the KUNIT
>> one) look good to me. For the remainder, it will depend on whether the
>> BoundedInt idea sticks or not as it changes the design in a way that
>> makes most of these patches unneeded. In any case I think this can be
>> worked on after the split and extraction.

Sure.

>>
>> Patch 5 should probably be dropped as it has the potential to clear
>> register fields that are useful to the hardware but have no entry in the
>> `register!` definition, making read-update-write updates of registers
>> unpredictable.
> 
> Ah, I forgot: please base the next revision on top of drm-rust-next as
> we are likely to apply it there.

Done, I rebased on top of drm-rust-next, commit: 299eb32863e5 ("gpu: nova-core:
Add base files for r570.144 firmware bindings")

I will send the v6 out shortly with just the patches to be included.

Thanks.

      reply	other threads:[~2025-10-03 15:26 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-30 14:45 [PATCH v5 0/9] Introduce bitfield and move register macro to rust/kernel/ Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 1/9] nova-core: bitfield: Move bitfield-specific code from register! into new macro Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 2/9] nova-core: bitfield: Add support for different storage widths Joel Fernandes
2025-09-30 17:18   ` Joel Fernandes
2025-10-02  1:17   ` Alexandre Courbot
2025-09-30 14:45 ` [PATCH v5 3/9] nova-core: bitfield: Add support for custom visiblity Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 4/9] rust: Move register and bitfield macros out of Nova Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 5/9] rust: bitfield: Add a new() constructor and raw() accessor Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 6/9] rust: bitfield: Add KUNIT tests for bitfield Joel Fernandes
2025-10-02  1:41   ` Alexandre Courbot
2025-10-02  2:16     ` Elle Rhumsaa
2025-10-02  2:51       ` Alexandre Courbot
2025-10-02  3:35         ` Elle Rhumsaa
2025-10-03 15:23     ` Joel Fernandes
2025-10-04  0:38       ` Alexandre Courbot
2025-10-04 16:14         ` Joel Fernandes
2025-10-06 16:40           ` Miguel Ojeda
2025-10-06 19:50             ` Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 7/9] rust: bitfield: Use 'as' operator for setter type conversion Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 8/9] rust: bitfield: Add hardening for out of bounds access Joel Fernandes
2025-09-30 18:03   ` Yury Norov
2025-09-30 22:06     ` Joel Fernandes
2025-09-30 14:45 ` [PATCH v5 9/9] rust: bitfield: Add hardening for undefined bits Joel Fernandes
2025-09-30 15:08 ` [PATCH v5 0/9] Introduce bitfield and move register macro to rust/kernel/ Danilo Krummrich
2025-10-02  1:24 ` Alexandre Courbot
2025-10-02  1:26   ` Alexandre Courbot
2025-10-03 15:26     ` Joel Fernandes [this message]

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=4f6ac8e8-3dee-46c3-b3a6-992bdb0225f8@nvidia.com \
    --to=joelagnelf@nvidia.com \
    --cc=a.hindborg@kernel.org \
    --cc=acourbot@nvidia.com \
    --cc=airlied@gmail.com \
    --cc=alex.gaynor@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=apopple@nvidia.com \
    --cc=arighi@nvidia.com \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun.feng@gmail.com \
    --cc=dakr@kernel.org \
    --cc=daniel.almeida@collabora.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=elle@weathered-steel.dev \
    --cc=gary@garyguo.net \
    --cc=jhubbard@nvidia.com \
    --cc=joel@joelfernandes.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lossin@kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mripard@kernel.org \
    --cc=nouveau@lists.freedesktop.org \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=simona@ffwll.ch \
    --cc=tmgross@umich.edu \
    --cc=ttabi@nvidia.com \
    --cc=tzimmermann@suse.de \
    --cc=yury.norov@gmail.com \
    /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).