From: "Eliot Courtney" <ecourtney@nvidia.com>
To: "Miguel Ojeda" <ojeda@kernel.org>, <ecourtney@nvidia.com>
Cc: <acourbot@nvidia.com>, <aliceryhl@google.com>,
<apopple@nvidia.com>, <bhelgaas@google.com>, <dakr@kernel.org>,
<daniel.almeida@collabora.com>, <driver-core@lists.linux.dev>,
<jhubbard@nvidia.com>, <joelagnelf@nvidia.com>,
<kwilczynski@kernel.org>, <linux-kernel@vger.kernel.org>,
<nova-gpu@lists.linux.dev>, <rust-for-linux@vger.kernel.org>,
<ttabi@nvidia.com>
Subject: Re: [PATCH] rust: pci: add resource_flags accessor
Date: Mon, 26 Oct 2026 13:05:04 +0900 [thread overview]
Message-ID: <DMEH0WG0MQGM.3N81OYGNMHXLV@nvidia.com> (raw)
In-Reply-To: <20261023154005.95904-1-ojeda@kernel.org>
On Sat Oct 24, 2026 at 12:40 AM JST, Miguel Ojeda wrote:
> On Tue, 08 Sep 2026 16:51:48 +0900 Eliot Courtney <ecourtney@nvidia.com> wrote:
>>
>> + /// Wrap a raw `c_ulong` value returned by a C API into [`Flags`].
>> + pub(crate) const fn from_raw(value: c_ulong) -> Self {
>> + Flags(value)
>> + }
>
> In linux-next (next-20261022), on UML x86_64, I am seeing:
>
> error: associated function `from_raw` is never used
> --> rust/kernel/io/resource.rs:240:25
> |
> 216 | impl Flags {
> | ---------- associated function in this implementation
> ...
> 240 | pub(crate) const fn from_raw(value: c_ulong) -> Self {
> | ^^^^^^^^
> |
> = note: `-D dead-code` implied by `-D warnings`
> = help: to override `-D warnings` add `#[allow(dead_code)]`
>
> `kernel::io::resource` is always built, but the only user of `from_raw`
> is under `CONFIG_PCI`.
>
> I hope that helps.
>
> Cheers,
> Miguel
Thanks Miguel! I've sent a fix [1].
[1]: https://lore.kernel.org/all/20261026-pci-fix-v1-1-a6a69ee584d4@nvidia.com/
prev parent reply other threads:[~2026-10-26 4:05 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-08 7:51 Eliot Courtney
2026-09-11 9:53 ` Danilo Krummrich
2026-09-11 12:38 ` Alexandre Courbot
2026-09-11 14:13 ` Eliot Courtney
2026-10-23 15:40 ` Miguel Ojeda
2026-10-26 4:05 ` Eliot Courtney [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=DMEH0WG0MQGM.3N81OYGNMHXLV@nvidia.com \
--to=ecourtney@nvidia.com \
--cc=acourbot@nvidia.com \
--cc=aliceryhl@google.com \
--cc=apopple@nvidia.com \
--cc=bhelgaas@google.com \
--cc=dakr@kernel.org \
--cc=daniel.almeida@collabora.com \
--cc=driver-core@lists.linux.dev \
--cc=jhubbard@nvidia.com \
--cc=joelagnelf@nvidia.com \
--cc=kwilczynski@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nova-gpu@lists.linux.dev \
--cc=ojeda@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=ttabi@nvidia.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
all inboxes | Powered by JetHome®