From: "Benno Lossin" <lossin@kernel.org>
To: "Rhys Lloyd" <krakow20@gmail.com>, <acourbot@nvidia.com>,
<dakr@kernel.org>
Cc: <rust-for-linux@vger.kernel.org>, <airlied@gmail.com>,
<simona@ffwll.ch>, <nouveau@lists.freedesktop.org>,
<dri-devel@lists.freedesktop.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] gpu: nova-core: vbios: change PmuLookupTableEntry to relax alignment
Date: Mon, 14 Jul 2025 12:51:52 +0200 [thread overview]
Message-ID: <DBBPYV1YV97X.OT2SPH3R67RS@kernel.org> (raw)
In-Reply-To: <20250714104322.100511-1-krakow20@gmail.com>
On Mon Jul 14, 2025 at 12:43 PM CEST, Rhys Lloyd wrote:
> +
> + /// Construct a u32 from `self.data`.
> + fn get_data(&self) -> u32 {
Getters in Rust usually don't start with `get_`. Using `data(&self)`
here also looks better IMO.
---
Cheers,
Benno
> + u32::from_le_bytes(self.data)
> + }
> }
prev parent reply other threads:[~2025-07-14 10:51 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-14 10:43 [PATCH] gpu: nova-core: vbios: change PmuLookupTableEntry to relax alignment Rhys Lloyd
2025-07-14 10:43 ` [PATCH] gpu: nova-core: vbios: split out PmuLookupTableHeader from PmuLookupTable Rhys Lloyd
2025-07-16 1:40 ` Alexandre Courbot
2025-07-14 10:43 ` [PATCH] gpu: nova-core: vbios: use size_of instead of magic number Rhys Lloyd
2025-07-16 1:43 ` Alexandre Courbot
2025-07-14 10:51 ` Benno Lossin [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=DBBPYV1YV97X.OT2SPH3R67RS@kernel.org \
--to=lossin@kernel.org \
--cc=acourbot@nvidia.com \
--cc=airlied@gmail.com \
--cc=dakr@kernel.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=krakow20@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=nouveau@lists.freedesktop.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=simona@ffwll.ch \
/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).